From 0863fa4d2370c355098824b2ba30708b87aa95af Mon Sep 17 00:00:00 2001 From: Pierre-Charles David Date: Tue, 7 Jul 2026 16:13:55 +0200 Subject: [PATCH] [cleanup] Remove all code related to the obsolete EEF 1.5 Signed-off-by: Pierre-Charles David --- doc/org.eclipse.emf.eef.doc/.classpath | 7 - doc/org.eclipse.emf.eef.doc/.gitignore | 2 - doc/org.eclipse.emf.eef.doc/.project | 34 - .../org.eclipse.core.resources.prefs | 5 - .../META-INF/MANIFEST.MF | 10 - doc/org.eclipse.emf.eef.doc/about.html | 28 - doc/org.eclipse.emf.eef.doc/build-help.xml | 54 - doc/org.eclipse.emf.eef.doc/build.properties | 21 - .../html/tutorial-toc.xml | 27 - .../html/tutorial.html | 119 - .../html/tutorial.mediawiki | 209 - .../pics/generateEEFArchitecture.png | Bin 10067 -> 0 bytes .../pics/initializeEEFmodels.png | Bin 14110 -> 0 bytes doc/org.eclipse.emf.eef.doc/plugin.xml | 23 - doc/org.eclipse.emf.eef.doc/pom.xml | 57 - .../org/eclipse/emf/eef/doc/Activator.java | 76 - .../.gitignore | 1 - .../.project | 17 - .../build.properties | 20 - .../epl-v10.html | 262 - .../feature.properties | 147 - .../feature.xml | 55 - .../license.html | 116 - .../license.txt | 87 - .../pom.xml | 29 - .../.gitignore | 1 - .../.project | 17 - .../build.properties | 20 - .../epl-v10.html | 262 - .../feature.properties | 147 - .../feature.xml | 45 - .../license.html | 116 - .../license.txt | 87 - .../pom.xml | 29 - .../.gitignore | 1 - .../.project | 17 - .../build.properties | 20 - .../epl-v10.html | 262 - .../feature.properties | 147 - .../feature.xml | 55 - .../license.html | 116 - .../license.txt | 87 - .../pom.xml | 29 - .../.gitignore | 1 - .../.project | 17 - .../build.properties | 20 - .../epl-v10.html | 262 - .../feature.properties | 146 - .../feature.xml | 49 - .../license.html | 116 - .../license.txt | 87 - .../pom.xml | 29 - .../.gitignore | 1 - .../org.eclipse.emf.eef.edt-feature/.project | 17 - .../build.properties | 20 - .../epl-v10.html | 262 - .../feature.properties | 159 - .../feature.xml | 150 - .../license.html | 116 - .../license.txt | 87 - .../org.eclipse.emf.eef.edt-feature/pom.xml | 29 - .../.gitignore | 1 - .../.project | 17 - .../build.properties | 20 - .../epl-v10.html | 262 - .../feature.properties | 147 - .../feature.xml | 69 - .../license.html | 116 - .../license.txt | 87 - .../pom.xml | 29 - .../.gitignore | 1 - .../.project | 17 - .../build.properties | 20 - .../epl-v10.html | 262 - .../feature.properties | 147 - .../feature.xml | 41 - .../license.html | 116 - .../license.txt | 87 - .../pom.xml | 29 - .../.gitignore | 1 - .../.project | 17 - .../build.properties | 20 - .../epl-v10.html | 262 - .../feature.properties | 146 - .../feature.xml | 55 - .../license.html | 116 - .../license.txt | 87 - .../pom.xml | 29 - .../.gitignore | 1 - .../org.eclipse.emf.eef.sdk-feature/.project | 17 - .../build.properties | 23 - .../epl-v10.html | 262 - .../feature.properties | 161 - .../feature.xml | 197 - .../license.html | 116 - .../license.txt | 87 - .../org.eclipse.emf.eef.sdk-feature/pom.xml | 29 - .../org.eclipse.emf.eef.branding/.gitignore | 1 - plugins/org.eclipse.emf.eef.branding/.project | 22 - .../META-INF/MANIFEST.MF | 6 - .../org.eclipse.emf.eef.branding/about.html | 28 - .../org.eclipse.emf.eef.branding/about.ini | 14 - .../about.mappings | 6 - .../about.properties | 20 - .../build.properties | 16 - .../modeling32.png | Bin 2414 -> 0 bytes plugins/org.eclipse.emf.eef.branding/pom.xml | 28 - .../.classpath | 7 - .../.gitignore | 2 - .../org.eclipse.emf.eef.cdo.runtime/.project | 28 - .../.settings/org.eclipse.jdt.core.prefs | 7 - .../META-INF/MANIFEST.MF | 15 - .../build.properties | 5 - .../plugin.xml | 35 - .../org.eclipse.emf.eef.cdo.runtime/pom.xml | 28 - .../schema/CDOLockStrategyProvider.exsd | 102 - .../eef/cdo/runtime/EEFCDORuntimePlugin.java | 66 - .../runtime/policies/CDOReadOnlyPolicy.java | 43 - .../policies/CDOWizardOpeningPolicy.java | 84 - .../runtime/policies/EEFWizardLockPolicy.java | 119 - .../provider/ICDOLockStrategyProvider.java | 57 - .../CDOLockStrategyProviderService.java | 120 - .../.classpath | 9 - .../.gitignore | 2 - .../.project | 48 - .../.settings/org.eclipse.jdt.core.prefs | 6 - .../META-INF/MANIFEST.MF | 27 - .../about.html | 28 - .../build.acceleo | 26 - .../build.properties | 25 - .../plugin.xml | 48 - .../org.eclipse.emf.eef.codegen.ecore/pom.xml | 55 - .../ecore/EEFCodegenEcoreCompiler.java | 148 - .../eef/codegen/ecore/EMFCodegenPlugin.java | 105 - .../ui/launcher/GenerateEMFCodeAction.java | 107 - .../launcher/GenerateEMFEditCodeAction.java | 160 - .../launcher/GenerateEMFEditorCodeAction.java | 159 - .../launcher/GenerateEMFModelCodeAction.java | 153 - .../ecore/util/EEFGeneratorAdapter.java | 193 - .../eef/codegen/ecore/edit/ItemProvider.mtl | 505 -- .../ecore/edit/ItemProviderAdapterFactory.mtl | 602 -- .../emf/eef/codegen/ecore/edit/Plugin.mtl | 254 - .../codegen/ecore/edit/buildproperties.mtl | 49 - .../emf/eef/codegen/ecore/edit/editIcons.mtl | 29 - .../emf/eef/codegen/ecore/edit/manifestmf.mtl | 53 - .../codegen/ecore/edit/pluginproperties.mtl | 81 - .../emf/eef/codegen/ecore/edit/pluginxml.mtl | 136 - .../ecore/editor/ActionBarContributor.mtl | 729 -- .../emf/eef/codegen/ecore/editor/Editor.mtl | 2434 ------ .../eef/codegen/ecore/editor/ModelWizard.mtl | 1014 --- .../emf/eef/codegen/ecore/editor/Plugin.mtl | 160 - .../codegen/ecore/editor/buildproperties.mtl | 48 - .../eef/codegen/ecore/editor/editorIcons.mtl | 24 - .../eef/codegen/ecore/editor/manifestmf.mtl | 87 - .../codegen/ecore/editor/pluginproperties.mtl | 132 - .../eef/codegen/ecore/editor/pluginxml.mtl | 264 - .../emf/eef/codegen/ecore/main/GenEdit.java | 436 - .../emf/eef/codegen/ecore/main/GenEdit.mtl | 68 - .../emf/eef/codegen/ecore/main/GenEditor.java | 437 - .../emf/eef/codegen/ecore/main/GenEditor.mtl | 60 - .../emf/eef/codegen/ecore/main/GenModel.java | 484 -- .../emf/eef/codegen/ecore/main/GenModel.mtl | 145 - .../ecore/model/AdapterFactoryClass.mtl | 180 - .../emf/eef/codegen/ecore/model/Class.mtl | 962 --- .../emf/eef/codegen/ecore/model/EnumClass.mtl | 343 - .../eef/codegen/ecore/model/FactoryClass.mtl | 750 -- .../eef/codegen/ecore/model/PackageClass.mtl | 1279 --- .../emf/eef/codegen/ecore/model/Plugin.mtl | 155 - .../eef/codegen/ecore/model/ResourceClass.mtl | 508 -- .../ecore/model/ResourceFactoryClass.mtl | 140 - .../eef/codegen/ecore/model/SwitchClass.mtl | 227 - .../codegen/ecore/model/ValidatorClass.mtl | 749 -- .../codegen/ecore/model/XmlProcessorClass.mtl | 104 - .../codegen/ecore/model/buildproperties.mtl | 36 - .../codegen/ecore/model/genclass/eIsSet.mtl | 120 - .../codegen/ecore/model/genclass/eUnset.mtl | 44 - .../model/genclass/genDeclaredFields.mtl | 196 - .../ecore/model/genclass/genFeature.mtl | 913 -- .../ecore/model/genclass/genOperation.mtl | 160 - .../reflectiveDelegationAlternative.mtl | 29 - .../ecore/model/genpackage/EGenericType.mtl | 44 - .../emf/eef/codegen/ecore/model/manifest.mtl | 52 - .../codegen/ecore/model/module_gwt_xml.mtl | 42 - .../codegen/ecore/model/plugin_properties.mtl | 36 - .../eef/codegen/ecore/model/plugin_xml.mtl | 113 - .../eef/codegen/ecore/services/FileUtil.java | 77 - .../codegen/ecore/services/Information.java | 29 - .../ecore/services/InformationIterator.java | 84 - .../codegen/ecore/services/StringUtil.java | 36 - .../eef/codegen/ecore/services/StringUtil.mtl | 15 - .../emf/eef/codegen/ecore/services/common.mtl | 14 - .../eef/codegen/ecore/services/fileUtil.mtl | 22 - .../emf/eef/codegen/ecore/services/header.mtl | 42 - .../ecore/services/wrappers/EAnnotation.mtl | 22 - .../services/wrappers/EAnnotationWrapper.java | 84 - .../ecore/services/wrappers/GenBase.mtl | 54 - .../ecore/services/wrappers/GenClass.mtl | 678 -- .../services/wrappers/GenClassWrapper.java | 212 - .../ecore/services/wrappers/GenClassifier.mtl | 138 - .../wrappers/GenClassifierWrapper.java | 37 - .../ecore/services/wrappers/GenDataType.mtl | 236 - .../services/wrappers/GenDataTypeWrapper.java | 35 - .../ecore/services/wrappers/GenEnum.mtl | 254 - .../services/wrappers/GenEnumLiteral.mtl | 89 - .../ecore/services/wrappers/GenFeature.mtl | 487 -- .../ecore/services/wrappers/GenModel.mtl | 464 - .../services/wrappers/GenModelWrapper.java | 220 - .../ecore/services/wrappers/GenOperation.mtl | 373 - .../wrappers/GenOperationWrapper.java | 34 - .../ecore/services/wrappers/GenPackage.mtl | 575 -- .../services/wrappers/GenPackageWrapper.java | 264 - .../ecore/services/wrappers/GenParameter.mtl | 266 - .../services/wrappers/GenTypeParameter.mtl | 76 - .../services/wrappers/GenTypedElement.mtl | 253 - .../templates/edit/CreateChild.gif | Bin 223 -> 0 bytes .../templates/edit/Item.gif | Bin 129 -> 0 bytes .../templates/editor/ModelFile.gif | Bin 346 -> 0 bytes .../templates/editor/NewModel.gif | Bin 2462 -> 0 bytes .../.classpath | 7 - .../.gitignore | 2 - .../.project | 48 - .../.settings/org.eclipse.jdt.core.prefs | 6 - .../META-INF/MANIFEST.MF | 24 - .../about.html | 28 - .../build.acceleo | 26 - .../build.properties | 19 - .../plugin.xml | 15 - .../pom.xml | 75 - .../extended/widgets/richtext/Activator.java | 64 - .../compiler/EEFRichTextCodegenCompiler.java | 169 - .../widgets/impl/richtext/richtextControl.mtl | 60 - .../impl/richtext/richtextFormImpl.mtl | 156 - .../impl/richtext/richtextGettersSetters.mtl | 55 - .../widgets/impl/richtext/richtextSWTImpl.mtl | 156 - .../std/Extended.toolkits | 4 - .../.classpath | 9 - .../.gitignore | 2 - .../.project | 48 - .../.settings/org.eclipse.jdt.core.prefs | 6 - .../META-INF/MANIFEST.MF | 33 - .../about.html | 28 - .../build.acceleo | 26 - .../build.properties | 21 - .../full/obj16/initialize_eef_editor.gif | Bin 1057 -> 0 bytes .../plugin.xml | 68 - .../pom.xml | 76 - .../extended/EEFCodegenExtendedCompiler.java | 172 - .../extended/flow/CleanEEFEditorSources.java | 344 - .../flow/GenerateEEFEditorModels.java | 147 - .../extended/flow/OverrideEMFEditorCode.java | 149 - .../EEFEditorContributionTransformer.java | 78 - .../initializer/EEFEditorInitializer.java | 252 - .../EEFEditorModelInitializer.java | 173 - .../initializer/EEFPagesTransformer.java | 86 - .../extended/launcher/GenerateAll.java | 60 - .../InitializeEEFEditorAction.java | 115 - .../InitializeEEFEditorModelsAction.java | 99 - .../ui/launcher/GenerateEEFEditorAction.java | 248 - .../emf/eef/codegen/extended/Activator.java | 64 - .../editor/api/EditorContribution.mtl | 145 - .../eef/codegen/extended/files/EEFEditor.mtl | 136 - .../extended/launcher/EEFEditorLauncher.java | 442 - .../extended/launcher/EEFEditorLauncher.mtl | 14 - .../eef/codegen/extended/query/oclquery.mtl | 24 - .../extended/services/editor-common.mtl | 14 - .../.classpath | 7 - .../.gitignore | 2 - .../.project | 28 - .../.settings/org.eclipse.jdt.core.prefs | 8 - .../META-INF/MANIFEST.MF | 14 - .../about.html | 28 - .../build.properties | 16 - .../pom.xml | 28 - .../emf/eef/codegen/flow/ConditionalStep.java | 132 - .../emf/eef/codegen/flow/IdentityStep.java | 42 - .../eclipse/emf/eef/codegen/flow/Step.java | 102 - .../emf/eef/codegen/flow/StepWithInput.java | 36 - .../emf/eef/codegen/flow/Workflow.java | 214 - .../eef/codegen/flow/var/WorkflowContext.java | 75 - .../codegen/flow/var/WorkflowVariable.java | 64 - .../codegen/launcher/EEFCodegenLauncher.java | 72 - .../.checkstyle | 10 - .../.classpath | 9 - .../.gitignore | 2 - .../.project | 34 - .../.settings/org.eclipse.jdt.core.prefs | 6 - .../META-INF/MANIFEST.MF | 22 - .../about.html | 28 - .../build.acceleo | 26 - .../build.properties | 20 - .../plugin.xml | 25 - .../org.eclipse.emf.eef.codegen.tests/pom.xml | 60 - .../tests/EEFCodegenTestsCompiler.java | 166 - ...onentPropertiesTestsGeneratorLauncher.java | 87 - .../ComponentTestsGeneratorLauncher.java | 91 - .../emf/eef/tests/codegen/Activator.java | 66 - .../main/cases/ComponentPropertiesTests.java | 420 - .../main/cases/ComponentPropertiesTests.mtl | 112 - .../codegen/main/cases/ComponentTests.java | 420 - .../codegen/main/cases/ComponentTests.mtl | 112 - .../cases/common/ComponentCommonTests.mtl | 283 - .../codegen/services/common/testsNaming.mtl | 23 - .../services/widgets/api/widgetTest.mtl | 77 - .../widgets/impl/EMFComboViewerTest.mtl | 60 - .../advancedEobjectFlatComboViewerTest.mtl | 70 - .../impl/advancedReferencesTableTest.mtl | 88 - .../impl/advancedTableCompositionTest.mtl | 116 - .../services/widgets/impl/checkboxTest.mtl | 61 - .../impl/eobjectFlatComboViewerTest.mtl | 75 - .../widgets/impl/flatReferencesTableTest.mtl | 74 - .../widgets/impl/multiValuedEditorTest.mtl | 62 - .../services/widgets/impl/radioTest.mtl | 60 - .../widgets/impl/referencesTableTest.mtl | 77 - .../widgets/impl/tableCompositionTest.mtl | 114 - .../services/widgets/impl/textTest.mtl | 58 - .../.classpath | 7 - .../.gitignore | 2 - .../org.eclipse.emf.eef.codegen.uml/.project | 42 - .../.settings/org.eclipse.jdt.core.prefs | 6 - .../META-INF/MANIFEST.MF | 16 - .../about.html | 28 - .../build.acceleo | 26 - .../build.properties | 25 - .../plugin.xml | 11 - .../org.eclipse.emf.eef.codegen.uml/pom.xml | 74 - .../emf/eef/codegen/services/umlCommon.mtl | 18 - .../codegen/services/umlComponentUtils.mtl | 31 - .../org.eclipse.emf.eef.codegen/.checkstyle | 10 - .../org.eclipse.emf.eef.codegen/.classpath | 9 - .../org.eclipse.emf.eef.codegen/.gitignore | 3 - plugins/org.eclipse.emf.eef.codegen/.project | 52 - .../org.eclipse.core.resources.prefs | 3 - .../.settings/org.eclipse.core.runtime.prefs | 3 - .../META-INF/MANIFEST.MF | 56 - .../org.eclipse.emf.eef.codegen/about.html | 28 - .../org.eclipse.emf.eef.codegen/build.acceleo | 26 - .../build.properties | 23 - .../org.eclipse.emf.eef.codegen/plugin.xml | 111 - plugins/org.eclipse.emf.eef.codegen/pom.xml | 74 - .../schema/PropertiesGeneratorLauncher.exsd | 109 - .../schema/PropertiesInitializerStrategy.exsd | 116 - .../emf/eef/codegen/EEFCodegenCompiler.java | 166 - .../emf/eef/codegen/EEFCodegenPlugin.java | 76 - .../AbstractPropertiesInitializer.java | 108 - .../core/initializer/AbstractTransformer.java | 87 - .../initializer/ComponentTransformer.java | 126 - .../initializer/IPropertiesInitializer.java | 20 - .../initializer/PropertiesInitializer.java | 208 - .../core/initializer/ViewTransformer.java | 242 - .../AbstractPropertiesGeneratorLauncher.java | 112 - .../codegen/core/launcher/EEFLauncher.java | 54 - .../core/launcher/EMFPropertiesLauncher.java | 27 - .../IPropertiesGeneratorLauncher.java | 25 - .../PropertiesGeneratorLaunchersServices.java | 112 - ...PropertiesInitializerStrategyServices.java | 120 - .../eef/codegen/core/util/BundleHelper.java | 101 - .../emf/eef/codegen/core/util/EMFHelper.java | 120 - .../codegen/core/util/ExtensionHelper.java | 247 - .../eef/codegen/flow/impl/AddDependency.java | 65 - .../codegen/flow/impl/GenerateEEFCode.java | 69 - .../codegen/flow/impl/GenerateEEFModels.java | 163 - .../codegen/flow/impl/GenerateEMFCode.java | 121 - .../flow/impl/GenerateEMFEditCode.java | 59 - .../flow/impl/GenerateEMFEditorCode.java | 59 - .../flow/impl/GenerateEMFModelCode.java | 59 - .../codegen/flow/impl/InitializeGenModel.java | 134 - .../eef/codegen/flow/impl/MergePluginXML.java | 108 - .../eef/codegen/flow/util/GenmodelHelper.java | 238 - .../actions/AbstractGenerateEEFAction.java | 174 - .../generators/actions/GenerateEEFAction.java | 157 - .../callback/EEFGenerationCallback.java | 31 - .../JDTImportsOrganisationCallback.java | 55 - .../ui/generators/common/GenerateAll.java | 112 - .../generators/common/GenerationHelper.java | 94 - .../ui/generators/common/ImportOrganizer.java | 56 - .../actions/InitializeEEFModelsAction.java | 99 - .../ui/InitializeEEFModelsDialog.java | 136 - .../actions/PurifyEEFModelsAction.java | 222 - .../DynamicPropertiesEditionComponent.mtl | 184 - .../components/PropertiesEditionComponent.mtl | 195 - .../SubPropertiesEditionComponent.mtl | 342 - .../emf/eef/codegen/launcher/EEFLauncher.java | 476 -- .../emf/eef/codegen/launcher/EEFLauncher.mtl | 68 - .../parts/FormPropertiesEditionPart.mtl | 371 - .../codegen/parts/IPropertiesEditionPart.mtl | 147 - .../codegen/parts/PropertiesEditionPart.mtl | 356 - .../emf/eef/codegen/parts/ViewsRepository.mtl | 111 - .../emf/eef/codegen/plugin/plugin_xml.mtl | 119 - .../eef/codegen/providers/ContextMessages.mtl | 124 - .../providers/ContextMessagesProperties.mtl | 58 - .../providers/ContextMessagesPropertiesFR.mtl | 58 - .../PackagePropertiesEditionPartProvider.mtl | 77 - .../PackagePropertiesEditionProvider.mtl | 85 - .../providers/PropertiesEditionProvider.mtl | 261 - .../eef/codegen/services/EcoreService.java | 54 - .../eef/codegen/services/ImportService.java | 90 - .../eef/codegen/services/PluginService.java | 72 - .../codegen/services/StringUtilService.java | 49 - .../emf/eef/codegen/services/common.mtl | 522 -- .../emf/eef/codegen/services/emfCodeGen.mtl | 145 - .../emf/eef/codegen/services/filters.mtl | 98 - .../emf/eef/codegen/services/imports.mtl | 107 - .../emf/eef/codegen/services/naming.mtl | 333 - .../eef/codegen/services/navigationStep.mtl | 37 - .../eef/codegen/services/pluginservice.mtl | 16 - .../emf/eef/codegen/services/typeUtils.mtl | 37 - .../emf/eef/codegen/services/viewCommon.mtl | 343 - .../eef/codegen/widgets/api/widgetControl.mtl | 114 - .../codegen/widgets/api/widgetFormImpl.mtl | 90 - .../widgets/api/widgetGettersSetters.mtl | 424 - .../eef/codegen/widgets/api/widgetSWTImpl.mtl | 90 - .../widgets/impl/checkbox/checkboxControl.mtl | 70 - .../impl/checkbox/checkboxFormImpl.mtl | 72 - .../impl/checkbox/checkboxGettersSetters.mtl | 34 - .../widgets/impl/checkbox/checkboxSWTImpl.mtl | 72 - .../widgets/impl/combo/comboControl.mtl | 109 - .../widgets/impl/combo/comboFormImpl.mtl | 78 - .../impl/combo/comboGettersSetters.mtl | 127 - .../widgets/impl/combo/comboSWTImpl.mtl | 77 - .../widgets/impl/custom/customControl.mtl | 45 - .../widgets/impl/custom/customFormImpl.mtl | 31 - .../widgets/impl/custom/customSWTImpl.mtl | 32 - .../emfcomboviewer/emfcomboviewerControl.mtl | 54 - .../emfcomboviewer/emfcomboviewerFormImpl.mtl | 78 - .../emfcomboviewerGettersSetters.mtl | 89 - .../emfcomboviewer/emfcomboviewerSWTImpl.mtl | 76 - .../eobjectflatcomboviewerControl.mtl | 258 - .../eobjectflatcomboviewerFormImpl.mtl | 143 - .../eobjectflatcomboviewerGettersSetters.mtl | 173 - .../eobjectflatcomboviewerSWTImpl.mtl | 132 - .../ereferencesviewerControl.mtl | 184 - .../ereferencesviewerFormImpl.mtl | 149 - .../ereferencesviewerGettersSetters.mtl | 150 - .../ereferencesviewerSWTImpl.mtl | 150 - .../flatreferencestableControl.mtl | 124 - .../flatreferencestableFormImpl.mtl | 73 - .../flatreferencestableGettersSetters.mtl | 133 - .../flatreferencestableSWTImpl.mtl | 72 - .../widgets/impl/group/groupFormImpl.mtl | 50 - .../widgets/impl/group/groupSWTImpl.mtl | 48 - .../widgets/impl/hbox/hboxFormImpl.mtl | 53 - .../codegen/widgets/impl/hbox/hboxSWTImpl.mtl | 51 - .../impl/imageviewer/imageViewerControl.mtl | 73 - .../impl/imageviewer/imageViewerFormImpl.mtl | 80 - .../imageviewer/imageViewerGettersSetters.mtl | 88 - .../impl/imageviewer/imageViewerSWTImpl.mtl | 75 - .../linkeobjectflatcomboviewerControl.mtl | 239 - .../linkeobjectflatcomboviewerFormImpl.mtl | 81 - ...nkeobjectflatcomboviewerGettersSetters.mtl | 141 - .../linkeobjectflatcomboviewerSWTImpl.mtl | 79 - .../linkereferenceviewerControl.mtl | 282 - .../linkereferenceviewerFormImpl.mtl | 81 - .../linkereferenceviewerGettersSetters.mtl | 141 - .../linkereferenceviewerSWTImpl.mtl | 79 - .../multivaluededitorControl.mtl | 68 - .../multivaluededitorFormImpl.mtl | 95 - .../multivaluededitorGettersSetters.mtl | 87 - .../multivaluededitorSWTImpl.mtl | 92 - .../widgets/impl/radio/radioControl.mtl | 64 - .../widgets/impl/radio/radioFormImpl.mtl | 63 - .../impl/radio/radioGettersSetters.mtl | 113 - .../widgets/impl/radio/radioSWTImpl.mtl | 64 - .../referencetable/referencetableControl.mtl | 210 - .../referencetable/referencetableFormImpl.mtl | 374 - .../referencetableGettersSetters.mtl | 165 - .../referencetable/referencetableSWTImpl.mtl | 369 - .../selectionfile/selectionDialogControl.mtl | 64 - .../selectionfile/selectionDialogFormImpl.mtl | 113 - .../selectionDialogGettersSetters.mtl | 35 - .../selectionfile/selectionDialogSWTImpl.mtl | 111 - .../singlecompositioneditorControl.mtl | 90 - .../singlecompositioneditorFormImpl.mtl | 76 - .../singlecompositioneditorGettersSetters.mtl | 93 - .../singlecompositioneditorSWTImpl.mtl | 73 - .../singlecompositionviewerControl.mtl | 35 - .../singlecompositionviewerFormImpl.mtl | 88 - .../singlecompositionviewerGettersSetters.mtl | 125 - .../singlecompositionviewerSWTImpl.mtl | 100 - .../tablecompositionControl.mtl | 296 - .../tablecompositionFormImpl.mtl | 320 - .../tablecompositionGettersSetters.mtl | 171 - .../tablecompositionSWTImpl.mtl | 321 - .../codegen/widgets/impl/text/textControl.mtl | 73 - .../widgets/impl/text/textFormImpl.mtl | 115 - .../widgets/impl/text/textGettersSetters.mtl | 35 - .../codegen/widgets/impl/text/textSWTImpl.mtl | 95 - .../widgets/impl/textarea/textareaControl.mtl | 59 - .../impl/textarea/textareaFormImpl.mtl | 105 - .../impl/textarea/textareaGettersSetters.mtl | 44 - .../widgets/impl/textarea/textareaSWTImpl.mtl | 80 - .../widgets/impl/vbox/vboxFormImpl.mtl | 45 - .../codegen/widgets/impl/vbox/vboxSWTImpl.mtl | 44 - .../.checkstyle | 10 - .../.classpath | 8 - .../.gitignore | 2 - .../.project | 28 - .../.settings/org.eclipse.jdt.ui.prefs | 4 - .../META-INF/MANIFEST.MF | 28 - .../about.html | 28 - .../build.properties | 23 - ...ng_properties_PropertiesEditionElement.gif | Bin 223 -> 0 bytes ...operties_PropertiesMultiEditionElement.gif | Bin 223 -> 0 bytes ...subElements_PropertiesEditionComponent.gif | Bin 223 -> 0 bytes ...ry_bindings_PropertiesEditionComponent.gif | Bin 223 -> 0 bytes ...ng_bindings_PropertiesEditionComponent.gif | Bin 223 -> 0 bytes .../icons/full/obj16/EEFElement.gif | Bin 129 -> 0 bytes .../full/obj16/PropertiesEditionComponent.gif | Bin 623 -> 0 bytes .../full/obj16/PropertiesEditionContext.gif | Bin 361 -> 0 bytes .../full/obj16/PropertiesEditionElement.gif | Bin 318 -> 0 bytes .../obj16/PropertiesMultiEditionElement.gif | Bin 129 -> 0 bytes .../model/components.components | 155 - .../model/components.eefgen | 15 - .../plugin.properties | 38 - .../plugin.xml | 173 - .../pom.xml | 27 - .../src-gen/components_properties.plugin.xml | 110 - ...mponentBasePropertiesEditionComponent.java | 354 - ...onComponentPropertiesEditionComponent.java | 118 - ...ContextBasePropertiesEditionComponent.java | 231 - ...tionContextPropertiesEditionComponent.java | 118 - ...ElementBasePropertiesEditionComponent.java | 363 - ...tionElementPropertiesEditionComponent.java | 118 - ...ElementBasePropertiesEditionComponent.java | 321 - ...tionElementPropertiesEditionComponent.java | 118 - .../parts/ComponentsViewsRepository.java | 130 - ...EditionComponentPropertiesEditionPart.java | 176 - ...esEditionContextPropertiesEditionPart.java | 91 - ...esEditionElementPropertiesEditionPart.java | 162 - ...tiEditionElementPropertiesEditionPart.java | 155 - ...ionComponentPropertiesEditionPartForm.java | 765 -- ...itionContextPropertiesEditionPartForm.java | 291 - ...itionElementPropertiesEditionPartForm.java | 805 -- ...itionElementPropertiesEditionPartForm.java | 842 -- ...ionComponentPropertiesEditionPartImpl.java | 702 -- ...itionContextPropertiesEditionPartImpl.java | 272 - ...itionElementPropertiesEditionPartImpl.java | 744 -- ...itionElementPropertiesEditionPartImpl.java | 783 -- .../provider/ComponentsEditPlugin.java | 103 - .../ComponentsItemProviderAdapterFactory.java | 452 - .../provider/EEFElementItemProvider.java | 147 - ...ropertiesEditionComponentItemProvider.java | 172 - .../PropertiesEditionContextItemProvider.java | 135 - .../PropertiesEditionElementItemProvider.java | 134 - ...ertiesMultiEditionElementItemProvider.java | 134 - .../ComponentsEEFAdapterFactory.java | 112 - .../providers/ComponentsMessages.java | 174 - ...mponentsPropertiesEditionPartProvider.java | 79 - ...ionComponentPropertiesEditionProvider.java | 158 - ...itionContextPropertiesEditionProvider.java | 158 - ...itionElementPropertiesEditionProvider.java | 158 - ...itionElementPropertiesEditionProvider.java | 158 - .../providers/componentsMessages.properties | 61 - .../componentsMessages_fr.properties | 61 - ...lementCustomPropertiesEditionPartForm.java | 42 - ...lementCustomPropertiesEditionPartImpl.java | 48 - ...tsCustomPropertiesEditionPartProvider.java | 36 - .../resources/ComponentsResource.java | 64 - .../resources/ComponentsResourceFactory.java | 30 - .../BadReferencedEditorConstraint.java | 78 - .../provider/CategoryCustomItemProvider.java | 52 - ...ppingCustomItemProviderAdapterFactory.java | 35 - .../.checkstyle | 10 - .../.classpath | 7 - .../.gitignore | 2 - .../.project | 28 - .../META-INF/MANIFEST.MF | 22 - .../about.html | 28 - .../build.properties | 21 - .../icons/full/obj16/ComponentsModelFile.gif | Bin 617 -> 0 bytes .../icons/full/wizban/NewComponents.gif | Bin 2462 -> 0 bytes .../plugin.properties | 58 - .../plugin.xml | 46 - .../pom.xml | 27 - .../ComponentsActionBarContributor.java | 428 - .../presentation/ComponentsEditor.java | 1503 ---- .../presentation/ComponentsEditorPlugin.java | 100 - .../presentation/ComponentsModelWizard.java | 615 -- .../.checkstyle | 10 - .../org.eclipse.emf.eef.components/.classpath | 7 - .../org.eclipse.emf.eef.components/.gitignore | 2 - .../org.eclipse.emf.eef.components/.project | 28 - .../org.eclipse.core.resources.prefs | 4 - .../META-INF/MANIFEST.MF | 17 - .../org.eclipse.emf.eef.components/about.html | 28 - .../build.properties | 19 - .../model/components.ecore | 18 - .../model/components.ecorediag | 117 - .../model/components.genmodel | 27 - .../org.eclipse.emf.eef.components/plugin.xml | 27 - .../org.eclipse.emf.eef.components/pom.xml | 28 - .../emf/eef/components/ComponentsFactory.java | 77 - .../emf/eef/components/ComponentsPackage.java | 651 -- .../emf/eef/components/EEFElement.java | 58 - .../PropertiesEditionComponent.java | 59 - .../components/PropertiesEditionContext.java | 60 - .../components/PropertiesEditionElement.java | 26 - .../PropertiesMultiEditionElement.java | 26 - .../impl/ComponentsFactoryImpl.java | 143 - .../impl/ComponentsPackageImpl.java | 326 - .../eef/components/impl/EEFElementImpl.java | 170 - .../impl/PropertiesEditionComponentImpl.java | 262 - .../impl/PropertiesEditionContextImpl.java | 165 - .../impl/PropertiesEditionElementImpl.java | 207 - .../PropertiesMultiEditionElementImpl.java | 207 - .../util/ComponentsAdapterFactory.java | 345 - .../eef/components/util/ComponentsSwitch.java | 364 - .../.classpath | 7 - .../.gitignore | 2 - .../org.eclipse.emf.eef.editor.model/.project | 28 - .../.settings/org.eclipse.jdt.core.prefs | 8 - .../META-INF/MANIFEST.MF | 31 - .../about.html | 28 - .../build.properties | 21 - ...ementBinding_bindingFilters_PartFilter.gif | Bin 223 -> 0 bytes ...bElements_DynamicEEFEditorContribution.gif | Bin 223 -> 0 bytes ...ding_subElements_EEFEditorContribution.gif | Bin 223 -> 0 bytes ...ubElements_StaticEEFEditorContribution.gif | Bin 223 -> 0 bytes ...pertyBinding_bindingFilters_PartFilter.gif | Bin 223 -> 0 bytes ..._bindings_DynamicEEFEditorContribution.gif | Bin 223 -> 0 bytes ...ategory_bindings_EEFEditorContribution.gif | Bin 223 -> 0 bytes ...y_bindings_StaticEEFEditorContribution.gif | Bin 223 -> 0 bytes ...gory_categories_EEFEditorContributions.gif | Bin 223 -> 0 bytes ...eateCategory_categories_EEFEditorPages.gif | Bin 223 -> 0 bytes .../CreateCategory_views_EEFMasterPage.gif | Bin 223 -> 0 bytes .../CreateCategory_views_StandardFormPage.gif | Bin 223 -> 0 bytes .../CreateCategory_views_TreeMasterPage.gif | Bin 223 -> 0 bytes ...CreateContainer_elements_EEFMasterPage.gif | Bin 223 -> 0 bytes ...ateContainer_elements_StandardFormPage.gif | Bin 223 -> 0 bytes ...reateContainer_elements_TreeMasterPage.gif | Bin 223 -> 0 bytes ..._bindings_DynamicEEFEditorContribution.gif | Bin 223 -> 0 bytes ...binding_bindings_EEFEditorContribution.gif | Bin 223 -> 0 bytes ...g_bindings_StaticEEFEditorContribution.gif | Bin 223 -> 0 bytes ...ding_categories_EEFEditorContributions.gif | Bin 223 -> 0 bytes ...n_input_AllResourcesRootsRelativeInput.gif | Bin 223 -> 0 bytes ...n_input_FirstResourceRootRelativeInput.gif | Bin 223 -> 0 bytes ...n_model_AllResourcesRootsRelativeInput.gif | Bin 223 -> 0 bytes ...n_model_FirstResourceRootRelativeInput.gif | Bin 223 -> 0 bytes ...teEEFPageInput_query_ExplicitPathQuery.gif | Bin 223 -> 0 bytes .../CreateEEFPageInput_query_OCLQuery.gif | Bin 223 -> 0 bytes ...wsRepository_categories_EEFEditorPages.gif | Bin 223 -> 0 bytes ...ateViewsRepository_views_EEFMasterPage.gif | Bin 223 -> 0 bytes ...ViewsRepository_views_StandardFormPage.gif | Bin 223 -> 0 bytes ...teViewsRepository_views_TreeMasterPage.gif | Bin 223 -> 0 bytes .../obj16/AllResourcesRootsRelativeInput.gif | Bin 163 -> 0 bytes .../obj16/DynamicEEFEditorContribution.gif | Bin 129 -> 0 bytes .../full/obj16/EEFEditorContribution.gif | Bin 587 -> 0 bytes .../full/obj16/EEFEditorContributions.gif | Bin 387 -> 0 bytes .../icons/full/obj16/EEFEditorPages.gif | Bin 604 -> 0 bytes .../icons/full/obj16/EEFMasterPage.gif | Bin 565 -> 0 bytes .../icons/full/obj16/ExplicitPathQuery.gif | Bin 576 -> 0 bytes .../obj16/FirstResourceRootRelativeInput.gif | Bin 577 -> 0 bytes .../icons/full/obj16/MasterDetailsPage.gif | Bin 352 -> 0 bytes .../icons/full/obj16/OCLQuery.gif | Bin 101 -> 0 bytes .../icons/full/obj16/PartFilter.gif | Bin 219 -> 0 bytes .../icons/full/obj16/ReferenceableObject.gif | Bin 129 -> 0 bytes .../icons/full/obj16/StandardFormPage.gif | Bin 351 -> 0 bytes .../obj16/StaticEEFEditorContribution.gif | Bin 587 -> 0 bytes .../icons/full/obj16/TreeMasterPage.gif | Bin 372 -> 0 bytes .../model/extended.components | 285 - .../model/extended.ecore | 58 - .../model/extended.ecorediag | 798 -- .../model/extended.eefgen | 21 - .../model/extended.genmodel | 59 - .../plugin.properties | 51 - .../plugin.xml | 266 - .../org.eclipse.emf.eef.editor.model/pom.xml | 27 - .../src-gen/editor_properties.plugin.xml | 164 - .../AllResourcesRootsRelativeInput.java | 25 - .../editor/DynamicEEFEditorContribution.java | 26 - .../editor/EEFEditorContribution.java | 58 - .../editor/EEFEditorContributions.java | 26 - .../eef/extended/editor/EEFEditorPages.java | 26 - .../eef/extended/editor/EEFMasterPage.java | 84 - .../emf/eef/extended/editor/EEFPage.java | 58 - .../emf/eef/extended/editor/EEFPageInput.java | 59 - .../eef/extended/editor/EditorFactory.java | 140 - .../eef/extended/editor/EditorPackage.java | 1688 ---- .../FirstResourceRootRelativeInput.java | 25 - .../extended/editor/MasterDetailsPage.java | 25 - .../emf/eef/extended/editor/PartFilter.java | 87 - .../extended/editor/ReferenceableObject.java | 26 - .../eef/extended/editor/StandardFormPage.java | 25 - .../editor/StaticEEFEditorContribution.java | 26 - .../eef/extended/editor/TreeMasterPage.java | 57 - ...ibutionBasePropertiesEditionComponent.java | 298 - ...ontributionPropertiesEditionComponent.java | 118 - ...butionsBasePropertiesEditionComponent.java | 185 - ...ntributionsPropertiesEditionComponent.java | 118 - ...orPagesBasePropertiesEditionComponent.java | 197 - ...EditorPagesPropertiesEditionComponent.java | 118 - ...terPageBasePropertiesEditionComponent.java | 268 - ...FMasterPagePropertiesEditionComponent.java | 118 - ...tFilterBasePropertiesEditionComponent.java | 342 - .../PartFilterPropertiesEditionComponent.java | 118 - ...ormPageBasePropertiesEditionComponent.java | 224 - ...ardFormPagePropertiesEditionComponent.java | 118 - ...ibutionBasePropertiesEditionComponent.java | 236 - ...ontributionPropertiesEditionComponent.java | 118 - ...terPageBasePropertiesEditionComponent.java | 246 - ...eMasterPagePropertiesEditionComponent.java | 118 - .../AllResourcesRootsRelativeInputImpl.java | 46 - .../DynamicEEFEditorContributionImpl.java | 214 - .../impl/EEFEditorContributionImpl.java | 180 - .../impl/EEFEditorContributionsImpl.java | 47 - .../editor/impl/EEFEditorPagesImpl.java | 47 - .../editor/impl/EEFMasterPageImpl.java | 221 - .../eef/extended/editor/impl/EEFPageImpl.java | 168 - .../editor/impl/EEFPageInputImpl.java | 181 - .../editor/impl/EditorFactoryImpl.java | 222 - .../editor/impl/EditorPackageImpl.java | 592 -- .../FirstResourceRootRelativeInputImpl.java | 46 - .../editor/impl/MasterDetailsPageImpl.java | 46 - .../extended/editor/impl/PartFilterImpl.java | 223 - .../editor/impl/ReferenceableObjectImpl.java | 47 - .../editor/impl/StandardFormPageImpl.java | 46 - .../impl/StaticEEFEditorContributionImpl.java | 214 - .../editor/impl/TreeMasterPageImpl.java | 167 - ...itorContributionPropertiesEditionPart.java | 148 - ...torContributionsPropertiesEditionPart.java | 55 - .../EEFEditorPagesPropertiesEditionPart.java | 55 - .../EEFMasterPagePropertiesEditionPart.java | 97 - .../editor/parts/EditorViewsRepository.java | 210 - .../parts/FilterPropertiesEditionPart.java | 138 - .../PartFilterPropertiesEditionPart.java | 166 - ...StandardFormPagePropertiesEditionPart.java | 69 - ...itorContributionPropertiesEditionPart.java | 99 - .../TreeMasterPagePropertiesEditionPart.java | 82 - ...ContributionPropertiesEditionPartForm.java | 591 -- ...ontributionsPropertiesEditionPartForm.java | 266 - ...FEditorPagesPropertiesEditionPartForm.java | 266 - ...EFMasterPagePropertiesEditionPartForm.java | 528 -- .../PartFilterPropertiesEditionPartForm.java | 638 -- ...dardFormPagePropertiesEditionPartForm.java | 371 - ...ContributionPropertiesEditionPartForm.java | 460 - ...eeMasterPagePropertiesEditionPartForm.java | 463 - ...ContributionPropertiesEditionPartImpl.java | 549 -- ...ontributionsPropertiesEditionPartImpl.java | 235 - ...FEditorPagesPropertiesEditionPartImpl.java | 235 - ...EFMasterPagePropertiesEditionPartImpl.java | 478 -- .../PartFilterPropertiesEditionPartImpl.java | 590 -- ...dardFormPagePropertiesEditionPartImpl.java | 321 - ...ContributionPropertiesEditionPartImpl.java | 425 - ...eeMasterPagePropertiesEditionPartImpl.java | 412 - ...sourcesRootsRelativeInputItemProvider.java | 112 - ...amicEEFEditorContributionItemProvider.java | 188 - .../EEFEditorContributionItemProvider.java | 182 - .../EEFEditorContributionsItemProvider.java | 126 - .../provider/EEFEditorPagesItemProvider.java | 133 - .../provider/EEFMasterPageItemProvider.java | 173 - .../provider/EEFPageInputItemProvider.java | 166 - .../editor/provider/EEFPageItemProvider.java | 156 - .../EditorItemProviderAdapterFactory.java | 818 -- .../editor/provider/ExtendedEditPlugin.java | 106 - ...ResourceRootRelativeInputItemProvider.java | 112 - .../MasterDetailsPageItemProvider.java | 105 - .../provider/PartFilterItemProvider.java | 165 - .../ReferenceableObjectItemProvider.java | 126 - .../StandardFormPageItemProvider.java | 116 - ...aticEEFEditorContributionItemProvider.java | 188 - .../provider/TreeMasterPageItemProvider.java | 149 - ...ContributionPropertiesEditionProvider.java | 158 - ...ontributionsPropertiesEditionProvider.java | 158 - ...FEditorPagesPropertiesEditionProvider.java | 158 - ...EFMasterPagePropertiesEditionProvider.java | 158 - .../providers/EditorEEFAdapterFactory.java | 109 - .../editor/providers/EditorMessages.java | 237 - .../EditorPropertiesEditionPartProvider.java | 111 - .../PartFilterPropertiesEditionProvider.java | 158 - ...dardFormPagePropertiesEditionProvider.java | 158 - ...ContributionPropertiesEditionProvider.java | 158 - ...eeMasterPagePropertiesEditionProvider.java | 158 - .../providers/editorMessages.properties | 82 - .../providers/editorMessages_fr.properties | 82 - .../editor/util/EditorAdapterFactory.java | 600 -- .../extended/editor/util/EditorSwitch.java | 662 -- .../query/EEFUnderstandableQuery.java | 26 - .../eef/extended/query/ExplicitPathQuery.java | 58 - .../emf/eef/extended/query/OCLQuery.java | 85 - .../emf/eef/extended/query/QueryFactory.java | 59 - .../emf/eef/extended/query/QueryPackage.java | 293 - ...itPathQueryPropertiesEditionComponent.java | 215 - .../OCLQueryPropertiesEditionComponent.java | 245 - .../impl/EEFUnderstandableQueryImpl.java | 47 - .../query/impl/ExplicitPathQueryImpl.java | 161 - .../eef/extended/query/impl/OCLQueryImpl.java | 229 - .../extended/query/impl/QueryFactoryImpl.java | 114 - .../extended/query/impl/QueryPackageImpl.java | 267 - ...xplicitPathQueryPropertiesEditionPart.java | 91 - .../parts/OCLQueryPropertiesEditionPart.java | 105 - .../query/parts/QueryViewsRepository.java | 57 - ...citPathQueryPropertiesEditionPartForm.java | 287 - .../OCLQueryPropertiesEditionPartForm.java | 399 - ...citPathQueryPropertiesEditionPartImpl.java | 269 - .../OCLQueryPropertiesEditionPartImpl.java | 361 - .../EEFUnderstandableQueryItemProvider.java | 115 - .../ExplicitPathQueryItemProvider.java | 137 - .../query/provider/OCLQueryItemProvider.java | 172 - .../QueryItemProviderAdapterFactory.java | 229 - ...citPathQueryPropertiesEditionProvider.java | 150 - .../OCLQueryPropertiesEditionProvider.java | 150 - .../providers/QueryEEFAdapterFactory.java | 40 - .../query/providers/QueryMessages.java | 114 - .../QueryPropertiesEditionPartProvider.java | 63 - .../query/providers/queryMessages.properties | 41 - .../providers/queryMessages_fr.properties | 41 - .../query/util/QueryAdapterFactory.java | 183 - .../eef/extended/query/util/QuerySwitch.java | 199 - .../src-gen/query_properties.plugin.xml | 73 - .../.checkstyle | 10 - .../.classpath | 7 - .../.gitignore | 2 - .../org.eclipse.emf.eef.eefgen.edit/.project | 28 - .../META-INF/MANIFEST.MF | 25 - .../about.html | 28 - .../build.properties | 21 - ...odel_editionContexts_GenEditionContext.gif | Bin 223 -> 0 bytes ...nModel_references_EEFGenModelReference.gif | Bin 223 -> 0 bytes ...l_viewsRepositories_GenViewsRepository.gif | Bin 223 -> 0 bytes ..._references_GenEditionContextReference.gif | Bin 223 -> 0 bytes .../icons/full/obj16/EEFGenModel.gif | Bin 372 -> 0 bytes .../icons/full/obj16/EEFGenModelReference.gif | Bin 145 -> 0 bytes .../icons/full/obj16/GenEditionContext.gif | Bin 1072 -> 0 bytes .../icons/full/obj16/GenViewsRepository.gif | Bin 606 -> 0 bytes .../model/EEFGen.components | 193 - .../model/EEFGen.eefgen | 9 - .../plugin.properties | 90 - .../plugin.xml | 102 - .../org.eclipse.emf.eef.eefgen.edit/pom.xml | 27 - .../src-gen/EEFGen_properties.plugin.xml | 79 - ...EEFGenModelPropertiesEditionComponent.java | 286 - ...elReferencePropertiesEditionComponent.java | 219 - ...tionContextPropertiesEditionComponent.java | 411 - ...sRepositoryPropertiesEditionComponent.java | 383 - .../EEFGenModelPropertiesEditionPart.java | 111 - ...enModelReferencePropertiesEditionPart.java | 91 - .../EEFGen/parts/EEFGenViewsRepository.java | 170 - ...enEditionContextPropertiesEditionPart.java | 189 - ...nViewsRepositoryPropertiesEditionPart.java | 183 - .../EEFGenModelPropertiesEditionPartForm.java | 664 -- ...delReferencePropertiesEditionPartForm.java | 287 - ...itionContextPropertiesEditionPartForm.java | 982 --- ...wsRepositoryPropertiesEditionPartForm.java | 897 -- .../EEFGenModelPropertiesEditionPartImpl.java | 571 -- ...delReferencePropertiesEditionPartImpl.java | 269 - ...itionContextPropertiesEditionPartImpl.java | 884 -- ...wsRepositoryPropertiesEditionPartImpl.java | 817 -- .../eef/EEFGen/provider/EEFGenEditPlugin.java | 106 - .../EEFGenItemProviderAdapterFactory.java | 277 - .../provider/EEFGenModelItemProvider.java | 312 - .../EEFGenModelReferenceItemProvider.java | 150 - .../GenEditionContextItemProvider.java | 329 - .../GenViewsRepositoryItemProvider.java | 305 - .../providers/EEFGenEEFAdapterFactory.java | 56 - .../eef/EEFGen/providers/EEFGenMessages.java | 207 - .../EEFGenModelPropertiesEditionProvider.java | 150 - ...delReferencePropertiesEditionProvider.java | 150 - .../EEFGenPropertiesEditionPartProvider.java | 79 - ...itionContextPropertiesEditionProvider.java | 150 - ...wsRepositoryPropertiesEditionProvider.java | 150 - .../providers/eEFGenMessages.properties | 72 - .../providers/eEFGenMessages_fr.properties | 72 - .../.checkstyle | 10 - .../.classpath | 7 - .../.gitignore | 2 - .../.project | 28 - .../META-INF/MANIFEST.MF | 23 - .../about.html | 28 - .../build.properties | 21 - .../icons/full/obj16/EEFGenModelFile.gif | Bin 351 -> 0 bytes .../icons/full/wizban/NewEEFGen.gif | Bin 2462 -> 0 bytes .../plugin.properties | 59 - .../plugin.xml | 46 - .../org.eclipse.emf.eef.eefgen.editor/pom.xml | 27 - .../EEFGenActionBarContributor.java | 426 - .../eef/EEFGen/presentation/EEFGenEditor.java | 1540 ---- .../presentation/EEFGenEditorPlugin.java | 107 - .../presentation/EEFGenModelWizard.java | 610 -- .../org.eclipse.emf.eef.eefgen/.checkstyle | 10 - plugins/org.eclipse.emf.eef.eefgen/.classpath | 7 - plugins/org.eclipse.emf.eef.eefgen/.gitignore | 2 - plugins/org.eclipse.emf.eef.eefgen/.project | 28 - .../META-INF/MANIFEST.MF | 18 - plugins/org.eclipse.emf.eef.eefgen/about.html | 28 - .../build.properties | 20 - .../model/EEFGen.ecore | 60 - .../model/EEFGen.genmodel | 58 - plugins/org.eclipse.emf.eef.eefgen/plugin.xml | 27 - plugins/org.eclipse.emf.eef.eefgen/pom.xml | 27 - .../eclipse/emf/eef/EEFGen/EEFGenFactory.java | 77 - .../eclipse/emf/eef/EEFGen/EEFGenModel.java | 223 - .../emf/eef/EEFGen/EEFGenModelReference.java | 58 - .../eclipse/emf/eef/EEFGen/EEFGenPackage.java | 1006 --- .../emf/eef/EEFGen/GenEditionContext.java | 277 - .../emf/eef/EEFGen/GenViewsRepository.java | 253 - .../eclipse/emf/eef/EEFGen/HELP_STRATEGY.java | 216 - .../eef/EEFGen/impl/EEFGenFactoryImpl.java | 191 - .../emf/eef/EEFGen/impl/EEFGenModelImpl.java | 533 -- .../EEFGen/impl/EEFGenModelReferenceImpl.java | 162 - .../eef/EEFGen/impl/EEFGenPackageImpl.java | 556 -- .../EEFGen/impl/GenEditionContextImpl.java | 653 -- .../EEFGen/impl/GenViewsRepositoryImpl.java | 600 -- .../eef/EEFGen/util/EEFGenAdapterFactory.java | 183 - .../emf/eef/EEFGen/util/EEFGenSwitch.java | 200 - .../.classpath | 7 - .../.gitignore | 2 - .../.project | 34 - .../.settings/org.eclipse.jdt.core.prefs | 11 - .../META-INF/MANIFEST.MF | 12 - .../about.html | 28 - .../build.properties | 16 - .../pom.xml | 28 - .../richtext/actions/EEFFontNameAction.java | 72 - .../richtext/actions/EEFFontSizeAction.java | 64 - .../richtext/actions/EEFFontStyleAction.java | 62 - .../.checkstyle | 10 - .../.classpath | 8 - .../.gitignore | 2 - .../org.eclipse.emf.eef.mapping.edit/.project | 28 - .../META-INF/MANIFEST.MF | 27 - .../about.html | 28 - .../build.properties | 22 - ...g_bindingFilters_JavaDeclarationFilter.gif | Bin 223 -> 0 bytes ...ng_bindingFilters_JavaExpressionFilter.gif | Bin 223 -> 0 bytes ...lementBinding_bindingFilters_OCLFilter.gif | Bin 223 -> 0 bytes ...bindingFilters_OnlyReferenceTypeFilter.gif | Bin 223 -> 0 bytes ...ding_bindingFilters_StrictTypingFilter.gif | Bin 223 -> 0 bytes ...g_properties_EMFMultiPropertiesBinding.gif | Bin 223 -> 0 bytes ...tBinding_properties_EMFPropertyBinding.gif | Bin 223 -> 0 bytes ...ing_properties_StandardPropertyBinding.gif | Bin 223 -> 0 bytes ...erencedBinding_ElementBindingReference.gif | Bin 223 -> 0 bytes ...tBinding_subElements_EMFElementBinding.gif | Bin 223 -> 0 bytes ...ing_subElements_StandardElementBinding.gif | Bin 223 -> 0 bytes ...g_bindingFilters_JavaDeclarationFilter.gif | Bin 223 -> 0 bytes ...ng_bindingFilters_JavaExpressionFilter.gif | Bin 223 -> 0 bytes ...opertyBinding_bindingFilters_OCLFilter.gif | Bin 223 -> 0 bytes ...bindingFilters_OnlyReferenceTypeFilter.gif | Bin 223 -> 0 bytes ...ding_bindingFilters_StrictTypingFilter.gif | Bin 223 -> 0 bytes ...ateCategory_bindings_EMFElementBinding.gif | Bin 223 -> 0 bytes ...tegory_bindings_StandardElementBinding.gif | Bin 223 -> 0 bytes .../CreateCategory_categories_Category.gif | Bin 223 -> 0 bytes ...igation_current_ChainedModelNavigation.gif | Bin 223 -> 0 bytes ...vigation_current_SimpleModelNavigation.gif | Bin 223 -> 0 bytes ...tion_current_StructuredModelNavigation.gif | Bin 223 -> 0 bytes ...Navigation_next_ChainedModelNavigation.gif | Bin 223 -> 0 bytes ...lNavigation_next_SimpleModelNavigation.gif | Bin 223 -> 0 bytes ...igation_next_StructuredModelNavigation.gif | Bin 223 -> 0 bytes ...edNavigation_current_ChainedNavigation.gif | Bin 223 -> 0 bytes ...tion_current_SimpleMetamodelNavigation.gif | Bin 223 -> 0 bytes ...ainedNavigation_next_ChainedNavigation.gif | Bin 223 -> 0 bytes ...igation_next_SimpleMetamodelNavigation.gif | Bin 223 -> 0 bytes ...Databinding_bindings_EMFElementBinding.gif | Bin 223 -> 0 bytes ...inding_bindings_StandardElementBinding.gif | Bin 223 -> 0 bytes .../CreateDatabinding_categories_Category.gif | Bin 223 -> 0 bytes ...ding_navigation_ChainedModelNavigation.gif | Bin 223 -> 0 bytes ...nding_navigation_CustomModelNavigation.gif | Bin 223 -> 0 bytes ...nding_navigation_SimpleModelNavigation.gif | Bin 223 -> 0 bytes ...inding_navigation_SmartModelNavigation.gif | Bin 223 -> 0 bytes ...editorSetting_EReferenceViewerSettings.gif | Bin 223 -> 0 bytes ...ding_navigation_ChainedModelNavigation.gif | Bin 223 -> 0 bytes ...tyBinding_navigation_ChainedNavigation.gif | Bin 223 -> 0 bytes ...nding_navigation_CustomModelNavigation.gif | Bin 223 -> 0 bytes ...g_navigation_SimpleMetamodelNavigation.gif | Bin 223 -> 0 bytes ...nding_navigation_SimpleModelNavigation.gif | Bin 223 -> 0 bytes ...inding_navigation_SmartModelNavigation.gif | Bin 223 -> 0 bytes ...g_navigation_StructuredModelNavigation.gif | Bin 223 -> 0 bytes ...ewerSettings_filter_JavaBodyStepFilter.gif | Bin 223 -> 0 bytes ...tings_filter_JavaDeclarationStepFilter.gif | Bin 223 -> 0 bytes ...igationStep_filters_JavaBodyStepFilter.gif | Bin 223 -> 0 bytes ...Step_filters_JavaDeclarationStepFilter.gif | Bin 223 -> 0 bytes ...ep_initializer_JavaBodyStepInitializer.gif | Bin 223 -> 0 bytes ...ializer_JavaDeclarationStepInitializer.gif | Bin 223 -> 0 bytes ...Step_subStep_DeclarativeNavigationStep.gif | Bin 223 -> 0 bytes ...igation_step_DeclarativeNavigationStep.gif | Bin 223 -> 0 bytes .../full/obj16/AbstractElementBinding.gif | Bin 129 -> 0 bytes .../full/obj16/AbstractPropertyBinding.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Category.gif | Bin 589 -> 0 bytes .../full/obj16/ChainedModelNavigation.gif | Bin 215 -> 0 bytes .../full/obj16/CustomModelNavigation.gif | Bin 564 -> 0 bytes .../icons/full/obj16/Databinding.gif | Bin 224 -> 0 bytes .../full/obj16/DeclarativeNavigationStep.gif | Bin 211 -> 0 bytes .../icons/full/obj16/DocumentedElement.gif | Bin 129 -> 0 bytes .../icons/full/obj16/EMFElementBinding.gif | Bin 337 -> 0 bytes .../full/obj16/EMFMultiPropertiesBinding.gif | Bin 129 -> 0 bytes .../icons/full/obj16/EMFPropertyBinding.gif | Bin 186 -> 0 bytes .../full/obj16/EReferenceViewerSettings.gif | Bin 186 -> 0 bytes .../full/obj16/ElementBindingReference.gif | Bin 583 -> 0 bytes .../icons/full/obj16/JavaBodyExpression.gif | Bin 129 -> 0 bytes .../icons/full/obj16/JavaBodyStepFilter.gif | Bin 219 -> 0 bytes .../full/obj16/JavaBodyStepInitializer.gif | Bin 355 -> 0 bytes .../full/obj16/JavaDeclarationFilter.gif | Bin 578 -> 0 bytes .../full/obj16/JavaDeclarationStepFilter.gif | Bin 209 -> 0 bytes .../obj16/JavaDeclarationStepInitializer.gif | Bin 314 -> 0 bytes .../icons/full/obj16/JavaExpressionFilter.gif | Bin 909 -> 0 bytes .../icons/full/obj16/OCLFilter.gif | Bin 129 -> 0 bytes .../full/obj16/OnlyReferenceTypeFilter.gif | Bin 183 -> 0 bytes .../full/obj16/SimpleModelNavigation.gif | Bin 336 -> 0 bytes .../icons/full/obj16/SmartModelNavigation.gif | Bin 356 -> 0 bytes .../full/obj16/StandardElementBinding.gif | Bin 186 -> 0 bytes .../full/obj16/StandardPropertyBinding.gif | Bin 298 -> 0 bytes .../icons/full/obj16/StrictTypingFilter.gif | Bin 129 -> 0 bytes .../full/obj16/StructuredModelNavigation.gif | Bin 191 -> 0 bytes .../model/mapping.components | 505 -- .../model/mapping.eefgen | 27 - .../plugin.properties | 171 - .../plugin.xml | 565 -- .../org.eclipse.emf.eef.mapping.edit/pom.xml | 27 - .../src-gen/filters_properties.plugin.xml | 195 - .../src-gen/mapping_properties.plugin.xml | 169 - .../src-gen/navigation_properties.plugin.xml | 97 - ...yStepFilterPropertiesEditionComponent.java | 197 - ...nFilterBasePropertiesEditionComponent.java | 199 - ...ationFilterPropertiesEditionComponent.java | 133 - ...nStepFilterPropertiesEditionComponent.java | 246 - ...nFilterBasePropertiesEditionComponent.java | 198 - ...ssionFilterPropertiesEditionComponent.java | 133 - ...LFilterBasePropertiesEditionComponent.java | 198 - .../OCLFilterPropertiesEditionComponent.java | 133 - ...eFilterBasePropertiesEditionComponent.java | 233 - ...eTypeFilterPropertiesEditionComponent.java | 133 - ...ilterFilterPropertiesEditionComponent.java | 133 - ...ypingFilterPropertiesEditionComponent.java | 241 - .../providers/FiltersEEFAdapterFactory.java | 119 - ...dyStepFilterPropertiesEditionProvider.java | 150 - ...rationFilterPropertiesEditionProvider.java | 164 - ...onStepFilterPropertiesEditionProvider.java | 150 - ...essionFilterPropertiesEditionProvider.java | 164 - .../OCLFilterPropertiesEditionProvider.java | 164 - ...ceTypeFilterPropertiesEditionProvider.java | 164 - ...FilterFilterPropertiesEditionProvider.java | 164 - ...ategoryBasePropertiesEditionComponent.java | 187 - .../CategoryPropertiesEditionComponent.java | 116 - ...ntedElementPropertiesEditionComponent.java | 188 - ...BindingBasePropertiesEditionComponent.java | 301 - ...mentBindingPropertiesEditionComponent.java | 116 - ...BindingBasePropertiesEditionComponent.java | 277 - ...tiesBindingPropertiesEditionComponent.java | 116 - ...BindingBasePropertiesEditionComponent.java | 300 - ...ertyBindingPropertiesEditionComponent.java | 116 - ...ferenceBasePropertiesEditionComponent.java | 229 - ...ngReferencePropertiesEditionComponent.java | 116 - ...rPropertiesPropertiesEditionComponent.java | 199 - ...BindingBasePropertiesEditionComponent.java | 301 - ...mentBindingPropertiesEditionComponent.java | 116 - ...BindingBasePropertiesEditionComponent.java | 301 - ...ertyBindingPropertiesEditionComponent.java | 116 - .../filters/parts/FiltersViewsRepository.java | 150 - ...vaBodyStepFilterPropertiesEditionPart.java | 54 - ...eclarationFilterPropertiesEditionPart.java | 88 - ...rationStepFilterPropertiesEditionPart.java | 82 - ...ExpressionFilterPropertiesEditionPart.java | 88 - .../parts/OCLFilterPropertiesEditionPart.java | 88 - ...erenceTypeFilterPropertiesEditionPart.java | 125 - ...rictTypingFilterPropertiesEditionPart.java | 125 - ...dyStepFilterPropertiesEditionPartForm.java | 270 - ...rationFilterPropertiesEditionPartForm.java | 336 - ...onStepFilterPropertiesEditionPartForm.java | 453 - ...essionFilterPropertiesEditionPartForm.java | 327 - .../OCLFilterPropertiesEditionPartForm.java | 327 - ...ceTypeFilterPropertiesEditionPartForm.java | 357 - ...TypingFilterPropertiesEditionPartForm.java | 357 - ...dyStepFilterPropertiesEditionPartImpl.java | 234 - ...rationFilterPropertiesEditionPartImpl.java | 304 - ...onStepFilterPropertiesEditionPartImpl.java | 404 - ...essionFilterPropertiesEditionPartImpl.java | 290 - .../OCLFilterPropertiesEditionPartImpl.java | 290 - ...ceTypeFilterPropertiesEditionPartImpl.java | 338 - ...TypingFilterPropertiesEditionPartImpl.java | 338 - .../provider/BindingFilterItemProvider.java | 152 - .../provider/BusinessFilterItemProvider.java | 99 - .../FiltersItemProviderAdapterFactory.java | 412 - .../JavaBodyStepFilterItemProvider.java | 112 - .../JavaDeclarationFilterItemProvider.java | 145 - ...JavaDeclarationStepFilterItemProvider.java | 114 - .../JavaExpressionFilterItemProvider.java | 144 - .../provider/JavaFilterItemProvider.java | 99 - .../provider/OCLFilterItemProvider.java | 141 - .../OnlyReferenceTypeFilterItemProvider.java | 136 - .../provider/StepFilterItemProvider.java | 108 - .../StrictTypingFilterItemProvider.java | 133 - .../filters/providers/FiltersMessages.java | 177 - .../FiltersPropertiesEditionPartProvider.java | 103 - .../providers/filtersMessages.properties | 62 - .../providers/filtersMessages_fr.properties | 62 - ...veNavigationStepPropertiesEditionPart.java | 154 - ...yStepInitializerPropertiesEditionPart.java | 54 - ...nStepInitializerPropertiesEditionPart.java | 82 - .../ModelNavigationPropertiesEditionPart.java | 41 - .../parts/NavigationViewsRepository.java | 114 - ...eModelNavigationPropertiesEditionPart.java | 152 - ...vigationStepPropertiesEditionPartForm.java | 534 -- ...pInitializerPropertiesEditionPartForm.java | 270 - ...pInitializerPropertiesEditionPartForm.java | 453 - ...elNavigationPropertiesEditionPartForm.java | 151 - ...elNavigationPropertiesEditionPartForm.java | 532 -- ...vigationStepPropertiesEditionPartImpl.java | 508 -- ...pInitializerPropertiesEditionPartImpl.java | 234 - ...pInitializerPropertiesEditionPartImpl.java | 404 - ...elNavigationPropertiesEditionPartImpl.java | 140 - ...elNavigationPropertiesEditionPartImpl.java | 487 -- .../ChainedModelNavigationItemProvider.java | 197 - .../CustomModelNavigationItemProvider.java | 111 - ...DeclarativeNavigationStepItemProvider.java | 275 - .../JavaBodyExpressionItemProvider.java | 156 - .../JavaBodyStepInitializerItemProvider.java | 112 - ...JavaDeclarationExpressionItemProvider.java | 194 - ...eclarationStepInitializerItemProvider.java | 115 - .../provider/ModelNavigationItemProvider.java | 110 - .../NavigationItemProviderAdapterFactory.java | 439 - .../provider/NavigationStepItemProvider.java | 184 - .../SimpleModelNavigationItemProvider.java | 279 - .../SmartModelNavigationItemProvider.java | 157 - .../provider/StepInitializerItemProvider.java | 108 - ...StructuredModelNavigationItemProvider.java | 111 - .../providers/NavigationMessages.java | 162 - ...vigationPropertiesEditionPartProvider.java | 87 - .../providers/navigationMessages.properties | 57 - .../navigationMessages_fr.properties | 57 - .../parts/CategoryPropertiesEditionPart.java | 55 - .../DocumentationPropertiesEditionPart.java | 53 - ...MFElementBindingPropertiesEditionPart.java | 148 - ...ropertiesBindingPropertiesEditionPart.java | 141 - ...FPropertyBindingPropertiesEditionPart.java | 148 - ...BindingReferencePropertiesEditionPart.java | 91 - ...FilterPropertiesPropertiesEditionPart.java | 67 - .../mapping/parts/MappingViewsRepository.java | 218 - ...rdElementBindingPropertiesEditionPart.java | 148 - ...dPropertyBindingPropertiesEditionPart.java | 148 - .../CategoryPropertiesEditionPartForm.java | 266 - ...ocumentationPropertiesEditionPartForm.java | 257 - ...ementBindingPropertiesEditionPartForm.java | 591 -- ...rtiesBindingPropertiesEditionPartForm.java | 614 -- ...pertyBindingPropertiesEditionPartForm.java | 591 -- ...ingReferencePropertiesEditionPartForm.java | 287 - ...erPropertiesPropertiesEditionPartForm.java | 335 - ...ementBindingPropertiesEditionPartForm.java | 591 -- ...pertyBindingPropertiesEditionPartForm.java | 591 -- .../CategoryPropertiesEditionPartImpl.java | 235 - ...ocumentationPropertiesEditionPartImpl.java | 221 - ...ementBindingPropertiesEditionPartImpl.java | 549 -- ...rtiesBindingPropertiesEditionPartImpl.java | 577 -- ...pertyBindingPropertiesEditionPartImpl.java | 549 -- ...ingReferencePropertiesEditionPartImpl.java | 269 - ...erPropertiesPropertiesEditionPartImpl.java | 305 - ...ementBindingPropertiesEditionPartImpl.java | 549 -- ...pertyBindingPropertiesEditionPartImpl.java | 549 -- .../AbstractElementBindingItemProvider.java | 234 - .../AbstractPropertyBindingItemProvider.java | 281 - .../provider/CategoryItemProvider.java | 192 - .../provider/DatabindingItemProvider.java | 168 - .../DocumentedElementItemProvider.java | 154 - .../EMFElementBindingItemProvider.java | 131 - ...EMFMultiPropertiesBindingItemProvider.java | 199 - .../EMFPropertyBindingItemProvider.java | 279 - .../ElementBindingReferenceItemProvider.java | 133 - .../mapping/provider/MappingEditPlugin.java | 102 - .../MappingItemProviderAdapterFactory.java | 436 - .../provider/ModelElementItemProvider.java | 162 - .../provider/ModelPropertyItemProvider.java | 118 - .../StandardElementBindingItemProvider.java | 133 - .../StandardPropertyBindingItemProvider.java | 133 - .../CategoryPropertiesEditionProvider.java | 157 - ...entedElementPropertiesEditionProvider.java | 150 - ...ementBindingPropertiesEditionProvider.java | 157 - ...rtiesBindingPropertiesEditionProvider.java | 157 - ...pertyBindingPropertiesEditionProvider.java | 157 - ...ingReferencePropertiesEditionProvider.java | 157 - ...erPropertiesPropertiesEditionProvider.java | 150 - .../providers/MappingEEFAdapterFactory.java | 107 - .../mapping/providers/MappingMessages.java | 243 - .../MappingPropertiesEditionPartProvider.java | 119 - ...ementBindingPropertiesEditionProvider.java | 157 - ...pertyBindingPropertiesEditionProvider.java | 157 - .../providers/mappingMessages.properties | 84 - .../providers/mappingMessages_fr.properties | 84 - .../parts/SettingsPropertiesEditionPart.java | 93 - .../parts/SettingsViewsRepository.java | 34 - .../SettingsPropertiesEditionPartForm.java | 277 - .../SettingsPropertiesEditionPartImpl.java | 262 - .../EReferenceViewerSettingsItemProvider.java | 184 - .../provider/EditorSettingsItemProvider.java | 109 - .../SettingsItemProviderAdapterFactory.java | 209 - .../settings/providers/SettingsMessages.java | 96 - ...SettingsPropertiesEditionPartProvider.java | 55 - .../providers/settingsMessages.properties | 35 - .../providers/settingsMessages_fr.properties | 35 - ...igationStepPropertiesEditionComponent.java | 319 - ...InitializerPropertiesEditionComponent.java | 196 - ...InitializerPropertiesEditionComponent.java | 245 - ...lNavigationPropertiesEditionComponent.java | 303 - ...vigationStepPropertiesEditionProvider.java | 150 - ...pInitializerPropertiesEditionProvider.java | 150 - ...pInitializerPropertiesEditionProvider.java | 150 - .../NavigationEEFAdapterFactory.java | 56 - ...elNavigationPropertiesEditionProvider.java | 150 - ...werSettingsPropertiesEditionComponent.java | 237 - ...ewerSettingsPropertiesEditionProvider.java | 150 - .../providers/SettingsEEFAdapterFactory.java | 32 - .../src-gen/settings_properties.plugin.xml | 79 - ...onStepCustomPropertiesEditionPartForm.java | 85 - ...gationCustomPropertiesEditionPartForm.java | 85 - ...onStepCustomPropertiesEditionPartImpl.java | 85 - ...gationCustomPropertiesEditionPartImpl.java | 85 - ...ngCustomPropertiesEditionPartProvider.java | 45 - .../org.eclipse.emf.eef.mapping/.checkstyle | 10 - .../org.eclipse.emf.eef.mapping/.classpath | 7 - .../org.eclipse.emf.eef.mapping/.gitignore | 2 - plugins/org.eclipse.emf.eef.mapping/.project | 28 - .../org.eclipse.core.resources.prefs | 3 - .../.settings/org.eclipse.jdt.ui.prefs | 4 - .../META-INF/MANIFEST.MF | 24 - .../org.eclipse.emf.eef.mapping/about.html | 28 - .../build.properties | 20 - .../model/mapping.ecore | 194 - .../model/mapping.ecorediag | 815 -- .../model/mapping.genmodel | 192 - .../plugin.properties | 8 - .../org.eclipse.emf.eef.mapping/plugin.xml | 34 - plugins/org.eclipse.emf.eef.mapping/pom.xml | 27 - .../eef/mapping/AbstractElementBinding.java | 237 - .../eef/mapping/AbstractPropertyBinding.java | 124 - .../org/eclipse/emf/eef/mapping/Category.java | 124 - .../eclipse/emf/eef/mapping/Databinding.java | 70 - .../emf/eef/mapping/DocumentedElement.java | 58 - .../emf/eef/mapping/EMFElementBinding.java | 58 - .../mapping/EMFMultiPropertiesBinding.java | 77 - .../emf/eef/mapping/EMFPropertyBinding.java | 114 - .../eef/mapping/ElementBindingReference.java | 58 - .../emf/eef/mapping/MappingFactory.java | 114 - .../emf/eef/mapping/MappingPackage.java | 1989 ----- .../eclipse/emf/eef/mapping/ModelElement.java | 128 - .../emf/eef/mapping/ModelProperty.java | 89 - .../eef/mapping/StandardElementBinding.java | 58 - .../eef/mapping/StandardPropertyBinding.java | 58 - .../eef/mapping/filters/BindingFilter.java | 86 - .../eef/mapping/filters/BusinessFilter.java | 24 - .../eef/mapping/filters/FiltersFactory.java | 105 - .../eef/mapping/filters/FiltersPackage.java | 998 --- .../mapping/filters/JavaBodyStepFilter.java | 22 - .../filters/JavaDeclarationFilter.java | 56 - .../filters/JavaDeclarationStepFilter.java | 23 - .../mapping/filters/JavaExpressionFilter.java | 56 - .../emf/eef/mapping/filters/JavaFilter.java | 24 - .../eef/mapping/filters/JavaStepFilter.java | 22 - .../emf/eef/mapping/filters/OCLFilter.java | 56 - .../filters/OnlyReferenceTypeFilter.java | 58 - .../emf/eef/mapping/filters/StepFilter.java | 22 - .../mapping/filters/StrictTypingFilter.java | 58 - .../filters/impl/BindingFilterImpl.java | 228 - .../filters/impl/BusinessFilterImpl.java | 47 - .../filters/impl/FiltersFactoryImpl.java | 181 - .../filters/impl/FiltersPackageImpl.java | 592 -- .../filters/impl/JavaBodyStepFilterImpl.java | 46 - .../impl/JavaDeclarationFilterImpl.java | 172 - .../impl/JavaDeclarationStepFilterImpl.java | 46 - .../impl/JavaExpressionFilterImpl.java | 172 - .../mapping/filters/impl/JavaFilterImpl.java | 47 - .../mapping/filters/impl/OCLFilterImpl.java | 170 - .../impl/OnlyReferenceTypeFilterImpl.java | 169 - .../mapping/filters/impl/StepFilterImpl.java | 45 - .../filters/impl/StrictTypingFilterImpl.java | 169 - .../filters/util/FiltersAdapterFactory.java | 405 - .../mapping/filters/util/FiltersSwitch.java | 484 -- .../impl/AbstractElementBindingImpl.java | 645 -- .../impl/AbstractPropertyBindingImpl.java | 372 - .../emf/eef/mapping/impl/CategoryImpl.java | 376 - .../emf/eef/mapping/impl/DatabindingImpl.java | 223 - .../mapping/impl/DocumentedElementImpl.java | 173 - .../mapping/impl/EMFElementBindingImpl.java | 166 - .../impl/EMFMultiPropertiesBindingImpl.java | 244 - .../mapping/impl/EMFPropertyBindingImpl.java | 352 - .../impl/ElementBindingReferenceImpl.java | 168 - .../eef/mapping/impl/MappingFactoryImpl.java | 196 - .../eef/mapping/impl/MappingPackageImpl.java | 1100 --- .../eef/mapping/impl/ModelElementImpl.java | 416 - .../eef/mapping/impl/ModelPropertyImpl.java | 321 - .../impl/StandardElementBindingImpl.java | 235 - .../impl/StandardPropertyBindingImpl.java | 235 - .../navigation/ChainedModelNavigation.java | 97 - .../navigation/CustomModelNavigation.java | 24 - .../navigation/DeclarativeNavigationStep.java | 109 - .../navigation/JavaBodyExpression.java | 54 - .../navigation/JavaBodyStepInitializer.java | 21 - .../navigation/JavaDeclarationExpression.java | 108 - .../JavaDeclarationStepInitializer.java | 21 - .../navigation/JavaStepInitializer.java | 22 - .../mapping/navigation/ModelNavigation.java | 26 - .../mapping/navigation/NavigationFactory.java | 114 - .../mapping/navigation/NavigationPackage.java | 1169 --- .../mapping/navigation/NavigationStep.java | 120 - .../navigation/SimpleModelNavigation.java | 126 - .../navigation/SmartModelNavigation.java | 52 - .../mapping/navigation/StepInitializer.java | 22 - .../navigation/StructuredModelNavigation.java | 34 - .../impl/ChainedModelNavigationImpl.java | 343 - .../impl/CustomModelNavigationImpl.java | 47 - .../impl/DeclarativeNavigationStepImpl.java | 376 - .../impl/JavaBodyExpressionImpl.java | 171 - .../impl/JavaBodyStepInitializerImpl.java | 44 - .../impl/JavaDeclarationExpressionImpl.java | 289 - .../JavaDeclarationStepInitializerImpl.java | 44 - .../navigation/impl/ModelNavigationImpl.java | 48 - .../impl/NavigationFactoryImpl.java | 192 - .../impl/NavigationPackageImpl.java | 809 -- .../navigation/impl/NavigationStepImpl.java | 330 - .../impl/SimpleModelNavigationImpl.java | 377 - .../impl/SmartModelNavigationImpl.java | 200 - .../navigation/impl/StepInitializerImpl.java | 46 - .../impl/StructuredModelNavigationImpl.java | 54 - .../util/NavigationAdapterFactory.java | 382 - .../navigation/util/NavigationSwitch.java | 455 - .../settings/EReferenceViewerSettings.java | 83 - .../eef/mapping/settings/EditorSettings.java | 22 - .../eef/mapping/settings/SettingsFactory.java | 47 - .../eef/mapping/settings/SettingsPackage.java | 223 - .../impl/EReferenceViewerSettingsImpl.java | 267 - .../settings/impl/EditorSettingsImpl.java | 46 - .../settings/impl/SettingsFactoryImpl.java | 102 - .../settings/impl/SettingsPackageImpl.java | 278 - .../settings/util/SettingsAdapterFactory.java | 143 - .../mapping/settings/util/SettingsSwitch.java | 153 - .../mapping/util/MappingAdapterFactory.java | 370 - .../emf/eef/mapping/util/MappingSwitch.java | 444 - .../.classpath | 8 - .../.gitignore | 2 - .../.project | 28 - .../.settings/org.eclipse.jdt.core.prefs | 8 - .../META-INF/MANIFEST.MF | 32 - .../build.properties | 19 - .../icons/full/obj16/Add.gif | Bin 318 -> 0 bytes .../icons/full/obj16/Cancel.gif | Bin 219 -> 0 bytes .../icons/full/obj16/Check.gif | Bin 343 -> 0 bytes .../icons/full/obj16/CloseEditor.gif | Bin 360 -> 0 bytes .../icons/full/obj16/CloseProject.gif | Bin 353 -> 0 bytes .../icons/full/obj16/CreateModel.gif | Bin 595 -> 0 bytes .../icons/full/obj16/CreateProject.gif | Bin 348 -> 0 bytes .../icons/full/obj16/DetailsPage.gif | Bin 914 -> 0 bytes .../icons/full/obj16/EEFActionsModelFile.gif | Bin 346 -> 0 bytes .../icons/full/obj16/ModelingBot.gif | Bin 934 -> 0 bytes .../icons/full/obj16/MoveDown.gif | Bin 332 -> 0 bytes .../icons/full/obj16/MoveUp.gif | Bin 323 -> 0 bytes .../icons/full/obj16/OpenEEFEditor.gif | Bin 1045 -> 0 bytes .../icons/full/obj16/OpenEditor.gif | Bin 129 -> 0 bytes .../icons/full/obj16/OpenPerspective.gif | Bin 129 -> 0 bytes .../icons/full/obj16/OpenProject.gif | Bin 213 -> 0 bytes .../icons/full/obj16/PropertiesView.gif | Bin 581 -> 0 bytes .../icons/full/obj16/Redo.gif | Bin 353 -> 0 bytes .../icons/full/obj16/Remove.gif | Bin 350 -> 0 bytes .../icons/full/obj16/RemoveProject.gif | Bin 358 -> 0 bytes .../icons/full/obj16/Save.gif | Bin 639 -> 0 bytes .../icons/full/obj16/Scenario.gif | Bin 323 -> 0 bytes .../icons/full/obj16/Set.gif | Bin 129 -> 0 bytes .../icons/full/obj16/SetAttribute.gif | Bin 574 -> 0 bytes .../icons/full/obj16/SetReference.gif | Bin 185 -> 0 bytes .../icons/full/obj16/Undo.gif | Bin 355 -> 0 bytes .../icons/full/obj16/Unset.gif | Bin 120 -> 0 bytes .../icons/full/obj16/UnsetAttribute.gif | Bin 92 -> 0 bytes .../icons/full/obj16/UnsetReference.gif | Bin 92 -> 0 bytes .../icons/full/obj16/Wizard.gif | Bin 167 -> 0 bytes .../icons/full/wizban/NewModelingBot.gif | Bin 2462 -> 0 bytes .../plugin.properties | 135 - .../plugin.xml | 102 - .../pom.xml | 28 - .../EEFActions/provider/AddItemProvider.java | 166 - .../provider/CancelItemProvider.java | 143 - .../provider/CheckItemProvider.java | 118 - .../provider/EEFActionItemProvider.java | 123 - .../EEFActionsItemProviderAdapterFactory.java | 471 - .../provider/EditActionItemProvider.java | 155 - .../provider/MoveDownItemProvider.java | 114 - .../provider/MoveUpItemProvider.java | 114 - .../provider/OpenEEFEditorItemProvider.java | 151 - .../provider/RemoveItemProvider.java | 118 - .../provider/SetAttributeItemProvider.java | 174 - .../provider/SetReferenceItemProvider.java | 166 - .../provider/UnsetAttributeItemProvider.java | 170 - .../provider/UnsetItemProvider.java | 143 - .../provider/UnsetReferenceItemProvider.java | 162 - .../provider/CloseEditorItemProvider.java | 151 - .../provider/CloseProjectItemProvider.java | 151 - .../provider/CreateModelItemProvider.java | 198 - .../provider/CreateProjectItemProvider.java | 151 - .../provider/EclipseActionItemProvider.java | 123 - ...ipseActionsItemProviderAdapterFactory.java | 447 - .../provider/OpenEditorItemProvider.java | 170 - .../provider/OpenPerspectiveItemProvider.java | 151 - .../provider/OpenProjectItemProvider.java | 151 - .../provider/RedoItemProvider.java | 118 - .../provider/RemoveProjectItemProvider.java | 151 - .../provider/SaveItemProvider.java | 118 - .../provider/UndoItemProvider.java | 118 - .../provider/ActionItemProvider.java | 107 - .../provider/DetailsPageItemProvider.java | 118 - .../DocumentedElementItemProvider.java | 178 - .../modelingBot/provider/MbotEditPlugin.java | 114 - .../provider/ModelingBotItemProvider.java | 237 - ...ModelingBotItemProviderAdapterFactory.java | 303 - .../provider/PropertiesViewItemProvider.java | 151 - .../provider/ScenarioItemProvider.java | 118 - .../provider/SequenceItemProvider.java | 311 - .../provider/WizardItemProvider.java | 143 - .../edit/commands/OpenWithEEFHandler.java | 56 - .../edit/wizards/ModelCreationWizard.java | 778 -- .../.classpath | 7 - .../.gitignore | 2 - .../.project | 28 - .../META-INF/MANIFEST.MF | 26 - .../build.properties | 24 - .../icons/full/obj16/EEFActionsModelFile.gif | Bin 346 -> 0 bytes .../full/obj16/EclipseActionsModelFile.gif | Bin 346 -> 0 bytes .../icons/full/obj16/ModelingBotModelFile.gif | Bin 592 -> 0 bytes .../icons/full/wizban/NewEEFActions.gif | Bin 2462 -> 0 bytes .../icons/full/wizban/NewEclipseActions.gif | Bin 2462 -> 0 bytes .../icons/full/wizban/NewModelingBot.gif | Bin 592 -> 0 bytes .../plugin.properties | 80 - .../plugin.xml | 91 - .../pom.xml | 28 - .../EEFActionsActionBarContributor.java | 433 - .../presentation/EEFActionsEditor.java | 1858 ---- .../presentation/EEFActionsModelWizard.java | 637 -- .../EclipseActionsActionBarContributor.java | 433 - .../presentation/EclipseActionsEditor.java | 1858 ---- .../EclipseActionsModelWizard.java | 637 -- .../presentation/MbotEditorPlugin.java | 117 - .../ModelingBotActionBarContributor.java | 431 - .../presentation/ModelingBotEditor.java | 1856 ---- .../presentation/ModelingBotModelWizard.java | 635 -- .../.classpath | 8 - .../.gitignore | 2 - .../org.eclipse.emf.eef.modelingbot/.project | 28 - .../org.eclipse.core.resources.prefs | 3 - .../.settings/org.eclipse.jdt.core.prefs | 8 - .../META-INF/MANIFEST.MF | 89 - .../build.properties | 29 - .../model/mbot.ecore | 120 - .../model/mbot.genmodel | 132 - .../modelingBot package entities.jpg | Bin 119351 -> 0 bytes .../plugin.properties | 18 - .../plugin.xml | 34 - .../org.eclipse.emf.eef.modelingbot/pom.xml | 28 - .../representations.aird | 7574 ----------------- .../eclipse/emf/eef/modelingBot/Action.java | 25 - .../emf/eef/modelingBot/DetailsPage.java | 25 - .../eef/modelingBot/DocumentedElement.java | 85 - .../emf/eef/modelingBot/EEFActions/Add.java | 87 - .../eef/modelingBot/EEFActions/Cancel.java | 60 - .../emf/eef/modelingBot/EEFActions/Check.java | 25 - .../eef/modelingBot/EEFActions/EEFAction.java | 26 - .../EEFActions/EEFActionsFactory.java | 149 - .../EEFActions/EEFActionsPackage.java | 1475 ---- .../modelingBot/EEFActions/EditAction.java | 87 - .../eef/modelingBot/EEFActions/MoveDown.java | 21 - .../eef/modelingBot/EEFActions/MoveUp.java | 21 - .../modelingBot/EEFActions/OpenEEFEditor.java | 57 - .../eef/modelingBot/EEFActions/Remove.java | 25 - .../modelingBot/EEFActions/SetAttribute.java | 77 - .../modelingBot/EEFActions/SetReference.java | 77 - .../emf/eef/modelingBot/EEFActions/Unset.java | 59 - .../EEFActions/UnsetAttribute.java | 73 - .../EEFActions/UnsetReference.java | 74 - .../modelingBot/EEFActions/impl/AddImpl.java | 222 - .../EEFActions/impl/CancelImpl.java | 162 - .../EEFActions/impl/CheckImpl.java | 47 - .../EEFActions/impl/EEFActionImpl.java | 49 - .../impl/EEFActionsFactoryImpl.java | 224 - .../impl/EEFActionsPackageImpl.java | 649 -- .../EEFActions/impl/EditActionImpl.java | 227 - .../EEFActions/impl/MoveDownImpl.java | 43 - .../EEFActions/impl/MoveUpImpl.java | 43 - .../EEFActions/impl/OpenEEFEditorImpl.java | 170 - .../EEFActions/impl/RemoveImpl.java | 47 - .../EEFActions/impl/SetAttributeImpl.java | 218 - .../EEFActions/impl/SetReferenceImpl.java | 204 - .../EEFActions/impl/UnsetAttributeImpl.java | 217 - .../EEFActions/impl/UnsetImpl.java | 162 - .../EEFActions/impl/UnsetReferenceImpl.java | 200 - .../util/EEFActionsAdapterFactory.java | 439 - .../EEFActions/util/EEFActionsSwitch.java | 546 -- .../EclipseActions/CloseEditor.java | 57 - .../EclipseActions/CloseProject.java | 57 - .../EclipseActions/CreateModel.java | 114 - .../EclipseActions/CreateProject.java | 57 - .../EclipseActions/EclipseAction.java | 26 - .../EclipseActions/EclipseActionsFactory.java | 140 - .../EclipseActions/EclipseActionsPackage.java | 1086 --- .../EclipseActions/OpenEditor.java | 82 - .../EclipseActions/OpenPerspective.java | 57 - .../EclipseActions/OpenProject.java | 57 - .../eef/modelingBot/EclipseActions/Redo.java | 25 - .../EclipseActions/RemoveProject.java | 57 - .../eef/modelingBot/EclipseActions/Save.java | 25 - .../eef/modelingBot/EclipseActions/Undo.java | 25 - .../EclipseActions/impl/CloseEditorImpl.java | 167 - .../EclipseActions/impl/CloseProjectImpl.java | 170 - .../EclipseActions/impl/CreateModelImpl.java | 285 - .../impl/CreateProjectImpl.java | 170 - .../impl/EclipseActionImpl.java | 49 - .../impl/EclipseActionsFactoryImpl.java | 213 - .../impl/EclipseActionsPackageImpl.java | 567 -- .../EclipseActions/impl/OpenEditorImpl.java | 227 - .../impl/OpenPerspectiveImpl.java | 170 - .../EclipseActions/impl/OpenProjectImpl.java | 170 - .../EclipseActions/impl/RedoImpl.java | 47 - .../impl/RemoveProjectImpl.java | 170 - .../EclipseActions/impl/SaveImpl.java | 47 - .../EclipseActions/impl/UndoImpl.java | 47 - .../util/EclipseActionsAdapterFactory.java | 403 - .../util/EclipseActionsSwitch.java | 478 -- .../emf/eef/modelingBot/ModelingBot.java | 79 - .../eef/modelingBot/ModelingBotFactory.java | 86 - .../eef/modelingBot/ModelingBotPackage.java | 944 -- .../emf/eef/modelingBot/Processing.java | 26 - .../emf/eef/modelingBot/PropertiesView.java | 57 - .../eclipse/emf/eef/modelingBot/Scenario.java | 25 - .../eclipse/emf/eef/modelingBot/Sequence.java | 82 - .../emf/eef/modelingBot/SequenceType.java | 243 - .../eclipse/emf/eef/modelingBot/Wizard.java | 59 - .../emf/eef/modelingBot/impl/ActionImpl.java | 47 - .../eef/modelingBot/impl/DetailsPageImpl.java | 47 - .../impl/DocumentedElementImpl.java | 225 - .../impl/ModelingBotFactoryImpl.java | 198 - .../eef/modelingBot/impl/ModelingBotImpl.java | 224 - .../impl/ModelingBotPackageImpl.java | 516 -- .../modelingBot/impl/PropertiesViewImpl.java | 170 - .../eef/modelingBot/impl/ScenarioImpl.java | 47 - .../eef/modelingBot/impl/SequenceImpl.java | 231 - .../emf/eef/modelingBot/impl/WizardImpl.java | 162 - .../util/ModelingBotAdapterFactory.java | 272 - .../modelingBot/util/ModelingBotSwitch.java | 318 - .../emf/eef/modelingBot/IModelingBot.java | 254 - .../modelingBot/batch/BatchModelingBot.java | 557 -- .../exception/InputModelInvalidException.java | 60 - .../exception/WidgetInvalidException.java | 60 - .../modelingBot/helper/EEFModelHelper.java | 96 - .../helper/EEFModelingBotHelper.java | 93 - .../emf/eef/modelingBot/helper/EMFHelper.java | 148 - .../helper/PropertiesEditionHelper.java | 671 -- .../eef/modelingBot/helper/SWTBotHelper.java | 278 - .../modelingBot/helper/SWTEEFBotHelper.java | 178 - .../eef/modelingBot/helper/StringHelper.java | 45 - .../eef/modelingBot/helper/UIConstants.java | 74 - .../interpreter/ComposedEEFInterpreter.java | 223 - .../interpreter/EEFInterpreter.java | 404 - .../interpreter/IModelingBotInterpreter.java | 73 - .../menu/FirstContextMenuFinder.java | 119 - .../modelingBot/menu/SWTBotContextMenu.java | 93 - .../modelingBot/swtbot/ComposedEEFBot.java | 392 - .../emf/eef/modelingBot/swtbot/SWTEEFBot.java | 1456 ---- .../AbstractBatchModelingBotTestCase.java | 51 - .../AbstractComposedModelingBotTestCase.java | 132 - .../AbstractSWTBotModelingBotTestCase.java | 79 - .../ui/utils/WrappedSWTBotRadio.java | 73 - .../eef/modelingBot/uri/EEFURIConverter.java | 65 - .../.checkstyle | 10 - .../.classpath | 7 - .../.gitignore | 2 - .../.project | 28 - .../.settings/org.eclipse.jdt.core.prefs | 8 - .../META-INF/MANIFEST.MF | 37 - .../about.html | 28 - .../build.properties | 19 - .../icons/full/obj16/InteractiveEditor.gif | Bin 1045 -> 0 bytes .../icons/full/obj16/OpenEEFEditor.gif | Bin 1045 -> 0 bytes .../plugin.properties | 63 - .../plugin.xml | 24 - .../pom.xml | 28 - .../emf/eef/runtime/query/EEFQuery.java | 62 - .../emf/eef/runtime/query/QueryProcessor.java | 34 - .../emf/eef/runtime/query/QueryResult.java | 35 - .../emf/eef/runtime/query/QueryWrapper.java | 20 - .../query/compound/CompoundProcessor.java | 88 - .../explicitpath/ExplicitPathProcessor.java | 49 - .../query/explicitpath/ExplicitPathQuery.java | 46 - .../exception/EvaluationException.java | 62 - .../path/AttributeModelNavigation.java | 77 - .../path/ChainedModelNavigation.java | 75 - .../explicitpath/path/ModelNavigation.java | 23 - .../path/ReferenceModelNavigation.java | 115 - .../eef/runtime/query/ocl/OCLProcessor.java | 85 - .../emf/eef/runtime/query/ocl/OCLQuery.java | 54 - .../eef/runtime/ui/EEFExtendedRuntime.java | 119 - .../ui/editor/InteractiveEEFEditor.java | 1344 --- ...eractiveEEFEditorActionBarContributor.java | 366 - .../ui/editor/messages/MessageHandler.java | 42 - .../ui/editor/messages/MessageProcessor.java | 110 - .../editors/pages/AbstractEEFEditorPage.java | 271 - .../editors/pages/AbstractEEFMDFormPage.java | 185 - .../ui/editors/pages/EEFDetailsPage.java | 166 - .../ui/editors/pages/EEFEditorPage.java | 58 - .../ui/editors/pages/EEFStandardFormPage.java | 136 - .../EEFPropertiesViewerMDFormPage.java | 102 - .../editors/pages/tree/EEFTreeMDFormPage.java | 80 - .../ui/layout/EEFFormLayoutFactory.java | 177 - .../emf/eef/runtime/ui/views/EEFView.java | 235 - .../AbstractEEFMasterDetailsBlock.java | 255 - .../masterdetails/AbstractEEFMasterPart.java | 165 - .../PropertiesViewerMasterDetailsBlock.java | 49 - .../eefviewer/PropertiesViewerMasterPart.java | 66 - .../tree/EEFTreeMasterDetailsBlock.java | 69 - .../masterdetails/tree/EEFTreeMasterPart.java | 315 - .../.checkstyle | 10 - .../.classpath | 7 - .../.gitignore | 2 - .../.project | 28 - .../META-INF/MANIFEST.MF | 28 - .../about.html | 28 - .../build.properties | 17 - .../icons/full/obj16/EEFReflectiveEditor.gif | Bin 364 -> 0 bytes .../icons/sample.gif | Bin 983 -> 0 bytes .../plugin.xml | 84 - .../org.eclipse.emf.eef.runtime.tests/pom.xml | 28 - .../eef/runtime/tests/SWTBotEEFTestCase.java | 244 - .../InputModelInvalidException.java | 60 - .../exceptions/WidgetInvalidException.java | 60 - .../tests/swtbot/finder/SWTEEFBot.java | 1233 --- .../tests/swtbot/finder/SWTEEFBotHelper.java | 141 - .../tests/swtbot/utils/ModelHelper.java | 71 - .../tests/swtbot/utils/SWTBotUtils.java | 212 - .../actions/OpenWithEEFReflectiveEditor.java | 92 - .../tests/ui/editors/EEFReflectiveEditor.java | 54 - .../section/EEFReflectiveEditionSection.java | 247 - .../tests/utils/EEFTestsModelsUtils.java | 93 - .../tests/utils/EEFTestsResourceUtils.java | 97 - .../eef/runtime/tests/utils/UIConstants.java | 56 - .../.classpath | 8 - .../.gitignore | 1 - .../.project | 28 - .../.settings/org.eclipse.jdt.core.prefs | 8 - .../META-INF/MANIFEST.MF | 10 - .../build.properties | 15 - .../icons/full/dlcl16/LocateValue.gif | Bin 149 -> 0 bytes .../icons/full/elcl16/LocateValue.gif | Bin 212 -> 0 bytes .../emf/eef/runtime/ui/gwt/EEFEditor.gwt.xml | 11 - .../runtime/ui/gwt/EEFEditorEntryPoint.java | 119 - .../ui/gwt/command/CreateObjectCommand.java | 74 - .../ui/gwt/command/CreateResourceCommand.java | 67 - .../runtime/ui/gwt/command/SaveCommand.java | 76 - .../command/UpdateURIConverterCommand.java | 77 - .../ui/gwt/dialog/CreateObjectDialog.java | 125 - .../ui/gwt/dialog/CreateResourceDialog.java | 123 - .../runtime/ui/gwt/dialog/ErrorDialog.java | 111 - .../eef/runtime/ui/gwt/editor/EEFEditor.java | 215 - .../ui/gwt/editor/part/EEFEditorToolbar.java | 152 - .../gwt/editor/part/EEFPropertiesPanel.java | 319 - .../ui/gwt/editor/property/FeatureEditor.java | 325 - .../ItemPropertyDescriptorFeatureEditor.java | 69 - .../editor/util/EditorToolbarListener.java | 471 - .../ui/gwt/editor/util/EventProcess.java | 51 - .../ui/gwt/editor/util/NavigationManager.java | 135 - .../ui/gwt/editor/widget/EEFTreeViewer.java | 50 - .../widget/EEFTreeViewerContentProvider.java | 191 - .../ui/gwt/editor/widget/ModelViewerCell.java | 120 - .../.checkstyle | 14 - .../.classpath | 7 - .../.gitignore | 1 - .../.project | 34 - .../.settings/org.eclipse.jdt.core.prefs | 7 - .../META-INF/MANIFEST.MF | 9 - .../build.properties | 14 - .../ui/widgets/EEFSelectionDialog.java | 218 - .../runtime/ui/widgets/EReferenceEditor.java | 553 -- .../util/ArrayFeatureContentProvider.java | 84 - .../ui/widgets/util/ChoiceOfValuesFilter.java | 85 - .../ui/widgets/util/EEFOverrideViewer.java | 55 - .../ui/widgets/util/SelectionMode.java | 20 - .../org.eclipse.emf.eef.runtime/.checkstyle | 10 - .../org.eclipse.emf.eef.runtime/.classpath | 7 - .../org.eclipse.emf.eef.runtime/.gitignore | 2 - plugins/org.eclipse.emf.eef.runtime/.project | 28 - .../.settings/org.eclipse.jdt.core.prefs | 12 - .../META-INF/MANIFEST.MF | 65 - .../org.eclipse.emf.eef.runtime/about.html | 28 - .../build.properties | 22 - .../icons/16x16/Add_16x16.gif | Bin 318 -> 0 bytes .../icons/16x16/ArrowDown_16x16.gif | Bin 332 -> 0 bytes .../icons/16x16/ArrowLeft_16x16.gif | Bin 327 -> 0 bytes .../icons/16x16/ArrowRight_16x16.gif | Bin 541 -> 0 bytes .../icons/16x16/ArrowUp_16x16.gif | Bin 323 -> 0 bytes .../icons/16x16/Create_16x16.gif | Bin 124 -> 0 bytes .../icons/16x16/Delete_16x16.gif | Bin 351 -> 0 bytes .../icons/16x16/Edit_Part.gif | Bin 347 -> 0 bytes .../icons/16x16/Switch_Visibility.gif | Bin 973 -> 0 bytes .../icons/16x16/ValidationErrors.gif | Bin 353 -> 0 bytes .../icons/16x16/ValidationWarnings.gif | Bin 326 -> 0 bytes .../icons/16x16/disabled/th_horizontal.gif | Bin 354 -> 0 bytes .../icons/16x16/disabled/th_vertical.gif | Bin 221 -> 0 bytes .../icons/16x16/th_horizontal.gif | Bin 374 -> 0 bytes .../icons/16x16/th_vertical.gif | Bin 352 -> 0 bytes .../icons/16x16/validate.gif | Bin 952 -> 0 bytes .../org.eclipse.emf.eef.runtime/plugin.xml | 34 - plugins/org.eclipse.emf.eef.runtime/pom.xml | 28 - .../schema/LockPolicyProvider.exsd | 102 - ...rtiesEditionComponentListenerProvider.exsd | 102 - .../schema/PropertiesEditionPartProvider.exsd | 102 - .../PropertiesEditionPolicyProvider.exsd | 102 - .../schema/PropertiesEditionProvider.exsd | 105 - .../schema/ReadOnlyPolicyProvider.exsd | 102 - .../schema/WizardOpeningPolicyProvider.exsd | 102 - .../emf/eef/runtime/EEFRuntimePlugin.java | 188 - .../runtime/api/adapters/SemanticAdapter.java | 28 - .../IPropertiesEditionComponent.java | 213 - .../eef/runtime/api/context/ContextEntry.java | 64 - .../notify/EClassifierNotificationFilter.java | 36 - .../EStructuralFeatureNotificationFilter.java | 37 - .../IPropertiesEditionComponentListener.java | 41 - .../api/notify/IPropertiesEditionEvent.java | 65 - .../notify/IPropertiesEditionListener.java | 26 - .../api/notify/NotificationFilter.java | 18 - .../PropertiesEditingSemanticListener.java | 90 - .../PropertiesEditingSemanticLister.java | 83 - .../api/notify/ResourceSetAdapter.java | 230 - .../api/parts/IFormPropertiesEditionPart.java | 38 - .../api/parts/IPropertiesEditionPart.java | 70 - .../api/parts/ISWTPropertiesEditionPart.java | 37 - .../IPropertiesEditionPartProvider.java | 44 - ...IPropertiesEditionPartProviderFactory.java | 45 - .../api/providers/IReadOnlyPolicy.java | 32 - .../ExtendedPropertiesEditingContext.java | 72 - .../context/PropertiesEditingContext.java | 73 - .../impl/DomainPropertiesEditionContext.java | 103 - .../impl/EObjectPropertiesEditionContext.java | 309 - .../EReferencePropertiesEditionContext.java | 89 - ...pedEReferencePropertiesEditingContext.java | 47 - .../impl/command/StandardEditingCommand.java | 63 - .../impl/command/WizardEditingCommand.java | 82 - .../ComposedPropertiesEditionComponent.java | 378 - .../SinglePartPropertiesEditingComponent.java | 257 - .../StandardPropertiesEditionComponent.java | 403 - .../runtime/impl/filters/EObjectFilter.java | 57 - .../impl/filters/EObjectStrictFilter.java | 44 - .../business/BusinessViewerFilter.java | 106 - .../business/CurrentModelViewerFilter.java | 61 - .../ReferencedModelsViewerFilter.java | 54 - .../impl/notify/EEFLockNotification.java | 26 - .../impl/notify/PropertiesEditionEvent.java | 187 - .../PropertiesValidationEditionEvent.java | 113 - .../operation/WizardEditingOperation.java | 60 - .../parts/CompositePropertiesEditionPart.java | 283 - .../NullCompositePropertiesEditionPart.java | 112 - .../ComposedPropertiesEditionProvider.java | 161 - ...dPropertiesEditionPartProviderFactory.java | 71 - .../services/LockPolicyProviderService.java | 117 - .../services/PropertiesContextService.java | 145 - ...itionComponentListenerProviderService.java | 117 - .../PropertiesEditionPartProviderService.java | 126 - .../ReadOnlyPolicyProviderService.java | 117 - .../WizardOpeningPolicyProviderService.java | 140 - .../impl/utils/EEFCommandParameter.java | 39 - .../runtime/impl/utils/EEFConverterUtil.java | 154 - .../impl/utils/EEFRuntimeMessages.java | 38 - .../emf/eef/runtime/impl/utils/EEFUtils.java | 441 - .../runtime/impl/utils/ModelViewerHelper.java | 80 - .../eef/runtime/impl/utils/PatternTool.java | 162 - .../eef/runtime/impl/utils/StringMatcher.java | 421 - .../eef/runtime/impl/utils/StringTools.java | 108 - .../runtime/impl/utils/ValidationUtils.java | 42 - .../impl/utils/eefRuntimeMessages.properties | 17 - .../EEFValidationClientSelector.java | 24 - .../runtime/impl/validation/EEFValidator.java | 95 - .../impl/SectionPropertiesEditingPart.java | 441 - .../impl/util/ValidationMessageInjector.java | 177 - .../emf/eef/runtime/policies/ILockPolicy.java | 36 - .../policies/PropertiesEditingPolicy.java | 23 - .../PropertiesEditingPolicyWithResult.java | 23 - .../policies/impl/CreateEditingPolicy.java | 86 - .../policies/impl/StandardEditingPolicy.java | 49 - .../providers/PropertiesEditingProvider.java | 128 - .../impl/PropertiesEditingProviderImpl.java | 110 - .../emf/eef/runtime/ui/UIConstants.java | 41 - .../ui/adapters/EEFBatchEditingUtil.java | 41 - .../ui/adapters/SimplestSemanticAdapter.java | 37 - .../comparator/EMFModelViewerComparator.java | 60 - .../ui/notify/DropDownSelectionListener.java | 60 - .../OpenTransactionalWizardOnDoubleClick.java | 89 - .../ui/notify/OpenWizardOnDoubleClick.java | 67 - .../eef/runtime/ui/parts/PartComposer.java | 91 - .../emf/eef/runtime/ui/parts/ViewHelper.java | 50 - .../ui/parts/impl/BindingViewHelper.java | 143 - .../runtime/ui/parts/impl/ViewHelperImpl.java | 50 - .../sequence/BindingCompositionSequence.java | 39 - .../sequence/BindingCompositionStep.java | 49 - .../parts/sequence/CompositionSequence.java | 34 - .../ui/parts/sequence/CompositionStep.java | 244 - .../sections/EEFAdvancedPropertySection.java | 66 - .../ui/providers/EMFListContentProvider.java | 93 - .../runtime/ui/utils/EEFLabelProvider.java | 67 - .../ui/utils/EEFRuntimeUIMessages.java | 128 - .../eef/runtime/ui/utils/EditingUtils.java | 113 - .../ui/utils/eefRuntimeUImessages.properties | 62 - .../PropertiesEditionContentProvider.java | 247 - .../PropertiesEditionMessageManager.java | 76 - .../ui/viewers/PropertiesEditionViewer.java | 643 -- .../filters/PropertiesEditionPartFilter.java | 48 - ...bstractAdvancedEObjectFlatComboViewer.java | 394 - .../AdvancedEObjectFlatComboViewer.java | 169 - .../runtime/ui/widgets/ButtonsModeEnum.java | 18 - .../ContainmentPropertiesEditingViewer.java | 649 -- .../ui/widgets/EEFFeatureEditorDialog.java | 485 -- .../runtime/ui/widgets/EMFComboViewer.java | 255 - .../ui/widgets/EMFModelViewerDialog.java | 437 - .../ui/widgets/EObjectFlatComboViewer.java | 251 - .../ui/widgets/ElementSelectionDialog.java | 400 - .../ui/widgets/FlatReferencesTable.java | 412 - .../emf/eef/runtime/ui/widgets/FormUtils.java | 83 - .../eef/runtime/ui/widgets/HorizontalBox.java | 48 - .../ui/widgets/IPropertiesFilteredWidget.java | 54 - .../widgets/LinkEObjectFlatComboViewer.java | 148 - .../ui/widgets/LinkEReferenceViewer.java | 130 - .../ui/widgets/ModelChooserDialog.java | 219 - .../eef/runtime/ui/widgets/RadioViewer.java | 220 - .../runtime/ui/widgets/ReferencesTable.java | 870 -- .../emf/eef/runtime/ui/widgets/SWTUtils.java | 383 - .../runtime/ui/widgets/SelectionDialog.java | 131 - .../ui/widgets/SingleCompositionEditor.java | 297 - .../ui/widgets/SingleCompositionViewer.java | 496 -- .../TabElementTreeSelectionDialog.java | 409 - .../eef/runtime/ui/widgets/VerticalBox.java | 48 - .../EObjectFlatComboSettings.java | 194 - .../widgets/imageviewer/EEFImageViewer.java | 180 - .../ReferencesTableContentProvider.java | 66 - .../ReferencesTableSettings.java | 643 -- .../AdvancedEEFEditorContentProvider.java | 137 - .../settings/EEFEditorContentProvider.java | 66 - .../widgets/settings/EEFEditorSettings.java | 65 - .../settings/EEFEditorSettingsBuilder.java | 317 - .../ui/widgets/settings/EEFFilter.java | 12 - .../ui/widgets/settings/EEFInitializer.java | 15 - .../ui/widgets/settings/NavigationStep.java | 55 - .../settings/NavigationStepBuilder.java | 142 - .../runtime/ui/wizards/EEFWizardDialog.java | 58 - .../ui/wizards/IWizardOpeningPolicy.java | 45 - .../ui/wizards/PropertiesEditionWizard.java | 521 -- .../ui/wizards/ResizableWizardDialog.java | 27 - .../impl/StandardWizardOpeningPolicy.java | 59 - .../.checkstyle | 10 - .../org.eclipse.emf.eef.views.edit/.classpath | 8 - .../org.eclipse.emf.eef.views.edit/.gitignore | 2 - .../org.eclipse.emf.eef.views.edit/.project | 28 - .../META-INF/MANIFEST.MF | 31 - .../org.eclipse.emf.eef.views.edit/about.html | 28 - .../build.properties | 23 - .../CreateCategory_categories_Category.gif | Bin 223 -> 0 bytes .../CreateCategory_views_CustomView.gif | Bin 223 -> 0 bytes .../ctool16/CreateCategory_views_View.gif | Bin 223 -> 0 bytes .../CreateContainer_elements_Container.gif | Bin 223 -> 0 bytes ...Container_elements_CustomElementEditor.gif | Bin 223 -> 0 bytes .../CreateContainer_elements_CustomView.gif | Bin 223 -> 0 bytes ...CreateContainer_elements_ElementEditor.gif | Bin 223 -> 0 bytes ...ntainer_elements_SpecificElementEditor.gif | Bin 223 -> 0 bytes .../ctool16/CreateContainer_elements_View.gif | Bin 223 -> 0 bytes ...CreateContainer_elements_ViewReference.gif | Bin 223 -> 0 bytes .../ctool16/CreateToolkit_widgets_Widget.gif | Bin 223 -> 0 bytes ...ateViewsRepository_categories_Category.gif | Bin 223 -> 0 bytes ...CreateViewsRepository_views_CustomView.gif | Bin 223 -> 0 bytes .../CreateViewsRepository_views_View.gif | Bin 223 -> 0 bytes .../icons/full/obj16/Category.gif | Bin 589 -> 0 bytes .../icons/full/obj16/Container.gif | Bin 398 -> 0 bytes .../icons/full/obj16/CustomElementEditor.gif | Bin 129 -> 0 bytes .../icons/full/obj16/CustomView.gif | Bin 374 -> 0 bytes .../icons/full/obj16/DocumentedElement.gif | Bin 129 -> 0 bytes .../icons/full/obj16/ElementEditor.gif | Bin 219 -> 0 bytes .../icons/full/obj16/Toolkit.gif | Bin 358 -> 0 bytes .../icons/full/obj16/View.gif | Bin 345 -> 0 bytes .../icons/full/obj16/ViewReference.gif | Bin 601 -> 0 bytes .../icons/full/obj16/ViewsRepository.gif | Bin 359 -> 0 bytes .../icons/full/obj16/Widget.gif | Bin 152 -> 0 bytes .../model/toolkits.components | 43 - .../model/views.components | 205 - .../model/views.eefgen | 15 - .../plugin.properties | 93 - .../org.eclipse.emf.eef.views.edit/plugin.xml | 293 - .../org.eclipse.emf.eef.views.edit/pom.xml | 27 - .../ToolkitPropertiesEditionComponent.java | 199 - .../WidgetPropertiesEditionComponent.java | 199 - .../parts/ToolkitPropertiesEditionPart.java | 55 - .../parts/ToolkitsViewsRepository.java | 55 - .../parts/WidgetPropertiesEditionPart.java | 55 - .../ToolkitPropertiesEditionPartForm.java | 267 - .../WidgetPropertiesEditionPartForm.java | 267 - .../ToolkitPropertiesEditionPartImpl.java | 235 - .../impl/WidgetPropertiesEditionPartImpl.java | 235 - .../provider/ToolkitItemProvider.java | 195 - .../ToolkitsItemProviderAdapterFactory.java | 281 - .../toolkits/provider/WidgetItemProvider.java | 192 - .../ToolkitPropertiesEditionProvider.java | 150 - .../providers/ToolkitsEEFAdapterFactory.java | 40 - .../toolkits/providers/ToolkitsMessages.java | 111 - ...ToolkitsPropertiesEditionPartProvider.java | 63 - .../WidgetPropertiesEditionProvider.java | 150 - .../providers/toolkitsMessages.properties | 40 - .../providers/toolkitsMessages_fr.properties | 40 - ...ategoryBasePropertiesEditionComponent.java | 199 - .../CategoryPropertiesEditionComponent.java | 116 - ...ntainerBasePropertiesEditionComponent.java | 263 - .../ContainerPropertiesEditionComponent.java | 116 - ...tEditorBasePropertiesEditionComponent.java | 223 - ...ementEditorPropertiesEditionComponent.java | 116 - ...tomViewBasePropertiesEditionComponent.java | 199 - .../CustomViewPropertiesEditionComponent.java | 116 - ...ntedElementPropertiesEditionComponent.java | 188 - ...tEditorBasePropertiesEditionComponent.java | 309 - ...ementEditorPropertiesEditionComponent.java | 116 - .../ViewBasePropertiesEditionComponent.java | 291 - .../ViewPropertiesEditionComponent.java | 116 - ...ferenceBasePropertiesEditionComponent.java | 261 - ...ewReferencePropertiesEditionComponent.java | 116 - ...ositoryBasePropertiesEditionComponent.java | 222 - ...sRepositoryPropertiesEditionComponent.java | 116 - .../parts/CategoryPropertiesEditionPart.java | 55 - .../parts/ContainerPropertiesEditionPart.java | 105 - ...tomElementEditorPropertiesEditionPart.java | 68 - .../CustomViewPropertiesEditionPart.java | 55 - .../DocumentationPropertiesEditionPart.java | 55 - .../ElementEditorPropertiesEditionPart.java | 133 - .../parts/ViewPropertiesEditionPart.java | 119 - .../ViewReferencePropertiesEditionPart.java | 105 - .../ViewsRepositoryPropertiesEditionPart.java | 69 - .../eef/views/parts/ViewsViewsRepository.java | 187 - .../CategoryPropertiesEditionPartForm.java | 267 - .../ContainerPropertiesEditionPartForm.java | 400 - ...lementEditorPropertiesEditionPartForm.java | 335 - .../CustomViewPropertiesEditionPartForm.java | 267 - ...ocumentationPropertiesEditionPartForm.java | 258 - ...lementEditorPropertiesEditionPartForm.java | 535 -- .../forms/ViewPropertiesEditionPartForm.java | 508 -- ...iewReferencePropertiesEditionPartForm.java | 400 - ...wsRepositoryPropertiesEditionPartForm.java | 372 - .../CategoryPropertiesEditionPartImpl.java | 235 - .../ContainerPropertiesEditionPartImpl.java | 361 - ...lementEditorPropertiesEditionPartImpl.java | 305 - .../CustomViewPropertiesEditionPartImpl.java | 235 - ...ocumentationPropertiesEditionPartImpl.java | 221 - ...lementEditorPropertiesEditionPartImpl.java | 498 -- .../impl/ViewPropertiesEditionPartImpl.java | 450 - ...iewReferencePropertiesEditionPartImpl.java | 361 - ...wsRepositoryPropertiesEditionPartImpl.java | 321 - .../views/provider/CategoryItemProvider.java | 191 - .../views/provider/ContainerItemProvider.java | 181 - .../CustomElementEditorItemProvider.java | 111 - .../provider/CustomViewItemProvider.java | 111 - .../DocumentedElementItemProvider.java | 155 - .../provider/ElementEditorItemProvider.java | 163 - .../IdentifiedElementItemProvider.java | 122 - .../provider/ViewElementItemProvider.java | 146 - .../eef/views/provider/ViewItemProvider.java | 161 - .../provider/ViewReferenceItemProvider.java | 139 - .../eef/views/provider/ViewsEditPlugin.java | 94 - .../ViewsItemProviderAdapterFactory.java | 431 - .../provider/ViewsRepositoryItemProvider.java | 213 - .../CategoryPropertiesEditionProvider.java | 157 - .../ContainerPropertiesEditionProvider.java | 157 - ...lementEditorPropertiesEditionProvider.java | 157 - .../CustomViewPropertiesEditionProvider.java | 157 - ...entedElementPropertiesEditionProvider.java | 150 - ...lementEditorPropertiesEditionProvider.java | 157 - .../providers/ToolkitsEEFAdapterFactory.java | 42 - .../ViewPropertiesEditionProvider.java | 157 - ...iewReferencePropertiesEditionProvider.java | 157 - .../providers/ViewsEEFAdapterFactory.java | 117 - .../eef/views/providers/ViewsMessages.java | 222 - .../ViewsPropertiesEditionPartProvider.java | 119 - ...wsRepositoryPropertiesEditionProvider.java | 157 - .../views/providers/viewsMessages.properties | 77 - .../providers/viewsMessages_fr.properties | 77 - .../src-gen/toolkits_properties.plugin.xml | 73 - .../src-gen/views_properties.plugin.xml | 163 - .../eef/views/resources/ViewsResource.java | 59 - .../views/resources/ViewsResourceFactory.java | 27 - ...tainerWithoutRepresensationConstraint.java | 50 - .../NonReferenceViewsConstraint.java | 59 - .../.checkstyle | 10 - .../.classpath | 7 - .../.gitignore | 2 - .../org.eclipse.emf.eef.views.editor/.project | 28 - .../META-INF/MANIFEST.MF | 20 - .../about.html | 28 - .../build.properties | 21 - .../icons/full/obj16/ToolkitsModelFile.gif | Bin 604 -> 0 bytes .../icons/full/obj16/ViewsModelFile.gif | Bin 589 -> 0 bytes .../icons/full/wizban/NewToolkits.gif | Bin 2462 -> 0 bytes .../icons/full/wizban/NewViews.gif | Bin 2462 -> 0 bytes .../plugin.properties | 68 - .../plugin.xml | 72 - .../org.eclipse.emf.eef.views.editor/pom.xml | 27 - .../ToolkitsActionBarContributor.java | 434 - .../toolkits/presentation/ToolkitsEditor.java | 1514 ---- .../presentation/ToolkitsModelWizard.java | 638 -- .../ViewsActionBarContributor.java | 432 - .../eef/views/presentation/ViewsEditor.java | 1512 ---- .../views/presentation/ViewsEditorPlugin.java | 97 - .../views/presentation/ViewsModelWizard.java | 635 -- plugins/org.eclipse.emf.eef.views/.checkstyle | 10 - plugins/org.eclipse.emf.eef.views/.classpath | 8 - plugins/org.eclipse.emf.eef.views/.gitignore | 2 - plugins/org.eclipse.emf.eef.views/.project | 28 - .../org.eclipse.core.resources.prefs | 3 - .../.settings/org.eclipse.jdt.ui.prefs | 4 - .../META-INF/MANIFEST.MF | 17 - plugins/org.eclipse.emf.eef.views/about.html | 28 - .../build.properties | 22 - .../model/views.ecore | 78 - .../model/views.ecorediag | 336 - .../model/views.genmodel | 90 - plugins/org.eclipse.emf.eef.views/plugin.xml | 45 - plugins/org.eclipse.emf.eef.views/pom.xml | 27 - .../org/eclipse/emf/eef/toolkits/Toolkit.java | 78 - .../emf/eef/toolkits/ToolkitsFactory.java | 60 - .../emf/eef/toolkits/ToolkitsPackage.java | 338 - .../org/eclipse/emf/eef/toolkits/Widget.java | 141 - .../emf/eef/toolkits/impl/ToolkitImpl.java | 249 - .../toolkits/impl/ToolkitsFactoryImpl.java | 119 - .../toolkits/impl/ToolkitsPackageImpl.java | 299 - .../emf/eef/toolkits/impl/WidgetImpl.java | 395 - .../toolkits/util/ToolkitsAdapterFactory.java | 145 - .../emf/eef/toolkits/util/ToolkitsSwitch.java | 157 - .../org/eclipse/emf/eef/views/Category.java | 123 - .../org/eclipse/emf/eef/views/Container.java | 50 - .../emf/eef/views/CustomElementEditor.java | 24 - .../org/eclipse/emf/eef/views/CustomView.java | 24 - .../emf/eef/views/DocumentedElement.java | 58 - .../eclipse/emf/eef/views/ElementEditor.java | 83 - .../emf/eef/views/IdentifiedElement.java | 47 - .../org/eclipse/emf/eef/views/View.java | 142 - .../eclipse/emf/eef/views/ViewElement.java | 114 - .../eclipse/emf/eef/views/ViewReference.java | 56 - .../eclipse/emf/eef/views/ViewsFactory.java | 114 - .../eclipse/emf/eef/views/ViewsPackage.java | 1495 ---- .../emf/eef/views/ViewsRepository.java | 113 - .../emf/eef/views/impl/CategoryImpl.java | 372 - .../emf/eef/views/impl/ContainerImpl.java | 252 - .../views/impl/CustomElementEditorImpl.java | 47 - .../emf/eef/views/impl/CustomViewImpl.java | 46 - .../eef/views/impl/DocumentedElementImpl.java | 173 - .../emf/eef/views/impl/ElementEditorImpl.java | 305 - .../eef/views/impl/IdentifiedElementImpl.java | 106 - .../emf/eef/views/impl/ViewElementImpl.java | 350 - .../eclipse/emf/eef/views/impl/ViewImpl.java | 435 - .../emf/eef/views/impl/ViewReferenceImpl.java | 243 - .../emf/eef/views/impl/ViewsFactoryImpl.java | 195 - .../emf/eef/views/impl/ViewsPackageImpl.java | 765 -- .../eef/views/impl/ViewsRepositoryImpl.java | 402 - .../eef/views/util/ViewsAdapterFactory.java | 326 - .../emf/eef/views/util/ViewsSwitch.java | 416 - .../emf/eef/views/helpers/NamingHelper.java | 65 - .../std/EMFProperties.toolkits | 21 - .../std/SWT.toolkits | 10 - .../.gitignore | 4 - .../.project | 11 - .../Change Version.launch | 9 - .../Clean.launch | 9 - .../LocalBuild tycho (DEBUG).launch | 9 - .../LocalBuild tycho.launch | 12 - .../README.textile | 5 - .../codestyle/EEFCheckstyleConfiguration.xml | 337 - .../codestyle/EEFCodeTemplates.xml | 51 - .../codestyle/EEFFormatter.xml | 274 - .../org.eclipse.emf.eef.releng.parent/pom.xml | 404 - releng/org.eclipse.emf.eef.target/.project | 11 - releng/org.eclipse.emf.eef.target/eef.target | 31 - releng/org.eclipse.emf.eef.target/eef.tpd | 28 - .../org.eclipse.emf.eef.uml.update/.gitignore | 3 - .../org.eclipse.emf.eef.uml.update/.project | 11 - .../category.xml | 14 - releng/org.eclipse.emf.eef.uml.update/pom.xml | 72 - .../publisher.properties | 8 - releng/org.eclipse.emf.eef.update/.gitignore | 3 - releng/org.eclipse.emf.eef.update/.project | 11 - .../org.eclipse.emf.eef.update/category.xml | 56 - releng/org.eclipse.emf.eef.update/pom.xml | 72 - .../publisher.properties | 8 - .../.classpath | 7 - .../.project | 35 - .../META-INF/MANIFEST.MF | 11 - .../emf/eef/nonreg/design/Activator.class | Bin 2066 -> 0 bytes .../build.acceleo | 26 - .../build.properties | 6 - .../description/nonreg.odesign | 40 - .../plugin.xml | 10 - .../emf/eef/nonreg/design/Activator.java | 67 - .../.classpath | 9 - .../.gitignore | 1 - .../.project | 28 - .../.settings/org.eclipse.jdt.core.prefs | 12 - .../META-INF/MANIFEST.MF | 41 - .../build.properties | 17 - ...iewerCompoOptionalProperty_TotalSample.gif | Bin 223 -> 0 bytes ...iewerCompoRequiredProperty_TotalSample.gif | Bin 223 -> 0 bytes ...ablecompositionOptionalProperty_Sample.gif | Bin 223 -> 0 bytes ...ompositionOptionalProperty_TotalSample.gif | Bin 223 -> 0 bytes ...ancedtablecompositionROProperty_Sample.gif | Bin 223 -> 0 bytes ...ablecompositionRequiredProperty_Sample.gif | Bin 223 -> 0 bytes ...ompositionRequiredProperty_TotalSample.gif | Bin 223 -> 0 bytes ...uedAttributeDelegate_AttributeDelegate.gif | Bin 223 -> 0 bytes ...uedAttributeDelegate_AttributeDelegate.gif | Bin 223 -> 0 bytes ...Typing2_ConcreteReferenceTargetSample1.gif | Bin 223 -> 0 bytes ...Typing2_ConcreteReferenceTargetSample2.gif | Bin 223 -> 0 bytes ...Typing2_ConcreteReferenceTargetSample3.gif | Bin 223 -> 0 bytes ...Typing3_ConcreteReferenceTargetSample1.gif | Bin 223 -> 0 bytes ...Typing3_ConcreteReferenceTargetSample2.gif | Bin 223 -> 0 bytes ...Typing3_ConcreteReferenceTargetSample3.gif | Bin 223 -> 0 bytes ...tTyping_ConcreteReferenceTargetSample1.gif | Bin 223 -> 0 bytes ...tTyping_ConcreteReferenceTargetSample2.gif | Bin 223 -> 0 bytes ...tTyping_ConcreteReferenceTargetSample3.gif | Bin 223 -> 0 bytes ...itorSample_references_DeferedReference.gif | Bin 223 -> 0 bytes ...itorSample_references_DeferedReference.gif | Bin 223 -> 0 bytes ...dModelNavigation_SecondModelNavigation.gif | Bin 223 -> 0 bytes ...dModelNavigation_SecondModelNavigation.gif | Bin 223 -> 0 bytes ...AdvancedReferencesTable_AnotherSubType.gif | Bin 223 -> 0 bytes ...pleSampleAdvancedReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...eSampleAdvancedReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...dvancedTableComposition_AnotherSubType.gif | Bin 223 -> 0 bytes ...ampleForAdvancedTableComposition_Owner.gif | Bin 223 -> 0 bytes ...pleForAdvancedTableComposition_Subtype.gif | Bin 223 -> 0 bytes ...eForFlatReferencesTable_AnotherSubType.gif | Bin 223 -> 0 bytes ...ipleSampleForFlatReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...leSampleForFlatReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...ampleForReferencesTable_AnotherSubType.gif | Bin 223 -> 0 bytes ...multipleSampleForReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...ltipleSampleForReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...mpleForTableComposition_AnotherSubType.gif | Bin 223 -> 0 bytes ...ultipleSampleForTableComposition_Owner.gif | Bin 223 -> 0 bytes ...tipleSampleForTableComposition_Subtype.gif | Bin 223 -> 0 bytes ...mpleampleAdvancedReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...leampleAdvancedReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...ampleForAdvancedTableComposition_Owner.gif | Bin 223 -> 0 bytes ...pleForAdvancedTableComposition_Subtype.gif | Bin 223 -> 0 bytes ...ampleampleForFlatReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...pleampleForFlatReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...pleSampleampleForReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...eSampleampleForReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...multipleReferencers_MultipleReferencer.gif | Bin 223 -> 0 bytes .../CreateOwner_referencers_Referencer.gif | Bin 223 -> 0 bytes ...ner_singleReferencers_SingleReferencer.gif | Bin 223 -> 0 bytes ...CreateReferencer_composedElement_Owner.gif | Bin 223 -> 0 bytes ...eateReferencer_composedElement_Subtype.gif | Bin 223 -> 0 bytes ...s_AdvancedEObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ..._samples_AdvancedReferencesTableSample.gif | Bin 223 -> 0 bytes ...s_AdvancedTableCompositionEditorSample.gif | Bin 223 -> 0 bytes .../CreateRoot_samples_AnotherSubType.gif | Bin 223 -> 0 bytes ...Root_samples_AttributeNavigationSample.gif | Bin 223 -> 0 bytes ...t_samples_CheckBoxExtendedEditorSample.gif | Bin 223 -> 0 bytes .../CreateRoot_samples_CheckboxSample.gif | Bin 223 -> 0 bytes ...t_samples_ConcreteReferenceOwnerSample.gif | Bin 223 -> 0 bytes ...samples_ConcreteReferenceTargetSample1.gif | Bin 223 -> 0 bytes ...samples_ConcreteReferenceTargetSample2.gif | Bin 223 -> 0 bytes ...samples_ConcreteReferenceTargetSample3.gif | Bin 223 -> 0 bytes ..._DeferedFlatReferenceTableEditorSample.gif | Bin 223 -> 0 bytes ...ples_DeferedReferenceTableEditorSample.gif | Bin 223 -> 0 bytes ...reateRoot_samples_EMFComboViewerSample.gif | Bin 223 -> 0 bytes ...t_samples_EObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...teRoot_samples_EReferencesViewerSample.gif | Bin 223 -> 0 bytes .../ctool16/CreateRoot_samples_Element.gif | Bin 223 -> 0 bytes .../full/ctool16/CreateRoot_samples_Event.gif | Bin 223 -> 0 bytes ...reateRoot_samples_FirstModelNavigation.gif | Bin 223 -> 0 bytes ...ples_FlatReferenceExtendedEditorSample.gif | Bin 223 -> 0 bytes ...Root_samples_FlatReferencesTableSample.gif | Bin 223 -> 0 bytes .../CreateRoot_samples_ImageViewerSample.gif | Bin 223 -> 0 bytes ...mples_LinkEObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...oot_samples_LinkEReferenceViewerSample.gif | Bin 223 -> 0 bytes ...teRoot_samples_MultiValuedEditorSample.gif | Bin 223 -> 0 bytes .../full/ctool16/CreateRoot_samples_Owner.gif | Bin 223 -> 0 bytes .../CreateRoot_samples_RadioSample.gif | Bin 223 -> 0 bytes ...ateRoot_samples_ReferenceEnabledSample.gif | Bin 223 -> 0 bytes ...eateRoot_samples_ReferencesTableSample.gif | Bin 223 -> 0 bytes .../ctool16/CreateRoot_samples_Sample.gif | Bin 223 -> 0 bytes ...eateRoot_samples_SecondModelNavigation.gif | Bin 223 -> 0 bytes ...eateRoot_samples_SelectionDialogSample.gif | Bin 223 -> 0 bytes ..._samples_SingleCompositionEditorSample.gif | Bin 223 -> 0 bytes ..._samples_SingleCompositionViewerSample.gif | Bin 223 -> 0 bytes ...oot_samples_SmartModelNavigationSample.gif | Bin 223 -> 0 bytes .../ctool16/CreateRoot_samples_Subtype.gif | Bin 223 -> 0 bytes ...t_samples_TableCompositionEditorSample.gif | Bin 223 -> 0 bytes ..._TableCompositionExtensionEditorSample.gif | Bin 223 -> 0 bytes ...CompositionTargetExtensionEditorSample.gif | Bin 223 -> 0 bytes .../full/ctool16/CreateRoot_samples_Tests.gif | Bin 223 -> 0 bytes .../ctool16/CreateRoot_samples_TextSample.gif | Bin 223 -> 0 bytes ...eateRoot_samples_TextSampleWithTwoTabs.gif | Bin 223 -> 0 bytes .../CreateRoot_samples_TextareaSample.gif | Bin 223 -> 0 bytes .../CreateRoot_samples_TotalSample.gif | Bin 223 -> 0 bytes ...y_AdvancedEObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...Property_AdvancedReferencesTableSample.gif | Bin 223 -> 0 bytes ...y_AdvancedTableCompositionEditorSample.gif | Bin 223 -> 0 bytes ...bstractOptionalProperty_AnotherSubType.gif | Bin 223 -> 0 bytes ...onalProperty_AttributeNavigationSample.gif | Bin 223 -> 0 bytes ...lProperty_CheckBoxExtendedEditorSample.gif | Bin 223 -> 0 bytes ...bstractOptionalProperty_CheckboxSample.gif | Bin 223 -> 0 bytes ...lProperty_ConcreteReferenceOwnerSample.gif | Bin 223 -> 0 bytes ...roperty_ConcreteReferenceTargetSample1.gif | Bin 223 -> 0 bytes ...roperty_ConcreteReferenceTargetSample2.gif | Bin 223 -> 0 bytes ...roperty_ConcreteReferenceTargetSample3.gif | Bin 223 -> 0 bytes ..._DeferedFlatReferenceTableEditorSample.gif | Bin 223 -> 0 bytes ...erty_DeferedReferenceTableEditorSample.gif | Bin 223 -> 0 bytes ...tOptionalProperty_EMFComboViewerSample.gif | Bin 223 -> 0 bytes ...lProperty_EObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...tionalProperty_EReferencesViewerSample.gif | Bin 223 -> 0 bytes ...itorOnAbstractOptionalProperty_Element.gif | Bin 223 -> 0 bytes ...editorOnAbstractOptionalProperty_Event.gif | Bin 223 -> 0 bytes ...tOptionalProperty_FirstModelNavigation.gif | Bin 223 -> 0 bytes ...erty_FlatReferenceExtendedEditorSample.gif | Bin 223 -> 0 bytes ...onalProperty_FlatReferencesTableSample.gif | Bin 223 -> 0 bytes ...ractOptionalProperty_ImageViewerSample.gif | Bin 223 -> 0 bytes ...perty_LinkEObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...nalProperty_LinkEReferenceViewerSample.gif | Bin 223 -> 0 bytes ...tionalProperty_MultiValuedEditorSample.gif | Bin 223 -> 0 bytes ...editorOnAbstractOptionalProperty_Owner.gif | Bin 223 -> 0 bytes ...OnAbstractOptionalProperty_RadioSample.gif | Bin 223 -> 0 bytes ...ptionalProperty_ReferenceEnabledSample.gif | Bin 223 -> 0 bytes ...OptionalProperty_ReferencesTableSample.gif | Bin 223 -> 0 bytes ...ditorOnAbstractOptionalProperty_Sample.gif | Bin 223 -> 0 bytes ...OptionalProperty_SecondModelNavigation.gif | Bin 223 -> 0 bytes ...OptionalProperty_SelectionDialogSample.gif | Bin 223 -> 0 bytes ...Property_SingleCompositionEditorSample.gif | Bin 223 -> 0 bytes ...Property_SingleCompositionViewerSample.gif | Bin 223 -> 0 bytes ...nalProperty_SmartModelNavigationSample.gif | Bin 223 -> 0 bytes ...itorOnAbstractOptionalProperty_Subtype.gif | Bin 223 -> 0 bytes ...lProperty_TableCompositionEditorSample.gif | Bin 223 -> 0 bytes ..._TableCompositionExtensionEditorSample.gif | Bin 223 -> 0 bytes ...CompositionTargetExtensionEditorSample.gif | Bin 223 -> 0 bytes ...editorOnAbstractOptionalProperty_Tests.gif | Bin 223 -> 0 bytes ...rOnAbstractOptionalProperty_TextSample.gif | Bin 223 -> 0 bytes ...OptionalProperty_TextSampleWithTwoTabs.gif | Bin 223 -> 0 bytes ...bstractOptionalProperty_TextareaSample.gif | Bin 223 -> 0 bytes ...OnAbstractOptionalProperty_TotalSample.gif | Bin 223 -> 0 bytes ...itioneditorOptionalProperty_TextSample.gif | Bin 223 -> 0 bytes ...ecompositioneditorROPropery_TextSample.gif | Bin 223 -> 0 bytes ...itioneditorRequiredProperty_TextSample.gif | Bin 223 -> 0 bytes ...y_AdvancedEObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...Property_AdvancedReferencesTableSample.gif | Bin 223 -> 0 bytes ...y_AdvancedTableCompositionEditorSample.gif | Bin 223 -> 0 bytes ...ewMultiOptionalProperty_AnotherSubType.gif | Bin 223 -> 0 bytes ...onalProperty_AttributeNavigationSample.gif | Bin 223 -> 0 bytes ...lProperty_CheckBoxExtendedEditorSample.gif | Bin 223 -> 0 bytes ...ewMultiOptionalProperty_CheckboxSample.gif | Bin 223 -> 0 bytes ...lProperty_ConcreteReferenceOwnerSample.gif | Bin 223 -> 0 bytes ...roperty_ConcreteReferenceTargetSample1.gif | Bin 223 -> 0 bytes ...roperty_ConcreteReferenceTargetSample2.gif | Bin 223 -> 0 bytes ...roperty_ConcreteReferenceTargetSample3.gif | Bin 223 -> 0 bytes ..._DeferedFlatReferenceTableEditorSample.gif | Bin 223 -> 0 bytes ...erty_DeferedReferenceTableEditorSample.gif | Bin 223 -> 0 bytes ...iOptionalProperty_EMFComboViewerSample.gif | Bin 223 -> 0 bytes ...lProperty_EObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...tionalProperty_EReferencesViewerSample.gif | Bin 223 -> 0 bytes ...itionviewMultiOptionalProperty_Element.gif | Bin 223 -> 0 bytes ...ositionviewMultiOptionalProperty_Event.gif | Bin 223 -> 0 bytes ...iOptionalProperty_FirstModelNavigation.gif | Bin 223 -> 0 bytes ...erty_FlatReferenceExtendedEditorSample.gif | Bin 223 -> 0 bytes ...onalProperty_FlatReferencesTableSample.gif | Bin 223 -> 0 bytes ...ultiOptionalProperty_ImageViewerSample.gif | Bin 223 -> 0 bytes ...perty_LinkEObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...nalProperty_LinkEReferenceViewerSample.gif | Bin 223 -> 0 bytes ...tionalProperty_MultiValuedEditorSample.gif | Bin 223 -> 0 bytes ...ositionviewMultiOptionalProperty_Owner.gif | Bin 223 -> 0 bytes ...nviewMultiOptionalProperty_RadioSample.gif | Bin 223 -> 0 bytes ...ptionalProperty_ReferenceEnabledSample.gif | Bin 223 -> 0 bytes ...OptionalProperty_ReferencesTableSample.gif | Bin 223 -> 0 bytes ...sitionviewMultiOptionalProperty_Sample.gif | Bin 223 -> 0 bytes ...OptionalProperty_SecondModelNavigation.gif | Bin 223 -> 0 bytes ...OptionalProperty_SelectionDialogSample.gif | Bin 223 -> 0 bytes ...Property_SingleCompositionEditorSample.gif | Bin 223 -> 0 bytes ...Property_SingleCompositionViewerSample.gif | Bin 223 -> 0 bytes ...nalProperty_SmartModelNavigationSample.gif | Bin 223 -> 0 bytes ...itionviewMultiOptionalProperty_Subtype.gif | Bin 223 -> 0 bytes ...lProperty_TableCompositionEditorSample.gif | Bin 223 -> 0 bytes ..._TableCompositionExtensionEditorSample.gif | Bin 223 -> 0 bytes ...CompositionTargetExtensionEditorSample.gif | Bin 223 -> 0 bytes ...ositionviewMultiOptionalProperty_Tests.gif | Bin 223 -> 0 bytes ...onviewMultiOptionalProperty_TextSample.gif | Bin 223 -> 0 bytes ...OptionalProperty_TextSampleWithTwoTabs.gif | Bin 223 -> 0 bytes ...ewMultiOptionalProperty_TextareaSample.gif | Bin 223 -> 0 bytes ...nviewMultiOptionalProperty_TotalSample.gif | Bin 223 -> 0 bytes ...y_AdvancedEObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...Property_AdvancedReferencesTableSample.gif | Bin 223 -> 0 bytes ...y_AdvancedTableCompositionEditorSample.gif | Bin 223 -> 0 bytes ...ewMultiRequiredProperty_AnotherSubType.gif | Bin 223 -> 0 bytes ...iredProperty_AttributeNavigationSample.gif | Bin 223 -> 0 bytes ...dProperty_CheckBoxExtendedEditorSample.gif | Bin 223 -> 0 bytes ...ewMultiRequiredProperty_CheckboxSample.gif | Bin 223 -> 0 bytes ...dProperty_ConcreteReferenceOwnerSample.gif | Bin 223 -> 0 bytes ...roperty_ConcreteReferenceTargetSample1.gif | Bin 223 -> 0 bytes ...roperty_ConcreteReferenceTargetSample2.gif | Bin 223 -> 0 bytes ...roperty_ConcreteReferenceTargetSample3.gif | Bin 223 -> 0 bytes ..._DeferedFlatReferenceTableEditorSample.gif | Bin 223 -> 0 bytes ...erty_DeferedReferenceTableEditorSample.gif | Bin 223 -> 0 bytes ...iRequiredProperty_EMFComboViewerSample.gif | Bin 223 -> 0 bytes ...dProperty_EObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...quiredProperty_EReferencesViewerSample.gif | Bin 223 -> 0 bytes ...itionviewMultiRequiredProperty_Element.gif | Bin 223 -> 0 bytes ...ositionviewMultiRequiredProperty_Event.gif | Bin 223 -> 0 bytes ...iRequiredProperty_FirstModelNavigation.gif | Bin 223 -> 0 bytes ...erty_FlatReferenceExtendedEditorSample.gif | Bin 223 -> 0 bytes ...iredProperty_FlatReferencesTableSample.gif | Bin 223 -> 0 bytes ...ultiRequiredProperty_ImageViewerSample.gif | Bin 223 -> 0 bytes ...perty_LinkEObjectFlatComboViewerSample.gif | Bin 223 -> 0 bytes ...redProperty_LinkEReferenceViewerSample.gif | Bin 223 -> 0 bytes ...quiredProperty_MultiValuedEditorSample.gif | Bin 223 -> 0 bytes ...ositionviewMultiRequiredProperty_Owner.gif | Bin 223 -> 0 bytes ...nviewMultiRequiredProperty_RadioSample.gif | Bin 223 -> 0 bytes ...equiredProperty_ReferenceEnabledSample.gif | Bin 223 -> 0 bytes ...RequiredProperty_ReferencesTableSample.gif | Bin 223 -> 0 bytes ...sitionviewMultiRequiredProperty_Sample.gif | Bin 223 -> 0 bytes ...RequiredProperty_SecondModelNavigation.gif | Bin 223 -> 0 bytes ...RequiredProperty_SelectionDialogSample.gif | Bin 223 -> 0 bytes ...Property_SingleCompositionEditorSample.gif | Bin 223 -> 0 bytes ...Property_SingleCompositionViewerSample.gif | Bin 223 -> 0 bytes ...redProperty_SmartModelNavigationSample.gif | Bin 223 -> 0 bytes ...itionviewMultiRequiredProperty_Subtype.gif | Bin 223 -> 0 bytes ...dProperty_TableCompositionEditorSample.gif | Bin 223 -> 0 bytes ..._TableCompositionExtensionEditorSample.gif | Bin 223 -> 0 bytes ...CompositionTargetExtensionEditorSample.gif | Bin 223 -> 0 bytes ...ositionviewMultiRequiredProperty_Tests.gif | Bin 223 -> 0 bytes ...onviewMultiRequiredProperty_TextSample.gif | Bin 223 -> 0 bytes ...RequiredProperty_TextSampleWithTwoTabs.gif | Bin 223 -> 0 bytes ...ewMultiRequiredProperty_TextareaSample.gif | Bin 223 -> 0 bytes ...nviewMultiRequiredProperty_TotalSample.gif | Bin 223 -> 0 bytes ...itionviewSingleOptionalProperty_Sample.gif | Bin 223 -> 0 bytes ...compositionviewSingleROProperty_Sample.gif | Bin 223 -> 0 bytes ...itionviewSingleRequiredProperty_Sample.gif | Bin 223 -> 0 bytes ...dEObjectFlatComboViewer_AnotherSubType.gif | Bin 223 -> 0 bytes ...orAdvancedEObjectFlatComboViewer_Owner.gif | Bin 223 -> 0 bytes ...AdvancedEObjectFlatComboViewer_Subtype.gif | Bin 223 -> 0 bytes ...rEObjectFlatComboViewer_AnotherSubType.gif | Bin 223 -> 0 bytes ...ainmentForEObjectFlatComboViewer_Owner.gif | Bin 223 -> 0 bytes ...nmentForEObjectFlatComboViewer_Subtype.gif | Bin 223 -> 0 bytes ...AdvancedReferencesTable_AnotherSubType.gif | Bin 223 -> 0 bytes ...gleSampleAdvancedReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...eSampleAdvancedReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...dvancedTableComposition_AnotherSubType.gif | Bin 223 -> 0 bytes ...ampleForAdvancedTableComposition_Owner.gif | Bin 223 -> 0 bytes ...pleForAdvancedTableComposition_Subtype.gif | Bin 223 -> 0 bytes ...eForFlatReferencesTable_AnotherSubType.gif | Bin 223 -> 0 bytes ...ngleSampleForFlatReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...leSampleForFlatReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...ampleForReferencesTable_AnotherSubType.gif | Bin 223 -> 0 bytes ...r_singleSampleForReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...singleSampleForReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...mpleForTableComposition_AnotherSubType.gif | Bin 223 -> 0 bytes ..._singleSampleForTableComposition_Owner.gif | Bin 223 -> 0 bytes ...ingleSampleForTableComposition_Subtype.gif | Bin 223 -> 0 bytes ...mpleampleAdvancedReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...leampleAdvancedReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...ampleForAdvancedTableComposition_Owner.gif | Bin 223 -> 0 bytes ...pleForAdvancedTableComposition_Subtype.gif | Bin 223 -> 0 bytes ...ampleampleForFlatReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...pleampleForFlatReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...gleSampleampleForReferencesTable_Owner.gif | Bin 223 -> 0 bytes ...eSampleampleForReferencesTable_Subtype.gif | Bin 223 -> 0 bytes ...tModelNavigation2_FirstModelNavigation.gif | Bin 223 -> 0 bytes ...stModelNavigation_FirstModelNavigation.gif | Bin 223 -> 0 bytes ...tModelNavigation2_FirstModelNavigation.gif | Bin 223 -> 0 bytes ...stModelNavigation_FirstModelNavigation.gif | Bin 223 -> 0 bytes ...ablecompositionOptionalProperty_Sample.gif | Bin 223 -> 0 bytes ...ompositionOptionalProperty_TotalSample.gif | Bin 223 -> 0 bytes ...mple_tablecompositionROProperty_Sample.gif | Bin 223 -> 0 bytes ...ablecompositionRequiredProperty_Sample.gif | Bin 223 -> 0 bytes ...ompositionRequiredProperty_TotalSample.gif | Bin 223 -> 0 bytes ...CompositionTargetExtensionEditorSample.gif | Bin 223 -> 0 bytes ...CompositionTargetExtensionEditorSample.gif | Bin 223 -> 0 bytes ...itionOnSameTypeRequiredProperty_Sample.gif | Bin 223 -> 0 bytes ...OnSameTypeRequiredProperty_TotalSample.gif | Bin 223 -> 0 bytes ...itionOnSametypeOptionalProperty_Sample.gif | Bin 223 -> 0 bytes ...OnSametypeOptionalProperty_TotalSample.gif | Bin 223 -> 0 bytes ...ablecompositionOptionalProperty_Sample.gif | Bin 223 -> 0 bytes ...ompositionOptionalProperty_TotalSample.gif | Bin 223 -> 0 bytes ...ancedtablecompositionROProperty_Sample.gif | Bin 223 -> 0 bytes ...ablecompositionRequiredProperty_Sample.gif | Bin 223 -> 0 bytes ...ompositionRequiredProperty_TotalSample.gif | Bin 223 -> 0 bytes ...OnSameTypeOptionalProperty_TotalSample.gif | Bin 223 -> 0 bytes ...OnSameTypeRequiredProperty_TotalSample.gif | Bin 223 -> 0 bytes ...ablecompositionOptionalProperty_Sample.gif | Bin 223 -> 0 bytes ...ompositionOptionalProperty_TotalSample.gif | Bin 223 -> 0 bytes ...mple_tablecompositionROProperty_Sample.gif | Bin 223 -> 0 bytes ...ablecompositionRequiredProperty_Sample.gif | Bin 223 -> 0 bytes ...compositionRequiredProperty_TextSample.gif | Bin 223 -> 0 bytes .../obj16/AbstractReferenceOwnerSample.gif | Bin 129 -> 0 bytes .../obj16/AbstractReferenceTargetSample.gif | Bin 129 -> 0 bytes .../AdvancedEObjectFlatComboViewerSample.gif | Bin 129 -> 0 bytes .../obj16/AdvancedReferencesTableSample.gif | Bin 129 -> 0 bytes .../AdvancedTableCompositionEditorSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/AnotherSubType.gif | Bin 129 -> 0 bytes .../icons/full/obj16/AttributeDelegate.gif | Bin 129 -> 0 bytes .../full/obj16/AttributeNavigationSample.gif | Bin 129 -> 0 bytes .../obj16/CheckBoxExtendedEditorSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/CheckboxSample.gif | Bin 129 -> 0 bytes .../obj16/ConcreteReferenceOwnerSample.gif | Bin 129 -> 0 bytes .../obj16/ConcreteReferenceTargetSample1.gif | Bin 129 -> 0 bytes .../obj16/ConcreteReferenceTargetSample2.gif | Bin 129 -> 0 bytes .../obj16/ConcreteReferenceTargetSample3.gif | Bin 129 -> 0 bytes .../DeferedFlatReferenceTableEditorSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/DeferedReference.gif | Bin 129 -> 0 bytes .../DeferedReferenceTableEditorSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/EMFComboViewerSample.gif | Bin 129 -> 0 bytes .../obj16/EObjectFlatComboViewerSample.gif | Bin 129 -> 0 bytes .../full/obj16/EReferencesViewerSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Element.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Event.gif | Bin 129 -> 0 bytes .../icons/full/obj16/FirstModelNavigation.gif | Bin 129 -> 0 bytes .../FlatReferenceExtendedEditorSample.gif | Bin 129 -> 0 bytes .../full/obj16/FlatReferencesTableSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/ImageViewerSample.gif | Bin 129 -> 0 bytes .../LinkEObjectFlatComboViewerSample.gif | Bin 129 -> 0 bytes .../full/obj16/LinkEReferenceViewerSample.gif | Bin 129 -> 0 bytes .../full/obj16/MultiValuedEditorSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/MultipleReferencer.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Owner.gif | Bin 129 -> 0 bytes .../icons/full/obj16/RadioSample.gif | Bin 129 -> 0 bytes .../full/obj16/ReferenceEnabledSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Referencer.gif | Bin 129 -> 0 bytes .../full/obj16/ReferencesTableSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Root.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Sample.gif | Bin 129 -> 0 bytes .../full/obj16/SecondModelNavigation.gif | Bin 129 -> 0 bytes .../full/obj16/SelectionDialogSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/SimpleSample.gif | Bin 129 -> 0 bytes .../obj16/SingleCompositionEditorSample.gif | Bin 129 -> 0 bytes .../obj16/SingleCompositionViewerSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/SingleReferencer.gif | Bin 129 -> 0 bytes .../full/obj16/SmartModelNavigationSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Subtype.gif | Bin 129 -> 0 bytes .../obj16/TableCompositionEditorSample.gif | Bin 129 -> 0 bytes .../TableCompositionExtensionEditorSample.gif | Bin 129 -> 0 bytes ...CompositionTargetExtensionEditorSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Tests.gif | Bin 129 -> 0 bytes .../icons/full/obj16/TextSample.gif | Bin 129 -> 0 bytes .../full/obj16/TextSampleWithTwoTabs.gif | Bin 129 -> 0 bytes .../icons/full/obj16/TextareaSample.gif | Bin 129 -> 0 bytes .../icons/full/obj16/TotalSample.gif | Bin 129 -> 0 bytes .../icons/sample.gif | Bin 983 -> 0 bytes .../models/eefnr.components | 1568 ---- .../models/eefnr.eefgen | 45 - .../plugin.properties | 254 - .../plugin.xml | 1473 ---- .../pom.xml | 28 - .../impl/EEFNRPropertiesEditingProvider.java | 14 - .../eclipse/emf/eef/eefnr/utils/Utils.java | 107 - .../src-gen/eefnr_properties.plugin.xml | 260 - .../src-gen/eefnrext_properties.plugin.xml | 148 - .../src-gen/filters_properties.plugin.xml | 109 - .../src-gen/interface_properties.plugin.xml | 86 - .../src-gen/naming_properties.plugin.xml | 97 - .../src-gen/navigation_properties.plugin.xml | 233 - ...iewerSamplePropertiesEditionComponent.java | 285 - ...TableSamplePropertiesEditionComponent.java | 265 - ...ditorSamplePropertiesEditionComponent.java | 329 - ...ckboxSamplePropertiesEditionComponent.java | 233 - ...iewerSamplePropertiesEditionComponent.java | 235 - ...iewerSamplePropertiesEditionComponent.java | 323 - ...iewerSamplePropertiesEditionComponent.java | 246 - ...TableSamplePropertiesEditionComponent.java | 290 - ...iewerSamplePropertiesEditionComponent.java | 251 - ...iewerSamplePropertiesEditionComponent.java | 294 - ...iewerSamplePropertiesEditionComponent.java | 351 - ...ditorSamplePropertiesEditionComponent.java | 260 - ...RadioSamplePropertiesEditionComponent.java | 235 - ...TableSamplePropertiesEditionComponent.java | 306 - .../RootPropertiesEditionComponent.java | 232 - .../SamplePropertiesEditionComponent.java | 223 - ...ialogSamplePropertiesEditionComponent.java | 248 - ...ditorSamplePropertiesEditionComponent.java | 347 - ...iewerSamplePropertiesEditionComponent.java | 221 - ...ditorSamplePropertiesEditionComponent.java | 329 - ...ditorSamplePropertiesEditionComponent.java | 305 - .../TextSamplePropertiesEditionComponent.java | 246 - ...WithTwoTabsPropertiesEditionComponent.java | 138 - ...pleFirstTabPropertiesEditionComponent.java | 223 - ...leSecondTabPropertiesEditionComponent.java | 223 - ...tareaSamplePropertiesEditionComponent.java | 243 - ...TotalSamplePropertiesEditionComponent.java | 1095 --- ...renceOwnerSamplePropertiesEditionPart.java | 232 - ...nceTargetSample1PropertiesEditionPart.java | 54 - ...nceTargetSample2PropertiesEditionPart.java | 54 - .../filters/parts/FiltersViewsRepository.java | 81 - ...eOwnerSamplePropertiesEditionPartForm.java | 956 --- ...argetSample1PropertiesEditionPartForm.java | 279 - ...argetSample2PropertiesEditionPartForm.java | 279 - ...eOwnerSamplePropertiesEditionPartImpl.java | 926 -- ...argetSample1PropertiesEditionPartImpl.java | 248 - ...argetSample2PropertiesEditionPartImpl.java | 248 - .../filters/providers/FiltersMessages.java | 135 - .../FiltersPropertiesEditionPartProvider.java | 71 - .../providers/filtersMessages.properties | 48 - .../providers/filtersMessages_fr.properties | 48 - .../parts/Interface_ViewsRepository.java | 34 - .../SimpleSamplePropertiesEditionPart.java | 37 - ...SimpleSamplePropertiesEditionPartForm.java | 118 - ...SimpleSamplePropertiesEditionPartImpl.java | 111 - .../providers/Interface_Messages.java | 93 - ...terface_PropertiesEditionPartProvider.java | 45 - .../providers/interface_Messages.properties | 34 - .../interface_Messages_fr.properties | 34 - .../AnotherSubtypePropertiesEditionPart.java | 699 -- ...NavigationSamplePropertiesEditionPart.java | 110 - ...encesTableSamplePropertiesEditionPart.java | 100 - ...encesTableSamplePropertiesEditionPart.java | 100 - .../parts/ElementPropertiesEditionPart.java | 73 - .../parts/EventPropertiesEditionPart.java | 54 - ...NavigationSamplePropertiesEditionPart.java | 54 - .../NamedElementPropertiesEditionPart.java | 54 - .../parts/NamingViewsRepository.java | 39 - .../parts/NavigationViewsRepository.java | 294 - .../parts/OwnerPropertiesEditionPart.java | 678 -- ...NavigationSamplePropertiesEditionPart.java | 54 - ...ionSampleOnglet2PropertiesEditionPart.java | 93 - ...NavigationSamplePropertiesEditionPart.java | 152 - .../parts/SubtypePropertiesEditionPart.java | 685 -- ...otherSubtypePropertiesEditionPartForm.java | 1061 --- ...gationSamplePropertiesEditionPartForm.java | 701 -- ...sTableSamplePropertiesEditionPartForm.java | 384 - ...sTableSamplePropertiesEditionPartForm.java | 552 -- .../ElementPropertiesEditionPartForm.java | 287 - .../forms/EventPropertiesEditionPartForm.java | 279 - ...gationSamplePropertiesEditionPartForm.java | 279 - ...NamedElementPropertiesEditionPartForm.java | 279 - .../forms/OwnerPropertiesEditionPartForm.java | 2676 ------ ...gationSamplePropertiesEditionPartForm.java | 279 - ...ampleOnglet2PropertiesEditionPartForm.java | 301 - ...gationSamplePropertiesEditionPartForm.java | 1017 --- .../SubtypePropertiesEditionPartForm.java | 1040 --- ...otherSubtypePropertiesEditionPartImpl.java | 1050 --- ...gationSamplePropertiesEditionPartImpl.java | 594 -- ...sTableSamplePropertiesEditionPartImpl.java | 353 - ...sTableSamplePropertiesEditionPartImpl.java | 516 -- .../ElementPropertiesEditionPartImpl.java | 276 - .../impl/EventPropertiesEditionPartImpl.java | 248 - ...gationSamplePropertiesEditionPartImpl.java | 248 - ...NamedElementPropertiesEditionPartImpl.java | 248 - .../impl/OwnerPropertiesEditionPartImpl.java | 2614 ------ ...gationSamplePropertiesEditionPartImpl.java | 248 - ...ampleOnglet2PropertiesEditionPartImpl.java | 284 - ...gationSamplePropertiesEditionPartImpl.java | 853 -- .../SubtypePropertiesEditionPartImpl.java | 1029 --- .../navigation/providers/NamingMessages.java | 99 - .../NamingPropertiesEditionPartProvider.java | 55 - .../providers/NavigationMessages.java | 312 - ...vigationPropertiesEditionPartProvider.java | 143 - .../providers/namingMessages.properties | 36 - .../providers/namingMessages_fr.properties | 36 - .../providers/navigationMessages.properties | 107 - .../navigationMessages_fr.properties | 107 - ...omboViewerSamplePropertiesEditionPart.java | 254 - ...encesTableSamplePropertiesEditionPart.java | 170 - ...tionEditorSamplePropertiesEditionPart.java | 176 - .../CheckboxSamplePropertiesEditionPart.java | 82 - ...omboViewerSamplePropertiesEditionPart.java | 103 - ...omboViewerSamplePropertiesEditionPart.java | 187 - ...ncesViewerSamplePropertiesEditionPart.java | 170 - .../eef/eefnr/parts/EefnrViewsRepository.java | 640 -- ...renceTableSamplePropertiesEditionPart.java | 170 - ...mageViewerSamplePropertiesEditionPart.java | 103 - ...omboViewerSamplePropertiesEditionPart.java | 187 - ...enceViewerSamplePropertiesEditionPart.java | 187 - ...luedEditorSamplePropertiesEditionPart.java | 118 - .../RadioSamplePropertiesEditionPart.java | 103 - ...encesTableSamplePropertiesEditionPart.java | 170 - .../parts/RootPropertiesEditionPart.java | 88 - .../parts/SamplePropertiesEditionPart.java | 68 - ...tionDialogSamplePropertiesEditionPart.java | 82 - ...tionEditorSamplePropertiesEditionPart.java | 122 - ...tionViewerSamplePropertiesEditionPart.java | 190 - ...tionEditorSamplePropertiesEditionPart.java | 176 - ...sionEditorSamplePropertiesEditionPart.java | 146 - ...xtSampleFirstTabPropertiesEditionPart.java | 68 - .../TextSamplePropertiesEditionPart.java | 82 - ...tSampleSecondTabPropertiesEditionPart.java | 68 - .../TextareaSamplePropertiesEditionPart.java | 82 - .../TotalSamplePropertiesEditionPart.java | 820 -- ...ViewerSamplePropertiesEditionPartForm.java | 754 -- ...sTableSamplePropertiesEditionPartForm.java | 652 -- ...EditorSamplePropertiesEditionPartForm.java | 546 -- ...eckboxSamplePropertiesEditionPartForm.java | 365 - ...ViewerSamplePropertiesEditionPartForm.java | 414 - ...ViewerSamplePropertiesEditionPartForm.java | 539 -- ...ViewerSamplePropertiesEditionPartForm.java | 645 -- ...eTableSamplePropertiesEditionPartForm.java | 450 - ...ViewerSamplePropertiesEditionPartForm.java | 436 - ...ViewerSamplePropertiesEditionPartForm.java | 537 -- ...ViewerSamplePropertiesEditionPartForm.java | 537 -- ...EditorSamplePropertiesEditionPartForm.java | 490 -- .../RadioSamplePropertiesEditionPartForm.java | 399 - ...sTableSamplePropertiesEditionPartForm.java | 926 -- .../forms/RootPropertiesEditionPartForm.java | 303 - .../SamplePropertiesEditionPartForm.java | 384 - ...DialogSamplePropertiesEditionPartForm.java | 467 - ...EditorSamplePropertiesEditionPartForm.java | 495 -- ...ViewerSamplePropertiesEditionPartForm.java | 639 -- ...EditorSamplePropertiesEditionPartForm.java | 961 --- ...EditorSamplePropertiesEditionPartForm.java | 542 -- ...mpleFirstTabPropertiesEditionPartForm.java | 384 - .../TextSamplePropertiesEditionPartForm.java | 484 -- ...pleSecondTabPropertiesEditionPartForm.java | 384 - ...xtareaSamplePropertiesEditionPartForm.java | 459 - .../TotalSamplePropertiesEditionPartForm.java | 3318 -------- ...ViewerSamplePropertiesEditionPartImpl.java | 728 -- ...sTableSamplePropertiesEditionPartImpl.java | 636 -- ...EditorSamplePropertiesEditionPartImpl.java | 536 -- ...eckboxSamplePropertiesEditionPartImpl.java | 356 - ...ViewerSamplePropertiesEditionPartImpl.java | 402 - ...ViewerSamplePropertiesEditionPartImpl.java | 508 -- ...ViewerSamplePropertiesEditionPartImpl.java | 629 -- ...eTableSamplePropertiesEditionPartImpl.java | 440 - ...ViewerSamplePropertiesEditionPartImpl.java | 424 - ...ViewerSamplePropertiesEditionPartImpl.java | 521 -- ...ViewerSamplePropertiesEditionPartImpl.java | 521 -- ...EditorSamplePropertiesEditionPartImpl.java | 470 - .../RadioSamplePropertiesEditionPartImpl.java | 390 - ...sTableSamplePropertiesEditionPartImpl.java | 899 -- .../impl/RootPropertiesEditionPartImpl.java | 293 - .../impl/SamplePropertiesEditionPartImpl.java | 334 - ...DialogSamplePropertiesEditionPartImpl.java | 455 - ...EditorSamplePropertiesEditionPartImpl.java | 475 -- ...ViewerSamplePropertiesEditionPartImpl.java | 674 -- ...EditorSamplePropertiesEditionPartImpl.java | 958 --- ...EditorSamplePropertiesEditionPartImpl.java | 512 -- ...mpleFirstTabPropertiesEditionPartImpl.java | 334 - .../TextSamplePropertiesEditionPartImpl.java | 415 - ...pleSecondTabPropertiesEditionPartImpl.java | 334 - ...xtareaSamplePropertiesEditionPartImpl.java | 375 - .../TotalSamplePropertiesEditionPartImpl.java | 3176 ------- ...ViewerSamplePropertiesEditionProvider.java | 150 - ...sTableSamplePropertiesEditionProvider.java | 150 - ...EditorSamplePropertiesEditionProvider.java | 150 - ...eckboxSamplePropertiesEditionProvider.java | 150 - ...ViewerSamplePropertiesEditionProvider.java | 150 - ...ViewerSamplePropertiesEditionProvider.java | 150 - ...ViewerSamplePropertiesEditionProvider.java | 150 - .../providers/EefnrEEFAdapterFactory.java | 244 - .../eef/eefnr/providers/EefnrMessages.java | 624 -- .../EefnrPropertiesEditionPartProvider.java | 255 - ...eTableSamplePropertiesEditionProvider.java | 150 - ...ViewerSamplePropertiesEditionProvider.java | 150 - ...ViewerSamplePropertiesEditionProvider.java | 150 - ...ViewerSamplePropertiesEditionProvider.java | 150 - ...EditorSamplePropertiesEditionProvider.java | 150 - .../RadioSamplePropertiesEditionProvider.java | 150 - ...sTableSamplePropertiesEditionProvider.java | 150 - .../RootPropertiesEditionProvider.java | 150 - .../SamplePropertiesEditionProvider.java | 150 - ...DialogSamplePropertiesEditionProvider.java | 150 - ...EditorSamplePropertiesEditionProvider.java | 150 - ...ViewerSamplePropertiesEditionProvider.java | 150 - ...EditorSamplePropertiesEditionProvider.java | 150 - ...EditorSamplePropertiesEditionProvider.java | 150 - .../TextSamplePropertiesEditionProvider.java | 150 - ...eWithTwoTabsPropertiesEditionProvider.java | 157 - ...xtareaSamplePropertiesEditionProvider.java | 150 - .../TotalSamplePropertiesEditionProvider.java | 150 - .../eefnr/providers/eefnrMessages.properties | 211 - .../providers/eefnrMessages_fr.properties | 211 - ...actEnabledSamplePropertiesEditionPart.java | 73 - .../AbstractSamplePropertiesEditionPart.java | 54 - ...nceEnabledSamplePropertiesEditionPart.java | 121 - .../parts/ReferencesViewsRepository.java | 75 - ...nabledSamplePropertiesEditionPartForm.java | 287 - ...stractSamplePropertiesEditionPartForm.java | 279 - ...nabledSamplePropertiesEditionPartForm.java | 415 - ...nabledSamplePropertiesEditionPartImpl.java | 276 - ...stractSamplePropertiesEditionPartImpl.java | 248 - ...nabledSamplePropertiesEditionPartImpl.java | 403 - .../providers/ReferencesMessages.java | 123 - ...ferencesPropertiesEditionPartProvider.java | 71 - .../providers/referencesMessages.properties | 44 - .../referencesMessages_fr.properties | 44 - ...rSampleBasePropertiesEditionComponent.java | 197 - ...ditorSamplePropertiesEditionComponent.java | 129 - ...rSampleBasePropertiesEditionComponent.java | 232 - ...ditorSamplePropertiesEditionComponent.java | 152 - ...ditorSamplePropertiesEditionComponent.java | 224 - ...ditorSamplePropertiesEditionComponent.java | 188 - ...ndedEditorSamplePropertiesEditionPart.java | 73 - .../parts/EefnrextViewsRepository.java | 93 - ...ndedEditorSamplePropertiesEditionPart.java | 121 - ...ndedEditorSamplePropertiesEditionPart.java | 68 - ...sionEditorSamplePropertiesEditionPart.java | 54 - ...EditorSamplePropertiesEditionPartForm.java | 289 - ...EditorSamplePropertiesEditionPartForm.java | 339 - ...EditorSamplePropertiesEditionPartForm.java | 384 - ...EditorSamplePropertiesEditionPartForm.java | 279 - ...EditorSamplePropertiesEditionPartImpl.java | 278 - ...EditorSamplePropertiesEditionPartImpl.java | 329 - ...EditorSamplePropertiesEditionPartImpl.java | 334 - ...EditorSamplePropertiesEditionPartImpl.java | 248 - ...EditorSamplePropertiesEditionProvider.java | 158 - .../providers/EefnrextEEFAdapterFactory.java | 67 - .../eefnrext/providers/EefnrextMessages.java | 138 - ...EefnrextPropertiesEditionPartProvider.java | 79 - ...EditorSamplePropertiesEditionProvider.java | 164 - ...EditorSamplePropertiesEditionProvider.java | 150 - .../providers/eefnrextMessages.properties | 49 - .../providers/eefnrextMessages_fr.properties | 49 - ...OwnerSamplePropertiesEditionComponent.java | 445 - ...rgetSample1PropertiesEditionComponent.java | 188 - ...rgetSample2PropertiesEditionComponent.java | 188 - ...eOwnerSamplePropertiesEditionProvider.java | 150 - ...argetSample1PropertiesEditionProvider.java | 150 - ...argetSample2PropertiesEditionProvider.java | 150 - .../providers/FiltersEEFAdapterFactory.java | 58 - .../Interface_EEFAdapterFactory.java | 22 - .../EventPropertiesEditionComponent.java | 188 - .../EventPropertiesEditionProvider.java | 150 - .../providers/NamingEEFAdapterFactory.java | 42 - ...SubtypeBasePropertiesEditionComponent.java | 193 - ...therSubtypePropertiesEditionComponent.java | 125 - ...ationSamplePropertiesEditionComponent.java | 388 - ...ampleEditorPropertiesEditionComponent.java | 261 - ...ampleEditorPropertiesEditionComponent.java | 263 - ...ElementBasePropertiesEditionComponent.java | 195 - .../ElementPropertiesEditionComponent.java | 125 - ...ationSamplePropertiesEditionComponent.java | 188 - ...amedElementPropertiesEditionComponent.java | 187 - .../OwnerPropertiesEditionComponent.java | 854 -- ...ationSamplePropertiesEditionComponent.java | 188 - ...ationSamplePropertiesEditionComponent.java | 169 - ...mpleOnglet2PropertiesEditionComponent.java | 213 - ...ationSamplePropertiesEditionComponent.java | 759 -- ...SubtypeBasePropertiesEditionComponent.java | 402 - .../SubtypePropertiesEditionComponent.java | 125 - ...otherSubtypePropertiesEditionProvider.java | 158 - ...gationSamplePropertiesEditionProvider.java | 150 - ...SampleEditorPropertiesEditionProvider.java | 150 - ...SampleEditorPropertiesEditionProvider.java | 150 - .../ElementPropertiesEditionProvider.java | 157 - ...gationSamplePropertiesEditionProvider.java | 150 - ...NamedElementPropertiesEditionProvider.java | 150 - .../NavigationEEFAdapterFactory.java | 133 - .../OwnerPropertiesEditionProvider.java | 150 - ...gationSamplePropertiesEditionProvider.java | 150 - ...gationSamplePropertiesEditionProvider.java | 157 - .../SubtypePropertiesEditionProvider.java | 157 - ...dSampleBasePropertiesEditionComponent.java | 195 - ...abledSamplePropertiesEditionComponent.java | 125 - ...tractSamplePropertiesEditionComponent.java | 187 - ...dSampleBasePropertiesEditionComponent.java | 205 - ...abledSamplePropertiesEditionComponent.java | 123 - ...nabledSamplePropertiesEditionProvider.java | 157 - ...stractSamplePropertiesEditionProvider.java | 150 - ...nabledSamplePropertiesEditionProvider.java | 157 - .../ReferencesEEFAdapterFactory.java | 67 - .../src-gen/references_properties.plugin.xml | 110 - ...tractReferenceOwnerSampleItemProvider.java | 155 - ...ractReferenceTargetSampleItemProvider.java | 130 - ...creteReferenceOwnerSampleItemProvider.java | 251 - ...eteReferenceTargetSample1ItemProvider.java | 114 - ...eteReferenceTargetSample2ItemProvider.java | 114 - ...eteReferenceTargetSample3ItemProvider.java | 114 - .../FiltersItemProviderAdapterFactory.java | 275 - .../InterfaceItemProviderAdapterFactory.java | 203 - .../provider/SimpleSampleItemProvider.java | 125 - ...ustomNamingItemProviderAdapterFactory.java | 203 - .../naming/provider/EventItemProvider.java | 130 - .../provider/AnotherSubTypeItemProvider.java | 147 - .../AttributeDelegateItemProvider.java | 187 - ...AttributeNavigationSampleItemProvider.java | 206 - ...eferenceTableEditorSampleItemProvider.java | 176 - .../DeferedReferenceItemProvider.java | 151 - ...eferenceTableEditorSampleItemProvider.java | 176 - .../provider/ElementItemProvider.java | 161 - .../FirstModelNavigationItemProvider.java | 257 - .../MultipleReferencerItemProvider.java | 347 - .../NavigationItemProviderAdapterFactory.java | 515 -- .../provider/OwnerItemProvider.java | 183 - .../SecondModelNavigationItemProvider.java | 187 - .../SingleReferencerItemProvider.java | 460 - ...martModelNavigationSampleItemProvider.java | 222 - .../provider/SubtypeItemProvider.java | 147 - .../provider/AbstractSampleItemProvider.java | 149 - ...rgetExtensionEditorSampleItemProvider.java | 103 - ...jectFlatComboViewerSampleItemProvider.java | 188 - ...ncedReferencesTableSampleItemProvider.java | 185 - ...leCompositionEditorSampleItemProvider.java | 198 - .../provider/CheckboxSampleItemProvider.java | 195 - .../EMFComboViewerSampleItemProvider.java | 195 - ...jectFlatComboViewerSampleItemProvider.java | 185 - .../EReferencesViewerSampleItemProvider.java | 185 - .../eef/eefnr/provider/EefnrEditPlugin.java | 93 - .../EefnrItemProviderAdapterFactory.java | 779 -- ...FlatReferencesTableSampleItemProvider.java | 185 - .../ImageViewerSampleItemProvider.java | 195 - ...jectFlatComboViewerSampleItemProvider.java | 185 - ...inkEReferenceViewerSampleItemProvider.java | 185 - .../MultiValuedEditorSampleItemProvider.java | 195 - .../provider/NamedElementItemProvider.java | 103 - .../provider/RadioSampleItemProvider.java | 195 - .../ReferencesTableSampleItemProvider.java | 185 - .../eef/eefnr/provider/RootItemProvider.java | 391 - .../eefnr/provider/SampleItemProvider.java | 171 - .../SelectionDialogSampleItemProvider.java | 195 - ...leCompositionEditorSampleItemProvider.java | 426 - ...leCompositionViewerSampleItemProvider.java | 653 -- ...leCompositionEditorSampleItemProvider.java | 198 - ...tionExtensionEditorSampleItemProvider.java | 191 - .../provider/TextSampleItemProvider.java | 195 - .../TextSampleWithTwoTabsItemProvider.java | 219 - .../provider/TextareaSampleItemProvider.java | 195 - .../provider/TotalSampleItemProvider.java | 698 -- .../AbstractEnabledSampleItemProvider.java | 152 - .../ReferenceEnabledSampleItemProvider.java | 139 - .../ReferencesItemProviderAdapterFactory.java | 227 - .../provider/TestsItemProvider.java | 130 - ...ckBoxExtendedEditorSampleItemProvider.java | 163 - .../EefnrextItemProviderAdapterFactory.java | 251 - ...renceExtendedEditorSampleItemProvider.java | 194 - ...rgetExtensionEditorSampleItemProvider.java | 130 - .../RemoveSingleCompositionEditorAction.java | 78 - .../nonreg/edit/actions/SampleAction.java | 78 - .../.classpath | 7 - .../.gitignore | 1 - .../.project | 28 - .../META-INF/MANIFEST.MF | 19 - .../build.properties | 14 - .../full/obj16/CustomNamingModelFile.gif | Bin 346 -> 0 bytes .../icons/full/obj16/EefnrModelFile.gif | Bin 346 -> 0 bytes .../icons/full/obj16/EefnrextModelFile.gif | Bin 346 -> 0 bytes .../icons/full/obj16/FiltersModelFile.gif | Bin 346 -> 0 bytes .../icons/full/obj16/InterfaceModelFile.gif | Bin 346 -> 0 bytes .../icons/full/obj16/NavigationModelFile.gif | Bin 346 -> 0 bytes .../icons/full/obj16/ReferencesModelFile.gif | Bin 346 -> 0 bytes .../icons/full/wizban/NewCustomNaming.gif | Bin 2462 -> 0 bytes .../icons/full/wizban/NewEefnr.gif | Bin 2462 -> 0 bytes .../icons/full/wizban/NewEefnrext.gif | Bin 2462 -> 0 bytes .../icons/full/wizban/NewFilters.gif | Bin 2462 -> 0 bytes .../icons/full/wizban/NewInterface.gif | Bin 2462 -> 0 bytes .../icons/full/wizban/NewNavigation.gif | Bin 2462 -> 0 bytes .../icons/full/wizban/NewReferences.gif | Bin 2462 -> 0 bytes .../plugin.properties | 93 - .../plugin.xml | 40 - .../pom.xml | 28 - .../FiltersActionBarContributor.java | 429 - .../filters/presentation/FiltersEditor.java | 1836 ---- .../presentation/FiltersModelWizard.java | 633 -- .../InterfaceActionBarContributor.java | 429 - .../presentation/InterfaceEditor.java | 1836 ---- .../presentation/InterfaceModelWizard.java | 633 -- .../CustomNamingActionBarContributor.java | 429 - .../presentation/CustomNamingEditor.java | 1836 ---- .../presentation/CustomNamingModelWizard.java | 633 -- .../NavigationActionBarContributor.java | 429 - .../presentation/NavigationEditor.java | 1836 ---- .../presentation/NavigationModelWizard.java | 633 -- .../EefnrActionBarContributor.java | 427 - .../eef/eefnr/presentation/EefnrEditor.java | 1466 ---- .../eefnr/presentation/EefnrEditorPlugin.java | 95 - .../eefnr/presentation/EefnrModelWizard.java | 631 -- .../ReferencesActionBarContributor.java | 429 - .../presentation/ReferencesEditor.java | 1836 ---- .../presentation/ReferencesModelWizard.java | 633 -- .../EefnrextActionBarContributor.java | 429 - .../eefnrext/presentation/EefnrextEditor.java | 1836 ---- .../presentation/EefnrextModelWizard.java | 633 -- .../.classpath | 8 - .../.gitignore | 2 - .../.project | 28 - .../.settings/org.eclipse.jdt.core.prefs | 12 - .../META-INF/MANIFEST.MF | 13 - .../build.properties | 18 - .../addAdvTableCompoOnAbstractRef.modelingbot | 28 - .../addTableCompo.modelingbot | 32 - .../cancelAddTableCompo.modelingbot | 33 - .../cancelSetReferenceAEOFCV.modelingbot | 29 - ...cancelSetReferenceFlatRefTable.modelingbot | 29 - .../cancelSetReferenceRefTable.modelingbot | 29 - .../redoAddTableCompo.modelingbot | 38 - .../redoSetAttributeRadio.modelingbot | 31 - .../redoSetReferenceAEOFCV.modelingbot | 34 - .../redoSetReferenceFlatRefTable.modelingbot | 34 - .../redoSetReferenceRefTable.modelingbot | 34 - .../removeTableCompo.modelingbot | 37 - .../setAttributeRadio.modelingbot | 25 - .../setReferenceAEOFCV.modelingbot | 28 - .../setReferenceFlatRefTable.modelingbot | 28 - .../setReferenceRefTable.modelingbot | 32 - .../undoAddTableCompo.modelingbot | 35 - .../undoSetAttributeRadio.modelingbot | 28 - .../undoSetReferenceAEOFCV.modelingbot | 31 - .../undoSetReferenceFlatRefTable.modelingbot | 31 - .../undoSetReferenceRefTable.modelingbot | 31 - .../unsetAEOFCV.modelingbot | 34 - .../unsetEOFCV.modelingbot | 34 - .../unsetFlatRefTable.modelingbot | 34 - .../unsetRefTable.modelingbot | 34 - .../unsetReferenceAEOFCV.modelingbot | 34 - .../unsetReferenceEOFCV.modelingbot | 34 - .../unsetReferenceFlatRefTable.modelingbot | 34 - .../unsetReferenceRefTable.modelingbot | 34 - .../addTableCompo.modelingbot | 34 - .../cancelAddTableCompo.modelingbot | 35 - .../cancelSetReferenceAEOFCV.modelingbot | 29 - ...cancelSetReferenceFlatRefTable.modelingbot | 31 - .../cancelSetReferenceRefTable.modelingbot | 31 - .../editSetReferenceAEOFCV.modelingbot | 40 - .../editSetReferenceFlatRefTable.modelingbot | 40 - .../editSetReferenceRefTable.modelingbot | 40 - .../moveTableCompo.modelingbot | 34 - .../redoAddTableCompo.modelingbot | 40 - .../redoSetAttributeRadio.modelingbot | 33 - .../redoSetReferenceAEOFCV.modelingbot | 36 - .../redoSetReferenceFlatRefTable.modelingbot | 36 - .../redoSetReferenceRefTable.modelingbot | 36 - .../removeTableCompo.modelingbot | 39 - .../setAttributeRadio.modelingbot | 27 - .../setReferenceAEOFCV.modelingbot | 30 - .../setReferenceFlatRefTable.modelingbot | 30 - .../setReferenceRefTable.modelingbot | 34 - .../undoAddTableCompo.modelingbot | 37 - .../undoSetAttributeRadio.modelingbot | 30 - .../undoSetReferenceAEOFCV.modelingbot | 33 - .../undoSetReferenceFlatRefTable.modelingbot | 33 - .../undoSetReferenceRefTable.modelingbot | 33 - .../unsetAEOFCV.modelingbot | 36 - .../unsetCombo.modelingbot | 36 - .../unsetEOFCV.modelingbot | 36 - .../unsetFlatRefTable.modelingbot | 36 - .../unsetRefTable.modelingbot | 36 - .../unsetReferenceAEOFCV.modelingbot | 36 - .../unsetReferenceCombo.modelingbot | 36 - .../unsetReferenceEOFCV.modelingbot | 36 - .../unsetReferenceFlatRefTable.modelingbot | 36 - .../unsetReferenceRefTable.modelingbot | 36 - .../addTableComposition.modelingbot | 34 - .../cancelAddTableComposition.modelingbot | 36 - .../cancelSetReferenceAEOFCV.modelingbot | 31 - ...cancelSetReferenceFlatRefTable.modelingbot | 31 - .../cancelSetReferenceRefTable.modelingbot | 31 - .../editSetReferenceAEOFCV.modelingbot | 38 - .../editSetReferenceFlatRefTable.modelingbot | 38 - .../redoAddTableComposition.modelingbot | 28 - .../redoSetAttributeRadio.modelingbot | 32 - .../redoSetReferenceAEOFCV.modelingbot | 35 - .../redoSetReferenceFlatRefTable.modelingbot | 36 - .../redoSetReferenceRefTable.modelingbot | 34 - .../removeTableComposition.modelingbot | 23 - .../setAttributeRadio.modelingbot | 27 - .../setReferenceAEOFCV.modelingbot | 30 - .../setReferenceFlatRefTable.modelingbot | 30 - .../setReferenceRefTable.modelingbot | 34 - .../undoAddTableComposition.modelingbot | 37 - .../undoSetAttributeRadio.modelingbot | 28 - .../undoSetReferenceAEOFCV.modelingbot | 32 - .../undoSetReferenceFlatRefTable.modelingbot | 32 - .../undoSetReferenceRefTable.modelingbot | 35 - .../wizard_nonreg/unsetAEOFCV.modelingbot | 42 - .../wizard_nonreg/unsetEOFCV.modelingbot | 43 - .../unsetFlatReferencesTable.modelingbot | 43 - .../unsetReferenceAEOFCV.modelingbot | 42 - .../unsetReferenceFlatRefTable.modelingbot | 42 - .../unsetReferenceRefTable.modelingbot | 42 - .../unsetReferencesTable.modelingbot | 43 - .../wizard_nonreg/unsetTextArea.modelingbot | 37 - .../pom.xml | 85 - .../src-mbot/log4j.xml | 60 - .../emf/eef/tests/nonreg/AllTests.java | 209 - ...osedMBotAddAdvTableCompoOnAbstractRef.java | 22 - .../ComposedMBotAddTableCompo.java | 22 - .../ComposedMBotCancelAddTableCompo.java | 22 - .../ComposedMBotCancelSetReferenceAEOFCV.java | 22 - ...sedMBotCancelSetReferenceFlatRefTable.java | 22 - ...omposedMBotCancelSetReferenceRefTable.java | 22 - .../ComposedMBotRedoAddTableCompo.java | 22 - .../ComposedMBotRedoSetAttributeRadio.java | 22 - .../ComposedMBotRedoSetReferenceAEOFCV.java | 22 - ...posedMBotRedoSetReferenceFlatRefTable.java | 22 - .../ComposedMBotRedoSetReferenceRefTable.java | 22 - .../ComposedMBotRemoveTableCompo.java | 22 - .../ComposedMBotSetAttributeRadio.java | 22 - .../ComposedMBotSetReferenceAEOFCV.java | 22 - .../ComposedMBotSetReferenceFlatRefTable.java | 22 - .../ComposedMBotSetReferenceRefTable.java | 22 - .../ComposedMBotUndoAddTableCompo.java | 22 - .../ComposedMBotUndoSetAttributeRadio.java | 22 - .../ComposedMBotUndoSetReferenceAEOFCV.java | 22 - ...posedMBotUndoSetReferenceFlatRefTable.java | 22 - .../ComposedMBotUndoSetReferenceRefTable.java | 22 - .../detailsview/ComposedMBotUnsetAEOFCV.java | 22 - .../detailsview/ComposedMBotUnsetEOFCV.java | 22 - .../ComposedMBotUnsetFlatRefTable.java | 22 - .../ComposedMBotUnsetRefTable.java | 22 - .../ComposedMBotUnsetReferenceAEOFCV.java | 22 - .../ComposedMBotUnsetReferenceEOFCV.java | 22 - ...omposedMBotUnsetReferenceFlatRefTable.java | 22 - .../ComposedMBotUnsetReferenceRefTable.java | 22 - .../PViewMBotAddTableComposition.java | 22 - .../PViewMBotCancelAddTableComposition.java | 22 - .../PViewMBotCancelSetReferenceAEOFCV.java | 22 - ...iewMBotCancelSetReferenceFlatRefTable.java | 22 - .../PViewMBotCancelSetReferenceRefTable.java | 22 - .../PViewMBotEditSetReferenceAEOFCV.java | 22 - ...PViewMBotEditSetReferenceFlatRefTable.java | 22 - .../PViewMBotEditSetReferenceRefTable.java | 22 - .../PViewMBotMoveTableComposition.java | 22 - .../PViewMBotRedoAddTableComposition.java | 22 - .../PViewMBotRedoSetAttributeRadio.java | 22 - .../PViewMBotRedoSetReferenceAEOFCV.java | 22 - ...PViewMBotRedoSetReferenceFlatRefTable.java | 22 - .../PViewMBotRedoSetReferenceRefTable.java | 22 - .../PViewMBotRemoveTableComposition.java | 22 - .../PViewMBotSetAttributeRadio.java | 22 - .../PViewMBotSetReferenceAEOFCV.java | 22 - .../PViewMBotSetReferenceFlatRefTable.java | 22 - .../PViewMBotSetReferenceRefTable.java | 22 - .../PViewMBotUndoAddTableComposition.java | 22 - .../PViewMBotUndoSetAttributeRadio.java | 22 - .../PViewMBotUndoSetReferenceAEOFCV.java | 22 - .../PViewMBotUndoSetReferenceCombo.java | 22 - ...PViewMBotUndoSetReferenceFlatRefTable.java | 22 - .../PViewMBotUndoSetReferenceRefTable.java | 22 - .../propertiesView/PViewMBotUnsetAEOFCV.java | 22 - .../propertiesView/PViewMBotUnsetEOFCV.java | 22 - .../PViewMBotUnsetFlatReferencesTable.java | 22 - .../PViewMBotUnsetReferenceAEOFCV.java | 22 - .../PViewMBotUnsetReferenceEOFCV.java | 22 - .../PViewMBotUnsetReferenceFlatRefTable.java | 22 - .../PViewMBotUnsetReferenceRefTable.java | 22 - .../PViewMBotUnsetReferencesTable.java | 22 - .../wizard/WizardMBotAddTableComposition.java | 22 - .../WizardMBotCancelAddTableComposition.java | 22 - .../WizardMBotCancelSetReferenceAEOFCV.java | 22 - ...ardMBotCancelSetReferenceFlatRefTable.java | 22 - .../WizardMBotCancelSetReferenceRefTable.java | 22 - .../WizardMBotEditSetReferenceAEOFCV.java | 22 - ...izardMBotEditSetReferenceFlatRefTable.java | 22 - .../WizardMBotRedoAddTableComposition.java | 22 - .../WizardMBotRedoSetAttributeRadio.java | 22 - .../WizardMBotRedoSetReferenceAEOFCV.java | 22 - ...izardMBotRedoSetReferenceFlatRefTable.java | 22 - .../WizardMBotRedoSetReferenceRefTable.java | 22 - .../WizardMBotRemoveTableComposition.java | 22 - .../wizard/WizardMBotSetAttributeRadio.java | 22 - .../wizard/WizardMBotSetReferenceAEOFCV.java | 22 - .../WizardMBotSetReferenceFlatRefTable.java | 22 - .../WizardMBotSetReferenceRefTable.java | 22 - .../WizardMBotUndoAddTableComposition.java | 22 - .../WizardMBotUndoSetAttributeRadio.java | 22 - .../WizardMBotUndoSetReferenceAEOFCV.java | 22 - ...izardMBotUndoSetReferenceFlatRefTable.java | 22 - .../WizardMBotUndoSetReferenceRefTable.java | 22 - .../nonreg/wizard/WizardMBotUnsetAEOFCV.java | 22 - .../nonreg/wizard/WizardMBotUnsetEOFCV.java | 22 - .../WizardMBotUnsetFlatReferencesTable.java | 22 - .../WizardMBotUnsetReferenceAEOFCV.java | 22 - .../WizardMBotUnsetReferenceFlatRefTable.java | 22 - .../WizardMBotUnsetReferenceRefTable.java | 22 - .../WizardMBotUnsetReferencesTable.java | 22 - .../wizard/WizardMBotUnsetTextArea.java | 22 - .../TestCompositionSequence.java | 162 - .../.classpath | 7 - .../.gitignore | 1 - .../org.eclipse.emf.eef.tests.nonreg/.project | 28 - .../META-INF/MANIFEST.MF | 33 - .../build.properties | 14 - .../model/eefnr.ecore | 412 - .../model/eefnr.genmodel | 293 - .../model/eefnrext.ecore | 17 - .../plugin.properties | 8 - .../plugin.xml | 62 - .../org.eclipse.emf.eef.tests.nonreg/pom.xml | 28 - .../eclipse/emf/eef/eefnr/AbstractSample.java | 54 - ...ompositionTargetExtensionEditorSample.java | 21 - .../AdvancedEObjectFlatComboViewerSample.java | 107 - .../eefnr/AdvancedReferencesTableSample.java | 78 - .../AdvancedTableCompositionEditorSample.java | 78 - .../eclipse/emf/eef/eefnr/CheckboxSample.java | 107 - .../emf/eef/eefnr/EMFComboViewerSample.java | 116 - .../eclipse/emf/eef/eefnr/ENUM_SAMPLE.java | 239 - .../eefnr/EObjectFlatComboViewerSample.java | 107 - .../eef/eefnr/EReferencesViewerSample.java | 78 - .../eclipse/emf/eef/eefnr/EefnrFactory.java | 262 - .../eclipse/emf/eef/eefnr/EefnrPackage.java | 4216 --------- .../eef/eefnr/FlatReferencesTableSample.java | 78 - .../emf/eef/eefnr/ImageViewerSample.java | 107 - .../LinkEObjectFlatComboViewerSample.java | 107 - .../eef/eefnr/LinkEReferenceViewerSample.java | 107 - .../eef/eefnr/MultiValuedEditorSample.java | 78 - .../eclipse/emf/eef/eefnr/NamedElement.java | 21 - .../eclipse/emf/eef/eefnr/RadioSample.java | 116 - .../emf/eef/eefnr/ReferencesTableSample.java | 78 - .../src/org/eclipse/emf/eef/eefnr/Root.java | 45 - .../src/org/eclipse/emf/eef/eefnr/Sample.java | 80 - .../emf/eef/eefnr/SelectionDialogSample.java | 107 - .../eefnr/SingleCompositionEditorSample.java | 134 - .../eefnr/SingleCompositionViewerSample.java | 161 - .../eefnr/TableCompositionEditorSample.java | 78 - ...TableCompositionExtensionEditorSample.java | 61 - .../org/eclipse/emf/eef/eefnr/TextSample.java | 107 - .../emf/eef/eefnr/TextSampleWithTwoTabs.java | 134 - .../eclipse/emf/eef/eefnr/TextareaSample.java | 107 - .../eclipse/emf/eef/eefnr/TotalSample.java | 621 -- .../filters/AbstractReferenceOwnerSample.java | 45 - .../AbstractReferenceTargetSample.java | 22 - .../filters/ConcreteReferenceOwnerSample.java | 95 - .../ConcreteReferenceTargetSample1.java | 21 - .../ConcreteReferenceTargetSample2.java | 21 - .../ConcreteReferenceTargetSample3.java | 21 - .../emf/eef/eefnr/filters/FiltersFactory.java | 73 - .../emf/eef/eefnr/filters/FiltersPackage.java | 525 -- .../AbstractReferenceOwnerSampleImpl.java | 134 - .../AbstractReferenceTargetSampleImpl.java | 43 - .../ConcreteReferenceOwnerSampleImpl.java | 240 - .../ConcreteReferenceTargetSample1Impl.java | 42 - .../ConcreteReferenceTargetSample2Impl.java | 42 - .../ConcreteReferenceTargetSample3Impl.java | 43 - .../filters/impl/FiltersFactoryImpl.java | 135 - .../filters/impl/FiltersPackageImpl.java | 366 - .../filters/util/FiltersAdapterFactory.java | 237 - .../eef/eefnr/filters/util/FiltersSwitch.java | 250 - .../eef/eefnr/impl/AbstractSampleImpl.java | 163 - ...sitionTargetExtensionEditorSampleImpl.java | 42 - ...ancedEObjectFlatComboViewerSampleImpl.java | 278 - .../AdvancedReferencesTableSampleImpl.java | 201 - ...ancedTableCompositionEditorSampleImpl.java | 222 - .../eef/eefnr/impl/CheckboxSampleImpl.java | 271 - .../eefnr/impl/EMFComboViewerSampleImpl.java | 272 - .../EObjectFlatComboViewerSampleImpl.java | 277 - .../impl/EReferencesViewerSampleImpl.java | 204 - .../emf/eef/eefnr/impl/EefnrFactoryImpl.java | 436 - .../emf/eef/eefnr/impl/EefnrPackageImpl.java | 1923 ----- .../impl/FlatReferencesTableSampleImpl.java | 201 - .../eef/eefnr/impl/ImageViewerSampleImpl.java | 271 - .../LinkEObjectFlatComboViewerSampleImpl.java | 281 - .../impl/LinkEReferenceViewerSampleImpl.java | 281 - .../impl/MultiValuedEditorSampleImpl.java | 220 - .../emf/eef/eefnr/impl/NamedElementImpl.java | 42 - .../emf/eef/eefnr/impl/RadioSampleImpl.java | 272 - .../eefnr/impl/ReferencesTableSampleImpl.java | 201 - .../eclipse/emf/eef/eefnr/impl/RootImpl.java | 151 - .../emf/eef/eefnr/impl/SampleImpl.java | 217 - .../eefnr/impl/SelectionDialogSampleImpl.java | 271 - .../SingleCompositionEditorSampleImpl.java | 378 - .../SingleCompositionViewerSampleImpl.java | 441 - .../TableCompositionEditorSampleImpl.java | 222 - ...eCompositionExtensionEditorSampleImpl.java | 186 - .../emf/eef/eefnr/impl/TextSampleImpl.java | 271 - .../eefnr/impl/TextSampleWithTwoTabsImpl.java | 325 - .../eef/eefnr/impl/TextareaSampleImpl.java | 271 - .../emf/eef/eefnr/impl/TotalSampleImpl.java | 1337 --- .../eefnr/interface_/InterfaceFactory.java | 46 - .../eefnr/interface_/InterfacePackage.java | 124 - .../eef/eefnr/interface_/SimpleSample.java | 22 - .../interface_/impl/InterfaceFactoryImpl.java | 100 - .../interface_/impl/InterfacePackageImpl.java | 196 - .../interface_/impl/SimpleSampleImpl.java | 43 - .../util/InterfaceAdapterFactory.java | 124 - .../interface_/util/InterfaceSwitch.java | 115 - .../eef/eefnr/naming/CustomNamingFactory.java | 46 - .../eef/eefnr/naming/CustomNamingPackage.java | 134 - .../eclipse/emf/eef/eefnr/naming/Event.java | 22 - .../naming/impl/CustomNamingFactoryImpl.java | 100 - .../naming/impl/CustomNamingPackageImpl.java | 200 - .../emf/eef/eefnr/naming/impl/EventImpl.java | 43 - .../util/CustomNamingAdapterFactory.java | 143 - .../eefnr/naming/util/CustomNamingSwitch.java | 132 - .../eef/eefnr/navigation/AnotherSubType.java | 53 - .../eefnr/navigation/AttributeDelegate.java | 81 - .../navigation/AttributeNavigationSample.java | 72 - ...DeferedFlatReferenceTableEditorSample.java | 45 - .../eefnr/navigation/DeferedReference.java | 55 - .../DeferedReferenceTableEditorSample.java | 45 - .../emf/eef/eefnr/navigation/Element.java | 55 - .../navigation/FirstModelNavigation.java | 127 - .../eefnr/navigation/MultipleReferencer.java | 162 - .../eefnr/navigation/NavigationFactory.java | 163 - .../eefnr/navigation/NavigationPackage.java | 1896 ----- .../emf/eef/eefnr/navigation/Owner.java | 72 - .../emf/eef/eefnr/navigation/Referencer.java | 99 - .../navigation/SecondModelNavigation.java | 81 - .../eefnr/navigation/SingleReferencer.java | 330 - .../SmartModelNavigationSample.java | 117 - .../emf/eef/eefnr/navigation/Subtype.java | 53 - .../navigation/impl/AnotherSubTypeImpl.java | 163 - .../impl/AttributeDelegateImpl.java | 218 - .../impl/AttributeNavigationSampleImpl.java | 219 - ...redFlatReferenceTableEditorSampleImpl.java | 151 - .../navigation/impl/DeferedReferenceImpl.java | 158 - ...DeferedReferenceTableEditorSampleImpl.java | 151 - .../eefnr/navigation/impl/ElementImpl.java | 164 - .../impl/FirstModelNavigationImpl.java | 348 - .../impl/MultipleReferencerImpl.java | 423 - .../impl/NavigationFactoryImpl.java | 252 - .../impl/NavigationPackageImpl.java | 928 -- .../eef/eefnr/navigation/impl/OwnerImpl.java | 218 - .../impl/SecondModelNavigationImpl.java | 217 - .../navigation/impl/SingleReferencerImpl.java | 765 -- .../impl/SmartModelNavigationSampleImpl.java | 328 - .../eefnr/navigation/impl/SubtypeImpl.java | 163 - .../util/NavigationAdapterFactory.java | 405 - .../navigation/util/NavigationSwitch.java | 446 - .../references/AbstractEnabledSample.java | 54 - .../references/ReferenceEnabledSample.java | 45 - .../eefnr/references/ReferencesFactory.java | 55 - .../eefnr/references/ReferencesPackage.java | 298 - .../emf/eef/eefnr/references/Tests.java | 22 - .../impl/AbstractEnabledSampleImpl.java | 164 - .../impl/ReferenceEnabledSampleImpl.java | 133 - .../impl/ReferencesFactoryImpl.java | 112 - .../impl/ReferencesPackageImpl.java | 268 - .../eef/eefnr/references/impl/TestsImpl.java | 43 - .../util/ReferencesAdapterFactory.java | 199 - .../references/util/ReferencesSwitch.java | 195 - .../eef/eefnr/util/EefnrAdapterFactory.java | 633 -- .../emf/eef/eefnr/util/EefnrSwitch.java | 730 -- .../CheckBoxExtendedEditorSample.java | 54 - .../emf/eef/eefnrext/EefnrextFactory.java | 64 - .../emf/eef/eefnrext/EefnrextPackage.java | 348 - .../FlatReferenceExtendedEditorSample.java | 100 - ...ompositionTargetExtensionEditorSample.java | 22 - .../CheckBoxExtendedEditorSampleImpl.java | 163 - .../eefnrext/impl/EefnrextFactoryImpl.java | 124 - .../eefnrext/impl/EefnrextPackageImpl.java | 292 - ...FlatReferenceExtendedEditorSampleImpl.java | 254 - ...sitionTargetExtensionEditorSampleImpl.java | 43 - .../eefnrext/util/EefnrextAdapterFactory.java | 200 - .../emf/eef/eefnrext/util/EefnrextSwitch.java | 196 - .../.classpath | 7 - .../.gitignore | 2 - .../.project | 28 - .../META-INF/MANIFEST.MF | 18 - .../build.properties | 15 - .../CreateConference_participants_Person.gif | Bin 223 -> 0 bytes .../ctool16/CreateConference_sites_Site.gif | Bin 223 -> 0 bytes .../ctool16/CreateConference_talks_Talk.gif | Bin 223 -> 0 bytes .../ctool16/CreateConference_topics_Topic.gif | Bin 223 -> 0 bytes ...reateEclipseSummit_participants_Person.gif | Bin 223 -> 0 bytes .../CreateEclipseSummit_sites_Site.gif | Bin 223 -> 0 bytes .../CreateEclipseSummit_talks_Talk.gif | Bin 223 -> 0 bytes .../CreateEclipseSummit_topics_Topic.gif | Bin 223 -> 0 bytes .../full/ctool16/CreateSite_rooms_Room.gif | Bin 223 -> 0 bytes .../icons/full/obj16/Conference.gif | Bin 129 -> 0 bytes .../icons/full/obj16/EclipseSummit.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Person.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Room.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Site.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Talk.gif | Bin 129 -> 0 bytes .../icons/full/obj16/Topic.gif | Bin 129 -> 0 bytes .../models/conference-editor.components | 64 - .../models/conference-editor.eefgen | 9 - .../models/conference.components | 244 - .../models/conference.eefgen | 9 - .../plugin.properties | 87 - .../plugin.xml | 162 - .../org.eclipse.emf.examples.eef.edit/pom.xml | 28 - .../src-gen/conference_properties.plugin.xml | 143 - ...ferenceBasePropertiesEditionComponent.java | 242 - ...ocalisationPropertiesEditionComponent.java | 290 - ...articipantsPropertiesEditionComponent.java | 262 - .../ConferencePropertiesEditionComponent.java | 192 - ...ksAndTopicsPropertiesEditionComponent.java | 319 - .../PersonBasePropertiesEditionComponent.java | 342 - ...sonPresencePropertiesEditionComponent.java | 236 - .../PersonPropertiesEditionComponent.java | 138 - .../RoomPropertiesEditionComponent.java | 224 - .../SitePropertiesEditionComponent.java | 309 - .../TalkPropertiesEditionComponent.java | 439 - .../TopicPropertiesEditionComponent.java | 268 - .../ConferencePropertiesEditionPart.java | 68 - .../parts/ConferenceViewsRepository.java | 218 - .../LocalisationPropertiesEditionPart.java | 102 - .../ParticipantsPropertiesEditionPart.java | 88 - .../parts/PersonPropertiesEditionPart.java | 131 - .../parts/PresencePropertiesEditionPart.java | 86 - .../parts/RoomPropertiesEditionPart.java | 68 - .../parts/SitePropertiesEditionPart.java | 116 - .../parts/TalkPropertiesEditionPart.java | 238 - .../TalksAndTopicsPropertiesEditionPart.java | 132 - .../parts/TopicPropertiesEditionPart.java | 94 - .../ConferencePropertiesEditionPartForm.java | 377 - ...LocalisationPropertiesEditionPartForm.java | 394 - ...ParticipantsPropertiesEditionPartForm.java | 279 - .../PersonPropertiesEditionPartForm.java | 742 -- .../PresencePropertiesEditionPartForm.java | 345 - .../forms/RoomPropertiesEditionPartForm.java | 384 - .../forms/SitePropertiesEditionPartForm.java | 516 -- .../forms/TalkPropertiesEditionPartForm.java | 852 -- ...lksAndTopicsPropertiesEditionPartForm.java | 403 - .../forms/TopicPropertiesEditionPartForm.java | 494 -- .../ConferencePropertiesEditionPartImpl.java | 322 - ...LocalisationPropertiesEditionPartImpl.java | 366 - ...ParticipantsPropertiesEditionPartImpl.java | 271 - .../impl/PersonPropertiesEditionPartImpl.java | 671 -- .../PresencePropertiesEditionPartImpl.java | 333 - .../impl/RoomPropertiesEditionPartImpl.java | 334 - .../impl/SitePropertiesEditionPartImpl.java | 462 - .../impl/TalkPropertiesEditionPartImpl.java | 774 -- ...lksAndTopicsPropertiesEditionPartImpl.java | 395 - .../impl/TopicPropertiesEditionPartImpl.java | 436 - .../provider/ConferenceEditPlugin.java | 92 - .../provider/ConferenceItemProvider.java | 267 - .../ConferenceItemProviderAdapterFactory.java | 321 - .../provider/PersonItemProvider.java | 301 - .../conference/provider/RoomItemProvider.java | 182 - .../conference/provider/SiteItemProvider.java | 222 - .../conference/provider/TalkItemProvider.java | 275 - .../provider/TopicItemProvider.java | 206 - .../ConferenceEEFAdapterFactory.java | 72 - .../providers/ConferenceMessages.java | 255 - ...nferencePropertiesEditionPartProvider.java | 127 - .../ConferencePropertiesEditionProvider.java | 169 - .../PersonPropertiesEditionProvider.java | 157 - .../RoomPropertiesEditionProvider.java | 150 - .../SitePropertiesEditionProvider.java | 150 - .../TalkPropertiesEditionProvider.java | 150 - .../TopicPropertiesEditionProvider.java | 150 - .../providers/conferenceMessages.properties | 88 - .../conferenceMessages_fr.properties | 88 - .../.classpath | 7 - .../.gitignore | 2 - .../.project | 28 - .../META-INF/MANIFEST.MF | 18 - .../build.properties | 14 - .../icons/full/obj16/ConferenceModelFile.gif | Bin 346 -> 0 bytes .../icons/full/wizban/NewConference.gif | Bin 2462 -> 0 bytes .../plugin.properties | 57 - .../plugin.xml | 39 - .../pom.xml | 28 - .../ConferenceActionBarContributor.java | 427 - .../presentation/ConferenceEditor.java | 1778 ---- .../presentation/ConferenceEditorPlugin.java | 95 - .../presentation/ConferenceModelWizard.java | 631 -- .../.classpath | 7 - .../.gitignore | 4 - .../.project | 28 - .../META-INF/MANIFEST.MF | 16 - .../build.properties | 5 - .../models/input/input.conference | 13 - .../addAdvTableCompo.modelingbot | 37 - .../cancelAddAdvTableCompo.modelingbot | 38 - .../cancelSetAttributeMVE.modelingbot | 27 - .../cancelSetReferenceAdvRefTable.modelingbot | 42 - .../cancelSetReferenceEOFCV.modelingbot | 37 - .../redoAddAdvTableCompo.modelingbot | 42 - .../redoSetAttributeCheckbox.modelingbot | 29 - ...redoSetAttributeEMFComboViewer.modelingbot | 29 - .../redoSetAttributeMVE.modelingbot | 32 - .../redoSetAttributeText.modelingbot | 34 - .../redoSetAttributeTextArea.modelingbot | 29 - .../redoSetReferenceAdvRefTable.modelingbot | 46 - .../redoSetReferenceEOFCV.modelingbot | 41 - .../removeAdvTableCompo.modelingbot | 42 - .../setAttributeCheckbox.modelingbot | 25 - .../setAttributeEMFComboViewer.modelingbot | 25 - .../setAttributeInteger.modelingbot | 25 - .../setAttributeMVE.modelingbot | 26 - .../setAttributeText.modelingbot | 25 - .../setAttributeTextArea.modelingbot | 25 - .../setReferenceAdvRefTable.modelingbot | 41 - .../setReferenceAdvRefTable2.modelingbot | 50 - .../setReferenceEOFCV.modelingbot | 36 - .../undoAddAdvTableCompo.modelingbot | 38 - .../undoSetAttributeCheckbox.modelingbot | 26 - ...undoSetAttributeEMFComboViewer.modelingbot | 26 - .../undoSetAttributeMVE.modelingbot | 30 - .../undoSetAttributeText.modelingbot | 31 - .../undoSetAttributeTextArea.modelingbot | 26 - .../undoSetReferenceAdvRefTable.modelingbot | 43 - .../undoSetReferenceEOFCV.modelingbot | 38 - .../unsetAdvRefTable.modelingbot | 56 - .../unsetAttributeMVE.modelingbot | 34 - .../unsetAttributeText.modelingbot | 32 - .../unsetAttributeTextArea.modelingbot | 32 - .../unsetMVE.modelingbot | 32 - .../unsetReferenceAdvRefTable.modelingbot | 55 - .../unsetText.modelingbot | 31 - .../unsetTextArea.modelingbot | 31 - .../addAdvTableCompo.modelingbot | 39 - .../cancelAddAdvTableCompo.modelingbot | 40 - .../cancelSetAttributeMVE.modelingbot | 29 - .../cancelSetReferenceAdvRefTable.modelingbot | 44 - .../cancelSetReferenceEOFCV.modelingbot | 39 - .../editSetReferenceAdvRefTable.modelingbot | 63 - .../editSetReferenceEOFCV.modelingbot | 93 - .../moveAdvTableCompo.modelingbot | 58 - .../redoAddAdvTableCompo.modelingbot | 44 - .../redoSetAttributeCheckbox.modelingbot | 31 - ...redoSetAttributeEMFComboViewer.modelingbot | 30 - .../redoSetAttributeMVE.modelingbot | 34 - .../redoSetAttributeText.modelingbot | 36 - .../redoSetAttributeTextArea.modelingbot | 31 - .../redoSetReferenceAdvRefTable.modelingbot | 48 - .../redoSetReferenceEOFCV.modelingbot | 43 - .../removeAdvTableCompo.modelingbot | 44 - .../setAttributeCheckbox.modelingbot | 27 - .../setAttributeEMFComboViewer.modelingbot | 27 - .../setAttributeInteger.modelingbot | 27 - .../setAttributeMVE.modelingbot | 28 - .../setAttributeText.modelingbot | 27 - .../setAttributeTextArea.modelingbot | 27 - .../setReferenceAdvRefTable.modelingbot | 43 - .../setReferenceEOFCV.modelingbot | 38 - .../undoAddAdvTableCompo.modelingbot | 40 - .../undoSetAttributeCheckbox.modelingbot | 28 - ...undoSetAttributeEMFComboViewer.modelingbot | 28 - .../undoSetAttributeMVE.modelingbot | 32 - .../undoSetAttributeText.modelingbot | 33 - .../undoSetAttributeTextArea.modelingbot | 28 - .../undoSetReferenceAdvRefTable.modelingbot | 45 - .../undoSetReferenceEOFCV.modelingbot | 40 - .../unsetAdvRefTable.modelingbot | 58 - .../unsetAttributeMVE.modelingbot | 36 - .../unsetAttributeText.modelingbot | 34 - .../unsetAttributeTextArea.modelingbot | 34 - .../unsetMVE.modelingbot | 34 - .../unsetReferenceAdvRefTable.modelingbot | 57 - .../unsetText.modelingbot | 33 - .../unsetTextArea.modelingbot | 33 - .../addAdvancedTableComposition.modelingbot | 45 - ...celAddAdvancedTableComposition.modelingbot | 47 - .../cancelSetAttributeMVE.modelingbot | 34 - .../cancelSetReferenceAdvRefTable.modelingbot | 49 - .../cancelSetReferenceEOFCV.modelingbot | 63 - .../editSetReferenceAdvRefTable.modelingbot | 61 - .../editSetReferenceEOFCV.modelingbot | 94 - .../redoAddAdvTableCompo.modelingbot | 51 - .../redoSetAttributeCheckbox.modelingbot | 37 - ...redoSetAttributeEMFComboViewer.modelingbot | 38 - .../redoSetAttributeMVE.modelingbot | 39 - .../redoSetAttributeText.modelingbot | 32 - .../redoSetAttributeTextArea.modelingbot | 32 - .../redoSetReferenceAdvRefTable.modelingbot | 54 - .../redoSetReferenceEOFCV.modelingbot | 68 - ...removeAdvancedTableComposition.modelingbot | 46 - .../setAttributeCheckbox.modelingbot | 32 - .../setAttributeEMFComboViewer.modelingbot | 32 - .../setAttributeMVE.modelingbot | 33 - .../setAttributeText.modelingbot | 27 - .../setAttributeTextArea.modelingbot | 27 - .../setReferenceAdvRefTable.modelingbot | 48 - .../setReferenceEOFCV.modelingbot | 62 - .../undoAddAdvTableCompo.modelingbot | 48 - .../undoSetAttributeCheckbox.modelingbot | 35 - ...undoSetAttributeEMFComboViewer.modelingbot | 34 - .../undoSetAttributeMVE.modelingbot | 35 - .../undoSetAttributeText.modelingbot | 29 - .../undoSetAttributeTextArea.modelingbot | 29 - .../undoSetReferenceAdvRefTable.modelingbot | 50 - .../undoSetReferenceEOFCV.modelingbot | 64 - .../unsetAdvancedReferencesTable.modelingbot | 49 - .../unsetAttributeMVE.modelingbot | 41 - .../unsetAttributeText.modelingbot | 39 - .../unsetAttributeTextArea.modelingbot | 39 - .../unsetReferenceAdvRefTable.modelingbot | 52 - .../unsetReferenceEOFCV.modelingbot | 72 - .../wizard_conference/unsetText.modelingbot | 38 - .../pom.xml | 85 - .../src/log4j.xml | 60 - .../emf/samples/tests/junit/AllTests.java | 253 - .../ComposedMBotAddAdvTableCompo.java | 22 - .../ComposedMBotCancelAddAdvTableCompo.java | 22 - .../ComposedMBotCancelSetAttributeMVE.java | 22 - ...osedMBotCancelSetReferenceAdvRefTable.java | 22 - .../ComposedMBotCancelSetReferenceEOFCV.java | 22 - .../ComposedMBotRedoAddAdvTableCompo.java | 22 - .../ComposedMBotRedoSetAttributeCheckbox.java | 22 - ...sedMBotRedoSetAttributeEMFComboViewer.java | 22 - .../ComposedMBotRedoSetAttributeMVE.java | 22 - .../ComposedMBotRedoSetAttributeText.java | 22 - .../ComposedMBotRedoSetAttributeTextArea.java | 22 - ...mposedMBotRedoSetReferenceAdvRefTable.java | 22 - .../ComposedMBotRedoSetReferenceEOFCV.java | 22 - .../ComposedMBotRemoveAdvTableCompo.java | 22 - .../ComposedMBotSetAttributeCheckbox.java | 22 - ...omposedMBotSetAttributeEMFComboViewer.java | 22 - .../ComposedMBotSetAttributeInteger.java | 22 - .../ComposedMBotSetAttributeMVE.java | 22 - .../ComposedMBotSetAttributeText.java | 22 - .../ComposedMBotSetAttributeTextArea.java | 22 - .../ComposedMBotSetReferenceAdvRefTable.java | 22 - .../ComposedMBotSetReferenceAdvRefTable2.java | 22 - .../ComposedMBotSetReferenceEOFCV.java | 22 - .../ComposedMBotUndoAddAdvTableCompo.java | 22 - .../ComposedMBotUndoSetAttributeCheckbox.java | 29 - ...sedMBotUndoSetAttributeEMFComboViewer.java | 30 - .../ComposedMBotUndoSetAttributeMVE.java | 30 - .../ComposedMBotUndoSetAttributeText.java | 22 - .../ComposedMBotUndoSetAttributeTextArea.java | 22 - ...mposedMBotUndoSetReferenceAdvRefTable.java | 22 - .../ComposedMBotUndoSetReferenceEOFCV.java | 22 - .../ComposedMBotUnsetAdvRefTable.java | 22 - .../ComposedMBotUnsetAttributeMVE.java | 22 - .../ComposedMBotUnsetAttributeText.java | 22 - .../ComposedMBotUnsetAttributeTextArea.java | 22 - .../conference/ComposedMBotUnsetMVE.java | 22 - ...ComposedMBotUnsetReferenceAdvRefTable.java | 22 - .../conference/ComposedMBotUnsetText.java | 22 - .../conference/ComposedMBotUnsetTextArea.java | 22 - .../PViewMBotAddAdvanceTableComposition.java | 22 - ...wMBotCancelAddAdvanceTableComposition.java | 22 - .../PViewMBotCancelSetAttributeMVE.java | 22 - ...ViewMBotCancelSetReferenceAdvRefTable.java | 22 - .../PViewMBotCancelSetReferenceEOFCV.java | 22 - .../PViewMBotEditSetReferenceAdvRefTable.java | 22 - .../PViewMBotEditSetReferenceEOFCV.java | 22 - .../PViewMBotMoveAdvanceTableComposition.java | 22 - .../PViewMBotRedoSetAttributeCheckbox.java | 22 - ...iewMBotRedoSetAttributeEMFComboViewer.java | 22 - .../PViewMBotRedoSetAttributeMVE.java | 22 - .../PViewMBotRedoSetAttributeText.java | 22 - .../PViewMBotRedoSetAttributeTextArea.java | 22 - .../PViewMBotRedoSetReferenceAdvRefTable.java | 22 - .../PViewMBotRedoSetReferenceEOFCV.java | 22 - ...ViewMBotRemoveAdvanceTableComposition.java | 22 - .../PViewMBotSetAttributeCheckbox.java | 22 - .../PViewMBotSetAttributeEMFComboViewer.java | 22 - .../conference/PViewMBotSetAttributeMVE.java | 22 - .../conference/PViewMBotSetAttributeText.java | 22 - .../PViewMBotSetAttributeTextArea.java | 22 - .../PViewMBotSetReferenceAdvRefTable.java | 22 - .../PViewMBotSetReferenceEOFCV.java | 22 - ...iewMBotUndoAddAdvanceTableComposition.java | 22 - .../PViewMBotUndoSetAttributeCheckbox.java | 22 - ...iewMBotUndoSetAttributeEMFComboViewer.java | 22 - .../PViewMBotUndoSetAttributeMVE.java | 22 - .../PViewMBotUndoSetAttributeText.java | 22 - .../PViewMBotUndoSetAttributeTextArea.java | 22 - .../PViewMBotUndoSetReferenceAdvRefTable.java | 22 - .../PViewMBotUndoSetReferenceEOFCV.java | 22 - .../PViewMBotUnsetAdvancedRefrencesTable.java | 22 - .../PViewMBotUnsetAttributeMVE.java | 22 - .../PViewMBotUnsetAttributeText.java | 22 - .../PViewMBotUnsetAttributeTextArea.java | 22 - .../PViewMBotUnsetReferenceAdvRefTable.java | 22 - .../conference/PViewMBotUnsetText.java | 22 - .../conference/PViewMBotUnsetTextArea.java | 22 - .../WizardMBotAddAdvanceTableComposition.java | 22 - ...dMBotCancelAddAdvanceTableComposition.java | 22 - .../WizardMBotCancelSetAttributeMVE.java | 22 - ...zardMBotCancelSetReferenceAdvRefTable.java | 22 - .../WizardMBotCancelSetReferenceEOFCV.java | 22 - ...WizardMBotEditSetReferenceAdvRefTable.java | 22 - .../WizardMBotEditSetReferenceEOFCV.java | 22 - ...ardMBotRedoAddAdvanceTableComposition.java | 22 - .../WizardMBotRedoSetAttributeCheckbox.java | 22 - ...ardMBotRedoSetAttributeEMFComboViewer.java | 22 - .../WizardMBotRedoSetAttributeMVE.java | 22 - .../WizardMBotRedoSetAttributeText.java | 22 - .../WizardMBotRedoSetAttributeTextArea.java | 22 - ...WizardMBotRedoSetReferenceAdvRefTable.java | 22 - .../WizardMBotRedoSetReferenceEOFCV.java | 22 - ...zardMBotRemoveAdvanceTableComposition.java | 22 - .../WizardMBotSetAttributeCheckbox.java | 22 - .../WizardMBotSetAttributeEMFComboViewer.java | 22 - .../conference/WizardMBotSetAttributeMVE.java | 22 - .../WizardMBotSetAttributeText.java | 22 - .../WizardMBotSetAttributeTextArea.java | 22 - .../WizardMBotSetReferenceAdvRefTable.java | 22 - .../WizardMBotSetReferenceEOFCV.java | 22 - ...ardMBotUndoAddAdvanceTableComposition.java | 22 - .../WizardMBotUndoSetAttributeCheckbox.java | 22 - ...ardMBotUndoSetAttributeEMFComboViewer.java | 22 - .../WizardMBotUndoSetAttributeMVE.java | 22 - .../WizardMBotUndoSetAttributeText.java | 22 - .../WizardMBotUndoSetAttributeTextArea.java | 22 - ...WizardMBotUndoSetReferenceAdvRefTable.java | 22 - .../WizardMBotUndoSetReferenceEOFCV.java | 22 - ...WizardMBotUnsetAdvancedRefrencesTable.java | 22 - .../WizardMBotUnsetAttributeMVE.java | 22 - .../WizardMBotUnsetAttributeText.java | 22 - .../WizardMBotUnsetAttributeTextArea.java | 22 - .../WizardMBotUnsetReferenceAdvRefTable.java | 22 - .../WizardMBotUnsetReferenceEOFCV.java | 22 - .../conference/WizardMBotUnsetText.java | 22 - tests/org.eclipse.emf.examples.eef/.classpath | 7 - tests/org.eclipse.emf.examples.eef/.gitignore | 2 - tests/org.eclipse.emf.examples.eef/.project | 28 - .../org.eclipse.core.resources.prefs | 3 - .../META-INF/MANIFEST.MF | 15 - .../build.properties | 14 - .../model/conference.ecore | 72 - .../model/conference.ecorediag | 349 - .../model/conference.genmodel | 82 - .../plugin.properties | 8 - tests/org.eclipse.emf.examples.eef/plugin.xml | 20 - tests/org.eclipse.emf.examples.eef/pom.xml | 28 - .../emf/samples/conference/Conference.java | 178 - .../samples/conference/ConferenceFactory.java | 91 - .../samples/conference/ConferencePackage.java | 1166 --- .../emf/samples/conference/GENDER.java | 239 - .../emf/samples/conference/Person.java | 211 - .../eclipse/emf/samples/conference/Room.java | 81 - .../eclipse/emf/samples/conference/Site.java | 99 - .../emf/samples/conference/TALK_TYPE.java | 239 - .../eclipse/emf/samples/conference/Talk.java | 193 - .../eclipse/emf/samples/conference/Topic.java | 100 - .../impl/ConferenceFactoryImpl.java | 236 - .../conference/impl/ConferenceImpl.java | 445 - .../impl/ConferencePackageImpl.java | 652 -- .../samples/conference/impl/PersonImpl.java | 480 -- .../emf/samples/conference/impl/RoomImpl.java | 221 - .../emf/samples/conference/impl/SiteImpl.java | 277 - .../emf/samples/conference/impl/TalkImpl.java | 459 - .../samples/conference/impl/TopicImpl.java | 264 - .../util/ConferenceAdapterFactory.java | 218 - .../conference/util/ConferenceSwitch.java | 224 - 3587 files changed, 514204 deletions(-) delete mode 100644 doc/org.eclipse.emf.eef.doc/.classpath delete mode 100644 doc/org.eclipse.emf.eef.doc/.gitignore delete mode 100644 doc/org.eclipse.emf.eef.doc/.project delete mode 100644 doc/org.eclipse.emf.eef.doc/.settings/org.eclipse.core.resources.prefs delete mode 100644 doc/org.eclipse.emf.eef.doc/META-INF/MANIFEST.MF delete mode 100644 doc/org.eclipse.emf.eef.doc/about.html delete mode 100644 doc/org.eclipse.emf.eef.doc/build-help.xml delete mode 100644 doc/org.eclipse.emf.eef.doc/build.properties delete mode 100644 doc/org.eclipse.emf.eef.doc/html/tutorial-toc.xml delete mode 100644 doc/org.eclipse.emf.eef.doc/html/tutorial.html delete mode 100644 doc/org.eclipse.emf.eef.doc/html/tutorial.mediawiki delete mode 100644 doc/org.eclipse.emf.eef.doc/pics/generateEEFArchitecture.png delete mode 100644 doc/org.eclipse.emf.eef.doc/pics/initializeEEFmodels.png delete mode 100644 doc/org.eclipse.emf.eef.doc/plugin.xml delete mode 100644 doc/org.eclipse.emf.eef.doc/pom.xml delete mode 100644 doc/org.eclipse.emf.eef.doc/src/org/eclipse/emf/eef/doc/Activator.java delete mode 100644 features/org.eclipse.emf.eef.codegen.ecore-feature/.gitignore delete mode 100644 features/org.eclipse.emf.eef.codegen.ecore-feature/.project delete mode 100644 features/org.eclipse.emf.eef.codegen.ecore-feature/build.properties delete mode 100755 features/org.eclipse.emf.eef.codegen.ecore-feature/epl-v10.html delete mode 100644 features/org.eclipse.emf.eef.codegen.ecore-feature/feature.properties delete mode 100644 features/org.eclipse.emf.eef.codegen.ecore-feature/feature.xml delete mode 100644 features/org.eclipse.emf.eef.codegen.ecore-feature/license.html delete mode 100644 features/org.eclipse.emf.eef.codegen.ecore-feature/license.txt delete mode 100644 features/org.eclipse.emf.eef.codegen.ecore-feature/pom.xml delete mode 100644 features/org.eclipse.emf.eef.codegen.richtext-feature/.gitignore delete mode 100644 features/org.eclipse.emf.eef.codegen.richtext-feature/.project delete mode 100644 features/org.eclipse.emf.eef.codegen.richtext-feature/build.properties delete mode 100644 features/org.eclipse.emf.eef.codegen.richtext-feature/epl-v10.html delete mode 100644 features/org.eclipse.emf.eef.codegen.richtext-feature/feature.properties delete mode 100644 features/org.eclipse.emf.eef.codegen.richtext-feature/feature.xml delete mode 100644 features/org.eclipse.emf.eef.codegen.richtext-feature/license.html delete mode 100644 features/org.eclipse.emf.eef.codegen.richtext-feature/license.txt delete mode 100644 features/org.eclipse.emf.eef.codegen.richtext-feature/pom.xml delete mode 100644 features/org.eclipse.emf.eef.codegen.uml.feature/.gitignore delete mode 100644 features/org.eclipse.emf.eef.codegen.uml.feature/.project delete mode 100644 features/org.eclipse.emf.eef.codegen.uml.feature/build.properties delete mode 100755 features/org.eclipse.emf.eef.codegen.uml.feature/epl-v10.html delete mode 100644 features/org.eclipse.emf.eef.codegen.uml.feature/feature.properties delete mode 100644 features/org.eclipse.emf.eef.codegen.uml.feature/feature.xml delete mode 100644 features/org.eclipse.emf.eef.codegen.uml.feature/license.html delete mode 100644 features/org.eclipse.emf.eef.codegen.uml.feature/license.txt delete mode 100644 features/org.eclipse.emf.eef.codegen.uml.feature/pom.xml delete mode 100644 features/org.eclipse.emf.eef.collab.runtime-feature/.gitignore delete mode 100644 features/org.eclipse.emf.eef.collab.runtime-feature/.project delete mode 100644 features/org.eclipse.emf.eef.collab.runtime-feature/build.properties delete mode 100644 features/org.eclipse.emf.eef.collab.runtime-feature/epl-v10.html delete mode 100644 features/org.eclipse.emf.eef.collab.runtime-feature/feature.properties delete mode 100644 features/org.eclipse.emf.eef.collab.runtime-feature/feature.xml delete mode 100644 features/org.eclipse.emf.eef.collab.runtime-feature/license.html delete mode 100644 features/org.eclipse.emf.eef.collab.runtime-feature/license.txt delete mode 100644 features/org.eclipse.emf.eef.collab.runtime-feature/pom.xml delete mode 100644 features/org.eclipse.emf.eef.edt-feature/.gitignore delete mode 100644 features/org.eclipse.emf.eef.edt-feature/.project delete mode 100644 features/org.eclipse.emf.eef.edt-feature/build.properties delete mode 100644 features/org.eclipse.emf.eef.edt-feature/epl-v10.html delete mode 100644 features/org.eclipse.emf.eef.edt-feature/feature.properties delete mode 100644 features/org.eclipse.emf.eef.edt-feature/feature.xml delete mode 100644 features/org.eclipse.emf.eef.edt-feature/license.html delete mode 100644 features/org.eclipse.emf.eef.edt-feature/license.txt delete mode 100644 features/org.eclipse.emf.eef.edt-feature/pom.xml delete mode 100644 features/org.eclipse.emf.eef.extended-feature/.gitignore delete mode 100644 features/org.eclipse.emf.eef.extended-feature/.project delete mode 100644 features/org.eclipse.emf.eef.extended-feature/build.properties delete mode 100644 features/org.eclipse.emf.eef.extended-feature/epl-v10.html delete mode 100644 features/org.eclipse.emf.eef.extended-feature/feature.properties delete mode 100644 features/org.eclipse.emf.eef.extended-feature/feature.xml delete mode 100644 features/org.eclipse.emf.eef.extended-feature/license.html delete mode 100644 features/org.eclipse.emf.eef.extended-feature/license.txt delete mode 100644 features/org.eclipse.emf.eef.extended-feature/pom.xml delete mode 100644 features/org.eclipse.emf.eef.richtext-feature/.gitignore delete mode 100644 features/org.eclipse.emf.eef.richtext-feature/.project delete mode 100644 features/org.eclipse.emf.eef.richtext-feature/build.properties delete mode 100644 features/org.eclipse.emf.eef.richtext-feature/epl-v10.html delete mode 100644 features/org.eclipse.emf.eef.richtext-feature/feature.properties delete mode 100644 features/org.eclipse.emf.eef.richtext-feature/feature.xml delete mode 100644 features/org.eclipse.emf.eef.richtext-feature/license.html delete mode 100644 features/org.eclipse.emf.eef.richtext-feature/license.txt delete mode 100644 features/org.eclipse.emf.eef.richtext-feature/pom.xml delete mode 100644 features/org.eclipse.emf.eef.runtime-feature/.gitignore delete mode 100644 features/org.eclipse.emf.eef.runtime-feature/.project delete mode 100644 features/org.eclipse.emf.eef.runtime-feature/build.properties delete mode 100644 features/org.eclipse.emf.eef.runtime-feature/epl-v10.html delete mode 100644 features/org.eclipse.emf.eef.runtime-feature/feature.properties delete mode 100644 features/org.eclipse.emf.eef.runtime-feature/feature.xml delete mode 100644 features/org.eclipse.emf.eef.runtime-feature/license.html delete mode 100644 features/org.eclipse.emf.eef.runtime-feature/license.txt delete mode 100644 features/org.eclipse.emf.eef.runtime-feature/pom.xml delete mode 100644 features/org.eclipse.emf.eef.sdk-feature/.gitignore delete mode 100644 features/org.eclipse.emf.eef.sdk-feature/.project delete mode 100644 features/org.eclipse.emf.eef.sdk-feature/build.properties delete mode 100644 features/org.eclipse.emf.eef.sdk-feature/epl-v10.html delete mode 100644 features/org.eclipse.emf.eef.sdk-feature/feature.properties delete mode 100644 features/org.eclipse.emf.eef.sdk-feature/feature.xml delete mode 100644 features/org.eclipse.emf.eef.sdk-feature/license.html delete mode 100644 features/org.eclipse.emf.eef.sdk-feature/license.txt delete mode 100644 features/org.eclipse.emf.eef.sdk-feature/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.branding/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.branding/.project delete mode 100644 plugins/org.eclipse.emf.eef.branding/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.branding/about.html delete mode 100644 plugins/org.eclipse.emf.eef.branding/about.ini delete mode 100644 plugins/org.eclipse.emf.eef.branding/about.mappings delete mode 100644 plugins/org.eclipse.emf.eef.branding/about.properties delete mode 100644 plugins/org.eclipse.emf.eef.branding/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.branding/modeling32.png delete mode 100644 plugins/org.eclipse.emf.eef.branding/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/.project delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/schema/CDOLockStrategyProvider.exsd delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/EEFCDORuntimePlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/CDOReadOnlyPolicy.java delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/CDOWizardOpeningPolicy.java delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/EEFWizardLockPolicy.java delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/provider/ICDOLockStrategyProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/service/CDOLockStrategyProviderService.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/.project delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/about.html delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/build.acceleo delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src-build/org/eclipse/emf/eef/codegen/ecore/EEFCodegenEcoreCompiler.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/EMFCodegenPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFCodeAction.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFEditCodeAction.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFEditorCodeAction.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFModelCodeAction.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/util/EEFGeneratorAdapter.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/ItemProvider.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/ItemProviderAdapterFactory.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/Plugin.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/buildproperties.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/editIcons.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/manifestmf.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/pluginproperties.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/pluginxml.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/ActionBarContributor.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/Editor.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/ModelWizard.mtl delete mode 100755 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/Plugin.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/buildproperties.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/editorIcons.mtl delete mode 100755 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/manifestmf.mtl delete mode 100755 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/pluginproperties.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/pluginxml.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEdit.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEdit.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEditor.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenModel.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenModel.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/AdapterFactoryClass.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/Class.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/EnumClass.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/FactoryClass.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/PackageClass.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/Plugin.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ResourceClass.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ResourceFactoryClass.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/SwitchClass.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ValidatorClass.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/XmlProcessorClass.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/buildproperties.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/eIsSet.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/eUnset.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genDeclaredFields.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genFeature.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genOperation.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/reflectiveDelegationAlternative.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genpackage/EGenericType.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/manifest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/module_gwt_xml.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/plugin_properties.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/plugin_xml.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/FileUtil.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/Information.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/InformationIterator.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/StringUtil.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/StringUtil.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/common.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/fileUtil.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/header.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/EAnnotation.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/EAnnotationWrapper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenBase.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClass.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassWrapper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassifier.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassifierWrapper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenDataType.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenDataTypeWrapper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenEnum.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenEnumLiteral.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenFeature.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenModel.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenModelWrapper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenOperation.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenOperationWrapper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenPackage.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenPackageWrapper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenParameter.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenTypeParameter.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenTypedElement.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/templates/edit/CreateChild.gif delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/templates/edit/Item.gif delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/templates/editor/ModelFile.gif delete mode 100644 plugins/org.eclipse.emf.eef.codegen.ecore/templates/editor/NewModel.gif delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.project delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/about.html delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/build.acceleo delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/extended/widgets/richtext/Activator.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/extended/widgets/richtext/compiler/EEFRichTextCodegenCompiler.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/std/Extended.toolkits delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/.project delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/about.html delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/build.acceleo delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/icons/full/obj16/initialize_eef_editor.gif delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src-build/org/eclipse/emf/eef/codegen/extended/EEFCodegenExtendedCompiler.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/CleanEEFEditorSources.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/GenerateEEFEditorModels.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/OverrideEMFEditorCode.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorContributionTransformer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorInitializer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorModelInitializer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFPagesTransformer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/launcher/GenerateAll.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/initializer/InitializeEEFEditorAction.java delete mode 100755 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/initializer/InitializeEEFEditorModelsAction.java delete mode 100755 plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/launcher/GenerateEEFEditorAction.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/Activator.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/editor/api/EditorContribution.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/files/EEFEditor.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/launcher/EEFEditorLauncher.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/launcher/EEFEditorLauncher.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/query/oclquery.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/services/editor-common.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.launcher/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.codegen.launcher/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.codegen.launcher/.project delete mode 100644 plugins/org.eclipse.emf.eef.codegen.launcher/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.codegen.launcher/META-INF/MANIFEST.MF delete mode 100755 plugins/org.eclipse.emf.eef.codegen.launcher/about.html delete mode 100644 plugins/org.eclipse.emf.eef.codegen.launcher/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.codegen.launcher/pom.xml delete mode 100755 plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/ConditionalStep.java delete mode 100755 plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/IdentityStep.java delete mode 100755 plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/Step.java delete mode 100755 plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/StepWithInput.java delete mode 100755 plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/Workflow.java delete mode 100755 plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/var/WorkflowContext.java delete mode 100755 plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/var/WorkflowVariable.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/launcher/EEFCodegenLauncher.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/.project delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/about.html delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/build.acceleo delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src-build/org/eclipse/emf/eef/codegen/tests/EEFCodegenTestsCompiler.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src-custom/org/eclipse/emf/eef/tests/codegen/core/launcher/ComponentPropertiesTestsGeneratorLauncher.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src-custom/org/eclipse/emf/eef/tests/codegen/core/launcher/ComponentTestsGeneratorLauncher.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/Activator.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentPropertiesTests.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentPropertiesTests.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentTests.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentTests.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/common/ComponentCommonTests.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/common/testsNaming.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/api/widgetTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/EMFComboViewerTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedEobjectFlatComboViewerTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedReferencesTableTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedTableCompositionTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/checkboxTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/eobjectFlatComboViewerTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/flatReferencesTableTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/multiValuedEditorTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/radioTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/referencesTableTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/tableCompositionTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/textTest.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/.project delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/about.html delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/build.acceleo delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/src/org/eclipse/emf/eef/codegen/services/umlCommon.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen.uml/src/org/eclipse/emf/eef/codegen/services/umlComponentUtils.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.codegen/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.codegen/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.codegen/.project delete mode 100644 plugins/org.eclipse.emf.eef.codegen/.settings/org.eclipse.core.resources.prefs delete mode 100644 plugins/org.eclipse.emf.eef.codegen/.settings/org.eclipse.core.runtime.prefs delete mode 100644 plugins/org.eclipse.emf.eef.codegen/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.codegen/about.html delete mode 100644 plugins/org.eclipse.emf.eef.codegen/build.acceleo delete mode 100644 plugins/org.eclipse.emf.eef.codegen/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.codegen/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.codegen/schema/PropertiesGeneratorLauncher.exsd delete mode 100644 plugins/org.eclipse.emf.eef.codegen/schema/PropertiesInitializerStrategy.exsd delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-build/org/eclipse/emf/eef/codegen/EEFCodegenCompiler.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/EEFCodegenPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/AbstractPropertiesInitializer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/AbstractTransformer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/ComponentTransformer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/IPropertiesInitializer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/PropertiesInitializer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/ViewTransformer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/AbstractPropertiesGeneratorLauncher.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/EEFLauncher.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/EMFPropertiesLauncher.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/IPropertiesGeneratorLauncher.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/services/PropertiesGeneratorLaunchersServices.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/services/PropertiesInitializerStrategyServices.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/BundleHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/EMFHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/ExtensionHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/AddDependency.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEEFCode.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEEFModels.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFCode.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFEditCode.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFEditorCode.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFModelCode.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/InitializeGenModel.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/MergePluginXML.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/util/GenmodelHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/actions/AbstractGenerateEEFAction.java delete mode 100755 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/actions/GenerateEEFAction.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/callback/EEFGenerationCallback.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/callback/imports/JDTImportsOrganisationCallback.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/GenerateAll.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/GenerationHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/ImportOrganizer.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/initializer/actions/InitializeEEFModelsAction.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/initializer/ui/InitializeEEFModelsDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/validators/actions/PurifyEEFModelsAction.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/DynamicPropertiesEditionComponent.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/PropertiesEditionComponent.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/SubPropertiesEditionComponent.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/launcher/EEFLauncher.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/launcher/EEFLauncher.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/FormPropertiesEditionPart.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/IPropertiesEditionPart.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/PropertiesEditionPart.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/ViewsRepository.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/plugin/plugin_xml.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessages.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessagesProperties.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessagesPropertiesFR.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PackagePropertiesEditionPartProvider.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PackagePropertiesEditionProvider.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PropertiesEditionProvider.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/EcoreService.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/ImportService.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/PluginService.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/StringUtilService.java delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/common.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/emfCodeGen.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/filters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/imports.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/naming.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/navigationStep.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/pluginservice.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/typeUtils.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/viewCommon.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/group/groupFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/group/groupSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/hbox/hboxFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/hbox/hboxSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaControl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaGettersSetters.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/vbox/vboxFormImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/vbox/vboxSWTImpl.mtl delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/.project delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/.settings/org.eclipse.jdt.ui.prefs delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/about.html delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateAbstractElementBinding_properties_PropertiesEditionElement.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateAbstractElementBinding_properties_PropertiesMultiEditionElement.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateAbstractElementBinding_subElements_PropertiesEditionComponent.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateCategory_bindings_PropertiesEditionComponent.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateDatabinding_bindings_PropertiesEditionComponent.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/EEFElement.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/PropertiesEditionComponent.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/PropertiesEditionContext.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/PropertiesEditionElement.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/PropertiesMultiEditionElement.gif delete mode 100755 plugins/org.eclipse.emf.eef.components.edit/model/components.components delete mode 100755 plugins/org.eclipse.emf.eef.components.edit/model/components.eefgen delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/components_properties.plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionComponentBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionComponentPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionContextBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionContextPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionElementBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionElementPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesMultiEditionElementBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesMultiEditionElementPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/ComponentsViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionComponentPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionContextPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionElementPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesMultiEditionElementPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionComponentPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionContextPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionElementPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesMultiEditionElementPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionComponentPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionContextPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionElementPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesMultiEditionElementPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/ComponentsEditPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/ComponentsItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/EEFElementItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionComponentItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionContextItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionElementItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesMultiEditionElementItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionComponentPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionContextPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionElementPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesMultiEditionElementPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/componentsMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/componentsMessages_fr.properties delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionElementCustomPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionElementCustomPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/providers/ComponentsCustomPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/resources/ComponentsResource.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/resources/ComponentsResourceFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/validation/BadReferencedEditorConstraint.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/mapping/provider/CategoryCustomItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/mapping/provider/MappingCustomItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/.project delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/about.html delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/icons/full/obj16/ComponentsModelFile.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/icons/full/wizban/NewComponents.gif delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsActionBarContributor.java delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsEditorPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsModelWizard.java delete mode 100644 plugins/org.eclipse.emf.eef.components/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.components/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.components/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.components/.project delete mode 100644 plugins/org.eclipse.emf.eef.components/.settings/org.eclipse.core.resources.prefs delete mode 100644 plugins/org.eclipse.emf.eef.components/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.components/about.html delete mode 100644 plugins/org.eclipse.emf.eef.components/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.components/model/components.ecore delete mode 100644 plugins/org.eclipse.emf.eef.components/model/components.ecorediag delete mode 100644 plugins/org.eclipse.emf.eef.components/model/components.genmodel delete mode 100644 plugins/org.eclipse.emf.eef.components/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.components/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/ComponentsFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/ComponentsPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/EEFElement.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionContext.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionElement.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesMultiEditionElement.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/ComponentsFactoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/ComponentsPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/EEFElementImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionComponentImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionContextImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionElementImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesMultiEditionElementImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/util/ComponentsAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/util/ComponentsSwitch.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/.project delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/META-INF/MANIFEST.MF delete mode 100755 plugins/org.eclipse.emf.eef.editor.model/about.html delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_PartFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateAbstractElementBinding_subElements_DynamicEEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateAbstractElementBinding_subElements_EEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateAbstractElementBinding_subElements_StaticEEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_PartFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_bindings_DynamicEEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_bindings_EEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_bindings_StaticEEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_categories_EEFEditorContributions.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_categories_EEFEditorPages.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_views_EEFMasterPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_views_StandardFormPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_views_TreeMasterPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateContainer_elements_EEFMasterPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateContainer_elements_StandardFormPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateContainer_elements_TreeMasterPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_bindings_DynamicEEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_bindings_EEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_bindings_StaticEEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_categories_EEFEditorContributions.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFEditorContribution_input_AllResourcesRootsRelativeInput.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFEditorContribution_input_FirstResourceRootRelativeInput.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFEditorContribution_model_AllResourcesRootsRelativeInput.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFEditorContribution_model_FirstResourceRootRelativeInput.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFPageInput_query_ExplicitPathQuery.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFPageInput_query_OCLQuery.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateViewsRepository_categories_EEFEditorPages.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateViewsRepository_views_EEFMasterPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateViewsRepository_views_StandardFormPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateViewsRepository_views_TreeMasterPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/AllResourcesRootsRelativeInput.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/DynamicEEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/EEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/EEFEditorContributions.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/EEFEditorPages.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/EEFMasterPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/ExplicitPathQuery.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/FirstResourceRootRelativeInput.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/MasterDetailsPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/OCLQuery.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/PartFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/ReferenceableObject.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/StandardFormPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/StaticEEFEditorContribution.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/TreeMasterPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/model/extended.components delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/model/extended.ecore delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/model/extended.ecorediag delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/model/extended.eefgen delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/model/extended.genmodel delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/editor_properties.plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/AllResourcesRootsRelativeInput.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/DynamicEEFEditorContribution.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorContribution.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorContributions.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorPages.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFMasterPage.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFPage.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFPageInput.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EditorFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EditorPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/FirstResourceRootRelativeInput.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/MasterDetailsPage.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/PartFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/ReferenceableObject.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/StandardFormPage.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/StaticEEFEditorContribution.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/TreeMasterPage.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/DynamicEEFEditorContributionBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/DynamicEEFEditorContributionPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorContributionsBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorContributionsPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorPagesBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorPagesPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFMasterPageBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFMasterPagePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/PartFilterBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/PartFilterPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StandardFormPageBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StandardFormPagePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StaticEEFEditorContributionBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StaticEEFEditorContributionPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/TreeMasterPageBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/TreeMasterPagePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/AllResourcesRootsRelativeInputImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/DynamicEEFEditorContributionImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorContributionImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorContributionsImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorPagesImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFMasterPageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFPageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFPageInputImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EditorFactoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EditorPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/FirstResourceRootRelativeInputImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/MasterDetailsPageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/PartFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/ReferenceableObjectImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/StandardFormPageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/StaticEEFEditorContributionImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/TreeMasterPageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/DynamicEEFEditorContributionPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFEditorContributionsPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFEditorPagesPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFMasterPagePropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EditorViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/FilterPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/PartFilterPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/StandardFormPagePropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/StaticEEFEditorContributionPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/TreeMasterPagePropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/DynamicEEFEditorContributionPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFEditorContributionsPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFEditorPagesPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFMasterPagePropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/PartFilterPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/StandardFormPagePropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/StaticEEFEditorContributionPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/TreeMasterPagePropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/DynamicEEFEditorContributionPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFEditorContributionsPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFEditorPagesPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFMasterPagePropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/PartFilterPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/StandardFormPagePropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/StaticEEFEditorContributionPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/TreeMasterPagePropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/AllResourcesRootsRelativeInputItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/DynamicEEFEditorContributionItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorContributionItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorContributionsItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorPagesItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFMasterPageItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFPageInputItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFPageItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EditorItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/ExtendedEditPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/FirstResourceRootRelativeInputItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/MasterDetailsPageItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/PartFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/ReferenceableObjectItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/StandardFormPageItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/StaticEEFEditorContributionItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/TreeMasterPageItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/DynamicEEFEditorContributionPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFEditorContributionsPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFEditorPagesPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFMasterPagePropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/PartFilterPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/StandardFormPagePropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/StaticEEFEditorContributionPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/TreeMasterPagePropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/editorMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/editorMessages_fr.properties delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/util/EditorAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/util/EditorSwitch.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/EEFUnderstandableQuery.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/ExplicitPathQuery.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/OCLQuery.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/QueryFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/QueryPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/components/ExplicitPathQueryPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/components/OCLQueryPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/EEFUnderstandableQueryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/ExplicitPathQueryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/OCLQueryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/QueryFactoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/QueryPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/ExplicitPathQueryPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/OCLQueryPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/QueryViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/forms/ExplicitPathQueryPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/forms/OCLQueryPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/impl/ExplicitPathQueryPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/impl/OCLQueryPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/EEFUnderstandableQueryItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/ExplicitPathQueryItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/OCLQueryItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/QueryItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/ExplicitPathQueryPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/OCLQueryPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/queryMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/queryMessages_fr.properties delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/util/QueryAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/util/QuerySwitch.java delete mode 100644 plugins/org.eclipse.emf.eef.editor.model/src-gen/query_properties.plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/.project delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/about.html delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/ctool16/CreateEEFGenModel_editionContexts_GenEditionContext.gif delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/ctool16/CreateEEFGenModel_references_EEFGenModelReference.gif delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/ctool16/CreateEEFGenModel_viewsRepositories_GenViewsRepository.gif delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/ctool16/CreateGenEditionContext_references_GenEditionContextReference.gif delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/obj16/EEFGenModel.gif delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/obj16/EEFGenModelReference.gif delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/obj16/GenEditionContext.gif delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/obj16/GenViewsRepository.gif delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/model/EEFGen.components delete mode 100755 plugins/org.eclipse.emf.eef.eefgen.edit/model/EEFGen.eefgen delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/EEFGen_properties.plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/EEFGenModelPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/EEFGenModelReferencePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/GenEditionContextPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/GenViewsRepositoryPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenModelPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenModelReferencePropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/GenEditionContextPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/GenViewsRepositoryPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/EEFGenModelPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/EEFGenModelReferencePropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/GenEditionContextPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/GenViewsRepositoryPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/EEFGenModelPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/EEFGenModelReferencePropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/GenEditionContextPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/GenViewsRepositoryPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenEditPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenModelItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenModelReferenceItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/GenEditionContextItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/GenViewsRepositoryItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenModelPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenModelReferencePropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/GenEditionContextPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/GenViewsRepositoryPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/eEFGenMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/eEFGenMessages_fr.properties delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/.project delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/about.html delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/icons/full/obj16/EEFGenModelFile.gif delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/icons/full/wizban/NewEEFGen.gif delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenActionBarContributor.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenEditorPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenModelWizard.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/.project delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/about.html delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/model/EEFGen.ecore delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/model/EEFGen.genmodel delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenModel.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenModelReference.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/GenEditionContext.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/GenViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/HELP_STRATEGY.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenFactoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenModelImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenModelReferenceImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/GenEditionContextImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/GenViewsRepositoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/util/EEFGenAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/util/EEFGenSwitch.java delete mode 100644 plugins/org.eclipse.emf.eef.extended.widgets.richtext/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.extended.widgets.richtext/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.extended.widgets.richtext/.project delete mode 100644 plugins/org.eclipse.emf.eef.extended.widgets.richtext/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.extended.widgets.richtext/META-INF/MANIFEST.MF delete mode 100755 plugins/org.eclipse.emf.eef.extended.widgets.richtext/about.html delete mode 100644 plugins/org.eclipse.emf.eef.extended.widgets.richtext/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.extended.widgets.richtext/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontNameAction.java delete mode 100644 plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontSizeAction.java delete mode 100644 plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontStyleAction.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/.project delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/about.html delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_JavaDeclarationFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_JavaExpressionFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_OCLFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_OnlyReferenceTypeFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_StrictTypingFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_properties_EMFMultiPropertiesBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_properties_EMFPropertyBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_properties_StandardPropertyBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_referencedBinding_ElementBindingReference.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_subElements_EMFElementBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_subElements_StandardElementBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_JavaDeclarationFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_JavaExpressionFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_OCLFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_OnlyReferenceTypeFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_StrictTypingFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateCategory_bindings_EMFElementBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateCategory_bindings_StandardElementBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateCategory_categories_Category.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_current_ChainedModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_current_SimpleModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_current_StructuredModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_next_ChainedModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_next_SimpleModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_next_StructuredModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedNavigation_current_ChainedNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedNavigation_current_SimpleMetamodelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedNavigation_next_ChainedNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedNavigation_next_SimpleMetamodelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateDatabinding_bindings_EMFElementBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateDatabinding_bindings_StandardElementBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateDatabinding_categories_Category.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFMultiPropertiesBinding_navigation_ChainedModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFMultiPropertiesBinding_navigation_CustomModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFMultiPropertiesBinding_navigation_SimpleModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFMultiPropertiesBinding_navigation_SmartModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_editorSetting_EReferenceViewerSettings.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_ChainedModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_ChainedNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_CustomModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_SimpleMetamodelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_SimpleModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_SmartModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_StructuredModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEReferenceViewerSettings_filter_JavaBodyStepFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEReferenceViewerSettings_filter_JavaDeclarationStepFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateNavigationStep_filters_JavaBodyStepFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateNavigationStep_filters_JavaDeclarationStepFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateNavigationStep_initializer_JavaBodyStepInitializer.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateNavigationStep_initializer_JavaDeclarationStepInitializer.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateNavigationStep_subStep_DeclarativeNavigationStep.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateSmartModelNavigation_step_DeclarativeNavigationStep.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/AbstractElementBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/AbstractPropertyBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/Category.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/ChainedModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/CustomModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/Databinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/DeclarativeNavigationStep.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/DocumentedElement.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/EMFElementBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/EMFMultiPropertiesBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/EMFPropertyBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/EReferenceViewerSettings.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/ElementBindingReference.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaBodyExpression.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaBodyStepFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaBodyStepInitializer.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaDeclarationFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaDeclarationStepFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaDeclarationStepInitializer.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaExpressionFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/OCLFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/OnlyReferenceTypeFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/SimpleModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/SmartModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/StandardElementBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/StandardPropertyBinding.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/StrictTypingFilter.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/StructuredModelNavigation.gif delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/model/mapping.components delete mode 100755 plugins/org.eclipse.emf.eef.mapping.edit/model/mapping.eefgen delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/filters_properties.plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/mapping_properties.plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/navigation_properties.plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaBodyStepFilterPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationFilterBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationFilterPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationStepFilterPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaExpressionFilterBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaExpressionFilterPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OCLFilterBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OCLFilterPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OnlyReferenceTypeFilterBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OnlyReferenceTypeFilterPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/StrictTypingFilterFilterPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/FiltersEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaBodyStepFilterPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaDeclarationFilterPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaDeclarationStepFilterPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaExpressionFilterPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/OCLFilterPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/OnlyReferenceTypeFilterPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/StrictTypingFilterFilterPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/CategoryBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/CategoryPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/DocumentedElementPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFElementBindingBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFElementBindingPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFMultiPropertiesBindingBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFMultiPropertiesBindingPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFPropertyBindingBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFPropertyBindingPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/ElementBindingReferenceBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/ElementBindingReferencePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/FilterPropertiesPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardElementBindingBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardElementBindingPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardPropertyBindingBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardPropertyBindingPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/FiltersViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaBodyStepFilterPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaDeclarationFilterPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaDeclarationStepFilterPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaExpressionFilterPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/OCLFilterPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/OnlyReferenceTypeFilterPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/StrictTypingFilterPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaBodyStepFilterPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaDeclarationFilterPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaDeclarationStepFilterPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaExpressionFilterPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/OCLFilterPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/OnlyReferenceTypeFilterPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/StrictTypingFilterPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaBodyStepFilterPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaDeclarationFilterPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaDeclarationStepFilterPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaExpressionFilterPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/OCLFilterPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/OnlyReferenceTypeFilterPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/StrictTypingFilterPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/BindingFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/BusinessFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/FiltersItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaBodyStepFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaDeclarationFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaDeclarationStepFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaExpressionFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/OCLFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/OnlyReferenceTypeFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/StepFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/StrictTypingFilterItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/FiltersMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/FiltersPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/filtersMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/filtersMessages_fr.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/DeclarativeNavigationStepPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/JavaBodyStepInitializerPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/JavaDeclarationStepInitializerPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/ModelNavigationPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/NavigationViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/SimpleModelNavigationPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/DeclarativeNavigationStepPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/JavaBodyStepInitializerPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/JavaDeclarationStepInitializerPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/ModelNavigationPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/SimpleModelNavigationPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/DeclarativeNavigationStepPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/JavaBodyStepInitializerPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/JavaDeclarationStepInitializerPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/ModelNavigationPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/SimpleModelNavigationPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/ChainedModelNavigationItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/CustomModelNavigationItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/DeclarativeNavigationStepItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaBodyExpressionItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaBodyStepInitializerItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaDeclarationExpressionItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaDeclarationStepInitializerItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/ModelNavigationItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/NavigationItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/NavigationStepItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/SimpleModelNavigationItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/SmartModelNavigationItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/StepInitializerItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/StructuredModelNavigationItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/NavigationMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/NavigationPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/navigationMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/navigationMessages_fr.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/CategoryPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/DocumentationPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFElementBindingPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFMultiPropertiesBindingPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFPropertyBindingPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/ElementBindingReferencePropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/FilterPropertiesPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/MappingViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/StandardElementBindingPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/StandardPropertyBindingPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/CategoryPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/DocumentationPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFElementBindingPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFMultiPropertiesBindingPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFPropertyBindingPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/ElementBindingReferencePropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/FilterPropertiesPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/StandardElementBindingPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/StandardPropertyBindingPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/CategoryPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/DocumentationPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFElementBindingPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFMultiPropertiesBindingPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFPropertyBindingPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/ElementBindingReferencePropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/FilterPropertiesPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/StandardElementBindingPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/StandardPropertyBindingPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/AbstractElementBindingItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/AbstractPropertyBindingItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/CategoryItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/DatabindingItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/DocumentedElementItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFElementBindingItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFMultiPropertiesBindingItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFPropertyBindingItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ElementBindingReferenceItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/MappingEditPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/MappingItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ModelElementItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ModelPropertyItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/StandardElementBindingItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/StandardPropertyBindingItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/CategoryPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/DocumentedElementPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFElementBindingPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFMultiPropertiesBindingPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFPropertyBindingPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/ElementBindingReferencePropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/FilterPropertiesPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/StandardElementBindingPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/StandardPropertyBindingPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/mappingMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/mappingMessages_fr.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/SettingsPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/SettingsViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/forms/SettingsPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/impl/SettingsPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/EReferenceViewerSettingsItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/EditorSettingsItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/SettingsItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/SettingsMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/SettingsPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/settingsMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/settingsMessages_fr.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/DeclarativeNavigationStepPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/JavaBodyStepInitializerPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/JavaDeclarationStepInitializerPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/SimpleModelNavigationPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/DeclarativeNavigationStepPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/JavaBodyStepInitializerPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/JavaDeclarationStepInitializerPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/NavigationEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/SimpleModelNavigationPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/components/EReferenceViewerSettingsPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/providers/EReferenceViewerSettingsPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/providers/SettingsEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src-gen/settings_properties.plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/forms/DeclarativeNavigationStepCustomPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/forms/SimpleModelNavigationCustomPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/impl/DeclarativeNavigationStepCustomPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/impl/SimpleModelNavigationCustomPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/providers/MappingCustomPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.mapping/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.mapping/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.mapping/.project delete mode 100644 plugins/org.eclipse.emf.eef.mapping/.settings/org.eclipse.core.resources.prefs delete mode 100644 plugins/org.eclipse.emf.eef.mapping/.settings/org.eclipse.jdt.ui.prefs delete mode 100644 plugins/org.eclipse.emf.eef.mapping/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.mapping/about.html delete mode 100644 plugins/org.eclipse.emf.eef.mapping/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping/model/mapping.ecore delete mode 100644 plugins/org.eclipse.emf.eef.mapping/model/mapping.ecorediag delete mode 100644 plugins/org.eclipse.emf.eef.mapping/model/mapping.genmodel delete mode 100644 plugins/org.eclipse.emf.eef.mapping/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.mapping/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.mapping/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/AbstractElementBinding.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/AbstractPropertyBinding.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/Category.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/Databinding.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/DocumentedElement.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFElementBinding.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFMultiPropertiesBinding.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFPropertyBinding.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ElementBindingReference.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/MappingFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/MappingPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ModelElement.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ModelProperty.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/StandardElementBinding.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/StandardPropertyBinding.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/BindingFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/BusinessFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/FiltersFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/FiltersPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaBodyStepFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaDeclarationFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaDeclarationStepFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaExpressionFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaStepFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/OCLFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/OnlyReferenceTypeFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/StepFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/StrictTypingFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/BindingFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/BusinessFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/FiltersFactoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/FiltersPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaBodyStepFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaDeclarationFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaDeclarationStepFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaExpressionFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/OCLFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/OnlyReferenceTypeFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/StepFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/StrictTypingFilterImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/util/FiltersAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/util/FiltersSwitch.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/AbstractElementBindingImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/AbstractPropertyBindingImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/CategoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/DatabindingImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/DocumentedElementImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFElementBindingImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFMultiPropertiesBindingImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFPropertyBindingImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ElementBindingReferenceImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/MappingFactoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/MappingPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ModelElementImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ModelPropertyImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/StandardElementBindingImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/StandardPropertyBindingImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/ChainedModelNavigation.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/CustomModelNavigation.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/DeclarativeNavigationStep.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaBodyExpression.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaBodyStepInitializer.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaDeclarationExpression.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaDeclarationStepInitializer.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaStepInitializer.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/ModelNavigation.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationStep.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/SimpleModelNavigation.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/SmartModelNavigation.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/StepInitializer.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/StructuredModelNavigation.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/ChainedModelNavigationImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/CustomModelNavigationImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/DeclarativeNavigationStepImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaBodyExpressionImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaBodyStepInitializerImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaDeclarationExpressionImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaDeclarationStepInitializerImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/ModelNavigationImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationFactoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationStepImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/SimpleModelNavigationImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/SmartModelNavigationImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/StepInitializerImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/StructuredModelNavigationImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/util/NavigationAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/util/NavigationSwitch.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/EReferenceViewerSettings.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/EditorSettings.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/SettingsFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/SettingsPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/EReferenceViewerSettingsImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/EditorSettingsImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/SettingsFactoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/SettingsPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/util/SettingsAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/util/SettingsSwitch.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/util/MappingAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/util/MappingSwitch.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/.project delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/META-INF/MANIFEST.MF delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Add.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Cancel.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Check.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/CloseEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/CloseProject.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/CreateModel.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/CreateProject.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/DetailsPage.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/EEFActionsModelFile.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/ModelingBot.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/MoveDown.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/MoveUp.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/OpenEEFEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/OpenEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/OpenPerspective.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/OpenProject.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/PropertiesView.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Redo.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Remove.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/RemoveProject.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Save.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Scenario.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Set.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/SetAttribute.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/SetReference.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Undo.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Unset.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/UnsetAttribute.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/UnsetReference.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Wizard.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/wizban/NewModelingBot.gif delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/AddItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/CancelItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/CheckItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EEFActionItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EEFActionsItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EditActionItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/MoveDownItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/MoveUpItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/OpenEEFEditorItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/RemoveItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/SetAttributeItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/SetReferenceItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetAttributeItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetReferenceItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CloseEditorItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CloseProjectItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CreateModelItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CreateProjectItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/EclipseActionItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/EclipseActionsItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenEditorItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenPerspectiveItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenProjectItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/RedoItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/RemoveProjectItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/SaveItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/UndoItemProvider.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ActionItemProvider.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/DetailsPageItemProvider.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/DocumentedElementItemProvider.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/MbotEditPlugin.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ModelingBotItemProvider.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ModelingBotItemProviderAdapterFactory.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/PropertiesViewItemProvider.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ScenarioItemProvider.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/SequenceItemProvider.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/WizardItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.edit/src/org/eclipse/emf/eef/modelingBot/edit/commands/OpenWithEEFHandler.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot.edit/src/org/eclipse/emf/eef/modelingBot/edit/wizards/ModelCreationWizard.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/.project delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/obj16/EEFActionsModelFile.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/obj16/EclipseActionsModelFile.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/obj16/ModelingBotModelFile.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/wizban/NewEEFActions.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/wizban/NewEclipseActions.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/wizban/NewModelingBot.gif delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsActionBarContributor.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsModelWizard.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsActionBarContributor.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsModelWizard.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/MbotEditorPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotActionBarContributor.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotModelWizard.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/.project delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/.settings/org.eclipse.core.resources.prefs delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/model/mbot.ecore delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/model/mbot.genmodel delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/modelingBot package entities.jpg delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/representations.aird delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Action.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/DetailsPage.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/DocumentedElement.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Add.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Cancel.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Check.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFAction.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFActionsFactory.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFActionsPackage.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EditAction.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/MoveDown.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/MoveUp.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/OpenEEFEditor.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Remove.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/SetAttribute.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/SetReference.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Unset.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/UnsetAttribute.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/UnsetReference.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/AddImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/CancelImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/CheckImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionsFactoryImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionsPackageImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EditActionImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/MoveDownImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/MoveUpImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/OpenEEFEditorImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/RemoveImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/SetAttributeImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/SetReferenceImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetAttributeImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetReferenceImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/util/EEFActionsAdapterFactory.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/util/EEFActionsSwitch.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CloseEditor.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CloseProject.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CreateModel.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CreateProject.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseAction.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseActionsFactory.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseActionsPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenEditor.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenPerspective.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenProject.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Redo.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/RemoveProject.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Save.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Undo.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CloseEditorImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CloseProjectImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CreateModelImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CreateProjectImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionsFactoryImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionsPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenEditorImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenPerspectiveImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenProjectImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/RedoImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/RemoveProjectImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/SaveImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/UndoImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/util/EclipseActionsAdapterFactory.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/util/EclipseActionsSwitch.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBot.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBotFactory.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBotPackage.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Processing.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/PropertiesView.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Scenario.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Sequence.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/SequenceType.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Wizard.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ActionImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/DetailsPageImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/DocumentedElementImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotFactoryImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotPackageImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/PropertiesViewImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ScenarioImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/SequenceImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/WizardImpl.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/util/ModelingBotAdapterFactory.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/util/ModelingBotSwitch.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/IModelingBot.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/batch/BatchModelingBot.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/exception/InputModelInvalidException.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/exception/WidgetInvalidException.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EEFModelHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EEFModelingBotHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EMFHelper.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/PropertiesEditionHelper.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/SWTBotHelper.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/SWTEEFBotHelper.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/StringHelper.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/UIConstants.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/ComposedEEFInterpreter.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/EEFInterpreter.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/IModelingBotInterpreter.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/menu/FirstContextMenuFinder.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/menu/SWTBotContextMenu.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/swtbot/ComposedEEFBot.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/swtbot/SWTEEFBot.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractBatchModelingBotTestCase.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractComposedModelingBotTestCase.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractSWTBotModelingBotTestCase.java delete mode 100644 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/ui/utils/WrappedSWTBotRadio.java delete mode 100755 plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/uri/EEFURIConverter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/.project delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/META-INF/MANIFEST.MF delete mode 100755 plugins/org.eclipse.emf.eef.runtime.extended/about.html delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/icons/full/obj16/InteractiveEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/icons/full/obj16/OpenEEFEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/EEFQuery.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryProcessor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryResult.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryWrapper.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/compound/CompoundProcessor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/ExplicitPathProcessor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/ExplicitPathQuery.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/exception/EvaluationException.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/AttributeModelNavigation.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ChainedModelNavigation.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ModelNavigation.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ReferenceModelNavigation.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/ocl/OCLProcessor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/ocl/OCLQuery.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/EEFExtendedRuntime.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/InteractiveEEFEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/InteractiveEEFEditorActionBarContributor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/messages/MessageHandler.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/messages/MessageProcessor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/AbstractEEFEditorPage.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/AbstractEEFMDFormPage.java delete mode 100755 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFDetailsPage.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFEditorPage.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFStandardFormPage.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/eefviewer/EEFPropertiesViewerMDFormPage.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/tree/EEFTreeMDFormPage.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/layout/EEFFormLayoutFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/views/EEFView.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/AbstractEEFMasterDetailsBlock.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/AbstractEEFMasterPart.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/eefviewer/PropertiesViewerMasterDetailsBlock.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/eefviewer/PropertiesViewerMasterPart.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/tree/EEFTreeMasterDetailsBlock.java delete mode 100755 plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/tree/EEFTreeMasterPart.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/.project delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/about.html delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/icons/full/obj16/EEFReflectiveEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/icons/sample.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/SWTBotEEFTestCase.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/exceptions/InputModelInvalidException.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/exceptions/WidgetInvalidException.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/finder/SWTEEFBot.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/finder/SWTEEFBotHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/utils/ModelHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/utils/SWTBotUtils.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/actions/OpenWithEEFReflectiveEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/editors/EEFReflectiveEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/properties/section/EEFReflectiveEditionSection.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/EEFTestsModelsUtils.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/EEFTestsResourceUtils.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/UIConstants.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/.project delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/icons/full/dlcl16/LocateValue.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/icons/full/elcl16/LocateValue.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/EEFEditor.gwt.xml delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/EEFEditorEntryPoint.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/CreateObjectCommand.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/CreateResourceCommand.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/SaveCommand.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/UpdateURIConverterCommand.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/CreateObjectDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/CreateResourceDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/ErrorDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/EEFEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/part/EEFEditorToolbar.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/part/EEFPropertiesPanel.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/property/FeatureEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/property/ItemPropertyDescriptorFeatureEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/EditorToolbarListener.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/EventProcess.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/NavigationManager.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/EEFTreeViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/EEFTreeViewerContentProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/ModelViewerCell.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/.project delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/EEFSelectionDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/EReferenceEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/ArrayFeatureContentProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/ChoiceOfValuesFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/EEFOverrideViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/SelectionMode.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.runtime/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.runtime/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.runtime/.project delete mode 100644 plugins/org.eclipse.emf.eef.runtime/.settings/org.eclipse.jdt.core.prefs delete mode 100644 plugins/org.eclipse.emf.eef.runtime/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.runtime/about.html delete mode 100644 plugins/org.eclipse.emf.eef.runtime/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/Add_16x16.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/ArrowDown_16x16.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/ArrowLeft_16x16.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/ArrowRight_16x16.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/ArrowUp_16x16.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/Create_16x16.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/Delete_16x16.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/Edit_Part.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/Switch_Visibility.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/ValidationErrors.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/ValidationWarnings.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/disabled/th_horizontal.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/disabled/th_vertical.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/th_horizontal.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/th_vertical.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/icons/16x16/validate.gif delete mode 100644 plugins/org.eclipse.emf.eef.runtime/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.runtime/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.runtime/schema/LockPolicyProvider.exsd delete mode 100644 plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionComponentListenerProvider.exsd delete mode 100644 plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionPartProvider.exsd delete mode 100644 plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionPolicyProvider.exsd delete mode 100644 plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionProvider.exsd delete mode 100644 plugins/org.eclipse.emf.eef.runtime/schema/ReadOnlyPolicyProvider.exsd delete mode 100644 plugins/org.eclipse.emf.eef.runtime/schema/WizardOpeningPolicyProvider.exsd delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/EEFRuntimePlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/adapters/SemanticAdapter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/component/IPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/context/ContextEntry.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/EClassifierNotificationFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/EStructuralFeatureNotificationFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionComponentListener.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionEvent.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionListener.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/NotificationFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/PropertiesEditingSemanticListener.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/PropertiesEditingSemanticLister.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/ResourceSetAdapter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/IFormPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/IPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/ISWTPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IPropertiesEditionPartProviderFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IReadOnlyPolicy.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/ExtendedPropertiesEditingContext.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/PropertiesEditingContext.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/DomainPropertiesEditionContext.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/EObjectPropertiesEditionContext.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/EReferencePropertiesEditionContext.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/TypedEReferencePropertiesEditingContext.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/command/StandardEditingCommand.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/command/WizardEditingCommand.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/ComposedPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/SinglePartPropertiesEditingComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/StandardPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/EObjectFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/EObjectStrictFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/BusinessViewerFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/CurrentModelViewerFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/ReferencedModelsViewerFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/EEFLockNotification.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/PropertiesEditionEvent.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/PropertiesValidationEditionEvent.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/operation/WizardEditingOperation.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/parts/CompositePropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/parts/NullCompositePropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/providers/ComposedPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/providers/StandardPropertiesEditionPartProviderFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/LockPolicyProviderService.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesContextService.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesEditionComponentListenerProviderService.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesEditionPartProviderService.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/ReadOnlyPolicyProviderService.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/WizardOpeningPolicyProviderService.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFCommandParameter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFConverterUtil.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFRuntimeMessages.java delete mode 100755 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFUtils.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/ModelViewerHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/PatternTool.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/StringMatcher.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/StringTools.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/ValidationUtils.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/eefRuntimeMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/validation/EEFValidationClientSelector.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/validation/EEFValidator.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/part/impl/SectionPropertiesEditingPart.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/part/impl/util/ValidationMessageInjector.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/ILockPolicy.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/PropertiesEditingPolicy.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/PropertiesEditingPolicyWithResult.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/impl/CreateEditingPolicy.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/impl/StandardEditingPolicy.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/providers/PropertiesEditingProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/providers/impl/PropertiesEditingProviderImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/UIConstants.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/adapters/EEFBatchEditingUtil.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/adapters/SimplestSemanticAdapter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/comparator/EMFModelViewerComparator.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/DropDownSelectionListener.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/OpenTransactionalWizardOnDoubleClick.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/OpenWizardOnDoubleClick.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/PartComposer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/ViewHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/impl/BindingViewHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/impl/ViewHelperImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/BindingCompositionSequence.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/BindingCompositionStep.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/CompositionSequence.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/CompositionStep.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/properties/sections/EEFAdvancedPropertySection.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/providers/EMFListContentProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EEFLabelProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EEFRuntimeUIMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EditingUtils.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/eefRuntimeUImessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionContentProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionMessageManager.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/filters/PropertiesEditionPartFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/AbstractAdvancedEObjectFlatComboViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/AdvancedEObjectFlatComboViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ButtonsModeEnum.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ContainmentPropertiesEditingViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/EEFFeatureEditorDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/EMFComboViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/EMFModelViewerDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/EObjectFlatComboViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ElementSelectionDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/FlatReferencesTable.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/FormUtils.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/HorizontalBox.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/IPropertiesFilteredWidget.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/LinkEObjectFlatComboViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/LinkEReferenceViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ModelChooserDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/RadioViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ReferencesTable.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/SWTUtils.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/SelectionDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/SingleCompositionEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/SingleCompositionViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/TabElementTreeSelectionDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/VerticalBox.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/eobjflatcombo/EObjectFlatComboSettings.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/imageviewer/EEFImageViewer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/referencestable/ReferencesTableContentProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/referencestable/ReferencesTableSettings.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/settings/AdvancedEEFEditorContentProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/settings/EEFEditorContentProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/settings/EEFEditorSettings.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/settings/EEFEditorSettingsBuilder.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/settings/EEFFilter.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/settings/EEFInitializer.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/settings/NavigationStep.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/settings/NavigationStepBuilder.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/wizards/EEFWizardDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/wizards/IWizardOpeningPolicy.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/wizards/PropertiesEditionWizard.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/wizards/ResizableWizardDialog.java delete mode 100644 plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/wizards/impl/StandardWizardOpeningPolicy.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/.project delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/about.html delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateCategory_categories_Category.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateCategory_views_CustomView.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateCategory_views_View.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateContainer_elements_Container.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateContainer_elements_CustomElementEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateContainer_elements_CustomView.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateContainer_elements_ElementEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateContainer_elements_SpecificElementEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateContainer_elements_View.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateContainer_elements_ViewReference.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateToolkit_widgets_Widget.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateViewsRepository_categories_Category.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateViewsRepository_views_CustomView.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/ctool16/CreateViewsRepository_views_View.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/Category.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/Container.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/CustomElementEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/CustomView.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/DocumentedElement.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/ElementEditor.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/Toolkit.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/View.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/ViewReference.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/ViewsRepository.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/icons/full/obj16/Widget.gif delete mode 100755 plugins/org.eclipse.emf.eef.views.edit/model/toolkits.components delete mode 100755 plugins/org.eclipse.emf.eef.views.edit/model/views.components delete mode 100755 plugins/org.eclipse.emf.eef.views.edit/model/views.eefgen delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/components/ToolkitPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/components/WidgetPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/parts/ToolkitPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/parts/ToolkitsViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/parts/WidgetPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/parts/forms/ToolkitPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/parts/forms/WidgetPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/parts/impl/ToolkitPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/parts/impl/WidgetPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/provider/ToolkitItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/provider/ToolkitsItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/provider/WidgetItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/providers/ToolkitPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/providers/ToolkitsEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/providers/ToolkitsMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/providers/ToolkitsPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/providers/WidgetPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/providers/toolkitsMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/toolkits/providers/toolkitsMessages_fr.properties delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/CategoryBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/CategoryPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/ContainerBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/ContainerPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/CustomElementEditorBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/CustomElementEditorPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/CustomViewBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/CustomViewPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/DocumentedElementPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/ElementEditorBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/ElementEditorPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/ViewBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/ViewPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/ViewReferenceBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/ViewReferencePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/ViewsRepositoryBasePropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/components/ViewsRepositoryPropertiesEditionComponent.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/CategoryPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/ContainerPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/CustomElementEditorPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/CustomViewPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/DocumentationPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/ElementEditorPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/ViewPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/ViewReferencePropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/ViewsRepositoryPropertiesEditionPart.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/ViewsViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/forms/CategoryPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/forms/ContainerPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/forms/CustomElementEditorPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/forms/CustomViewPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/forms/DocumentationPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/forms/ElementEditorPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/forms/ViewPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/forms/ViewReferencePropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/forms/ViewsRepositoryPropertiesEditionPartForm.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/impl/CategoryPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/impl/ContainerPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/impl/CustomElementEditorPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/impl/CustomViewPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/impl/DocumentationPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/impl/ElementEditorPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/impl/ViewPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/impl/ViewReferencePropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/parts/impl/ViewsRepositoryPropertiesEditionPartImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/CategoryItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/ContainerItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/CustomElementEditorItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/CustomViewItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/DocumentedElementItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/ElementEditorItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/IdentifiedElementItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/ViewElementItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/ViewItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/ViewReferenceItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/ViewsEditPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/ViewsItemProviderAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/provider/ViewsRepositoryItemProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/CategoryPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/ContainerPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/CustomElementEditorPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/CustomViewPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/DocumentedElementPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/ElementEditorPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/ToolkitsEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/ViewPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/ViewReferencePropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/ViewsEEFAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/ViewsMessages.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/ViewsPropertiesEditionPartProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/ViewsRepositoryPropertiesEditionProvider.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/viewsMessages.properties delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/org/eclipse/emf/eef/views/providers/viewsMessages_fr.properties delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/toolkits_properties.plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src-gen/views_properties.plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src/org/eclipse/emf/eef/views/resources/ViewsResource.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src/org/eclipse/emf/eef/views/resources/ViewsResourceFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src/org/eclipse/emf/eef/views/validation/ContainerWithoutRepresensationConstraint.java delete mode 100644 plugins/org.eclipse.emf.eef.views.edit/src/org/eclipse/emf/eef/views/validation/NonReferenceViewsConstraint.java delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/.project delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/about.html delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/icons/full/obj16/ToolkitsModelFile.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/icons/full/obj16/ViewsModelFile.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/icons/full/wizban/NewToolkits.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/icons/full/wizban/NewViews.gif delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/plugin.properties delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/src-gen/org/eclipse/emf/eef/toolkits/presentation/ToolkitsActionBarContributor.java delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/src-gen/org/eclipse/emf/eef/toolkits/presentation/ToolkitsEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/src-gen/org/eclipse/emf/eef/toolkits/presentation/ToolkitsModelWizard.java delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/src-gen/org/eclipse/emf/eef/views/presentation/ViewsActionBarContributor.java delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/src-gen/org/eclipse/emf/eef/views/presentation/ViewsEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/src-gen/org/eclipse/emf/eef/views/presentation/ViewsEditorPlugin.java delete mode 100644 plugins/org.eclipse.emf.eef.views.editor/src-gen/org/eclipse/emf/eef/views/presentation/ViewsModelWizard.java delete mode 100644 plugins/org.eclipse.emf.eef.views/.checkstyle delete mode 100644 plugins/org.eclipse.emf.eef.views/.classpath delete mode 100644 plugins/org.eclipse.emf.eef.views/.gitignore delete mode 100644 plugins/org.eclipse.emf.eef.views/.project delete mode 100644 plugins/org.eclipse.emf.eef.views/.settings/org.eclipse.core.resources.prefs delete mode 100644 plugins/org.eclipse.emf.eef.views/.settings/org.eclipse.jdt.ui.prefs delete mode 100644 plugins/org.eclipse.emf.eef.views/META-INF/MANIFEST.MF delete mode 100644 plugins/org.eclipse.emf.eef.views/about.html delete mode 100644 plugins/org.eclipse.emf.eef.views/build.properties delete mode 100644 plugins/org.eclipse.emf.eef.views/model/views.ecore delete mode 100644 plugins/org.eclipse.emf.eef.views/model/views.ecorediag delete mode 100644 plugins/org.eclipse.emf.eef.views/model/views.genmodel delete mode 100644 plugins/org.eclipse.emf.eef.views/plugin.xml delete mode 100644 plugins/org.eclipse.emf.eef.views/pom.xml delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/toolkits/Toolkit.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/toolkits/ToolkitsFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/toolkits/ToolkitsPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/toolkits/Widget.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/toolkits/impl/ToolkitImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/toolkits/impl/ToolkitsFactoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/toolkits/impl/ToolkitsPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/toolkits/impl/WidgetImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/toolkits/util/ToolkitsAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/toolkits/util/ToolkitsSwitch.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/Category.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/Container.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/CustomElementEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/CustomView.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/DocumentedElement.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/ElementEditor.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/IdentifiedElement.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/View.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/ViewElement.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/ViewReference.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/ViewsFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/ViewsPackage.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/ViewsRepository.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/CategoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/ContainerImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/CustomElementEditorImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/CustomViewImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/DocumentedElementImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/ElementEditorImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/IdentifiedElementImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/ViewElementImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/ViewImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/ViewReferenceImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/ViewsFactoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/ViewsPackageImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/impl/ViewsRepositoryImpl.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/util/ViewsAdapterFactory.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src-gen/org/eclipse/emf/eef/views/util/ViewsSwitch.java delete mode 100644 plugins/org.eclipse.emf.eef.views/src/org/eclipse/emf/eef/views/helpers/NamingHelper.java delete mode 100644 plugins/org.eclipse.emf.eef.views/std/EMFProperties.toolkits delete mode 100644 plugins/org.eclipse.emf.eef.views/std/SWT.toolkits delete mode 100644 releng/org.eclipse.emf.eef.releng.parent/.gitignore delete mode 100644 releng/org.eclipse.emf.eef.releng.parent/.project delete mode 100644 releng/org.eclipse.emf.eef.releng.parent/Change Version.launch delete mode 100644 releng/org.eclipse.emf.eef.releng.parent/Clean.launch delete mode 100644 releng/org.eclipse.emf.eef.releng.parent/LocalBuild tycho (DEBUG).launch delete mode 100644 releng/org.eclipse.emf.eef.releng.parent/LocalBuild tycho.launch delete mode 100644 releng/org.eclipse.emf.eef.releng.parent/README.textile delete mode 100755 releng/org.eclipse.emf.eef.releng.parent/codestyle/EEFCheckstyleConfiguration.xml delete mode 100644 releng/org.eclipse.emf.eef.releng.parent/codestyle/EEFCodeTemplates.xml delete mode 100644 releng/org.eclipse.emf.eef.releng.parent/codestyle/EEFFormatter.xml delete mode 100644 releng/org.eclipse.emf.eef.releng.parent/pom.xml delete mode 100644 releng/org.eclipse.emf.eef.target/.project delete mode 100644 releng/org.eclipse.emf.eef.target/eef.target delete mode 100644 releng/org.eclipse.emf.eef.target/eef.tpd delete mode 100644 releng/org.eclipse.emf.eef.uml.update/.gitignore delete mode 100644 releng/org.eclipse.emf.eef.uml.update/.project delete mode 100644 releng/org.eclipse.emf.eef.uml.update/category.xml delete mode 100644 releng/org.eclipse.emf.eef.uml.update/pom.xml delete mode 100644 releng/org.eclipse.emf.eef.uml.update/publisher.properties delete mode 100644 releng/org.eclipse.emf.eef.update/.gitignore delete mode 100644 releng/org.eclipse.emf.eef.update/.project delete mode 100644 releng/org.eclipse.emf.eef.update/category.xml delete mode 100644 releng/org.eclipse.emf.eef.update/pom.xml delete mode 100644 releng/org.eclipse.emf.eef.update/publisher.properties delete mode 100644 tests/org.eclipse.emf.eef.nonreg.design/.classpath delete mode 100644 tests/org.eclipse.emf.eef.nonreg.design/.project delete mode 100644 tests/org.eclipse.emf.eef.nonreg.design/META-INF/MANIFEST.MF delete mode 100644 tests/org.eclipse.emf.eef.nonreg.design/bin/org/eclipse/emf/eef/nonreg/design/Activator.class delete mode 100644 tests/org.eclipse.emf.eef.nonreg.design/build.acceleo delete mode 100644 tests/org.eclipse.emf.eef.nonreg.design/build.properties delete mode 100644 tests/org.eclipse.emf.eef.nonreg.design/description/nonreg.odesign delete mode 100644 tests/org.eclipse.emf.eef.nonreg.design/plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.nonreg.design/src/org/eclipse/emf/eef/nonreg/design/Activator.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/.classpath delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/.gitignore delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/.project delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/.settings/org.eclipse.jdt.core.prefs delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/META-INF/MANIFEST.MF delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/build.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateAdvancedEObjectFlatComboViewerSample_advancedeobjectflatcomboviewerCompoOptionalProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateAdvancedEObjectFlatComboViewerSample_advancedeobjectflatcomboviewerCompoRequiredProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateAdvancedTableCompositionEditorSample_advancedtablecompositionOptionalProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateAdvancedTableCompositionEditorSample_advancedtablecompositionOptionalProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateAdvancedTableCompositionEditorSample_advancedtablecompositionROProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateAdvancedTableCompositionEditorSample_advancedtablecompositionRequiredProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateAdvancedTableCompositionEditorSample_advancedtablecompositionRequiredProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateAttributeNavigationSample_multiValuedAttributeDelegate_AttributeDelegate.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateAttributeNavigationSample_singleValuedAttributeDelegate_AttributeDelegate.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateConcreteReferenceOwnerSample_strictTyping2_ConcreteReferenceTargetSample1.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateConcreteReferenceOwnerSample_strictTyping2_ConcreteReferenceTargetSample2.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateConcreteReferenceOwnerSample_strictTyping2_ConcreteReferenceTargetSample3.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateConcreteReferenceOwnerSample_strictTyping3_ConcreteReferenceTargetSample1.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateConcreteReferenceOwnerSample_strictTyping3_ConcreteReferenceTargetSample2.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateConcreteReferenceOwnerSample_strictTyping3_ConcreteReferenceTargetSample3.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateConcreteReferenceOwnerSample_strictTyping_ConcreteReferenceTargetSample1.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateConcreteReferenceOwnerSample_strictTyping_ConcreteReferenceTargetSample2.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateConcreteReferenceOwnerSample_strictTyping_ConcreteReferenceTargetSample3.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateDeferedFlatReferenceTableEditorSample_references_DeferedReference.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateDeferedReferenceTableEditorSample_references_DeferedReference.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateFirstModelNavigation_secondModelNavigation_SecondModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateFirstModelNavigation_severalSecondModelNavigation_SecondModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleAdvancedReferencesTable_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleAdvancedReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleAdvancedReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForAdvancedTableComposition_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForAdvancedTableComposition_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForAdvancedTableComposition_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForFlatReferencesTable_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForFlatReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForFlatReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForReferencesTable_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForTableComposition_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForTableComposition_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleForTableComposition_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleampleAdvancedReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleampleAdvancedReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleampleForAdvancedTableComposition_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleampleForAdvancedTableComposition_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleampleForFlatReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleampleForFlatReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleampleForReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateMultipleReferencer_multipleSampleampleForReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateOwner_multipleReferencers_MultipleReferencer.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateOwner_referencers_Referencer.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateOwner_singleReferencers_SingleReferencer.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateReferencer_composedElement_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateReferencer_composedElement_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_AdvancedEObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_AdvancedReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_AdvancedTableCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_AttributeNavigationSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_CheckBoxExtendedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_CheckboxSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_ConcreteReferenceOwnerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_ConcreteReferenceTargetSample1.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_ConcreteReferenceTargetSample2.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_ConcreteReferenceTargetSample3.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_DeferedFlatReferenceTableEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_DeferedReferenceTableEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_EMFComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_EObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_EReferencesViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_Element.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_Event.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_FirstModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_FlatReferenceExtendedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_FlatReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_ImageViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_LinkEObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_LinkEReferenceViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_MultiValuedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_RadioSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_ReferenceEnabledSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_ReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_SecondModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_SelectionDialogSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_SingleCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_SingleCompositionViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_SmartModelNavigationSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_TableCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_TableCompositionExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_TableCompositionTargetExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_Tests.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_TextSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_TextSampleWithTwoTabs.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_TextareaSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateRoot_samples_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_AdvancedEObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_AdvancedReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_AdvancedTableCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_AttributeNavigationSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_CheckBoxExtendedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_CheckboxSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_ConcreteReferenceOwnerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_ConcreteReferenceTargetSample1.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_ConcreteReferenceTargetSample2.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_ConcreteReferenceTargetSample3.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_DeferedFlatReferenceTableEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_DeferedReferenceTableEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_EMFComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_EObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_EReferencesViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_Element.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_Event.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_FirstModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_FlatReferenceExtendedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_FlatReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_ImageViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_LinkEObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_LinkEReferenceViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_MultiValuedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_RadioSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_ReferenceEnabledSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_ReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_SecondModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_SelectionDialogSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_SingleCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_SingleCompositionViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_SmartModelNavigationSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_TableCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_TableCompositionExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_TableCompositionTargetExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_Tests.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_TextSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_TextSampleWithTwoTabs.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_TextareaSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOnAbstractOptionalProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorOptionalProperty_TextSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorROPropery_TextSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionEditorSample_singlecompositioneditorRequiredProperty_TextSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_AdvancedEObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_AdvancedReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_AdvancedTableCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_AttributeNavigationSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_CheckBoxExtendedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_CheckboxSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_ConcreteReferenceOwnerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_ConcreteReferenceTargetSample1.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_ConcreteReferenceTargetSample2.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_ConcreteReferenceTargetSample3.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_DeferedFlatReferenceTableEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_DeferedReferenceTableEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_EMFComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_EObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_EReferencesViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_Element.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_Event.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_FirstModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_FlatReferenceExtendedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_FlatReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_ImageViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_LinkEObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_LinkEReferenceViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_MultiValuedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_RadioSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_ReferenceEnabledSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_ReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_SecondModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_SelectionDialogSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_SingleCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_SingleCompositionViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_SmartModelNavigationSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_TableCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_TableCompositionExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_TableCompositionTargetExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_Tests.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_TextSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_TextSampleWithTwoTabs.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_TextareaSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiOptionalProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_AdvancedEObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_AdvancedReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_AdvancedTableCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_AttributeNavigationSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_CheckBoxExtendedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_CheckboxSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_ConcreteReferenceOwnerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_ConcreteReferenceTargetSample1.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_ConcreteReferenceTargetSample2.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_ConcreteReferenceTargetSample3.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_DeferedFlatReferenceTableEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_DeferedReferenceTableEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_EMFComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_EObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_EReferencesViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_Element.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_Event.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_FirstModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_FlatReferenceExtendedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_FlatReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_ImageViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_LinkEObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_LinkEReferenceViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_MultiValuedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_RadioSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_ReferenceEnabledSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_ReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_SecondModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_SelectionDialogSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_SingleCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_SingleCompositionViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_SmartModelNavigationSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_TableCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_TableCompositionExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_TableCompositionTargetExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_Tests.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_TextSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_TextSampleWithTwoTabs.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_TextareaSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewMultiRequiredProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewSingleOptionalProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewSingleROProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleCompositionViewerSample_singlecompositionviewSingleRequiredProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleContainmentForAdvancedEObjectFlatComboViewer_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleContainmentForAdvancedEObjectFlatComboViewer_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleContainmentForAdvancedEObjectFlatComboViewer_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleContainmentForEObjectFlatComboViewer_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleContainmentForEObjectFlatComboViewer_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleContainmentForEObjectFlatComboViewer_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleAdvancedReferencesTable_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleAdvancedReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleAdvancedReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForAdvancedTableComposition_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForAdvancedTableComposition_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForAdvancedTableComposition_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForFlatReferencesTable_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForFlatReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForFlatReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForReferencesTable_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForTableComposition_AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForTableComposition_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleForTableComposition_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleampleAdvancedReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleampleAdvancedReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleampleForAdvancedTableComposition_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleampleForAdvancedTableComposition_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleampleForFlatReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleampleForFlatReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleampleForReferencesTable_Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSingleReferencer_singleSampleampleForReferencesTable_Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSmartModelNavigationSample_firstModelNavigation2_FirstModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSmartModelNavigationSample_firstModelNavigation_FirstModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSmartModelNavigationSample_severalFirstModelNavigation2_FirstModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateSmartModelNavigationSample_severalFirstModelNavigation_FirstModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTableCompositionEditorSample_tablecompositionOptionalProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTableCompositionEditorSample_tablecompositionOptionalProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTableCompositionEditorSample_tablecompositionROProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTableCompositionEditorSample_tablecompositionRequiredProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTableCompositionEditorSample_tablecompositionRequiredProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTableCompositionExtensionEditorSample_tablecompositionOptionalProperty_TableCompositionTargetExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTableCompositionExtensionEditorSample_tablecompositionRequiredProperty_TableCompositionTargetExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_advancedtablecompositionOnSameTypeRequiredProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_advancedtablecompositionOnSameTypeRequiredProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_advancedtablecompositionOnSametypeOptionalProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_advancedtablecompositionOnSametypeOptionalProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_advancedtablecompositionOptionalProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_advancedtablecompositionOptionalProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_advancedtablecompositionROProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_advancedtablecompositionRequiredProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_advancedtablecompositionRequiredProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_tablecompositionOnSameTypeOptionalProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_tablecompositionOnSameTypeRequiredProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_tablecompositionOptionalProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_tablecompositionOptionalProperty_TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_tablecompositionROProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_tablecompositionRequiredProperty_Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/ctool16/CreateTotalSample_tablecompositionRequiredProperty_TextSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/AbstractReferenceOwnerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/AbstractReferenceTargetSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/AdvancedEObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/AdvancedReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/AdvancedTableCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/AnotherSubType.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/AttributeDelegate.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/AttributeNavigationSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/CheckBoxExtendedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/CheckboxSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/ConcreteReferenceOwnerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/ConcreteReferenceTargetSample1.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/ConcreteReferenceTargetSample2.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/ConcreteReferenceTargetSample3.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/DeferedFlatReferenceTableEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/DeferedReference.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/DeferedReferenceTableEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/EMFComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/EObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/EReferencesViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/Element.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/Event.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/FirstModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/FlatReferenceExtendedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/FlatReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/ImageViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/LinkEObjectFlatComboViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/LinkEReferenceViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/MultiValuedEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/MultipleReferencer.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/Owner.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/RadioSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/ReferenceEnabledSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/Referencer.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/ReferencesTableSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/Root.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/Sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/SecondModelNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/SelectionDialogSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/SimpleSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/SingleCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/SingleCompositionViewerSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/SingleReferencer.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/SmartModelNavigationSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/Subtype.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/TableCompositionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/TableCompositionExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/TableCompositionTargetExtensionEditorSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/Tests.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/TextSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/TextSampleWithTwoTabs.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/TextareaSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/full/obj16/TotalSample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/icons/sample.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/models/eefnr.components delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/models/eefnr.eefgen delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/plugin.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/pom.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-custom/org/eclipse/emf/eef/eefnr/providers/impl/EEFNRPropertiesEditingProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-custom/org/eclipse/emf/eef/eefnr/utils/Utils.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/eefnr_properties.plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/eefnrext_properties.plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/filters_properties.plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/interface_properties.plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/naming_properties.plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/navigation_properties.plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/AdvancedEObjectFlatComboViewerSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/AdvancedReferencesTableSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/AdvancedTableCompositionEditorSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/CheckboxSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/EMFComboViewerSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/EObjectFlatComboViewerSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/EReferencesViewerSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/FlatReferenceTableSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/ImageViewerSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/LinkEObjectFlatComboViewerSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/LinkEReferenceViewerSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/MultiValuedEditorSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/RadioSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/ReferencesTableSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/RootPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/SamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/SelectionDialogSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/SingleCompositionEditorSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/SingleCompositionViewerSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/TableCompositionEditorSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/TableCompositionExtensionEditorSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/TextSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/TextSampleWithTwoTabsPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/TextSampleWithTwoTabsTextSampleFirstTabPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/TextSampleWithTwoTabsTextSampleSecondTabPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/TextareaSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/components/TotalSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/parts/ConcreteReferenceOwnerSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/parts/ConcreteReferenceTargetSample1PropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/parts/ConcreteReferenceTargetSample2PropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/parts/FiltersViewsRepository.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/parts/forms/ConcreteReferenceOwnerSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/parts/forms/ConcreteReferenceTargetSample1PropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/parts/forms/ConcreteReferenceTargetSample2PropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/parts/impl/ConcreteReferenceOwnerSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/parts/impl/ConcreteReferenceTargetSample1PropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/parts/impl/ConcreteReferenceTargetSample2PropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/providers/FiltersMessages.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/providers/FiltersPropertiesEditionPartProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/providers/filtersMessages.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/filters/providers/filtersMessages_fr.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/interface_/parts/Interface_ViewsRepository.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/interface_/parts/SimpleSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/interface_/parts/forms/SimpleSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/interface_/parts/impl/SimpleSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/interface_/providers/Interface_Messages.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/interface_/providers/Interface_PropertiesEditionPartProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/interface_/providers/interface_Messages.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/interface_/providers/interface_Messages_fr.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/AnotherSubtypePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/AttributeNavigationSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/DeferedFlatReferencesTableSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/DeferedReferencesTableSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/ElementPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/EventPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/FirstNavigationSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/NamedElementPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/NamingViewsRepository.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/NavigationViewsRepository.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/OwnerPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/SecondNavigationSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/SmartNavigationSampleOnglet2PropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/SmartNavigationSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/SubtypePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/AnotherSubtypePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/AttributeNavigationSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/DeferedFlatReferencesTableSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/DeferedReferencesTableSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/ElementPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/EventPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/FirstNavigationSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/NamedElementPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/OwnerPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/SecondNavigationSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/SmartNavigationSampleOnglet2PropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/SmartNavigationSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/forms/SubtypePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/AnotherSubtypePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/AttributeNavigationSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/DeferedFlatReferencesTableSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/DeferedReferencesTableSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/ElementPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/EventPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/FirstNavigationSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/NamedElementPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/OwnerPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/SecondNavigationSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/SmartNavigationSampleOnglet2PropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/SmartNavigationSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/parts/impl/SubtypePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/providers/NamingMessages.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/providers/NamingPropertiesEditionPartProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/providers/NavigationMessages.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/providers/NavigationPropertiesEditionPartProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/providers/namingMessages.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/providers/namingMessages_fr.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/providers/navigationMessages.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/navigation/providers/navigationMessages_fr.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/AdvancedEObjectFlatComboViewerSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/AdvancedReferencesTableSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/AdvancedTableCompositionEditorSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/CheckboxSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/EMFComboViewerSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/EObjectFlatComboViewerSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/EReferencesViewerSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/EefnrViewsRepository.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/FlatReferenceTableSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/ImageViewerSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/LinkEObjectFlatComboViewerSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/LinkEReferenceViewerSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/MultiValuedEditorSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/RadioSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/ReferencesTableSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/RootPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/SamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/SelectionDialogSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/SingleCompositionEditorSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/SingleCompositionViewerSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/TableCompositionEditorSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/TableCompositionExtensionEditorSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/TextSampleFirstTabPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/TextSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/TextSampleSecondTabPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/TextareaSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/TotalSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/AdvancedEObjectFlatComboViewerSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/AdvancedReferencesTableSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/AdvancedTableCompositionEditorSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/CheckboxSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/EMFComboViewerSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/EObjectFlatComboViewerSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/EReferencesViewerSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/FlatReferenceTableSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/ImageViewerSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/LinkEObjectFlatComboViewerSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/LinkEReferenceViewerSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/MultiValuedEditorSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/RadioSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/ReferencesTableSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/RootPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/SamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/SelectionDialogSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/SingleCompositionEditorSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/SingleCompositionViewerSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/TableCompositionEditorSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/TableCompositionExtensionEditorSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/TextSampleFirstTabPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/TextSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/TextSampleSecondTabPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/TextareaSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/forms/TotalSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/AdvancedEObjectFlatComboViewerSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/AdvancedReferencesTableSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/AdvancedTableCompositionEditorSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/CheckboxSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/EMFComboViewerSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/EObjectFlatComboViewerSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/EReferencesViewerSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/FlatReferenceTableSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/ImageViewerSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/LinkEObjectFlatComboViewerSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/LinkEReferenceViewerSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/MultiValuedEditorSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/RadioSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/ReferencesTableSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/RootPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/SamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/SelectionDialogSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/SingleCompositionEditorSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/SingleCompositionViewerSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/TableCompositionEditorSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/TableCompositionExtensionEditorSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/TextSampleFirstTabPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/TextSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/TextSampleSecondTabPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/TextareaSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/parts/impl/TotalSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/AdvancedEObjectFlatComboViewerSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/AdvancedReferencesTableSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/AdvancedTableCompositionEditorSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/CheckboxSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/EMFComboViewerSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/EObjectFlatComboViewerSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/EReferencesViewerSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/EefnrEEFAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/EefnrMessages.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/EefnrPropertiesEditionPartProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/FlatReferenceTableSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/ImageViewerSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/LinkEObjectFlatComboViewerSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/LinkEReferenceViewerSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/MultiValuedEditorSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/RadioSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/ReferencesTableSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/RootPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/SamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/SelectionDialogSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/SingleCompositionEditorSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/SingleCompositionViewerSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/TableCompositionEditorSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/TableCompositionExtensionEditorSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/TextSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/TextSampleWithTwoTabsPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/TextareaSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/TotalSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/eefnrMessages.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/providers/eefnrMessages_fr.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/parts/AbstractEnabledSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/parts/AbstractSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/parts/ReferenceEnabledSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/parts/ReferencesViewsRepository.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/parts/forms/AbstractEnabledSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/parts/forms/AbstractSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/parts/forms/ReferenceEnabledSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/parts/impl/AbstractEnabledSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/parts/impl/AbstractSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/parts/impl/ReferenceEnabledSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/providers/ReferencesMessages.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/providers/ReferencesPropertiesEditionPartProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/providers/referencesMessages.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnr/references/providers/referencesMessages_fr.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/components/CheckBoxExtendedEditorSampleBasePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/components/CheckBoxExtendedEditorSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/components/FlatReferenceExtendedEditorSampleBasePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/components/FlatReferenceExtendedEditorSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/components/FlatReferenceExtendedEditorSampleSecondFlatReferenceExtendedEditorSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/components/TableCompositionTargetExtensionEditorSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/CheckBoxExtendedEditorSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/EefnrextViewsRepository.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/FlatReferenceExtendedEditorSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/SecondFlatReferenceExtendedEditorSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/TableCompositionTargetExtensionEditorSamplePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/forms/CheckBoxExtendedEditorSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/forms/FlatReferenceExtendedEditorSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/forms/SecondFlatReferenceExtendedEditorSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/forms/TableCompositionTargetExtensionEditorSamplePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/impl/CheckBoxExtendedEditorSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/impl/FlatReferenceExtendedEditorSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/impl/SecondFlatReferenceExtendedEditorSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/parts/impl/TableCompositionTargetExtensionEditorSamplePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/providers/CheckBoxExtendedEditorSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/providers/EefnrextEEFAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/providers/EefnrextMessages.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/providers/EefnrextPropertiesEditionPartProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/providers/FlatReferenceExtendedEditorSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/providers/TableCompositionTargetExtensionEditorSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/providers/eefnrextMessages.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/eefnrext/providers/eefnrextMessages_fr.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/filters/components/ConcreteReferenceOwnerSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/filters/components/ConcreteReferenceTargetSample1PropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/filters/components/ConcreteReferenceTargetSample2PropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/filters/providers/ConcreteReferenceOwnerSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/filters/providers/ConcreteReferenceTargetSample1PropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/filters/providers/ConcreteReferenceTargetSample2PropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/filters/providers/FiltersEEFAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/interface_/providers/Interface_EEFAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/naming/components/EventPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/naming/providers/EventPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/naming/providers/NamingEEFAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/AnotherSubtypeBasePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/AnotherSubtypePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/AttributeNavigationSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/DeferedFlatReferencesTableSampleEditorPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/DeferedReferencesTableSampleEditorPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/ElementBasePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/ElementPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/FirstModelNavigationSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/NamedElementPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/OwnerPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/SecondModelNavigationSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/SmartModelNavigationSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/SmartModelNavigationSampleSmartNavigationSampleOnglet2PropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/SmartModelNavigationSampleSmartNavigationSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/SubtypeBasePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/components/SubtypePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/AnotherSubtypePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/AttributeNavigationSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/DeferedFlatReferencesTableSampleEditorPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/DeferedReferencesTableSampleEditorPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/ElementPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/FirstModelNavigationSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/NamedElementPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/NavigationEEFAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/OwnerPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/SecondModelNavigationSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/SmartModelNavigationSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/navigation/providers/SubtypePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/references/components/AbstractEnabledSampleBasePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/references/components/AbstractEnabledSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/references/components/AbstractSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/references/components/ReferenceEnabledSampleBasePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/references/components/ReferenceEnabledSamplePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/references/providers/AbstractEnabledSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/references/providers/AbstractSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/references/providers/ReferenceEnabledSamplePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/org/eclipse/emf/eef/references/providers/ReferencesEEFAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src-gen/references_properties.plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/filters/provider/AbstractReferenceOwnerSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/filters/provider/AbstractReferenceTargetSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/filters/provider/ConcreteReferenceOwnerSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/filters/provider/ConcreteReferenceTargetSample1ItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/filters/provider/ConcreteReferenceTargetSample2ItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/filters/provider/ConcreteReferenceTargetSample3ItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/filters/provider/FiltersItemProviderAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/interface_/provider/InterfaceItemProviderAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/interface_/provider/SimpleSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/naming/provider/CustomNamingItemProviderAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/naming/provider/EventItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/AnotherSubTypeItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/AttributeDelegateItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/AttributeNavigationSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/DeferedFlatReferenceTableEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/DeferedReferenceItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/DeferedReferenceTableEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/ElementItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/FirstModelNavigationItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/MultipleReferencerItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/NavigationItemProviderAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/OwnerItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/SecondModelNavigationItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/SingleReferencerItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/SmartModelNavigationSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/navigation/provider/SubtypeItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/AbstractSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/AbstractTableCompositionTargetExtensionEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/AdvancedEObjectFlatComboViewerSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/AdvancedReferencesTableSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/AdvancedTableCompositionEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/CheckboxSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/EMFComboViewerSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/EObjectFlatComboViewerSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/EReferencesViewerSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/EefnrEditPlugin.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/EefnrItemProviderAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/FlatReferencesTableSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/ImageViewerSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/LinkEObjectFlatComboViewerSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/LinkEReferenceViewerSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/MultiValuedEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/NamedElementItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/RadioSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/ReferencesTableSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/RootItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/SampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/SelectionDialogSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/SingleCompositionEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/SingleCompositionViewerSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/TableCompositionEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/TableCompositionExtensionEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/TextSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/TextSampleWithTwoTabsItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/TextareaSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/provider/TotalSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/references/provider/AbstractEnabledSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/references/provider/ReferenceEnabledSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/references/provider/ReferencesItemProviderAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnr/references/provider/TestsItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnrext/provider/CheckBoxExtendedEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnrext/provider/EefnrextItemProviderAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnrext/provider/FlatReferenceExtendedEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/eefnrext/provider/TableCompositionTargetExtensionEditorSampleItemProvider.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/tests/nonreg/edit/actions/RemoveSingleCompositionEditorAction.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.edit/src/org/eclipse/emf/eef/tests/nonreg/edit/actions/SampleAction.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/.classpath delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/.gitignore delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/.project delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/META-INF/MANIFEST.MF delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/build.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/obj16/CustomNamingModelFile.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/obj16/EefnrModelFile.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/obj16/EefnrextModelFile.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/obj16/FiltersModelFile.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/obj16/InterfaceModelFile.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/obj16/NavigationModelFile.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/obj16/ReferencesModelFile.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/wizban/NewCustomNaming.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/wizban/NewEefnr.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/wizban/NewEefnrext.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/wizban/NewFilters.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/wizban/NewInterface.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/wizban/NewNavigation.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/icons/full/wizban/NewReferences.gif delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/plugin.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/pom.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/filters/presentation/FiltersActionBarContributor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/filters/presentation/FiltersEditor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/filters/presentation/FiltersModelWizard.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/interface_/presentation/InterfaceActionBarContributor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/interface_/presentation/InterfaceEditor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/interface_/presentation/InterfaceModelWizard.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/naming/presentation/CustomNamingActionBarContributor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/naming/presentation/CustomNamingEditor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/naming/presentation/CustomNamingModelWizard.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/navigation/presentation/NavigationActionBarContributor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/navigation/presentation/NavigationEditor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/navigation/presentation/NavigationModelWizard.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/presentation/EefnrActionBarContributor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/presentation/EefnrEditor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/presentation/EefnrEditorPlugin.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/presentation/EefnrModelWizard.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/references/presentation/ReferencesActionBarContributor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/references/presentation/ReferencesEditor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnr/references/presentation/ReferencesModelWizard.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnrext/presentation/EefnrextActionBarContributor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnrext/presentation/EefnrextEditor.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.editor/src/org/eclipse/emf/eef/eefnrext/presentation/EefnrextModelWizard.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/.classpath delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/.gitignore delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/.project delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/.settings/org.eclipse.jdt.core.prefs delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/META-INF/MANIFEST.MF delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/build.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/addAdvTableCompoOnAbstractRef.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/addTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/cancelAddTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/cancelSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/cancelSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/cancelSetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/redoAddTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/redoSetAttributeRadio.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/redoSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/redoSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/redoSetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/removeTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/setAttributeRadio.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/setReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/setReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/setReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/undoAddTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/undoSetAttributeRadio.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/undoSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/undoSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/undoSetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/unsetAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/unsetEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/unsetFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/unsetRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/unsetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/unsetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/unsetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/details_view_nonreg/unsetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/addTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/cancelAddTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/cancelSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/cancelSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/cancelSetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/editSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/editSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/editSetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/moveTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/redoAddTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/redoSetAttributeRadio.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/redoSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/redoSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/redoSetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/removeTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/setAttributeRadio.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/setReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/setReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/setReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/undoAddTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/undoSetAttributeRadio.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/undoSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/undoSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/undoSetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/unsetAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/unsetCombo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/unsetEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/unsetFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/unsetRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/unsetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/unsetReferenceCombo.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/unsetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/unsetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/propertiesView_nonreg/unsetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/addTableComposition.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/cancelAddTableComposition.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/cancelSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/cancelSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/cancelSetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/editSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/editSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/redoAddTableComposition.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/redoSetAttributeRadio.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/redoSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/redoSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/redoSetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/removeTableComposition.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/setAttributeRadio.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/setReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/setReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/setReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/undoAddTableComposition.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/undoSetAttributeRadio.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/undoSetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/undoSetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/undoSetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/unsetAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/unsetEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/unsetFlatReferencesTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/unsetReferenceAEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/unsetReferenceFlatRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/unsetReferenceRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/unsetReferencesTable.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/models/wizard_nonreg/unsetTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/pom.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/log4j.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/AllTests.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotAddAdvTableCompoOnAbstractRef.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotAddTableCompo.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotCancelAddTableCompo.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotCancelSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotCancelSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotCancelSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotRedoAddTableCompo.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotRedoSetAttributeRadio.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotRedoSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotRedoSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotRedoSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotRemoveTableCompo.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotSetAttributeRadio.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUndoAddTableCompo.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUndoSetAttributeRadio.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUndoSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUndoSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUndoSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUnsetAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUnsetEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUnsetFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUnsetRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUnsetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUnsetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUnsetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/composed/detailsview/ComposedMBotUnsetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotAddTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotCancelAddTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotCancelSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotCancelSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotCancelSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotEditSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotEditSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotEditSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotMoveTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotRedoAddTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotRedoSetAttributeRadio.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotRedoSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotRedoSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotRedoSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotRemoveTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotSetAttributeRadio.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUndoAddTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUndoSetAttributeRadio.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUndoSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUndoSetReferenceCombo.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUndoSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUndoSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUnsetAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUnsetEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUnsetFlatReferencesTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUnsetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUnsetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUnsetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUnsetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/propertiesView/PViewMBotUnsetReferencesTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotAddTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotCancelAddTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotCancelSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotCancelSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotCancelSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotEditSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotEditSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotRedoAddTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotRedoSetAttributeRadio.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotRedoSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotRedoSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotRedoSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotRemoveTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotSetAttributeRadio.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUndoAddTableComposition.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUndoSetAttributeRadio.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUndoSetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUndoSetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUndoSetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUnsetAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUnsetEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUnsetFlatReferencesTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUnsetReferenceAEOFCV.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUnsetReferenceFlatRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUnsetReferenceRefTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUnsetReferencesTable.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src-mbot/org/eclipse/emf/eef/tests/nonreg/wizard/WizardMBotUnsetTextArea.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg.junit/src/org/eclipse/emf/eef/tests/nonreg/junit/compositionsequence/TestCompositionSequence.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/.classpath delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/.gitignore delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/.project delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/META-INF/MANIFEST.MF delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/build.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/model/eefnr.ecore delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/model/eefnr.genmodel delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/model/eefnrext.ecore delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/plugin.properties delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/plugin.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/pom.xml delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/AbstractSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/AbstractTableCompositionTargetExtensionEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/AdvancedEObjectFlatComboViewerSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/AdvancedReferencesTableSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/AdvancedTableCompositionEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/CheckboxSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/EMFComboViewerSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/ENUM_SAMPLE.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/EObjectFlatComboViewerSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/EReferencesViewerSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/EefnrFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/EefnrPackage.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/FlatReferencesTableSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/ImageViewerSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/LinkEObjectFlatComboViewerSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/LinkEReferenceViewerSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/MultiValuedEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/NamedElement.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/RadioSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/ReferencesTableSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/Root.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/Sample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/SelectionDialogSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/SingleCompositionEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/SingleCompositionViewerSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/TableCompositionEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/TableCompositionExtensionEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/TextSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/TextSampleWithTwoTabs.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/TextareaSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/TotalSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/AbstractReferenceOwnerSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/AbstractReferenceTargetSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/ConcreteReferenceOwnerSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/ConcreteReferenceTargetSample1.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/ConcreteReferenceTargetSample2.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/ConcreteReferenceTargetSample3.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/FiltersFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/FiltersPackage.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/impl/AbstractReferenceOwnerSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/impl/AbstractReferenceTargetSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/impl/ConcreteReferenceOwnerSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/impl/ConcreteReferenceTargetSample1Impl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/impl/ConcreteReferenceTargetSample2Impl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/impl/ConcreteReferenceTargetSample3Impl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/impl/FiltersFactoryImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/impl/FiltersPackageImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/util/FiltersAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/filters/util/FiltersSwitch.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/AbstractSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/AbstractTableCompositionTargetExtensionEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/AdvancedEObjectFlatComboViewerSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/AdvancedReferencesTableSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/AdvancedTableCompositionEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/CheckboxSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/EMFComboViewerSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/EObjectFlatComboViewerSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/EReferencesViewerSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/EefnrFactoryImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/EefnrPackageImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/FlatReferencesTableSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/ImageViewerSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/LinkEObjectFlatComboViewerSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/LinkEReferenceViewerSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/MultiValuedEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/NamedElementImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/RadioSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/ReferencesTableSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/RootImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/SampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/SelectionDialogSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/SingleCompositionEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/SingleCompositionViewerSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/TableCompositionEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/TableCompositionExtensionEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/TextSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/TextSampleWithTwoTabsImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/TextareaSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/impl/TotalSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/interface_/InterfaceFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/interface_/InterfacePackage.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/interface_/SimpleSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/interface_/impl/InterfaceFactoryImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/interface_/impl/InterfacePackageImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/interface_/impl/SimpleSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/interface_/util/InterfaceAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/interface_/util/InterfaceSwitch.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/naming/CustomNamingFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/naming/CustomNamingPackage.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/naming/Event.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/naming/impl/CustomNamingFactoryImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/naming/impl/CustomNamingPackageImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/naming/impl/EventImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/naming/util/CustomNamingAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/naming/util/CustomNamingSwitch.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/AnotherSubType.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/AttributeDelegate.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/AttributeNavigationSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/DeferedFlatReferenceTableEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/DeferedReference.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/DeferedReferenceTableEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/Element.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/FirstModelNavigation.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/MultipleReferencer.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/NavigationFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/NavigationPackage.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/Owner.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/Referencer.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/SecondModelNavigation.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/SingleReferencer.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/SmartModelNavigationSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/Subtype.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/AnotherSubTypeImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/AttributeDelegateImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/AttributeNavigationSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/DeferedFlatReferenceTableEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/DeferedReferenceImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/DeferedReferenceTableEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/ElementImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/FirstModelNavigationImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/MultipleReferencerImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/NavigationFactoryImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/NavigationPackageImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/OwnerImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/SecondModelNavigationImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/SingleReferencerImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/SmartModelNavigationSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/impl/SubtypeImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/util/NavigationAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/navigation/util/NavigationSwitch.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/AbstractEnabledSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/ReferenceEnabledSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/ReferencesFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/ReferencesPackage.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/Tests.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/impl/AbstractEnabledSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/impl/ReferenceEnabledSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/impl/ReferencesFactoryImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/impl/ReferencesPackageImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/impl/TestsImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/util/ReferencesAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/references/util/ReferencesSwitch.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/util/EefnrAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnr/util/EefnrSwitch.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/CheckBoxExtendedEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/EefnrextFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/EefnrextPackage.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/FlatReferenceExtendedEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/TableCompositionTargetExtensionEditorSample.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/impl/CheckBoxExtendedEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/impl/EefnrextFactoryImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/impl/EefnrextPackageImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/impl/FlatReferenceExtendedEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/impl/TableCompositionTargetExtensionEditorSampleImpl.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/util/EefnrextAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.eef.tests.nonreg/src/org/eclipse/emf/eef/eefnrext/util/EefnrextSwitch.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/.classpath delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/.gitignore delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/.project delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/META-INF/MANIFEST.MF delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/build.properties delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/ctool16/CreateConference_participants_Person.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/ctool16/CreateConference_sites_Site.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/ctool16/CreateConference_talks_Talk.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/ctool16/CreateConference_topics_Topic.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/ctool16/CreateEclipseSummit_participants_Person.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/ctool16/CreateEclipseSummit_sites_Site.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/ctool16/CreateEclipseSummit_talks_Talk.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/ctool16/CreateEclipseSummit_topics_Topic.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/ctool16/CreateSite_rooms_Room.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/obj16/Conference.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/obj16/EclipseSummit.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/obj16/Person.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/obj16/Room.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/obj16/Site.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/obj16/Talk.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/icons/full/obj16/Topic.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/models/conference-editor.components delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/models/conference-editor.eefgen delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/models/conference.components delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/models/conference.eefgen delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/plugin.properties delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/plugin.xml delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/pom.xml delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/conference_properties.plugin.xml delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/ConferenceBasePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/ConferenceLocalisationPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/ConferenceParticipantsPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/ConferencePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/ConferenceTalksAndTopicsPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/PersonBasePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/PersonPresencePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/PersonPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/RoomPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/SitePropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/TalkPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/components/TopicPropertiesEditionComponent.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/ConferencePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/ConferenceViewsRepository.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/LocalisationPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/ParticipantsPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/PersonPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/PresencePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/RoomPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/SitePropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/TalkPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/TalksAndTopicsPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/TopicPropertiesEditionPart.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/forms/ConferencePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/forms/LocalisationPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/forms/ParticipantsPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/forms/PersonPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/forms/PresencePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/forms/RoomPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/forms/SitePropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/forms/TalkPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/forms/TalksAndTopicsPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/forms/TopicPropertiesEditionPartForm.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/impl/ConferencePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/impl/LocalisationPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/impl/ParticipantsPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/impl/PersonPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/impl/PresencePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/impl/RoomPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/impl/SitePropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/impl/TalkPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/impl/TalksAndTopicsPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/parts/impl/TopicPropertiesEditionPartImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/provider/ConferenceEditPlugin.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/provider/ConferenceItemProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/provider/ConferenceItemProviderAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/provider/PersonItemProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/provider/RoomItemProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/provider/SiteItemProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/provider/TalkItemProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/provider/TopicItemProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/ConferenceEEFAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/ConferenceMessages.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/ConferencePropertiesEditionPartProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/ConferencePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/PersonPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/RoomPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/SitePropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/TalkPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/TopicPropertiesEditionProvider.java delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/conferenceMessages.properties delete mode 100644 tests/org.eclipse.emf.examples.eef.edit/src-gen/org/eclipse/emf/samples/conference/providers/conferenceMessages_fr.properties delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/.classpath delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/.gitignore delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/.project delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/META-INF/MANIFEST.MF delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/build.properties delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/icons/full/obj16/ConferenceModelFile.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/icons/full/wizban/NewConference.gif delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/plugin.properties delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/plugin.xml delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/pom.xml delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/src-gen/org/eclipse/emf/samples/conference/presentation/ConferenceActionBarContributor.java delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/src-gen/org/eclipse/emf/samples/conference/presentation/ConferenceEditor.java delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/src-gen/org/eclipse/emf/samples/conference/presentation/ConferenceEditorPlugin.java delete mode 100644 tests/org.eclipse.emf.examples.eef.editor/src-gen/org/eclipse/emf/samples/conference/presentation/ConferenceModelWizard.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/.classpath delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/.gitignore delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/.project delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/META-INF/MANIFEST.MF delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/build.properties delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/input/input.conference delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/addAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/cancelAddAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/cancelSetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/cancelSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/cancelSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/redoAddAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/redoSetAttributeCheckbox.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/redoSetAttributeEMFComboViewer.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/redoSetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/redoSetAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/redoSetAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/redoSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/redoSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/removeAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/setAttributeCheckbox.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/setAttributeEMFComboViewer.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/setAttributeInteger.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/setAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/setAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/setAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/setReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/setReferenceAdvRefTable2.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/setReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/undoAddAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/undoSetAttributeCheckbox.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/undoSetAttributeEMFComboViewer.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/undoSetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/undoSetAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/undoSetAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/undoSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/undoSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/unsetAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/unsetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/unsetAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/unsetAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/unsetMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/unsetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/unsetText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/details_view_conference/unsetTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/addAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/cancelAddAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/cancelSetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/cancelSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/cancelSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/editSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/editSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/moveAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/redoAddAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/redoSetAttributeCheckbox.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/redoSetAttributeEMFComboViewer.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/redoSetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/redoSetAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/redoSetAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/redoSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/redoSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/removeAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/setAttributeCheckbox.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/setAttributeEMFComboViewer.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/setAttributeInteger.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/setAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/setAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/setAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/setReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/setReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/undoAddAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/undoSetAttributeCheckbox.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/undoSetAttributeEMFComboViewer.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/undoSetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/undoSetAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/undoSetAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/undoSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/undoSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/unsetAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/unsetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/unsetAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/unsetAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/unsetMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/unsetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/unsetText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/propertiesView_conference/unsetTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/addAdvancedTableComposition.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/cancelAddAdvancedTableComposition.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/cancelSetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/cancelSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/cancelSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/editSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/editSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/redoAddAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/redoSetAttributeCheckbox.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/redoSetAttributeEMFComboViewer.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/redoSetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/redoSetAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/redoSetAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/redoSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/redoSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/removeAdvancedTableComposition.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/setAttributeCheckbox.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/setAttributeEMFComboViewer.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/setAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/setAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/setAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/setReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/setReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/undoAddAdvTableCompo.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/undoSetAttributeCheckbox.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/undoSetAttributeEMFComboViewer.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/undoSetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/undoSetAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/undoSetAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/undoSetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/undoSetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/unsetAdvancedReferencesTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/unsetAttributeMVE.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/unsetAttributeText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/unsetAttributeTextArea.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/unsetReferenceAdvRefTable.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/unsetReferenceEOFCV.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/models/modelingbot/wizard_conference/unsetText.modelingbot delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/pom.xml delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/log4j.xml delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/AllTests.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotAddAdvTableCompo.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotCancelAddAdvTableCompo.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotCancelSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotCancelSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotCancelSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotRedoAddAdvTableCompo.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotRedoSetAttributeCheckbox.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotRedoSetAttributeEMFComboViewer.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotRedoSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotRedoSetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotRedoSetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotRedoSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotRedoSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotRemoveAdvTableCompo.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotSetAttributeCheckbox.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotSetAttributeEMFComboViewer.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotSetAttributeInteger.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotSetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotSetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotSetReferenceAdvRefTable2.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUndoAddAdvTableCompo.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUndoSetAttributeCheckbox.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUndoSetAttributeEMFComboViewer.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUndoSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUndoSetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUndoSetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUndoSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUndoSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUnsetAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUnsetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUnsetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUnsetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUnsetMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUnsetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUnsetText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/composed/detailsview/conference/ComposedMBotUnsetTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotAddAdvanceTableComposition.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotCancelAddAdvanceTableComposition.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotCancelSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotCancelSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotCancelSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotEditSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotEditSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotMoveAdvanceTableComposition.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotRedoSetAttributeCheckbox.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotRedoSetAttributeEMFComboViewer.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotRedoSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotRedoSetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotRedoSetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotRedoSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotRedoSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotRemoveAdvanceTableComposition.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotSetAttributeCheckbox.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotSetAttributeEMFComboViewer.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotSetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotSetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUndoAddAdvanceTableComposition.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUndoSetAttributeCheckbox.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUndoSetAttributeEMFComboViewer.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUndoSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUndoSetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUndoSetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUndoSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUndoSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUnsetAdvancedRefrencesTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUnsetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUnsetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUnsetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUnsetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUnsetText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/propertiesView/conference/PViewMBotUnsetTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotAddAdvanceTableComposition.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotCancelAddAdvanceTableComposition.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotCancelSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotCancelSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotCancelSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotEditSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotEditSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotRedoAddAdvanceTableComposition.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotRedoSetAttributeCheckbox.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotRedoSetAttributeEMFComboViewer.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotRedoSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotRedoSetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotRedoSetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotRedoSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotRedoSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotRemoveAdvanceTableComposition.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotSetAttributeCheckbox.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotSetAttributeEMFComboViewer.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotSetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotSetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUndoAddAdvanceTableComposition.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUndoSetAttributeCheckbox.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUndoSetAttributeEMFComboViewer.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUndoSetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUndoSetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUndoSetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUndoSetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUndoSetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUnsetAdvancedRefrencesTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUnsetAttributeMVE.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUnsetAttributeText.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUnsetAttributeTextArea.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUnsetReferenceAdvRefTable.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUnsetReferenceEOFCV.java delete mode 100644 tests/org.eclipse.emf.examples.eef.tests.junit/src/org/eclipse/emf/samples/tests/junit/modelingbot/wizard/conference/WizardMBotUnsetText.java delete mode 100644 tests/org.eclipse.emf.examples.eef/.classpath delete mode 100644 tests/org.eclipse.emf.examples.eef/.gitignore delete mode 100644 tests/org.eclipse.emf.examples.eef/.project delete mode 100644 tests/org.eclipse.emf.examples.eef/.settings/org.eclipse.core.resources.prefs delete mode 100644 tests/org.eclipse.emf.examples.eef/META-INF/MANIFEST.MF delete mode 100644 tests/org.eclipse.emf.examples.eef/build.properties delete mode 100644 tests/org.eclipse.emf.examples.eef/model/conference.ecore delete mode 100644 tests/org.eclipse.emf.examples.eef/model/conference.ecorediag delete mode 100644 tests/org.eclipse.emf.examples.eef/model/conference.genmodel delete mode 100644 tests/org.eclipse.emf.examples.eef/plugin.properties delete mode 100644 tests/org.eclipse.emf.examples.eef/plugin.xml delete mode 100644 tests/org.eclipse.emf.examples.eef/pom.xml delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/Conference.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/ConferenceFactory.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/ConferencePackage.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/GENDER.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/Person.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/Room.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/Site.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/TALK_TYPE.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/Talk.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/Topic.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/impl/ConferenceFactoryImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/impl/ConferenceImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/impl/ConferencePackageImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/impl/PersonImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/impl/RoomImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/impl/SiteImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/impl/TalkImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/impl/TopicImpl.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/util/ConferenceAdapterFactory.java delete mode 100644 tests/org.eclipse.emf.examples.eef/src-gen/org/eclipse/emf/samples/conference/util/ConferenceSwitch.java diff --git a/doc/org.eclipse.emf.eef.doc/.classpath b/doc/org.eclipse.emf.eef.doc/.classpath deleted file mode 100644 index 64c5e31b7..000000000 --- a/doc/org.eclipse.emf.eef.doc/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/doc/org.eclipse.emf.eef.doc/.gitignore b/doc/org.eclipse.emf.eef.doc/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/doc/org.eclipse.emf.eef.doc/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/doc/org.eclipse.emf.eef.doc/.project b/doc/org.eclipse.emf.eef.doc/.project deleted file mode 100644 index 3bc84c601..000000000 --- a/doc/org.eclipse.emf.eef.doc/.project +++ /dev/null @@ -1,34 +0,0 @@ - - - org.eclipse.emf.eef.doc - - - - - - org.eclipse.mylyn.wikitext.ui.wikiTextValidationBuilder - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.mylyn.wikitext.ui.wikiTextNature - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/doc/org.eclipse.emf.eef.doc/.settings/org.eclipse.core.resources.prefs b/doc/org.eclipse.emf.eef.doc/.settings/org.eclipse.core.resources.prefs deleted file mode 100644 index e0e89ab7c..000000000 --- a/doc/org.eclipse.emf.eef.doc/.settings/org.eclipse.core.resources.prefs +++ /dev/null @@ -1,5 +0,0 @@ -#Mon Sep 28 17:45:15 CEST 2009 -eclipse.preferences.version=1 -encoding//html/tutorial-toc.xml=utf-8 -encoding//html/tutorial.html=utf-8 -encoding//html/tutorial.mediawiki=UTF-8 diff --git a/doc/org.eclipse.emf.eef.doc/META-INF/MANIFEST.MF b/doc/org.eclipse.emf.eef.doc/META-INF/MANIFEST.MF deleted file mode 100644 index 07cb027e8..000000000 --- a/doc/org.eclipse.emf.eef.doc/META-INF/MANIFEST.MF +++ /dev/null @@ -1,10 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Documentation -Bundle-SymbolicName: org.eclipse.emf.eef.doc;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Vendor: Eclipse Modeling Project -Require-Bundle: org.eclipse.ui;bundle-version="3.4.0", - org.eclipse.core.runtime;bundle-version="3.4.0" -Bundle-ActivationPolicy: lazy -Bundle-RequiredExecutionEnvironment: J2SE-1.5 diff --git a/doc/org.eclipse.emf.eef.doc/about.html b/doc/org.eclipse.emf.eef.doc/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/doc/org.eclipse.emf.eef.doc/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/doc/org.eclipse.emf.eef.doc/build-help.xml b/doc/org.eclipse.emf.eef.doc/build-help.xml deleted file mode 100644 index 93a002ec8..000000000 --- a/doc/org.eclipse.emf.eef.doc/build-help.xml +++ /dev/null @@ -1,54 +0,0 @@ - - - - - Generate Eclipse help content - - - - - - - - - - - - - - - - - - - - - - - - = Updating This Document = - - This document is maintained in a collaborative wiki. If you wish to - update or modify this document please visit - {url} - - - - - - - - diff --git a/doc/org.eclipse.emf.eef.doc/build.properties b/doc/org.eclipse.emf.eef.doc/build.properties deleted file mode 100644 index 8afc88729..000000000 --- a/doc/org.eclipse.emf.eef.doc/build.properties +++ /dev/null @@ -1,21 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ - html/,\ - pics/,\ - about.html -output.. = bin/ -src.includes = pics/,\ - html/,\ - about.html diff --git a/doc/org.eclipse.emf.eef.doc/html/tutorial-toc.xml b/doc/org.eclipse.emf.eef.doc/html/tutorial-toc.xml deleted file mode 100644 index b979a04fd..000000000 --- a/doc/org.eclipse.emf.eef.doc/html/tutorial-toc.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/doc/org.eclipse.emf.eef.doc/html/tutorial.html b/doc/org.eclipse.emf.eef.doc/html/tutorial.html deleted file mode 100644 index 87ef8bd2d..000000000 --- a/doc/org.eclipse.emf.eef.doc/html/tutorial.html +++ /dev/null @@ -1,119 +0,0 @@ -

First generation

This first tutorial will show you the common use of EEF. It describes the steps to obtain the EEF models and generate the associated code. Finally, it shows how to link the generated code with a simple EMF treeview editor.

Environment

To do this tutorial, you need to have an "EEF ready" environment. To obtain this environment, read the EEF Installation Guide.

EEF Models initialization

In the EEF environment, the first step is to initialize the EEF models. These models describe the visual elements of the generated editing components and the binding between these elements and the meta-classes of your meta-model. EEF provides an action to create these models. To call this action, perform a right click on the .genmodel file generated from your metamodel and select the action EEF > Initialize EEF models.

Generation and parameterization

The initializer has just created elements for meta-class attributes choosing predefined default widgets. So you need to parameterize the EEF models to model correctly the generation. For example, references representations, widgets changes...

By default, the generation is done in the plug-in project where the example model is. The parameterization model assigns a "src-gen" directory to know where the code is going to be generated. This information can be modified.

When parameterization is done, generation can be called with the action "Generate EEF Architecture", just right click on the EEFGen model.

The generation creates an architecture displaying properties views corresponding to the parametrized models. What is generated is :

Global providers are also generated. They defined the structure instantiation and the elements edition strategies. Two providers have to be declared in the plugin.xml file with the extension points defined by the EEF runtime (explained in the next part : EEF generation with EMF treeview editor).

EEF Generation in EMF treeview editor

Add dependency on EEF runtime

In order to compile the generated code, the plug-in with the generated code must have a dependency on the EEF runtime : "org.eclipse.emf.eef.runtime". The treeview editor also have to depend on it.

Extension points declaration

For the generation, EEF creates two generic providers which have to be configured with extension points in the project where the code is generated. The extension point declares a "PropertiesEditionProviders" and a "PropertieEditionPolicyProviders".

Here is an example for the demo project :

<extension
-       point="org.eclipse.emf.eef.runtime.PropertiesEditionProvider">
-  <PropertiesEditionComponentProvider
-       providerClass="org.eclipse.emf.eef.nonreg.providers.NonregPackagePropertiesEditionProvider">
-  </PropertiesEditionComponentProvider>
-</extension>
-<extension
-     point="org.eclipse.emf.eef.runtime.PropertiesEditionPolicyProvider">
-  <PropertiesEditionPolicyProvider
-       providerClass="org.eclipse.emf.eef.nonreg.providers.NonregPackagePropertiesEditionPolicyProvider">
-  </PropertiesEditionPolicyProvider>
-</extension>
-<extension
-     point="org.eclipse.emf.eef.runtime.PropertiesEditionPartProvider">
-  <PropertiesEditionPartProvider
-       providerClass="org.eclipse.emf.eef.nonreg.providers.NonregPropertiesEditionPartProvider">
-  </PropertiesEditionPartProvider>
-</extension>
-

Extension points to declare properties views in the editor project have also to be added. They are generated in the file "src-gen/properties.plugin.xml". For example :

<extension
-        point="org.eclipse.ui.views.properties.tabbed.propertyContributor">
-     <propertyContributor
-           contributorId="org.eclipse.emf.eef.components.properties">
-        <propertyCategory
-              category="default">
-        </propertyCategory>
-        <propertyCategory
-              category="extended">
-        </propertyCategory>
-        <propertyCategory
-              category="advanced">
-        </propertyCategory>
-     </propertyContributor>
-  </extension>
-  <extension
-        point="org.eclipse.ui.views.properties.tabbed.propertyTabs">
-     <propertyTabs
-           contributorId="org.eclipse.emf.eef.components.properties">
-        <propertyTab
-              label="Base"
-              category="default"
-              id="Base">
-        </propertyTab>
-     </propertyTabs>
-  </extension>
-  <extension
-        point="org.eclipse.ui.views.properties.tabbed.propertySections">
-     <propertySections
-           contributorId="org.eclipse.emf.eef.components.properties">
-        <propertySection
-              tab="Base"
-              class="org.eclipse.emf.eef.runtime.ui.properties.sections.PropertiesEditionSection"
-              id="org.eclipse.emf.eef.components.section.PropertiesEditionContext">
-            <input
-                   type="org.eclipse.emf.eef.components.PropertiesEditionContext">
-            </input>
-        </propertySection>
-        <propertySection
-              tab="Base"
-              class="org.eclipse.emf.eef.runtime.ui.properties.sections.PropertiesEditionSection"
-              id="org.eclipse.emf.eef.components.section.PropertiesEditionComponent">
-            <input
-                   type="org.eclipse.emf.eef.components.PropertiesEditionComponent">
-            </input>
-        </propertySection>
-        <propertySection
-              tab="Base"
-              class="org.eclipse.emf.eef.runtime.ui.properties.sections.PropertiesEditionSection"
-              id="org.eclipse.emf.eef.components.section.PropertiesEditionElement">
-            <input
-                   type="org.eclipse.emf.eef.components.PropertiesEditionElement">
-            </input>
-        </propertySection>
-        <propertySection
-              tab="Base"
-              class="org.eclipse.emf.eef.runtime.ui.properties.sections.PropertiesEditionSection"
-              id="org.eclipse.emf.eef.components.section.PropertiesMultiEditionElement">
-            <input
-                   type="org.eclipse.emf.eef.components.PropertiesMultiEditionElement">
-            </input>
-        </propertySection>
-     </propertySections>
-  </extension>
-

EMF treeview editor modification

The standard EMF codegen generates an editor that uses standard properties views (with grid layout). So, you need to update it to use the EEF properties view (with tabs).

You might create a dependency between the EEF runtime ('org.eclipse.emf.eef.runtime') and the EMF generated editor plugin.

Open the XYZEditor.java located in the EMF generated xxx.editor plugin.

/** (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor#getContributorId()
- * @generated NOT
- */
-public String getContributorId() {
-    return PROPERTIES_CONTRIBUTOR;
-}
-

For example, for our example demo :

public static final String PROPERTIES_CONTRIBUTOR = "org.eclipse.emf.eef.nonreg.properties";
-

The original code :

protected PropertySheetPage propertySheetPage;
-

becomes

protected TabbedPropertySheetPage propertySheetPage;
-

The original code : -

 public IPropertySheetPage getPropertySheetPage() {
-     if (propertySheetPage == null) {
-         propertySheetPage = new ExtendedPropertySheetPage(editingDomain) {
-               @Override
-               public void setSelectionToViewer(List<?> selection) {
-                    NonregEditor.this.setSelectionToViewer(selection);
-                    NonregEditor.this.setFocus();
-               }
-               @Override
-               public void setActionBars(IActionBars actionBars) {
-                    super.setActionBars(actionBars);
-                    getActionBarContributor().shareGlobalActions(this, actionBars);
-               }
-        };
-        propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory));
-     }
-     return propertySheetPage;
-}
-

becomes

 public IPropertySheetPage getPropertySheetPage() {
-     if (propertySheetPage == null || propertySheetPage.getControl().isDisposed()) {
-        propertySheetPage = new TabbedPropertiesEditionSheetPage(XXXEditor.this);
-     }
-     return propertySheetPage;
- }
-

selectionViewer.addDoubleClickListener(new OpenWizardOnDoubleClick(editingDomain));
-

\ No newline at end of file diff --git a/doc/org.eclipse.emf.eef.doc/html/tutorial.mediawiki b/doc/org.eclipse.emf.eef.doc/html/tutorial.mediawiki deleted file mode 100644 index 3d64f7508..000000000 --- a/doc/org.eclipse.emf.eef.doc/html/tutorial.mediawiki +++ /dev/null @@ -1,209 +0,0 @@ -= First generation = -This first tutorial will show you the common use of EEF. It describes the steps to obtain the EEF models and generate the associated code. Finally, it shows how to link the generated code with a simple EMF treeview editor. - -== Environment == -To do this tutorial, you need to have an "EEF ready" environment. To obtain this environment, read the [[EEF Installation Guide]]. - -== EEF Models initialization == -In the EEF environment, the first step is to initialize the EEF models. These models describe the visual elements of the generated editing components and the binding between these elements and the meta-classes of your meta-model. EEF provides an action to create these models. To call this action, perform a right click on the .genmodel file generated from your metamodel and select the action ''EEF > Initialize EEF models''. - -[[Image:../pics/initializeEEFmodels.png|center]] - -== Generation and parameterization == -The initializer has just created elements for meta-class attributes choosing predefined default widgets. So you need to parameterize the EEF models to model correctly the generation. For example, references representations, widgets changes... - -By default, the generation is done in the plug-in project where the example model is. The parameterization model assigns a "src-gen" directory to know where the code is going to be generated. This information can be modified. - -When parameterization is done, generation can be called with the action "Generate EEF Architecture", just right click on the EEFGen model. - -[[Image:../pics/generateEEFArchitecture.png|center]] - -The generation creates an architecture displaying properties views corresponding to the parametrized models. What is generated is : -* Components for the control part -* Parts for views -* Providers for the structure instantiation - -Global providers are also generated. They defined the structure instantiation and the elements edition strategies. Two providers have to be declared in the plugin.xml file with the extension points defined by the EEF runtime (explained in the next part : [[#EEF generation with EMF treeview editor]]). - - -== EEF Generation in EMF treeview editor == - -=== Add dependency on EEF runtime === -In order to compile the generated code, the plug-in with the generated code must have a dependency on the EEF runtime : "org.eclipse.emf.eef.runtime". The treeview editor also have to depend on it. - -=== Extension points declaration === -For the generation, EEF creates two generic providers which have to be configured with extension points in the project where the code is generated. The extension point declares a "PropertiesEditionProviders" and a "PropertieEditionPolicyProviders". - -Here is an example for the demo project : - - - - - - - - - - - - - - - - -Extension points to declare properties views in the editor project have also to be added. They are generated in the file "src-gen/properties.plugin.xml". For example : - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -=== EMF treeview editor modification === -The standard EMF codegen generates an editor that uses standard properties views (with grid layout). So, you need to update it to use the EEF properties view (with tabs). - -You might create a dependency between the EEF runtime ('org.eclipse.emf.eef.runtime') and the EMF generated editor plugin. - -Open the XYZEditor.java located in the EMF generated xxx.editor plugin. - -*The editor must implement an additional interface : ''"org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor"'' - -*With this interface, you have to implement the methods ''"getContributorId()"'' - - - /** (non-Javadoc) - * @see org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor#getContributorId() - * @generated NOT - */ - public String getContributorId() { - return PROPERTIES_CONTRIBUTOR; - } - - -*The identifier returned by this method is a constant which is added to the editor. It is generated by EEF with the following pattern : ''"..properties"''. -For example, for our example demo : - - - public static final String PROPERTIES_CONTRIBUTOR = "org.eclipse.emf.eef.nonreg.properties"; - - -*Then, you need to replace the declaration of the Eclipse standard properties view by a tabbed properties view. -The original code : - - - protected PropertySheetPage propertySheetPage; - - -becomes - - - protected TabbedPropertySheetPage propertySheetPage; - - -*Replace also its instantiation, done in the method ''"getPropertySheetPage()"'' : - -The original code : - - public IPropertySheetPage getPropertySheetPage() { - if (propertySheetPage == null) { - propertySheetPage = new ExtendedPropertySheetPage(editingDomain) { - @Override - public void setSelectionToViewer(List selection) { - NonregEditor.this.setSelectionToViewer(selection); - NonregEditor.this.setFocus(); - } - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - }; - propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory)); - } - return propertySheetPage; - } - - -becomes - - - public IPropertySheetPage getPropertySheetPage() { - if (propertySheetPage == null || propertySheetPage.getControl().isDisposed()) { - propertySheetPage = new TabbedPropertiesEditionSheetPage(XXXEditor.this); - } - return propertySheetPage; - } - - -*Finally, it is possible to add properties edition wizard on double click on a tree element. You just have to call the following listener in the method ''"createPages()"'' in the editor (on the selectionViewer) : - - - selectionViewer.addDoubleClickListener(new OpenWizardOnDoubleClick(editingDomain)); - diff --git a/doc/org.eclipse.emf.eef.doc/pics/generateEEFArchitecture.png b/doc/org.eclipse.emf.eef.doc/pics/generateEEFArchitecture.png deleted file mode 100644 index 572540b6478072fb1f03384d99f686dc48c76d1c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 10067 zcmaL7Wl&tp7w!!Mfx!od!QI{62A3cqSa2raqNa6pS&^#k!RqsZ4Cs{>F_+BIpalsU+avNF8e2Bo_cogpyy?7|j5;>hea*TVBA>3< zP*x^|1wxDGk-|3HY9kr{5!D>W(PT7Bn=ngLpvFU%I{d?b=)`Z)q;0_oF8f3em_b43 z{d-0b@M*f4bnVT6q%FwP=b3w|wJp5bg~wlpSlkcvuR~6B(gH?BPCDlQEG-g#VKZkD zNwDPq)aM7HRfG+rmB&6V~9YM6dK~Q9y`@kd)6|3_bGdqet~PACHTH$!e!& zB36WL%r^+jN0(TcSs?~VK3V7UHFsn}PQ38&@Vz7$xfDcX@s+dZT1DIiD>#U6C36477_Mkq>@NsR@*-|iB6?1l4*bDX$_e_BxBTk#PDcF zHUfVa2{+_?OIgqE&K)sE*@{Z2?`5k0K`IfE@1z5kMo2SNO)Hda1X-lEbb4E z95U?9agUQYu^czJp4`Lbt9P|7`S7WY$6fk-Y-fAZazZfs`%-+>bBnaZZ%(>`WDmE~ zsltGsPN|k(5b*tL-fGxBZ?g-}HkF=2_;PsK9OjbyY0AC9f+-|uC~tnax-6bNT5Pax zBTi*0^;tkFCt+EZ_jbh1$+oxVsj%mz@M?NXr=T4R=nnuXSIoOTRZ&?iG$O=P z&0~n?fnY~tX{+9hbez83`tm|O0yxqFL=I4gGI2>HmU=LGoiEjH!*zo4Z%{=Gut=%E zU(t95PTyVv9ZOLS`!-G5Mal%E&JhQ1ZDWCpogT-CDV-QGYWS++bVGH*KRG@>`v6MO zf_FxOsPH;BNnxq(_HEjET`^st*EYNEa z&3f766o9d=)2ZWbrjT;F^Y0jcMRu6agkT zn;u%HO4ESW&(cwPtQh;b+@$>Kqphv@C5(j8PXNI@o(0h-vcg}zYaq=1XmRtmwXf04 z7k&8d$iJ|H>~98m6`S}CZlB{>&*HXkPh)C{a*e($!j)P55Oc*;akN56%Bd~l&&E)1 zO1dA6uY2A`S?47$M)+7dK5v6NOm!%#v}cVGGvha#n2{T)yuz9f9%@WZ;5$O`?YDld zfi&~hWDY8Y_ec;V`awGH8LoSdxXe;c>BR3^R%eb#S4FE1vH+aB+2@@8P$i=JOX zPlgg$EaTrPsZ_D@0x7FQ>+U;eg$u-R{RSI^*NfM>CS+^sLvv^g-+)y0mZQ{OG7M}z z1lm_hkhZJFK*_(*;dzR8;?cCbRo6y~4K?Za<_YpAJ`d}xxgEC3g^Ieka5tnV__ws6 zar-poym)BvBg+_w=h4EBPTg7|4pJzx>|~zd8ZgkNX3$@9=}RbhRa+(bP{A#ZJ8vb9 z1xk*jy>&7{5A8UfCE#Dt*!|u{vL!Y@CS!E7M7f;`Hr!y_H*g}uu@6ltXd37VDgSiW zC=9&)7NXUaZAPtPgOePCL;$f>r|DU;Abs2v2(o=a$0cx)e4$4HfxYl`c)UX{xV*2N zC<%UT}}g`ydet?7sUPGE`~~HHFnGn)hw(#109-jdPbKG z!xRkcsR{e7?p)>m`djqwjMw#Kd=HsE{qQjnY-#UHZoNS4Y(?)@)JQty{nIffN{DiW@ zU(c(9GMFlii7wngBp>}jUO*v}AR_JPH|R@^@c9uRw&%$oi5>B?JSooHM&dC6qJj1y zojkn`11CbFm=oQQJazwzBhW8Tptv&pZyooBIwdYI?aKA$U3>)2HKkYxPs4G0Oz>p33qKY0!k-4lBk|NP2u zAj8K!8d-$@=|3tUIhIyvx&Or&4F{gUBjjHU@B@Jk#?=0Y5dV_I0T863I`MxEi0_^f z%HjX@3q>Xhk#+u$INp&0A5f%{g3RObA5!EckcvXIWDzs^DgR>*d;lbgsxNx|Kcpz5 ze0TmiA%L3gf4}t393g(57*zUGP4*x3IoF6xXtlD7TK>l)c66|7iL|Y6h$gyR z__fUc!VO>bcwcw`ljtNa8E$Nd#my3=GF<6xSj-+LC|#wa>(@7kBcV5v{GiItlI<|hisGK@@S$5nK!lB2*NzJP#ge+mK7#hqJgZqF$8GFXW%(koTCB?GGUVcc9 zaOBcXTW#6Vl$*B$Y&D{Z#ehCiZcpRkQ|;*iUKU?F_{H{2JSusEK}s0Qcn`{RNXZ(WQHL(rCtb0@OdQbguh*hoD&AZ6lo+WT9Cl_ma9_}f zV(#K%nO`^uvQDEXw~yyGa7WyZcQ!?A@9?g@s`zudm}&4&EP;m|O{Lu%FLSy?L>%}!_OWm(akj2w0uT0)yAMX+ zCloip=>h4Cy3Its`|2L~_6}!+o#GX?TE}Z^!d-HN@_T6QW--^VkEnf}dSqosmVW#` z6doII`fPetXaL4VkT+HKz@BKzsb2nrooaSeG+Y7NAgR~MhcDJk@P8^eMJ+B(y*iFK zAXaHDU*82nd3{i~uDD;~ZqcIN&~(`$K$e|`rbYF-D;eH*V>#a_Ih_P+ z4b9*ByYQt)_n01P%mKF8b?s)V<}NPG34Uc3QOIx*XA#x^Rcj-cFwP;kuO(oq23$c!tD=FI@Y?jq%T&QM zORI>USQAp~W4Y7TxQJVVp<2r=jOU(<2G72T(NN=P*8d;9_QxE+wn8dDsUf4Dl>4HE z-pR@{Vr+f-p?^TvNiKn%%t0mlWr9F9-#!Vf;FFV_EE$?<9G5+Tph_ug>aG!V?Rq+Q z^*pwiL?k-I&vK~7{AZ#f9l`0gBaO?Pfl+7C_(6J>?e7&%n4u$PH1t~!2j)Q@c8iWf zeIsY@Y_w0`kC+?uOdBb?TuWf?GAeNlKx@TtWlcFMdmW|6SQBmdgji6pkp!&snv%nr z|7VUXO~jmB?{P}CzYk4FPsbmd+UI>Tl&C5E87mI0bn{;=Pw|O4uWDb0sQ)YG27R^b zuXY6_F#9QPHgO-OZh?bF*c{R~56R5xtV#H;5K>lFD1x+Bb$miD8Ph^C9(s4Mi~w6% zI?f2%be06TSYQFqtTM4t=CxvumS{>>+atIsa9LPW7u)f~0%7am`fnaTUaQE#bDhlX zG0$AF=~yD4uuxGSeboL=W)3#ZYLc3G_dI$W0h}}kgGlVs^#^427en@pe^B5b4glvb z9{q;`(^mP0IgOB{YP}h%G5ynp;ND2KbpQL0hlO`Ccjqe^2kj?9R z-P?s=+3~~>AtNWEKLcoqCT&?3>OC_uwLTPliYt_=GVG_tpss0q<`Kw5$)FpqH^L~U z$t?0c?WvbYRV9a|M+ely7ar#Iph^W~QF6SGE0kiX3E2c5%56MU*Yn{S%Y4)5VyQlb znp5I*z26PJMW$hp^!Sl1%Gn@wt$xP^d)1t_f?K)7@{H)x$o?`Z913ZrxGYw8Z=6@N z1{#xkC!OdSY^3mO2=E6xU~-W1LqU>kLc9SrPaB(Kg&^FBIig*{?qU3TcJnif6jZx(5AV0_VMJT>z_Df7Px zxd)k_S`bS#Q7(WHdK=hkh3%OZs%t@_R8peU3h|VZjto3aQs>Jd<-+QC?AAvN1R`lT zJtfN1RuRdS^>a2fK*H{rpqrtyUika@5l6jg@iqI*$fSOfl!O^H$jmiPrU;$(Ky+o_|fUhciiX$PRYPb zGY8RSVK<2@cOv+&iglkS^$F>uk8n{4p@iec?uhTw)HZtc5Mwu?w*=A)omc^PP0Y!u zUiH5i36?Hs8I=E49X1N#oTrm#;IB5duQ$o5*;Wqf8x`b1^+Dcfp6dQmm`|&(bgu1F zP0hL&`i{GD=+Nt=m+BfzJh^>@ZfTf83iAYcQVleATf?}b>eFLcD`BerSq1ctu=j3- z(p6G`DP1!!bB|jIGBkLfRZD$N3Dz!l78@I%JyfeTcc$3UG?y1jh502`CUlc@Tv95T z_v{oP;4HajgC3*U>#$pTmfKVksX1{GwDDmRj(s3vXTye;37HGTjN9dkxJ9pUn_wjr~rQVd6p#tilM2y{R)8nkR7R;6r! zS$c)K1AMNa{|fMLImt-Zmj4~W)u{j9UqfRZ5Qb{by8*5x0KurP)b5e$Lx=Mr1ub*) zEg{*aFmSj;qitE8yN~}$Eswj`dsLSb^HS^2ObzBVEcr_Y`jJBmm8!5t8cW}BDDm#M z{-hu+A4qyTE?Urd_te8^F?Mr5qj4rl>Tc()4b>TT>*AvP%-T0trQEh4wi=d!kXZA+ zQpD9fr5Wnvt^)j&n*DNMFvxVUScXx*9f!pB4Zbu%Yp3E0(&zHmsDCNn?T?s9ny&o- z@j8z4J&WG*)Jk?jGZA*HP$JI(&gh10)y-+tZ#FOb4{f=h5H;x%X;Dt)wNlaDSVyTZJIHj5#$JmL6KyLPQ$jPTI;Pg0KQEb5U=@o4KjFb1 zKg^5z*`nMM@}i6QwBo4?E}PXnKe-ALQqku{*Jf{oyn6S>30p8ONR5k~{G>La8rnI` zeFEJLc${{)l6(BzZFc+ebw7GAyOD_MTMh4z;3iksgwpNL1FP|GE;&p}kHtj#_A^e` z$Sgkg>~(IJk9qg%m9fknr$rh^m8Dwri>Fpyyvzv~KW3jy>5z)|+K~}(QwJm`?l2#n zMk*}k8-x3gvuG=nxe)=~aG>KK@e`DuAs6&lz0 z+#lX(OwUSqu)JV&x*L-p&tE_%+uCx1|6t!yIfxtlZB1v{byv{gCt=FGd=lE6Hswws z?xac^2r`fG=$f`r$P&RMi(Yzq#k~6FfMb)r5;zhV(%rkQ_8<(q;X|^$DsMeNM%JNq z&-Va)47v1telRL>gC|!z&Ff(C3yMuxfAmNu?qJ?a;k!7046~$2OTQk zF!5&ZHy6Da2wj5M6(t%9d~)}tEB_RmDDPH<LvNWG?9hxuFZyd7SXF_S%-CB?kJbvwGed~|?=|%Z z*)C-Ua*;~6s6w8sLOhT2c~~h;MPf>@;2mYTrxJ|RMOTgkwjD!?uQNCvY+BlXP*(u6 zC?7;D(VhG`sRSgTBMSr|%HoR6hl`rr32#yx)E$Jxd)O}M1ci(v-bcEroEKQpKp`<; z5*lFCHs|fkjdy=kmLT34)Bd~J?bUu@+{{a+@1{SsBb5m3(dyi5r25A9tL==}!}B3s z%4fFwKhSP(;kkB{OXxpM!c?ly4%}>Hj}x&IJ!R&FB=?xcVe$y`>NG$IbFyKAa0a@j}m1_a5wS7WsJf0 zD4KvBh``Np{MU{6rUXsY(YP9aflg)rG8=l7d}(GG&s5F&)j1}SZS<2F0_~CaUGg+N_K=aGX2_+is1| zXAZMD1{n1$0os(_Qn~u!K`VQnI3%$=&~JKzp|Rp5LyV^VMKFs_?llH zdzyNv1An(8rl!Z8@I{z?F>5+D@HWP+r+!+n8w#wNRaAcI+H*p@Zu~j>GzYZaDIFtv*#+&C76e8+BA5{w3xl9~J`b<uMT=hkqE-D{CL_3Bm$v7LKF7B;TRysH?k&>KaN8v75Z{kKhrevcweTj; z6T-panNrh0&b&oq8p72dygxf_c&W5nQLwJDt%d9!J@27)$lP+ zCv$AQ0imV0(p6Ijg;T3t+p$ZT){YyDOE$WF@g36k>(tS%U>LTN7L*Hxji7I(3Gp@! z+p2RUX*`x(F7^pd$C-I}x%AUd+?pKftQm@BMu19tm3xD8kJFFw*G1d~CCmuYJC&`d z5|SlqF~&&>XH1`n&GEo6m!}fkUaVh{e1677a5gh;;o5qK3$;Y}x3YI87^rKmOm1_` z^}ldU8b9Dp|41_HWBRPeU}oE`|6SFcFS(}7W3Qh_a#e5 z+EQ5_g}q5KbSA@&@J_Y{N~7G`|JseK*4-VDe)ScMl%dI$(u%q(Z(M08*hODcC0vyv z;%AM1{2feU>~^^LBk0&|HyIb*#^kyIRU$u)VTS?zb8u0WLx}gc_8&h;P!+!*Z@A9- z(L>|$o@O2K$ztMFmI9kf ziYHym0e=VpP``HUvwb``@m3?)I-k$4ANjjJHnm+o5!P)}SbG^7Usivnq0J!or=o24IV_3N(Yk(zmNyn$#dUjSdL%lczAyKTy3z#p0Ab zU$eWRk6QQH^x+d!CfJ%OmPu!z24o$$>88MJ^!7P`* zNDBwk$s-C>b_t{nQ_b=n%5ukGA>TTMzUL%CI>By6Wki~j`gEUAJqNH;WdAcr^+osr z-pXl2_gcJgTD0o(>PSLj3E_3sxN-S!jCp=VNUvctOt*+YnvV53>aS$5E=CT>&JmXP zqglh-eby6WGf2#=8IC^oXW5DwiJB_H{J>GX36#TOnVE;2r zCWBVhEM-3Pm_KH50wa;(a0^NCKo`fonE(3>f*uXfzQ}lfokK;)-5g)VL;-_;D)Vuw zEsCfKJ-Jlx6OOF2HdA91<3qmTPO_CvglTVNU&>@kZ3W|ST-JO0$Du*HXGvA5A_-Yv zfp9OkZzgC#fb%dvz0yFbG1-K4gAeteGK`jg;-AxUjzHdfVN0yvOupECX7sXM!Cd{i z%TBXyo#V-(vgaJE?I$Px1(?O-r5*yTD$x=v7hwPBdg2$LtqA6Ah&%|0~W#0I6YAZM0oMoMGB(>&rYv`i!t32c=f=bSv z9Cj2Px=zecI%cWt5-tdSJ`7_;!>e#UA7{53F!VxCF@0W(8M%kWL>GGig^3gZ%)=})e62bSr zBuYotJw)s7=Cs)$j;3v)aDPnM{+Fqk?5-bQ<(N-ppZLqpE$(}9=;0wlrC9Kj5{bS;bq5JhgUOHsjQ{4(?L=7^fr6}U2m~f zQt}ghrs-*I4&`K%oZ0HK=r>wPbiC@vPSe+I6b~_w; z(8aARlFt7Wr%6VXXQ97WYLh5d7&=19Xh@OM@R%paa$wD`sK?jXJ+vt~k$_pki8BRM zqn6dmOxmDJkvfVHSIc>yJa3+pl73BcIBnO+9`KwG!2b+hG~BhIk?ZhJuZDb6BiG=kWO7ZT{1P_Z0($~=`;t7?*S=82s*F-=E~5u*>4Rmy(p|0 z`i%*xPHe@&j0f%o!v*PEeo>{CouR$Zb5|Y@5)Fp<@gVlDdqzM@t-B2`CZP&sfj)3l z8hGsOq!h@0rigk7>u^Rq5B1B@LNzJitgTOlY2jR&YN#<>ZMVE%dBzalc%cPvV|D5X zA~`m54UW>Bh>jgctTZsKuimkVUy!rmRI2amRx2HXg!U61N{Zw z(7zefrnc(nDsN3i9zi7Y`4ePD;cjzYL+m zEb<;x_qdP9|c2-S3l=f9Z*^4ilDNvSVfWG zIEUcIPI+MHOrmttpkL%ka+TDruS9d9E^^W{ppN^Xk5wZNN_SOCs6hH;bGrp`i~3omJ`C-CHQEtM0LSY&pgKrE>=_d#b$rrCJWaN3Jn zs4ut9!Y)IBU)CMCZ?bg6f0Z7&Gio(se=89Rfa49kNbwG$2p6mMcP=Zx?S4F@-I~uD z|3pc+5m?*G!OClh-#mE&%OYLjy@KHN5{TL-j33PWnk6eVeejku^t1FW6cbjc4iWygQ3BBW4)N$6zUxx1kur-x_io0x*OK;w>@n5N)P39=}G zA#3uDkfZ918M?|(3-2OpbO5uzU&7`4c$Y(&6=qS)$(1rrVpef+rNCT!X1)xa6HAyK zcC4-rmfrAyFQu6pNX#ywn9xM~oqHVQG4HThyt7^uk#!`b-1b1>cJ}*ZY4MHWnWKZ_ zrzW98PIA~y>gzyiY;!OB9+SHCno*iizw$zj3pmtB0 u%?pyORzfI4?2vT+LWZ`{=#%l~8yS3;P_bsn@AvI(P_mLrkZN&*fd2zwJqfV@ diff --git a/doc/org.eclipse.emf.eef.doc/pics/initializeEEFmodels.png b/doc/org.eclipse.emf.eef.doc/pics/initializeEEFmodels.png deleted file mode 100644 index 40414508c934297f140130acdcdf602e6f555eab..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 14110 zcmZv@V{j%<*f+YdZ6|kZ+qP}nwr$%^Hg-0)Z95xmZ0F7YdCq(4d^j~Vx~99P>gw*9 z{-GlkAcTvgtSH1fFb)hBO<}!U@lOcLMO4E@ z*xuIG)XwFXu#>5wi>V2ryQPZ-p}3^1f_fl4#;;$5za&KjRXp@Abs+>$#WB7(;M;*C zz+#IuA_BTWX(*!BVigsQuX$Tf>l)mbG?Fn{t!(NeS9?2lg(%o8W`#uSKYF#nUG~9qAP5ory7Q z9ySBj(4jnh9nr|9Hv)|Lh!mpxMf^`oObZ{EWcj(GTup87ppxZoeo)Cen&OS)8cqAtI$ z9lVtF-V*-i^Sgfsp^g2l_q@aO`5wjV5;au$$AdK4a~(P%MNIfX!R6P0nA({>G%s6@ zRKONqJgV~1*zO+Hd#?ri=MF+kQ|WdIh=bwVKjYXHX?6*Etpz*UlpiiwnJAKsww(0E zD1ukc8?WzD{Wf8}!|>?f)#B^HTt=@0XH{=R$Zi!}S?xPSP&Ji72sa4cKYpH>{m@4M zRiPc5D_%e1_0y^^DQRkK{78y~6bqjzHYNrUrDlR6Qsqk=>O^We*Wfc#HtpaHeCGru z&W~FDU_MHZLVpVvj_g`Y9K+j&-wEikry>#!5Zuie83uOU#h6OMeN@qGeaB3`PREJ>E{a+#VwO?rN`2{Ri-s zpLdb-KEEENX|TGH5SCEM@0kAjv=Oi=!w-Jn5^wSH;IUp`4%()+$_e2u_7oKZ`XfYk z8_cKZyW7J)v^*Yyc4_THx*&b7`5Z6Daa8E7ND`#KRZk4G$WB6R{eLeQ>X`bgUi=H#gj+K(mCSde>WfjT@B6&`4OpZJ<|?& z2Pfhx>Vf%gj2bNurE%qdP$v0e=sVoWVHo zTBC$qq$ij6AyNE-1O??0HZV{KOOpQmJIa|eP!+kr?>Kl{dUdbC7lvaDvp-E z5zjwxnZh6iq4g@+sIRNgp+&K8stCYC7AG(s?LQzcBdv&*+(Qr(W}3plN)3LJ2cn>R z%PHm!A0T~}Vh&GFci;#+sRR9o1>aCG{#HK%JBsO%(cz1wy*{!kOq982;T$0|(wa~v z8lJaFmdPm5kJ}Yuk!uCRrYyb?rV+2MCgjJ1MMaRrdNXd6WlS1rVw3c7k{VLgAL%&HCycJdf6@IH%(aMfZA) zo%SaYS<=8lmw^<{tDF3D@OLLPg@#uX9g0Z5T%b6CG(-yR6?ASUh3GT#j1-YK z>t)+1i(OzkIGkd=X#0Ai3uzkNEpSqjNEYEut@>Ptlxw1k6MjfhgTXXtp4Yoo+$JgJQoq}l~nvctD%3`lvz zd-hTDG_i3@K`UsKN=_+_5(R`%DPC)-Z+tY<@@<2L(;XC(*VkMkOK6{{C?fq zW`+uY@j~Q?e6%q7_4KB@zkO0eLS~5-S0^&MhVw_>P4(5u@Xg~zjRt3{GWr_~t^7w5 zIPu1xfd(Vel=3Q}&&V6USLj5jfJ|L=*hbD^eYtKSz^AvX6)hbXykL1_HE!jhR8xZW zQ?OQZU%nr$(gGu8AlbLJczR)ptYX=x4{ix{YBu1jG#%Z$I^R!gwoxA?4_JI}Q9wWw z&AF9UbkV38oH$vSj5)ZHk{Ci!cf?@s13kx)C`G9&?0XW^M{`WZqr`7NUOh^Q!bE2O zAkzr|>aPELd{^Zr-q#bOE|skw^;0v7#_V(O?Y-Gn2e>AT(|A3p+hd`b@@oe%cC*#%smcCbW(L7`}-+4aS40`$RID}(`6=otR+c9X@NqUB7$GT!d#gmJ*Mr=Gd` zKpmyQPs)};#2?Oj-oLDZ%Z=GjgA>G=*Xq#D0@=h=XU_Nnc1fWg%)4f-B(-d)u}irO zwM-ncfBqidFFYx&%& z>u}d6N918fn#p*@#^FQ{O@0LmxRG^nQezW6!rWzv=3YW=VKnqIj>&r@{T&NnttiFQ za{Gpcm }%J7TR`;6+h9g%F-;)h}bB%cnmPAuC_WQt~lA3{2S@=*cXWH&Ypn=4SE zDo~syQ4=Ol5;7Z8F)2%wlDS|FuC1-@)&7pxdI3&)9S`md$ue=raW>nNfL)KC(Z?HY zBUdZ9h0rFIN<6FiLsEBz z(baL1iv6eMDq=C*9mblOKqt$PK!YoGXn9tL(Jd3g=J8p{1O>DfFi94`!zEro2VyMyTjjie zm~@07v-7#Y+cr6TkAi5i1UR;7X!5_7Cd=*uMIg`UTEgz4`T1!765r!RoFmPCj>t1s zZ0v7d)8x}W=GxKTwgzHMN7 z-i#Q&%9vA1DNimLAHIt~*h2p-S}vMgCS&OwnkXZ74vAMSE|z~6 zTDRdt!uj?l`|)e_dya%584yVL&0~z-wX+egLW=obt3RA}!4h5Nad?E&sPJ_}5=(RS zJ!D|iqA3s?Ehy2>^&Y@^A2^q2sn6CAoVUb@^Zn22E zRL}H0tQP;=V>AkOu#j_KY9Q~r)Sb7S*@axl>YTz0lJto^boLkBI+cC#OrXA~o+4yz z64EqBkkR8rsQtUqs{U%Y*jA&MDalbn#Xw1!lm)ASlT;RaOBDgZ*skrZ zf)JC1Dn1MEWN!?HNh=Yzm(y$-@0Ysw9euIxw*voQ|GMrzO^IcE7>Ig5w@e9Q?%!mM z!5V$m7hAqi1KRwG5BWa+b9}iM%bF?Du0BP2|D}sv%oVCjY-z%6Jct9M7t#lJ6VKD? zPLi1Rc1I0&XXh$gXczdTWkdZ>9)^9)Cf}*n?|M4WFF`O0+D_0&a6VLCjqYQqGG140 zd3-%$FYLpOMcc|w{gW>2uRAGujGx-l<8B9p=M9>pF8tqadhTn5 z5VHVshDY_=6nE3;9{gTG0iEOx1rwGs86K#0B0Ujzqch@De_udA!5JP^VeM!yLnYnE zN=EGWNg9XEvm#aXs>FJcq6vs}~LLb)4-HX$8=wq08 zzM5=W2Twv5MZ_vQ>ypuaJ|e|@ib7*a*CuxksU;N4&bK+YKA24NU}#<;hlA(a8_BC< z8NHe^t!@$Od(#KPXyvRm#uJ1_haCqbTW!GnZy5vid4!v>c)>xkvk6nCk=d#~yYr*% zl;s9?^hYzj{s#>1=6Nm;{LtHHK$&dsD6K1?2%lhZz;9YXvK~8>dMZ79GR=C$%VU@Vda!0mA?)CBD$*Pmugl~-3d=~1?BIx z#z1!+!ng}qq2h7j`3ltB4&C2GVlq|{eY&GJF_>iTkYtR&^u;L@x)gY5i0ixPHlDM@ z+S{aKY3`97m^|_8cRN746t-1SPi?l-hEz>t@0%bkPi+tbr7{!D{a>x^BmEct%~e_Low@lbn$7$;ssr^hFfT|RFG_=-bJk~nc&qH*n7{( zxi_ySneXz0Ej$Mx3r(g^8uiZ-2T6T0w?RZ;9HSwsG+w+yY)@?Yko4 zhYxwVZ$`T5bH*>M%W{ga$-JI~b#WTm>F5K!e8Kw}U-WtAH5bQKxOfo72|+;duU~@5~Die`3X7=Zf~V^eTK}4s1dNUWj>6;_hM%>?c%uG=l74e5oz#QQsZM~ z$&}%!g;v3YAC}+DtofXAeaO)Z4vKp_=-UKT*zDoqMBvm(74_&waVmuB>ZU;d2{c!k z*&@P>;?Azr_OAJBIEGq47nkH#byXKMl=e&0l= zFwA_*WFbnU5w^x#|8}Fu1F$o`?}@6;Hd`iro<>tMw2RuNEN*7&twy^4lZvwRpO12{cJVe^;3TA~sqbs0(j@QTT-c%om%^UG1s+k?v%MJJZWaPT zP@~_d13#8D@0JD{YAU0hmpn&$(RfKU$N9r4NO%IZhm{3Wrrz3V=bEVPoV%2~6?Nm8 zu`Y~nIlKhX*2P|Kg_uVUCG@ybg$RHebg>;WVJ}S@R2Z*9HWlOLevDa=-h3{R)*i=f zlA8mJ_fguvi%febRQZMYUomjgH(rj=YeWC@P1uFMb^}Y~pOe@P&_zKU$N6|Rd>$Bq zy_V97(xpY$GiZ#30SaqnH0Bw8z%rV$zGa;`H%n(PEJvoWdh@8C2VTi=-7HSA5D|C# zW^Z5r_CLqIc90Hk%p9#mB66u1`dX9jY0nsUM1v!yuTH4;!^3P!Cqt+%AH0Z5WA9>D z?J|IMD0pt#f!vt2NJJBRCEA3>nI-8%eqv2x!6~4=O)m2&6Rl0W;q(L&?Iion@raed za##VCw+$5}i+iv~4`GT2HKf`y@DRz#j?oL28~%jAuiwDiH@ScP(Hs)1zetNZ<@=iD zDx7a1uQz7S-cDWQ(-BgBkYLY5z_Yo=Os>!Z@IH$jV{rm4E-0!7g?26<@;s>?A%h^D zC8MQ%Dwk(@$;C)#dRM(UaTXejP&(d;#z&v#gx+h($UWC3z^yn2zJtuHkue0IAv1N$ z#Y73yK!M3XIyp)LRYsjIgA02&>A~zwTv9h=IaCYZuYAU*!DNIxSp&c@I$%6YRA-B| zc8#mK%P_3p<#hldnN)QuMLncG76z|>=lwz2AxbfWT>mcH{avQ3m|2=>!@rSaBQK4J z@9-=gufmk8zr+KpBJ6ZH6Cu z(k!)*MX4yNlQWKnBb9u_c2Fq14Djn{2a z>*@Wy87^NvMtK}TKmW<>-bOFAfG+zwR5BrN`gvwEqSW~Ao}L6WZ-r&jvz8um$5sj# zo-u0eGR%GV*TC`Ss^dr#K+fYU!Wvv!v|Yq-9h zSu&%^sgAJ~Ii6AwNyrn%F1k|9CWuxHe2BU;xfC4EQk1eO$MA0z_OX*1DHXQORf|;yNtnss+aIOHev0xH8Gmz2ELl02l;|@+$ zc)?;3Bf zv8+Xr707c!dz-v_VmlMC(TfLNtKgYf;+xG6+jcoB@y9BhH5UJ1vqcc+_5RHv@S4t) zp>;58hrgaIMfv%o6JRHbzong1$^vOI_`4GNikvW}K67hX`k0i|M8DC*&zKPVg51qL?mE4heNDw@`2CK|Go0laVd%dR<*idzMQ}z4!M% z^~RB8F2wdOf|1UaMsekmp9cMt>=I;*5?+mN6L14rkSIqSc4j2jFa-IB~H+)Y_s>b!B8A=vs8FdP}0 zD#bhV(EB9kOy)WwcR9Ogb|KxuSSEi@YP3Hv?I?|{+xGTd96eYYjF;M;nxx5o8@)L@ zp`=)<5d5XCE0n%hV$n<)C=(S=(Y~Y3(UG=xo2Ifd9(WkRXT#2#eqPnBebffXf=)1xFWf+$sJ_c8j8IWuEL}6RvVnshO4=*w(yU=$<48slWa2kMj^t6?<9V+; zqhnm)90MnK?K~!NLVaR|-EP_xsZs|@3wEqcNwVbe2n(4|T@$5BmS^|GV`~xq?g8hZ z*N2Uq)ePbUO3;JDrHJTc09_hgC8&}yagqjwl@f3g@?l~|9~7CgfZsqMN59WN>}=Hx zk^~0O(;1Ji;P+MObI#xxk_5;PL(paYA6Wp7B(abL!(AeJuPn@VQS0sa!U1ea)CU#z z4EMu2^fC0GB1%&!A?20p;PS-@Xh9x*+fH0?WJtY!FpLE$Kzzlaae#^-&*QSZ)*cnn zkC(iD6M*@2A3xvKTUpvCKKpc%Mrd7rg~sKA|b}nn^`q9 zuNcAB%wl?&?cn;qe8i>w&4iRUS;&MR=AD=_i~7f}8ENk@O@Z=y=V4jhW{S}HGlOL7 zv!WGi1R;~&@QK^dj~yh_SM6zbMgG531^jXYc-d2bk{^tt_DRZmN!#e$cQpJO>R&l> zL2HDqBa=ahyZC^<|CgnJoA$Z7o?2Vf3x9P$4jePTro42ZB%V|n3AgTa-=uMe40E-d zd|Nx6t>*sK!WS#P&562{zt zRfI(`Jwn~Q%i;5X=n8t*W0&lkheh!MnaqXy2Fg%6O~Ood^;W};ge!}cMl|eJydbR3 zF&2j)GepT4&!BGR&i?ft9viCmg4H`}ldznRfp4)BDOyJFFG7~zD)4N_9s3f5yj4=} zWdM{9ZG*Rqo(lEE58J8%-zD^y-^i?fs^Eu8FZ`Gap|58{NQX^bs(x!MPtq#1(uNZ& zLX!;}FEKhA*s0ow?*w8+nyhJJoGLCjQOoRrgt2k*)p7D?NU}fQIQ`8Eo-9}#i0~{F z{Kjg_OS29RZt5KB1`Dyg*zh`F*9@0)(`Fw}(+s|9_De_~)P>^_(@R8f>&S8;=lh0J zmuduPppun5R&F`L#PlMY)hygmo-w?OT!n1XRW`g2AFt3tqG=L!xEMgJXfAYu&C7xofU=g({?8e!Ic zaskUyH=URotXeR1qb9y84IBph?g$GA5!C-LmyvM1CX+PP3YV@>{cLox(~BU!0xNnf zKDvi94M_&gj)5=&+xw>BbAf)PuL%=Bro8mcdK6622=qON#-H~zx+uOm7gRX{YMZ^H z?~1VbdA?un+|%yv$;%Z=Bl!KQUdUu0mfN;k&|}J5-TMg%B+ud)%94C2exN`5rGfZB zy7Kui*!#P7Ks_*e-u((qgsl8J+?KC};rYgv=iwVd?^6Gu+_85*FiTpLld=X=>YW%- z2H9wk;Be{fvEBL-R=WvvOKSrr`RYd(H2=IEy8bmn!De{V+ysfjDdLK;>7!f!vB1mI z@i%maD0=Gswx#^!8|q_$_*h0u*=XZ$QWC zi4w=KStuzM?7cohx{0OSs9fv>hPJPj@fV{PC4q-=^r-X)hZ`}z$uy$p4$itqrO!mrajDs^!qir1g=9EgLt|{-fQUNW-t1X8_rNRx!+oG{-ItKNN1BkHHrZnE zd}y8qbe{SmIF~#Xli}BG`rWTz=(hiP0m6sV6@AQMa~2`)P`GZ(xV*qs zS_C88r}T<42f;PrGIRcu4lJ###SW?Sj#8$wFF$<5B6WBkrwOsN`Gd1}C>8|poN)rG zdTn;`Va8vMhhlcUA$7rvJUov>K7yGv7de!s>dZuCl|hkNzY6O?n<+}gx>-Vw+RaGv zbHxgZjN!vL;)G5}7pzy(r;E)P%S{ZzsV*k2*xbnLjkN&@ydZN$(LJkF5&hTE6252} zHgriP=@g}rN2yveg7KnFfABJSyuXt3b>^a%}%9Jts6p~rl1fZBV%I8t7Ls6 zRZMQLeQ~F1$1-!9^XQzVZD9fy@x@=W80{x&EtV${-%L`QBl|r9+-SDYM;bLK?X1dg ztKLE+ra3<8ohum$^;pi;)+*zz?Na%rh0pRHFppGq((r5$(S zB~*Q8vWnpA{gy5gXv;%uw%$^t-2}64LRKgID(NdEnY%Gd;K{qI7rS-h=4&1_aVrE- z&FtS6jlTRnlyzqgmAKiTqoI3ru76wAvf$CA@y=rxz}0@b8eZW4V_(Q^N5atNENTzM zBI)OzZ=EN|A}I|utnz`|O}CPgjyD;j-*&>Z_+Nyr;DP58RxrEye-U==_P>2wna)vM z*z9N&`21r$-uP~4uuhH`oe_U_Aa@_1MUwQR7I;G+xq-he5QxoiFyKQIpk)OhyncjEfe# z$sK&T-NfRk)1?=GFs{z}5Bf4jK>dk=d(d7^;VKtGs4C$Q8I>kf)))|?6O`HOUE}Zt zs*R3jy`wsvCqu^}uNzo5S5)YI9K5>5*eCca@8`=z74El~p(;>L=X82;Epp(R3v4k8g!BQJn z$Wgzi?Q*dN1L6-AviS{Om_>sW8Ch1rWCTUFsoUpXqpQ#|FL9B~E&#^X$E-$V8z{hV zyCMCI^4UDubzHd3Zd@KaVhHmgQg1TiKl2p4yb_ps9))lDpXPd-X2&MBDqs?!ei*P0Sw(5wLZtkL_yEL{E+!iwXfvxpJhTr{4pv5d% zzHPXZ$5Yy2R)>|ilZzDL{fv{Kt+w6+j%W53T8mNWETj}VlX#_)-<##OSeOZ;r^mko z1-Da9e^hIjSP9#)p7{MkB5}fSr2la_NYIx3dmu&sOP&Om>|t~6+W$c2TbM9OXe|Di ztea8N&M}m%V`!p;T|-vepROFEykc+~at!JzY{Rjdpj5P5)LigR69i5mNyLHh3e`+6 zFdB&*kM$ctKR$X;lwJzL%QDM1u9gJIHP@WbPwdqh>TmFKvq}<7rTH5F-;A;m3N5t6 zwp3P|Y^PjT%&8T78a@s-9>KUi^5_5whOpLj{O!(E6+`r(PYllWpv3X9(+tW^nKASj z$`Z1y;gqiNzD(L@L0EDuCR9n00yGcu!VJxw@mH@sk(`yNQ!|s+ zsrQhlQgksYL)3wvX4VvvF*+8V4URMGQlaw?px zORqPm@j3RXAF06<-KR+~|4=UMSIqDD`ZeZ8BmHRaFwVQ0aRYsV0w@|Hl%$1<%o5r1 zYTJi6uqh$Zb=TyW(B-H|&q(ti!&FSh&l7x<^!26?!UHPMjoqOhk;EvF%h*VR z41X)T&Ax-)@89fE{s+xM0t#6%0u4l*46PV9G>`nB!4sis{z#Mt4FOEuX)Ei2M0Nbf z7qDUN1A&7B3IN7OMY{fm$#7y+1G>@-p8koweJl`lkm7{)gaw_-GQ@u@NYGoSQ)>Qr zzo*^W1$!{qE z4kpiLTKdW`NsTNweF{TeJ>QfEegCGAUPzGUd{X2~gq}gg=n7g;rL`$8xCh%U9#t|b zfaw4aWf%m+eB*gZj-{~{GC|kp-p4$lc+I256E_O^um%_I_?<(-|XITON5cF zRaHUPhn$Znk&(!EvsRF=Lkoh%18k=E$naS)miAo#8Hf7F1AcKsCPjpH-%B>v&$>m7 zN3ZvH{D#Qe-hxJ*zu55cc7?O)IRy)SJn@Nn0qq!mSDBA+i(`a0{5%4C#CT2bC6Q)O zqO^tGAG+hKzvK96@0frBVq*eTD@d^}8JJX&hfQ)3hOCa^F3(?{irRdyQ=_uE+M?#4 zA&(gIPz0w7av}@Sw}YNeRY)FuxPe`Pzqs+F>h%Rlgh7SX0hL^s*CZsT8vdo`S+rw5 zF=IHFY3|bfZ&1qVXUMS1{Z3G1*R5FeSmK1{h;vd5K~F*nCQ2oktvC4-$E3@iFPypWK`0zG{UFp z`XND9=m4RnVUk3|{@YrRAr*?(L^Q!Jp6}&^1<~4K;yC7{He8s@XQV%9>H|27LvHZQ z9a;s&`_rGKSoiv{E_TwK=|lAZ(j=my64?9H6x#S)~RN%OoUTd@mvejZ8zag=JF zrDEO^4C<}t@o?)R?M$Ssgnc49|r?! zpi^m$p|x@BU)|CD>q{8Lv7ng=^Xs0kQhop6Ly%;bwdnNa=WE}?$j}M9k13X`_c&3S z%ZHK1YNOQ5Ml&`UHHS&5wV3;K%&hUFF=jP%kfyRD^Yur0dfTgXz9-y#;Q08EI6=Km z3mPl6$^i6j@;zCLjMf>g)Z_|m&u{~le=OHJ2k#RqI&s1bre``!6neIL}ZgFWUnTd+Csy^-*7G`PGltGDL8ky8MIyx}1`-og@>7#ppDvP1f{=Nvf< z#L0qedTDhTVaPgf%TEoSN9PYtYupJ{gD=~Ch8uSs66s9KIPrD7Xr?Io718MJqtbiD zPBH1ikEpj~#(y@1wRV~@UM<>CvnjPr^%t#D!Q|S^(LMpJyYRvd3o7{wc#7|vy$;k& zrF>KV%MpR~CLSuMp)1n0`>B068*WpO@ke)~fV~?lmYP+yVB2NG)24m`LzgVKEMK9z z?<3^?`t>+F@fCUlx6j221_BP4kG@ReL<=Ou)!Ut;pl>}^xS$-Fly})w+-^GahV0>{Y-nlpK>kJuBkSvw@WMmtr79` zm+K1{>oa&~Fs^v5-qYi45Aoo`Z+K#22b1fJCn!`l_Z_R5% zB6`q9qnpVNv?Q8#nDZt8(8mZH=MT1{P{#FQ?H4M4jcsOd+_Kn^(~o9{Lm+xNFyvh4 z15h3^$uT#|rYdO5@zA(F(79Ar*x{$RHi5N*Jqi46b?lCr%5mb$^$QT^e0SIFKc#yc z!$u$!>1$NWDfq)ra#|f)5*19CS{l8XZRRif1Un z7^owkiaQM~vte!`?E((4%2Fft4yorItu3oxi_xegDDzL>HQMxp60^AqEiK)&B(WYc z=D?_V;ttJJXhGCicg<;xMCI&hq^+xqx>DRSxa&Z+q?s>FEasZ2mxji2Fq#i3}MoI|`1|6})?Cs>gs(Yq- zQC8Zzi~D(rd0ZIF;wg?7K)axzhYk}4D)h>*#ipyuR{hR;aTiM3D{}mO55^i3Owlel z**E*JWl)mH>1%G z(Z?~)gwhH}@oz|F^At5?6+iEJODzU5+q_@yrp;wM^F-|g52#h!n}%U_mlV?qX=Rmq zsm{*TMxK%;6s2?haZ$#A)WQ*01PBfqw%_dKN&=9|0IOi=XLeT5B} zJxpl;X?tS&1TCNHL`X6;4?Wyb3LOnAhz#5)7F7dsK8(lpoqJ4dZu~uF+QUj|r+*=| z?niOjdZX7YLtC>gilT&#l6UR#*-~?L#D--9oau4(gDDH%+ zKQ39(M4{(T6V!TF3D{x7q>X7wIBl@MShVTwki)nGNpvw`al%hMh{sT!P?M5xkWPbB zom=-CrF8fuh;<*8X)ynWt_F`73i5)HbeNWDzRa~cz8Id{;re01|A>Qm?;jwuw>S<- zaAns^^u??x7jOS+`n#IgY$<$m&7HI#EOBG=%?XBH(-|ZD&Z6_p@Wecf)m74!H}05D zH%YLm|Kbk}8{8p04K{MV-x7*N8-{tD9-%qn?D{=JJiUekvU;rNtBV&o-7+t^W$uuH zPnwNGp`Sy=YwWx@RY&ry7w6)j^9p;@REKRhICV|(_Ud$8&imn&FMtAk^ZId&syY$q-u{u+W)mC~l%=u1#)%UAt!(%i?cQ4t8 z3{G@4VoES+9GBA_#O0KD*3NR5`-M-udth?A?*2?|V?z0rV9QZ-7)mQ&ZY&%%+o6y; zh(kFI$hf6E-~qg1*%Nu(XHH!@7Y|Bh}mn2q5!I&B8ElQgWF{{?*} z;~5Ycn1q3&j2Qo2LbK5Hhfyh8v6wH0`n~fZA8e=u?lET;aMY@tHrm(meXtq0+jl4m ze8i^8uyv2aLI{|=;IK(?u%GPg{!Q4e*+uuC@0$t~GqK+IEi;NH4xS{Ylr;mBRT6=* z;fAvtNGy&RG}suSdrPr$y$zQ)PM{3&hPwyW%~w7M3pW{!8m3feJU(h1)#=C0@{`5_ zcXUlE)_HD#44nlBG;(VfT_xgJuBab8*MBBpcSMO`gHs-z%d>GV(P=m|uN}d#^dk_W zJ~?%C8ZD;a%B}xq=K1izSuL;&F^l2pm2~xoud&JO9#~kCN=ZpPOt1Qlt z_0AU>{z$nEjG6mp=(Mkv6PX|h;RleYn4q9gVq2M_+Toc;Lh3d{)MM3B#9G>lX4br9 z4`4@Xq%bneo}y0RKr8b9)eqrYK!p^0eB-BpPCsf&$?4B6pFkS(hCD@#L0U8*nFsh= zAPVK_2<}@ATKuEVRTis_Sabl*%?_UBs~a7S=vs~PEE17%iu8KNrN{pOu~yHO*Q}H$ zB^?sNzPrF*YKxx_Asfcl%%k9>2mLPx#E=Yrk|o~_*LWzWAX6_Q#+aGuLWvuLgp^8P z9-fM0>R+00s5R{HMC@#Li~w;hz&H8Cl95^Hq!K?C{R76lWT_Hl`n0XY;5r4@K-^Vsc_A%ldl@7z z;_7jw8v<@J$I?lcX|OgFe2Iy&Y!qWqk)I&}hd8CbxoXO;kDveFKWz{)!aUA*-8Db} zK87S_{f~wS_CZW?;L;3i_fqX-pTlJs$Jk`SftW^6YDJmyYD`XJ#e*h3j$_oGh diff --git a/doc/org.eclipse.emf.eef.doc/plugin.xml b/doc/org.eclipse.emf.eef.doc/plugin.xml deleted file mode 100644 index 30836ea8f..000000000 --- a/doc/org.eclipse.emf.eef.doc/plugin.xml +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - - - - - diff --git a/doc/org.eclipse.emf.eef.doc/pom.xml b/doc/org.eclipse.emf.eef.doc/pom.xml deleted file mode 100644 index 7b8154b68..000000000 --- a/doc/org.eclipse.emf.eef.doc/pom.xml +++ /dev/null @@ -1,57 +0,0 @@ - - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.doc - eclipse-plugin - - EEF Documentation - - - - - maven-antrun-plugin - - - ant - optional - 1.5.4 - - - - - generate-sources - - - - - - - - run - - - - - - - diff --git a/doc/org.eclipse.emf.eef.doc/src/org/eclipse/emf/eef/doc/Activator.java b/doc/org.eclipse.emf.eef.doc/src/org/eclipse/emf/eef/doc/Activator.java deleted file mode 100644 index 76be5d8aa..000000000 --- a/doc/org.eclipse.emf.eef.doc/src/org/eclipse/emf/eef/doc/Activator.java +++ /dev/null @@ -1,76 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2010 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.doc; - -import org.eclipse.jface.resource.ImageDescriptor; -import org.eclipse.ui.plugin.AbstractUIPlugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle. - * - * @author Stephane Bouchet - */ -public class Activator extends AbstractUIPlugin { - - /** The plug-in ID. */ - public static final String PLUGIN_ID = "org.eclipse.emf.eef.doc"; - - /** The shared instance. */ - private static Activator plugin; - - /** - * The constructor. - */ - public Activator() { - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance. - * - * @return the shared instance - */ - public static Activator getDefault() { - return plugin; - } - - /** - * Returns an image descriptor for the image file at the given plug-in - * relative path. - * - * @param path - * the path - * @return the image descriptor - */ - public static ImageDescriptor getImageDescriptor(String path) { - return imageDescriptorFromPlugin(PLUGIN_ID, path); - } -} diff --git a/features/org.eclipse.emf.eef.codegen.ecore-feature/.gitignore b/features/org.eclipse.emf.eef.codegen.ecore-feature/.gitignore deleted file mode 100644 index eb5a316cb..000000000 --- a/features/org.eclipse.emf.eef.codegen.ecore-feature/.gitignore +++ /dev/null @@ -1 +0,0 @@ -target diff --git a/features/org.eclipse.emf.eef.codegen.ecore-feature/.project b/features/org.eclipse.emf.eef.codegen.ecore-feature/.project deleted file mode 100644 index 48cb6a304..000000000 --- a/features/org.eclipse.emf.eef.codegen.ecore-feature/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - org.eclipse.emf.eef.codegen.ecore-feature - - - - - - org.eclipse.pde.FeatureBuilder - - - - - - org.eclipse.pde.FeatureNature - - diff --git a/features/org.eclipse.emf.eef.codegen.ecore-feature/build.properties b/features/org.eclipse.emf.eef.codegen.ecore-feature/build.properties deleted file mode 100644 index 7aa629d6d..000000000 --- a/features/org.eclipse.emf.eef.codegen.ecore-feature/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = feature.xml,\ - feature.properties,\ - license.html,\ - license.txt,\ - epl-v10.html -src.includes = feature.properties,\ - license.html,\ - license.txt,\ - feature.xml,\ - epl-v10.html diff --git a/features/org.eclipse.emf.eef.codegen.ecore-feature/epl-v10.html b/features/org.eclipse.emf.eef.codegen.ecore-feature/epl-v10.html deleted file mode 100755 index 0d34dd06a..000000000 --- a/features/org.eclipse.emf.eef.codegen.ecore-feature/epl-v10.html +++ /dev/null @@ -1,262 +0,0 @@ - - - - - - -Eclipse Public License - Version 1.0 - - - - - - -

Eclipse Public License - v 1.0

- -

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE -PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR -DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS -AGREEMENT.

- -

1. DEFINITIONS

- -

"Contribution" means:

- -

a) in the case of the initial Contributor, the initial -code and documentation distributed under this Agreement, and

-

b) in the case of each subsequent Contributor:

- -

i) changes to the Program, and

-

ii) additions to the Program;

-

where such changes and/or additions to the Program -originate from and are distributed by that particular Contributor. A -Contribution 'originates' from a Contributor if it was added to the -Program by such Contributor itself or anyone acting on such -Contributor's behalf. Contributions do not include additions to the -Program which: (i) are separate modules of software distributed in -conjunction with the Program under their own license agreement, and (ii) -are not derivative works of the Program.

- -

"Contributor" means any person or entity that distributes -the Program.

- -

"Licensed Patents" mean patent claims licensable by a -Contributor which are necessarily infringed by the use or sale of its -Contribution alone or when combined with the Program.

- -

"Program" means the Contributions distributed in accordance -with this Agreement.

- -

"Recipient" means anyone who receives the Program under -this Agreement, including all Contributors.

- -

2. GRANT OF RIGHTS

- -

a) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free copyright license to reproduce, prepare derivative works -of, publicly display, publicly perform, distribute and sublicense the -Contribution of such Contributor, if any, and such derivative works, in -source code and object code form.

- -

b) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free patent license under Licensed Patents to make, use, sell, -offer to sell, import and otherwise transfer the Contribution of such -Contributor, if any, in source code and object code form. This patent -license shall apply to the combination of the Contribution and the -Program if, at the time the Contribution is added by the Contributor, -such addition of the Contribution causes such combination to be covered -by the Licensed Patents. The patent license shall not apply to any other -combinations which include the Contribution. No hardware per se is -licensed hereunder.

- -

c) Recipient understands that although each Contributor -grants the licenses to its Contributions set forth herein, no assurances -are provided by any Contributor that the Program does not infringe the -patent or other intellectual property rights of any other entity. Each -Contributor disclaims any liability to Recipient for claims brought by -any other entity based on infringement of intellectual property rights -or otherwise. As a condition to exercising the rights and licenses -granted hereunder, each Recipient hereby assumes sole responsibility to -secure any other intellectual property rights needed, if any. For -example, if a third party patent license is required to allow Recipient -to distribute the Program, it is Recipient's responsibility to acquire -that license before distributing the Program.

- -

d) Each Contributor represents that to its knowledge it -has sufficient copyright rights in its Contribution, if any, to grant -the copyright license set forth in this Agreement.

- -

3. REQUIREMENTS

- -

A Contributor may choose to distribute the Program in object code -form under its own license agreement, provided that:

- -

a) it complies with the terms and conditions of this -Agreement; and

- -

b) its license agreement:

- -

i) effectively disclaims on behalf of all Contributors -all warranties and conditions, express and implied, including warranties -or conditions of title and non-infringement, and implied warranties or -conditions of merchantability and fitness for a particular purpose;

- -

ii) effectively excludes on behalf of all Contributors -all liability for damages, including direct, indirect, special, -incidental and consequential damages, such as lost profits;

- -

iii) states that any provisions which differ from this -Agreement are offered by that Contributor alone and not by any other -party; and

- -

iv) states that source code for the Program is available -from such Contributor, and informs licensees how to obtain it in a -reasonable manner on or through a medium customarily used for software -exchange.

- -

When the Program is made available in source code form:

- -

a) it must be made available under this Agreement; and

- -

b) a copy of this Agreement must be included with each -copy of the Program.

- -

Contributors may not remove or alter any copyright notices contained -within the Program.

- -

Each Contributor must identify itself as the originator of its -Contribution, if any, in a manner that reasonably allows subsequent -Recipients to identify the originator of the Contribution.

- -

4. COMMERCIAL DISTRIBUTION

- -

Commercial distributors of software may accept certain -responsibilities with respect to end users, business partners and the -like. While this license is intended to facilitate the commercial use of -the Program, the Contributor who includes the Program in a commercial -product offering should do so in a manner which does not create -potential liability for other Contributors. Therefore, if a Contributor -includes the Program in a commercial product offering, such Contributor -("Commercial Contributor") hereby agrees to defend and -indemnify every other Contributor ("Indemnified Contributor") -against any losses, damages and costs (collectively "Losses") -arising from claims, lawsuits and other legal actions brought by a third -party against the Indemnified Contributor to the extent caused by the -acts or omissions of such Commercial Contributor in connection with its -distribution of the Program in a commercial product offering. The -obligations in this section do not apply to any claims or Losses -relating to any actual or alleged intellectual property infringement. In -order to qualify, an Indemnified Contributor must: a) promptly notify -the Commercial Contributor in writing of such claim, and b) allow the -Commercial Contributor to control, and cooperate with the Commercial -Contributor in, the defense and any related settlement negotiations. The -Indemnified Contributor may participate in any such claim at its own -expense.

- -

For example, a Contributor might include the Program in a commercial -product offering, Product X. That Contributor is then a Commercial -Contributor. If that Commercial Contributor then makes performance -claims, or offers warranties related to Product X, those performance -claims and warranties are such Commercial Contributor's responsibility -alone. Under this section, the Commercial Contributor would have to -defend claims against the other Contributors related to those -performance claims and warranties, and if a court requires any other -Contributor to pay any damages as a result, the Commercial Contributor -must pay those damages.

- -

5. NO WARRANTY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS -PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS -OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, -ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY -OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely -responsible for determining the appropriateness of using and -distributing the Program and assumes all risks associated with its -exercise of rights under this Agreement , including but not limited to -the risks and costs of program errors, compliance with applicable laws, -damage to or loss of data, programs or equipment, and unavailability or -interruption of operations.

- -

6. DISCLAIMER OF LIABILITY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT -NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING -WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR -DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED -HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

- -

7. GENERAL

- -

If any provision of this Agreement is invalid or unenforceable under -applicable law, it shall not affect the validity or enforceability of -the remainder of the terms of this Agreement, and without further action -by the parties hereto, such provision shall be reformed to the minimum -extent necessary to make such provision valid and enforceable.

- -

If Recipient institutes patent litigation against any entity -(including a cross-claim or counterclaim in a lawsuit) alleging that the -Program itself (excluding combinations of the Program with other -software or hardware) infringes such Recipient's patent(s), then such -Recipient's rights granted under Section 2(b) shall terminate as of the -date such litigation is filed.

- -

All Recipient's rights under this Agreement shall terminate if it -fails to comply with any of the material terms or conditions of this -Agreement and does not cure such failure in a reasonable period of time -after becoming aware of such noncompliance. If all Recipient's rights -under this Agreement terminate, Recipient agrees to cease use and -distribution of the Program as soon as reasonably practicable. However, -Recipient's obligations under this Agreement and any licenses granted by -Recipient relating to the Program shall continue and survive.

- -

Everyone is permitted to copy and distribute copies of this -Agreement, but in order to avoid inconsistency the Agreement is -copyrighted and may only be modified in the following manner. The -Agreement Steward reserves the right to publish new versions (including -revisions) of this Agreement from time to time. No one other than the -Agreement Steward has the right to modify this Agreement. The Eclipse -Foundation is the initial Agreement Steward. The Eclipse Foundation may -assign the responsibility to serve as the Agreement Steward to a -suitable separate entity. Each new version of the Agreement will be -given a distinguishing version number. The Program (including -Contributions) may always be distributed subject to the version of the -Agreement under which it was received. In addition, after a new version -of the Agreement is published, Contributor may elect to distribute the -Program (including its Contributions) under the new version. Except as -expressly stated in Sections 2(a) and 2(b) above, Recipient receives no -rights or licenses to the intellectual property of any Contributor under -this Agreement, whether expressly, by implication, estoppel or -otherwise. All rights in the Program not expressly granted under this -Agreement are reserved.

- -

This Agreement is governed by the laws of the State of New York and -the intellectual property laws of the United States of America. No party -to this Agreement will bring a legal action under this Agreement more -than one year after the cause of action arose. Each party waives its -rights to a jury trial in any resulting litigation.

- - - - \ No newline at end of file diff --git a/features/org.eclipse.emf.eef.codegen.ecore-feature/feature.properties b/features/org.eclipse.emf.eef.codegen.ecore-feature/feature.properties deleted file mode 100644 index e8f570a82..000000000 --- a/features/org.eclipse.emf.eef.codegen.ecore-feature/feature.properties +++ /dev/null @@ -1,147 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -providerName=Eclipse Modeling Project -featureName=Extended Editing Framework - EMF Edit generation using Acceleo -modelingUpdateSiteName=Eclipse Modeling Project Updates -description=Extended Editing Framework - EMF Edit generation using Acceleo. \ -This plugin contains the necessary acceleo templates and code to generates EMF Edit and editor code. - -# "licenseURL" property - URL of the "Feature License" -# do not translate value - just change to point to a locale-specific HTML page -licenseURL=license.html - -# "license" property - text of the "Feature Update License" -# should be plain text version of license agreement pointed to be "licenseURL" -license=\ -Eclipse Foundation Software User Agreement\n\ -February 1, 2011\n\ -\n\ -Usage Of Content\n\ -\n\ -THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\ -OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\ -USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\ -AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\ -NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\ -AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\ -AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\ -OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\ -TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\ -OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\ -BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\ -\n\ -Applicable Licenses\n\ -\n\ -Unless otherwise indicated, all Content made available by the\n\ -Eclipse Foundation is provided to you under the terms and conditions of\n\ -the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is\n\ -provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\ -For purposes of the EPL, "Program" will mean the Content.\n\ -\n\ -Content includes, but is not limited to, source code, object code,\n\ -documentation and other files maintained in the Eclipse Foundation source code\n\ -repository ("Repository") in software modules ("Modules") and made available\n\ -as downloadable archives ("Downloads").\n\ -\n\ - - Content may be structured and packaged into modules to facilitate delivering,\n\ - extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\ - plug-in fragments ("Fragments"), and features ("Features").\n\ - - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive)\n\ - in a directory named "plugins".\n\ - - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\ - Each Feature may be packaged as a sub-directory in a directory named "features".\n\ - Within a Feature, files named "feature.xml" may contain a list of the names and version\n\ - numbers of the Plug-ins and/or Fragments associated with that Feature.\n\ - - Features may also include other Features ("Included Features"). Within a Feature, files\n\ - named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\ -\n\ -The terms and conditions governing Plug-ins and Fragments should be\n\ -contained in files named "about.html" ("Abouts"). The terms and\n\ -conditions governing Features and Included Features should be contained\n\ -in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\ -Licenses may be located in any directory of a Download or Module\n\ -including, but not limited to the following locations:\n\ -\n\ - - The top-level (root) directory\n\ - - Plug-in and Fragment directories\n\ - - Inside Plug-ins and Fragments packaged as JARs\n\ - - Sub-directories of the directory named "src" of certain Plug-ins\n\ - - Feature directories\n\ -\n\ -Note: if a Feature made available by the Eclipse Foundation is installed using the\n\ -Provisioning Technology (as defined below), you must agree to a license ("Feature \n\ -Update License") during the installation process. If the Feature contains\n\ -Included Features, the Feature Update License should either provide you\n\ -with the terms and conditions governing the Included Features or inform\n\ -you where you can locate them. Feature Update Licenses may be found in\n\ -the "license" property of files named "feature.properties" found within a Feature.\n\ -Such Abouts, Feature Licenses, and Feature Update Licenses contain the\n\ -terms and conditions (or references to such terms and conditions) that\n\ -govern your use of the associated Content in that directory.\n\ -\n\ -THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER\n\ -TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\ -SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\ -\n\ - - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html)\n\ - - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\ - - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\ - - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\ - - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\ - - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\ -\n\ -IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\ -TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License\n\ -is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\ -govern that particular Content.\n\ -\n\ -\n\Use of Provisioning Technology\n\ -\n\ -The Eclipse Foundation makes available provisioning software, examples of which include,\n\ -but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for\n\ -the purpose of allowing users to install software, documentation, information and/or\n\ -other materials (collectively "Installable Software"). This capability is provided with\n\ -the intent of allowing such users to install, extend and update Eclipse-based products.\n\ -Information about packaging Installable Software is available at\n\ -http://eclipse.org/equinox/p2/repository_packaging.html ("Specification").\n\ -\n\ -You may use Provisioning Technology to allow other parties to install Installable Software.\n\ -You shall be responsible for enabling the applicable license agreements relating to the\n\ -Installable Software to be presented to, and accepted by, the users of the Provisioning Technology\n\ -in accordance with the Specification. By using Provisioning Technology in such a manner and\n\ -making it available in accordance with the Specification, you further acknowledge your\n\ -agreement to, and the acquisition of all necessary rights to permit the following:\n\ -\n\ - 1. A series of actions may occur ("Provisioning Process") in which a user may execute\n\ - the Provisioning Technology on a machine ("Target Machine") with the intent of installing,\n\ - extending or updating the functionality of an Eclipse-based product.\n\ - 2. During the Provisioning Process, the Provisioning Technology may cause third party\n\ - Installable Software or a portion thereof to be accessed and copied to the Target Machine.\n\ - 3. Pursuant to the Specification, you will provide to the user the terms and conditions that\n\ - govern the use of the Installable Software ("Installable Software Agreement") and such\n\ - Installable Software Agreement shall be accessed from the Target Machine in accordance\n\ - with the Specification. Such Installable Software Agreement must inform the user of the\n\ - terms and conditions that govern the Installable Software and must solicit acceptance by\n\ - the end user in the manner prescribed in such Installable Software Agreement. Upon such\n\ - indication of agreement by the user, the provisioning Technology will complete installation\n\ - of the Installable Software.\n\ -\n\ -Cryptography\n\ -\n\ -Content may contain encryption software. The country in which you are\n\ -currently may have restrictions on the import, possession, and use,\n\ -and/or re-export to another country, of encryption software. BEFORE\n\ -using any encryption software, please check the country's laws,\n\ -regulations and policies concerning the import, possession, or use, and\n\ -re-export of encryption software, to see if this is permitted.\n\ -\n\ -Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.\n -########### end of license property ########################################## diff --git a/features/org.eclipse.emf.eef.codegen.ecore-feature/feature.xml b/features/org.eclipse.emf.eef.codegen.ecore-feature/feature.xml deleted file mode 100644 index 9805c9509..000000000 --- a/features/org.eclipse.emf.eef.codegen.ecore-feature/feature.xml +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - %description - - - - Copyright (c) 2011 Obeo. -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 - - - - %license - - - - - - - - - - - - diff --git a/features/org.eclipse.emf.eef.codegen.ecore-feature/license.html b/features/org.eclipse.emf.eef.codegen.ecore-feature/license.html deleted file mode 100644 index a1fe5ea3f..000000000 --- a/features/org.eclipse.emf.eef.codegen.ecore-feature/license.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - -Eclipse Foundation Software User Agreement - - - -

Eclipse Foundation Software User Agreement

-

February 1, 2011

- -

Usage Of Content

- -

THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS - (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND - CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE - OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR - NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND - CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.

- -

Applicable Licenses

- -

Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 - ("EPL"). A copy of the EPL is provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html. - For purposes of the EPL, "Program" will mean the Content.

- -

Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code - repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").

- -
    -
  • Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").
  • - -
  • Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".
  • -
  • A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins - and/or Fragments associated with that Feature.
  • -
  • Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.
  • - -
- -

The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and -Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module -including, but not limited to the following locations:

- -
    -
  • The top-level (root) directory
  • - -
  • Plug-in and Fragment directories
  • -
  • Inside Plug-ins and Fragments packaged as JARs
  • -
  • Sub-directories of the directory named "src" of certain Plug-ins
  • -
  • Feature directories
  • -
- -

Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the -installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or -inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. -Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in -that directory.

- -

THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE -OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):

- - - -

IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please -contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.

- - -

Use of Provisioning Technology

- -

The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse - Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or - other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to - install, extend and update Eclipse-based products. Information about packaging Installable Software is available at http://eclipse.org/equinox/p2/repository_packaging.html - - ("Specification").

- -

You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the - applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology - in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the - Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:

- -
    -
  1. A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology - on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based - product.
  2. - -
  3. During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be - accessed and copied to the Target Machine.
  4. -
  5. Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable - Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target - Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern - the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such - indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.
  6. -
- -

Cryptography

- -

Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to - another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, - possession, or use, and re-export of encryption software, to see if this is permitted.

- -

Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.

- - - diff --git a/features/org.eclipse.emf.eef.codegen.ecore-feature/license.txt b/features/org.eclipse.emf.eef.codegen.ecore-feature/license.txt deleted file mode 100644 index 24937b64c..000000000 --- a/features/org.eclipse.emf.eef.codegen.ecore-feature/license.txt +++ /dev/null @@ -1,87 +0,0 @@ -Eclipse Public License - v 1.0 - -THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. - -1. DEFINITIONS - -"Contribution" means: - -a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and -b) in the case of each subsequent Contributor: - -i) changes to the Program, and - -ii) additions to the Program; - -where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program. - -"Contributor" means any person or entity that distributes the Program. - -"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. - -"Program" means the Contributions distributed in accordance with this Agreement. - -"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. - -2. GRANT OF RIGHTS - -a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form. - -b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. - -c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. - -d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. - -3. REQUIREMENTS - -A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: - -a) it complies with the terms and conditions of this Agreement; and - -b) its license agreement: - -i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; - -ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; - -iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and - -iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange. - -When the Program is made available in source code form: - -a) it must be made available under this Agreement; and - -b) a copy of this Agreement must be included with each copy of the Program. - -Contributors may not remove or alter any copyright notices contained within the Program. - -Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. - -4. COMMERCIAL DISTRIBUTION - -Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. - -For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. - -5. NO WARRANTY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. - -6. DISCLAIMER OF LIABILITY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - -7. GENERAL - -If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. - -If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. - -All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. - -Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. - -This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. - diff --git a/features/org.eclipse.emf.eef.codegen.ecore-feature/pom.xml b/features/org.eclipse.emf.eef.codegen.ecore-feature/pom.xml deleted file mode 100644 index 129d9382f..000000000 --- a/features/org.eclipse.emf.eef.codegen.ecore-feature/pom.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.codegen.ecore-feature - eclipse-feature - - EEF Ecore Codegen Feature - - diff --git a/features/org.eclipse.emf.eef.codegen.richtext-feature/.gitignore b/features/org.eclipse.emf.eef.codegen.richtext-feature/.gitignore deleted file mode 100644 index eb5a316cb..000000000 --- a/features/org.eclipse.emf.eef.codegen.richtext-feature/.gitignore +++ /dev/null @@ -1 +0,0 @@ -target diff --git a/features/org.eclipse.emf.eef.codegen.richtext-feature/.project b/features/org.eclipse.emf.eef.codegen.richtext-feature/.project deleted file mode 100644 index cad0e58b3..000000000 --- a/features/org.eclipse.emf.eef.codegen.richtext-feature/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - org.eclipse.emf.eef.codegen.richtext-feature - - - - - - org.eclipse.pde.FeatureBuilder - - - - - - org.eclipse.pde.FeatureNature - - diff --git a/features/org.eclipse.emf.eef.codegen.richtext-feature/build.properties b/features/org.eclipse.emf.eef.codegen.richtext-feature/build.properties deleted file mode 100644 index 7aa629d6d..000000000 --- a/features/org.eclipse.emf.eef.codegen.richtext-feature/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = feature.xml,\ - feature.properties,\ - license.html,\ - license.txt,\ - epl-v10.html -src.includes = feature.properties,\ - license.html,\ - license.txt,\ - feature.xml,\ - epl-v10.html diff --git a/features/org.eclipse.emf.eef.codegen.richtext-feature/epl-v10.html b/features/org.eclipse.emf.eef.codegen.richtext-feature/epl-v10.html deleted file mode 100644 index 0d34dd06a..000000000 --- a/features/org.eclipse.emf.eef.codegen.richtext-feature/epl-v10.html +++ /dev/null @@ -1,262 +0,0 @@ - - - - - - -Eclipse Public License - Version 1.0 - - - - - - -

Eclipse Public License - v 1.0

- -

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE -PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR -DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS -AGREEMENT.

- -

1. DEFINITIONS

- -

"Contribution" means:

- -

a) in the case of the initial Contributor, the initial -code and documentation distributed under this Agreement, and

-

b) in the case of each subsequent Contributor:

- -

i) changes to the Program, and

-

ii) additions to the Program;

-

where such changes and/or additions to the Program -originate from and are distributed by that particular Contributor. A -Contribution 'originates' from a Contributor if it was added to the -Program by such Contributor itself or anyone acting on such -Contributor's behalf. Contributions do not include additions to the -Program which: (i) are separate modules of software distributed in -conjunction with the Program under their own license agreement, and (ii) -are not derivative works of the Program.

- -

"Contributor" means any person or entity that distributes -the Program.

- -

"Licensed Patents" mean patent claims licensable by a -Contributor which are necessarily infringed by the use or sale of its -Contribution alone or when combined with the Program.

- -

"Program" means the Contributions distributed in accordance -with this Agreement.

- -

"Recipient" means anyone who receives the Program under -this Agreement, including all Contributors.

- -

2. GRANT OF RIGHTS

- -

a) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free copyright license to reproduce, prepare derivative works -of, publicly display, publicly perform, distribute and sublicense the -Contribution of such Contributor, if any, and such derivative works, in -source code and object code form.

- -

b) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free patent license under Licensed Patents to make, use, sell, -offer to sell, import and otherwise transfer the Contribution of such -Contributor, if any, in source code and object code form. This patent -license shall apply to the combination of the Contribution and the -Program if, at the time the Contribution is added by the Contributor, -such addition of the Contribution causes such combination to be covered -by the Licensed Patents. The patent license shall not apply to any other -combinations which include the Contribution. No hardware per se is -licensed hereunder.

- -

c) Recipient understands that although each Contributor -grants the licenses to its Contributions set forth herein, no assurances -are provided by any Contributor that the Program does not infringe the -patent or other intellectual property rights of any other entity. Each -Contributor disclaims any liability to Recipient for claims brought by -any other entity based on infringement of intellectual property rights -or otherwise. As a condition to exercising the rights and licenses -granted hereunder, each Recipient hereby assumes sole responsibility to -secure any other intellectual property rights needed, if any. For -example, if a third party patent license is required to allow Recipient -to distribute the Program, it is Recipient's responsibility to acquire -that license before distributing the Program.

- -

d) Each Contributor represents that to its knowledge it -has sufficient copyright rights in its Contribution, if any, to grant -the copyright license set forth in this Agreement.

- -

3. REQUIREMENTS

- -

A Contributor may choose to distribute the Program in object code -form under its own license agreement, provided that:

- -

a) it complies with the terms and conditions of this -Agreement; and

- -

b) its license agreement:

- -

i) effectively disclaims on behalf of all Contributors -all warranties and conditions, express and implied, including warranties -or conditions of title and non-infringement, and implied warranties or -conditions of merchantability and fitness for a particular purpose;

- -

ii) effectively excludes on behalf of all Contributors -all liability for damages, including direct, indirect, special, -incidental and consequential damages, such as lost profits;

- -

iii) states that any provisions which differ from this -Agreement are offered by that Contributor alone and not by any other -party; and

- -

iv) states that source code for the Program is available -from such Contributor, and informs licensees how to obtain it in a -reasonable manner on or through a medium customarily used for software -exchange.

- -

When the Program is made available in source code form:

- -

a) it must be made available under this Agreement; and

- -

b) a copy of this Agreement must be included with each -copy of the Program.

- -

Contributors may not remove or alter any copyright notices contained -within the Program.

- -

Each Contributor must identify itself as the originator of its -Contribution, if any, in a manner that reasonably allows subsequent -Recipients to identify the originator of the Contribution.

- -

4. COMMERCIAL DISTRIBUTION

- -

Commercial distributors of software may accept certain -responsibilities with respect to end users, business partners and the -like. While this license is intended to facilitate the commercial use of -the Program, the Contributor who includes the Program in a commercial -product offering should do so in a manner which does not create -potential liability for other Contributors. Therefore, if a Contributor -includes the Program in a commercial product offering, such Contributor -("Commercial Contributor") hereby agrees to defend and -indemnify every other Contributor ("Indemnified Contributor") -against any losses, damages and costs (collectively "Losses") -arising from claims, lawsuits and other legal actions brought by a third -party against the Indemnified Contributor to the extent caused by the -acts or omissions of such Commercial Contributor in connection with its -distribution of the Program in a commercial product offering. The -obligations in this section do not apply to any claims or Losses -relating to any actual or alleged intellectual property infringement. In -order to qualify, an Indemnified Contributor must: a) promptly notify -the Commercial Contributor in writing of such claim, and b) allow the -Commercial Contributor to control, and cooperate with the Commercial -Contributor in, the defense and any related settlement negotiations. The -Indemnified Contributor may participate in any such claim at its own -expense.

- -

For example, a Contributor might include the Program in a commercial -product offering, Product X. That Contributor is then a Commercial -Contributor. If that Commercial Contributor then makes performance -claims, or offers warranties related to Product X, those performance -claims and warranties are such Commercial Contributor's responsibility -alone. Under this section, the Commercial Contributor would have to -defend claims against the other Contributors related to those -performance claims and warranties, and if a court requires any other -Contributor to pay any damages as a result, the Commercial Contributor -must pay those damages.

- -

5. NO WARRANTY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS -PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS -OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, -ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY -OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely -responsible for determining the appropriateness of using and -distributing the Program and assumes all risks associated with its -exercise of rights under this Agreement , including but not limited to -the risks and costs of program errors, compliance with applicable laws, -damage to or loss of data, programs or equipment, and unavailability or -interruption of operations.

- -

6. DISCLAIMER OF LIABILITY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT -NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING -WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR -DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED -HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

- -

7. GENERAL

- -

If any provision of this Agreement is invalid or unenforceable under -applicable law, it shall not affect the validity or enforceability of -the remainder of the terms of this Agreement, and without further action -by the parties hereto, such provision shall be reformed to the minimum -extent necessary to make such provision valid and enforceable.

- -

If Recipient institutes patent litigation against any entity -(including a cross-claim or counterclaim in a lawsuit) alleging that the -Program itself (excluding combinations of the Program with other -software or hardware) infringes such Recipient's patent(s), then such -Recipient's rights granted under Section 2(b) shall terminate as of the -date such litigation is filed.

- -

All Recipient's rights under this Agreement shall terminate if it -fails to comply with any of the material terms or conditions of this -Agreement and does not cure such failure in a reasonable period of time -after becoming aware of such noncompliance. If all Recipient's rights -under this Agreement terminate, Recipient agrees to cease use and -distribution of the Program as soon as reasonably practicable. However, -Recipient's obligations under this Agreement and any licenses granted by -Recipient relating to the Program shall continue and survive.

- -

Everyone is permitted to copy and distribute copies of this -Agreement, but in order to avoid inconsistency the Agreement is -copyrighted and may only be modified in the following manner. The -Agreement Steward reserves the right to publish new versions (including -revisions) of this Agreement from time to time. No one other than the -Agreement Steward has the right to modify this Agreement. The Eclipse -Foundation is the initial Agreement Steward. The Eclipse Foundation may -assign the responsibility to serve as the Agreement Steward to a -suitable separate entity. Each new version of the Agreement will be -given a distinguishing version number. The Program (including -Contributions) may always be distributed subject to the version of the -Agreement under which it was received. In addition, after a new version -of the Agreement is published, Contributor may elect to distribute the -Program (including its Contributions) under the new version. Except as -expressly stated in Sections 2(a) and 2(b) above, Recipient receives no -rights or licenses to the intellectual property of any Contributor under -this Agreement, whether expressly, by implication, estoppel or -otherwise. All rights in the Program not expressly granted under this -Agreement are reserved.

- -

This Agreement is governed by the laws of the State of New York and -the intellectual property laws of the United States of America. No party -to this Agreement will bring a legal action under this Agreement more -than one year after the cause of action arose. Each party waives its -rights to a jury trial in any resulting litigation.

- - - - \ No newline at end of file diff --git a/features/org.eclipse.emf.eef.codegen.richtext-feature/feature.properties b/features/org.eclipse.emf.eef.codegen.richtext-feature/feature.properties deleted file mode 100644 index 0434212d8..000000000 --- a/features/org.eclipse.emf.eef.codegen.richtext-feature/feature.properties +++ /dev/null @@ -1,147 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -providerName=Eclipse Modeling Project -featureName=Extended Editing Framework - Richtext widget Generation -modelingUpdateSiteName=Eclipse Modeling Project Updates -description=Extended Editing Framework - \n\ -this includes EPF richtext widget. - -# "licenseURL" property - URL of the "Feature License" -# do not translate value - just change to point to a locale-specific HTML page -licenseURL=license.html - -# "license" property - text of the "Feature Update License" -# should be plain text version of license agreement pointed to be "licenseURL" -license=\ -Eclipse Foundation Software User Agreement\n\ -February 1, 2011\n\ -\n\ -Usage Of Content\n\ -\n\ -THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\ -OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\ -USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\ -AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\ -NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\ -AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\ -AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\ -OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\ -TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\ -OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\ -BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\ -\n\ -Applicable Licenses\n\ -\n\ -Unless otherwise indicated, all Content made available by the\n\ -Eclipse Foundation is provided to you under the terms and conditions of\n\ -the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is\n\ -provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\ -For purposes of the EPL, "Program" will mean the Content.\n\ -\n\ -Content includes, but is not limited to, source code, object code,\n\ -documentation and other files maintained in the Eclipse Foundation source code\n\ -repository ("Repository") in software modules ("Modules") and made available\n\ -as downloadable archives ("Downloads").\n\ -\n\ - - Content may be structured and packaged into modules to facilitate delivering,\n\ - extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\ - plug-in fragments ("Fragments"), and features ("Features").\n\ - - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive)\n\ - in a directory named "plugins".\n\ - - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\ - Each Feature may be packaged as a sub-directory in a directory named "features".\n\ - Within a Feature, files named "feature.xml" may contain a list of the names and version\n\ - numbers of the Plug-ins and/or Fragments associated with that Feature.\n\ - - Features may also include other Features ("Included Features"). Within a Feature, files\n\ - named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\ -\n\ -The terms and conditions governing Plug-ins and Fragments should be\n\ -contained in files named "about.html" ("Abouts"). The terms and\n\ -conditions governing Features and Included Features should be contained\n\ -in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\ -Licenses may be located in any directory of a Download or Module\n\ -including, but not limited to the following locations:\n\ -\n\ - - The top-level (root) directory\n\ - - Plug-in and Fragment directories\n\ - - Inside Plug-ins and Fragments packaged as JARs\n\ - - Sub-directories of the directory named "src" of certain Plug-ins\n\ - - Feature directories\n\ -\n\ -Note: if a Feature made available by the Eclipse Foundation is installed using the\n\ -Provisioning Technology (as defined below), you must agree to a license ("Feature \n\ -Update License") during the installation process. If the Feature contains\n\ -Included Features, the Feature Update License should either provide you\n\ -with the terms and conditions governing the Included Features or inform\n\ -you where you can locate them. Feature Update Licenses may be found in\n\ -the "license" property of files named "feature.properties" found within a Feature.\n\ -Such Abouts, Feature Licenses, and Feature Update Licenses contain the\n\ -terms and conditions (or references to such terms and conditions) that\n\ -govern your use of the associated Content in that directory.\n\ -\n\ -THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER\n\ -TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\ -SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\ -\n\ - - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html)\n\ - - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\ - - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\ - - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\ - - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\ - - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\ -\n\ -IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\ -TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License\n\ -is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\ -govern that particular Content.\n\ -\n\ -\n\Use of Provisioning Technology\n\ -\n\ -The Eclipse Foundation makes available provisioning software, examples of which include,\n\ -but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for\n\ -the purpose of allowing users to install software, documentation, information and/or\n\ -other materials (collectively "Installable Software"). This capability is provided with\n\ -the intent of allowing such users to install, extend and update Eclipse-based products.\n\ -Information about packaging Installable Software is available at\n\ -http://eclipse.org/equinox/p2/repository_packaging.html ("Specification").\n\ -\n\ -You may use Provisioning Technology to allow other parties to install Installable Software.\n\ -You shall be responsible for enabling the applicable license agreements relating to the\n\ -Installable Software to be presented to, and accepted by, the users of the Provisioning Technology\n\ -in accordance with the Specification. By using Provisioning Technology in such a manner and\n\ -making it available in accordance with the Specification, you further acknowledge your\n\ -agreement to, and the acquisition of all necessary rights to permit the following:\n\ -\n\ - 1. A series of actions may occur ("Provisioning Process") in which a user may execute\n\ - the Provisioning Technology on a machine ("Target Machine") with the intent of installing,\n\ - extending or updating the functionality of an Eclipse-based product.\n\ - 2. During the Provisioning Process, the Provisioning Technology may cause third party\n\ - Installable Software or a portion thereof to be accessed and copied to the Target Machine.\n\ - 3. Pursuant to the Specification, you will provide to the user the terms and conditions that\n\ - govern the use of the Installable Software ("Installable Software Agreement") and such\n\ - Installable Software Agreement shall be accessed from the Target Machine in accordance\n\ - with the Specification. Such Installable Software Agreement must inform the user of the\n\ - terms and conditions that govern the Installable Software and must solicit acceptance by\n\ - the end user in the manner prescribed in such Installable Software Agreement. Upon such\n\ - indication of agreement by the user, the provisioning Technology will complete installation\n\ - of the Installable Software.\n\ -\n\ -Cryptography\n\ -\n\ -Content may contain encryption software. The country in which you are\n\ -currently may have restrictions on the import, possession, and use,\n\ -and/or re-export to another country, of encryption software. BEFORE\n\ -using any encryption software, please check the country's laws,\n\ -regulations and policies concerning the import, possession, or use, and\n\ -re-export of encryption software, to see if this is permitted.\n\ -\n\ -Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.\n -########### end of license property ########################################## diff --git a/features/org.eclipse.emf.eef.codegen.richtext-feature/feature.xml b/features/org.eclipse.emf.eef.codegen.richtext-feature/feature.xml deleted file mode 100644 index 468898292..000000000 --- a/features/org.eclipse.emf.eef.codegen.richtext-feature/feature.xml +++ /dev/null @@ -1,45 +0,0 @@ - - - - - - %description - - - - Copyright (c) 2011 Obeo. -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 - - - - %license - - - - - - - - - diff --git a/features/org.eclipse.emf.eef.codegen.richtext-feature/license.html b/features/org.eclipse.emf.eef.codegen.richtext-feature/license.html deleted file mode 100644 index a1fe5ea3f..000000000 --- a/features/org.eclipse.emf.eef.codegen.richtext-feature/license.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - -Eclipse Foundation Software User Agreement - - - -

Eclipse Foundation Software User Agreement

-

February 1, 2011

- -

Usage Of Content

- -

THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS - (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND - CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE - OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR - NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND - CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.

- -

Applicable Licenses

- -

Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 - ("EPL"). A copy of the EPL is provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html. - For purposes of the EPL, "Program" will mean the Content.

- -

Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code - repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").

- -
    -
  • Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").
  • - -
  • Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".
  • -
  • A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins - and/or Fragments associated with that Feature.
  • -
  • Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.
  • - -
- -

The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and -Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module -including, but not limited to the following locations:

- -
    -
  • The top-level (root) directory
  • - -
  • Plug-in and Fragment directories
  • -
  • Inside Plug-ins and Fragments packaged as JARs
  • -
  • Sub-directories of the directory named "src" of certain Plug-ins
  • -
  • Feature directories
  • -
- -

Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the -installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or -inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. -Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in -that directory.

- -

THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE -OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):

- - - -

IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please -contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.

- - -

Use of Provisioning Technology

- -

The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse - Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or - other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to - install, extend and update Eclipse-based products. Information about packaging Installable Software is available at http://eclipse.org/equinox/p2/repository_packaging.html - - ("Specification").

- -

You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the - applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology - in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the - Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:

- -
    -
  1. A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology - on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based - product.
  2. - -
  3. During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be - accessed and copied to the Target Machine.
  4. -
  5. Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable - Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target - Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern - the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such - indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.
  6. -
- -

Cryptography

- -

Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to - another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, - possession, or use, and re-export of encryption software, to see if this is permitted.

- -

Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.

- - - diff --git a/features/org.eclipse.emf.eef.codegen.richtext-feature/license.txt b/features/org.eclipse.emf.eef.codegen.richtext-feature/license.txt deleted file mode 100644 index 24937b64c..000000000 --- a/features/org.eclipse.emf.eef.codegen.richtext-feature/license.txt +++ /dev/null @@ -1,87 +0,0 @@ -Eclipse Public License - v 1.0 - -THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. - -1. DEFINITIONS - -"Contribution" means: - -a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and -b) in the case of each subsequent Contributor: - -i) changes to the Program, and - -ii) additions to the Program; - -where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program. - -"Contributor" means any person or entity that distributes the Program. - -"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. - -"Program" means the Contributions distributed in accordance with this Agreement. - -"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. - -2. GRANT OF RIGHTS - -a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form. - -b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. - -c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. - -d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. - -3. REQUIREMENTS - -A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: - -a) it complies with the terms and conditions of this Agreement; and - -b) its license agreement: - -i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; - -ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; - -iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and - -iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange. - -When the Program is made available in source code form: - -a) it must be made available under this Agreement; and - -b) a copy of this Agreement must be included with each copy of the Program. - -Contributors may not remove or alter any copyright notices contained within the Program. - -Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. - -4. COMMERCIAL DISTRIBUTION - -Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. - -For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. - -5. NO WARRANTY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. - -6. DISCLAIMER OF LIABILITY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - -7. GENERAL - -If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. - -If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. - -All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. - -Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. - -This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. - diff --git a/features/org.eclipse.emf.eef.codegen.richtext-feature/pom.xml b/features/org.eclipse.emf.eef.codegen.richtext-feature/pom.xml deleted file mode 100644 index 6d1dd00c9..000000000 --- a/features/org.eclipse.emf.eef.codegen.richtext-feature/pom.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.codegen.richtext-feature - eclipse-feature - - EEF RichText Codegen Feature - - diff --git a/features/org.eclipse.emf.eef.codegen.uml.feature/.gitignore b/features/org.eclipse.emf.eef.codegen.uml.feature/.gitignore deleted file mode 100644 index eb5a316cb..000000000 --- a/features/org.eclipse.emf.eef.codegen.uml.feature/.gitignore +++ /dev/null @@ -1 +0,0 @@ -target diff --git a/features/org.eclipse.emf.eef.codegen.uml.feature/.project b/features/org.eclipse.emf.eef.codegen.uml.feature/.project deleted file mode 100644 index 556f115a7..000000000 --- a/features/org.eclipse.emf.eef.codegen.uml.feature/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - org.eclipse.emf.eef.codegen.uml.feature - - - - - - org.eclipse.pde.FeatureBuilder - - - - - - org.eclipse.pde.FeatureNature - - diff --git a/features/org.eclipse.emf.eef.codegen.uml.feature/build.properties b/features/org.eclipse.emf.eef.codegen.uml.feature/build.properties deleted file mode 100644 index 7aa629d6d..000000000 --- a/features/org.eclipse.emf.eef.codegen.uml.feature/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = feature.xml,\ - feature.properties,\ - license.html,\ - license.txt,\ - epl-v10.html -src.includes = feature.properties,\ - license.html,\ - license.txt,\ - feature.xml,\ - epl-v10.html diff --git a/features/org.eclipse.emf.eef.codegen.uml.feature/epl-v10.html b/features/org.eclipse.emf.eef.codegen.uml.feature/epl-v10.html deleted file mode 100755 index 0d34dd06a..000000000 --- a/features/org.eclipse.emf.eef.codegen.uml.feature/epl-v10.html +++ /dev/null @@ -1,262 +0,0 @@ - - - - - - -Eclipse Public License - Version 1.0 - - - - - - -

Eclipse Public License - v 1.0

- -

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE -PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR -DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS -AGREEMENT.

- -

1. DEFINITIONS

- -

"Contribution" means:

- -

a) in the case of the initial Contributor, the initial -code and documentation distributed under this Agreement, and

-

b) in the case of each subsequent Contributor:

- -

i) changes to the Program, and

-

ii) additions to the Program;

-

where such changes and/or additions to the Program -originate from and are distributed by that particular Contributor. A -Contribution 'originates' from a Contributor if it was added to the -Program by such Contributor itself or anyone acting on such -Contributor's behalf. Contributions do not include additions to the -Program which: (i) are separate modules of software distributed in -conjunction with the Program under their own license agreement, and (ii) -are not derivative works of the Program.

- -

"Contributor" means any person or entity that distributes -the Program.

- -

"Licensed Patents" mean patent claims licensable by a -Contributor which are necessarily infringed by the use or sale of its -Contribution alone or when combined with the Program.

- -

"Program" means the Contributions distributed in accordance -with this Agreement.

- -

"Recipient" means anyone who receives the Program under -this Agreement, including all Contributors.

- -

2. GRANT OF RIGHTS

- -

a) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free copyright license to reproduce, prepare derivative works -of, publicly display, publicly perform, distribute and sublicense the -Contribution of such Contributor, if any, and such derivative works, in -source code and object code form.

- -

b) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free patent license under Licensed Patents to make, use, sell, -offer to sell, import and otherwise transfer the Contribution of such -Contributor, if any, in source code and object code form. This patent -license shall apply to the combination of the Contribution and the -Program if, at the time the Contribution is added by the Contributor, -such addition of the Contribution causes such combination to be covered -by the Licensed Patents. The patent license shall not apply to any other -combinations which include the Contribution. No hardware per se is -licensed hereunder.

- -

c) Recipient understands that although each Contributor -grants the licenses to its Contributions set forth herein, no assurances -are provided by any Contributor that the Program does not infringe the -patent or other intellectual property rights of any other entity. Each -Contributor disclaims any liability to Recipient for claims brought by -any other entity based on infringement of intellectual property rights -or otherwise. As a condition to exercising the rights and licenses -granted hereunder, each Recipient hereby assumes sole responsibility to -secure any other intellectual property rights needed, if any. For -example, if a third party patent license is required to allow Recipient -to distribute the Program, it is Recipient's responsibility to acquire -that license before distributing the Program.

- -

d) Each Contributor represents that to its knowledge it -has sufficient copyright rights in its Contribution, if any, to grant -the copyright license set forth in this Agreement.

- -

3. REQUIREMENTS

- -

A Contributor may choose to distribute the Program in object code -form under its own license agreement, provided that:

- -

a) it complies with the terms and conditions of this -Agreement; and

- -

b) its license agreement:

- -

i) effectively disclaims on behalf of all Contributors -all warranties and conditions, express and implied, including warranties -or conditions of title and non-infringement, and implied warranties or -conditions of merchantability and fitness for a particular purpose;

- -

ii) effectively excludes on behalf of all Contributors -all liability for damages, including direct, indirect, special, -incidental and consequential damages, such as lost profits;

- -

iii) states that any provisions which differ from this -Agreement are offered by that Contributor alone and not by any other -party; and

- -

iv) states that source code for the Program is available -from such Contributor, and informs licensees how to obtain it in a -reasonable manner on or through a medium customarily used for software -exchange.

- -

When the Program is made available in source code form:

- -

a) it must be made available under this Agreement; and

- -

b) a copy of this Agreement must be included with each -copy of the Program.

- -

Contributors may not remove or alter any copyright notices contained -within the Program.

- -

Each Contributor must identify itself as the originator of its -Contribution, if any, in a manner that reasonably allows subsequent -Recipients to identify the originator of the Contribution.

- -

4. COMMERCIAL DISTRIBUTION

- -

Commercial distributors of software may accept certain -responsibilities with respect to end users, business partners and the -like. While this license is intended to facilitate the commercial use of -the Program, the Contributor who includes the Program in a commercial -product offering should do so in a manner which does not create -potential liability for other Contributors. Therefore, if a Contributor -includes the Program in a commercial product offering, such Contributor -("Commercial Contributor") hereby agrees to defend and -indemnify every other Contributor ("Indemnified Contributor") -against any losses, damages and costs (collectively "Losses") -arising from claims, lawsuits and other legal actions brought by a third -party against the Indemnified Contributor to the extent caused by the -acts or omissions of such Commercial Contributor in connection with its -distribution of the Program in a commercial product offering. The -obligations in this section do not apply to any claims or Losses -relating to any actual or alleged intellectual property infringement. In -order to qualify, an Indemnified Contributor must: a) promptly notify -the Commercial Contributor in writing of such claim, and b) allow the -Commercial Contributor to control, and cooperate with the Commercial -Contributor in, the defense and any related settlement negotiations. The -Indemnified Contributor may participate in any such claim at its own -expense.

- -

For example, a Contributor might include the Program in a commercial -product offering, Product X. That Contributor is then a Commercial -Contributor. If that Commercial Contributor then makes performance -claims, or offers warranties related to Product X, those performance -claims and warranties are such Commercial Contributor's responsibility -alone. Under this section, the Commercial Contributor would have to -defend claims against the other Contributors related to those -performance claims and warranties, and if a court requires any other -Contributor to pay any damages as a result, the Commercial Contributor -must pay those damages.

- -

5. NO WARRANTY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS -PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS -OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, -ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY -OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely -responsible for determining the appropriateness of using and -distributing the Program and assumes all risks associated with its -exercise of rights under this Agreement , including but not limited to -the risks and costs of program errors, compliance with applicable laws, -damage to or loss of data, programs or equipment, and unavailability or -interruption of operations.

- -

6. DISCLAIMER OF LIABILITY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT -NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING -WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR -DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED -HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

- -

7. GENERAL

- -

If any provision of this Agreement is invalid or unenforceable under -applicable law, it shall not affect the validity or enforceability of -the remainder of the terms of this Agreement, and without further action -by the parties hereto, such provision shall be reformed to the minimum -extent necessary to make such provision valid and enforceable.

- -

If Recipient institutes patent litigation against any entity -(including a cross-claim or counterclaim in a lawsuit) alleging that the -Program itself (excluding combinations of the Program with other -software or hardware) infringes such Recipient's patent(s), then such -Recipient's rights granted under Section 2(b) shall terminate as of the -date such litigation is filed.

- -

All Recipient's rights under this Agreement shall terminate if it -fails to comply with any of the material terms or conditions of this -Agreement and does not cure such failure in a reasonable period of time -after becoming aware of such noncompliance. If all Recipient's rights -under this Agreement terminate, Recipient agrees to cease use and -distribution of the Program as soon as reasonably practicable. However, -Recipient's obligations under this Agreement and any licenses granted by -Recipient relating to the Program shall continue and survive.

- -

Everyone is permitted to copy and distribute copies of this -Agreement, but in order to avoid inconsistency the Agreement is -copyrighted and may only be modified in the following manner. The -Agreement Steward reserves the right to publish new versions (including -revisions) of this Agreement from time to time. No one other than the -Agreement Steward has the right to modify this Agreement. The Eclipse -Foundation is the initial Agreement Steward. The Eclipse Foundation may -assign the responsibility to serve as the Agreement Steward to a -suitable separate entity. Each new version of the Agreement will be -given a distinguishing version number. The Program (including -Contributions) may always be distributed subject to the version of the -Agreement under which it was received. In addition, after a new version -of the Agreement is published, Contributor may elect to distribute the -Program (including its Contributions) under the new version. Except as -expressly stated in Sections 2(a) and 2(b) above, Recipient receives no -rights or licenses to the intellectual property of any Contributor under -this Agreement, whether expressly, by implication, estoppel or -otherwise. All rights in the Program not expressly granted under this -Agreement are reserved.

- -

This Agreement is governed by the laws of the State of New York and -the intellectual property laws of the United States of America. No party -to this Agreement will bring a legal action under this Agreement more -than one year after the cause of action arose. Each party waives its -rights to a jury trial in any resulting litigation.

- - - - \ No newline at end of file diff --git a/features/org.eclipse.emf.eef.codegen.uml.feature/feature.properties b/features/org.eclipse.emf.eef.codegen.uml.feature/feature.properties deleted file mode 100644 index c2c001676..000000000 --- a/features/org.eclipse.emf.eef.codegen.uml.feature/feature.properties +++ /dev/null @@ -1,147 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -providerName=Eclipse Modeling Project -featureName=Extended Editing Framework - EEF Generation for UML -modelingUpdateSiteName=Eclipse Modeling Project Updates -description=Extended Editing Framework - EEF Generation for UML. \ -This plugin contains the necessary acceleo templates and code generate EEF specifically for UML. - -# "licenseURL" property - URL of the "Feature License" -# do not translate value - just change to point to a locale-specific HTML page -licenseURL=license.html - -# "license" property - text of the "Feature Update License" -# should be plain text version of license agreement pointed to be "licenseURL" -license=\ -Eclipse Foundation Software User Agreement\n\ -February 1, 2011\n\ -\n\ -Usage Of Content\n\ -\n\ -THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\ -OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\ -USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\ -AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\ -NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\ -AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\ -AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\ -OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\ -TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\ -OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\ -BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\ -\n\ -Applicable Licenses\n\ -\n\ -Unless otherwise indicated, all Content made available by the\n\ -Eclipse Foundation is provided to you under the terms and conditions of\n\ -the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is\n\ -provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\ -For purposes of the EPL, "Program" will mean the Content.\n\ -\n\ -Content includes, but is not limited to, source code, object code,\n\ -documentation and other files maintained in the Eclipse Foundation source code\n\ -repository ("Repository") in software modules ("Modules") and made available\n\ -as downloadable archives ("Downloads").\n\ -\n\ - - Content may be structured and packaged into modules to facilitate delivering,\n\ - extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\ - plug-in fragments ("Fragments"), and features ("Features").\n\ - - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive)\n\ - in a directory named "plugins".\n\ - - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\ - Each Feature may be packaged as a sub-directory in a directory named "features".\n\ - Within a Feature, files named "feature.xml" may contain a list of the names and version\n\ - numbers of the Plug-ins and/or Fragments associated with that Feature.\n\ - - Features may also include other Features ("Included Features"). Within a Feature, files\n\ - named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\ -\n\ -The terms and conditions governing Plug-ins and Fragments should be\n\ -contained in files named "about.html" ("Abouts"). The terms and\n\ -conditions governing Features and Included Features should be contained\n\ -in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\ -Licenses may be located in any directory of a Download or Module\n\ -including, but not limited to the following locations:\n\ -\n\ - - The top-level (root) directory\n\ - - Plug-in and Fragment directories\n\ - - Inside Plug-ins and Fragments packaged as JARs\n\ - - Sub-directories of the directory named "src" of certain Plug-ins\n\ - - Feature directories\n\ -\n\ -Note: if a Feature made available by the Eclipse Foundation is installed using the\n\ -Provisioning Technology (as defined below), you must agree to a license ("Feature \n\ -Update License") during the installation process. If the Feature contains\n\ -Included Features, the Feature Update License should either provide you\n\ -with the terms and conditions governing the Included Features or inform\n\ -you where you can locate them. Feature Update Licenses may be found in\n\ -the "license" property of files named "feature.properties" found within a Feature.\n\ -Such Abouts, Feature Licenses, and Feature Update Licenses contain the\n\ -terms and conditions (or references to such terms and conditions) that\n\ -govern your use of the associated Content in that directory.\n\ -\n\ -THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER\n\ -TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\ -SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\ -\n\ - - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html)\n\ - - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\ - - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\ - - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\ - - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\ - - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\ -\n\ -IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\ -TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License\n\ -is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\ -govern that particular Content.\n\ -\n\ -\n\Use of Provisioning Technology\n\ -\n\ -The Eclipse Foundation makes available provisioning software, examples of which include,\n\ -but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for\n\ -the purpose of allowing users to install software, documentation, information and/or\n\ -other materials (collectively "Installable Software"). This capability is provided with\n\ -the intent of allowing such users to install, extend and update Eclipse-based products.\n\ -Information about packaging Installable Software is available at\n\ -http://eclipse.org/equinox/p2/repository_packaging.html ("Specification").\n\ -\n\ -You may use Provisioning Technology to allow other parties to install Installable Software.\n\ -You shall be responsible for enabling the applicable license agreements relating to the\n\ -Installable Software to be presented to, and accepted by, the users of the Provisioning Technology\n\ -in accordance with the Specification. By using Provisioning Technology in such a manner and\n\ -making it available in accordance with the Specification, you further acknowledge your\n\ -agreement to, and the acquisition of all necessary rights to permit the following:\n\ -\n\ - 1. A series of actions may occur ("Provisioning Process") in which a user may execute\n\ - the Provisioning Technology on a machine ("Target Machine") with the intent of installing,\n\ - extending or updating the functionality of an Eclipse-based product.\n\ - 2. During the Provisioning Process, the Provisioning Technology may cause third party\n\ - Installable Software or a portion thereof to be accessed and copied to the Target Machine.\n\ - 3. Pursuant to the Specification, you will provide to the user the terms and conditions that\n\ - govern the use of the Installable Software ("Installable Software Agreement") and such\n\ - Installable Software Agreement shall be accessed from the Target Machine in accordance\n\ - with the Specification. Such Installable Software Agreement must inform the user of the\n\ - terms and conditions that govern the Installable Software and must solicit acceptance by\n\ - the end user in the manner prescribed in such Installable Software Agreement. Upon such\n\ - indication of agreement by the user, the provisioning Technology will complete installation\n\ - of the Installable Software.\n\ -\n\ -Cryptography\n\ -\n\ -Content may contain encryption software. The country in which you are\n\ -currently may have restrictions on the import, possession, and use,\n\ -and/or re-export to another country, of encryption software. BEFORE\n\ -using any encryption software, please check the country's laws,\n\ -regulations and policies concerning the import, possession, or use, and\n\ -re-export of encryption software, to see if this is permitted.\n\ -\n\ -Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.\n -########### end of license property ########################################## diff --git a/features/org.eclipse.emf.eef.codegen.uml.feature/feature.xml b/features/org.eclipse.emf.eef.codegen.uml.feature/feature.xml deleted file mode 100644 index 15835108b..000000000 --- a/features/org.eclipse.emf.eef.codegen.uml.feature/feature.xml +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - %description - - - - Copyright (c) 2011 Obeo. -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 - - - - %license - - - - - - - - - - - - diff --git a/features/org.eclipse.emf.eef.codegen.uml.feature/license.html b/features/org.eclipse.emf.eef.codegen.uml.feature/license.html deleted file mode 100644 index a1fe5ea3f..000000000 --- a/features/org.eclipse.emf.eef.codegen.uml.feature/license.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - -Eclipse Foundation Software User Agreement - - - -

Eclipse Foundation Software User Agreement

-

February 1, 2011

- -

Usage Of Content

- -

THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS - (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND - CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE - OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR - NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND - CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.

- -

Applicable Licenses

- -

Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 - ("EPL"). A copy of the EPL is provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html. - For purposes of the EPL, "Program" will mean the Content.

- -

Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code - repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").

- -
    -
  • Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").
  • - -
  • Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".
  • -
  • A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins - and/or Fragments associated with that Feature.
  • -
  • Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.
  • - -
- -

The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and -Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module -including, but not limited to the following locations:

- -
    -
  • The top-level (root) directory
  • - -
  • Plug-in and Fragment directories
  • -
  • Inside Plug-ins and Fragments packaged as JARs
  • -
  • Sub-directories of the directory named "src" of certain Plug-ins
  • -
  • Feature directories
  • -
- -

Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the -installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or -inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. -Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in -that directory.

- -

THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE -OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):

- - - -

IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please -contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.

- - -

Use of Provisioning Technology

- -

The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse - Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or - other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to - install, extend and update Eclipse-based products. Information about packaging Installable Software is available at http://eclipse.org/equinox/p2/repository_packaging.html - - ("Specification").

- -

You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the - applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology - in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the - Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:

- -
    -
  1. A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology - on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based - product.
  2. - -
  3. During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be - accessed and copied to the Target Machine.
  4. -
  5. Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable - Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target - Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern - the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such - indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.
  6. -
- -

Cryptography

- -

Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to - another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, - possession, or use, and re-export of encryption software, to see if this is permitted.

- -

Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.

- - - diff --git a/features/org.eclipse.emf.eef.codegen.uml.feature/license.txt b/features/org.eclipse.emf.eef.codegen.uml.feature/license.txt deleted file mode 100644 index 24937b64c..000000000 --- a/features/org.eclipse.emf.eef.codegen.uml.feature/license.txt +++ /dev/null @@ -1,87 +0,0 @@ -Eclipse Public License - v 1.0 - -THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. - -1. DEFINITIONS - -"Contribution" means: - -a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and -b) in the case of each subsequent Contributor: - -i) changes to the Program, and - -ii) additions to the Program; - -where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program. - -"Contributor" means any person or entity that distributes the Program. - -"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. - -"Program" means the Contributions distributed in accordance with this Agreement. - -"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. - -2. GRANT OF RIGHTS - -a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form. - -b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. - -c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. - -d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. - -3. REQUIREMENTS - -A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: - -a) it complies with the terms and conditions of this Agreement; and - -b) its license agreement: - -i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; - -ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; - -iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and - -iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange. - -When the Program is made available in source code form: - -a) it must be made available under this Agreement; and - -b) a copy of this Agreement must be included with each copy of the Program. - -Contributors may not remove or alter any copyright notices contained within the Program. - -Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. - -4. COMMERCIAL DISTRIBUTION - -Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. - -For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. - -5. NO WARRANTY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. - -6. DISCLAIMER OF LIABILITY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - -7. GENERAL - -If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. - -If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. - -All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. - -Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. - -This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. - diff --git a/features/org.eclipse.emf.eef.codegen.uml.feature/pom.xml b/features/org.eclipse.emf.eef.codegen.uml.feature/pom.xml deleted file mode 100644 index c6166c78d..000000000 --- a/features/org.eclipse.emf.eef.codegen.uml.feature/pom.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.codegen.uml.feature - eclipse-feature - - EEF UML Codegen Feature - - diff --git a/features/org.eclipse.emf.eef.collab.runtime-feature/.gitignore b/features/org.eclipse.emf.eef.collab.runtime-feature/.gitignore deleted file mode 100644 index eb5a316cb..000000000 --- a/features/org.eclipse.emf.eef.collab.runtime-feature/.gitignore +++ /dev/null @@ -1 +0,0 @@ -target diff --git a/features/org.eclipse.emf.eef.collab.runtime-feature/.project b/features/org.eclipse.emf.eef.collab.runtime-feature/.project deleted file mode 100644 index a9a5df5d5..000000000 --- a/features/org.eclipse.emf.eef.collab.runtime-feature/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - org.eclipse.emf.eef.collab.runtime-feature - - - - - - org.eclipse.pde.FeatureBuilder - - - - - - org.eclipse.pde.FeatureNature - - diff --git a/features/org.eclipse.emf.eef.collab.runtime-feature/build.properties b/features/org.eclipse.emf.eef.collab.runtime-feature/build.properties deleted file mode 100644 index 2f5d242cc..000000000 --- a/features/org.eclipse.emf.eef.collab.runtime-feature/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2010 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = feature.xml,\ - feature.properties,\ - license.html,\ - license.txt,\ - epl-v10.html -src.includes = feature.properties,\ - license.html,\ - license.txt,\ - feature.xml,\ - epl-v10.html diff --git a/features/org.eclipse.emf.eef.collab.runtime-feature/epl-v10.html b/features/org.eclipse.emf.eef.collab.runtime-feature/epl-v10.html deleted file mode 100644 index 0d34dd06a..000000000 --- a/features/org.eclipse.emf.eef.collab.runtime-feature/epl-v10.html +++ /dev/null @@ -1,262 +0,0 @@ - - - - - - -Eclipse Public License - Version 1.0 - - - - - - -

Eclipse Public License - v 1.0

- -

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE -PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR -DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS -AGREEMENT.

- -

1. DEFINITIONS

- -

"Contribution" means:

- -

a) in the case of the initial Contributor, the initial -code and documentation distributed under this Agreement, and

-

b) in the case of each subsequent Contributor:

- -

i) changes to the Program, and

-

ii) additions to the Program;

-

where such changes and/or additions to the Program -originate from and are distributed by that particular Contributor. A -Contribution 'originates' from a Contributor if it was added to the -Program by such Contributor itself or anyone acting on such -Contributor's behalf. Contributions do not include additions to the -Program which: (i) are separate modules of software distributed in -conjunction with the Program under their own license agreement, and (ii) -are not derivative works of the Program.

- -

"Contributor" means any person or entity that distributes -the Program.

- -

"Licensed Patents" mean patent claims licensable by a -Contributor which are necessarily infringed by the use or sale of its -Contribution alone or when combined with the Program.

- -

"Program" means the Contributions distributed in accordance -with this Agreement.

- -

"Recipient" means anyone who receives the Program under -this Agreement, including all Contributors.

- -

2. GRANT OF RIGHTS

- -

a) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free copyright license to reproduce, prepare derivative works -of, publicly display, publicly perform, distribute and sublicense the -Contribution of such Contributor, if any, and such derivative works, in -source code and object code form.

- -

b) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free patent license under Licensed Patents to make, use, sell, -offer to sell, import and otherwise transfer the Contribution of such -Contributor, if any, in source code and object code form. This patent -license shall apply to the combination of the Contribution and the -Program if, at the time the Contribution is added by the Contributor, -such addition of the Contribution causes such combination to be covered -by the Licensed Patents. The patent license shall not apply to any other -combinations which include the Contribution. No hardware per se is -licensed hereunder.

- -

c) Recipient understands that although each Contributor -grants the licenses to its Contributions set forth herein, no assurances -are provided by any Contributor that the Program does not infringe the -patent or other intellectual property rights of any other entity. Each -Contributor disclaims any liability to Recipient for claims brought by -any other entity based on infringement of intellectual property rights -or otherwise. As a condition to exercising the rights and licenses -granted hereunder, each Recipient hereby assumes sole responsibility to -secure any other intellectual property rights needed, if any. For -example, if a third party patent license is required to allow Recipient -to distribute the Program, it is Recipient's responsibility to acquire -that license before distributing the Program.

- -

d) Each Contributor represents that to its knowledge it -has sufficient copyright rights in its Contribution, if any, to grant -the copyright license set forth in this Agreement.

- -

3. REQUIREMENTS

- -

A Contributor may choose to distribute the Program in object code -form under its own license agreement, provided that:

- -

a) it complies with the terms and conditions of this -Agreement; and

- -

b) its license agreement:

- -

i) effectively disclaims on behalf of all Contributors -all warranties and conditions, express and implied, including warranties -or conditions of title and non-infringement, and implied warranties or -conditions of merchantability and fitness for a particular purpose;

- -

ii) effectively excludes on behalf of all Contributors -all liability for damages, including direct, indirect, special, -incidental and consequential damages, such as lost profits;

- -

iii) states that any provisions which differ from this -Agreement are offered by that Contributor alone and not by any other -party; and

- -

iv) states that source code for the Program is available -from such Contributor, and informs licensees how to obtain it in a -reasonable manner on or through a medium customarily used for software -exchange.

- -

When the Program is made available in source code form:

- -

a) it must be made available under this Agreement; and

- -

b) a copy of this Agreement must be included with each -copy of the Program.

- -

Contributors may not remove or alter any copyright notices contained -within the Program.

- -

Each Contributor must identify itself as the originator of its -Contribution, if any, in a manner that reasonably allows subsequent -Recipients to identify the originator of the Contribution.

- -

4. COMMERCIAL DISTRIBUTION

- -

Commercial distributors of software may accept certain -responsibilities with respect to end users, business partners and the -like. While this license is intended to facilitate the commercial use of -the Program, the Contributor who includes the Program in a commercial -product offering should do so in a manner which does not create -potential liability for other Contributors. Therefore, if a Contributor -includes the Program in a commercial product offering, such Contributor -("Commercial Contributor") hereby agrees to defend and -indemnify every other Contributor ("Indemnified Contributor") -against any losses, damages and costs (collectively "Losses") -arising from claims, lawsuits and other legal actions brought by a third -party against the Indemnified Contributor to the extent caused by the -acts or omissions of such Commercial Contributor in connection with its -distribution of the Program in a commercial product offering. The -obligations in this section do not apply to any claims or Losses -relating to any actual or alleged intellectual property infringement. In -order to qualify, an Indemnified Contributor must: a) promptly notify -the Commercial Contributor in writing of such claim, and b) allow the -Commercial Contributor to control, and cooperate with the Commercial -Contributor in, the defense and any related settlement negotiations. The -Indemnified Contributor may participate in any such claim at its own -expense.

- -

For example, a Contributor might include the Program in a commercial -product offering, Product X. That Contributor is then a Commercial -Contributor. If that Commercial Contributor then makes performance -claims, or offers warranties related to Product X, those performance -claims and warranties are such Commercial Contributor's responsibility -alone. Under this section, the Commercial Contributor would have to -defend claims against the other Contributors related to those -performance claims and warranties, and if a court requires any other -Contributor to pay any damages as a result, the Commercial Contributor -must pay those damages.

- -

5. NO WARRANTY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS -PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS -OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, -ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY -OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely -responsible for determining the appropriateness of using and -distributing the Program and assumes all risks associated with its -exercise of rights under this Agreement , including but not limited to -the risks and costs of program errors, compliance with applicable laws, -damage to or loss of data, programs or equipment, and unavailability or -interruption of operations.

- -

6. DISCLAIMER OF LIABILITY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT -NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING -WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR -DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED -HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

- -

7. GENERAL

- -

If any provision of this Agreement is invalid or unenforceable under -applicable law, it shall not affect the validity or enforceability of -the remainder of the terms of this Agreement, and without further action -by the parties hereto, such provision shall be reformed to the minimum -extent necessary to make such provision valid and enforceable.

- -

If Recipient institutes patent litigation against any entity -(including a cross-claim or counterclaim in a lawsuit) alleging that the -Program itself (excluding combinations of the Program with other -software or hardware) infringes such Recipient's patent(s), then such -Recipient's rights granted under Section 2(b) shall terminate as of the -date such litigation is filed.

- -

All Recipient's rights under this Agreement shall terminate if it -fails to comply with any of the material terms or conditions of this -Agreement and does not cure such failure in a reasonable period of time -after becoming aware of such noncompliance. If all Recipient's rights -under this Agreement terminate, Recipient agrees to cease use and -distribution of the Program as soon as reasonably practicable. However, -Recipient's obligations under this Agreement and any licenses granted by -Recipient relating to the Program shall continue and survive.

- -

Everyone is permitted to copy and distribute copies of this -Agreement, but in order to avoid inconsistency the Agreement is -copyrighted and may only be modified in the following manner. The -Agreement Steward reserves the right to publish new versions (including -revisions) of this Agreement from time to time. No one other than the -Agreement Steward has the right to modify this Agreement. The Eclipse -Foundation is the initial Agreement Steward. The Eclipse Foundation may -assign the responsibility to serve as the Agreement Steward to a -suitable separate entity. Each new version of the Agreement will be -given a distinguishing version number. The Program (including -Contributions) may always be distributed subject to the version of the -Agreement under which it was received. In addition, after a new version -of the Agreement is published, Contributor may elect to distribute the -Program (including its Contributions) under the new version. Except as -expressly stated in Sections 2(a) and 2(b) above, Recipient receives no -rights or licenses to the intellectual property of any Contributor under -this Agreement, whether expressly, by implication, estoppel or -otherwise. All rights in the Program not expressly granted under this -Agreement are reserved.

- -

This Agreement is governed by the laws of the State of New York and -the intellectual property laws of the United States of America. No party -to this Agreement will bring a legal action under this Agreement more -than one year after the cause of action arose. Each party waives its -rights to a jury trial in any resulting litigation.

- - - - \ No newline at end of file diff --git a/features/org.eclipse.emf.eef.collab.runtime-feature/feature.properties b/features/org.eclipse.emf.eef.collab.runtime-feature/feature.properties deleted file mode 100644 index 688aba8f3..000000000 --- a/features/org.eclipse.emf.eef.collab.runtime-feature/feature.properties +++ /dev/null @@ -1,146 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -providerName=Eclipse Modeling Project -featureName=Extended Editing Framework - Extension for collaboration editing -modelingUpdateSiteName=Eclipse Modeling Project Updates -description=Extended Editing Framework - Extension for collaboration editing - -# "licenseURL" property - URL of the "Feature License" -# do not translate value - just change to point to a locale-specific HTML page -licenseURL=license.html - -# "license" property - text of the "Feature Update License" -# should be plain text version of license agreement pointed to be "licenseURL" -license=\ -Eclipse Foundation Software User Agreement\n\ -February 1, 2011\n\ -\n\ -Usage Of Content\n\ -\n\ -THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\ -OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\ -USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\ -AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\ -NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\ -AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\ -AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\ -OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\ -TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\ -OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\ -BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\ -\n\ -Applicable Licenses\n\ -\n\ -Unless otherwise indicated, all Content made available by the\n\ -Eclipse Foundation is provided to you under the terms and conditions of\n\ -the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is\n\ -provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\ -For purposes of the EPL, "Program" will mean the Content.\n\ -\n\ -Content includes, but is not limited to, source code, object code,\n\ -documentation and other files maintained in the Eclipse Foundation source code\n\ -repository ("Repository") in software modules ("Modules") and made available\n\ -as downloadable archives ("Downloads").\n\ -\n\ - - Content may be structured and packaged into modules to facilitate delivering,\n\ - extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\ - plug-in fragments ("Fragments"), and features ("Features").\n\ - - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive)\n\ - in a directory named "plugins".\n\ - - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\ - Each Feature may be packaged as a sub-directory in a directory named "features".\n\ - Within a Feature, files named "feature.xml" may contain a list of the names and version\n\ - numbers of the Plug-ins and/or Fragments associated with that Feature.\n\ - - Features may also include other Features ("Included Features"). Within a Feature, files\n\ - named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\ -\n\ -The terms and conditions governing Plug-ins and Fragments should be\n\ -contained in files named "about.html" ("Abouts"). The terms and\n\ -conditions governing Features and Included Features should be contained\n\ -in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\ -Licenses may be located in any directory of a Download or Module\n\ -including, but not limited to the following locations:\n\ -\n\ - - The top-level (root) directory\n\ - - Plug-in and Fragment directories\n\ - - Inside Plug-ins and Fragments packaged as JARs\n\ - - Sub-directories of the directory named "src" of certain Plug-ins\n\ - - Feature directories\n\ -\n\ -Note: if a Feature made available by the Eclipse Foundation is installed using the\n\ -Provisioning Technology (as defined below), you must agree to a license ("Feature \n\ -Update License") during the installation process. If the Feature contains\n\ -Included Features, the Feature Update License should either provide you\n\ -with the terms and conditions governing the Included Features or inform\n\ -you where you can locate them. Feature Update Licenses may be found in\n\ -the "license" property of files named "feature.properties" found within a Feature.\n\ -Such Abouts, Feature Licenses, and Feature Update Licenses contain the\n\ -terms and conditions (or references to such terms and conditions) that\n\ -govern your use of the associated Content in that directory.\n\ -\n\ -THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER\n\ -TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\ -SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\ -\n\ - - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html)\n\ - - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\ - - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\ - - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\ - - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\ - - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\ -\n\ -IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\ -TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License\n\ -is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\ -govern that particular Content.\n\ -\n\ -\n\Use of Provisioning Technology\n\ -\n\ -The Eclipse Foundation makes available provisioning software, examples of which include,\n\ -but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for\n\ -the purpose of allowing users to install software, documentation, information and/or\n\ -other materials (collectively "Installable Software"). This capability is provided with\n\ -the intent of allowing such users to install, extend and update Eclipse-based products.\n\ -Information about packaging Installable Software is available at\n\ -http://eclipse.org/equinox/p2/repository_packaging.html ("Specification").\n\ -\n\ -You may use Provisioning Technology to allow other parties to install Installable Software.\n\ -You shall be responsible for enabling the applicable license agreements relating to the\n\ -Installable Software to be presented to, and accepted by, the users of the Provisioning Technology\n\ -in accordance with the Specification. By using Provisioning Technology in such a manner and\n\ -making it available in accordance with the Specification, you further acknowledge your\n\ -agreement to, and the acquisition of all necessary rights to permit the following:\n\ -\n\ - 1. A series of actions may occur ("Provisioning Process") in which a user may execute\n\ - the Provisioning Technology on a machine ("Target Machine") with the intent of installing,\n\ - extending or updating the functionality of an Eclipse-based product.\n\ - 2. During the Provisioning Process, the Provisioning Technology may cause third party\n\ - Installable Software or a portion thereof to be accessed and copied to the Target Machine.\n\ - 3. Pursuant to the Specification, you will provide to the user the terms and conditions that\n\ - govern the use of the Installable Software ("Installable Software Agreement") and such\n\ - Installable Software Agreement shall be accessed from the Target Machine in accordance\n\ - with the Specification. Such Installable Software Agreement must inform the user of the\n\ - terms and conditions that govern the Installable Software and must solicit acceptance by\n\ - the end user in the manner prescribed in such Installable Software Agreement. Upon such\n\ - indication of agreement by the user, the provisioning Technology will complete installation\n\ - of the Installable Software.\n\ -\n\ -Cryptography\n\ -\n\ -Content may contain encryption software. The country in which you are\n\ -currently may have restrictions on the import, possession, and use,\n\ -and/or re-export to another country, of encryption software. BEFORE\n\ -using any encryption software, please check the country's laws,\n\ -regulations and policies concerning the import, possession, or use, and\n\ -re-export of encryption software, to see if this is permitted.\n\ -\n\ -Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.\n -########### end of license property ########################################## diff --git a/features/org.eclipse.emf.eef.collab.runtime-feature/feature.xml b/features/org.eclipse.emf.eef.collab.runtime-feature/feature.xml deleted file mode 100644 index 257b879f8..000000000 --- a/features/org.eclipse.emf.eef.collab.runtime-feature/feature.xml +++ /dev/null @@ -1,49 +0,0 @@ - - - - - - %description - - - - Copyright (c) 2008 - 2010 Obeo. -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 - - - - %license - - - - - - - - - - diff --git a/features/org.eclipse.emf.eef.collab.runtime-feature/license.html b/features/org.eclipse.emf.eef.collab.runtime-feature/license.html deleted file mode 100644 index a1fe5ea3f..000000000 --- a/features/org.eclipse.emf.eef.collab.runtime-feature/license.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - -Eclipse Foundation Software User Agreement - - - -

Eclipse Foundation Software User Agreement

-

February 1, 2011

- -

Usage Of Content

- -

THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS - (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND - CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE - OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR - NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND - CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.

- -

Applicable Licenses

- -

Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 - ("EPL"). A copy of the EPL is provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html. - For purposes of the EPL, "Program" will mean the Content.

- -

Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code - repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").

- -
    -
  • Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").
  • - -
  • Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".
  • -
  • A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins - and/or Fragments associated with that Feature.
  • -
  • Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.
  • - -
- -

The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and -Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module -including, but not limited to the following locations:

- -
    -
  • The top-level (root) directory
  • - -
  • Plug-in and Fragment directories
  • -
  • Inside Plug-ins and Fragments packaged as JARs
  • -
  • Sub-directories of the directory named "src" of certain Plug-ins
  • -
  • Feature directories
  • -
- -

Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the -installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or -inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. -Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in -that directory.

- -

THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE -OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):

- - - -

IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please -contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.

- - -

Use of Provisioning Technology

- -

The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse - Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or - other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to - install, extend and update Eclipse-based products. Information about packaging Installable Software is available at http://eclipse.org/equinox/p2/repository_packaging.html - - ("Specification").

- -

You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the - applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology - in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the - Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:

- -
    -
  1. A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology - on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based - product.
  2. - -
  3. During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be - accessed and copied to the Target Machine.
  4. -
  5. Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable - Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target - Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern - the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such - indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.
  6. -
- -

Cryptography

- -

Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to - another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, - possession, or use, and re-export of encryption software, to see if this is permitted.

- -

Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.

- - - diff --git a/features/org.eclipse.emf.eef.collab.runtime-feature/license.txt b/features/org.eclipse.emf.eef.collab.runtime-feature/license.txt deleted file mode 100644 index 24937b64c..000000000 --- a/features/org.eclipse.emf.eef.collab.runtime-feature/license.txt +++ /dev/null @@ -1,87 +0,0 @@ -Eclipse Public License - v 1.0 - -THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. - -1. DEFINITIONS - -"Contribution" means: - -a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and -b) in the case of each subsequent Contributor: - -i) changes to the Program, and - -ii) additions to the Program; - -where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program. - -"Contributor" means any person or entity that distributes the Program. - -"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. - -"Program" means the Contributions distributed in accordance with this Agreement. - -"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. - -2. GRANT OF RIGHTS - -a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form. - -b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. - -c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. - -d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. - -3. REQUIREMENTS - -A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: - -a) it complies with the terms and conditions of this Agreement; and - -b) its license agreement: - -i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; - -ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; - -iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and - -iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange. - -When the Program is made available in source code form: - -a) it must be made available under this Agreement; and - -b) a copy of this Agreement must be included with each copy of the Program. - -Contributors may not remove or alter any copyright notices contained within the Program. - -Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. - -4. COMMERCIAL DISTRIBUTION - -Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. - -For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. - -5. NO WARRANTY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. - -6. DISCLAIMER OF LIABILITY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - -7. GENERAL - -If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. - -If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. - -All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. - -Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. - -This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. - diff --git a/features/org.eclipse.emf.eef.collab.runtime-feature/pom.xml b/features/org.eclipse.emf.eef.collab.runtime-feature/pom.xml deleted file mode 100644 index 2863f08c1..000000000 --- a/features/org.eclipse.emf.eef.collab.runtime-feature/pom.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.collab.runtime-feature - eclipse-feature - - EEF Runtime Feature - - diff --git a/features/org.eclipse.emf.eef.edt-feature/.gitignore b/features/org.eclipse.emf.eef.edt-feature/.gitignore deleted file mode 100644 index eb5a316cb..000000000 --- a/features/org.eclipse.emf.eef.edt-feature/.gitignore +++ /dev/null @@ -1 +0,0 @@ -target diff --git a/features/org.eclipse.emf.eef.edt-feature/.project b/features/org.eclipse.emf.eef.edt-feature/.project deleted file mode 100644 index f60852d33..000000000 --- a/features/org.eclipse.emf.eef.edt-feature/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - org.eclipse.emf.eef.edt-feature - - - - - - org.eclipse.pde.FeatureBuilder - - - - - - org.eclipse.pde.FeatureNature - - diff --git a/features/org.eclipse.emf.eef.edt-feature/build.properties b/features/org.eclipse.emf.eef.edt-feature/build.properties deleted file mode 100644 index 2f5d242cc..000000000 --- a/features/org.eclipse.emf.eef.edt-feature/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2010 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = feature.xml,\ - feature.properties,\ - license.html,\ - license.txt,\ - epl-v10.html -src.includes = feature.properties,\ - license.html,\ - license.txt,\ - feature.xml,\ - epl-v10.html diff --git a/features/org.eclipse.emf.eef.edt-feature/epl-v10.html b/features/org.eclipse.emf.eef.edt-feature/epl-v10.html deleted file mode 100644 index 0d34dd06a..000000000 --- a/features/org.eclipse.emf.eef.edt-feature/epl-v10.html +++ /dev/null @@ -1,262 +0,0 @@ - - - - - - -Eclipse Public License - Version 1.0 - - - - - - -

Eclipse Public License - v 1.0

- -

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE -PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR -DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS -AGREEMENT.

- -

1. DEFINITIONS

- -

"Contribution" means:

- -

a) in the case of the initial Contributor, the initial -code and documentation distributed under this Agreement, and

-

b) in the case of each subsequent Contributor:

- -

i) changes to the Program, and

-

ii) additions to the Program;

-

where such changes and/or additions to the Program -originate from and are distributed by that particular Contributor. A -Contribution 'originates' from a Contributor if it was added to the -Program by such Contributor itself or anyone acting on such -Contributor's behalf. Contributions do not include additions to the -Program which: (i) are separate modules of software distributed in -conjunction with the Program under their own license agreement, and (ii) -are not derivative works of the Program.

- -

"Contributor" means any person or entity that distributes -the Program.

- -

"Licensed Patents" mean patent claims licensable by a -Contributor which are necessarily infringed by the use or sale of its -Contribution alone or when combined with the Program.

- -

"Program" means the Contributions distributed in accordance -with this Agreement.

- -

"Recipient" means anyone who receives the Program under -this Agreement, including all Contributors.

- -

2. GRANT OF RIGHTS

- -

a) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free copyright license to reproduce, prepare derivative works -of, publicly display, publicly perform, distribute and sublicense the -Contribution of such Contributor, if any, and such derivative works, in -source code and object code form.

- -

b) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free patent license under Licensed Patents to make, use, sell, -offer to sell, import and otherwise transfer the Contribution of such -Contributor, if any, in source code and object code form. This patent -license shall apply to the combination of the Contribution and the -Program if, at the time the Contribution is added by the Contributor, -such addition of the Contribution causes such combination to be covered -by the Licensed Patents. The patent license shall not apply to any other -combinations which include the Contribution. No hardware per se is -licensed hereunder.

- -

c) Recipient understands that although each Contributor -grants the licenses to its Contributions set forth herein, no assurances -are provided by any Contributor that the Program does not infringe the -patent or other intellectual property rights of any other entity. Each -Contributor disclaims any liability to Recipient for claims brought by -any other entity based on infringement of intellectual property rights -or otherwise. As a condition to exercising the rights and licenses -granted hereunder, each Recipient hereby assumes sole responsibility to -secure any other intellectual property rights needed, if any. For -example, if a third party patent license is required to allow Recipient -to distribute the Program, it is Recipient's responsibility to acquire -that license before distributing the Program.

- -

d) Each Contributor represents that to its knowledge it -has sufficient copyright rights in its Contribution, if any, to grant -the copyright license set forth in this Agreement.

- -

3. REQUIREMENTS

- -

A Contributor may choose to distribute the Program in object code -form under its own license agreement, provided that:

- -

a) it complies with the terms and conditions of this -Agreement; and

- -

b) its license agreement:

- -

i) effectively disclaims on behalf of all Contributors -all warranties and conditions, express and implied, including warranties -or conditions of title and non-infringement, and implied warranties or -conditions of merchantability and fitness for a particular purpose;

- -

ii) effectively excludes on behalf of all Contributors -all liability for damages, including direct, indirect, special, -incidental and consequential damages, such as lost profits;

- -

iii) states that any provisions which differ from this -Agreement are offered by that Contributor alone and not by any other -party; and

- -

iv) states that source code for the Program is available -from such Contributor, and informs licensees how to obtain it in a -reasonable manner on or through a medium customarily used for software -exchange.

- -

When the Program is made available in source code form:

- -

a) it must be made available under this Agreement; and

- -

b) a copy of this Agreement must be included with each -copy of the Program.

- -

Contributors may not remove or alter any copyright notices contained -within the Program.

- -

Each Contributor must identify itself as the originator of its -Contribution, if any, in a manner that reasonably allows subsequent -Recipients to identify the originator of the Contribution.

- -

4. COMMERCIAL DISTRIBUTION

- -

Commercial distributors of software may accept certain -responsibilities with respect to end users, business partners and the -like. While this license is intended to facilitate the commercial use of -the Program, the Contributor who includes the Program in a commercial -product offering should do so in a manner which does not create -potential liability for other Contributors. Therefore, if a Contributor -includes the Program in a commercial product offering, such Contributor -("Commercial Contributor") hereby agrees to defend and -indemnify every other Contributor ("Indemnified Contributor") -against any losses, damages and costs (collectively "Losses") -arising from claims, lawsuits and other legal actions brought by a third -party against the Indemnified Contributor to the extent caused by the -acts or omissions of such Commercial Contributor in connection with its -distribution of the Program in a commercial product offering. The -obligations in this section do not apply to any claims or Losses -relating to any actual or alleged intellectual property infringement. In -order to qualify, an Indemnified Contributor must: a) promptly notify -the Commercial Contributor in writing of such claim, and b) allow the -Commercial Contributor to control, and cooperate with the Commercial -Contributor in, the defense and any related settlement negotiations. The -Indemnified Contributor may participate in any such claim at its own -expense.

- -

For example, a Contributor might include the Program in a commercial -product offering, Product X. That Contributor is then a Commercial -Contributor. If that Commercial Contributor then makes performance -claims, or offers warranties related to Product X, those performance -claims and warranties are such Commercial Contributor's responsibility -alone. Under this section, the Commercial Contributor would have to -defend claims against the other Contributors related to those -performance claims and warranties, and if a court requires any other -Contributor to pay any damages as a result, the Commercial Contributor -must pay those damages.

- -

5. NO WARRANTY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS -PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS -OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, -ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY -OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely -responsible for determining the appropriateness of using and -distributing the Program and assumes all risks associated with its -exercise of rights under this Agreement , including but not limited to -the risks and costs of program errors, compliance with applicable laws, -damage to or loss of data, programs or equipment, and unavailability or -interruption of operations.

- -

6. DISCLAIMER OF LIABILITY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT -NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING -WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR -DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED -HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

- -

7. GENERAL

- -

If any provision of this Agreement is invalid or unenforceable under -applicable law, it shall not affect the validity or enforceability of -the remainder of the terms of this Agreement, and without further action -by the parties hereto, such provision shall be reformed to the minimum -extent necessary to make such provision valid and enforceable.

- -

If Recipient institutes patent litigation against any entity -(including a cross-claim or counterclaim in a lawsuit) alleging that the -Program itself (excluding combinations of the Program with other -software or hardware) infringes such Recipient's patent(s), then such -Recipient's rights granted under Section 2(b) shall terminate as of the -date such litigation is filed.

- -

All Recipient's rights under this Agreement shall terminate if it -fails to comply with any of the material terms or conditions of this -Agreement and does not cure such failure in a reasonable period of time -after becoming aware of such noncompliance. If all Recipient's rights -under this Agreement terminate, Recipient agrees to cease use and -distribution of the Program as soon as reasonably practicable. However, -Recipient's obligations under this Agreement and any licenses granted by -Recipient relating to the Program shall continue and survive.

- -

Everyone is permitted to copy and distribute copies of this -Agreement, but in order to avoid inconsistency the Agreement is -copyrighted and may only be modified in the following manner. The -Agreement Steward reserves the right to publish new versions (including -revisions) of this Agreement from time to time. No one other than the -Agreement Steward has the right to modify this Agreement. The Eclipse -Foundation is the initial Agreement Steward. The Eclipse Foundation may -assign the responsibility to serve as the Agreement Steward to a -suitable separate entity. Each new version of the Agreement will be -given a distinguishing version number. The Program (including -Contributions) may always be distributed subject to the version of the -Agreement under which it was received. In addition, after a new version -of the Agreement is published, Contributor may elect to distribute the -Program (including its Contributions) under the new version. Except as -expressly stated in Sections 2(a) and 2(b) above, Recipient receives no -rights or licenses to the intellectual property of any Contributor under -this Agreement, whether expressly, by implication, estoppel or -otherwise. All rights in the Program not expressly granted under this -Agreement are reserved.

- -

This Agreement is governed by the laws of the State of New York and -the intellectual property laws of the United States of America. No party -to this Agreement will bring a legal action under this Agreement more -than one year after the cause of action arose. Each party waives its -rights to a jury trial in any resulting litigation.

- - - - \ No newline at end of file diff --git a/features/org.eclipse.emf.eef.edt-feature/feature.properties b/features/org.eclipse.emf.eef.edt-feature/feature.properties deleted file mode 100644 index cfaf37ad2..000000000 --- a/features/org.eclipse.emf.eef.edt-feature/feature.properties +++ /dev/null @@ -1,159 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -# "providerName" property - name of the company that provides the feature -providerName=Eclipse Modeling Project - -# "featureName" property - name of the feature -featureName=Extended Editing Framework - Development Tools - -# "updateSiteName" property - label for the update site (on download.eclipse.org) -modelingUpdateSiteName=Eclipse Modeling Project Updates - -# "description" property - description of the feature -description=Extended Editing Framework - Development Tools.\n\ -This includes :\n\ -- EEF metamodels\n\ -- EEF editors\n\ -- EEF models initializer\n\ -- EEF Acceleo generators\n\ -- EEF documentation\n\ - -# "licenseURL" property - URL of the "Feature License" -# do not translate value - just change to point to a locale-specific HTML page -licenseURL=license.html - -# "license" property - text of the "Feature Update License" -# should be plain text version of license agreement pointed to be "licenseURL" -license=\ -Eclipse Foundation Software User Agreement\n\ -February 1, 2011\n\ -\n\ -Usage Of Content\n\ -\n\ -THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\ -OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\ -USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\ -AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\ -NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\ -AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\ -AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\ -OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\ -TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\ -OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\ -BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\ -\n\ -Applicable Licenses\n\ -\n\ -Unless otherwise indicated, all Content made available by the\n\ -Eclipse Foundation is provided to you under the terms and conditions of\n\ -the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is\n\ -provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\ -For purposes of the EPL, "Program" will mean the Content.\n\ -\n\ -Content includes, but is not limited to, source code, object code,\n\ -documentation and other files maintained in the Eclipse Foundation source code\n\ -repository ("Repository") in software modules ("Modules") and made available\n\ -as downloadable archives ("Downloads").\n\ -\n\ - - Content may be structured and packaged into modules to facilitate delivering,\n\ - extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\ - plug-in fragments ("Fragments"), and features ("Features").\n\ - - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive)\n\ - in a directory named "plugins".\n\ - - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\ - Each Feature may be packaged as a sub-directory in a directory named "features".\n\ - Within a Feature, files named "feature.xml" may contain a list of the names and version\n\ - numbers of the Plug-ins and/or Fragments associated with that Feature.\n\ - - Features may also include other Features ("Included Features"). Within a Feature, files\n\ - named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\ -\n\ -The terms and conditions governing Plug-ins and Fragments should be\n\ -contained in files named "about.html" ("Abouts"). The terms and\n\ -conditions governing Features and Included Features should be contained\n\ -in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\ -Licenses may be located in any directory of a Download or Module\n\ -including, but not limited to the following locations:\n\ -\n\ - - The top-level (root) directory\n\ - - Plug-in and Fragment directories\n\ - - Inside Plug-ins and Fragments packaged as JARs\n\ - - Sub-directories of the directory named "src" of certain Plug-ins\n\ - - Feature directories\n\ -\n\ -Note: if a Feature made available by the Eclipse Foundation is installed using the\n\ -Provisioning Technology (as defined below), you must agree to a license ("Feature \n\ -Update License") during the installation process. If the Feature contains\n\ -Included Features, the Feature Update License should either provide you\n\ -with the terms and conditions governing the Included Features or inform\n\ -you where you can locate them. Feature Update Licenses may be found in\n\ -the "license" property of files named "feature.properties" found within a Feature.\n\ -Such Abouts, Feature Licenses, and Feature Update Licenses contain the\n\ -terms and conditions (or references to such terms and conditions) that\n\ -govern your use of the associated Content in that directory.\n\ -\n\ -THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER\n\ -TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\ -SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\ -\n\ - - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html)\n\ - - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\ - - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\ - - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\ - - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\ - - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\ -\n\ -IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\ -TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License\n\ -is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\ -govern that particular Content.\n\ -\n\ -\n\Use of Provisioning Technology\n\ -\n\ -The Eclipse Foundation makes available provisioning software, examples of which include,\n\ -but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for\n\ -the purpose of allowing users to install software, documentation, information and/or\n\ -other materials (collectively "Installable Software"). This capability is provided with\n\ -the intent of allowing such users to install, extend and update Eclipse-based products.\n\ -Information about packaging Installable Software is available at\n\ -http://eclipse.org/equinox/p2/repository_packaging.html ("Specification").\n\ -\n\ -You may use Provisioning Technology to allow other parties to install Installable Software.\n\ -You shall be responsible for enabling the applicable license agreements relating to the\n\ -Installable Software to be presented to, and accepted by, the users of the Provisioning Technology\n\ -in accordance with the Specification. By using Provisioning Technology in such a manner and\n\ -making it available in accordance with the Specification, you further acknowledge your\n\ -agreement to, and the acquisition of all necessary rights to permit the following:\n\ -\n\ - 1. A series of actions may occur ("Provisioning Process") in which a user may execute\n\ - the Provisioning Technology on a machine ("Target Machine") with the intent of installing,\n\ - extending or updating the functionality of an Eclipse-based product.\n\ - 2. During the Provisioning Process, the Provisioning Technology may cause third party\n\ - Installable Software or a portion thereof to be accessed and copied to the Target Machine.\n\ - 3. Pursuant to the Specification, you will provide to the user the terms and conditions that\n\ - govern the use of the Installable Software ("Installable Software Agreement") and such\n\ - Installable Software Agreement shall be accessed from the Target Machine in accordance\n\ - with the Specification. Such Installable Software Agreement must inform the user of the\n\ - terms and conditions that govern the Installable Software and must solicit acceptance by\n\ - the end user in the manner prescribed in such Installable Software Agreement. Upon such\n\ - indication of agreement by the user, the provisioning Technology will complete installation\n\ - of the Installable Software.\n\ -\n\ -Cryptography\n\ -\n\ -Content may contain encryption software. The country in which you are\n\ -currently may have restrictions on the import, possession, and use,\n\ -and/or re-export to another country, of encryption software. BEFORE\n\ -using any encryption software, please check the country's laws,\n\ -regulations and policies concerning the import, possession, or use, and\n\ -re-export of encryption software, to see if this is permitted.\n\ -\n\ -Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.\n -########### end of license property ########################################## diff --git a/features/org.eclipse.emf.eef.edt-feature/feature.xml b/features/org.eclipse.emf.eef.edt-feature/feature.xml deleted file mode 100644 index 5f8581af1..000000000 --- a/features/org.eclipse.emf.eef.edt-feature/feature.xml +++ /dev/null @@ -1,150 +0,0 @@ - - - - - - %description - - - - Copyright (c) 2008 - 2010 Obeo. -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 - - - - %license - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/features/org.eclipse.emf.eef.edt-feature/license.html b/features/org.eclipse.emf.eef.edt-feature/license.html deleted file mode 100644 index a1fe5ea3f..000000000 --- a/features/org.eclipse.emf.eef.edt-feature/license.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - -Eclipse Foundation Software User Agreement - - - -

Eclipse Foundation Software User Agreement

-

February 1, 2011

- -

Usage Of Content

- -

THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS - (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND - CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE - OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR - NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND - CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.

- -

Applicable Licenses

- -

Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 - ("EPL"). A copy of the EPL is provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html. - For purposes of the EPL, "Program" will mean the Content.

- -

Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code - repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").

- -
    -
  • Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").
  • - -
  • Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".
  • -
  • A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins - and/or Fragments associated with that Feature.
  • -
  • Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.
  • - -
- -

The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and -Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module -including, but not limited to the following locations:

- -
    -
  • The top-level (root) directory
  • - -
  • Plug-in and Fragment directories
  • -
  • Inside Plug-ins and Fragments packaged as JARs
  • -
  • Sub-directories of the directory named "src" of certain Plug-ins
  • -
  • Feature directories
  • -
- -

Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the -installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or -inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. -Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in -that directory.

- -

THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE -OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):

- - - -

IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please -contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.

- - -

Use of Provisioning Technology

- -

The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse - Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or - other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to - install, extend and update Eclipse-based products. Information about packaging Installable Software is available at http://eclipse.org/equinox/p2/repository_packaging.html - - ("Specification").

- -

You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the - applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology - in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the - Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:

- -
    -
  1. A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology - on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based - product.
  2. - -
  3. During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be - accessed and copied to the Target Machine.
  4. -
  5. Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable - Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target - Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern - the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such - indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.
  6. -
- -

Cryptography

- -

Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to - another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, - possession, or use, and re-export of encryption software, to see if this is permitted.

- -

Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.

- - - diff --git a/features/org.eclipse.emf.eef.edt-feature/license.txt b/features/org.eclipse.emf.eef.edt-feature/license.txt deleted file mode 100644 index 24937b64c..000000000 --- a/features/org.eclipse.emf.eef.edt-feature/license.txt +++ /dev/null @@ -1,87 +0,0 @@ -Eclipse Public License - v 1.0 - -THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. - -1. DEFINITIONS - -"Contribution" means: - -a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and -b) in the case of each subsequent Contributor: - -i) changes to the Program, and - -ii) additions to the Program; - -where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program. - -"Contributor" means any person or entity that distributes the Program. - -"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. - -"Program" means the Contributions distributed in accordance with this Agreement. - -"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. - -2. GRANT OF RIGHTS - -a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form. - -b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. - -c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. - -d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. - -3. REQUIREMENTS - -A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: - -a) it complies with the terms and conditions of this Agreement; and - -b) its license agreement: - -i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; - -ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; - -iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and - -iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange. - -When the Program is made available in source code form: - -a) it must be made available under this Agreement; and - -b) a copy of this Agreement must be included with each copy of the Program. - -Contributors may not remove or alter any copyright notices contained within the Program. - -Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. - -4. COMMERCIAL DISTRIBUTION - -Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. - -For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. - -5. NO WARRANTY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. - -6. DISCLAIMER OF LIABILITY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - -7. GENERAL - -If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. - -If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. - -All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. - -Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. - -This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. - diff --git a/features/org.eclipse.emf.eef.edt-feature/pom.xml b/features/org.eclipse.emf.eef.edt-feature/pom.xml deleted file mode 100644 index 2ead023ef..000000000 --- a/features/org.eclipse.emf.eef.edt-feature/pom.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.edt-feature - eclipse-feature - - EEF Development Tools Feature - - diff --git a/features/org.eclipse.emf.eef.extended-feature/.gitignore b/features/org.eclipse.emf.eef.extended-feature/.gitignore deleted file mode 100644 index eb5a316cb..000000000 --- a/features/org.eclipse.emf.eef.extended-feature/.gitignore +++ /dev/null @@ -1 +0,0 @@ -target diff --git a/features/org.eclipse.emf.eef.extended-feature/.project b/features/org.eclipse.emf.eef.extended-feature/.project deleted file mode 100644 index 3198bd1b9..000000000 --- a/features/org.eclipse.emf.eef.extended-feature/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - org.eclipse.emf.eef.extended-feature - - - - - - org.eclipse.pde.FeatureBuilder - - - - - - org.eclipse.pde.FeatureNature - - diff --git a/features/org.eclipse.emf.eef.extended-feature/build.properties b/features/org.eclipse.emf.eef.extended-feature/build.properties deleted file mode 100644 index 2f5d242cc..000000000 --- a/features/org.eclipse.emf.eef.extended-feature/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2010 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = feature.xml,\ - feature.properties,\ - license.html,\ - license.txt,\ - epl-v10.html -src.includes = feature.properties,\ - license.html,\ - license.txt,\ - feature.xml,\ - epl-v10.html diff --git a/features/org.eclipse.emf.eef.extended-feature/epl-v10.html b/features/org.eclipse.emf.eef.extended-feature/epl-v10.html deleted file mode 100644 index 0d34dd06a..000000000 --- a/features/org.eclipse.emf.eef.extended-feature/epl-v10.html +++ /dev/null @@ -1,262 +0,0 @@ - - - - - - -Eclipse Public License - Version 1.0 - - - - - - -

Eclipse Public License - v 1.0

- -

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE -PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR -DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS -AGREEMENT.

- -

1. DEFINITIONS

- -

"Contribution" means:

- -

a) in the case of the initial Contributor, the initial -code and documentation distributed under this Agreement, and

-

b) in the case of each subsequent Contributor:

- -

i) changes to the Program, and

-

ii) additions to the Program;

-

where such changes and/or additions to the Program -originate from and are distributed by that particular Contributor. A -Contribution 'originates' from a Contributor if it was added to the -Program by such Contributor itself or anyone acting on such -Contributor's behalf. Contributions do not include additions to the -Program which: (i) are separate modules of software distributed in -conjunction with the Program under their own license agreement, and (ii) -are not derivative works of the Program.

- -

"Contributor" means any person or entity that distributes -the Program.

- -

"Licensed Patents" mean patent claims licensable by a -Contributor which are necessarily infringed by the use or sale of its -Contribution alone or when combined with the Program.

- -

"Program" means the Contributions distributed in accordance -with this Agreement.

- -

"Recipient" means anyone who receives the Program under -this Agreement, including all Contributors.

- -

2. GRANT OF RIGHTS

- -

a) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free copyright license to reproduce, prepare derivative works -of, publicly display, publicly perform, distribute and sublicense the -Contribution of such Contributor, if any, and such derivative works, in -source code and object code form.

- -

b) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free patent license under Licensed Patents to make, use, sell, -offer to sell, import and otherwise transfer the Contribution of such -Contributor, if any, in source code and object code form. This patent -license shall apply to the combination of the Contribution and the -Program if, at the time the Contribution is added by the Contributor, -such addition of the Contribution causes such combination to be covered -by the Licensed Patents. The patent license shall not apply to any other -combinations which include the Contribution. No hardware per se is -licensed hereunder.

- -

c) Recipient understands that although each Contributor -grants the licenses to its Contributions set forth herein, no assurances -are provided by any Contributor that the Program does not infringe the -patent or other intellectual property rights of any other entity. Each -Contributor disclaims any liability to Recipient for claims brought by -any other entity based on infringement of intellectual property rights -or otherwise. As a condition to exercising the rights and licenses -granted hereunder, each Recipient hereby assumes sole responsibility to -secure any other intellectual property rights needed, if any. For -example, if a third party patent license is required to allow Recipient -to distribute the Program, it is Recipient's responsibility to acquire -that license before distributing the Program.

- -

d) Each Contributor represents that to its knowledge it -has sufficient copyright rights in its Contribution, if any, to grant -the copyright license set forth in this Agreement.

- -

3. REQUIREMENTS

- -

A Contributor may choose to distribute the Program in object code -form under its own license agreement, provided that:

- -

a) it complies with the terms and conditions of this -Agreement; and

- -

b) its license agreement:

- -

i) effectively disclaims on behalf of all Contributors -all warranties and conditions, express and implied, including warranties -or conditions of title and non-infringement, and implied warranties or -conditions of merchantability and fitness for a particular purpose;

- -

ii) effectively excludes on behalf of all Contributors -all liability for damages, including direct, indirect, special, -incidental and consequential damages, such as lost profits;

- -

iii) states that any provisions which differ from this -Agreement are offered by that Contributor alone and not by any other -party; and

- -

iv) states that source code for the Program is available -from such Contributor, and informs licensees how to obtain it in a -reasonable manner on or through a medium customarily used for software -exchange.

- -

When the Program is made available in source code form:

- -

a) it must be made available under this Agreement; and

- -

b) a copy of this Agreement must be included with each -copy of the Program.

- -

Contributors may not remove or alter any copyright notices contained -within the Program.

- -

Each Contributor must identify itself as the originator of its -Contribution, if any, in a manner that reasonably allows subsequent -Recipients to identify the originator of the Contribution.

- -

4. COMMERCIAL DISTRIBUTION

- -

Commercial distributors of software may accept certain -responsibilities with respect to end users, business partners and the -like. While this license is intended to facilitate the commercial use of -the Program, the Contributor who includes the Program in a commercial -product offering should do so in a manner which does not create -potential liability for other Contributors. Therefore, if a Contributor -includes the Program in a commercial product offering, such Contributor -("Commercial Contributor") hereby agrees to defend and -indemnify every other Contributor ("Indemnified Contributor") -against any losses, damages and costs (collectively "Losses") -arising from claims, lawsuits and other legal actions brought by a third -party against the Indemnified Contributor to the extent caused by the -acts or omissions of such Commercial Contributor in connection with its -distribution of the Program in a commercial product offering. The -obligations in this section do not apply to any claims or Losses -relating to any actual or alleged intellectual property infringement. In -order to qualify, an Indemnified Contributor must: a) promptly notify -the Commercial Contributor in writing of such claim, and b) allow the -Commercial Contributor to control, and cooperate with the Commercial -Contributor in, the defense and any related settlement negotiations. The -Indemnified Contributor may participate in any such claim at its own -expense.

- -

For example, a Contributor might include the Program in a commercial -product offering, Product X. That Contributor is then a Commercial -Contributor. If that Commercial Contributor then makes performance -claims, or offers warranties related to Product X, those performance -claims and warranties are such Commercial Contributor's responsibility -alone. Under this section, the Commercial Contributor would have to -defend claims against the other Contributors related to those -performance claims and warranties, and if a court requires any other -Contributor to pay any damages as a result, the Commercial Contributor -must pay those damages.

- -

5. NO WARRANTY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS -PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS -OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, -ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY -OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely -responsible for determining the appropriateness of using and -distributing the Program and assumes all risks associated with its -exercise of rights under this Agreement , including but not limited to -the risks and costs of program errors, compliance with applicable laws, -damage to or loss of data, programs or equipment, and unavailability or -interruption of operations.

- -

6. DISCLAIMER OF LIABILITY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT -NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING -WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR -DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED -HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

- -

7. GENERAL

- -

If any provision of this Agreement is invalid or unenforceable under -applicable law, it shall not affect the validity or enforceability of -the remainder of the terms of this Agreement, and without further action -by the parties hereto, such provision shall be reformed to the minimum -extent necessary to make such provision valid and enforceable.

- -

If Recipient institutes patent litigation against any entity -(including a cross-claim or counterclaim in a lawsuit) alleging that the -Program itself (excluding combinations of the Program with other -software or hardware) infringes such Recipient's patent(s), then such -Recipient's rights granted under Section 2(b) shall terminate as of the -date such litigation is filed.

- -

All Recipient's rights under this Agreement shall terminate if it -fails to comply with any of the material terms or conditions of this -Agreement and does not cure such failure in a reasonable period of time -after becoming aware of such noncompliance. If all Recipient's rights -under this Agreement terminate, Recipient agrees to cease use and -distribution of the Program as soon as reasonably practicable. However, -Recipient's obligations under this Agreement and any licenses granted by -Recipient relating to the Program shall continue and survive.

- -

Everyone is permitted to copy and distribute copies of this -Agreement, but in order to avoid inconsistency the Agreement is -copyrighted and may only be modified in the following manner. The -Agreement Steward reserves the right to publish new versions (including -revisions) of this Agreement from time to time. No one other than the -Agreement Steward has the right to modify this Agreement. The Eclipse -Foundation is the initial Agreement Steward. The Eclipse Foundation may -assign the responsibility to serve as the Agreement Steward to a -suitable separate entity. Each new version of the Agreement will be -given a distinguishing version number. The Program (including -Contributions) may always be distributed subject to the version of the -Agreement under which it was received. In addition, after a new version -of the Agreement is published, Contributor may elect to distribute the -Program (including its Contributions) under the new version. Except as -expressly stated in Sections 2(a) and 2(b) above, Recipient receives no -rights or licenses to the intellectual property of any Contributor under -this Agreement, whether expressly, by implication, estoppel or -otherwise. All rights in the Program not expressly granted under this -Agreement are reserved.

- -

This Agreement is governed by the laws of the State of New York and -the intellectual property laws of the United States of America. No party -to this Agreement will bring a legal action under this Agreement more -than one year after the cause of action arose. Each party waives its -rights to a jury trial in any resulting litigation.

- - - - \ No newline at end of file diff --git a/features/org.eclipse.emf.eef.extended-feature/feature.properties b/features/org.eclipse.emf.eef.extended-feature/feature.properties deleted file mode 100644 index 2f943a150..000000000 --- a/features/org.eclipse.emf.eef.extended-feature/feature.properties +++ /dev/null @@ -1,147 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -providerName=Eclipse Modeling Project -featureName=Extended Editing Framework - Extension -modelingUpdateSiteName=Eclipse Modeling Project Updates -description=Extended Editing Framework - Extension.\n\ -this includes the Editor Generator. - -# "licenseURL" property - URL of the "Feature License" -# do not translate value - just change to point to a locale-specific HTML page -licenseURL=license.html - -# "license" property - text of the "Feature Update License" -# should be plain text version of license agreement pointed to be "licenseURL" -license=\ -Eclipse Foundation Software User Agreement\n\ -February 1, 2011\n\ -\n\ -Usage Of Content\n\ -\n\ -THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\ -OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\ -USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\ -AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\ -NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\ -AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\ -AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\ -OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\ -TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\ -OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\ -BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\ -\n\ -Applicable Licenses\n\ -\n\ -Unless otherwise indicated, all Content made available by the\n\ -Eclipse Foundation is provided to you under the terms and conditions of\n\ -the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is\n\ -provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\ -For purposes of the EPL, "Program" will mean the Content.\n\ -\n\ -Content includes, but is not limited to, source code, object code,\n\ -documentation and other files maintained in the Eclipse Foundation source code\n\ -repository ("Repository") in software modules ("Modules") and made available\n\ -as downloadable archives ("Downloads").\n\ -\n\ - - Content may be structured and packaged into modules to facilitate delivering,\n\ - extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\ - plug-in fragments ("Fragments"), and features ("Features").\n\ - - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive)\n\ - in a directory named "plugins".\n\ - - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\ - Each Feature may be packaged as a sub-directory in a directory named "features".\n\ - Within a Feature, files named "feature.xml" may contain a list of the names and version\n\ - numbers of the Plug-ins and/or Fragments associated with that Feature.\n\ - - Features may also include other Features ("Included Features"). Within a Feature, files\n\ - named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\ -\n\ -The terms and conditions governing Plug-ins and Fragments should be\n\ -contained in files named "about.html" ("Abouts"). The terms and\n\ -conditions governing Features and Included Features should be contained\n\ -in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\ -Licenses may be located in any directory of a Download or Module\n\ -including, but not limited to the following locations:\n\ -\n\ - - The top-level (root) directory\n\ - - Plug-in and Fragment directories\n\ - - Inside Plug-ins and Fragments packaged as JARs\n\ - - Sub-directories of the directory named "src" of certain Plug-ins\n\ - - Feature directories\n\ -\n\ -Note: if a Feature made available by the Eclipse Foundation is installed using the\n\ -Provisioning Technology (as defined below), you must agree to a license ("Feature \n\ -Update License") during the installation process. If the Feature contains\n\ -Included Features, the Feature Update License should either provide you\n\ -with the terms and conditions governing the Included Features or inform\n\ -you where you can locate them. Feature Update Licenses may be found in\n\ -the "license" property of files named "feature.properties" found within a Feature.\n\ -Such Abouts, Feature Licenses, and Feature Update Licenses contain the\n\ -terms and conditions (or references to such terms and conditions) that\n\ -govern your use of the associated Content in that directory.\n\ -\n\ -THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER\n\ -TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\ -SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\ -\n\ - - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html)\n\ - - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\ - - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\ - - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\ - - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\ - - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\ -\n\ -IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\ -TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License\n\ -is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\ -govern that particular Content.\n\ -\n\ -\n\Use of Provisioning Technology\n\ -\n\ -The Eclipse Foundation makes available provisioning software, examples of which include,\n\ -but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for\n\ -the purpose of allowing users to install software, documentation, information and/or\n\ -other materials (collectively "Installable Software"). This capability is provided with\n\ -the intent of allowing such users to install, extend and update Eclipse-based products.\n\ -Information about packaging Installable Software is available at\n\ -http://eclipse.org/equinox/p2/repository_packaging.html ("Specification").\n\ -\n\ -You may use Provisioning Technology to allow other parties to install Installable Software.\n\ -You shall be responsible for enabling the applicable license agreements relating to the\n\ -Installable Software to be presented to, and accepted by, the users of the Provisioning Technology\n\ -in accordance with the Specification. By using Provisioning Technology in such a manner and\n\ -making it available in accordance with the Specification, you further acknowledge your\n\ -agreement to, and the acquisition of all necessary rights to permit the following:\n\ -\n\ - 1. A series of actions may occur ("Provisioning Process") in which a user may execute\n\ - the Provisioning Technology on a machine ("Target Machine") with the intent of installing,\n\ - extending or updating the functionality of an Eclipse-based product.\n\ - 2. During the Provisioning Process, the Provisioning Technology may cause third party\n\ - Installable Software or a portion thereof to be accessed and copied to the Target Machine.\n\ - 3. Pursuant to the Specification, you will provide to the user the terms and conditions that\n\ - govern the use of the Installable Software ("Installable Software Agreement") and such\n\ - Installable Software Agreement shall be accessed from the Target Machine in accordance\n\ - with the Specification. Such Installable Software Agreement must inform the user of the\n\ - terms and conditions that govern the Installable Software and must solicit acceptance by\n\ - the end user in the manner prescribed in such Installable Software Agreement. Upon such\n\ - indication of agreement by the user, the provisioning Technology will complete installation\n\ - of the Installable Software.\n\ -\n\ -Cryptography\n\ -\n\ -Content may contain encryption software. The country in which you are\n\ -currently may have restrictions on the import, possession, and use,\n\ -and/or re-export to another country, of encryption software. BEFORE\n\ -using any encryption software, please check the country's laws,\n\ -regulations and policies concerning the import, possession, or use, and\n\ -re-export of encryption software, to see if this is permitted.\n\ -\n\ -Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.\n -########### end of license property ########################################## diff --git a/features/org.eclipse.emf.eef.extended-feature/feature.xml b/features/org.eclipse.emf.eef.extended-feature/feature.xml deleted file mode 100644 index 89a80fd42..000000000 --- a/features/org.eclipse.emf.eef.extended-feature/feature.xml +++ /dev/null @@ -1,69 +0,0 @@ - - - - - - %description - - - - Copyright (c) 2008 - 2010 Obeo. -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 - - - - %license - - - - - - - - - - - - - - - - diff --git a/features/org.eclipse.emf.eef.extended-feature/license.html b/features/org.eclipse.emf.eef.extended-feature/license.html deleted file mode 100644 index a1fe5ea3f..000000000 --- a/features/org.eclipse.emf.eef.extended-feature/license.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - -Eclipse Foundation Software User Agreement - - - -

Eclipse Foundation Software User Agreement

-

February 1, 2011

- -

Usage Of Content

- -

THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS - (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND - CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE - OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR - NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND - CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.

- -

Applicable Licenses

- -

Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 - ("EPL"). A copy of the EPL is provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html. - For purposes of the EPL, "Program" will mean the Content.

- -

Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code - repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").

- -
    -
  • Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").
  • - -
  • Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".
  • -
  • A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins - and/or Fragments associated with that Feature.
  • -
  • Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.
  • - -
- -

The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and -Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module -including, but not limited to the following locations:

- -
    -
  • The top-level (root) directory
  • - -
  • Plug-in and Fragment directories
  • -
  • Inside Plug-ins and Fragments packaged as JARs
  • -
  • Sub-directories of the directory named "src" of certain Plug-ins
  • -
  • Feature directories
  • -
- -

Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the -installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or -inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. -Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in -that directory.

- -

THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE -OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):

- - - -

IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please -contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.

- - -

Use of Provisioning Technology

- -

The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse - Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or - other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to - install, extend and update Eclipse-based products. Information about packaging Installable Software is available at http://eclipse.org/equinox/p2/repository_packaging.html - - ("Specification").

- -

You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the - applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology - in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the - Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:

- -
    -
  1. A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology - on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based - product.
  2. - -
  3. During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be - accessed and copied to the Target Machine.
  4. -
  5. Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable - Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target - Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern - the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such - indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.
  6. -
- -

Cryptography

- -

Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to - another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, - possession, or use, and re-export of encryption software, to see if this is permitted.

- -

Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.

- - - diff --git a/features/org.eclipse.emf.eef.extended-feature/license.txt b/features/org.eclipse.emf.eef.extended-feature/license.txt deleted file mode 100644 index 24937b64c..000000000 --- a/features/org.eclipse.emf.eef.extended-feature/license.txt +++ /dev/null @@ -1,87 +0,0 @@ -Eclipse Public License - v 1.0 - -THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. - -1. DEFINITIONS - -"Contribution" means: - -a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and -b) in the case of each subsequent Contributor: - -i) changes to the Program, and - -ii) additions to the Program; - -where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program. - -"Contributor" means any person or entity that distributes the Program. - -"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. - -"Program" means the Contributions distributed in accordance with this Agreement. - -"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. - -2. GRANT OF RIGHTS - -a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form. - -b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. - -c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. - -d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. - -3. REQUIREMENTS - -A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: - -a) it complies with the terms and conditions of this Agreement; and - -b) its license agreement: - -i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; - -ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; - -iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and - -iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange. - -When the Program is made available in source code form: - -a) it must be made available under this Agreement; and - -b) a copy of this Agreement must be included with each copy of the Program. - -Contributors may not remove or alter any copyright notices contained within the Program. - -Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. - -4. COMMERCIAL DISTRIBUTION - -Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. - -For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. - -5. NO WARRANTY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. - -6. DISCLAIMER OF LIABILITY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - -7. GENERAL - -If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. - -If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. - -All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. - -Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. - -This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. - diff --git a/features/org.eclipse.emf.eef.extended-feature/pom.xml b/features/org.eclipse.emf.eef.extended-feature/pom.xml deleted file mode 100644 index 0cf4770cf..000000000 --- a/features/org.eclipse.emf.eef.extended-feature/pom.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.extended-feature - eclipse-feature - - EEF Extensions Feature - - diff --git a/features/org.eclipse.emf.eef.richtext-feature/.gitignore b/features/org.eclipse.emf.eef.richtext-feature/.gitignore deleted file mode 100644 index eb5a316cb..000000000 --- a/features/org.eclipse.emf.eef.richtext-feature/.gitignore +++ /dev/null @@ -1 +0,0 @@ -target diff --git a/features/org.eclipse.emf.eef.richtext-feature/.project b/features/org.eclipse.emf.eef.richtext-feature/.project deleted file mode 100644 index 4bd942324..000000000 --- a/features/org.eclipse.emf.eef.richtext-feature/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - org.eclipse.emf.eef.richtext-feature - - - - - - org.eclipse.pde.FeatureBuilder - - - - - - org.eclipse.pde.FeatureNature - - diff --git a/features/org.eclipse.emf.eef.richtext-feature/build.properties b/features/org.eclipse.emf.eef.richtext-feature/build.properties deleted file mode 100644 index 7aa629d6d..000000000 --- a/features/org.eclipse.emf.eef.richtext-feature/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = feature.xml,\ - feature.properties,\ - license.html,\ - license.txt,\ - epl-v10.html -src.includes = feature.properties,\ - license.html,\ - license.txt,\ - feature.xml,\ - epl-v10.html diff --git a/features/org.eclipse.emf.eef.richtext-feature/epl-v10.html b/features/org.eclipse.emf.eef.richtext-feature/epl-v10.html deleted file mode 100644 index 0d34dd06a..000000000 --- a/features/org.eclipse.emf.eef.richtext-feature/epl-v10.html +++ /dev/null @@ -1,262 +0,0 @@ - - - - - - -Eclipse Public License - Version 1.0 - - - - - - -

Eclipse Public License - v 1.0

- -

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE -PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR -DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS -AGREEMENT.

- -

1. DEFINITIONS

- -

"Contribution" means:

- -

a) in the case of the initial Contributor, the initial -code and documentation distributed under this Agreement, and

-

b) in the case of each subsequent Contributor:

- -

i) changes to the Program, and

-

ii) additions to the Program;

-

where such changes and/or additions to the Program -originate from and are distributed by that particular Contributor. A -Contribution 'originates' from a Contributor if it was added to the -Program by such Contributor itself or anyone acting on such -Contributor's behalf. Contributions do not include additions to the -Program which: (i) are separate modules of software distributed in -conjunction with the Program under their own license agreement, and (ii) -are not derivative works of the Program.

- -

"Contributor" means any person or entity that distributes -the Program.

- -

"Licensed Patents" mean patent claims licensable by a -Contributor which are necessarily infringed by the use or sale of its -Contribution alone or when combined with the Program.

- -

"Program" means the Contributions distributed in accordance -with this Agreement.

- -

"Recipient" means anyone who receives the Program under -this Agreement, including all Contributors.

- -

2. GRANT OF RIGHTS

- -

a) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free copyright license to reproduce, prepare derivative works -of, publicly display, publicly perform, distribute and sublicense the -Contribution of such Contributor, if any, and such derivative works, in -source code and object code form.

- -

b) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free patent license under Licensed Patents to make, use, sell, -offer to sell, import and otherwise transfer the Contribution of such -Contributor, if any, in source code and object code form. This patent -license shall apply to the combination of the Contribution and the -Program if, at the time the Contribution is added by the Contributor, -such addition of the Contribution causes such combination to be covered -by the Licensed Patents. The patent license shall not apply to any other -combinations which include the Contribution. No hardware per se is -licensed hereunder.

- -

c) Recipient understands that although each Contributor -grants the licenses to its Contributions set forth herein, no assurances -are provided by any Contributor that the Program does not infringe the -patent or other intellectual property rights of any other entity. Each -Contributor disclaims any liability to Recipient for claims brought by -any other entity based on infringement of intellectual property rights -or otherwise. As a condition to exercising the rights and licenses -granted hereunder, each Recipient hereby assumes sole responsibility to -secure any other intellectual property rights needed, if any. For -example, if a third party patent license is required to allow Recipient -to distribute the Program, it is Recipient's responsibility to acquire -that license before distributing the Program.

- -

d) Each Contributor represents that to its knowledge it -has sufficient copyright rights in its Contribution, if any, to grant -the copyright license set forth in this Agreement.

- -

3. REQUIREMENTS

- -

A Contributor may choose to distribute the Program in object code -form under its own license agreement, provided that:

- -

a) it complies with the terms and conditions of this -Agreement; and

- -

b) its license agreement:

- -

i) effectively disclaims on behalf of all Contributors -all warranties and conditions, express and implied, including warranties -or conditions of title and non-infringement, and implied warranties or -conditions of merchantability and fitness for a particular purpose;

- -

ii) effectively excludes on behalf of all Contributors -all liability for damages, including direct, indirect, special, -incidental and consequential damages, such as lost profits;

- -

iii) states that any provisions which differ from this -Agreement are offered by that Contributor alone and not by any other -party; and

- -

iv) states that source code for the Program is available -from such Contributor, and informs licensees how to obtain it in a -reasonable manner on or through a medium customarily used for software -exchange.

- -

When the Program is made available in source code form:

- -

a) it must be made available under this Agreement; and

- -

b) a copy of this Agreement must be included with each -copy of the Program.

- -

Contributors may not remove or alter any copyright notices contained -within the Program.

- -

Each Contributor must identify itself as the originator of its -Contribution, if any, in a manner that reasonably allows subsequent -Recipients to identify the originator of the Contribution.

- -

4. COMMERCIAL DISTRIBUTION

- -

Commercial distributors of software may accept certain -responsibilities with respect to end users, business partners and the -like. While this license is intended to facilitate the commercial use of -the Program, the Contributor who includes the Program in a commercial -product offering should do so in a manner which does not create -potential liability for other Contributors. Therefore, if a Contributor -includes the Program in a commercial product offering, such Contributor -("Commercial Contributor") hereby agrees to defend and -indemnify every other Contributor ("Indemnified Contributor") -against any losses, damages and costs (collectively "Losses") -arising from claims, lawsuits and other legal actions brought by a third -party against the Indemnified Contributor to the extent caused by the -acts or omissions of such Commercial Contributor in connection with its -distribution of the Program in a commercial product offering. The -obligations in this section do not apply to any claims or Losses -relating to any actual or alleged intellectual property infringement. In -order to qualify, an Indemnified Contributor must: a) promptly notify -the Commercial Contributor in writing of such claim, and b) allow the -Commercial Contributor to control, and cooperate with the Commercial -Contributor in, the defense and any related settlement negotiations. The -Indemnified Contributor may participate in any such claim at its own -expense.

- -

For example, a Contributor might include the Program in a commercial -product offering, Product X. That Contributor is then a Commercial -Contributor. If that Commercial Contributor then makes performance -claims, or offers warranties related to Product X, those performance -claims and warranties are such Commercial Contributor's responsibility -alone. Under this section, the Commercial Contributor would have to -defend claims against the other Contributors related to those -performance claims and warranties, and if a court requires any other -Contributor to pay any damages as a result, the Commercial Contributor -must pay those damages.

- -

5. NO WARRANTY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS -PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS -OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, -ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY -OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely -responsible for determining the appropriateness of using and -distributing the Program and assumes all risks associated with its -exercise of rights under this Agreement , including but not limited to -the risks and costs of program errors, compliance with applicable laws, -damage to or loss of data, programs or equipment, and unavailability or -interruption of operations.

- -

6. DISCLAIMER OF LIABILITY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT -NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING -WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR -DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED -HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

- -

7. GENERAL

- -

If any provision of this Agreement is invalid or unenforceable under -applicable law, it shall not affect the validity or enforceability of -the remainder of the terms of this Agreement, and without further action -by the parties hereto, such provision shall be reformed to the minimum -extent necessary to make such provision valid and enforceable.

- -

If Recipient institutes patent litigation against any entity -(including a cross-claim or counterclaim in a lawsuit) alleging that the -Program itself (excluding combinations of the Program with other -software or hardware) infringes such Recipient's patent(s), then such -Recipient's rights granted under Section 2(b) shall terminate as of the -date such litigation is filed.

- -

All Recipient's rights under this Agreement shall terminate if it -fails to comply with any of the material terms or conditions of this -Agreement and does not cure such failure in a reasonable period of time -after becoming aware of such noncompliance. If all Recipient's rights -under this Agreement terminate, Recipient agrees to cease use and -distribution of the Program as soon as reasonably practicable. However, -Recipient's obligations under this Agreement and any licenses granted by -Recipient relating to the Program shall continue and survive.

- -

Everyone is permitted to copy and distribute copies of this -Agreement, but in order to avoid inconsistency the Agreement is -copyrighted and may only be modified in the following manner. The -Agreement Steward reserves the right to publish new versions (including -revisions) of this Agreement from time to time. No one other than the -Agreement Steward has the right to modify this Agreement. The Eclipse -Foundation is the initial Agreement Steward. The Eclipse Foundation may -assign the responsibility to serve as the Agreement Steward to a -suitable separate entity. Each new version of the Agreement will be -given a distinguishing version number. The Program (including -Contributions) may always be distributed subject to the version of the -Agreement under which it was received. In addition, after a new version -of the Agreement is published, Contributor may elect to distribute the -Program (including its Contributions) under the new version. Except as -expressly stated in Sections 2(a) and 2(b) above, Recipient receives no -rights or licenses to the intellectual property of any Contributor under -this Agreement, whether expressly, by implication, estoppel or -otherwise. All rights in the Program not expressly granted under this -Agreement are reserved.

- -

This Agreement is governed by the laws of the State of New York and -the intellectual property laws of the United States of America. No party -to this Agreement will bring a legal action under this Agreement more -than one year after the cause of action arose. Each party waives its -rights to a jury trial in any resulting litigation.

- - - - \ No newline at end of file diff --git a/features/org.eclipse.emf.eef.richtext-feature/feature.properties b/features/org.eclipse.emf.eef.richtext-feature/feature.properties deleted file mode 100644 index dea52bede..000000000 --- a/features/org.eclipse.emf.eef.richtext-feature/feature.properties +++ /dev/null @@ -1,147 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -providerName=Eclipse Modeling Project -featureName=Extended Editing Framework - Richtext widget -modelingUpdateSiteName=Eclipse Modeling Project Updates -description=Extended Editing Framework - \n\ -this includes EPF richtext widget. - -# "licenseURL" property - URL of the "Feature License" -# do not translate value - just change to point to a locale-specific HTML page -licenseURL=license.html - -# "license" property - text of the "Feature Update License" -# should be plain text version of license agreement pointed to be "licenseURL" -license=\ -Eclipse Foundation Software User Agreement\n\ -February 1, 2011\n\ -\n\ -Usage Of Content\n\ -\n\ -THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\ -OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\ -USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\ -AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\ -NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\ -AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\ -AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\ -OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\ -TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\ -OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\ -BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\ -\n\ -Applicable Licenses\n\ -\n\ -Unless otherwise indicated, all Content made available by the\n\ -Eclipse Foundation is provided to you under the terms and conditions of\n\ -the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is\n\ -provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\ -For purposes of the EPL, "Program" will mean the Content.\n\ -\n\ -Content includes, but is not limited to, source code, object code,\n\ -documentation and other files maintained in the Eclipse Foundation source code\n\ -repository ("Repository") in software modules ("Modules") and made available\n\ -as downloadable archives ("Downloads").\n\ -\n\ - - Content may be structured and packaged into modules to facilitate delivering,\n\ - extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\ - plug-in fragments ("Fragments"), and features ("Features").\n\ - - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive)\n\ - in a directory named "plugins".\n\ - - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\ - Each Feature may be packaged as a sub-directory in a directory named "features".\n\ - Within a Feature, files named "feature.xml" may contain a list of the names and version\n\ - numbers of the Plug-ins and/or Fragments associated with that Feature.\n\ - - Features may also include other Features ("Included Features"). Within a Feature, files\n\ - named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\ -\n\ -The terms and conditions governing Plug-ins and Fragments should be\n\ -contained in files named "about.html" ("Abouts"). The terms and\n\ -conditions governing Features and Included Features should be contained\n\ -in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\ -Licenses may be located in any directory of a Download or Module\n\ -including, but not limited to the following locations:\n\ -\n\ - - The top-level (root) directory\n\ - - Plug-in and Fragment directories\n\ - - Inside Plug-ins and Fragments packaged as JARs\n\ - - Sub-directories of the directory named "src" of certain Plug-ins\n\ - - Feature directories\n\ -\n\ -Note: if a Feature made available by the Eclipse Foundation is installed using the\n\ -Provisioning Technology (as defined below), you must agree to a license ("Feature \n\ -Update License") during the installation process. If the Feature contains\n\ -Included Features, the Feature Update License should either provide you\n\ -with the terms and conditions governing the Included Features or inform\n\ -you where you can locate them. Feature Update Licenses may be found in\n\ -the "license" property of files named "feature.properties" found within a Feature.\n\ -Such Abouts, Feature Licenses, and Feature Update Licenses contain the\n\ -terms and conditions (or references to such terms and conditions) that\n\ -govern your use of the associated Content in that directory.\n\ -\n\ -THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER\n\ -TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\ -SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\ -\n\ - - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html)\n\ - - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\ - - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\ - - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\ - - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\ - - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\ -\n\ -IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\ -TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License\n\ -is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\ -govern that particular Content.\n\ -\n\ -\n\Use of Provisioning Technology\n\ -\n\ -The Eclipse Foundation makes available provisioning software, examples of which include,\n\ -but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for\n\ -the purpose of allowing users to install software, documentation, information and/or\n\ -other materials (collectively "Installable Software"). This capability is provided with\n\ -the intent of allowing such users to install, extend and update Eclipse-based products.\n\ -Information about packaging Installable Software is available at\n\ -http://eclipse.org/equinox/p2/repository_packaging.html ("Specification").\n\ -\n\ -You may use Provisioning Technology to allow other parties to install Installable Software.\n\ -You shall be responsible for enabling the applicable license agreements relating to the\n\ -Installable Software to be presented to, and accepted by, the users of the Provisioning Technology\n\ -in accordance with the Specification. By using Provisioning Technology in such a manner and\n\ -making it available in accordance with the Specification, you further acknowledge your\n\ -agreement to, and the acquisition of all necessary rights to permit the following:\n\ -\n\ - 1. A series of actions may occur ("Provisioning Process") in which a user may execute\n\ - the Provisioning Technology on a machine ("Target Machine") with the intent of installing,\n\ - extending or updating the functionality of an Eclipse-based product.\n\ - 2. During the Provisioning Process, the Provisioning Technology may cause third party\n\ - Installable Software or a portion thereof to be accessed and copied to the Target Machine.\n\ - 3. Pursuant to the Specification, you will provide to the user the terms and conditions that\n\ - govern the use of the Installable Software ("Installable Software Agreement") and such\n\ - Installable Software Agreement shall be accessed from the Target Machine in accordance\n\ - with the Specification. Such Installable Software Agreement must inform the user of the\n\ - terms and conditions that govern the Installable Software and must solicit acceptance by\n\ - the end user in the manner prescribed in such Installable Software Agreement. Upon such\n\ - indication of agreement by the user, the provisioning Technology will complete installation\n\ - of the Installable Software.\n\ -\n\ -Cryptography\n\ -\n\ -Content may contain encryption software. The country in which you are\n\ -currently may have restrictions on the import, possession, and use,\n\ -and/or re-export to another country, of encryption software. BEFORE\n\ -using any encryption software, please check the country's laws,\n\ -regulations and policies concerning the import, possession, or use, and\n\ -re-export of encryption software, to see if this is permitted.\n\ -\n\ -Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.\n -########### end of license property ########################################## diff --git a/features/org.eclipse.emf.eef.richtext-feature/feature.xml b/features/org.eclipse.emf.eef.richtext-feature/feature.xml deleted file mode 100644 index 1e7f28609..000000000 --- a/features/org.eclipse.emf.eef.richtext-feature/feature.xml +++ /dev/null @@ -1,41 +0,0 @@ - - - - - - %description - - - - Copyright (c) 2011 Obeo. -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 - - - - %license - - - - - diff --git a/features/org.eclipse.emf.eef.richtext-feature/license.html b/features/org.eclipse.emf.eef.richtext-feature/license.html deleted file mode 100644 index a1fe5ea3f..000000000 --- a/features/org.eclipse.emf.eef.richtext-feature/license.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - -Eclipse Foundation Software User Agreement - - - -

Eclipse Foundation Software User Agreement

-

February 1, 2011

- -

Usage Of Content

- -

THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS - (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND - CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE - OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR - NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND - CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.

- -

Applicable Licenses

- -

Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 - ("EPL"). A copy of the EPL is provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html. - For purposes of the EPL, "Program" will mean the Content.

- -

Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code - repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").

- -
    -
  • Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").
  • - -
  • Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".
  • -
  • A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins - and/or Fragments associated with that Feature.
  • -
  • Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.
  • - -
- -

The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and -Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module -including, but not limited to the following locations:

- -
    -
  • The top-level (root) directory
  • - -
  • Plug-in and Fragment directories
  • -
  • Inside Plug-ins and Fragments packaged as JARs
  • -
  • Sub-directories of the directory named "src" of certain Plug-ins
  • -
  • Feature directories
  • -
- -

Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the -installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or -inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. -Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in -that directory.

- -

THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE -OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):

- - - -

IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please -contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.

- - -

Use of Provisioning Technology

- -

The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse - Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or - other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to - install, extend and update Eclipse-based products. Information about packaging Installable Software is available at http://eclipse.org/equinox/p2/repository_packaging.html - - ("Specification").

- -

You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the - applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology - in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the - Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:

- -
    -
  1. A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology - on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based - product.
  2. - -
  3. During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be - accessed and copied to the Target Machine.
  4. -
  5. Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable - Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target - Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern - the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such - indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.
  6. -
- -

Cryptography

- -

Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to - another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, - possession, or use, and re-export of encryption software, to see if this is permitted.

- -

Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.

- - - diff --git a/features/org.eclipse.emf.eef.richtext-feature/license.txt b/features/org.eclipse.emf.eef.richtext-feature/license.txt deleted file mode 100644 index 24937b64c..000000000 --- a/features/org.eclipse.emf.eef.richtext-feature/license.txt +++ /dev/null @@ -1,87 +0,0 @@ -Eclipse Public License - v 1.0 - -THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. - -1. DEFINITIONS - -"Contribution" means: - -a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and -b) in the case of each subsequent Contributor: - -i) changes to the Program, and - -ii) additions to the Program; - -where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program. - -"Contributor" means any person or entity that distributes the Program. - -"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. - -"Program" means the Contributions distributed in accordance with this Agreement. - -"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. - -2. GRANT OF RIGHTS - -a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form. - -b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. - -c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. - -d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. - -3. REQUIREMENTS - -A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: - -a) it complies with the terms and conditions of this Agreement; and - -b) its license agreement: - -i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; - -ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; - -iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and - -iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange. - -When the Program is made available in source code form: - -a) it must be made available under this Agreement; and - -b) a copy of this Agreement must be included with each copy of the Program. - -Contributors may not remove or alter any copyright notices contained within the Program. - -Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. - -4. COMMERCIAL DISTRIBUTION - -Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. - -For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. - -5. NO WARRANTY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. - -6. DISCLAIMER OF LIABILITY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - -7. GENERAL - -If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. - -If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. - -All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. - -Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. - -This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. - diff --git a/features/org.eclipse.emf.eef.richtext-feature/pom.xml b/features/org.eclipse.emf.eef.richtext-feature/pom.xml deleted file mode 100644 index b76161e49..000000000 --- a/features/org.eclipse.emf.eef.richtext-feature/pom.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.richtext-feature - eclipse-feature - - EEF RichText Feature - - diff --git a/features/org.eclipse.emf.eef.runtime-feature/.gitignore b/features/org.eclipse.emf.eef.runtime-feature/.gitignore deleted file mode 100644 index eb5a316cb..000000000 --- a/features/org.eclipse.emf.eef.runtime-feature/.gitignore +++ /dev/null @@ -1 +0,0 @@ -target diff --git a/features/org.eclipse.emf.eef.runtime-feature/.project b/features/org.eclipse.emf.eef.runtime-feature/.project deleted file mode 100644 index ce6b60583..000000000 --- a/features/org.eclipse.emf.eef.runtime-feature/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - org.eclipse.emf.eef.runtime-feature - - - - - - org.eclipse.pde.FeatureBuilder - - - - - - org.eclipse.pde.FeatureNature - - diff --git a/features/org.eclipse.emf.eef.runtime-feature/build.properties b/features/org.eclipse.emf.eef.runtime-feature/build.properties deleted file mode 100644 index 2f5d242cc..000000000 --- a/features/org.eclipse.emf.eef.runtime-feature/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2010 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = feature.xml,\ - feature.properties,\ - license.html,\ - license.txt,\ - epl-v10.html -src.includes = feature.properties,\ - license.html,\ - license.txt,\ - feature.xml,\ - epl-v10.html diff --git a/features/org.eclipse.emf.eef.runtime-feature/epl-v10.html b/features/org.eclipse.emf.eef.runtime-feature/epl-v10.html deleted file mode 100644 index 0d34dd06a..000000000 --- a/features/org.eclipse.emf.eef.runtime-feature/epl-v10.html +++ /dev/null @@ -1,262 +0,0 @@ - - - - - - -Eclipse Public License - Version 1.0 - - - - - - -

Eclipse Public License - v 1.0

- -

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE -PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR -DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS -AGREEMENT.

- -

1. DEFINITIONS

- -

"Contribution" means:

- -

a) in the case of the initial Contributor, the initial -code and documentation distributed under this Agreement, and

-

b) in the case of each subsequent Contributor:

- -

i) changes to the Program, and

-

ii) additions to the Program;

-

where such changes and/or additions to the Program -originate from and are distributed by that particular Contributor. A -Contribution 'originates' from a Contributor if it was added to the -Program by such Contributor itself or anyone acting on such -Contributor's behalf. Contributions do not include additions to the -Program which: (i) are separate modules of software distributed in -conjunction with the Program under their own license agreement, and (ii) -are not derivative works of the Program.

- -

"Contributor" means any person or entity that distributes -the Program.

- -

"Licensed Patents" mean patent claims licensable by a -Contributor which are necessarily infringed by the use or sale of its -Contribution alone or when combined with the Program.

- -

"Program" means the Contributions distributed in accordance -with this Agreement.

- -

"Recipient" means anyone who receives the Program under -this Agreement, including all Contributors.

- -

2. GRANT OF RIGHTS

- -

a) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free copyright license to reproduce, prepare derivative works -of, publicly display, publicly perform, distribute and sublicense the -Contribution of such Contributor, if any, and such derivative works, in -source code and object code form.

- -

b) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free patent license under Licensed Patents to make, use, sell, -offer to sell, import and otherwise transfer the Contribution of such -Contributor, if any, in source code and object code form. This patent -license shall apply to the combination of the Contribution and the -Program if, at the time the Contribution is added by the Contributor, -such addition of the Contribution causes such combination to be covered -by the Licensed Patents. The patent license shall not apply to any other -combinations which include the Contribution. No hardware per se is -licensed hereunder.

- -

c) Recipient understands that although each Contributor -grants the licenses to its Contributions set forth herein, no assurances -are provided by any Contributor that the Program does not infringe the -patent or other intellectual property rights of any other entity. Each -Contributor disclaims any liability to Recipient for claims brought by -any other entity based on infringement of intellectual property rights -or otherwise. As a condition to exercising the rights and licenses -granted hereunder, each Recipient hereby assumes sole responsibility to -secure any other intellectual property rights needed, if any. For -example, if a third party patent license is required to allow Recipient -to distribute the Program, it is Recipient's responsibility to acquire -that license before distributing the Program.

- -

d) Each Contributor represents that to its knowledge it -has sufficient copyright rights in its Contribution, if any, to grant -the copyright license set forth in this Agreement.

- -

3. REQUIREMENTS

- -

A Contributor may choose to distribute the Program in object code -form under its own license agreement, provided that:

- -

a) it complies with the terms and conditions of this -Agreement; and

- -

b) its license agreement:

- -

i) effectively disclaims on behalf of all Contributors -all warranties and conditions, express and implied, including warranties -or conditions of title and non-infringement, and implied warranties or -conditions of merchantability and fitness for a particular purpose;

- -

ii) effectively excludes on behalf of all Contributors -all liability for damages, including direct, indirect, special, -incidental and consequential damages, such as lost profits;

- -

iii) states that any provisions which differ from this -Agreement are offered by that Contributor alone and not by any other -party; and

- -

iv) states that source code for the Program is available -from such Contributor, and informs licensees how to obtain it in a -reasonable manner on or through a medium customarily used for software -exchange.

- -

When the Program is made available in source code form:

- -

a) it must be made available under this Agreement; and

- -

b) a copy of this Agreement must be included with each -copy of the Program.

- -

Contributors may not remove or alter any copyright notices contained -within the Program.

- -

Each Contributor must identify itself as the originator of its -Contribution, if any, in a manner that reasonably allows subsequent -Recipients to identify the originator of the Contribution.

- -

4. COMMERCIAL DISTRIBUTION

- -

Commercial distributors of software may accept certain -responsibilities with respect to end users, business partners and the -like. While this license is intended to facilitate the commercial use of -the Program, the Contributor who includes the Program in a commercial -product offering should do so in a manner which does not create -potential liability for other Contributors. Therefore, if a Contributor -includes the Program in a commercial product offering, such Contributor -("Commercial Contributor") hereby agrees to defend and -indemnify every other Contributor ("Indemnified Contributor") -against any losses, damages and costs (collectively "Losses") -arising from claims, lawsuits and other legal actions brought by a third -party against the Indemnified Contributor to the extent caused by the -acts or omissions of such Commercial Contributor in connection with its -distribution of the Program in a commercial product offering. The -obligations in this section do not apply to any claims or Losses -relating to any actual or alleged intellectual property infringement. In -order to qualify, an Indemnified Contributor must: a) promptly notify -the Commercial Contributor in writing of such claim, and b) allow the -Commercial Contributor to control, and cooperate with the Commercial -Contributor in, the defense and any related settlement negotiations. The -Indemnified Contributor may participate in any such claim at its own -expense.

- -

For example, a Contributor might include the Program in a commercial -product offering, Product X. That Contributor is then a Commercial -Contributor. If that Commercial Contributor then makes performance -claims, or offers warranties related to Product X, those performance -claims and warranties are such Commercial Contributor's responsibility -alone. Under this section, the Commercial Contributor would have to -defend claims against the other Contributors related to those -performance claims and warranties, and if a court requires any other -Contributor to pay any damages as a result, the Commercial Contributor -must pay those damages.

- -

5. NO WARRANTY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS -PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS -OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, -ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY -OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely -responsible for determining the appropriateness of using and -distributing the Program and assumes all risks associated with its -exercise of rights under this Agreement , including but not limited to -the risks and costs of program errors, compliance with applicable laws, -damage to or loss of data, programs or equipment, and unavailability or -interruption of operations.

- -

6. DISCLAIMER OF LIABILITY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT -NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING -WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR -DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED -HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

- -

7. GENERAL

- -

If any provision of this Agreement is invalid or unenforceable under -applicable law, it shall not affect the validity or enforceability of -the remainder of the terms of this Agreement, and without further action -by the parties hereto, such provision shall be reformed to the minimum -extent necessary to make such provision valid and enforceable.

- -

If Recipient institutes patent litigation against any entity -(including a cross-claim or counterclaim in a lawsuit) alleging that the -Program itself (excluding combinations of the Program with other -software or hardware) infringes such Recipient's patent(s), then such -Recipient's rights granted under Section 2(b) shall terminate as of the -date such litigation is filed.

- -

All Recipient's rights under this Agreement shall terminate if it -fails to comply with any of the material terms or conditions of this -Agreement and does not cure such failure in a reasonable period of time -after becoming aware of such noncompliance. If all Recipient's rights -under this Agreement terminate, Recipient agrees to cease use and -distribution of the Program as soon as reasonably practicable. However, -Recipient's obligations under this Agreement and any licenses granted by -Recipient relating to the Program shall continue and survive.

- -

Everyone is permitted to copy and distribute copies of this -Agreement, but in order to avoid inconsistency the Agreement is -copyrighted and may only be modified in the following manner. The -Agreement Steward reserves the right to publish new versions (including -revisions) of this Agreement from time to time. No one other than the -Agreement Steward has the right to modify this Agreement. The Eclipse -Foundation is the initial Agreement Steward. The Eclipse Foundation may -assign the responsibility to serve as the Agreement Steward to a -suitable separate entity. Each new version of the Agreement will be -given a distinguishing version number. The Program (including -Contributions) may always be distributed subject to the version of the -Agreement under which it was received. In addition, after a new version -of the Agreement is published, Contributor may elect to distribute the -Program (including its Contributions) under the new version. Except as -expressly stated in Sections 2(a) and 2(b) above, Recipient receives no -rights or licenses to the intellectual property of any Contributor under -this Agreement, whether expressly, by implication, estoppel or -otherwise. All rights in the Program not expressly granted under this -Agreement are reserved.

- -

This Agreement is governed by the laws of the State of New York and -the intellectual property laws of the United States of America. No party -to this Agreement will bring a legal action under this Agreement more -than one year after the cause of action arose. Each party waives its -rights to a jury trial in any resulting litigation.

- - - - \ No newline at end of file diff --git a/features/org.eclipse.emf.eef.runtime-feature/feature.properties b/features/org.eclipse.emf.eef.runtime-feature/feature.properties deleted file mode 100644 index 489d5cf61..000000000 --- a/features/org.eclipse.emf.eef.runtime-feature/feature.properties +++ /dev/null @@ -1,146 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -providerName=Eclipse Modeling Project -featureName=Extended Editing Framework - Runtime -modelingUpdateSiteName=Eclipse Modeling Project Updates -description=Extended Editing Framework - Runtime - -# "licenseURL" property - URL of the "Feature License" -# do not translate value - just change to point to a locale-specific HTML page -licenseURL=license.html - -# "license" property - text of the "Feature Update License" -# should be plain text version of license agreement pointed to be "licenseURL" -license=\ -Eclipse Foundation Software User Agreement\n\ -February 1, 2011\n\ -\n\ -Usage Of Content\n\ -\n\ -THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\ -OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\ -USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\ -AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\ -NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\ -AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\ -AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\ -OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\ -TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\ -OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\ -BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\ -\n\ -Applicable Licenses\n\ -\n\ -Unless otherwise indicated, all Content made available by the\n\ -Eclipse Foundation is provided to you under the terms and conditions of\n\ -the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is\n\ -provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\ -For purposes of the EPL, "Program" will mean the Content.\n\ -\n\ -Content includes, but is not limited to, source code, object code,\n\ -documentation and other files maintained in the Eclipse Foundation source code\n\ -repository ("Repository") in software modules ("Modules") and made available\n\ -as downloadable archives ("Downloads").\n\ -\n\ - - Content may be structured and packaged into modules to facilitate delivering,\n\ - extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\ - plug-in fragments ("Fragments"), and features ("Features").\n\ - - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive)\n\ - in a directory named "plugins".\n\ - - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\ - Each Feature may be packaged as a sub-directory in a directory named "features".\n\ - Within a Feature, files named "feature.xml" may contain a list of the names and version\n\ - numbers of the Plug-ins and/or Fragments associated with that Feature.\n\ - - Features may also include other Features ("Included Features"). Within a Feature, files\n\ - named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\ -\n\ -The terms and conditions governing Plug-ins and Fragments should be\n\ -contained in files named "about.html" ("Abouts"). The terms and\n\ -conditions governing Features and Included Features should be contained\n\ -in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\ -Licenses may be located in any directory of a Download or Module\n\ -including, but not limited to the following locations:\n\ -\n\ - - The top-level (root) directory\n\ - - Plug-in and Fragment directories\n\ - - Inside Plug-ins and Fragments packaged as JARs\n\ - - Sub-directories of the directory named "src" of certain Plug-ins\n\ - - Feature directories\n\ -\n\ -Note: if a Feature made available by the Eclipse Foundation is installed using the\n\ -Provisioning Technology (as defined below), you must agree to a license ("Feature \n\ -Update License") during the installation process. If the Feature contains\n\ -Included Features, the Feature Update License should either provide you\n\ -with the terms and conditions governing the Included Features or inform\n\ -you where you can locate them. Feature Update Licenses may be found in\n\ -the "license" property of files named "feature.properties" found within a Feature.\n\ -Such Abouts, Feature Licenses, and Feature Update Licenses contain the\n\ -terms and conditions (or references to such terms and conditions) that\n\ -govern your use of the associated Content in that directory.\n\ -\n\ -THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER\n\ -TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\ -SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\ -\n\ - - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html)\n\ - - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\ - - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\ - - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\ - - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\ - - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\ -\n\ -IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\ -TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License\n\ -is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\ -govern that particular Content.\n\ -\n\ -\n\Use of Provisioning Technology\n\ -\n\ -The Eclipse Foundation makes available provisioning software, examples of which include,\n\ -but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for\n\ -the purpose of allowing users to install software, documentation, information and/or\n\ -other materials (collectively "Installable Software"). This capability is provided with\n\ -the intent of allowing such users to install, extend and update Eclipse-based products.\n\ -Information about packaging Installable Software is available at\n\ -http://eclipse.org/equinox/p2/repository_packaging.html ("Specification").\n\ -\n\ -You may use Provisioning Technology to allow other parties to install Installable Software.\n\ -You shall be responsible for enabling the applicable license agreements relating to the\n\ -Installable Software to be presented to, and accepted by, the users of the Provisioning Technology\n\ -in accordance with the Specification. By using Provisioning Technology in such a manner and\n\ -making it available in accordance with the Specification, you further acknowledge your\n\ -agreement to, and the acquisition of all necessary rights to permit the following:\n\ -\n\ - 1. A series of actions may occur ("Provisioning Process") in which a user may execute\n\ - the Provisioning Technology on a machine ("Target Machine") with the intent of installing,\n\ - extending or updating the functionality of an Eclipse-based product.\n\ - 2. During the Provisioning Process, the Provisioning Technology may cause third party\n\ - Installable Software or a portion thereof to be accessed and copied to the Target Machine.\n\ - 3. Pursuant to the Specification, you will provide to the user the terms and conditions that\n\ - govern the use of the Installable Software ("Installable Software Agreement") and such\n\ - Installable Software Agreement shall be accessed from the Target Machine in accordance\n\ - with the Specification. Such Installable Software Agreement must inform the user of the\n\ - terms and conditions that govern the Installable Software and must solicit acceptance by\n\ - the end user in the manner prescribed in such Installable Software Agreement. Upon such\n\ - indication of agreement by the user, the provisioning Technology will complete installation\n\ - of the Installable Software.\n\ -\n\ -Cryptography\n\ -\n\ -Content may contain encryption software. The country in which you are\n\ -currently may have restrictions on the import, possession, and use,\n\ -and/or re-export to another country, of encryption software. BEFORE\n\ -using any encryption software, please check the country's laws,\n\ -regulations and policies concerning the import, possession, or use, and\n\ -re-export of encryption software, to see if this is permitted.\n\ -\n\ -Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.\n -########### end of license property ########################################## diff --git a/features/org.eclipse.emf.eef.runtime-feature/feature.xml b/features/org.eclipse.emf.eef.runtime-feature/feature.xml deleted file mode 100644 index a0cd95147..000000000 --- a/features/org.eclipse.emf.eef.runtime-feature/feature.xml +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - %description - - - - Copyright (c) 2008 - 2010 Obeo. -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 - - - - %license - - - - - - - - - - - - diff --git a/features/org.eclipse.emf.eef.runtime-feature/license.html b/features/org.eclipse.emf.eef.runtime-feature/license.html deleted file mode 100644 index a1fe5ea3f..000000000 --- a/features/org.eclipse.emf.eef.runtime-feature/license.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - -Eclipse Foundation Software User Agreement - - - -

Eclipse Foundation Software User Agreement

-

February 1, 2011

- -

Usage Of Content

- -

THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS - (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND - CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE - OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR - NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND - CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.

- -

Applicable Licenses

- -

Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 - ("EPL"). A copy of the EPL is provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html. - For purposes of the EPL, "Program" will mean the Content.

- -

Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code - repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").

- -
    -
  • Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").
  • - -
  • Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".
  • -
  • A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins - and/or Fragments associated with that Feature.
  • -
  • Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.
  • - -
- -

The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and -Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module -including, but not limited to the following locations:

- -
    -
  • The top-level (root) directory
  • - -
  • Plug-in and Fragment directories
  • -
  • Inside Plug-ins and Fragments packaged as JARs
  • -
  • Sub-directories of the directory named "src" of certain Plug-ins
  • -
  • Feature directories
  • -
- -

Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the -installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or -inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. -Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in -that directory.

- -

THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE -OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):

- - - -

IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please -contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.

- - -

Use of Provisioning Technology

- -

The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse - Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or - other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to - install, extend and update Eclipse-based products. Information about packaging Installable Software is available at http://eclipse.org/equinox/p2/repository_packaging.html - - ("Specification").

- -

You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the - applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology - in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the - Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:

- -
    -
  1. A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology - on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based - product.
  2. - -
  3. During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be - accessed and copied to the Target Machine.
  4. -
  5. Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable - Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target - Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern - the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such - indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.
  6. -
- -

Cryptography

- -

Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to - another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, - possession, or use, and re-export of encryption software, to see if this is permitted.

- -

Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.

- - - diff --git a/features/org.eclipse.emf.eef.runtime-feature/license.txt b/features/org.eclipse.emf.eef.runtime-feature/license.txt deleted file mode 100644 index 24937b64c..000000000 --- a/features/org.eclipse.emf.eef.runtime-feature/license.txt +++ /dev/null @@ -1,87 +0,0 @@ -Eclipse Public License - v 1.0 - -THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. - -1. DEFINITIONS - -"Contribution" means: - -a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and -b) in the case of each subsequent Contributor: - -i) changes to the Program, and - -ii) additions to the Program; - -where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program. - -"Contributor" means any person or entity that distributes the Program. - -"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. - -"Program" means the Contributions distributed in accordance with this Agreement. - -"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. - -2. GRANT OF RIGHTS - -a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form. - -b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. - -c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. - -d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. - -3. REQUIREMENTS - -A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: - -a) it complies with the terms and conditions of this Agreement; and - -b) its license agreement: - -i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; - -ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; - -iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and - -iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange. - -When the Program is made available in source code form: - -a) it must be made available under this Agreement; and - -b) a copy of this Agreement must be included with each copy of the Program. - -Contributors may not remove or alter any copyright notices contained within the Program. - -Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. - -4. COMMERCIAL DISTRIBUTION - -Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. - -For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. - -5. NO WARRANTY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. - -6. DISCLAIMER OF LIABILITY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - -7. GENERAL - -If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. - -If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. - -All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. - -Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. - -This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. - diff --git a/features/org.eclipse.emf.eef.runtime-feature/pom.xml b/features/org.eclipse.emf.eef.runtime-feature/pom.xml deleted file mode 100644 index 441578f64..000000000 --- a/features/org.eclipse.emf.eef.runtime-feature/pom.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.runtime-feature - eclipse-feature - - EEF Runtime Feature - - diff --git a/features/org.eclipse.emf.eef.sdk-feature/.gitignore b/features/org.eclipse.emf.eef.sdk-feature/.gitignore deleted file mode 100644 index eb5a316cb..000000000 --- a/features/org.eclipse.emf.eef.sdk-feature/.gitignore +++ /dev/null @@ -1 +0,0 @@ -target diff --git a/features/org.eclipse.emf.eef.sdk-feature/.project b/features/org.eclipse.emf.eef.sdk-feature/.project deleted file mode 100644 index 005fcb44c..000000000 --- a/features/org.eclipse.emf.eef.sdk-feature/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - org.eclipse.emf.eef.sdk-feature - - - - - - org.eclipse.pde.FeatureBuilder - - - - - - org.eclipse.pde.FeatureNature - - diff --git a/features/org.eclipse.emf.eef.sdk-feature/build.properties b/features/org.eclipse.emf.eef.sdk-feature/build.properties deleted file mode 100644 index 8278da22b..000000000 --- a/features/org.eclipse.emf.eef.sdk-feature/build.properties +++ /dev/null @@ -1,23 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2010 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = feature.xml,\ - feature.properties,\ - license.html,\ - license.txt,\ - epl-v10.html -src.includes = feature.properties,\ - license.html,\ - license.txt,\ - feature.xml,\ - epl-v10.html - -generate.feature@org.eclipse.emf.eef.runtime.source = org.eclipse.emf.eef.runtime -generate.feature@org.eclipse.emf.eef.extended.source = org.eclipse.emf.eef.extended diff --git a/features/org.eclipse.emf.eef.sdk-feature/epl-v10.html b/features/org.eclipse.emf.eef.sdk-feature/epl-v10.html deleted file mode 100644 index 0d34dd06a..000000000 --- a/features/org.eclipse.emf.eef.sdk-feature/epl-v10.html +++ /dev/null @@ -1,262 +0,0 @@ - - - - - - -Eclipse Public License - Version 1.0 - - - - - - -

Eclipse Public License - v 1.0

- -

THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE -PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR -DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS -AGREEMENT.

- -

1. DEFINITIONS

- -

"Contribution" means:

- -

a) in the case of the initial Contributor, the initial -code and documentation distributed under this Agreement, and

-

b) in the case of each subsequent Contributor:

- -

i) changes to the Program, and

-

ii) additions to the Program;

-

where such changes and/or additions to the Program -originate from and are distributed by that particular Contributor. A -Contribution 'originates' from a Contributor if it was added to the -Program by such Contributor itself or anyone acting on such -Contributor's behalf. Contributions do not include additions to the -Program which: (i) are separate modules of software distributed in -conjunction with the Program under their own license agreement, and (ii) -are not derivative works of the Program.

- -

"Contributor" means any person or entity that distributes -the Program.

- -

"Licensed Patents" mean patent claims licensable by a -Contributor which are necessarily infringed by the use or sale of its -Contribution alone or when combined with the Program.

- -

"Program" means the Contributions distributed in accordance -with this Agreement.

- -

"Recipient" means anyone who receives the Program under -this Agreement, including all Contributors.

- -

2. GRANT OF RIGHTS

- -

a) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free copyright license to reproduce, prepare derivative works -of, publicly display, publicly perform, distribute and sublicense the -Contribution of such Contributor, if any, and such derivative works, in -source code and object code form.

- -

b) Subject to the terms of this Agreement, each -Contributor hereby grants Recipient a non-exclusive, worldwide, -royalty-free patent license under Licensed Patents to make, use, sell, -offer to sell, import and otherwise transfer the Contribution of such -Contributor, if any, in source code and object code form. This patent -license shall apply to the combination of the Contribution and the -Program if, at the time the Contribution is added by the Contributor, -such addition of the Contribution causes such combination to be covered -by the Licensed Patents. The patent license shall not apply to any other -combinations which include the Contribution. No hardware per se is -licensed hereunder.

- -

c) Recipient understands that although each Contributor -grants the licenses to its Contributions set forth herein, no assurances -are provided by any Contributor that the Program does not infringe the -patent or other intellectual property rights of any other entity. Each -Contributor disclaims any liability to Recipient for claims brought by -any other entity based on infringement of intellectual property rights -or otherwise. As a condition to exercising the rights and licenses -granted hereunder, each Recipient hereby assumes sole responsibility to -secure any other intellectual property rights needed, if any. For -example, if a third party patent license is required to allow Recipient -to distribute the Program, it is Recipient's responsibility to acquire -that license before distributing the Program.

- -

d) Each Contributor represents that to its knowledge it -has sufficient copyright rights in its Contribution, if any, to grant -the copyright license set forth in this Agreement.

- -

3. REQUIREMENTS

- -

A Contributor may choose to distribute the Program in object code -form under its own license agreement, provided that:

- -

a) it complies with the terms and conditions of this -Agreement; and

- -

b) its license agreement:

- -

i) effectively disclaims on behalf of all Contributors -all warranties and conditions, express and implied, including warranties -or conditions of title and non-infringement, and implied warranties or -conditions of merchantability and fitness for a particular purpose;

- -

ii) effectively excludes on behalf of all Contributors -all liability for damages, including direct, indirect, special, -incidental and consequential damages, such as lost profits;

- -

iii) states that any provisions which differ from this -Agreement are offered by that Contributor alone and not by any other -party; and

- -

iv) states that source code for the Program is available -from such Contributor, and informs licensees how to obtain it in a -reasonable manner on or through a medium customarily used for software -exchange.

- -

When the Program is made available in source code form:

- -

a) it must be made available under this Agreement; and

- -

b) a copy of this Agreement must be included with each -copy of the Program.

- -

Contributors may not remove or alter any copyright notices contained -within the Program.

- -

Each Contributor must identify itself as the originator of its -Contribution, if any, in a manner that reasonably allows subsequent -Recipients to identify the originator of the Contribution.

- -

4. COMMERCIAL DISTRIBUTION

- -

Commercial distributors of software may accept certain -responsibilities with respect to end users, business partners and the -like. While this license is intended to facilitate the commercial use of -the Program, the Contributor who includes the Program in a commercial -product offering should do so in a manner which does not create -potential liability for other Contributors. Therefore, if a Contributor -includes the Program in a commercial product offering, such Contributor -("Commercial Contributor") hereby agrees to defend and -indemnify every other Contributor ("Indemnified Contributor") -against any losses, damages and costs (collectively "Losses") -arising from claims, lawsuits and other legal actions brought by a third -party against the Indemnified Contributor to the extent caused by the -acts or omissions of such Commercial Contributor in connection with its -distribution of the Program in a commercial product offering. The -obligations in this section do not apply to any claims or Losses -relating to any actual or alleged intellectual property infringement. In -order to qualify, an Indemnified Contributor must: a) promptly notify -the Commercial Contributor in writing of such claim, and b) allow the -Commercial Contributor to control, and cooperate with the Commercial -Contributor in, the defense and any related settlement negotiations. The -Indemnified Contributor may participate in any such claim at its own -expense.

- -

For example, a Contributor might include the Program in a commercial -product offering, Product X. That Contributor is then a Commercial -Contributor. If that Commercial Contributor then makes performance -claims, or offers warranties related to Product X, those performance -claims and warranties are such Commercial Contributor's responsibility -alone. Under this section, the Commercial Contributor would have to -defend claims against the other Contributors related to those -performance claims and warranties, and if a court requires any other -Contributor to pay any damages as a result, the Commercial Contributor -must pay those damages.

- -

5. NO WARRANTY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS -PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS -OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, -ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY -OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely -responsible for determining the appropriateness of using and -distributing the Program and assumes all risks associated with its -exercise of rights under this Agreement , including but not limited to -the risks and costs of program errors, compliance with applicable laws, -damage to or loss of data, programs or equipment, and unavailability or -interruption of operations.

- -

6. DISCLAIMER OF LIABILITY

- -

EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT -NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING -WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR -DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED -HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

- -

7. GENERAL

- -

If any provision of this Agreement is invalid or unenforceable under -applicable law, it shall not affect the validity or enforceability of -the remainder of the terms of this Agreement, and without further action -by the parties hereto, such provision shall be reformed to the minimum -extent necessary to make such provision valid and enforceable.

- -

If Recipient institutes patent litigation against any entity -(including a cross-claim or counterclaim in a lawsuit) alleging that the -Program itself (excluding combinations of the Program with other -software or hardware) infringes such Recipient's patent(s), then such -Recipient's rights granted under Section 2(b) shall terminate as of the -date such litigation is filed.

- -

All Recipient's rights under this Agreement shall terminate if it -fails to comply with any of the material terms or conditions of this -Agreement and does not cure such failure in a reasonable period of time -after becoming aware of such noncompliance. If all Recipient's rights -under this Agreement terminate, Recipient agrees to cease use and -distribution of the Program as soon as reasonably practicable. However, -Recipient's obligations under this Agreement and any licenses granted by -Recipient relating to the Program shall continue and survive.

- -

Everyone is permitted to copy and distribute copies of this -Agreement, but in order to avoid inconsistency the Agreement is -copyrighted and may only be modified in the following manner. The -Agreement Steward reserves the right to publish new versions (including -revisions) of this Agreement from time to time. No one other than the -Agreement Steward has the right to modify this Agreement. The Eclipse -Foundation is the initial Agreement Steward. The Eclipse Foundation may -assign the responsibility to serve as the Agreement Steward to a -suitable separate entity. Each new version of the Agreement will be -given a distinguishing version number. The Program (including -Contributions) may always be distributed subject to the version of the -Agreement under which it was received. In addition, after a new version -of the Agreement is published, Contributor may elect to distribute the -Program (including its Contributions) under the new version. Except as -expressly stated in Sections 2(a) and 2(b) above, Recipient receives no -rights or licenses to the intellectual property of any Contributor under -this Agreement, whether expressly, by implication, estoppel or -otherwise. All rights in the Program not expressly granted under this -Agreement are reserved.

- -

This Agreement is governed by the laws of the State of New York and -the intellectual property laws of the United States of America. No party -to this Agreement will bring a legal action under this Agreement more -than one year after the cause of action arose. Each party waives its -rights to a jury trial in any resulting litigation.

- - - - \ No newline at end of file diff --git a/features/org.eclipse.emf.eef.sdk-feature/feature.properties b/features/org.eclipse.emf.eef.sdk-feature/feature.properties deleted file mode 100644 index 935180671..000000000 --- a/features/org.eclipse.emf.eef.sdk-feature/feature.properties +++ /dev/null @@ -1,161 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -# "providerName" property - name of the company that provides the feature -providerName=Eclipse Modeling Project - -# "featureName" property - name of the feature -featureName=Extended Editing Framework - SDK - -# "updateSiteName" property - label for the update site (on download.eclipse.org) -modelingUpdateSiteName=Eclipse Modeling Project Updates - -# "description" property - description of the feature -description=Extended Editing Framework - SDK.\n\ -This includes :\n\ -- EEF metamodels\n\ -- EEF editors\n\ -- EEF models initializer\n\ -- EEF Acceleo generators\n\ -- EEF Documentation\n\ -- EEF extension\n\ -- all sources\n\ - -# "licenseURL" property - URL of the "Feature License" -# do not translate value - just change to point to a locale-specific HTML page -licenseURL=license.html - -# "license" property - text of the "Feature Update License" -# should be plain text version of license agreement pointed to be "licenseURL" -license=\ -Eclipse Foundation Software User Agreement\n\ -February 1, 2011\n\ -\n\ -Usage Of Content\n\ -\n\ -THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\ -OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\ -USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\ -AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\ -NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\ -AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\ -AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\ -OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\ -TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\ -OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\ -BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\ -\n\ -Applicable Licenses\n\ -\n\ -Unless otherwise indicated, all Content made available by the\n\ -Eclipse Foundation is provided to you under the terms and conditions of\n\ -the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is\n\ -provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\ -For purposes of the EPL, "Program" will mean the Content.\n\ -\n\ -Content includes, but is not limited to, source code, object code,\n\ -documentation and other files maintained in the Eclipse Foundation source code\n\ -repository ("Repository") in software modules ("Modules") and made available\n\ -as downloadable archives ("Downloads").\n\ -\n\ - - Content may be structured and packaged into modules to facilitate delivering,\n\ - extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\ - plug-in fragments ("Fragments"), and features ("Features").\n\ - - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive)\n\ - in a directory named "plugins".\n\ - - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\ - Each Feature may be packaged as a sub-directory in a directory named "features".\n\ - Within a Feature, files named "feature.xml" may contain a list of the names and version\n\ - numbers of the Plug-ins and/or Fragments associated with that Feature.\n\ - - Features may also include other Features ("Included Features"). Within a Feature, files\n\ - named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\ -\n\ -The terms and conditions governing Plug-ins and Fragments should be\n\ -contained in files named "about.html" ("Abouts"). The terms and\n\ -conditions governing Features and Included Features should be contained\n\ -in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\ -Licenses may be located in any directory of a Download or Module\n\ -including, but not limited to the following locations:\n\ -\n\ - - The top-level (root) directory\n\ - - Plug-in and Fragment directories\n\ - - Inside Plug-ins and Fragments packaged as JARs\n\ - - Sub-directories of the directory named "src" of certain Plug-ins\n\ - - Feature directories\n\ -\n\ -Note: if a Feature made available by the Eclipse Foundation is installed using the\n\ -Provisioning Technology (as defined below), you must agree to a license ("Feature \n\ -Update License") during the installation process. If the Feature contains\n\ -Included Features, the Feature Update License should either provide you\n\ -with the terms and conditions governing the Included Features or inform\n\ -you where you can locate them. Feature Update Licenses may be found in\n\ -the "license" property of files named "feature.properties" found within a Feature.\n\ -Such Abouts, Feature Licenses, and Feature Update Licenses contain the\n\ -terms and conditions (or references to such terms and conditions) that\n\ -govern your use of the associated Content in that directory.\n\ -\n\ -THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER\n\ -TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\ -SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\ -\n\ - - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html)\n\ - - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\ - - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\ - - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\ - - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\ - - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\ -\n\ -IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\ -TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License\n\ -is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\ -govern that particular Content.\n\ -\n\ -\n\Use of Provisioning Technology\n\ -\n\ -The Eclipse Foundation makes available provisioning software, examples of which include,\n\ -but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for\n\ -the purpose of allowing users to install software, documentation, information and/or\n\ -other materials (collectively "Installable Software"). This capability is provided with\n\ -the intent of allowing such users to install, extend and update Eclipse-based products.\n\ -Information about packaging Installable Software is available at\n\ -http://eclipse.org/equinox/p2/repository_packaging.html ("Specification").\n\ -\n\ -You may use Provisioning Technology to allow other parties to install Installable Software.\n\ -You shall be responsible for enabling the applicable license agreements relating to the\n\ -Installable Software to be presented to, and accepted by, the users of the Provisioning Technology\n\ -in accordance with the Specification. By using Provisioning Technology in such a manner and\n\ -making it available in accordance with the Specification, you further acknowledge your\n\ -agreement to, and the acquisition of all necessary rights to permit the following:\n\ -\n\ - 1. A series of actions may occur ("Provisioning Process") in which a user may execute\n\ - the Provisioning Technology on a machine ("Target Machine") with the intent of installing,\n\ - extending or updating the functionality of an Eclipse-based product.\n\ - 2. During the Provisioning Process, the Provisioning Technology may cause third party\n\ - Installable Software or a portion thereof to be accessed and copied to the Target Machine.\n\ - 3. Pursuant to the Specification, you will provide to the user the terms and conditions that\n\ - govern the use of the Installable Software ("Installable Software Agreement") and such\n\ - Installable Software Agreement shall be accessed from the Target Machine in accordance\n\ - with the Specification. Such Installable Software Agreement must inform the user of the\n\ - terms and conditions that govern the Installable Software and must solicit acceptance by\n\ - the end user in the manner prescribed in such Installable Software Agreement. Upon such\n\ - indication of agreement by the user, the provisioning Technology will complete installation\n\ - of the Installable Software.\n\ -\n\ -Cryptography\n\ -\n\ -Content may contain encryption software. The country in which you are\n\ -currently may have restrictions on the import, possession, and use,\n\ -and/or re-export to another country, of encryption software. BEFORE\n\ -using any encryption software, please check the country's laws,\n\ -regulations and policies concerning the import, possession, or use, and\n\ -re-export of encryption software, to see if this is permitted.\n\ -\n\ -Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.\n -########### end of license property ########################################## diff --git a/features/org.eclipse.emf.eef.sdk-feature/feature.xml b/features/org.eclipse.emf.eef.sdk-feature/feature.xml deleted file mode 100644 index bcd9cb272..000000000 --- a/features/org.eclipse.emf.eef.sdk-feature/feature.xml +++ /dev/null @@ -1,197 +0,0 @@ - - - - - - %description - - - - Copyright (c) 2008 - 2010 Obeo. -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 - - - - %license - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/features/org.eclipse.emf.eef.sdk-feature/license.html b/features/org.eclipse.emf.eef.sdk-feature/license.html deleted file mode 100644 index a1fe5ea3f..000000000 --- a/features/org.eclipse.emf.eef.sdk-feature/license.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - -Eclipse Foundation Software User Agreement - - - -

Eclipse Foundation Software User Agreement

-

February 1, 2011

- -

Usage Of Content

- -

THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS - (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND - CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE - OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR - NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND - CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.

- -

Applicable Licenses

- -

Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 - ("EPL"). A copy of the EPL is provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html. - For purposes of the EPL, "Program" will mean the Content.

- -

Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code - repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").

- -
    -
  • Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").
  • - -
  • Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".
  • -
  • A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins - and/or Fragments associated with that Feature.
  • -
  • Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.
  • - -
- -

The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and -Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module -including, but not limited to the following locations:

- -
    -
  • The top-level (root) directory
  • - -
  • Plug-in and Fragment directories
  • -
  • Inside Plug-ins and Fragments packaged as JARs
  • -
  • Sub-directories of the directory named "src" of certain Plug-ins
  • -
  • Feature directories
  • -
- -

Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the -installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or -inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. -Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in -that directory.

- -

THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE -OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):

- - - -

IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please -contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.

- - -

Use of Provisioning Technology

- -

The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse - Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or - other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to - install, extend and update Eclipse-based products. Information about packaging Installable Software is available at http://eclipse.org/equinox/p2/repository_packaging.html - - ("Specification").

- -

You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the - applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology - in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the - Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:

- -
    -
  1. A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology - on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based - product.
  2. - -
  3. During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be - accessed and copied to the Target Machine.
  4. -
  5. Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable - Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target - Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern - the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such - indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.
  6. -
- -

Cryptography

- -

Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to - another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, - possession, or use, and re-export of encryption software, to see if this is permitted.

- -

Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.

- - - diff --git a/features/org.eclipse.emf.eef.sdk-feature/license.txt b/features/org.eclipse.emf.eef.sdk-feature/license.txt deleted file mode 100644 index 24937b64c..000000000 --- a/features/org.eclipse.emf.eef.sdk-feature/license.txt +++ /dev/null @@ -1,87 +0,0 @@ -Eclipse Public License - v 1.0 - -THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. - -1. DEFINITIONS - -"Contribution" means: - -a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and -b) in the case of each subsequent Contributor: - -i) changes to the Program, and - -ii) additions to the Program; - -where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program. - -"Contributor" means any person or entity that distributes the Program. - -"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. - -"Program" means the Contributions distributed in accordance with this Agreement. - -"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. - -2. GRANT OF RIGHTS - -a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form. - -b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. - -c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. - -d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. - -3. REQUIREMENTS - -A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: - -a) it complies with the terms and conditions of this Agreement; and - -b) its license agreement: - -i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; - -ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; - -iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and - -iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange. - -When the Program is made available in source code form: - -a) it must be made available under this Agreement; and - -b) a copy of this Agreement must be included with each copy of the Program. - -Contributors may not remove or alter any copyright notices contained within the Program. - -Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. - -4. COMMERCIAL DISTRIBUTION - -Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. - -For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. - -5. NO WARRANTY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. - -6. DISCLAIMER OF LIABILITY - -EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - -7. GENERAL - -If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. - -If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. - -All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. - -Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. - -This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. - diff --git a/features/org.eclipse.emf.eef.sdk-feature/pom.xml b/features/org.eclipse.emf.eef.sdk-feature/pom.xml deleted file mode 100644 index 1b72ef8c0..000000000 --- a/features/org.eclipse.emf.eef.sdk-feature/pom.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.sdk-feature - eclipse-feature - - EEF SDK Feature - - diff --git a/plugins/org.eclipse.emf.eef.branding/.gitignore b/plugins/org.eclipse.emf.eef.branding/.gitignore deleted file mode 100644 index ea8c4bf7f..000000000 --- a/plugins/org.eclipse.emf.eef.branding/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/target diff --git a/plugins/org.eclipse.emf.eef.branding/.project b/plugins/org.eclipse.emf.eef.branding/.project deleted file mode 100644 index 7a3db7b7e..000000000 --- a/plugins/org.eclipse.emf.eef.branding/.project +++ /dev/null @@ -1,22 +0,0 @@ - - - org.eclipse.emf.eef.branding - - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.branding/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.branding/META-INF/MANIFEST.MF deleted file mode 100644 index c9d1d42b4..000000000 --- a/plugins/org.eclipse.emf.eef.branding/META-INF/MANIFEST.MF +++ /dev/null @@ -1,6 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF -Bundle-SymbolicName: org.eclipse.emf.eef.branding -Bundle-Version: 1.5.2.qualifier -Bundle-Vendor: Eclipse Modeling Project diff --git a/plugins/org.eclipse.emf.eef.branding/about.html b/plugins/org.eclipse.emf.eef.branding/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.branding/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.branding/about.ini b/plugins/org.eclipse.emf.eef.branding/about.ini deleted file mode 100644 index eec22440e..000000000 --- a/plugins/org.eclipse.emf.eef.branding/about.ini +++ /dev/null @@ -1,14 +0,0 @@ -# about.ini -# contains information about a feature -# java.io.Properties file (ISO 8859-1 with "\" escapes) -# "%key" are externalized strings defined in about.properties -# This file does not need to be translated. - -# Property "aboutText" contains blurb for "About" dialog (translated) -aboutText=%featureText - -# Property "featureImage" contains path to feature image (32x32) -featureImage=modeling32.png - -# Property "appName" contains name of the application (translated) -appName=%featureName diff --git a/plugins/org.eclipse.emf.eef.branding/about.mappings b/plugins/org.eclipse.emf.eef.branding/about.mappings deleted file mode 100644 index a28390a75..000000000 --- a/plugins/org.eclipse.emf.eef.branding/about.mappings +++ /dev/null @@ -1,6 +0,0 @@ -# about.mappings -# contains fill-ins for about.properties -# java.io.Properties file (ISO 8859-1 with "\" escapes) -# This file does not need to be translated. - -0=@build@ diff --git a/plugins/org.eclipse.emf.eef.branding/about.properties b/plugins/org.eclipse.emf.eef.branding/about.properties deleted file mode 100644 index 13ccbfde1..000000000 --- a/plugins/org.eclipse.emf.eef.branding/about.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -featureName=Extended Editing Framework - -featureText=Extended Editing Framework \n\ -Version: {featureVersion}\n\ -\n\ -(c) Copyright Obeo and others. 2008, 2012. All rights reserved.\n\ -\n\ -Extended Editing Framework brings sexy properties into standards Eclipse Modeling Framework editors.\n\ -Visit http://www.eclipse.org/eef diff --git a/plugins/org.eclipse.emf.eef.branding/build.properties b/plugins/org.eclipse.emf.eef.branding/build.properties deleted file mode 100644 index b3258f21a..000000000 --- a/plugins/org.eclipse.emf.eef.branding/build.properties +++ /dev/null @@ -1,16 +0,0 @@ -############################################################################### -# Copyright (c) 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = about.html,\ - modeling32.png,\ - about.properties,\ - about.ini,\ - about.mappings,\ - META-INF/ diff --git a/plugins/org.eclipse.emf.eef.branding/modeling32.png b/plugins/org.eclipse.emf.eef.branding/modeling32.png deleted file mode 100644 index 6b08de2ada775b81a7d93d35ecdbc8bbed6da81f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2414 zcmV-!36b`RP)mG85FUz8YqR{-rnBN_xo$VbKdjbHiRY1wv+qh zy!SolJ-_GU_dMquMrc70)S+vDBxRp~#32gAhd2-uVnB4>GsbMXM(ghBrT{$?KOu^g z7~U&*p~!K*uBQTAm7vX#CMjHz`gsai61d72l1lqf!krH+8{?=!I4_20H8h6BnKVk_ zp938KZB<&El)x>JlzeWGV4k#`gR2sRzw@Ak1|@`aarAYNghH$VBMD4M zFhz-T?eX72UuAe+D1mu@o$QxLk1z?YL5jw#rj{=imRV(^#nGJQ6FIH1P_+tgowzh& z7!I>-tz_u=qs7^`KfR7*iefRnE=TGi^{`q09K&u2@ z1X&E}fP7vG4?|v?t|axDYLBB?>7r)Sg`7@flNHM5G%A%%(sYY7!zSC($+9#ujmkyK zC>(OV(cd#FD~iHewtahBcYlBXgRQNtE4jCFx!l^++im7#y6Fejxd{HH)P=INbm4XZ*$<-s0mR3fkb?Xf1I=g7&U|n0 z-aqJz7wh}m+S*z-Z{GY3+qU(cJ9oYw_<^H@D+;D_;i+Xhx}AjOuQs5DW7xOG6LBPIjC41kQpqF}%2<|5rU_429=WbZw(SXpUG+$Ko*oQbbg^<)-0;MAL0DOfHTP zODf<=aNqZYP!Kv484Bz`aAn7iEtH!nB_DtMiQlMdkjDoFOsYf*h&-SDWcr)1B}kc)BD1VNi$~XM($DDafKIn2()S#4g>!!+r=1wIk;z&?>e+}X+7QZrIob$j@uDa zgIZE4dgINvs9faWo{&nV@r#Ls^=r;OC1fhIUBkZ12eCYWeL7X4nY>2%ypCR{{H#v1 z1sz4lqEf}63Oo^l^9614Tw8j;p~gm)QmJN&*Tt#6zK)WONm{k4U4)Vw=m7)S)GLYa zN41?Z`3BBr8!n%ms*-{X0HZ{nb0Tsu3z@+CP+Y{`g2JZgxd#F-^hTwk(Zr=mkqNqP z(3Q&t0J|WoC$a@-OEKhun?X$hxS@-?f2wFwv1~@03oj|+BcAsT*B&uWg2ugUkp9R zQc+bxQ z4KEKK09Q(4;Lhc3)SO@fjDvEE-J10#b>5PuhqtbypYM5{W@ct;ZuccoYrsJm0%Ec( zht>~dvqvvP3dGve?adg%k%@gSUn%4=x2)O3C$=w2(O>^Q8patU3*gd*hB$56vJPIc z=)i$Lirz(j3xaw!&>#Y>G5_#%_Shp=-y?9|3X;n@I$EFHzI{hL9&dbM-@Xri`s$uHbLQ;n z>u*ofuAeIO9U%m8$ z)m>c=@fQ;l6QAK2>$SJH-!%GABYq(X=Qqp2+RcP=7APSWsj8 zJl4bQ$9B=bX)Ke;^bQXX|5;Vlrs(DL^z^yiyLay&K7Ra@73mJ|vHtIFT(n@}w-lzN z{xp1&4h;>{XOox3T(P;Zxg(e$TWB@kZl9UY_-iZBo4I4?y`kU1>eTr7_^H9c!J~uk zyz>#$9;e}vk!VjH!Tb?$cwlPk zNQwS~#=0|^4qV_;FrW!lkYA@94v7C66u`MC(2*rJEOQV?98t+<(ME}OO4juMw&8N> zm%Tt-GAp7qgF!)fLbmvk31GOB1g^ZzM&SQ5a7_UwZoPpcN-{T3+ - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.branding - eclipse-plugin - - EEF Branding Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/.classpath b/plugins/org.eclipse.emf.eef.cdo.runtime/.classpath deleted file mode 100644 index 2d1a4302f..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/.gitignore b/plugins/org.eclipse.emf.eef.cdo.runtime/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/.project b/plugins/org.eclipse.emf.eef.cdo.runtime/.project deleted file mode 100644 index 87cc90256..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.cdo.runtime - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.cdo.runtime/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index 44217f8c0..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,7 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.cdo.runtime/META-INF/MANIFEST.MF deleted file mode 100644 index c34d25f4d..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/META-INF/MANIFEST.MF +++ /dev/null @@ -1,15 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF CDO Runtime Plug-in -Bundle-SymbolicName: org.eclipse.emf.eef.cdo.runtime;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Activator: org.eclipse.emf.eef.cdo.runtime.EEFCDORuntimePlugin -Bundle-Vendor: Eclipse Modeling Project -Require-Bundle: org.eclipse.ui, - org.eclipse.core.runtime, - org.eclipse.emf.cdo;bundle-version="4.0.0", - org.eclipse.emf.eef.runtime -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Bundle-ActivationPolicy: lazy -Export-Package: org.eclipse.emf.eef.cdo.runtime.policies, - org.eclipse.emf.eef.cdo.runtime.provider diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/build.properties b/plugins/org.eclipse.emf.eef.cdo.runtime/build.properties deleted file mode 100644 index 6f20375d6..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/build.properties +++ /dev/null @@ -1,5 +0,0 @@ -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/plugin.xml b/plugins/org.eclipse.emf.eef.cdo.runtime/plugin.xml deleted file mode 100644 index a7c78c195..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/plugin.xml +++ /dev/null @@ -1,35 +0,0 @@ - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/pom.xml b/plugins/org.eclipse.emf.eef.cdo.runtime/pom.xml deleted file mode 100644 index 9fdfb6ee0..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/pom.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.cdo.runtime - eclipse-plugin - - EEF Runtime Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/schema/CDOLockStrategyProvider.exsd b/plugins/org.eclipse.emf.eef.cdo.runtime/schema/CDOLockStrategyProvider.exsd deleted file mode 100644 index 4e13aa4df..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/schema/CDOLockStrategyProvider.exsd +++ /dev/null @@ -1,102 +0,0 @@ - - - - - - - - - Declare a EEF CDO Lock Strategy Provider - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [Enter the first release in which this extension point appears.] - - - - - - - - - [Enter extension point usage example here.] - - - - - - - - - [Enter API information here.] - - - - - - - - - [Enter information about supplied implementation of this extension point.] - - - - - diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/EEFCDORuntimePlugin.java b/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/EEFCDORuntimePlugin.java deleted file mode 100644 index c646735a6..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/EEFCDORuntimePlugin.java +++ /dev/null @@ -1,66 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.cdo.runtime; - -import org.eclipse.ui.plugin.AbstractUIPlugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle - * - * @author Nathalie Lepine - */ -public class EEFCDORuntimePlugin extends AbstractUIPlugin { - - // The plug-in ID - public static final String PLUGIN_ID = "org.eclipse.emf.eef.cdo.runtime"; //$NON-NLS-1$ - - // The shared instance - private static EEFCDORuntimePlugin plugin; - - /** - * The constructor - */ - public EEFCDORuntimePlugin() { - } - - /** - * (non-Javadoc) - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - - /** - * (non-Javadoc) - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance - * - * @return the shared instance - */ - public static EEFCDORuntimePlugin getDefault() { - return plugin; - } - -} diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/CDOReadOnlyPolicy.java b/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/CDOReadOnlyPolicy.java deleted file mode 100644 index 3b849e41e..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/CDOReadOnlyPolicy.java +++ /dev/null @@ -1,43 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.cdo.runtime.policies; - -import org.eclipse.emf.cdo.CDOObject; -import org.eclipse.emf.cdo.eresource.CDOResource; -import org.eclipse.emf.cdo.util.CDOUtil; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.api.providers.IReadOnlyPolicy; - -/** - * Read Only policy for CDO. If an element is locked -> the widget is read only. - * - * @author Nathalie Lepine - * - */ -public class CDOReadOnlyPolicy implements IReadOnlyPolicy { - - - /** (non-Javadoc) - * @see org.eclipse.emf.eef.runtime.api.providers.IReadOnlyPolicy#isReadOnly(org.eclipse.emf.ecore.EObject, java.lang.Object) - */ - public boolean isReadOnly(EObject context, Object eStructuralFeature) { - if (context != null && context.eResource() instanceof CDOResource) { - CDOObject cdoObject = CDOUtil.getCDOObject(context); - if (cdoObject != null - && cdoObject.cdoWriteLock().isLockedByOthers()) { - return true; - } - } - - return false; - } - -} diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/CDOWizardOpeningPolicy.java b/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/CDOWizardOpeningPolicy.java deleted file mode 100644 index 2fb866e60..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/CDOWizardOpeningPolicy.java +++ /dev/null @@ -1,84 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.cdo.runtime.policies; - -import org.eclipse.emf.cdo.CDOObject; -import org.eclipse.emf.cdo.util.CDOUtil; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.change.ChangeDescription; -import org.eclipse.emf.ecore.change.util.ChangeRecorder; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.wizards.EEFWizardDialog; -import org.eclipse.emf.eef.runtime.ui.wizards.PropertiesEditionWizard; -import org.eclipse.emf.eef.runtime.ui.wizards.IWizardOpeningPolicy; -import org.eclipse.jface.window.Window; - -/** - * CDO policy for wizard opening : if object is locked, no opening. - * - * @author Nathalie Lepine - * - */ -public class CDOWizardOpeningPolicy implements IWizardOpeningPolicy { - - private ChangeDescription description; - - /** - * (non-Javadoc) - * - * @see org.eclipse.emf.eef.runtime.ui.wizards.IWizardOpeningPolicy#openWizard(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, - * org.eclipse.emf.eef.runtime.ui.wizards.PropertiesEditionWizard) - */ - public boolean openWizard(PropertiesEditingContext editionContext, - PropertiesEditionWizard wizard) { - CDOReadOnlyPolicy cdoReadOnlyPolicy = new CDOReadOnlyPolicy(); - if (!cdoReadOnlyPolicy.isReadOnly(editionContext.getEObject(), null)) { - EEFWizardDialog wDialog = new EEFWizardDialog( - EditingUtils.getShell(), wizard); - int open = wDialog.open(); - ChangeRecorder changeRecorder = editionContext.getChangeRecorder(); - if (changeRecorder != null) { - description = changeRecorder.endRecording(); - } else { - description = null; - } - if (open == Window.OK) { - return true; - } else { - if (description != null) { - description.applyAndReverse(); - } - return false; - } - } - return false; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.wizards.IWizardOpeningPolicy#getDescription() - */ - public ChangeDescription getDescription() { - return description; - } - - /** - * (non-Javadoc) - * - * @see org.eclipse.emf.eef.runtime.ui.wizards.IWizardOpeningPolicy#provide(org.eclipse.emf.ecore.EObject) - */ - public boolean provide(EObject eObject) { - CDOObject cdoObject = CDOUtil.getCDOObject(eObject); - return cdoObject != null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/EEFWizardLockPolicy.java b/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/EEFWizardLockPolicy.java deleted file mode 100644 index 10a36447e..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/policies/EEFWizardLockPolicy.java +++ /dev/null @@ -1,119 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.cdo.runtime.policies; - -import java.util.List; - -import org.eclipse.emf.cdo.CDOObject; -import org.eclipse.emf.cdo.eresource.CDOResource; -import org.eclipse.emf.cdo.transaction.CDOTransaction; -import org.eclipse.emf.cdo.util.CDOUtil; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.cdo.runtime.provider.ICDOLockStrategyProvider; -import org.eclipse.emf.eef.cdo.runtime.service.CDOLockStrategyProviderService; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.policies.ILockPolicy; -import org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFEditorSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFEditorSettingsBuilder.EEFEditorSettingsImpl; -import org.eclipse.emf.spi.cdo.FSMUtil; - -/** - * Lock policy for EEF wizard : lock the semantic elements and its EEFEditorSettings for SmartModelNavigation. - * - * @author Nathalie Lepine - * - */ -public class EEFWizardLockPolicy implements ILockPolicy { - - /** - * (non-Javadoc) - * - * @see org.eclipse.emf.eef.runtime.policies.ILockPolicy#lock(org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - */ - public void lock(IPropertiesEditionComponent propertiesEditingComponent) { - lock(propertiesEditingComponent.getEditingContext().getEObject()); - if (propertiesEditingComponent instanceof SinglePartPropertiesEditingComponent && ((SinglePartPropertiesEditingComponent) propertiesEditingComponent).getEditingPart() instanceof CompositePropertiesEditionPart) { - lock(((CompositePropertiesEditionPart) ((SinglePartPropertiesEditingComponent) propertiesEditingComponent).getEditingPart()).getSettings()); - } - - } - - private void lock(List allSettings) { - for (EEFEditorSettings eefEditorSettings : allSettings) { - if (eefEditorSettings instanceof EEFEditorSettingsImpl) { - EObject significantObject = ((EEFEditorSettingsImpl) eefEditorSettings) - .getSignificantObject(); - if (significantObject != null) { - lock(significantObject); - } - } - } - } - - private void lock(EObject eObject) { - if (eObject != null && eObject.eResource() instanceof CDOResource) { - CDOObject cdoObject = CDOUtil.getCDOObject(eObject); - if (cdoObject != null && !FSMUtil.isTransient(cdoObject)) { - if (!CDOLockStrategyProviderService.getInstance().getProviders() - .isEmpty()) { - for (ICDOLockStrategyProvider provider : CDOLockStrategyProviderService.getInstance().getProviders()) { - provider.lock(cdoObject); - } - } else if (cdoObject.cdoWriteLock() != null) { - cdoObject.cdoWriteLock().tryLock(); - } - } - } - } - - private void unlock(List allSettings) { - for (EEFEditorSettings eefEditorSettings : allSettings) { - if (eefEditorSettings instanceof EEFEditorSettingsImpl) { - EObject significantObject = ((EEFEditorSettingsImpl) eefEditorSettings) - .getSignificantObject(); - if (significantObject != null) { - unlock(significantObject); - } - } - } - } - - private void unlock(EObject eObject) { - if (eObject != null && eObject.eResource() instanceof CDOResource) { - CDOObject cdoObject = CDOUtil.getCDOObject(eObject); - if (cdoObject != null && !FSMUtil.isTransient(cdoObject) && cdoObject.cdoView() instanceof CDOTransaction) { - if (!CDOLockStrategyProviderService.getInstance().getProviders() - .isEmpty()) { - for (ICDOLockStrategyProvider provider : CDOLockStrategyProviderService.getInstance().getProviders()) { - provider.release(cdoObject); - } - } else if (cdoObject.cdoWriteLock() != null) { - cdoObject.cdoWriteLock().unlock(); - } - } - } - } - - /** - * (non-Javadoc) - * - * @see org.eclipse.emf.eef.runtime.policies.ILockPolicy#release(org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - */ - public void release(IPropertiesEditionComponent propertiesEditingComponent) { - unlock(propertiesEditingComponent.getEditingContext().getEObject()); - if (propertiesEditingComponent instanceof SinglePartPropertiesEditingComponent && ((SinglePartPropertiesEditingComponent) propertiesEditingComponent).getEditingPart() instanceof CompositePropertiesEditionPart) { - unlock(((CompositePropertiesEditionPart) ((SinglePartPropertiesEditingComponent) propertiesEditingComponent).getEditingPart()).getSettings()); - } - } - -} \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/provider/ICDOLockStrategyProvider.java b/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/provider/ICDOLockStrategyProvider.java deleted file mode 100644 index 4bb17907b..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/provider/ICDOLockStrategyProvider.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.cdo.runtime.provider; - -import java.util.Collection; - -import org.eclipse.emf.ecore.EObject; - -/** - * Provide a strategy for lock and unlock elements. - * - * @author Nathalie Lepine - * - */ -public interface ICDOLockStrategyProvider { - - /** - * Lock an instance. - * - * @param instance - * any instance. - */ - void lock(EObject instance); - - /** - * Unlocked an instance. - * - * @param instance - * any instance. - */ - void release(EObject instance); - - /** - * Lock several instances. - * - * @param instances - * locked instances. - */ - void lock(Collection instances); - - /** - * Unlock several instances.. - * - * @param instances - * unlocked instances. - */ - void release(Collection instances); - -} diff --git a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/service/CDOLockStrategyProviderService.java b/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/service/CDOLockStrategyProviderService.java deleted file mode 100644 index ad34684a1..000000000 --- a/plugins/org.eclipse.emf.eef.cdo.runtime/src/org/eclipse/emf/eef/cdo/runtime/service/CDOLockStrategyProviderService.java +++ /dev/null @@ -1,120 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.cdo.runtime.service; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IConfigurationElement; -import org.eclipse.core.runtime.IExtension; -import org.eclipse.core.runtime.IExtensionPoint; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.eef.cdo.runtime.EEFCDORuntimePlugin; -import org.eclipse.emf.eef.cdo.runtime.provider.ICDOLockStrategyProvider; - -/** - * Service that manage all the registered - * {@link ICDOLockStrategyProvider}. - * - * @author Nathalie Lepine - */ -public class CDOLockStrategyProviderService { - - /** - * The extension name. - */ - public static final String EXTENSION_NAME = "CDOLockStrategyProvider"; //$NON-NLS-1$ - - /** - * The extension's element name. - */ - private static final String EXTENSION_ELEMENT_NAME = "CDOLockStrategyProvider"; //$NON-NLS-1$ - - /** - * The element's attribute name. - */ - private static final String EXTENSION_ATTRIBUTE_NAME = "policyClass"; //$NON-NLS-1$ - - /** - * A singleton for the service. - */ - private static CDOLockStrategyProviderService instance = new CDOLockStrategyProviderService(); - - /** - * The factory where the providers are registered. - */ - private List cdoLockStrategyProviders; - - /** - * Default constructor. - */ - private CDOLockStrategyProviderService() { - cdoLockStrategyProviders = new ArrayList(); - configureService(); - } - - /** - * Singleton constructor. - * - * @return the Singleton instance - */ - public static CDOLockStrategyProviderService getInstance() { - return instance; - } - - /** - * @return all the registered policies - */ - public List getProviders() { - return cdoLockStrategyProviders; - } - - /** - * Register a listener. - * - * @param lockStrategy - * ICDOLockStrategyProvider - */ - public void register(ICDOLockStrategyProvider lockStrategy) { - cdoLockStrategyProviders.add(lockStrategy); - } - - /** - * Load all the providers registered by extension point. - */ - private void configureService() { - IExtensionPoint extensionPoint = Platform.getExtensionRegistry() - .getExtensionPoint(EEFCDORuntimePlugin.PLUGIN_ID, - EXTENSION_NAME); - - IExtension[] extensions = extensionPoint.getExtensions(); - for (int extensionIndex = 0; extensionIndex < extensions.length; extensionIndex++) { - IExtension extension = extensions[extensionIndex]; - IConfigurationElement[] configurationElements = extension - .getConfigurationElements(); - for (int i = 0; i < configurationElements.length; i++) { - IConfigurationElement cfg = configurationElements[i]; - - if (EXTENSION_ELEMENT_NAME.equals(cfg.getName())) { - try { - register((ICDOLockStrategyProvider) cfg - .createExecutableExtension(EXTENSION_ATTRIBUTE_NAME)); - } catch (CoreException e) { - e.printStackTrace(); - } - } - } - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/.classpath b/plugins/org.eclipse.emf.eef.codegen.ecore/.classpath deleted file mode 100644 index ed5ee00d9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/.classpath +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/.gitignore b/plugins/org.eclipse.emf.eef.codegen.ecore/.gitignore deleted file mode 100644 index 011f45878..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/.project b/plugins/org.eclipse.emf.eef.codegen.ecore/.project deleted file mode 100644 index ab17f2a89..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/.project +++ /dev/null @@ -1,48 +0,0 @@ - - - org.eclipse.emf.eef.codegen.ecore - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - org.eclipse.acceleo.ide.ui.acceleoBuilder - - - compliance - pragmatic - - - resource.kind - binary - - - - - org.eclipse.pde.api.tools.apiAnalysisBuilder - - - - - - org.eclipse.acceleo.ide.ui.acceleoNature - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - org.eclipse.pde.api.tools.apiAnalysisNature - - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.codegen.ecore/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index d1c0bf949..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,6 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.codegen.ecore/META-INF/MANIFEST.MF deleted file mode 100644 index bf3b3840d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/META-INF/MANIFEST.MF +++ /dev/null @@ -1,27 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: Acceleo Ecore Module Runtime Plug-in -Bundle-SymbolicName: org.eclipse.emf.eef.codegen.ecore;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Activator: org.eclipse.emf.eef.codegen.ecore.EMFCodegenPlugin -Bundle-Vendor: Eclipse Modeling Project -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.emf.codegen;bundle-version="2.4.0", - org.eclipse.emf.codegen.ecore;bundle-version="2.4.0", - org.eclipse.emf.ecore;bundle-version="2.4.0", - org.eclipse.emf.ecore.xmi;bundle-version="2.4.0", - org.eclipse.ocl;bundle-version="1.2.0", - org.eclipse.ocl.ecore;bundle-version="1.2.0", - org.eclipse.acceleo.model;bundle-version="3.1.0", - org.eclipse.acceleo.engine;bundle-version="3.1.0", - org.eclipse.core.resources;bundle-version="3.4.0", - org.eclipse.ui;bundle-version="3.4.0", - org.eclipse.ui.ide;bundle-version="3.4.0", - org.eclipse.acceleo.parser;bundle-version="3.1.0";resolution:=optional, - org.eclipse.emf.eef.codegen.launcher;bundle-version="1.1.0" -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Bundle-ActivationPolicy: lazy -Eclipse-LazyStart: true -Export-Package: org.eclipse.emf.eef.codegen.ecore.main, - org.eclipse.emf.eef.codegen.ecore.services, - org.eclipse.emf.eef.codegen.ecore.services.wrappers diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/about.html b/plugins/org.eclipse.emf.eef.codegen.ecore/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/build.acceleo b/plugins/org.eclipse.emf.eef.codegen.ecore/build.acceleo deleted file mode 100644 index 3c0291aa9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/build.acceleo +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/build.properties b/plugins/org.eclipse.emf.eef.codegen.ecore/build.properties deleted file mode 100644 index 8e1f0b0d0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/build.properties +++ /dev/null @@ -1,25 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/,\ - src-custom/,\ - src-build/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ - build.acceleo,\ - about.html,\ - templates/edit/CreateChild.gif,\ - templates/edit/Item.gif,\ - templates/editor/ModelFile.gif,\ - templates/editor/NewModel.gif -customBuildCallbacks = build.acceleo -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/plugin.xml b/plugins/org.eclipse.emf.eef.codegen.ecore/plugin.xml deleted file mode 100644 index f2e9f15d6..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/plugin.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/pom.xml b/plugins/org.eclipse.emf.eef.codegen.ecore/pom.xml deleted file mode 100644 index ac0026328..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/pom.xml +++ /dev/null @@ -1,55 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf - org.eclipse.emf.eef.codegen.ecore - 1.5.2-SNAPSHOT - eclipse-plugin - - EEF Ecore Codegen Plug-in - - - - - org.codehaus.mojo - exec-maven-plugin - 1.1.1 - - - compile - - java - - - org.eclipse.emf.eef.codegen.ecore.EEFCodegenEcoreCompiler - - ${basedir}/src/ - ${basedir}/target/classes - true - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src-build/org/eclipse/emf/eef/codegen/ecore/EEFCodegenEcoreCompiler.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src-build/org/eclipse/emf/eef/codegen/ecore/EEFCodegenEcoreCompiler.java deleted file mode 100644 index cdf9d2ae7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src-build/org/eclipse/emf/eef/codegen/ecore/EEFCodegenEcoreCompiler.java +++ /dev/null @@ -1,148 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore; - -import java.io.File; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.Map; - -import org.eclipse.acceleo.common.IAcceleoConstants; -import org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; - -/** - * The Acceleo Stand Alone compiler. - * - * @author Stephane Begaudeau - * @since 3.1 - */ -public class EEFCodegenEcoreCompiler extends AbstractAcceleoCompiler { - - /** - * The entry point of the compilation. - * - * @param args - * The arguments used in the compilation: the source folder, the output folder, a boolean - * indicating if we should use binary resource serialization and finally the dependencies of - * the project. - */ - public static void main(String[] args) { - if (args.length < 3) { - throw new IllegalArgumentException("Missing parameters"); //$NON-NLS-1$ - } - EEFCodegenEcoreCompiler acceleoCompiler = new EEFCodegenEcoreCompiler(); - acceleoCompiler.setSourceFolder(args[0]); - acceleoCompiler.setOutputFolder(args[1]); - acceleoCompiler.setBinaryResource(Boolean.valueOf(args[2]).booleanValue()); - if (args.length == 4 && args[3] != null && !"".equals(args[3])) { //$NON-NLS-1$ - acceleoCompiler.setDependencies(args[3]); - } - acceleoCompiler.doCompile(new BasicMonitor()); - } - - /** - * Launches the compilation of the mtl files in the generator. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#doCompile(org.eclipse.emf.common.util.Monitor) - */ - @Override - public void doCompile(Monitor monitor) { - super.doCompile(monitor); - } - - /** - * Registers the packages of the metamodels used in the generator. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#registerPackages() - */ - @Override - protected void registerPackages() { - super.registerPackages(); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), - org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE); - } - - /** - * Registers the resource factories. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#registerResourceFactories() - */ - @Override - protected void registerResourceFactories() { - super.registerResourceFactories(); - /* - * If you want to add other resource factories, for example if your metamodel uses a specific - * serialization: - * org.eclipse.emf.ecore.resource.Resource.Factory.Registry.getExtensionToFactoryMap().put - * (UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - */ - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#computeDependencies(java.util.List, - * java.util.Map) - */ - protected void computeDependencies(List dependenciesURIs, Map mapURIs) { - // USED TO FIX COMPILER WITH TYCHO - Iterator identifiersIt = dependenciesIDs.iterator(); - for (Iterator dependenciesIt = dependencies.iterator(); dependenciesIt.hasNext() - && identifiersIt.hasNext();) { - File requiredFolder = dependenciesIt.next(); - String identifier = identifiersIt.next(); - if (requiredFolder != null && requiredFolder.exists() && requiredFolder.isDirectory()) { - List emtlFiles = new ArrayList(); - members(emtlFiles, requiredFolder, IAcceleoConstants.EMTL_FILE_EXTENSION); - for (File emtlFile : emtlFiles) { - String requiredFolderAbsolutePath = requiredFolder.getAbsolutePath(); - if (requiredFolderAbsolutePath.endsWith("target/classes")) { - // using tycho - String[] splited = requiredFolderAbsolutePath.split("\\/"); - StringBuffer buf = new StringBuffer(requiredFolderAbsolutePath.length()); - for (int i = 0; i < splited.length - 3; i++) { - buf.append(splited[i]); - buf.append("/"); - } - requiredFolderAbsolutePath = buf.toString(); - String emtlAbsolutePath = emtlFile.getAbsolutePath(); - URI emtlFileURI = URI.createFileURI(emtlAbsolutePath); - dependenciesURIs.add(emtlFileURI); - String emtlModifiedPath = emtlAbsolutePath.replaceAll("target\\/|classes\\/", ""); - IPath relativePath = new Path(emtlModifiedPath.substring(requiredFolderAbsolutePath - .length())); - URI relativeURI = URI.createPlatformPluginURI(relativePath.toString(), false); - mapURIs.put(emtlFileURI, relativeURI); - } else { - // normal behavior - String emtlAbsolutePath = emtlFile.getAbsolutePath(); - URI emtlFileURI = URI.createFileURI(emtlAbsolutePath); - dependenciesURIs.add(emtlFileURI); - IPath relativePath = new Path(identifier).append(emtlAbsolutePath - .substring(requiredFolderAbsolutePath.length())); - mapURIs.put(emtlFileURI, URI.createPlatformPluginURI(relativePath.toString(), false)); - } - } - } - } - } -} - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/EMFCodegenPlugin.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/EMFCodegenPlugin.java deleted file mode 100644 index e55c28a95..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/EMFCodegenPlugin.java +++ /dev/null @@ -1,105 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore; - -import java.io.File; -import java.io.FileOutputStream; -import java.io.IOException; -import java.io.OutputStream; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.ui.plugin.AbstractUIPlugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle. - * - * @author Stephane Bouchet - */ -public class EMFCodegenPlugin extends AbstractUIPlugin { - - /** - * The plug-in ID. - */ - public static final String PLUGIN_ID = "org.eclipse.emf.eef.codegen.ecore"; - - /** - * The shared instance. - */ - private static EMFCodegenPlugin plugin; - - /** - * The constructor. - */ - public EMFCodegenPlugin() { - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.core.runtime.Plugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.core.runtime.Plugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance. - * - * @return the shared instance - */ - public static EMFCodegenPlugin getDefault() { - return plugin; - } - - public void logError(Exception e) { - IStatus status = new Status(IStatus.ERROR, PLUGIN_ID, e.getMessage(), e); - getLog().log(status); - } - - public void logWarning(Exception e) { - IStatus status = new Status(IStatus.WARNING, PLUGIN_ID, e.getMessage(), e); - getLog().log(status); - } - - public void createGIF(byte[] result, Path itemIconFilePath) { - OutputStream outputStream; - try { - IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(itemIconFilePath); - File f = new File(file.getLocation().toString()); - if (!f.exists()) { - f.getParentFile().mkdirs(); - f.createNewFile(); - - outputStream = new FileOutputStream(f); - outputStream.write(result); - outputStream.close(); - } - } catch (IOException e) { - EMFCodegenPlugin.getDefault().logError(e); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFCodeAction.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFCodeAction.java deleted file mode 100644 index 31bfa6915..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFCodeAction.java +++ /dev/null @@ -1,107 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.ui.launcher; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IWorkspace; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.core.runtime.jobs.Job; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.eef.codegen.flow.Workflow; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.IActionDelegate; -import org.eclipse.ui.IObjectActionDelegate; -import org.eclipse.ui.IWorkbenchPart; - -/** - * @author Stephane Bouchet - */ -public abstract class GenerateEMFCodeAction implements IObjectActionDelegate { - - protected Shell shell; - - protected List emfGenModels; - - protected IWorkspace workspace = ResourcesPlugin.getWorkspace(); - - public GenerateEMFCodeAction() { - emfGenModels = new ArrayList(); - } - - /** - * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart) - */ - public void setActivePart(IAction action, IWorkbenchPart targetPart) { - shell = targetPart.getSite().getShell(); - } - - /** - * @see IActionDelegate#run(IAction) - */ - public void run(IAction action) { - if (emfGenModels != null) { - final Workflow flow = initEMFGenFlow(); - flow.prepare(); - Job job = new Job("EEF architecture generation") { - @Override - protected IStatus run(IProgressMonitor monitor) { - flow.execute(monitor); - monitor.done(); - return Status.OK_STATUS; - } - - }; - job.setUser(true); - job.schedule(); - } - } - - /** - * @return the flow to execute in order to generate EMF code. - */ - protected abstract Workflow initEMFGenFlow(); - - /** - * @see IActionDelegate#selectionChanged(IAction, ISelection) - */ - public void selectionChanged(IAction action, ISelection selection) { - emfGenModels.clear(); - if (selection instanceof StructuredSelection) { - StructuredSelection sSelection = (StructuredSelection)selection; - for (Object selectedElement : sSelection.toList()) { - if (selectedElement instanceof GenModel) { - emfGenModels.add((GenModel)selectedElement); - } - } - - } - } - - protected IProject extractProject(String sPath) { - IPath path = new Path(sPath); - if (path.isEmpty()) { - return null; - } - return workspace.getRoot().getProject(path.segment(0)); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFEditCodeAction.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFEditCodeAction.java deleted file mode 100644 index 730384341..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFEditCodeAction.java +++ /dev/null @@ -1,160 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.ui.launcher; - -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.core.runtime.SubProgressMonitor; -import org.eclipse.emf.codegen.ecore.Generator; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.generator.GenBaseGeneratorAdapter; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.UniqueEList; -import org.eclipse.emf.eef.codegen.ecore.EMFCodegenPlugin; -import org.eclipse.emf.eef.codegen.ecore.main.GenEdit; -import org.eclipse.emf.eef.codegen.ecore.util.EEFGeneratorAdapter; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.Workflow; - -/** - * @author Goulwen Le Fur - */ -public class GenerateEMFEditCodeAction extends GenerateEMFCodeAction { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.ecore.ui.launcher.GenerateEMFCodeAction#initEMFGenFlow() - */ - protected Workflow initEMFGenFlow() { - final Workflow flow = new Workflow("Generate EMF edit code ", shell); - for (final GenModel emfGenModel : emfGenModels) { - String s1 = "Generate EMF Edit code for " + emfGenModel.eResource().getURI().lastSegment(); - // use this once we can add acceleo inside emf generator - // Step emfEditCode = new GenerateEMFEditCode(s, - // emfGenModel); - // flow.addStep(s, emfEditCode); - flow.addStep(s1, new Step("EMF EDIT") { - - @Override - public IStatus execute(IProgressMonitor monitor) { - // create the edit project - IProject editProject = extractProject(emfGenModel.getEditProjectDirectory()); - if (editProject == null) { - return Status.OK_STATUS; - } - IProject modelProject = workspace.getRoot().getProject( - emfGenModel.getModelProjectDirectory()); - List referencedProjects = new UniqueEList(); - referencedProjects.add(modelProject); - if (!workspace.getRoot().exists(editProject.getFullPath())) { - editProject = Generator.createEMFProject(new Path(emfGenModel.getEditDirectory()), null, - referencedProjects, - new SubProgressMonitor(monitor, IProgressMonitor.UNKNOWN), - Generator.EMF_EDIT_PROJECT_STYLE | Generator.EMF_PLUGIN_PROJECT_STYLE); - } else if (!editProject.isAccessible()) { - try { - editProject.open(monitor); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - } - // generate using acceleo - List args = new ArrayList(); - File editDirectory = editProject.getLocation().toFile(); - try { - GenEdit generator = new GenEdit(emfGenModel, editDirectory, args); - generator.doGenerate(BasicMonitor.toMonitor(new SubProgressMonitor(monitor, - IProgressMonitor.UNKNOWN))); - } catch (IOException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - return Status.OK_STATUS; - } - }); - - if (emfGenModel.isCodeFormatting()) { - // TODO Ne rafraichir avant le formatage que si le folder demand� n'est pas accessible - // FIXME IMPORTANT !!! Virer le double refresh, fait � l'arrache par LDE qui sait pas comment faire autrement - // TODO D�terminer pourquoi il reste des diff�rences de formatage avec EMF - // TODO D�terminer pourquoi quand on fait clic-droit -> Source -> format sur le code g�n�r�, le code est modifi� - // (cas o� le projet vient d'�tre cr�� par exemple) - String s1b = "Refreshing workspace " + emfGenModel.eResource().getURI().toString(); - flow.addStep(s1b, new Step("REFRESH") { - - @Override - public IStatus execute(IProgressMonitor monitor) { - // refresh edit project - IProject modelProject = extractProject(emfGenModel.getEditProjectDirectory()); - if (modelProject == null) { - return Status.OK_STATUS; - } - try { - if (!modelProject.isOpen()) { - modelProject.open(monitor); - } - modelProject.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - return Status.OK_STATUS; - } - }); - - String s2prime = "Formatting generated files"; - flow.addStep(s2prime, new Step(s2prime) { - - @Override - public IStatus execute(IProgressMonitor monitor) { - EEFGeneratorAdapter eefGen = new EEFGeneratorAdapter(); - eefGen.generate(emfGenModel, GenBaseGeneratorAdapter.EDIT_PROJECT_TYPE, - BasicMonitor.toMonitor(new SubProgressMonitor(monitor, IProgressMonitor.UNKNOWN))); - return Status.OK_STATUS; - } - }); - } - - String s3 = "Refresh workspace " + emfGenModel.eResource().getURI().toString(); - flow.addStep(s3, new Step("REFRESH") { - - @Override - public IStatus execute(IProgressMonitor monitor) { - // refresh edit - IProject editProject = extractProject(emfGenModel.getEditProjectDirectory()); - if (editProject == null) { - return Status.OK_STATUS; - } - try { - if (!editProject.isOpen()) { - editProject.open(monitor); - } - editProject.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - return Status.OK_STATUS; - } - }); - } - return flow; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFEditorCodeAction.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFEditorCodeAction.java deleted file mode 100644 index adc61392f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFEditorCodeAction.java +++ /dev/null @@ -1,159 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.ui.launcher; - -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.core.runtime.SubProgressMonitor; -import org.eclipse.emf.codegen.ecore.Generator; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.generator.GenBaseGeneratorAdapter; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.UniqueEList; -import org.eclipse.emf.eef.codegen.ecore.EMFCodegenPlugin; -import org.eclipse.emf.eef.codegen.ecore.main.GenEditor; -import org.eclipse.emf.eef.codegen.ecore.util.EEFGeneratorAdapter; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.Workflow; - -/** - * @author Goulwen Le Fur - */ -public class GenerateEMFEditorCodeAction extends GenerateEMFCodeAction { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.ecore.ui.launcher.GenerateEMFCodeAction#initEMFGenFlow() - */ - protected Workflow initEMFGenFlow() { - final Workflow flow = new Workflow("Generate EMF editor code ", shell); - for (final GenModel emfGenModel : emfGenModels) { - String s2 = "Generate EMF Editor code for " + emfGenModel.eResource().getURI().toString(); - flow.addStep(s2, new Step("EMF EDITOR") { - - @Override - public IStatus execute(IProgressMonitor monitor) { - // create the editor project - IProject editorProject = extractProject(emfGenModel.getEditorProjectDirectory()); - if (editorProject == null) { - return Status.OK_STATUS; - } - List referencedProjects = new UniqueEList(); - IProject modelProject = workspace.getRoot().getProject( - emfGenModel.getModelProjectDirectory()); - IProject editProject = workspace.getRoot().getProject( - emfGenModel.getEditProjectDirectory()); - referencedProjects.add(modelProject); - referencedProjects.add(editProject); - if (!workspace.getRoot().exists(editorProject.getFullPath())) { - editorProject = Generator.createEMFProject(new Path(emfGenModel.getEditorDirectory()), editorProject - .getLocation(), referencedProjects, new SubProgressMonitor(monitor, - IProgressMonitor.UNKNOWN), Generator.EMF_EDITOR_PROJECT_STYLE - | Generator.EMF_PLUGIN_PROJECT_STYLE); - } else if (!editorProject.isAccessible()) { - try { - editorProject.open(monitor); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - } - // generate using acceleo - List args = new ArrayList(); - File editorDirectory = editorProject.getLocation().toFile(); - try { - GenEditor generator = new GenEditor(emfGenModel, editorDirectory, args); - generator.doGenerate(BasicMonitor.toMonitor(new SubProgressMonitor(monitor, - IProgressMonitor.UNKNOWN))); - } catch (IOException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - return Status.OK_STATUS; - } - }); - - if (emfGenModel.isCodeFormatting()) { - // TODO Ne rafraichir avant le formatage que si le folder demand� n'est pas accessible - // FIXME IMPORTANT !!! Virer le double refresh, fait � l'arrache par LDE qui sait pas comment faire autrement - // TODO D�terminer pourquoi il reste des diff�rences de formatage avec EMF - // TODO D�terminer pourquoi quand on fait clic-droit -> Source -> format sur le code g�n�r�, le code est modifi� - // (cas o� le projet vient d'�tre cr�� par exemple) - String s1b = "Refreshing workspace " + emfGenModel.eResource().getURI().toString(); - flow.addStep(s1b, new Step("REFRESH") { - - @Override - public IStatus execute(IProgressMonitor monitor) { - // refresh editor project - IProject modelProject = extractProject(emfGenModel.getEditorProjectDirectory()); - if (modelProject == null) { - return Status.OK_STATUS; - } - try { - if (!modelProject.isOpen()) { - modelProject.open(monitor); - } - modelProject.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - return Status.OK_STATUS; - } - }); - - String s2prime = "Formatting generated files"; - flow.addStep(s2prime, new Step(s2prime) { - - @Override - public IStatus execute(IProgressMonitor monitor) { - EEFGeneratorAdapter eefGen = new EEFGeneratorAdapter(); - eefGen.generate(emfGenModel, GenBaseGeneratorAdapter.EDITOR_PROJECT_TYPE, - BasicMonitor.toMonitor(new SubProgressMonitor(monitor, IProgressMonitor.UNKNOWN))); - return Status.OK_STATUS; - } - }); - } - - String s3 = "Refresh workspace " + emfGenModel.eResource().getURI().toString(); - flow.addStep(s3, new Step("REFRESH") { - - @Override - public IStatus execute(IProgressMonitor monitor) { - // refresh editor - IProject editorProject = extractProject(emfGenModel.getEditorProjectDirectory()); - if (editorProject == null) { - return Status.OK_STATUS; - } - try { - if (!editorProject.isOpen()) { - editorProject.open(monitor); - } - editorProject.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - return Status.OK_STATUS; - } - }); - } - return flow; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFModelCodeAction.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFModelCodeAction.java deleted file mode 100644 index 1db5056f0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/ui/launcher/GenerateEMFModelCodeAction.java +++ /dev/null @@ -1,153 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.ui.launcher; - -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.core.runtime.SubProgressMonitor; -import org.eclipse.emf.codegen.ecore.Generator; -import org.eclipse.emf.codegen.ecore.genmodel.generator.GenBaseGeneratorAdapter; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.UniqueEList; -import org.eclipse.emf.eef.codegen.ecore.EMFCodegenPlugin; -import org.eclipse.emf.eef.codegen.ecore.main.GenModel; -import org.eclipse.emf.eef.codegen.ecore.util.EEFGeneratorAdapter; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.Workflow; - -/** - * @author Goulwen Le Fur - */ -public class GenerateEMFModelCodeAction extends GenerateEMFCodeAction { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.ecore.ui.launcher.GenerateEMFCodeAction#initEMFGenFlow() - */ - protected Workflow initEMFGenFlow() { - final Workflow flow = new Workflow("Generate EMF model code ", shell); - for (final org.eclipse.emf.codegen.ecore.genmodel.GenModel emfGenModel : emfGenModels) { - String s2 = "Generate EMF Model code for " + emfGenModel.eResource().getURI().toString(); - flow.addStep(s2, new Step("EMF MODEL") { - - @Override - public IStatus execute(IProgressMonitor monitor) { - // create the model project - IProject modelProject = extractProject(emfGenModel.getModelProjectDirectory()); - if (modelProject == null) { - return Status.OK_STATUS; - } - List referencedProjects = new UniqueEList(); - if (!workspace.getRoot().exists(modelProject.getFullPath())) { - // TODO Manage the case when the model project has been deleted from the workspace but is still present on disk ? - modelProject = Generator.createEMFProject(new Path(emfGenModel.getModelDirectory()), modelProject - .getLocation(), referencedProjects, new SubProgressMonitor(monitor, - IProgressMonitor.UNKNOWN), Generator.EMF_MODEL_PROJECT_STYLE - | Generator.EMF_PLUGIN_PROJECT_STYLE); - } else if (!modelProject.isAccessible()) { - try { - modelProject.open(monitor); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - } - // generate using acceleo - List args = new ArrayList(); - File modelDirectory = modelProject.getLocation().toFile(); - try { - GenModel generator = new GenModel(emfGenModel, modelDirectory, args); - generator.doGenerate(BasicMonitor.toMonitor(new SubProgressMonitor(monitor, - IProgressMonitor.UNKNOWN))); - } catch (IOException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - return Status.OK_STATUS; - } - }); - - if (emfGenModel.isCodeFormatting()) { - // TODO Ne rafraichir avant le formatage que si le folder demand� n'est pas accessible - // FIXME IMPORTANT !!! Virer le double refresh, fait � l'arrache par LDE qui sait pas comment faire autrement - // TODO D�terminer pourquoi il reste des diff�rences de formatage avec EMF - // TODO D�terminer pourquoi quand on fait clic-droit -> Source -> format sur le code g�n�r�, le code est modifi� - // (cas o� le projet vient d'�tre cr�� par exemple) - String s1b = "Refreshing workspace " + emfGenModel.eResource().getURI().toString(); - flow.addStep(s1b, new Step("REFRESH") { - - @Override - public IStatus execute(IProgressMonitor monitor) { - // refresh model project - IProject modelProject = extractProject(emfGenModel.getModelProjectDirectory()); - if (modelProject == null) { - return Status.OK_STATUS; - } - try { - if (!modelProject.isOpen()) { - modelProject.open(monitor); - } - modelProject.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - return Status.OK_STATUS; - } - }); - - String s2prime = "Formatting generated files"; - flow.addStep(s2prime, new Step(s2prime) { - - @Override - public IStatus execute(IProgressMonitor monitor) { - EEFGeneratorAdapter eefGen = new EEFGeneratorAdapter(); - eefGen.generate(emfGenModel, GenBaseGeneratorAdapter.MODEL_PROJECT_TYPE, - BasicMonitor.toMonitor(new SubProgressMonitor(monitor, IProgressMonitor.UNKNOWN))); - return Status.OK_STATUS; - } - }); - } - - String s3 = "Refreshing workspace " + emfGenModel.eResource().getURI().toString(); - flow.addStep(s3, new Step("REFRESH") { - - @Override - public IStatus execute(IProgressMonitor monitor) { - // refresh model project - IProject modelProject = extractProject(emfGenModel.getModelProjectDirectory()); - if (modelProject == null) { - return Status.OK_STATUS; - } - try { - if (!modelProject.isOpen()) { - modelProject.open(monitor); - } - modelProject.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EMFCodegenPlugin.PLUGIN_ID, e.getMessage(), e); - } - return Status.OK_STATUS; - } - }); - } - return flow; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/util/EEFGeneratorAdapter.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/util/EEFGeneratorAdapter.java deleted file mode 100644 index d125c17bf..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src-custom/org/eclipse/emf/eef/codegen/ecore/util/EEFGeneratorAdapter.java +++ /dev/null @@ -1,193 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.util; - -import java.io.ByteArrayInputStream; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.IResourceVisitor; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.codegen.ecore.generator.AbstractGeneratorAdapter; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.codegen.ecore.genmodel.generator.GenBaseGeneratorAdapter; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; - -/** - * @author Goulwen Le Fur - */ -public class EEFGeneratorAdapter extends AbstractGeneratorAdapter { - - private static final String JAVA_EXT_FILE = "java"; - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.codegen.ecore.generator.AbstractGeneratorAdapter#canGenerate(java.lang.Object, - * java.lang.Object) - */ - @Override - public boolean canGenerate(Object object, Object projectType) { - return EMFPlugin.IS_ECLIPSE_RUNNING && object instanceof GenModel; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.codegen.ecore.generator.AbstractGeneratorAdapter#doGenerate(java.lang.Object, - * java.lang.Object, org.eclipse.emf.common.util.Monitor) - */ - @Override - protected Diagnostic doGenerate(Object object, Object projectType, - Monitor monitor) throws Exception { - GenModel genmodel = (GenModel) object; - IFolder folder = null; - final IProgressMonitor progressMonitor = BasicMonitor - .toIProgressMonitor(monitor); - if (projectType == GenBaseGeneratorAdapter.MODEL_PROJECT_TYPE) { - final Object codeFormatter = createCodeFormatter(null, - URI.createPlatformResourceURI(genmodel.getModelDirectory(), - true)); - folder = ResourcesPlugin.getWorkspace().getRoot() - .getFolder(new Path(genmodel.getModelDirectory())); // path); - if (folder != null && folder.isAccessible()) { - folder.accept(new ResourceVisitorFormatter(codeFormatter, - progressMonitor)); - } - } else if (projectType == GenBaseGeneratorAdapter.EDIT_PROJECT_TYPE) { - final Object codeFormatter = createCodeFormatter(null, - URI.createPlatformResourceURI(genmodel.getEditDirectory(), - true)); - folder = ResourcesPlugin.getWorkspace().getRoot() - .getFolder(new Path(genmodel.getEditDirectory())); - if (folder != null && folder.isAccessible()) { - folder.accept(new ResourceVisitorFormatter(codeFormatter, - progressMonitor)); - } - } else if (projectType == GenBaseGeneratorAdapter.EDITOR_PROJECT_TYPE) { - final Object codeFormatter = createCodeFormatter(null, - URI.createPlatformResourceURI( - genmodel.getEditorDirectory(), true)); - folder = ResourcesPlugin.getWorkspace().getRoot() - .getFolder(new Path(genmodel.getEditorDirectory())); - if (folder != null && folder.isAccessible()) { - folder.accept(new ResourceVisitorFormatter(codeFormatter, - progressMonitor)); - } - } - return Diagnostic.OK_INSTANCE; - } - - /** - * @param genmodel - * @param genPack - * @return - */ - protected IPath buildModelPath(GenModel genmodel, GenPackage genPack) { - String pathStr = genmodel.getModelDirectory() + "/" - + genPack.getQualifiedPackageName().replaceAll("\\.", "/"); - IPath path = new Path(pathStr); - return path; - } - - /** - * @param genmodel - * @param genPack - * @return - */ - protected IPath buildProviderPath(GenModel genmodel, GenPackage genPack) { - String pathStr = genmodel.getEditDirectory(); - if (genPack.getProviderPackageName() != null - && !genPack.getProviderPackageName().equals("")) { - pathStr += "/" - + genPack.getProviderPackageName().replaceAll("\\.", "/"); - } - IPath path = new Path(pathStr); - return path; - } - - /** - * @param genmodel - * @param genPack - * @return - */ - protected IPath buildPresentationPath(GenModel genmodel, GenPackage genPack) { - String pathStr = genmodel.getEditorDirectory(); - if (genPack.getPresentationPackageName() != null - && !genPack.getPresentationPackageName().equals("")) { - pathStr += "/" - + genPack.getPresentationPackageName().replaceAll("\\.", - "/"); - } - IPath path = new Path(pathStr); - return path; - } - - /** - * IResourceVisitor responsible to format all java code in a given folder. - * - * @author Goulwen Le Fur - */ - private final class ResourceVisitorFormatter implements IResourceVisitor { - private final Object codeFormatter; - - private final IProgressMonitor progressMonitor; - - private ResourceVisitorFormatter(Object codeFormatter, - IProgressMonitor progressMonitor) { - this.codeFormatter = codeFormatter; - this.progressMonitor = progressMonitor; - } - - public boolean visit(IResource resource) throws CoreException { - try { - if (resource instanceof IFile - && ((IFile) resource).getFileExtension().equals( - JAVA_EXT_FILE)) { - formatFile((IFile) resource, codeFormatter, progressMonitor); - } - return true; - } catch (Exception e) { - return false; - } - } - - /** - * @param file - * @param codeFormatter - * @param progressMonitor - * @throws Exception - */ - private void formatFile(IFile file, Object codeFormatter, - IProgressMonitor progressMonitor) throws Exception { - URI createPlatformResourceURI = URI.createURI(file.getFullPath() - .toString(), true); - final String contentsStr = getContents(createPlatformResourceURI, - null); - String formatedContentsStr = formatCode(contentsStr, codeFormatter); - ByteArrayInputStream formatedContents = new ByteArrayInputStream( - formatedContentsStr.getBytes()); - file.setContents(formatedContents, true, true, progressMonitor); - formatedContents.close(); - } - - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/ItemProvider.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/ItemProvider.mtl deleted file mode 100644 index 751895ecf..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/ItemProvider.mtl +++ /dev/null @@ -1,505 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module ItemProvider('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenTypedElement /] - -[template public ItemProvider(genClass : GenClass) { genPackage : GenPackage = genClass.genPackage ; genModel : GenModel = genPackage.genModel ; packageName : String = genPackage.getProviderPackageName() ; className : String = genClass.getProviderClassName() }] -[genModel.initializeImportManager(packageName, className)/] -[file (genModel.editPath(packageName, className), false, 'UTF-8')] -[includeHeader()/] -package [packageName/]; - -[genModel.addImports()/] -[let content : String = genModel.fileContent(genPackage, genClass, className)] -[genModel.genSortedImports()/] - -[content/] -[/let] -[/file] -[/template] - -[template public addImports (genModel : GenModel) post (trim())] -[genModel.addImport('org.eclipse.emf.common.notify.AdapterFactory')/] -[genModel.addImport('org.eclipse.emf.common.notify.Notification')/] -[genModel.addImport('org.eclipse.emf.edit.provider.IEditingDomainItemProvider')/] -[genModel.addImport('org.eclipse.emf.edit.provider.IItemLabelProvider')/] -[genModel.addImport('org.eclipse.emf.edit.provider.IItemPropertySource')/] -[genModel.addImport('org.eclipse.emf.edit.provider.IStructuredItemContentProvider')/] -[genModel.addImport('org.eclipse.emf.edit.provider.ITreeItemContentProvider')/] -[/template] - -[template public fileContent(genModel : GenModel, genPackage : GenPackage, genClass : GenClass, className : String)] -/** - * This is the item provider adapter for a {@link [genClass.getQualifiedInterfaceName()/]} object. - * - * - * @generated - */ -public class [className/] - extends [if (not genClass.getProviderBaseClassName().oclIsUndefined())][genClass.getProviderBaseClassName()/][else][genModel.getImportedName('org.eclipse.emf.edit.provider.ItemProviderAdapter')/][/if] - implements [for (string : String | genPackage.getProviderSupportedTypes()) separator (', ')][genModel.getImportedName(string)/][/for] -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public [genClass.getProviderClassName()/](AdapterFactory adapterFactory) - { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public [genModel._List()/] getPropertyDescriptors(Object object) - { - if (itemPropertyDescriptors == null) - { - super.getPropertyDescriptors(object); - -[for (genFeature : GenFeature | genClass.getPropertyFeatures())] - add[genFeature.getCapName()/]PropertyDescriptor(object); -[/for] - } - return itemPropertyDescriptors; - } - -[for (genFeature : GenFeature | genClass.getPropertyFeatures())] - /** - * This adds a property descriptor for the [genFeature.getFormattedName()/] feature. - * - * - * @generated - */ - protected void add[genFeature.getCapName()/]PropertyDescriptor(Object object) - { -[comment]<%@ include file="ItemProvider/addPropertyDescriptor.override.javajetinc" fail="alternative" %> -<%@ start %>[/comment] - itemPropertyDescriptors.add - (createItemPropertyDescriptor - ((([genModel.getImportedName('org.eclipse.emf.edit.provider.ComposeableAdapterFactory')/])adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_[genFeature.genClass.getName()/]_[genFeature.getName()/]_feature"),[genModel.getNonNLS()/] - [if (genFeature.propertyDescription.oclIsUndefined() or genFeature.propertyDescription.size() = 0)] - getString("_UI_PropertyDescriptor_description", "_UI_[genFeature.genClass.getName()/]_[genFeature.getName()/]_feature", "_UI_[genFeature.genClass.getName()/]_type"),[genModel.getNonNLS()/][genModel.getNonNLS(2)/][genModel.getNonNLS(3)/] - [else] - getString("_UI_[genFeature.genClass.getName()/]_[genFeature.getName()/]_description"),[genModel.getNonNLS()/] - [/if] - [genFeature.getQualifiedFeatureAccessor()/], - [if (genFeature.property = genmodel::GenPropertyKind::Editable)]true[else]false[/if], - [if (genFeature.propertyMultiLine)]true[else]false[/if], - [if (genFeature.propertySortChoices)]true[else]false[/if], - [if (genFeature.isReferenceType())] - null, - [else] - [genModel.getImportedName('org.eclipse.emf.edit.provider.ItemPropertyDescriptor')/].[genFeature.getPropertyImageName()/], - [/if] - [if (genFeature.propertyCategory.oclIsUndefined() or genFeature.propertyCategory.size() = 0)] - null, - [else] - getString("[genModel.getPropertyCategoryKey(genFeature.propertyCategory)/]"),[genModel.getNonNLS()/] - [/if] - [if (genFeature.propertyFilterFlags->isEmpty())] - null)); - [else] - new String[genModel.genSquareBrackets('')/] { - [genFeature.propertyFilterFlags.declareFilterFlag()->sep(',' + genModel.getLineDelimiter() + genModel.getNonNLS())/] - })); - [/if] -[comment]<%@ end %><%//ItemProvider/addPropertyDescriptor.override.javajetinc%>[/comment] - } - -[/for] -[if (genClass.getChildrenFeatures()->notEmpty())] - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public [genModel.getImportedName('java.util.Collection')/][if (genModel.useGenerics())][/if] getChildrenFeatures(Object object) - { - if (childrenFeatures == null) - { - super.getChildrenFeatures(object); -[for (genFeature : GenFeature | genClass.getChildrenFeatures())] - childrenFeatures.add([genFeature.getQualifiedFeatureAccessor()/]); -[/for] - } - return childrenFeatures; - } - -[if (genClass.getChildrenFeatures()->notEmpty())] - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected [genModel.getImportedName('org.eclipse.emf.ecore.EStructuralFeature')/] getChildFeature(Object object, Object child) - { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - -[/if] -[/if] -[if (genClass.needsHasChildrenMethodOverride())] - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public boolean hasChildren(Object object) - { - return hasChildren(object, [genModel.optimizedHasChildren/]); - } - -[/if] -[if (genClass.image)] - /** - * This returns [genClass.getName()/].gif. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Object getImage(Object object) - { - return overlayImage(object, getResourceLocator().getImage("full/obj16/[genClass.getName()/]"));[genModel.getNonNLS()/] - } - -[/if] -[comment <%if (genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE && !genModel.isCreationIcons()) {%>/] -[if (not genModel.creationIcons)] - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected boolean shouldComposeCreationImage() - { - return true; - } - -[/if] - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public String getText(Object object) - { -[comment]<%@ include file="ItemProvider/getText.override.javajetinc" fail="alternative" %> -<%@ start %>[/comment] -[if (genClass.isMapEntry())] - [genClass.getImportedInterfaceName()/][if (genModel.useGenerics())][/if] [genClass.getSafeUncapName()/] = ([genClass.getImportedInterfaceName()/][if (genModel.useGenerics())][/if])object; - [if (not genClass.getMapEntryKeyFeature().propertyMultiLine and not genClass.getMapEntryValueFeature().propertyMultiLine)] - return "" + [genClass.getSafeUncapName()/].getKey() + " -> " + [genClass.getSafeUncapName()/].getValue();[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - [else] - [if (genClass.getMapEntryKeyFeature().propertyMultiLine)] - String key = crop("" + [genClass.getSafeUncapName()/].getKey());[genModel.getNonNLS()/] - [else] - String key = "" + [genClass.getSafeUncapName()/].getKey();[genModel.getNonNLS()/] - [/if] - [if (genClass.getMapEntryValueFeature().propertyMultiLine)] - String value = crop("" + [genClass.getSafeUncapName()/].getValue());[genModel.getNonNLS()/] - [else] - String value = "" + [genClass.getSafeUncapName()/].getValue();[genModel.getNonNLS()/] - [/if] - return key + " -> " + value;[genModel.getNonNLS()/] - [/if] -[elseif (not genClass.labelFeature.oclIsUndefined())][let labelFeature : GenFeature = genClass.labelFeature] - [if (labelFeature.isPrimitiveType() and not labelFeature.genClass.dynamic and not labelFeature.isSuppressedGetVisibility())] - [genClass.getImportedInterfaceName()/][genClass.getInterfaceWildTypeArguments()/] [genClass.getSafeUncapName()/] = ([genClass.getImportedInterfaceName()/][genClass.getInterfaceWildTypeArguments()/])object; - return getString("_UI_[genClass.getName()/]_type") + " " + [genClass.getSafeUncapName()/].[genClass.labelFeature.getGetAccessor()/]();[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - [else] - [if (labelFeature.isStringType() and not labelFeature.genClass.dynamic and not labelFeature.isSuppressedGetVisibility())] - [if (labelFeature.propertyMultiLine)] - String label = crop((([genClass.getImportedInterfaceName()/][genClass.getInterfaceWildTypeArguments()/])object).[labelFeature.getGetAccessor()/]()); - [else] - String label = (([genClass.getImportedInterfaceName()/][genClass.getInterfaceWildTypeArguments()/])object).[labelFeature.getGetAccessor()/](); - [/if] - [else] - [if (labelFeature.isSuppressedGetVisibility() or labelFeature.genClass.dynamic)] - Object labelValue = ((EObject)object).eGet([labelFeature.getQualifiedFeatureAccessor()/]); - [else] - [labelFeature.getRawImportedType()/] labelValue = (([genClass.getImportedInterfaceName()/][genClass.getInterfaceWildTypeArguments()/])object).[labelFeature.getGetAccessor()/](); - [/if] - String label = labelValue == null ? null : labelValue.toString(); - [/if] - return label == null || label.length() == 0 ? - getString("_UI_[genClass.getName()/]_type") :[genModel.getNonNLS()/] - getString("_UI_[genClass.getName()/]_type") + " " + label;[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - [/if] - [/let] -[else] - return getString("_UI_[genClass.getName()/]_type");[genModel.getNonNLS()/] -[/if] -[comment]<%@ end %><%//ItemProvider/getText.override.javajetinc%>[/comment] - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void notifyChanged(Notification notification) - { - updateChildren(notification); -[if (genClass.getLabelNotifyFeatures()->notEmpty() or genClass.getContentNotifyFeatures()->notEmpty() or genClass.getLabelAndContentNotifyFeatures()->notEmpty())] - - switch (notification.getFeatureID([genClass.getRawImportedInterfaceName()/].class)) - { - [if (genClass.getLabelNotifyFeatures()->notEmpty())] - [for (genFeature : GenFeature | genClass.getLabelNotifyFeatures())] - case [genClass.getQualifiedFeatureID(genFeature)/]: - [/for] - fireNotifyChanged(new [genModel.getImportedName('org.eclipse.emf.edit.provider.ViewerNotification')/](notification, notification.getNotifier(), false, true)); - return; - [/if] - [if (genClass.getContentNotifyFeatures()->notEmpty())] - [for (genFeature : GenFeature | genClass.getContentNotifyFeatures())] - case [genClass.getQualifiedFeatureID(genFeature)/]: - [/for] - fireNotifyChanged(new [genModel.getImportedName('org.eclipse.emf.edit.provider.ViewerNotification')/](notification, notification.getNotifier(), true, false)); - return; - [/if] - [if (genClass.getLabelAndContentNotifyFeatures()->notEmpty())] - [for (genFeature : GenFeature | genClass.getLabelAndContentNotifyFeatures())] - case [genClass.getQualifiedFeatureID(genFeature)/]: - [/for] - fireNotifyChanged(new [genModel.getImportedName('org.eclipse.emf.edit.provider.ViewerNotification')/](notification, notification.getNotifier(), true, true)); - return; - [/if] - } -[/if] - super.notifyChanged(notification); - } - -[if (genModel.creationCommands)] - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected void collectNewChildDescriptors([genModel.getImportedName('java.util.Collection')/][if (genModel.useGenerics())]<[genModel.getImportedName('java.lang.Object')/]>[/if] newChildDescriptors, Object object) - { - super.collectNewChildDescriptors(newChildDescriptors, object); - [for (genClass.getChildCreationData())] - [if (getChildCreationDataCreateFeature().isFeatureMapType())] - [if (getChildCreationDataDelegatedFeature().isReferenceType())] -[comment]<%@ include file="ItemProvider/newChildDescriptorsReferenceDelegatedFeature.override.javajetinc" fail="alternative"%> -<%@ start %>[/comment] - - newChildDescriptors.add - (createChildParameter - ([getChildCreationDataCreateFeature().getQualifiedFeatureAccessor()/], - [genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMapUtil')/].createEntry - ([getChildCreationDataDelegatedFeature().getQualifiedFeatureAccessor()/], - [if (getChildCreationDataCreateClassifier().oclAsType(GenClass).isMapEntry())] - [getChildCreationDataCreateClassifier().oclAsType(GenClass).genPackage.getQualifiedEFactoryInstanceAccessor()/].create([getChildCreationDataCreateClassifier().oclAsType(GenClass).getQualifiedClassifierAccessor()/])))); - [else] - [getChildCreationDataCreateClassifier().oclAsType(GenClass).genPackage.getQualifiedFactoryInstanceAccessor()/].create[getChildCreationDataCreateClassifier().oclAsType(GenClass).getName()/]()))); - [/if] -[comment]<%@ include file="ItemProvider/newChildDescriptorsReferenceDelegatedFeature.insert.javajetinc" fail="silent"%> -<%@ end %><%//ItemProvider/newChildDescriptorsReferenceDelegatedFeature.override.javajetinc%>[/comment] - [else] -[comment]<%@ include file="ItemProvider/newChildDescriptorsAttributeDelegatedFeature.override.javajetinc" fail="alternative"%> -<%@ start %>[/comment] - - newChildDescriptors.add - (createChildParameter - ([getChildCreationDataCreateFeature().getQualifiedFeatureAccessor()/], - [genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMapUtil')/].createEntry - ([getChildCreationDataDelegatedFeature().getQualifiedFeatureAccessor()/], - [if (getChildCreationDataDelegatedFeature().isEnumBasedType())] - [getChildCreationDataDelegatedFeature().getTypeGenEnum().getStaticValue(getChildCreationDataDelegatedFeature().ecoreFeature.defaultValueLiteral)/]))); - [elseif (getChildCreationDataDelegatedFeature().isStringBasedType())] - [getChildCreationDataDelegatedFeature().getCreateChildValueLiteral()/])));[genModel.getNonNLS()/] - [else] - [getChildCreationDataCreateClassifier().oclAsType(GenDataType).genPackage.getQualifiedEFactoryInstanceAccessor()/].createFromString([getChildCreationDataCreateClassifier().oclAsType(GenDataType).getQualifiedClassifierAccessor()/], [getChildCreationDataDelegatedFeature().getCreateChildValueLiteral()/]))));[if (not getChildCreationDataDelegatedFeature().getCreateChildValueLiteral().oclIsUndefined())][genModel.getNonNLS()/][else] // TODO: ensure this is a valid literal value[/if] - [/if] -[comment]<%@ include file="ItemProvider/newChildDescriptorsAttributeDelegatedFeature.insert.javajetinc" fail="silent"%> -<%@ end %><%//ItemProvider/newChildDescriptorsAttributeDelegatedFeature.override.javajetinc%>[/comment] - [/if] - [elseif (getChildCreationDataCreateFeature().isReferenceType())] -[comment]<%@ include file="ItemProvider/newChildDescriptorsReferenceFeature.override.javajetinc" fail="alternative"%> -<%@ start %>[/comment] - - newChildDescriptors.add - (createChildParameter - ([getChildCreationDataCreateFeature().getQualifiedFeatureAccessor()/], - [if (getChildCreationDataCreateClassifier().oclAsType(GenClass).isMapEntry())] - [getChildCreationDataCreateClassifier().oclAsType(GenClass).genPackage.getQualifiedEFactoryInstanceAccessor()/].create([getChildCreationDataCreateClassifier().oclAsType(GenClass).getQualifiedClassifierAccessor()/]))); - [else] - [getChildCreationDataCreateClassifier().oclAsType(GenClass).genPackage.getQualifiedFactoryInstanceAccessor()/].create[getChildCreationDataCreateClassifier().oclAsType(GenClass).getName()/]())); - [/if] -[comment]<%@ include file="ItemProvider/newChildDescriptorsReferenceFeature.insert.javajetinc" fail="silent"%> -<%@ end %><%//ItemProvider/newChildDescriptorsReferenceFeature.override.javajetinc %>[/comment] - [else] -[comment]<%@ include file="ItemProvider/newChildDescriptorsAttributeFeature.override.javajetinc" fail="alternative"%> -<%@ start %>[/comment] - - newChildDescriptors.add - (createChildParameter - ([getChildCreationDataCreateFeature().getQualifiedFeatureAccessor()/], - [if (getChildCreationDataCreateFeature().isEnumBasedType())] - [getChildCreationDataCreateFeature().getTypeGenEnum().getStaticValue(getChildCreationDataCreateFeature().ecoreFeature.defaultValueLiteral)/])); - [elseif (getChildCreationDataCreateFeature().isStringBasedType())] - [getChildCreationDataCreateFeature().getCreateChildValueLiteral()/]));[genModel.getNonNLS()/] - [else] - [getChildCreationDataCreateClassifier().oclAsType(GenDataType).genPackage.getQualifiedEFactoryInstanceAccessor()/].createFromString([getChildCreationDataCreateClassifier().oclAsType(GenDataType).getQualifiedClassifierAccessor()/], [getChildCreationDataCreateFeature().getCreateChildValueLiteral()/])));[if (not getChildCreationDataCreateFeature().getCreateChildValueLiteral().oclIsUndefined())][genModel.getNonNLS()/][else] // TODO: ensure this is a valid literal value[/if] - [/if] -[comment]<%@ include file="ItemProvider/newChildDescriptorsAttributeFeature.insert.javajetinc" fail="silent"%> -<%@ end %><%//ItemProvider/newChildDescriptorsAttributeFeature.override.javajetinc%>[/comment] - [/if] - [/for] - } - -[if (genClass.getSharedClassCreateChildFeatures()->notEmpty())] - /** - * This returns the label text for {@link org.eclipse.emf.edit.command.CreateChildCommand}. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public String getCreateChildText(Object owner, Object feature, Object child, [genModel.getImportedName('java.util.Collection')/][if genModel.useGenerics()][/if] selection) - { - Object childFeature = feature; - Object childObject = child; - - [if (genClass.hasFeatureMapCreateChildFeatures())] - if (childFeature instanceof [genModel.getImportedName('org.eclipse.emf.ecore.EStructuralFeature')/] && [genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMapUtil')/].isFeatureMap((EStructuralFeature)childFeature)) - { - [genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Entry entry = (FeatureMap.Entry)childObject; - childFeature = entry.getEStructuralFeature(); - childObject = entry.getValue(); - } - - [/if] - boolean qualify = - [for (createFeature : GenFeature | genClass.getSharedClassCreateChildFeatures()) separator (' ||' + genModel.getLineDelimiter())] - childFeature == [createFeature.getQualifiedFeatureAccessor()/][/for]; - - if (qualify) - { - return getString - ("_UI_CreateChild_text2",[genModel.getNonNLS()/] - new Object[genModel.genSquareBrackets('')/] { getTypeText(childObject), getFeatureText(childFeature), getTypeText(owner) }); - } - return super.getCreateChildText(owner, feature, child, selection); - } - -[/if] -[/if] -[if (genClass.getProviderExtendsGenClass().oclIsUndefined() or genClass.getProviderExtendsGenClass().genPackage <> genPackage and ( not genPackage.extensibleProviderFactory or genClass.getProviderExtendsGenClass().genPackage.extensibleProviderFactory <> genPackage.extensibleProviderFactory))] - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public [genModel.getImportedName('org.eclipse.emf.common.util.ResourceLocator')/] getResourceLocator() - { -[if (genPackage.extensibleProviderFactory)] - return (([genModel.getImportedName('org.eclipse.emf.edit.provider.IChildCreationExtender')/])adapterFactory).getResourceLocator(); -[else] - return [genPackage.getImportedEditPluginClassName()/].INSTANCE; -[/if] - } - -[/if] -[comment]<%@ include file="ItemProvider/insert.javajetinc" fail="silent" %>[/comment] -} - -[/template] - -[template protected _List (genModel : GenModel)] -[genModel.getImportedName('java.util.List')/][if genModel.useGenerics()]<[genModel.getImportedName('org.eclipse.emf.edit.provider.IItemPropertyDescriptor')/]>[/if] -[/template] - -[template private declareFilterFlag(filterFlag : EString)] - [if (not filterFlag.oclIsUndefined() and filterFlag.size() > 0)] - "[filterFlag/]" - [/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/ItemProviderAdapterFactory.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/ItemProviderAdapterFactory.mtl deleted file mode 100644 index 92808be61..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/ItemProviderAdapterFactory.mtl +++ /dev/null @@ -1,602 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module ItemProviderAdapterFactory('http://www.eclipse.org/emf/2002/GenModel','http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenTypedElement /] - -[template public ItemProviderAdapterFactory(genPackage : GenPackage) { genModel : GenModel = genPackage.genModel ; packageName : String = genPackage.getProviderPackageName() ; className : String = genPackage.getItemProviderAdapterFactoryClassName() }] -[genModel.initializeImportManager(packageName, className)/] -[file (genModel.editPath(packageName, className), false, 'UTF-8')] -[includeHeader()/] -package [packageName/]; - -[genModel.addImports()/] -[let content : String = genModel.fileContent(genPackage, className)] -[genModel.genSortedImports()/] - -[content/] -[/let] -[/file] -[/template] - -[template public addImports (genModel : GenModel) post (trim())] -[genModel.addImport('org.eclipse.emf.common.notify.Adapter')/] -[genModel.addImport('org.eclipse.emf.common.notify.Notification')/] -[genModel.addImport('org.eclipse.emf.common.notify.Notifier')/] -[genModel.addImport('org.eclipse.emf.edit.provider.ChangeNotifier')/] -[genModel.addImport('org.eclipse.emf.edit.provider.ComposeableAdapterFactory')/] -[genModel.addImport('org.eclipse.emf.edit.provider.ComposedAdapterFactory')/] -[genModel.addImport('org.eclipse.emf.edit.provider.IChangeNotifier')/] -[genModel.addImport('org.eclipse.emf.edit.provider.IEditingDomainItemProvider')/] -[genModel.addImport('org.eclipse.emf.edit.provider.IItemLabelProvider')/] -[genModel.addImport('org.eclipse.emf.edit.provider.IItemPropertySource')/] -[genModel.addImport('org.eclipse.emf.edit.provider.INotifyChangedListener')/] -[genModel.addImport('org.eclipse.emf.edit.provider.IStructuredItemContentProvider')/] -[genModel.addImport('org.eclipse.emf.edit.provider.ITreeItemContentProvider')/] -[/template] - -[template public fileContent(genModel : GenModel, genPackage : GenPackage, className : String)] -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class [className/] extends [genPackage.getImportedAdapterFactoryClassName()/] implements ComposeableAdapterFactory, IChangeNotifier[if (genPackage.disposableProviderFactory)], [genModel.getImportedName('org.eclipse.emf.edit.provider.IDisposable')/][/if][if (genPackage.extensibleProviderFactory)], [genModel.getImportedName('org.eclipse.emf.edit.provider.IChildCreationExtender')/][/if] -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final java.lang.String copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - -[if (genPackage.disposableProviderFactory and genPackage.hasStatefulProvider())] - /** - * This keeps track of all the item providers created, so that they can be {@link #dispose disposed}. - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.emf.edit.provider.Disposable')/] disposable = new Disposable(); - -[/if] -[if (genPackage.extensibleProviderFactory)] - /** - * This helps manage the child creation extenders. - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.emf.edit.provider.ChildCreationExtenderManager')/] childCreationExtenderManager = new [genModel.getImportedName('org.eclipse.emf.edit.provider.ChildCreationExtenderManager')/]([genPackage.getImportedEditPluginClassName()/].INSTANCE, [genPackage.getImportedPackageInterfaceName()/].eNS_URI); - -[/if] - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected [_Collection(genPackage)/] supportedTypes = new [_ArrayList(genPackage)/](); - - /** - * This constructs an instance. - * - * - * @generated - */ - public [genPackage.getItemProviderAdapterFactoryClassName()/]() - { -[for (name : String | genPackage.getProviderSupportedTypes())] - supportedTypes.add([genModel.getImportedName(name)/].class); -[/for] - } - -[for (genDelegate : GenPackage | genPackage.getAdapterDelegatePackages())] - /** - * This keeps track of the factory to which to delegate adapter creation for objects from that package. - * - * - * @generated - */ - protected [genDelegate.getImportedAdapterFactoryClassName()/] [genPackage.getUncapAdapterFactoryDelegateName(genDelegate)/] = null; - - /** - * This determines the delegate factory for the package. - * - * - * @generated - */ - protected [genDelegate.getImportedAdapterFactoryClassName()/] get[genPackage.getAdapterFactoryDelegateName(genDelegate)/]() - { - if ([genPackage.getUncapAdapterFactoryDelegateName(genDelegate)/] == null) - { - [genModel.getImportedName('org.eclipse.emf.common.notify.AdapterFactory')/] rootAdapterFactory = getRootAdapterFactory(); - if (rootAdapterFactory instanceof ComposedAdapterFactory) - { - [genModel.getImportedName('org.eclipse.emf.common.notify.AdapterFactory')/] delegateAdapterFactory = - ((ComposedAdapterFactory)rootAdapterFactory).getFactoryForType([genDelegate.getImportedAdapterFactoryClassName()/].getPackage()); - if (delegateAdapterFactory instanceof [genDelegate.getImportedAdapterFactoryClassName()/]) - { - [genPackage.getUncapAdapterFactoryDelegateName(genDelegate)/] = ([genDelegate.getImportedAdapterFactoryClassName()/])delegateAdapterFactory; - } - } - } - return [genPackage.getUncapAdapterFactoryDelegateName(genDelegate)/]; - } - -[/for] -[for (genClass : GenClass | genPackage.genClasses)] -[if (not genClass.isAbstract() and (genClass.provider <> GenProviderKind::None))] -[if (genClass.isProviderSingleton())] - /** - * This keeps track of the one adapter used for all {@link [genClass.getQualifiedInterfaceName()/]} instances. - * - * - * @generated - */ - protected [genClass.getProviderClassName()/] [genClass.getUncapName()/]ItemProvider; - - /** - * This creates an adapter for a {@link [genClass.getQualifiedInterfaceName()/]}. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Adapter create[genClass.getName()/]Adapter() - { - if ([genClass.getUncapName()/]ItemProvider == null) - { - [genClass.getUncapName()/]ItemProvider = new [genClass.getProviderClassName()/](this); - } - - return [genClass.getUncapName()/]ItemProvider; - } - -[else] - /** - * This creates an adapter for a {@link [genClass.getQualifiedInterfaceName()/]}. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Adapter create[genClass.getName()/]Adapter() - { - return new [genClass.getProviderClassName()/](this); - } - -[/if] -[/if] -[/for] -[for (genClass : GenClass | genPackage.getAdapterDelegateSuperClasses())] - /** - * <[genClass.getName()/] of [genClass.getItemProviderAdapterFactoryClassName()/] - * - * - * @generated - */ - public Adapter create[genClass.getName()/]Adapter() - { - return - get[genClass.getItemProviderAdapterFactoryClassName()/]() == null ? - null : - get[genClass.getItemProviderAdapterFactoryClassName()/]().create[genClass.getName()/]Adapter(); - } - -[/for] - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() - { - return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) - { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public boolean isFactoryForType(Object type) - { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Adapter adapt(Notifier notifier, Object type) - { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Object adapt(Object object, Object type) - { - if (isFactoryForType(type)) - { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class[if (genModel.useGenerics())][/if]) || [if (genModel.runtimePlatform = GenRuntimePlatform::GWT)][genModel.getImportedName('org.eclipse.emf.common.util.Reflect')/].isInstance((Class[if (genModel.useGenerics())][/if])type, adapter)[else](((Class[if (genModel.useGenerics())][/if])type).isInstance(adapter))[/if]) - { - return adapter; - } - } - - return null; - } - -[if (genPackage.disposableProviderFactory and genPackage.hasStatefulProvider())] - /** - * Associates an adapter with a notifier via the base implementation, then records it to ensure it will be disposed. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected void associate(Adapter adapter, Notifier target) - { - super.associate(adapter, target); - if (adapter != null) - { - disposable.add(adapter); - } - } - -[/if] -[if (genPackage.extensibleProviderFactory)] - /** - * - * - * @generated - */ - public [if useGenerics(genPackage)][genModel.getImportedName('java.util.List')/]<[genModel.getImportedName('org.eclipse.emf.edit.provider.IChildCreationExtender')/]>[else][genModel.getImportedName('java.util.List')/][/if] getChildCreationExtenders() - { - return childCreationExtenderManager.getChildCreationExtenders(); - } - - /** - * - * - * @generated - */ - public [if useGenerics(genPackage)][genModel.getImportedName('java.util.Collection')/][else][genModel.getImportedName('java.util.Collection')/][/if] getNewChildDescriptors(Object object, [genModel.getImportedName('org.eclipse.emf.edit.domain.EditingDomain')/] editingDomain) - { - return childCreationExtenderManager.getNewChildDescriptors(object, editingDomain); - } - - /** - * - * - * @generated - */ - public [genModel.getImportedName('org.eclipse.emf.common.util.ResourceLocator')/] getResourceLocator() - { - return childCreationExtenderManager; - } - -[/if] - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) - { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) - { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) - { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) - { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - -[if (genPackage.disposableProviderFactory)] - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() - { -[if (genPackage.hasStatefulProvider())] - disposable.dispose(); -[else] -[for (genClass : GenClass | genPackage.genClasses)] -[if (not genClass.isAbstract() and genClass.isProviderSingleton())] - if ([genClass.getUncapName()/]ItemProvider != null) [genClass.getUncapName()/]ItemProvider.dispose(); -[/if] -[/for] -[/if] - } - -[/if] -[if (genPackage.childCreationExtenders)] -[comment <%for (Map.Entry>> packageEntry : genPackage.getExtendedChildCreationData().entrySet()) {%> /] - [for (genPackage.getExtendedChildCreationDataEntrySet())] -[comment packageEntry.getKey() = GenPackage/] - [let key : GenPackage = getPackageEntryKey()] - /** - * A child creation extender for the {@link [key.getImportedPackageInterfaceName()/]}. - * - * - * @generated - */ - public static class [genPackage.getChildCreationExtenderName(key)/] implements [genModel.getImportedName('org.eclipse.emf.edit.provider.IChildCreationExtender')/] - { - /** - * The switch for creating child descriptors specific to each extended class. - * - * - * @generated - */ - protected static class CreationSwitch extends [genModel.getImportedName(key.getQualifiedSwitchClassName())/][if useGenerics(genPackage)][/if] - { - /** - * The child descriptors being populated. - * - * - * @generated - */ - protected [genModel.getImportedName('java.util.List')/][if useGenerics(genPackage)][/if] newChildDescriptors; - - /** - * The domain in which to create the children. - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.emf.edit.domain.EditingDomain')/] editingDomain; - - /** - * Creates the a switch for populating child descriptors in the given domain. - * - * - * @generated - */ - CreationSwitch([genModel.getImportedName('java.util.List')/][if useGenerics(genPackage)][/if] newChildDescriptors, [genModel.getImportedName('org.eclipse.emf.edit.domain.EditingDomain')/] editingDomain) - { - this.newChildDescriptors = newChildDescriptors; - this.editingDomain = editingDomain; - } -[comment <%for (Map.Entry> classEntry : packageEntry.getValue().entrySet()) { GenClass genClass = classEntry.getKey();%>/] - [for (getPackageEntryValueEntrySet())] - [let genClass : GenClass = getClassEntryKey()] - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public [genClass.getTypeParameters()/]Object case[genPackage.getClassUniqueName(genClass)/]([genClass.getImportedInterfaceName()/][genClass.getInterfaceTypeArguments()/] object) - { -[comment <%for (GenClass.ChildCreationData childCreationData : classEntry.getValue()) { GenFeature createFeature = childCreationData.createFeature; GenFeature delegatedFeature = childCreationData.delegatedFeature; GenClassifier createClassifier = childCreationData.createClassifier;%>/] - [for (getClassEntryChildCreationData())] - [if (getChildCreationDataCreateFeature().isFeatureMapType())] - [if (getChildCreationDataDelegatedFeature().isReferenceType())] -[comment]<%@ include file="ItemProvider/newChildDescriptorsReferenceDelegatedFeature.override.javajetinc" fail="alternative"%> -<%@ start %>[/comment] - newChildDescriptors.add - (createChildParameter - ([getChildCreationDataCreateFeature().getQualifiedFeatureAccessor()/], - [genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMapUtil')/].createEntry - ([getChildCreationDataDelegatedFeature().getQualifiedFeatureAccessor()/], - [if (getChildCreationDataCreateClassifier().oclAsType(GenClass).isMapEntry())] - [getChildCreationDataCreateClassifier().oclAsType(GenClass).genPackage.getQualifiedEFactoryInstanceAccessor()/].create([getChildCreationDataCreateClassifier().oclAsType(GenClass).getQualifiedClassifierAccessor()/])))); - [else] - [getChildCreationDataCreateClassifier().oclAsType(GenClass).genPackage.getQualifiedFactoryInstanceAccessor()/].create[getChildCreationDataCreateClassifier().oclAsType(GenClass).getName()/]()))); - [/if] -[comment]<%@ include file="ItemProvider/newChildDescriptorsReferenceDelegatedFeature.insert.javajetinc" fail="silent"%> -<%@ end %><%//ItemProvider/newChildDescriptorsReferenceDelegatedFeature.override.javajetinc%>[/comment] - [else] -[comment]<%@ include file="ItemProvider/newChildDescriptorsAttributeDelegatedFeature.override.javajetinc" fail="alternative"%> -<%@ start %>[/comment] - newChildDescriptors.add - (createChildParameter - ([getChildCreationDataCreateFeature().getQualifiedFeatureAccessor()/], - [genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMapUtil')/].createEntry - ([getChildCreationDataDelegatedFeature().getQualifiedFeatureAccessor()/], - [if (getChildCreationDataDelegatedFeature().isEnumBasedType())] - [getChildCreationDataDelegatedFeature().getTypeGenEnum().getStaticValue(getChildCreationDataDelegatedFeature().ecoreFeature.defaultValueLiteral)/]))); - [elseif (getChildCreationDataDelegatedFeature().isStringBasedType())] - [getChildCreationDataDelegatedFeature().getCreateChildValueLiteral()/])));[genModel.getNonNLS()/] - [else] - [getChildCreationDataCreateClassifier().oclAsType(GenDataType).genPackage.getQualifiedEFactoryInstanceAccessor()/].createFromString([getChildCreationDataCreateClassifier().oclAsType(GenDataType).getQualifiedClassifierAccessor()/], [getChildCreationDataDelegatedFeature().getCreateChildValueLiteral()/]))));[if (not getChildCreationDataDelegatedFeature().getCreateChildValueLiteral().oclIsUndefined())][genModel.getNonNLS()/][else] // TODO: ensure this is a valid literal value[/if] - [/if] -[comment]<%@ include file="ItemProvider/newChildDescriptorsAttributeDelegatedFeature.insert.javajetinc" fail="silent"%> -<%@ end %><%//ItemProvider/newChildDescriptorsAttributeDelegatedFeature.override.javajetinc%>[/comment] - [/if] - [elseif (getChildCreationDataCreateFeature().isReferenceType())] -[comment]<%@ include file="ItemProvider/newChildDescriptorsReferenceFeature.override.javajetinc" fail="alternative"%> -<%@ start %>[/comment] - newChildDescriptors.add - (createChildParameter - ([getChildCreationDataCreateFeature().getQualifiedFeatureAccessor()/], - [if (getChildCreationDataCreateClassifier().oclAsType(GenClass).isMapEntry())] - [getChildCreationDataCreateClassifier().oclAsType(GenClass).genPackage.getQualifiedEFactoryInstanceAccessor()/].create([getChildCreationDataCreateClassifier().oclAsType(GenClass).getQualifiedClassifierAccessor()/]))); - [else] - [getChildCreationDataCreateClassifier().oclAsType(GenClass).genPackage.getQualifiedFactoryInstanceAccessor()/].create[getChildCreationDataCreateClassifier().oclAsType(GenClass).getName()/]())); - [/if] -[comment]<%@ include file="ItemProvider/newChildDescriptorsReferenceFeature.insert.javajetinc" fail="silent"%> -<%@ end %><%//ItemProvider/newChildDescriptorsReferenceFeature.override.javajetinc %>[/comment] - [else] -[comment]<%@ include file="ItemProvider/newChildDescriptorsAttributeFeature.override.javajetinc" fail="alternative"%> -<%@ start %>[/comment] - newChildDescriptors.add - (createChildParameter - ([getChildCreationDataCreateFeature().getQualifiedFeatureAccessor()/], - [if (getChildCreationDataCreateFeature().isEnumBasedType())] - [getChildCreationDataCreateFeature().getTypeGenEnum().getStaticValue(getChildCreationDataCreateFeature().ecoreFeature.defaultValueLiteral)/])); - [elseif (getChildCreationDataCreateFeature().isStringBasedType())] - [getChildCreationDataCreateFeature().getCreateChildValueLiteral()/]));[genModel.getNonNLS()/] - [else] - [getChildCreationDataCreateClassifier().oclAsType(GenDataType).genPackage.getQualifiedEFactoryInstanceAccessor()/].createFromString([getChildCreationDataCreateClassifier().oclAsType(GenDataType).getQualifiedClassifierAccessor()/], [getChildCreationDataCreateFeature().getCreateChildValueLiteral()/])));[if (not getChildCreationDataCreateFeature().getCreateChildValueLiteral().oclIsUndefined())][genModel.getNonNLS()/][else] // TODO: ensure this is a valid literal value[/if] - [/if] -[comment]<%@ include file="ItemProvider/newChildDescriptorsAttributeFeature.insert.javajetinc" fail="silent"%> -<%@ end %><%//ItemProvider/newChildDescriptorsAttributeFeature.override.javajetinc%>[/comment] - [/if] - - [/for] - return null; - } - - [/let] - [/for] - /** - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.emf.edit.command.CommandParameter')/] createChildParameter(Object feature, Object child) - { - return new [genModel.getImportedName('org.eclipse.emf.edit.command.CommandParameter')/](null, feature, child); - } - - } - - /** - * - * - * @generated - */ - public [_Collection(genPackage)/] getNewChildDescriptors(Object object, [genModel.getImportedName('org.eclipse.emf.edit.domain.EditingDomain')/] editingDomain) - { - [_ArrayList(genPackage)/] result = new [_ArrayList(genPackage)/](); - new CreationSwitch(result, editingDomain).doSwitch(([genModel.getImportedName('org.eclipse.emf.ecore.EObject')/])object); - return result; - } - - /** - * - * - * @generated - */ - public [genModel.getImportedName('org.eclipse.emf.common.util.ResourceLocator')/] getResourceLocator() - { - return [genPackage.getImportedEditPluginClassName()/].INSTANCE; - } - } - - [/let] - [/for] -[/if] -} -[/template] - -[query public useGenerics(genPackage : GenPackage) : Boolean = genModel.useGenerics()/] - -[template protected _ArrayList (genPackage : GenPackage)] -[genPackage.genModel.getImportedName('java.util.ArrayList')/][if genPackage.useGenerics()]<[genPackage.genModel.getImportedName('java.lang.Object')/]>[/if] -[/template] - -[template protected _Collection (genPackage : GenPackage)] -[genPackage.genModel.getImportedName('java.util.Collection')/][if genPackage.useGenerics()]<[genPackage.genModel.getImportedName('java.lang.Object')/]>[/if] -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/Plugin.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/Plugin.mtl deleted file mode 100644 index 430234e3b..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/Plugin.mtl +++ /dev/null @@ -1,254 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module Plugin('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnumLiteral /] - -[template public Plugin(genModel : GenModel) { packageName : String = genModel.getEditPluginPackageName() ; className : String = genModel.getEditPluginClassName() }] -[initializeImportManager(packageName, className)/] -[genModel.addImport('org.eclipse.emf.common.EMFPlugin')/] -[genModel.addImport('org.eclipse.emf.common.util.ResourceLocator')/] - -[file (genModel.editPath(packageName, className), false, 'UTF-8')] -[includeHeader()/] -package [packageName/]; -[let content : String = pluginFileContent(packageName, className)] -[genModel.genSortedImports()/] - -[content/] -[/let] -[/file] -[/template] - -[template public pluginFileContent(genModel : GenModel, packageName : String, className : String)] -/** - * This is the central singleton for the [genModel.modelName/] edit plugin. - * - * - * @generated - */ -public final class [className/] extends EMFPlugin -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - /** - * Keep track of the singleton. - * - * - * @generated - */ - public static final [className/] INSTANCE = new [className/](); - -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - /** - * Keep track of the singleton. - * - * - * @generated - */ - private static Implementation plugin; - -[/if] - /** - * Create the instance. - * - * - * @generated - */ - public [className/]() - { - super - (new ResourceLocator [genModel.genSquareBrackets('')/] - { -[for (pluginClassName : String | genModel.getEditResourceDelegateImportedPluginClassNames(packageName, className))] - [pluginClassName/].INSTANCE, -[/for] - }); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public ResourceLocator getPluginResourceLocator() - { -[if (genModel.runtimePlatform = GenRuntimePlatform::GWT)] - return null; -[else] - return plugin; -[/if] - } - -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() - { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * - * @generated - */ - public static class Implementation extends EclipsePlugin - { - /** - * Creates an instance. - * - * -[if (genModel.needsRuntimeCompatibility())] - * @param descriptor the description of the plugin. -[/if] - * @generated - */ - public Implementation([if (genModel.needsRuntimeCompatibility())][genModel.getImportedName('org.eclipse.core.runtime.IPluginDescriptor')/] descriptor[/if]) - { - super([if (genModel.needsRuntimeCompatibility())]descriptor[/if]); - - // Remember the static instance. - // - plugin = this; - } - } - -[else] - /** - * - * - * @generated - */ - protected static final [genModel.getQualifiedEditPluginClassName().concat('Properties')/] PROPERTIES = com.google.gwt.core.client.GWT.create([genModel.getQualifiedEditPluginClassName().concat('Properties')/].class); - - /** - * - * - * @generated - */ - @Override - public String getString(String key, boolean translate) - { -[for (genPackage : GenPackage | genModel.getAllGenAndUsedGenPackagesWithClassifiers()) separator ('else ')] - [if (genPackage.genModel = genModel or not genPackage.genModel.hasEditSupport())] - [for (genClass : GenClass | genPackage.genClasses)] - if ("_UI_[genClass.getName()/]_type".equals(key)) return PROPERTIES.[genClass.getUncapName()/]Type(); - [/for] - [/if] -[/for] - [if (not genModel.getAllGenAndUsedGenPackagesWithClassifiers()->isEmpty() and (genModel.getAllGenAndUsedGenPackagesWithClassifiers()->first().genModel = genModel or not genModel.getAllGenAndUsedGenPackagesWithClassifiers()->first().genModel.hasEditSupport()))] else [/if] if ("_UI_Unknown_type".equals(key)) return PROPERTIES.unknownType(); - else if ("_UI_Unknown_datatype".equals(key)) return PROPERTIES.unknownDatatype(); -[for (genFeature : GenFeature | genModel.getFilteredAllGenFeatures())] - else if ("_UI_[genFeature.genClass.getName()/]_[genFeature.getName()/]_feature".equals(key)) return PROPERTIES.[genFeature.genClass.getUncapName()/]_[genFeature.getCapName()/]Feature(); - [if (not genFeature.propertyDescription.oclIsUndefined() and genFeature.propertyDescription->size() > 0)] - else if ("_UI_[genFeature.genClass.getName()/]_[genFeature.getName()/]_description".equals(key)) return PROPERTIES.[genFeature.genClass.getUncapName()/]_[genFeature.getCapName()/]Description(); - [/if] -[/for] - else if ("_UI_Unknown_feature".equals(key)) return PROPERTIES.unknownFeature(); -[for (genPackage : GenPackage | genModel.getAllGenAndUsedGenPackagesWithClassifiers())] - [if (genPackage.genModel = genModel or not genPackage.genModel.hasEditSupport())] - [for (genEnum : GenEnum | genPackage.genEnums)] - [for (genEnumLiteral : GenEnumLiteral | genEnum.genEnumLiterals)] - else if ("_UI_[genEnum.getName()/]_[genEnumLiteral.getName()/]_literal".equals(key)) return PROPERTIES.[genEnum.getSafeUncapName()/]_[genEnumLiteral.getName()/]Literal(); - [/for] - [/for] - [/if] -[/for] -[for (category : String | genModel.getPropertyCategories())] -[genModel.getPropertyCategoryKey(category)/] = [category/] - else if ("[genModel.getPropertyCategoryKey(category)/]".equals(key)) return PROPERTIES.[genModel.getPropertyCategoryKey(category)/](); -[/for] - else return key; - } - - /** - * - * - * @generated - */ - @Override - public String getString(String key, Object [genModel.genSquareBrackets('')/] substitutions, boolean translate) - { -[if (genModel.creationCommands)] - if ("_UI_CreateChild_text".equals(key)) return PROPERTIES.createChildText(substitutions[genModel.genSquareBrackets('0')/]); - else if ("_UI_CreateChild_text2".equals(key)) return PROPERTIES.createChildText2(substitutions[genModel.genSquareBrackets('0')/], substitutions[genModel.genSquareBrackets('1')/]); - else if ("_UI_CreateChild_text3".equals(key)) return PROPERTIES.createChildText3(substitutions[genModel.genSquareBrackets('1')/]); - else if ("_UI_CreateChild_tooltip".equals(key)) return PROPERTIES.createChildTooltip(substitutions[genModel.genSquareBrackets('0')/], substitutions[genModel.genSquareBrackets('1')/]); - else if ("_UI_CreateChild_description".equals(key)) return PROPERTIES.createChildDescripition(substitutions[genModel.genSquareBrackets('0')/], substitutions[genModel.genSquareBrackets('1')/], substitutions[genModel.genSquareBrackets('2')/]); - else if ("_UI_CreateSibling_description".equals(key)) return PROPERTIES.createSiblingDescription(substitutions[genModel.genSquareBrackets('0')/], substitutions[genModel.genSquareBrackets('1')/], substitutions[genModel.genSquareBrackets('2')/]); -[/if] - [if (not genModel.creationCommands)]else [/if]if ("_UI_PropertyDescriptor_description".equals(key)) return PROPERTIES.propertyDescriptorDescription(substitutions[genModel.genSquareBrackets('0')/], substitutions[genModel.genSquareBrackets('1')/]); - else return key; - } - - /** - * - * - * @generated - */ - protected static final [genModel.getQualifiedEditPluginClassName().concat('Images')/] IMAGES = com.google.gwt.core.client.GWT.create([genModel.getQualifiedEditPluginClassName().concat('Images')/].class); - - /** - * - * - * @generated - */ - @Override - public Object getImage(String key) - { -[for (genPackage : GenPackage | genModel.getAllGenAndUsedGenPackagesWithClassifiers()) separator ('else ')] - [for (genClass : GenClass | genPackage.genClasses)] - [if (genClass.image)] - if ("[image/]".equals(key)) return IMAGES.[genClass.getSafeUncapName()/](); - [/if] - [/for] -[/for] - [if (not genModel.getAllGenAndUsedGenPackagesWithClassifiers()->isEmpty())]else [/if] return key; - } - -[/if] -} -[/template] - -[query public image(genClass : GenClass) : String = genClass.getItemIconFileName().substring(genClass.getItemIconFileName().lastIndex('/icons/') + 7, genClass.getItemIconFileName()->size() - 4) /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/buildproperties.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/buildproperties.mtl deleted file mode 100644 index 754cd6760..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/buildproperties.mtl +++ /dev/null @@ -1,49 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module buildproperties('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] - -[template public buildproperties(genModel : GenModel)] -[file (buildpropertiesPath(), false, 'UTF-8')] -[includeHeaderProperties()/] -bin.includes = [pluginClassesLocation()/],\ -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - icons/,\ -[/if] -[if (genModel.bundleManifest)] - META-INF/,\ -[/if] -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - plugin.xml,\ -[/if] - plugin.properties -jars.compile.order = [pluginClassesLocation()/] -source.[pluginClassesLocation()/] = [for (sourceFolder : String | genModel.getEditSourceFolders()) separator (',\\ ')] -[sourceFolder/] -[/for] -output.[pluginClassesLocation()/] = bin/ -[/file] -[/template] - -[query public buildpropertiesPath(genModel : GenModel) : String = 'build.properties' /] - -[query public pluginClassesLocation(genModel : GenModel) : String - = if genModel.runtimeJar then genModel.editPluginID + '.jar' else '.' endif/] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/editIcons.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/editIcons.mtl deleted file mode 100644 index 514541b69..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/editIcons.mtl +++ /dev/null @@ -1,29 +0,0 @@ -[comment encoding = UTF-8 -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - Initial API and implementation - *******************************************************************************/ -/] -[module editIcons('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] - -[template public ItemIcon(genClass : GenClass)] -[genClass.generateItemIcon()/] -[/template] - -[template public CreateChildIcons(genClass : GenClass)] -[genClass.generateCreateChildIcons()/] -[/template] - -[template public CreateChildIcons(genPackage : GenPackage)] -[genPackage.generateCreateChildIcons()/] -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/manifestmf.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/manifestmf.mtl deleted file mode 100644 index ca8867ef3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/manifestmf.mtl +++ /dev/null @@ -1,53 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module manifestmf('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] - -[template public manifestmf(genModel : GenModel)] -[file (manifestmfPath(), false, 'UTF-8')] -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: %pluginName -Bundle-SymbolicName: [genModel.editPluginID/];singleton:=true -Bundle-Version: 1.0.0.qualifier -Bundle-ClassPath: [if (genModel.runtimeJar)][genModel.editPluginID/].jar[else].[/if] -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] -Bundle-Activator: [genModel.getQualifiedEditPluginClassName()/]$Implementation -[/if] -Bundle-Vendor: %providerName -Bundle-Localization: plugin -[if (genModel.complianceLevel = GenJDKLevel::JDK50)] -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -[elseif (genModel.complianceLevel = GenJDKLevel::JDK60)] -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -[/if] -[for (pack : String | genModel.getEditQualifiedPackageNames()) before ('Export-Package:') separator (',' + genModel.getLineDelimiter())] - [pack/][/for] - -[for (pluginID : String | genModel.getEditRequiredPlugins()) before ('Require-Bundle:') separator (',' + genModel.getLineDelimiter())] - [pluginID/][if (not pluginID.startsWith('org.eclipse.core.runtime'))];visibility:=reexport[/if][/for] - -[if (genModel.runtimeVersion = GenRuntimeVersion::EMF22 or genModel.runtimeVersion = GenRuntimeVersion::EMF23)] -Eclipse-LazyStart: true -[/if] -Bundle-ActivationPolicy: lazy -[/file] -[/template] - -[query public manifestmfPath(genModel : GenModel) : String = 'META-INF/MANIFEST.MF' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/pluginproperties.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/pluginproperties.mtl deleted file mode 100644 index 4dbb63247..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/pluginproperties.mtl +++ /dev/null @@ -1,81 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module pluginproperties('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnumLiteral /] - -[template public pluginproperties(genModel : GenModel)] -[file (pluginpropertiesPath(), false, 'UTF-8')] -[includeHeaderProperties()/] -pluginName = [genModel.modelName/] Edit Support -providerName = www.example.org -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - -[if (genModel.creationCommands)] -_UI_CreateChild_text = {0} -_UI_CreateChild_text2 = {1} [if (genModel.creationSubmenus)]| [/if]{0} -_UI_CreateChild_text3 = {1} -_UI_CreateChild_tooltip = Create New {0} Under {1} Feature -_UI_CreateChild_description = Create a new child of type {0} for the {1} feature of the selected {2}. -_UI_CreateSibling_description = Create a new sibling of type {0} for the selected {2}, under the {1} feature of their parent. - -[/if] -_UI_PropertyDescriptor_description = The {0} of the {1} - -[for (genPackage : GenPackage | genModel.getAllGenAndUsedGenPackagesWithClassifiers())] - [if (genPackage.genModel = genModel or not genPackage.genModel.hasEditSupport())] - [for (genClass : GenClass | genPackage.genClasses)] -_UI_[genClass.getName()/]_type = [genClass.getFormattedName()/] - [/for] - [/if] -[/for] -_UI_Unknown_type = Object - -_UI_Unknown_datatype= Value - -[for (genFeature : GenFeature | genModel.getFilteredAllGenFeatures())] -_UI_[genFeature.genClass.getName()/]_[genFeature.getName()/]_feature = [genFeature.getFormattedName()/] - [if (not genFeature.propertyDescription.oclIsUndefined() and genFeature.propertyDescription->size() > 0)] -_UI_[genFeature.genClass.getName()/]_[genFeature.getName()/]_description = [genFeature.propertyDescription/] - [/if] -[/for] -_UI_Unknown_feature = Unspecified - -[for (genPackage : GenPackage | genModel.getAllGenAndUsedGenPackagesWithClassifiers())] - [if (genPackage.genModel = genModel or not genPackage.genModel.hasEditSupport())] - [for (genEnum : GenEnum | genPackage.genEnums)] - [for (genEnumLiteral : GenEnumLiteral | genEnum.genEnumLiterals)] -_UI_[genEnum.getName()/]_[genEnumLiteral.getName()/]_literal = [genEnumLiteral.getLiteral()/] - [/for] - [/for] - [/if] -[/for] -[for (category : String | genModel.getPropertyCategories())] -[genModel.getPropertyCategoryKey(category)/] = [category/] -[/for] -[/if] -[/file] -[/template] - -[query public pluginpropertiesPath(genModel : GenModel) : String = 'plugin.properties' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/pluginxml.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/pluginxml.mtl deleted file mode 100644 index a39cd0853..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/edit/pluginxml.mtl +++ /dev/null @@ -1,136 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module pluginxml('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage/] - -[template public pluginxml(genModel : GenModel)] -[file (pluginxmlPath(), false, 'UTF-8')] - - - -[includeHeaderXml()/] - -[if (genModel.bundleManifest)] - -[else] - - - - [for (pluginID : String | genModel.getEditRequiredPlugins())] - - [/for] - - - - [if (genModel.runtimeJar)] - - [else] - - [/if] - - - -[/if] -[for (genPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers())] - [if (not genPackage.genClasses->isEmpty())] - - - ') ][supported/][/for] - - [comment]<%if (genPackage.isChildCreationExtenders()) { Map>> extendedChildCreationData = genPackage.getExtendedChildCreationData();%> - <%if (!extendedChildCreationData.isEmpty()) {%>[/comment] -[if (genPackage.childCreationExtenders)] - - [for (genPackage.getExtendedChildCreationDataEntrySet())] - [let key : GenPackage = getPackageEntryKey()] - - [/let] - [/for] - -[/if] - [/if] -[/for] -[if (genModel.sameModelEditProject())] - [for (genPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers())] - - - - [else] - class="[genPackage.getQualifiedPackageInterfaceName()/]"/> - [/if] - - [if (genPackage.isContentType())] - - - - - - - - - [if (genPackage.hasTargetNamespace())] - - [/if] - [if (genPackage.isXMIResource())] - - [/if] - - - - [elseif (genPackage.getResource() <> GenResourceKind::None)] - - - - - [/if] - [/for] -[/if] - - -[/file] -[/template] - -[query public pluginxmlPath (genModel : GenModel) : String = 'plugin.xml' /] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/ActionBarContributor.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/ActionBarContributor.mtl deleted file mode 100644 index b02dbd814..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/ActionBarContributor.mtl +++ /dev/null @@ -1,729 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module ActionBarContributor('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[template public ActionBarContributor(genPackage : GenPackage) { genModel : GenModel = genPackage.genModel ; packageName : String = genPackage.getPresentationPackageName() ; className : String = genPackage.getActionBarContributorClassName() }] -[genModel.initializeImportManager(packageName, className)/] -[file (genModel.editorPath(packageName, className), false, 'UTF-8')] -[includeHeader()/] -package [packageName/]; - -[let content : String = genModel.fileContent(genPackage, packageName, className)] -[genModel.genSortedImports()/] - -[content/][/let] -[/file] -[/template] - -[template public fileContent(genModel : GenModel, genPackage : GenPackage, packageName : String, className : String)] -/** - * This is the action bar contributor for the [genPackage.prefix/] model editor. - * - * - * @generated - */ -public class [className/] - extends [genModel.getImportedName('org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor')/] - implements [genModel.getImportedName('org.eclipse.jface.viewers.ISelectionChangedListener')/] -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final String copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] -[if (genModel.richClientPlatform and genPackage.generateModelWizard)] - /** - * Action to create objects from the [genPackage.prefix/] model. - * - * - * @generated - */ - public static class NewAction extends [genModel.getImportedName('org.eclipse.emf.common.ui.action.WorkbenchWindowActionDelegate')/] - { - /** - * @see org.eclipse.ui.IActionDelegate#run(org.eclipse.jface.action.IAction) - * - * - * @generated - */ - public void run([genModel.getImportedName('org.eclipse.jface.action.IAction')/] action) - { - [genPackage.getModelWizardClassName()/] wizard = new [genPackage.getModelWizardClassName()/](); - wizard.init(getWindow().getWorkbench(), [genModel.getImportedName('org.eclipse.jface.viewers.StructuredSelection')/].EMPTY); - [genModel.getImportedName('org.eclipse.jface.wizard.WizardDialog')/] wizardDialog = new [genModel.getImportedName('org.eclipse.jface.wizard.WizardDialog')/](getWindow().getShell(), wizard); - wizardDialog.open(); - } - } - -[/if] - /** - * This keeps track of the active editor. - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.ui.IEditorPart')/] activeEditorPart; - - /** - * This keeps track of the current selection provider. - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.jface.viewers.ISelectionProvider')/] selectionProvider; - - /** - * This action opens the Properties view. - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.jface.action.IAction')/] showPropertiesViewAction = - new [genModel.getImportedName('org.eclipse.jface.action.Action')/]([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_ShowPropertiesView_menu_item"))[genModel.getNonNLS()/] - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void run() - { - try - { - getPage().showView("org.eclipse.ui.views.PropertySheet");[genModel.getNonNLS()/] - } - catch ([genModel.getImportedName('org.eclipse.ui.PartInitException')/] exception) - { - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.log(exception); - } - } - }; - - /** - * This action refreshes the viewer of the current editor if the editor - * implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}. - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.jface.action.IAction')/] refreshViewerAction = - new [genModel.getImportedName('org.eclipse.jface.action.Action')/]([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_RefreshViewer_menu_item"))[genModel.getNonNLS()/] - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public boolean isEnabled() - { - return activeEditorPart instanceof [genModel.getImportedName('org.eclipse.emf.common.ui.viewer.IViewerProvider')/]; - } - -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void run() - { - if (activeEditorPart instanceof [genModel.getImportedName('org.eclipse.emf.common.ui.viewer.IViewerProvider')/]) - { - [genModel.getImportedName('org.eclipse.jface.viewers.Viewer')/] viewer = (([genModel.getImportedName('org.eclipse.emf.common.ui.viewer.IViewerProvider')/])activeEditorPart).getViewer(); - if (viewer != null) - { - viewer.refresh(); - } - } - } - }; - -[if (genModel.creationCommands)] - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected [genModel._CollectionOfIAction()/] createChildActions; - - [if (genModel.creationSubmenus)] - /** - * This will contain a map of {@link org.eclipse.emf.edit.ui.action.CreateChildAction}s, keyed by sub-menu text. - * - * - * @generated - */ - protected [genModel._MapOfStringToCollectionOfIAction()/] createChildSubmenuActions; - - [/if] - /** - * This is the menu manager into which menu contribution items should be added for CreateChild actions. - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.jface.action.IMenuManager')/] createChildMenuManager; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected [genModel._CollectionOfIAction()/] createSiblingActions; - - [if (genModel.creationSubmenus)] - /** - * This will contain a map of {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction}s, keyed by submenu text. - * - * - * @generated - */ - protected [genModel._MapOfStringToCollectionOfIAction()/] createSiblingSubmenuActions; - - [/if] - /** - * This is the menu manager into which menu contribution items should be added for CreateSibling actions. - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.jface.action.IMenuManager')/] createSiblingMenuManager; - -[/if] - /** - * This creates an instance of the contributor. - * - * - * @generated - */ - public [genPackage.getActionBarContributorClassName()/]() - { - super(ADDITIONS_LAST_STYLE); - loadResourceAction = new [genModel.getImportedName('org.eclipse.emf.edit.ui.action.LoadResourceAction')/](); - validateAction = new [genModel.getImportedName('org.eclipse.emf.edit.ui.action.ValidateAction')/](); - controlAction = new [genModel.getImportedName('org.eclipse.emf.edit.ui.action.ControlAction')/](); - } - - /** - * This adds Separators for editor additions to the tool bar. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void contributeToToolBar([genModel.getImportedName('org.eclipse.jface.action.IToolBarManager')/] toolBarManager) - { - toolBarManager.add(new [genModel.getImportedName('org.eclipse.jface.action.Separator')/]("[genModel.toLowerCase(genPackage.prefix, genModel.getLocale())/]-settings"));[genModel.getNonNLS()/] - toolBarManager.add(new [genModel.getImportedName('org.eclipse.jface.action.Separator')/]("[genModel.toLowerCase(genPackage.prefix, genModel.getLocale())/]-additions"));[genModel.getNonNLS()/] - } - - /** - * This adds to the menu bar a menu and some separators for editor additions, - * as well as the sub-menus for object creation items. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void contributeToMenu([genModel.getImportedName('org.eclipse.jface.action.IMenuManager')/] menuManager) - { - super.contributeToMenu(menuManager); - - [genModel.getImportedName('org.eclipse.jface.action.IMenuManager')/] submenuManager = new [genModel.getImportedName('org.eclipse.jface.action.MenuManager')/]([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_[genPackage.getEditorClassName()/]_menu"), "[genPackage.getInterfacePackageName()/]MenuID");[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - menuManager.insertAfter("additions", submenuManager);[genModel.getNonNLS()/] - submenuManager.add(new [genModel.getImportedName('org.eclipse.jface.action.Separator')/]("settings"));[genModel.getNonNLS()/] - submenuManager.add(new [genModel.getImportedName('org.eclipse.jface.action.Separator')/]("actions"));[genModel.getNonNLS()/] - submenuManager.add(new [genModel.getImportedName('org.eclipse.jface.action.Separator')/]("additions"));[genModel.getNonNLS()/] - submenuManager.add(new [genModel.getImportedName('org.eclipse.jface.action.Separator')/]("additions-end"));[genModel.getNonNLS()/] - -[if (genModel.creationCommands)] - // Prepare for CreateChild item addition or removal. - // - createChildMenuManager = new [genModel.getImportedName('org.eclipse.jface.action.MenuManager')/]([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_CreateChild_menu_item"));[genModel.getNonNLS()/] - submenuManager.insertBefore("additions", createChildMenuManager);[genModel.getNonNLS()/] - - // Prepare for CreateSibling item addition or removal. - // - createSiblingMenuManager = new [genModel.getImportedName('org.eclipse.jface.action.MenuManager')/]([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_CreateSibling_menu_item"));[genModel.getNonNLS()/] - submenuManager.insertBefore("additions", createSiblingMenuManager);[genModel.getNonNLS()/] - - // Force an update because Eclipse hides empty menus now. - // - submenuManager.addMenuListener - (new [genModel.getImportedName('org.eclipse.jface.action.IMenuListener')/]() - { - public void menuAboutToShow([genModel.getImportedName('org.eclipse.jface.action.IMenuManager')/] menuManager) - { - menuManager.updateAll(true); - } - }); - -[else] - // Add your contributions. - // Ensure that you remove @generated or mark it @generated NOT - -[/if] - addGlobalActions(submenuManager); - } - - /** - * When the active editor changes, this remembers the change and registers with it as a selection provider. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void setActiveEditor([genModel.getImportedName('org.eclipse.ui.IEditorPart')/] part) - { - super.setActiveEditor(part); - activeEditorPart = part; - - // Switch to the new selection provider. - // - if (selectionProvider != null) - { - selectionProvider.removeSelectionChangedListener(this); - } - if (part == null) - { - selectionProvider = null; - } - else - { - selectionProvider = part.getSite().getSelectionProvider(); - selectionProvider.addSelectionChangedListener(this); - - // Fake a selection changed event to update the menus. - // - if (selectionProvider.getSelection() != null) - { - selectionChanged(new [genModel.getImportedName('org.eclipse.jface.viewers.SelectionChangedEvent')/](selectionProvider, selectionProvider.getSelection())); - } - } - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionChangedListener}, - * handling {@link org.eclipse.jface.viewers.SelectionChangedEvent}s by querying for the children and siblings - * that can be added to the selected object and updating the menus accordingly. - * - * - * @generated - */ - public void selectionChanged([genModel.getImportedName('org.eclipse.jface.viewers.SelectionChangedEvent')/] event) - { -[if (genModel.creationCommands)] - // Remove any menu items for old selection. - // - if (createChildMenuManager != null) - { - [if (genModel.creationSubmenus)] - depopulateManager(createChildMenuManager, createChildSubmenuActions); - [/if] - depopulateManager(createChildMenuManager, createChildActions); - } - if (createSiblingMenuManager != null) - { - [if (genModel.creationSubmenus)] - depopulateManager(createSiblingMenuManager, createSiblingSubmenuActions); - [/if] - depopulateManager(createSiblingMenuManager, createSiblingActions); - } - - // Query the new selection for appropriate new child/sibling descriptors - // - [genModel._CollectionOfAnything()/] newChildDescriptors = null; - [genModel._CollectionOfAnything()/] newSiblingDescriptors = null; - - [genModel.getImportedName('org.eclipse.jface.viewers.ISelection')/] selection = event.getSelection(); - if (selection instanceof [genModel.getImportedName('org.eclipse.jface.viewers.IStructuredSelection')/] && ((IStructuredSelection)selection).size() == 1) - { - Object object = (([genModel.getImportedName('org.eclipse.jface.viewers.IStructuredSelection')/])selection).getFirstElement(); - - [genModel.getImportedName('org.eclipse.emf.edit.domain.EditingDomain')/] domain = (([genModel.getImportedName('org.eclipse.emf.edit.domain.IEditingDomainProvider')/])activeEditorPart).getEditingDomain(); - - newChildDescriptors = domain.getNewChildDescriptors(object, null); - newSiblingDescriptors = domain.getNewChildDescriptors(null, object); - } - - // Generate actions for selection; populate and redraw the menus. - // - createChildActions = generateCreateChildActions(newChildDescriptors, selection); - [if (genModel.creationSubmenus)] - createChildSubmenuActions = extractSubmenuActions(createChildActions); - [/if] - createSiblingActions = generateCreateSiblingActions(newSiblingDescriptors, selection); - [if (genModel.creationSubmenus)] - createSiblingSubmenuActions = extractSubmenuActions(createSiblingActions); - [/if] - - if (createChildMenuManager != null) - { - [if (genModel.creationSubmenus)] - populateManager(createChildMenuManager, createChildSubmenuActions, null); - [/if] - populateManager(createChildMenuManager, createChildActions, null); - createChildMenuManager.update(true); - } - if (createSiblingMenuManager != null) - { - [if (genModel.creationSubmenus)] - populateManager(createSiblingMenuManager, createSiblingSubmenuActions, null); - [/if] - populateManager(createSiblingMenuManager, createSiblingActions, null); - createSiblingMenuManager.update(true); - } -[else] - // Add your contributions. - // Ensure that you remove @generated or mark it @generated NOT -[/if] - } - -[if (genModel.creationCommands)] - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateChildAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected [genModel._CollectionOfIAction()/] generateCreateChildActions([genModel._CollectionOfAnything()/] descriptors, [genModel.getImportedName('org.eclipse.jface.viewers.ISelection')/] selection) - { - [genModel._CollectionOfIAction()/] actions = new [genModel._ArrayListOfIAction()/](); - if (descriptors != null) - { -[if (genModel.useGenerics())] - for ([genModel.getImportedName('java.lang.Object')/] descriptor : descriptors) -[else] - for ([genModel.getImportedName('java.util.Iterator')/] i = descriptors.iterator(); i.hasNext(); ) -[/if] - { - actions.add(new [genModel.getImportedName('org.eclipse.emf.edit.ui.action.CreateChildAction')/](activeEditorPart, selection, [if (genModel.useGenerics())]descriptor[else]i.next()[/if])); - } - } - return actions; - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected [genModel._CollectionOfIAction()/] generateCreateSiblingActions([genModel._CollectionOfAnything()/] descriptors, [genModel.getImportedName('org.eclipse.jface.viewers.ISelection')/] selection) - { - [genModel._CollectionOfIAction()/] actions = new [genModel._ArrayListOfIAction()/](); - if (descriptors != null) - { -[if (genModel.useGenerics())] - for ([genModel.getImportedName('java.lang.Object')/] descriptor : descriptors) -[else] - for ([genModel.getImportedName('java.util.Iterator')/] i = descriptors.iterator(); i.hasNext(); ) -[/if] - { - actions.add(new [genModel.getImportedName('org.eclipse.emf.edit.ui.action.CreateSiblingAction')/](activeEditorPart, selection, [if (genModel.useGenerics())]descriptor[else]i.next()[/if])); - } - } - return actions; - } - - /** - * This populates the specified manager with {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection, - * by inserting them before the specified contribution item contributionID. - * If contributionID is null, they are simply added. - * - * - * @generated - */ - protected void populateManager([genModel.getImportedName('org.eclipse.jface.action.IContributionManager')/] manager, [genModel._CollectionOfExtendsIAction()/] actions, String contributionID) - { - if (actions != null) - { -[if (genModel.useGenerics())] - for ([genModel.getImportedName('org.eclipse.jface.action.IAction')/] action : actions) -[else] - for ([genModel.getImportedName('java.util.Iterator')/] i = actions.iterator(); i.hasNext(); ) -[/if] - { -[if (not genModel.useGenerics())] - [genModel.getImportedName('org.eclipse.jface.action.IAction')/] action = (IAction)i.next(); -[/if] - if (contributionID != null) - { - manager.insertBefore(contributionID, action); - } - else - { - manager.add(action); - } - } - } - } - - /** - * This removes from the specified manager all {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection. - * - * - * @generated - */ - protected void depopulateManager([genModel.getImportedName('org.eclipse.jface.action.IContributionManager')/] manager, [genModel._CollectionOfExtendsIAction()/] actions) - { - if (actions != null) - { - [genModel.getImportedName('org.eclipse.jface.action.IContributionItem')/][genModel.genSquareBrackets('')/] items = manager.getItems(); - for (int i = 0; i < items.length; i++) - { - // Look into SubContributionItems - // - [genModel.getImportedName('org.eclipse.jface.action.IContributionItem')/] contributionItem = items[genModel.genSquareBrackets('i')/]; - while (contributionItem instanceof [genModel.getImportedName('org.eclipse.jface.action.SubContributionItem')/]) - { - contributionItem = (([genModel.getImportedName('org.eclipse.jface.action.SubContributionItem')/])contributionItem).getInnerItem(); - } - - // Delete the ActionContributionItems with matching action. - // - if (contributionItem instanceof [genModel.getImportedName('org.eclipse.jface.action.ActionContributionItem')/]) - { - [genModel.getImportedName('org.eclipse.jface.action.IAction')/] action = (([genModel.getImportedName('org.eclipse.jface.action.ActionContributionItem')/])contributionItem).getAction(); - if (actions.contains(action)) - { - manager.remove(contributionItem); - } - } - } - } - } - - [if (genModel.creationSubmenus)] - /** - * This extracts those actions in the submenuActions collection whose text is qualified and returns - * a map of these actions, keyed by submenu text. - * - * - * @generated - */ - protected [genModel._MapOfStringToCollectionOfIAction()/] extractSubmenuActions([genModel._CollectionOfIAction()/] createActions) - { - [genModel._MapOfStringToCollectionOfIAction()/] createSubmenuActions = new [genModel._LinkedHashMapOfStringToCollectionOfIAction()/](); - if (createActions != null) - { - for ([genModel._IteratorOfIAction()/] actions = createActions.iterator(); actions.hasNext(); ) - { - [genModel.getImportedName('org.eclipse.jface.action.IAction')/] action = [if (not genModel.useGenerics())]([genModel.getImportedName('org.eclipse.jface.action.IAction')/])[/if]actions.next(); - [genModel.getImportedName('java.util.StringTokenizer')/] st = new [genModel.getImportedName('java.util.StringTokenizer')/](action.getText(), "|");[genModel.getNonNLS()/] - if (st.countTokens() == 2) - { - String text = st.nextToken().trim(); - [genModel._CollectionOfIAction()/] submenuActions = [if ( not genModel.useGenerics())]([genModel._CollectionOfIAction()/])[/if]createSubmenuActions.get(text); - if (submenuActions == null) - { - createSubmenuActions.put(text, submenuActions = new [genModel._ArrayListOfIAction()/]()); - } - action.setText(st.nextToken().trim()); - submenuActions.add(action); - actions.remove(); - } - } - } - return createSubmenuActions; - } - - /** - * This populates the specified manager with {@link org.eclipse.jface.action.MenuManager}s containing - * {@link org.eclipse.jface.action.ActionContributionItem}s based on the {@link org.eclipse.jface.action.IAction}s - * contained in the submenuActions collection, by inserting them before the specified contribution - * item contributionID. - * If contributionID is null, they are simply added. - * - * - * @generated - */ - protected void populateManager([genModel.getImportedName('org.eclipse.jface.action.IContributionManager')/] manager, [genModel._MapOfStringToCollectionOfIAction()/] submenuActions, String contributionID) - { - if (submenuActions != null) - { - [if (genModel.complianceLevel = GenJDKLevel::JDK14)] - for ([genModel.getImportedName('java.util.Iterator')/] entries = submenuActions.entrySet().iterator(); entries.hasNext();) - { - [genModel._MapEntryOfStringToCollectionOfIAction()/] entry = ([genModel._MapEntryOfStringToCollectionOfIAction()/])entries.next(); - [else] - for ([genModel._MapEntryOfStringToCollectionOfIAction()/] entry : submenuActions.entrySet()) - { - [/if] - [genModel.getImportedName('org.eclipse.jface.action.MenuManager')/] submenuManager = new [genModel.getImportedName('org.eclipse.jface.action.MenuManager')/]([if (not genModel.useGenerics())](String)[/if]entry.getKey()); - if (contributionID != null) - { - manager.insertBefore(contributionID, submenuManager); - } - else - { - manager.add(submenuManager); - } - populateManager(submenuManager, [if (not genModel.useGenerics())]([genModel._CollectionOfIAction()/])[/if]entry.getValue(), null); - } - } - } - - /** - * This removes from the specified manager all {@link org.eclipse.jface.action.MenuManager}s and their - * {@link org.eclipse.jface.action.ActionContributionItem}s based on the {@link org.eclipse.jface.action.IAction}s - * contained in the submenuActions map. - * - * - * @generated - */ - protected void depopulateManager([genModel.getImportedName('org.eclipse.jface.action.IContributionManager')/] manager, [genModel._MapOfStringToCollectionOfIAction()/] submenuActions) - { - if (submenuActions != null) - { - [genModel.getImportedName('org.eclipse.jface.action.IContributionItem')/][genModel.genSquareBrackets('')/] items = manager.getItems(); - for (int i = 0; i < items.length; i++) - { - [genModel.getImportedName('org.eclipse.jface.action.IContributionItem')/] contributionItem = items[genModel.genSquareBrackets('i')/]; - if (contributionItem instanceof [genModel.getImportedName('org.eclipse.jface.action.MenuManager')/]) - { - [genModel.getImportedName('org.eclipse.jface.action.MenuManager')/] submenuManager = ([genModel.getImportedName('org.eclipse.jface.action.MenuManager')/])contributionItem; - if (submenuActions.containsKey(submenuManager.getMenuText())) - { - depopulateManager(submenuManager, [if (not genModel.useGenerics())]([genModel._CollectionOfIAction()/])[/if]submenuActions.get(contributionItem)); - manager.remove(contributionItem); - } - } - } - } - } - - [/if] -[/if] - /** - * This populates the pop-up menu before it appears. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void menuAboutToShow([genModel.getImportedName('org.eclipse.jface.action.IMenuManager')/] menuManager) - { - super.menuAboutToShow(menuManager); -[if (genModel.creationCommands)] - [genModel.getImportedName('org.eclipse.jface.action.MenuManager')/] submenuManager = null; - - submenuManager = new [genModel.getImportedName('org.eclipse.jface.action.MenuManager')/]([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_CreateChild_menu_item"));[genModel.getNonNLS()/] - [if (genModel.creationSubmenus)] - populateManager(submenuManager, createChildSubmenuActions, null); - [/if] - populateManager(submenuManager, createChildActions, null); - menuManager.insertBefore("edit", submenuManager);[genModel.getNonNLS()/] - - submenuManager = new [genModel.getImportedName('org.eclipse.jface.action.MenuManager')/]([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_CreateSibling_menu_item"));[genModel.getNonNLS()/] - [if (genModel.creationSubmenus)] - populateManager(submenuManager, createSiblingSubmenuActions, null); - [/if] - populateManager(submenuManager, createSiblingActions, null); - menuManager.insertBefore("edit", submenuManager);[genModel.getNonNLS()/] -[/if] - } - - /** - * This inserts global actions before the "additions-end" separator. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected void addGlobalActions([genModel.getImportedName('org.eclipse.jface.action.IMenuManager')/] menuManager) - { - menuManager.insertAfter("additions-end", new [genModel.getImportedName('org.eclipse.jface.action.Separator')/]("ui-actions"));[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - menuManager.insertAfter("ui-actions", showPropertiesViewAction);[genModel.getNonNLS()/] - - refreshViewerAction.setEnabled(refreshViewerAction.isEnabled()); - menuManager.insertAfter("ui-actions", refreshViewerAction);[genModel.getNonNLS()/] - - super.addGlobalActions(menuManager); - } - - /** - * This ensures that a delete action will clean up all references to deleted objects. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected boolean removeAllReferencesOnDelete() - { - return true; - } - -} -[/template] - -[template protected _CollectionOfAnything (genModel : GenModel)] -[if genModel.useGenerics()]Collection[else]Collection[/if] -[/template] - -[template protected _CollectionOfIAction (genModel : GenModel)] -[if genModel.useGenerics()][genModel.getImportedName('java.util.Collection')/]<[genModel.getImportedName('org.eclipse.jface.action.IAction')/]>[else][genModel.getImportedName('java.util.Collection')/][/if] -[/template] - -[template protected _ArrayListOfIAction (genModel : GenModel)] -[if genModel.useGenerics()][genModel.getImportedName('java.util.ArrayList')/]<[genModel.getImportedName('org.eclipse.jface.action.IAction')/]>[else][genModel.getImportedName('java.util.ArrayList')/][/if] -[/template] - -[template protected _CollectionOfExtendsIAction (genModel : GenModel)] -[if genModel.useGenerics()][genModel.getImportedName('java.util.Collection')/][else][genModel.getImportedName('java.util.Collection')/][/if] -[/template] - -[template protected _IteratorOfIAction (genModel : GenModel)] -[if genModel.useGenerics()][genModel.getImportedName('java.util.Iterator')/]<[genModel.getImportedName('org.eclipse.jface.action.IAction')/]>[else][genModel.getImportedName('java.util.Iterator')/][/if] -[/template] - -[template protected _MapOfStringToCollectionOfIAction (genModel : GenModel)] -[if genModel.useGenerics()][genModel.getImportedName('java.util.Map')/][else][genModel.getImportedName('java.util.Map')/][/if] -[/template] - -[template protected _MapEntryOfStringToCollectionOfIAction (genModel : GenModel)] -[if genModel.useGenerics()][genModel.getImportedName('java.util.Map')/].Entry[else][genModel.getImportedName('java.util.Map')/].Entry[/if] -[/template] - -[template protected _LinkedHashMapOfStringToCollectionOfIAction (genModel : GenModel)] -[if genModel.useGenerics()][genModel.getImportedName('java.util.LinkedHashMap')/][else][genModel.getImportedName('java.util.LinkedHashMap')/][/if] -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/Editor.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/Editor.mtl deleted file mode 100644 index 5e69e4919..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/Editor.mtl +++ /dev/null @@ -1,2434 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module Editor('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[template public Editor(genPackage : GenPackage) {genModel : GenModel = genPackage.genModel ; packageName : String = genPackage.getPresentationPackageName() ; className : String = genPackage.getEditorClassName()}] -[genModel.initializeImportManager(packageName, className)/] - -[file (genModel.editorPath(packageName, className), false, 'UTF-8')] -[includeHeader()/] -package [packageName/]; - -[genModel.addImportHere('java.io.IOException')/] -[genModel.addImportHere('java.io.InputStream')/] - -[genModel.addImportHere('java.util.ArrayList')/] -[genModel.addImportHere('java.util.Collection')/] -[genModel.addImportHere('java.util.Collections')/] -[genModel.addImportHere('java.util.EventObject')/] -[genModel.addImportHere('java.util.HashMap')/] -[genModel.addImportHere('java.util.Iterator')/] -[genModel.addImportHere('java.util.LinkedHashMap')/] -[genModel.addImportHere('java.util.List')/] -[genModel.addImportHere('java.util.Map')/] -[if (not genModel.richClientPlatform)] - -[genModel.addImportHere('org.eclipse.core.resources.IFile')/] -[genModel.addImportHere('org.eclipse.core.resources.IMarker')/] -[genModel.addImportHere('org.eclipse.core.resources.IResource')/] -[genModel.addImportHere('org.eclipse.core.resources.IResourceChangeEvent')/] -[genModel.addImportHere('org.eclipse.core.resources.IResourceChangeListener')/] -[genModel.addImportHere('org.eclipse.core.resources.IResourceDelta')/] -[genModel.addImportHere('org.eclipse.core.resources.IResourceDeltaVisitor')/] -[genModel.addImportHere('org.eclipse.core.resources.ResourcesPlugin')/] -[/if] - -[if (not genModel.richClientPlatform)] -[genModel.addImportHere('org.eclipse.core.runtime.CoreException')/] -[genModel.addImportHere('org.eclipse.core.runtime.IPath')/] -[/if] -[genModel.addImportHere('org.eclipse.core.runtime.IProgressMonitor')/] -[genModel.addImportHere('org.eclipse.core.runtime.NullProgressMonitor')/] - -[genModel.addImportHere('org.eclipse.jface.action.IMenuListener')/] -[genModel.addImportHere('org.eclipse.jface.action.IMenuManager')/] -[genModel.addImportHere('org.eclipse.jface.action.IStatusLineManager')/] -[genModel.addImportHere('org.eclipse.jface.action.IToolBarManager')/] -[genModel.addImportHere('org.eclipse.jface.action.MenuManager')/] -[genModel.addImportHere('org.eclipse.jface.action.Separator')/] - -[genModel.addImportHere('org.eclipse.jface.dialogs.MessageDialog')/] -[genModel.addImportHere('org.eclipse.jface.dialogs.ProgressMonitorDialog')/] - -[if (genPackage.multipleEditorPages)] -[genModel.addImportHere('org.eclipse.jface.viewers.ColumnWeightData')/] -[/if] -[genModel.addImportHere('org.eclipse.jface.viewers.ISelection')/] -[genModel.addImportHere('org.eclipse.jface.viewers.ISelectionChangedListener')/] -[genModel.addImportHere('org.eclipse.jface.viewers.ISelectionProvider')/] -[genModel.addImportHere('org.eclipse.jface.viewers.IStructuredSelection')/] -[if (genPackage.multipleEditorPages)] -[genModel.addImportHere('org.eclipse.jface.viewers.ListViewer')/] -[/if] -[genModel.addImportHere('org.eclipse.jface.viewers.SelectionChangedEvent')/] -[genModel.addImportHere('org.eclipse.jface.viewers.StructuredSelection')/] -[genModel.addImportHere('org.eclipse.jface.viewers.StructuredViewer')/] -[if (genPackage.multipleEditorPages)] -[genModel.addImportHere('org.eclipse.jface.viewers.TableLayout')/] -[genModel.addImportHere('org.eclipse.jface.viewers.TableViewer')/] -[/if] -[genModel.addImportHere('org.eclipse.jface.viewers.TreeViewer')/] -[genModel.addImportHere('org.eclipse.jface.viewers.Viewer')/] - -[genModel.addImportHere('org.eclipse.swt.SWT')/] - -[genModel.addImportHere('org.eclipse.swt.custom.CTabFolder')/] - -[genModel.addImportHere('org.eclipse.swt.dnd.DND')/] -[genModel.addImportHere('org.eclipse.swt.dnd.Transfer')/] - -[genModel.addImportHere('org.eclipse.swt.events.ControlAdapter')/] -[genModel.addImportHere('org.eclipse.swt.events.ControlEvent')/] - -[genModel.addImportHere('org.eclipse.swt.graphics.Point')/] -[if (genPackage.multipleEditorPages)] - -[genModel.addImportHere('org.eclipse.swt.layout.FillLayout')/] -[/if] - -[genModel.addImportHere('org.eclipse.swt.widgets.Composite')/] -[genModel.addImportHere('org.eclipse.swt.widgets.Menu')/] -[if (genPackage.multipleEditorPages)] -[genModel.addImportHere('org.eclipse.swt.widgets.Table')/] -[genModel.addImportHere('org.eclipse.swt.widgets.TableColumn')/] -[/if] -[genModel.addImportHere('org.eclipse.swt.widgets.Tree')/] -[if (genPackage.multipleEditorPages)] -[genModel.addImportHere('org.eclipse.swt.widgets.TreeColumn')/] -[/if] - -[genModel.addImportHere('org.eclipse.ui.IActionBars')/] -[genModel.addImportHere('org.eclipse.ui.IEditorInput')/] -[genModel.addImportHere('org.eclipse.ui.IEditorPart')/] -[genModel.addImportHere('org.eclipse.ui.IEditorSite')/] -[if (not genModel.richClientPlatform and genModel.complianceLevel = GenJDKLevel::JDK14)] -[genModel.addImportHere('org.eclipse.ui.IFileEditorInput')/] -[/if] -[genModel.addImportHere('org.eclipse.ui.IPartListener')/] -[genModel.addImportHere('org.eclipse.ui.IWorkbenchPart')/] -[genModel.addImportHere('org.eclipse.ui.PartInitException')/] -[if (not genModel.richClientPlatform)] - -[genModel.addImportHere('org.eclipse.ui.dialogs.SaveAsDialog')/] - -[genModel.addImportHere('org.eclipse.ui.ide.IGotoMarker')/] -[/if] - -[if (not genModel.richClientPlatform)] -[genModel.addImportHere('org.eclipse.ui.part.FileEditorInput')/] -[/if] -[genModel.addImportHere('org.eclipse.ui.part.MultiPageEditorPart')/] - -[genModel.addImportHere('org.eclipse.ui.views.contentoutline.ContentOutline')/] -[genModel.addImportHere('org.eclipse.ui.views.contentoutline.ContentOutlinePage')/] -[genModel.addImportHere('org.eclipse.ui.views.contentoutline.IContentOutlinePage')/] - -[genModel.addImportHere('org.eclipse.ui.views.properties.IPropertySheetPage')/] -[genModel.addImportHere('org.eclipse.ui.views.properties.PropertySheet')/] -[genModel.addImportHere('org.eclipse.ui.views.properties.PropertySheetPage')/] - -[genModel.addImportHere('org.eclipse.emf.common.command.BasicCommandStack')/] -[genModel.addImportHere('org.eclipse.emf.common.command.Command')/] -[genModel.addImportHere('org.eclipse.emf.common.command.CommandStack')/] -[genModel.addImportHere('org.eclipse.emf.common.command.CommandStackListener')/] - -[genModel.addImportHere('org.eclipse.emf.common.notify.AdapterFactory')/] -[genModel.addImportHere('org.eclipse.emf.common.notify.Notification')/] - -[if (not genModel.richClientPlatform)] -[genModel.addImportHere('org.eclipse.emf.common.ui.MarkerHelper')/] -[/if] -[if (genPackage.multipleEditorPages)] -[genModel.addImportHere('org.eclipse.emf.common.ui.ViewerPane')/] -[/if] - -[genModel.addImportHere('org.eclipse.emf.common.ui.editor.ProblemEditorPart')/] - -[genModel.addImportHere('org.eclipse.emf.common.ui.viewer.IViewerProvider')/] - -[genModel.addImportHere('org.eclipse.emf.common.util.BasicDiagnostic')/] -[genModel.addImportHere('org.eclipse.emf.common.util.Diagnostic')/] -[genModel.addImportHere('org.eclipse.emf.common.util.URI')/] - -[if (not genModel.richClientPlatform)] -[genModel.addImportHere('org.eclipse.emf.ecore.EObject')/] -[genModel.addImportHere('org.eclipse.emf.ecore.EValidator')/] -[/if] - -[genModel.addImportHere('org.eclipse.emf.ecore.resource.Resource')/] -[if (not genModel.richClientPlatform)] -[genModel.addImportHere('org.eclipse.emf.ecore.resource.ResourceSet')/] -[/if] - -[genModel.addImportHere('org.eclipse.emf.ecore.util.EContentAdapter')/] -[genModel.addImportHere('org.eclipse.emf.ecore.util.EcoreUtil')/] - -[genModel.addImportHere('org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain')/] -[genModel.addImportHere('org.eclipse.emf.edit.domain.EditingDomain')/] -[genModel.addImportHere('org.eclipse.emf.edit.domain.IEditingDomainProvider')/] - -[genModel.addImportHere('org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator')/] -[genModel.addImportHere('org.eclipse.emf.edit.provider.ComposedAdapterFactory')/] -[genModel.addImportHere('org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory')/] - -[genModel.addImportHere('org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory')/] - -[genModel.addImportHere('org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor')/] - -[genModel.addImportHere('org.eclipse.emf.edit.ui.celleditor.AdapterFactoryTreeEditor')/] - -[genModel.addImportHere('org.eclipse.emf.edit.ui.dnd.EditingDomainViewerDropAdapter')/] -[genModel.addImportHere('org.eclipse.emf.edit.ui.dnd.LocalTransfer')/] -[genModel.addImportHere('org.eclipse.emf.edit.ui.dnd.ViewerDragAdapter')/] - -[genModel.addImportHere('org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider')/] -[genModel.addImportHere('org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider')/] -[if (genModel.runtimeVersion <> GenRuntimeVersion::EMF22)] -[genModel.addImportHere('org.eclipse.emf.edit.ui.provider.UnwrappingSelectionProvider')/] -[/if] -[if (not genModel.richClientPlatform)] - -[genModel.addImportHere('org.eclipse.emf.edit.ui.util.EditUIMarkerHelper')/] -[/if] -[if (genModel.complianceLevel <> GenJDKLevel::JDK14)] -[genModel.addImportHere('org.eclipse.emf.edit.ui.util.EditUIUtil')/] -[/if] - -[genModel.addImportHere('org.eclipse.emf.edit.ui.view.ExtendedPropertySheetPage')/] - -[genModel.addImportHere(genPackage.getQualifiedItemProviderAdapterFactoryClassName())/] - -[let content : String = genModel.fileContent(genPackage, genModel, packageName, className)] -[genModel.genSortedImports()/] - -[content/] -[/let] -[/file] -[/template] - -[template public fileContent(genPackage : GenPackage, genModel : GenModel, packageName : String, className : String)] -/** - * This is an example of a [genPackage.prefix/] model editor. - * - * - * @generated - */ -public class [className/] - extends MultiPageEditorPart - implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider[if (not genModel.richClientPlatform)], IGotoMarker[/if] -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] -[if (genModel.richClientPlatform)] - /** - * The filters for file extensions supported by the editor. - * - * - * @generated - */[if (genPackage.generateModelWizard)] - public static final [genModel._ListOfString()/] FILE_EXTENSION_FILTERS = prefixExtensions([genPackage.getImportedModelWizardClassName()/].FILE_EXTENSIONS, "*.");[genModel.getNonNLS()/] - [else] - public static final [genModel._ListOfString()/] FILE_EXTENSION_FILTERS = prefixExtensions([genModel.getImportedName('java.util.Arrays')/].asList([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_[genPackage.getEditorClassName()/]FilenameExtensions").split("\\s*,\\s*")), "*.");[genModel.getNonNLS()/][genModel.getNonNLS(2)/][genModel.getNonNLS(3)/] - [/if] - /** - * Returns a new unmodifiable list containing prefixed versions of the extensions in the given list. - * - * - * @generated - */ - private static [genModel._ListOfString()/] prefixExtensions([genModel._ListOfString()/] extensions, String prefix) - { - [genModel._ListOfString()/] result = new [genModel._ArrayListOfString()/](); - [if (genModel.useGenerics())] - for (String extension : extensions) - { - result.add(prefix + extension); - [ else ] - for (Iterator iterator = extensions.iterator() ; iterator.hasNext(); ) - { - result.add(prefix + (String)iterator.next()); - [/if] - } - return Collections.unmodifiableList(result); - } - -[/if] - /** - * This keeps track of the editing domain that is used to track all changes to the model. - * - * - * @generated - */ - protected AdapterFactoryEditingDomain editingDomain; - - /** - * This is the one adapter factory used for providing views of the model. - * - * - * @generated - */ - protected ComposedAdapterFactory adapterFactory; - - /** - * This is the content outline page. - * - * - * @generated - */ - protected IContentOutlinePage contentOutlinePage; - - /** - * This is a kludge... - * - * - * @generated - */ - protected IStatusLineManager contentOutlineStatusLineManager; - - /** - * This is the content outline page's viewer. - * - * - * @generated - */ - protected TreeViewer contentOutlineViewer; - - /** - * This is the property sheet page. - * - * - * @generated - */ - protected PropertySheetPage propertySheetPage; - - /** - * This is the viewer that shadows the selection in the content outline. - * The parent relation must be correctly defined for this to work. - * - * - * @generated - */ - protected TreeViewer selectionViewer; -[if (genPackage.multipleEditorPages)] - - /** - * This inverts the roll of parent and child in the content provider and show parents as a tree. - * - * - * @generated - */ - protected TreeViewer parentViewer; - - /** - * This shows how a tree view works. - * - * - * @generated - */ - protected TreeViewer treeViewer; - - /** - * This shows how a list view works. - * A list viewer doesn't support icons. - * - * - * @generated - */ - protected ListViewer listViewer; - - /** - * This shows how a table view works. - * A table can be used as a list with icons. - * - * - * @generated - */ - protected TableViewer tableViewer; - - /** - * This shows how a tree view with columns works. - * - * - * @generated - */ - protected TreeViewer treeViewerWithColumns; - - /** - * This keeps track of the active viewer pane, in the book. - * - * - * @generated - */ - protected ViewerPane currentViewerPane; -[/if] - - /** - * This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer. - * - * - * @generated - */ - protected Viewer currentViewer; - - /** - * This listens to which ever viewer is active. - * - * - * @generated - */ - protected ISelectionChangedListener selectionChangedListener; - - /** - * This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor. - * - * - * @generated - */ - protected [genModel._CollectionOfSelectionChangedListener()/] selectionChangedListeners = new [genModel._ArrayListOfSelectionChangedListener()/](); - - /** - * This keeps track of the selection of the editor as a whole. - * - * - * @generated - */ - protected ISelection editorSelection = StructuredSelection.EMPTY; - -[if (not genModel.richClientPlatform)] - /** - * The MarkerHelper is responsible for creating workspace resource markers presented - * in Eclipse's Problems View. - * - * - * @generated - */ - protected MarkerHelper markerHelper = new EditUIMarkerHelper(); - -[/if] - /** - * This listens for when the outline becomes active - * - * - * @generated - */ - protected IPartListener partListener = - new IPartListener() - { - public void partActivated(IWorkbenchPart p) - { - if (p instanceof ContentOutline) - { - if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) - { - getActionBarContributor().setActiveEditor([genPackage.getEditorClassName()/].this); - - setCurrentViewer(contentOutlineViewer); - } - } - else if (p instanceof PropertySheet) - { - if (((PropertySheet)p).getCurrentPage() == propertySheetPage) - { - getActionBarContributor().setActiveEditor([genPackage.getEditorClassName()/].this); - handleActivate(); - } - } - else if (p == [genPackage.getEditorClassName()/].this) - { - handleActivate(); - } - } - public void partBroughtToTop(IWorkbenchPart p) - { - // Ignore. - } - public void partClosed(IWorkbenchPart p) - { - // Ignore. - } - public void partDeactivated(IWorkbenchPart p) - { - // Ignore. - } - public void partOpened(IWorkbenchPart p) - { - // Ignore. - } - }; - - /** - * Resources that have been removed since last activation. - * - * - * @generated - */ - protected [genModel._CollectionOfResource()/] removedResources = new [genModel._ArrayListOfResource()/](); - - /** - * Resources that have been changed since last activation. - * - * - * @generated - */ - protected [genModel._CollectionOfResource()/] changedResources = new [genModel._ArrayListOfResource()/](); - - /** - * Resources that have been saved. - * - * - * @generated - */ - protected [genModel._CollectionOfResource()/] savedResources = new [genModel._ArrayListOfResource()/](); - - /** - * Map to store the diagnostic associated with a resource. - * - * - * @generated - */ - protected [genModel._MapOfResourceToDiagnostic()/] resourceToDiagnosticMap = new [genModel._LinkedHashMapOfResourceToDiagnostic()/](); - - /** - * Controls whether the problem indication should be updated. - * - * - * @generated - */ - protected boolean updateProblemIndication = true; - - /** - * Adapter used to update the problem indication when resources are demanded loaded. - * - * - * @generated - */ - protected EContentAdapter problemIndicationAdapter = - new EContentAdapter() - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void notifyChanged(Notification notification) - { - if (notification.getNotifier() instanceof Resource) - { - switch (notification.getFeatureID(Resource.class)) - { - case Resource.RESOURCE__IS_LOADED: - case Resource.RESOURCE__ERRORS: - case Resource.RESOURCE__WARNINGS: - { - Resource resource = (Resource)notification.getNotifier(); - Diagnostic diagnostic = analyzeResourceProblems(resource, null); - if (diagnostic.getSeverity() != Diagnostic.OK) - { - resourceToDiagnosticMap.put(resource, diagnostic); - } - else - { - resourceToDiagnosticMap.remove(resource); - } - - if (updateProblemIndication) - { - getSite().getShell().getDisplay().asyncExec - (new Runnable() - { - public void run() - { - updateProblemIndication(); - } - }); - } - break; - } - } - } - else - { - super.notifyChanged(notification); - } - } - -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected void setTarget(Resource target) - { - basicSetTarget(target); - } - -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected void unsetTarget(Resource target) - { - basicUnsetTarget(target); - } - }; -[if (not genModel.richClientPlatform)] - - /** - * This listens for workspace changes. - * - * - * @generated - */ - protected IResourceChangeListener resourceChangeListener = - new IResourceChangeListener() - { - public void resourceChanged(IResourceChangeEvent event) - { - IResourceDelta delta = event.getDelta(); - try - { - class ResourceDeltaVisitor implements IResourceDeltaVisitor - { - protected ResourceSet resourceSet = editingDomain.getResourceSet(); - protected [genModel._CollectionOfResource()/] changedResources = new [genModel._ArrayListOfResource()/](); - protected [genModel._CollectionOfResource()/] removedResources = new [genModel._ArrayListOfResource()/](); - - public boolean visit(IResourceDelta delta) - { - if (delta.getResource().getType() == IResource.FILE) - { - if (delta.getKind() == IResourceDelta.REMOVED || - delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) - { - Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false); - if (resource != null) - { - if (delta.getKind() == IResourceDelta.REMOVED) - { - removedResources.add(resource); - } - else if (!savedResources.remove(resource)) - { - changedResources.add(resource); - } - } - } - } - - return true; - } - - public [genModel._CollectionOfResource()/] getChangedResources() - { - return changedResources; - } - - public [genModel._CollectionOfResource()/] getRemovedResources() - { - return removedResources; - } - } - - final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor(); - delta.accept(visitor); - - if (!visitor.getRemovedResources().isEmpty()) - { - getSite().getShell().getDisplay().asyncExec - (new Runnable() - { - public void run() - { - removedResources.addAll(visitor.getRemovedResources()); - if (!isDirty()) - { - getSite().getPage().closeEditor([genPackage.getEditorClassName()/].this, false); - } - } - }); - } - - if (!visitor.getChangedResources().isEmpty()) - { - getSite().getShell().getDisplay().asyncExec - (new Runnable() - { - public void run() - { - changedResources.addAll(visitor.getChangedResources()); - if (getSite().getPage().getActiveEditor() == [genPackage.getEditorClassName()/].this) - { - handleActivate(); - } - } - }); - } - } - catch (CoreException exception) - { - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.log(exception); - } - } - }; -[/if] - - /** - * Handles activation of the editor or it's associated views. - * - * - * @generated - */ - protected void handleActivate() - { - // Recompute the read only state. - // - if (editingDomain.getResourceToReadOnlyMap() != null) - { - editingDomain.getResourceToReadOnlyMap().clear(); - - // Refresh any actions that may become enabled or disabled. - // - setSelection(getSelection()); - } - - if (!removedResources.isEmpty()) - { - if (handleDirtyConflict()) - { - getSite().getPage().closeEditor([genPackage.getEditorClassName()/].this, false); - } - else - { - removedResources.clear(); - changedResources.clear(); - savedResources.clear(); - } - } - else if (!changedResources.isEmpty()) - { - changedResources.removeAll(savedResources); - handleChangedResources(); - changedResources.clear(); - savedResources.clear(); - } - } - - /** - * Handles what to do with changed resources on activation. - * - * - * @generated - */ - protected void handleChangedResources() - { - if (!changedResources.isEmpty() && (!isDirty() || handleDirtyConflict())) - { - if (isDirty()) - { - changedResources.addAll(editingDomain.getResourceSet().getResources()); - } - editingDomain.getCommandStack().flush(); - - updateProblemIndication = false; -[if (genModel.useGenerics())] - for (Resource resource : changedResources) -[else] - for (Iterator i = changedResources.iterator(); i.hasNext(); ) -[/if] - { -[if ( not genModel.useGenerics())] - Resource resource = (Resource)i.next(); -[/if] - if (resource.isLoaded()) - { - resource.unload(); - try - { - resource.load(Collections.EMPTY_MAP); - } - catch (IOException exception) - { - if (!resourceToDiagnosticMap.containsKey(resource)) - { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - } - } - } - -[if (not (genModel.runtimeVersion = GenRuntimeVersion::EMF22 or genModel.runtimeVersion = GenRuntimeVersion::EMF23))] - if (AdapterFactoryEditingDomain.isStale(editorSelection)) - { - setSelection(StructuredSelection.EMPTY); - } -[/if] - - updateProblemIndication = true; - updateProblemIndication(); - } - } - - /** - * Updates the problems indication with the information described in the specified diagnostic. - * - * - * @generated - */ - protected void updateProblemIndication() - { - if (updateProblemIndication) - { - BasicDiagnostic diagnostic = - new BasicDiagnostic - (Diagnostic.OK, - "[genPackage.genModel.editorPluginID/]",[genModel.getNonNLS()/] - 0, - null, - new Object [genModel.genSquareBrackets('')/] { editingDomain.getResourceSet() }); -[if (genModel.useGenerics())] - for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) -[else] - for (Iterator i = resourceToDiagnosticMap.values().iterator(); i.hasNext(); ) -[/if] - { -[if (not genModel.useGenerics())] - Diagnostic childDiagnostic = (Diagnostic)i.next(); -[/if] - if (childDiagnostic.getSeverity() != Diagnostic.OK) - { - diagnostic.add(childDiagnostic); - } - } - - int lastEditorPage = getPageCount() - 1; - if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) - { - ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic); - if (diagnostic.getSeverity() != Diagnostic.OK) - { - setActivePage(lastEditorPage); - } - } - else if (diagnostic.getSeverity() != Diagnostic.OK) - { - ProblemEditorPart problemEditorPart = new ProblemEditorPart(); - problemEditorPart.setDiagnostic(diagnostic); -[if ( not genModel.richClientPlatform)] - problemEditorPart.setMarkerHelper(markerHelper); -[/if] - try - { - addPage(++lastEditorPage, problemEditorPart, getEditorInput()); - setPageText(lastEditorPage, problemEditorPart.getPartName()); - setActivePage(lastEditorPage); - showTabs(); - } - catch (PartInitException exception) - { - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.log(exception); - } - } -[if (not genModel.richClientPlatform)] - - if (markerHelper.hasMarkers(editingDomain.getResourceSet())) - { - markerHelper.deleteMarkers(editingDomain.getResourceSet()); - if (diagnostic.getSeverity() != Diagnostic.OK) - { - try - { - markerHelper.createMarkers(diagnostic); - } - catch (CoreException exception) - { - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.log(exception); - } - } - } -[/if] - } - } - - /** - * Shows a dialog that asks if conflicting changes should be discarded. - * - * - * @generated - */ - protected boolean handleDirtyConflict() - { - return - MessageDialog.openQuestion - (getSite().getShell(), - getString("_UI_FileConflict_label"),[genModel.getNonNLS()/] - getString("_WARN_FileConflict"));[genModel.getNonNLS()/] - } - - /** - * This creates a model editor. - * - * - * @generated - */ - public [genPackage.getEditorClassName()/]() - { - super(); - initializeEditingDomain(); - } - - /** - * This sets up the editing domain for the model editor. - * - * - * @generated - */ - protected void initializeEditingDomain() - { - // Create an adapter factory that yields item providers. - // - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - - adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory()); -[comment]<%@ include file="Editor/addItemProviderFactories.override.javajetinc" fail="alternative"%> -<%@ start%>[/comment] -[for (aGenPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers())] - [if (not aGenPackage.genClasses->isEmpty() and aGenPackage.genModel.hasEditSupport())] - adapterFactory.addAdapterFactory(new [aGenPackage.getImportedItemProviderAdapterFactoryClassName()/]()); - [/if] -[/for] -[for (aGenPackage : GenPackage | genModel.getAllUsedGenPackagesWithClassifiers())] - [if (not aGenPackage.genClasses->isEmpty() and aGenPackage.genModel.hasEditSupport())] - adapterFactory.addAdapterFactory(new [aGenPackage.getImportedItemProviderAdapterFactoryClassName()/]()); - [/if] -[/for] -[comment]<%@ include file="Editor/addItemProviderFactories.insert.javajetinc" fail="silent"%> -<%@end%><%//Editor/addItemproviderFactories.override.javajetinc"%>[/comment] - adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory()); - - // Create the command stack that will notify this editor as commands are executed. - // - BasicCommandStack commandStack = new BasicCommandStack(); - - // Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus. - // - commandStack.addCommandStackListener - (new CommandStackListener() - { - public void commandStackChanged(final EventObject event) - { - getContainer().getDisplay().asyncExec - (new Runnable() - { - public void run() - { - firePropertyChange(IEditorPart.PROP_DIRTY); - - // Try to select the affected objects. - // - Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand(); - if (mostRecentCommand != null) - { - setSelectionToViewer(mostRecentCommand.getAffectedObjects()); - } - if (propertySheetPage != null && !propertySheetPage.getControl().isDisposed()) - { - propertySheetPage.refresh(); - } - } - }); - } - }); - - // Create the editing domain with a special command stack. - // - editingDomain = new AdapterFactoryEditingDomain(adapterFactory, commandStack, new [genModel._HashMapOfResourceToBoolean()/]()); - } - - /** - * This is here for the listener to be able to call it. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected void firePropertyChange(int action) - { - super.firePropertyChange(action); - } - - /** - * This sets the selection into whichever viewer is active. - * - * - * @generated - */ - public void setSelectionToViewer([genModel._CollectionOfAnything()/] collection) - { - final [genModel._CollectionOfAnything()/] theSelection = collection; - // Make sure it's okay. - // - if (theSelection != null && !theSelection.isEmpty()) - { - Runnable runnable = - new Runnable() - { - public void run() - { - // Try to select the items in the current content viewer of the editor. - // - if (currentViewer != null) - { - currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true); - } - } - }; - getSite().getShell().getDisplay().asyncExec(runnable); - } - } - - /** - * This returns the editing domain as required by the {@link IEditingDomainProvider} interface. - * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} - * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}. - * - * - * @generated - */ - public EditingDomain getEditingDomain() - { - return editingDomain; - } - - /** - * - * - * @generated - */ - public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider - { - /** - * - * - * @generated - */ - public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) - { - super(adapterFactory); - } - - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Object [genModel.genSquareBrackets('')/] getElements(Object object) - { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Object [genModel.genSquareBrackets('')/] getChildren(Object object) - { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public boolean hasChildren(Object object) - { - Object parent = super.getParent(object); - return parent != null; - } - - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Object getParent(Object object) - { - return null; - } - } -[if (genPackage.multipleEditorPages)] - - /** - * - * - * @generated - */ - public void setCurrentViewerPane(ViewerPane viewerPane) - { - if (currentViewerPane != viewerPane) - { - if (currentViewerPane != null) - { - currentViewerPane.showFocus(false); - } - currentViewerPane = viewerPane; - } - setCurrentViewer(currentViewerPane.getViewer()); - } -[/if] - - /** - * This makes sure that one content viewer, either for the current page or the outline view, if it has focus, - * is the current one. - * - * - * @generated - */ - public void setCurrentViewer(Viewer viewer) - { - // If it is changing... - // - if (currentViewer != viewer) - { - if (selectionChangedListener == null) - { - // Create the listener on demand. - // - selectionChangedListener = - new ISelectionChangedListener() - { - // This just notifies those things that are affected by the section. - // - public void selectionChanged(SelectionChangedEvent selectionChangedEvent) - { - setSelection(selectionChangedEvent.getSelection()); - } - }; - } - - // Stop listening to the old one. - // - if (currentViewer != null) - { - currentViewer.removeSelectionChangedListener(selectionChangedListener); - } - - // Start listening to the new one. - // - if (viewer != null) - { - viewer.addSelectionChangedListener(selectionChangedListener); - } - - // Remember it. - // - currentViewer = viewer; - - // Set the editors selection based on the current viewer's selection. - // - setSelection(currentViewer == null ? StructuredSelection.EMPTY : currentViewer.getSelection()); - } - } - - /** - * This returns the viewer as required by the {@link IViewerProvider} interface. - * - * - * @generated - */ - public Viewer getViewer() - { - return currentViewer; - } - - /** - * This creates a context menu for the viewer and adds a listener as well registering the menu for extension. - * - * - * @generated - */ - protected void createContextMenuFor(StructuredViewer viewer) - { - MenuManager contextMenu = new MenuManager("#PopUp");[genModel.getNonNLS()/] - contextMenu.add(new Separator("additions"));[genModel.getNonNLS()/] - contextMenu.setRemoveAllWhenShown(true); - contextMenu.addMenuListener(this); - Menu menu= contextMenu.createContextMenu(viewer.getControl()); - viewer.getControl().setMenu(menu); -[if (genModel.runtimeVersion <> GenRuntimeVersion::EMF22)] - getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer)); -[else] - getSite().registerContextMenu(contextMenu, viewer); -[/if] - - int dndOperations = DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK; - Transfer[genModel.genSquareBrackets('')/] transfers = new Transfer[genModel.genSquareBrackets('')/] { LocalTransfer.getInstance() }; - viewer.addDragSupport(dndOperations, transfers, new ViewerDragAdapter(viewer)); - viewer.addDropSupport(dndOperations, transfers, new EditingDomainViewerDropAdapter(editingDomain, viewer)); - } - - /** - * This is the method called to load a resource into the editing domain's resource set based on the editor's input. - * - * - * @generated - */ - public void createModel() - { -[if (genModel.runtimeVersion <> GenRuntimeVersion::EMF22)] - URI resourceURI = EditUIUtil.getURI(getEditorInput()); -[elseif (genModel.richClientPlatform)] - URI resourceURI = URI.createURI(getEditorInput().getName()); -[else] - // Assumes that the input is a file object. - // - IFileEditorInput modelFile = (IFileEditorInput)getEditorInput(); - URI resourceURI = URI.createPlatformResourceURI(modelFile.getFile().getFullPath().toString(), true); -[/if] - Exception exception = null; - Resource resource = null; - try - { - // Load the resource through the editing domain. - // - resource = editingDomain.getResourceSet().getResource(resourceURI, true); - } - catch (Exception e) - { - exception = e; - resource = editingDomain.getResourceSet().getResource(resourceURI, false); - } - - Diagnostic diagnostic = analyzeResourceProblems(resource, exception); - if (diagnostic.getSeverity() != Diagnostic.OK) - { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter); - } - - /** - * Returns a diagnostic describing the errors and warnings listed in the resource - * and the specified exception (if any). - * - * - * @generated - */ - public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) - { - if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) - { - BasicDiagnostic basicDiagnostic = - new BasicDiagnostic - (Diagnostic.ERROR, - "[genPackage.genModel.editorPluginID/]",[genModel.getNonNLS()/] - 0, - getString("_UI_CreateModelError_message", resource.getURI()),[genModel.getNonNLS()/] - new Object [genModel.genSquareBrackets('')/] { exception == null ? (Object)resource : exception }); - basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true)); - return basicDiagnostic; - } - else if (exception != null) - { - return - new BasicDiagnostic - (Diagnostic.ERROR, - "[genPackage.genModel.editorPluginID/]",[genModel.getNonNLS()/] - 0, - getString("_UI_CreateModelError_message", resource.getURI()),[genModel.getNonNLS()/] - new Object[genModel.genSquareBrackets('')/] { exception }); - } - else - { - return Diagnostic.OK_INSTANCE; - } - } - - /** - * This is the method used by the framework to install your own controls. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void createPages() - { - // Creates the model from the editor input - // - createModel(); - - // Only creates the other pages if there is something that can be edited - // - if (!getEditingDomain().getResourceSet().getResources().isEmpty()) - { - // Create a page for the selection tree view. - // -[if (genPackage.multipleEditorPages)] - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), [genPackage.getEditorClassName()/].this) - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Viewer createViewer(Composite composite) - { - Tree tree = new Tree(composite, SWT.MULTI); - TreeViewer newTreeViewer = new TreeViewer(tree); - return newTreeViewer; - } -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void requestActivation() - { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - selectionViewer = (TreeViewer)viewerPane.getViewer(); - selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - - selectionViewer.setLabelProvider(new [genModel._AdapterFactoryLabelProvider()/](adapterFactory[if (genModel.useExtendedLabelProvider())], selectionViewer[/if])); - selectionViewer.setInput(editingDomain.getResourceSet()); - selectionViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - viewerPane.setTitle(editingDomain.getResourceSet()); - - new AdapterFactoryTreeEditor(selectionViewer.getTree(), adapterFactory); - - createContextMenuFor(selectionViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_SelectionPage_label"));[genModel.getNonNLS()/] - } - - // Create a page for the parent tree view. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), [genPackage.getEditorClassName()/].this) - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Viewer createViewer(Composite composite) - { - Tree tree = new Tree(composite, SWT.MULTI); - TreeViewer newTreeViewer = new TreeViewer(tree); - return newTreeViewer; - } -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void requestActivation() - { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - parentViewer = (TreeViewer)viewerPane.getViewer(); - parentViewer.setAutoExpandLevel(30); - parentViewer.setContentProvider(new ReverseAdapterFactoryContentProvider(adapterFactory)); - parentViewer.setLabelProvider(new [genModel._AdapterFactoryLabelProvider()/](adapterFactory[if (genModel.useExtendedLabelProvider())], parentViewer[/if])); - - createContextMenuFor(parentViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_ParentPage_label"));[genModel.getNonNLS()/] - } - - // This is the page for the list viewer - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), [genPackage.getEditorClassName()/].this) - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Viewer createViewer(Composite composite) - { - return new ListViewer(composite); - } -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void requestActivation() - { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - listViewer = (ListViewer)viewerPane.getViewer(); - listViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - listViewer.setLabelProvider(new [genModel._AdapterFactoryLabelProvider()/](adapterFactory[if (genModel.useExtendedLabelProvider())], listViewer[/if])); - - createContextMenuFor(listViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_ListPage_label"));[genModel.getNonNLS()/] - } - - // This is the page for the tree viewer - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), [genPackage.getEditorClassName()/].this) - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Viewer createViewer(Composite composite) - { - return new TreeViewer(composite); - } -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void requestActivation() - { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - treeViewer = (TreeViewer)viewerPane.getViewer(); - treeViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - treeViewer.setLabelProvider(new [genModel._AdapterFactoryLabelProvider()/](adapterFactory[if (genModel.useExtendedLabelProvider())], treeViewer[/if])); - - new AdapterFactoryTreeEditor(treeViewer.getTree(), adapterFactory); - - createContextMenuFor(treeViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TreePage_label"));[genModel.getNonNLS()/] - } - - // This is the page for the table viewer. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), [genPackage.getEditorClassName()/].this) - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Viewer createViewer(Composite composite) - { - return new TableViewer(composite); - } -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void requestActivation() - { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - tableViewer = (TableViewer)viewerPane.getViewer(); - - Table table = tableViewer.getTable(); - TableLayout layout = new TableLayout(); - table.setLayout(layout); - table.setHeaderVisible(true); - table.setLinesVisible(true); - - TableColumn objectColumn = new TableColumn(table, SWT.NONE); - layout.addColumnData(new ColumnWeightData(3, 100, true)); - objectColumn.setText(getString("_UI_ObjectColumn_label"));[genModel.getNonNLS()/] - objectColumn.setResizable(true); - - TableColumn selfColumn = new TableColumn(table, SWT.NONE); - layout.addColumnData(new ColumnWeightData(2, 100, true)); - selfColumn.setText(getString("_UI_SelfColumn_label"));[genModel.getNonNLS()/] - selfColumn.setResizable(true); - - tableViewer.setColumnProperties(new String [genModel.genSquareBrackets('')/] {"a", "b"});[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - tableViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - tableViewer.setLabelProvider(new [genModel._AdapterFactoryLabelProvider()/](adapterFactory[if (genModel.useExtendedLabelProvider())], tableViewer[/if])); - - createContextMenuFor(tableViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TablePage_label"));[genModel.getNonNLS()/] - } - - // This is the page for the table tree viewer. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), [genPackage.getEditorClassName()/].this) - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Viewer createViewer(Composite composite) - { - return new TreeViewer(composite); - } -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void requestActivation() - { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - treeViewerWithColumns = (TreeViewer)viewerPane.getViewer(); - - Tree tree = treeViewerWithColumns.getTree(); - tree.setLayoutData(new FillLayout()); - tree.setHeaderVisible(true); - tree.setLinesVisible(true); - - TreeColumn objectColumn = new TreeColumn(tree, SWT.NONE); - objectColumn.setText(getString("_UI_ObjectColumn_label"));[genModel.getNonNLS()/] - objectColumn.setResizable(true); - objectColumn.setWidth(250); - - TreeColumn selfColumn = new TreeColumn(tree, SWT.NONE); - selfColumn.setText(getString("_UI_SelfColumn_label"));[genModel.getNonNLS()/] - selfColumn.setResizable(true); - selfColumn.setWidth(200); - - treeViewerWithColumns.setColumnProperties(new String [genModel.genSquareBrackets('')/] {"a", "b"});[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - treeViewerWithColumns.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - treeViewerWithColumns.setLabelProvider(new [genModel._AdapterFactoryLabelProvider()/](adapterFactory[if (genModel.useExtendedLabelProvider())], treeViewerWithColumns[/if])); - - createContextMenuFor(treeViewerWithColumns); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TreeWithColumnsPage_label"));[genModel.getNonNLS()/] - } -[else] - Tree tree = new Tree(getContainer(), SWT.MULTI); - selectionViewer = new TreeViewer(tree); - setCurrentViewer(selectionViewer); - - selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - selectionViewer.setLabelProvider(new [genModel._AdapterFactoryLabelProvider()/](adapterFactory[if (genModel.useExtendedLabelProvider())], selectionViewer[/if])); - selectionViewer.setInput(editingDomain.getResourceSet()); - selectionViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - - new AdapterFactoryTreeEditor(selectionViewer.getTree(), adapterFactory); - - createContextMenuFor(selectionViewer); - int pageIndex = addPage(tree); - setPageText(pageIndex, getString("_UI_SelectionPage_label"));[genModel.getNonNLS()/] -[/if] - - getSite().getShell().getDisplay().asyncExec - (new Runnable() - { - public void run() - { - setActivePage(0); - } - }); - } - - // Ensures that this editor will only display the page's tab - // area if there are more than one page - // - getContainer().addControlListener - (new ControlAdapter() - { - boolean guard = false; -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void controlResized(ControlEvent event) - { - if (!guard) - { - guard = true; - hideTabs(); - guard = false; - } - } - }); - - getSite().getShell().getDisplay().asyncExec - (new Runnable() - { - public void run() - { - updateProblemIndication(); - } - }); - } - - /** - * If there is just one page in the multi-page editor part, - * this hides the single tab at the bottom. - * - * - * @generated - */ - protected void hideTabs() - { - if (getPageCount() <= 1) - { - setPageText(0, "");[genModel.getNonNLS()/] - if (getContainer() instanceof CTabFolder) - { - ((CTabFolder)getContainer()).setTabHeight(1); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y + 6); - } - } - } - - /** - * If there is more than one page in the multi-page editor part, - * this shows the tabs at the bottom. - * - * - * @generated - */ - protected void showTabs() - { - if (getPageCount() > 1) - { - setPageText(0, getString("_UI_SelectionPage_label"));[genModel.getNonNLS()/] - if (getContainer() instanceof CTabFolder) - { - ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y - 6); - } - } - } - - /** - * This is used to track the active viewer. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected void pageChange(int pageIndex) - { - super.pageChange(pageIndex); - - if (contentOutlinePage != null) - { - handleContentOutlineSelection(contentOutlinePage.getSelection()); - } - } - - /** - * This is how the framework determines which interfaces we implement. - * - * - * @generated - */ -[if (genModel.useGenerics())] - @SuppressWarnings("[if (genModel.runtimeVersion <> GenRuntimeVersion::EMF27)]unchecked[else]rawtypes[/if]") -[/if] -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public Object getAdapter(Class key) - { - if (key.equals(IContentOutlinePage.class)) - { - return showOutlineView() ? getContentOutlinePage() : null; - } - else if (key.equals(IPropertySheetPage.class)) - { - return getPropertySheetPage(); - } -[if ( not genModel.richClientPlatform)] - else if (key.equals(IGotoMarker.class)) - { - return this; - } -[/if] - else - { - return super.getAdapter(key); - } - } - - /** - * This accesses a cached version of the content outliner. - * - * - * @generated - */ - public IContentOutlinePage getContentOutlinePage() - { - if (contentOutlinePage == null) - { - // The content outline is just a tree. - // - class MyContentOutlinePage extends ContentOutlinePage - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void createControl(Composite parent) - { - super.createControl(parent); - contentOutlineViewer = getTreeViewer(); - contentOutlineViewer.addSelectionChangedListener(this); - - // Set up the tree viewer. - // - contentOutlineViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - contentOutlineViewer.setLabelProvider(new [genModel._AdapterFactoryLabelProvider()/](adapterFactory[if (genModel.useExtendedLabelProvider())], contentOutlineViewer[/if])); - contentOutlineViewer.setInput(editingDomain.getResourceSet()); - - // Make sure our popups work. - // - createContextMenuFor(contentOutlineViewer); - - if (!editingDomain.getResourceSet().getResources().isEmpty()) - { - // Select the root object in the view. - // - contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - } - } - -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void makeContributions(IMenuManager menuManager, IToolBarManager toolBarManager, IStatusLineManager statusLineManager) - { - super.makeContributions(menuManager, toolBarManager, statusLineManager); - contentOutlineStatusLineManager = statusLineManager; - } - -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void setActionBars(IActionBars actionBars) - { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - } - - contentOutlinePage = new MyContentOutlinePage(); - - // Listen to selection so that we can handle it is a special way. - // - contentOutlinePage.addSelectionChangedListener - (new ISelectionChangedListener() - { - // This ensures that we handle selections correctly. - // - public void selectionChanged(SelectionChangedEvent event) - { - handleContentOutlineSelection(event.getSelection()); - } - }); - } - - return contentOutlinePage; - } - - /** - * This accesses a cached version of the property sheet. - * - * - * @generated - */ - public IPropertySheetPage getPropertySheetPage() - { - if (propertySheetPage == null) - { - propertySheetPage = - new ExtendedPropertySheetPage(editingDomain) - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void setSelectionToViewer([genModel._ListOfAnything()/] selection) - { - [genPackage.getEditorClassName()/].this.setSelectionToViewer(selection); - [genPackage.getEditorClassName()/].this.setFocus(); - } - -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void setActionBars(IActionBars actionBars) - { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - }; - propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory)); - } - - return propertySheetPage; - } - - /** - * This deals with how we want selection in the outliner to affect the other views. - * - * - * @generated - */ - public void handleContentOutlineSelection(ISelection selection) - { -[if (genPackage.multipleEditorPages)] - if (currentViewerPane != null && !selection.isEmpty() && selection instanceof IStructuredSelection) -[else] - if (selectionViewer != null && !selection.isEmpty() && selection instanceof IStructuredSelection) -[/if] - { - Iterator[if (genModel.useGenerics())][/if] selectedElements = ((IStructuredSelection)selection).iterator(); - if (selectedElements.hasNext()) - { - // Get the first selected element. - // - Object selectedElement = selectedElements.next(); - -[if (genPackage.multipleEditorPages)] - // If it's the selection viewer, then we want it to select the same selection as this selection. - // - if (currentViewerPane.getViewer() == selectionViewer) - { - [genModel._ArrayListOfObject()/] selectionList = new [genModel._ArrayListOfObject()/](); - selectionList.add(selectedElement); - while (selectedElements.hasNext()) - { - selectionList.add(selectedElements.next()); - } - - // Set the selection to the widget. - // - selectionViewer.setSelection(new StructuredSelection(selectionList)); - } - else - { - // Set the input to the widget. - // - if (currentViewerPane.getViewer().getInput() != selectedElement) - { - currentViewerPane.getViewer().setInput(selectedElement); - currentViewerPane.setTitle(selectedElement); - } - } -[else] - [genModel._ArrayListOfObject()/] selectionList = new [genModel._ArrayListOfObject()/](); - selectionList.add(selectedElement); - while (selectedElements.hasNext()) - { - selectionList.add(selectedElements.next()); - } - - // Set the selection to the widget. - // - selectionViewer.setSelection(new StructuredSelection(selectionList)); -[/if] - } - } - } - - /** - * This is for implementing {@link IEditorPart} and simply tests the command stack. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public boolean isDirty() - { - return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded(); - } - - /** - * This is for implementing {@link IEditorPart} and simply saves the model file. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void doSave(IProgressMonitor progressMonitor) - { - // Save only resources that have actually changed. - // - final [genModel._MapOfObjectToObject()/] saveOptions = new [genModel._HashMapOfObjectToObject()/](); -[if (genModel.runtimeVersion <> GenRuntimeVersion::EMF22)] - saveOptions.put(Resource.OPTION_SAVE_ONLY_IF_CHANGED, Resource.OPTION_SAVE_ONLY_IF_CHANGED_MEMORY_BUFFER); -[/if] - - // Do the work within an operation because this is a long running activity that modifies the workbench. - // - [genModel.importedOperationClassName()/] operation = - new [genModel.importedOperationClassName()/]() - { - // This is the method that gets invoked when the operation runs. - // -[if (not genModel.richClientPlatform and genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void [genModel.operationMethodName()/](IProgressMonitor monitor) - { - // Save the resources to the file system. - // - boolean first = true; -[if (genModel.useGenerics())] - for (Resource resource : editingDomain.getResourceSet().getResources()) -[else] - for (Iterator i = editingDomain.getResourceSet().getResources().iterator(); i.hasNext(); ) -[/if] - { -[if (not genModel.useGenerics())] - Resource resource = (Resource)i.next(); -[/if] - if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) - { - try - { -[if (genModel.runtimeVersion = GenRuntimeVersion::EMF22 or genModel.runtimeVersion = GenRuntimeVersion::EMF23)] - resource.save(saveOptions); - savedResources.add(resource); -[else] - long timeStamp = resource.getTimeStamp(); - resource.save(saveOptions); - if (resource.getTimeStamp() != timeStamp) - { - savedResources.add(resource); - } -[/if] - } - catch (Exception exception) - { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - first = false; - } - } - } - }; - - updateProblemIndication = false; - try - { - // This runs the options, and shows progress. - // - new ProgressMonitorDialog(getSite().getShell()).run(true, false, operation); - - // Refresh the necessary state. - // - ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone(); - firePropertyChange(IEditorPart.PROP_DIRTY); - } - catch (Exception exception) - { - // Something went wrong that shouldn't. - // - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.log(exception); - } - updateProblemIndication = true; - updateProblemIndication(); - } - - /** - * This returns whether something has been persisted to the URI of the specified resource. - * The implementation uses the URI converter from the editor's resource set to try to open an input stream. - * - * - * @generated - */ - protected boolean isPersisted(Resource resource) - { - boolean result = false; - try - { - InputStream stream = editingDomain.getResourceSet().getURIConverter().createInputStream(resource.getURI()); - if (stream != null) - { - result = true; - stream.close(); - } - } - catch (IOException e) - { - // Ignore - } - return result; - } - - /** - * This always returns true because it is not currently supported. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public boolean isSaveAsAllowed() - { - return true; - } - - /** - * This also changes the editor's input. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void doSaveAs() - { -[if (genModel.richClientPlatform)] - [if (genModel.richAjaxPlatform)] - new [genModel.getImportedName('org.eclipse.emf.common.ui.dialogs.ResourceDialog')/](getSite().getShell(), null, SWT.NONE) - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected boolean isSave() - { - return true; - } - -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected boolean processResources() - { - List[if (genModel.useGenerics())][/if] uris = getURIs(); - if (uris.size() > 0) - { - URI uri = [if (not genModel.useGenerics())](URI)[/if]uris.get(0); - doSaveAs(uri, new [genModel.getImportedName('org.eclipse.emf.common.ui.URIEditorInput')/](uri)); - return true; - } - else - { - return false; - } - } - }.open(); - [else] - String[genModel.genSquareBrackets('')/] filters = [if (not genModel.useGenerics())](String[genModel.genSquareBrackets('')/])[/if]FILE_EXTENSION_FILTERS.toArray(new String[genModel.genSquareBrackets('FILE_EXTENSION_FILTERS.size()')/]); - String[genModel.genSquareBrackets('')/] files = [genModel.getQualifiedEditorAdvisorClassName()/].openFilePathDialog(getSite().getShell(), [genModel.getImportedName('org.eclipse.swt.SWT')/].SAVE, filters); - if (files.length > 0) - { - URI uri = URI.createFileURI(files[genModel.genSquareBrackets('0')/]); - doSaveAs(uri, new [genModel.getImportedName('org.eclipse.emf.common.ui.URIEditorInput')/](uri)); - } - [/if] -[else] - SaveAsDialog saveAsDialog = new SaveAsDialog(getSite().getShell()); - saveAsDialog.open(); - IPath path = saveAsDialog.getResult(); - if (path != null) - { - IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path); - if (file != null) - { - doSaveAs(URI.createPlatformResourceURI(file.getFullPath().toString(), true), new FileEditorInput(file)); - } - } -[/if] - } - - /** - * - * - * @generated - */ - protected void doSaveAs(URI uri, IEditorInput editorInput) - { - ([if (not genModel.useGenerics())](Resource)[/if]editingDomain.getResourceSet().getResources().get(0)).setURI(uri); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - IProgressMonitor progressMonitor = - getActionBars().getStatusLineManager() != null ? - getActionBars().getStatusLineManager().getProgressMonitor() : - new NullProgressMonitor(); - doSave(progressMonitor); - } -[if (not genModel.richClientPlatform)] - - /** - * - * - * @generated - */ - public void gotoMarker(IMarker marker) - { - try - { - if (marker.getType().equals(EValidator.MARKER)) - { - String uriAttribute = marker.getAttribute(EValidator.URI_ATTRIBUTE, null); - if (uriAttribute != null) - { - URI uri = URI.createURI(uriAttribute); - EObject eObject = editingDomain.getResourceSet().getEObject(uri, true); - if (eObject != null) - { - setSelectionToViewer(Collections.singleton(editingDomain.getWrapper(eObject))); - } - } - } - } - catch (CoreException exception) - { - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.log(exception); - } - } -[/if] - - /** - * This is called during startup. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void init(IEditorSite site, IEditorInput editorInput) - { - setSite(site); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - site.setSelectionProvider(this); - site.getPage().addPartListener(partListener); -[if (not genModel.richClientPlatform)] - ResourcesPlugin.getWorkspace().addResourceChangeListener(resourceChangeListener, IResourceChangeEvent.POST_CHANGE); -[/if] - } - - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void setFocus() - { -[if (genPackage.multipleEditorPages)] - if (currentViewerPane != null) - { - currentViewerPane.setFocus(); - } - else - { - getControl(getActivePage()).setFocus(); - } -[else] - getControl(getActivePage()).setFocus(); -[/if] - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void addSelectionChangedListener(ISelectionChangedListener listener) - { - selectionChangedListeners.add(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void removeSelectionChangedListener(ISelectionChangedListener listener) - { - selectionChangedListeners.remove(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection. - * - * - * @generated - */ - public ISelection getSelection() - { - return editorSelection; - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to set this editor's overall selection. - * Calling this result will notify the listeners. - * - * - * @generated - */ - public void setSelection(ISelection selection) - { - editorSelection = selection; - -[if (genModel.useGenerics())] - for (ISelectionChangedListener listener : selectionChangedListeners) -[else] - for (Iterator listeners = selectionChangedListeners.iterator(); listeners.hasNext(); ) -[/if] - { -[if (not genModel.useGenerics())] - ISelectionChangedListener listener = (ISelectionChangedListener)listeners.next(); -[/if] - listener.selectionChanged(new SelectionChangedEvent(this, selection)); - } - setStatusLineManager(selection); - } - - /** - * - * - * @generated - */ - public void setStatusLineManager(ISelection selection) - { - IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ? - contentOutlineStatusLineManager : getActionBars().getStatusLineManager(); - - if (statusLineManager != null) - { - if (selection instanceof IStructuredSelection) - { - [genModel._CollectionOfAnything()/] collection = ((IStructuredSelection)selection).toList(); - switch (collection.size()) - { - case 0: - { - statusLineManager.setMessage(getString("_UI_NoObjectSelected"));[genModel.getNonNLS()/] - break; - } - case 1: - { - String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next()); - statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text));[genModel.getNonNLS()/] - break; - } - default: - { - statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size())));[genModel.getNonNLS()/] - break; - } - } - } - else - { - statusLineManager.setMessage("");[genModel.getNonNLS()/] - } - } - } - - /** - * This looks up a string in the plugin's plugin.properties file. - * - * - * @generated - */ - private static String getString(String key) - { - return [genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString(key); - } - - /** - * This looks up a string in plugin.properties, making a substitution. - * - * - * @generated - */ - private static String getString(String key, Object s1) - { - return [genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString(key, new Object [genModel.genSquareBrackets('')/] { s1 }); - } - - /** - * This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu. - * - * - * @generated - */ - public void menuAboutToShow(IMenuManager menuManager) - { - ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager); - } - - /** - * - * - * @generated - */ - public EditingDomainActionBarContributor getActionBarContributor() - { - return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor(); - } - - /** - * - * - * @generated - */ - public IActionBars getActionBars() - { - return getActionBarContributor().getActionBars(); - } - - /** - * - * - * @generated - */ - public AdapterFactory getAdapterFactory() - { - return adapterFactory; - } - - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void dispose() - { - updateProblemIndication = false; - -[if (not genModel.richClientPlatform)] - ResourcesPlugin.getWorkspace().removeResourceChangeListener(resourceChangeListener); - -[/if] - getSite().getPage().removePartListener(partListener); - - adapterFactory.dispose(); - - if (getActionBarContributor().getActiveEditor() == this) - { - getActionBarContributor().setActiveEditor(null); - } - - if (propertySheetPage != null) - { - propertySheetPage.dispose(); - } - - if (contentOutlinePage != null) - { - contentOutlinePage.dispose(); - } - - super.dispose(); - } - - /** - * Returns whether the outline view should be presented to the user. - * - * - * @generated - */ - protected boolean showOutlineView() - { - return [genPackage.multipleEditorPages/]; - } -} -[/template] - -[query public operationMethodName(genModel : GenModel) : String = if genModel.richClientPlatform then'run' else 'execute' endif/] - -[template public importedOperationClassName (genModel : GenModel)] -[if genModel.richClientPlatform][genModel.getImportedName('org.eclipse.jface.operation.IRunnableWithProgress')/][else][genModel.getImportedName('org.eclipse.ui.actions.WorkspaceModifyOperation')/][/if] -[/template] - -[query public _ArrayListOfObject(genModel : GenModel) : String = if genModel.useGenerics() then 'ArrayList' else 'ArrayList' endif/] - -[query public _ArrayListOfSelectionChangedListener(genModel : GenModel) : String = if genModel.useGenerics() then 'ArrayList' else 'ArrayList' endif/] - -[query public _CollectionOfSelectionChangedListener(genModel : GenModel) : String = if genModel.useGenerics() then 'Collection' else 'Collection' endif/] - -[query public _ArrayListOfResource(genModel : GenModel) : String = if genModel.useGenerics() then 'ArrayList' else 'ArrayList' endif/] - -[query public _CollectionOfResource(genModel : GenModel) : String = if genModel.useGenerics() then 'Collection' else 'Collection' endif/] - -[query public _MapOfResourceToDiagnostic(genModel : GenModel) : String = if genModel.useGenerics() then 'Map' else 'Map' endif/] - -[query public _HashMapOfResourceToBoolean(genModel : GenModel) : String = if genModel.useGenerics() then 'HashMap' else 'HashMap' endif/] - -[query public _MapOfObjectToObject(genModel : GenModel) : String = if genModel.useGenerics() then 'Map' else 'Map' endif/] - -[query public _HashMapOfObjectToObject(genModel : GenModel) : String = if genModel.useGenerics() then 'HashMap' else 'HashMap' endif/] - -[query public _LinkedHashMapOfResourceToDiagnostic(genModel : GenModel) : String = if genModel.useGenerics() then 'LinkedHashMap' else 'LinkedHashMap' endif/] - -[query public _CollectionOfAnything(genModel : GenModel) : String = if genModel.useGenerics() then 'Collection' else 'Collection' endif/] - -[query public _ListOfAnything(genModel : GenModel) : String = if genModel.useGenerics() then 'List' else 'List' endif/] - -[query public useExtendedLabelProvider(genModel : GenModel) : Boolean = genModel.fontProviders or genModel.colorProviders/] - -[query public _AdapterFactoryLabelProvider(genModel : GenModel) : String = if genModel.fontProviders and genModel.colorProviders then 'AdapterFactoryLabelProvider.FontAndColorProvider' else if genModel.fontProviders then 'AdapterFactoryLabelProvider.FontProvider' else if genModel.colorProviders then 'AdapterFactoryLabelProvider.ColorProvider' else 'AdapterFactoryLabelProvider' endif endif endif/] - -[query public _ArrayListOfString(genModel : GenModel) : String = if genModel.useGenerics() then 'ArrayList' else 'ArrayList' endif/] - -[query public _ListOfString(genModel : GenModel) : String = if genModel.useGenerics() then 'List' else 'List' endif/] - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/ModelWizard.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/ModelWizard.mtl deleted file mode 100644 index d736b3c2b..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/ModelWizard.mtl +++ /dev/null @@ -1,1014 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module ModelWizard('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenTypedElement /] - -[template public ModelWizard(genPackage : GenPackage) {genModel : GenModel = genPackage.genModel; packageName : String = genPackage.getPresentationPackageName(); className : String = genPackage.getModelWizardClassName()}] -[genModel.initializeImportManager(packageName, className)/] - -[file (genModel.editorPath(packageName, className), false, 'UTF-8')] -[includeHeader()/] -package [packageName/]; - - -[genModel.addImportHere('java.util.ArrayList')/] -[genModel.addImportHere('java.util.Arrays')/] -[genModel.addImportHere('java.util.Collection')/] -[genModel.addImportHere('java.util.Collections')/] -[genModel.addImportHere('java.util.HashMap')/] -[if (not genModel.useGenerics())] -[genModel.addImportHere('java.util.Iterator')/] -[/if] -[genModel.addImportHere('java.util.List')/] -[genModel.addImportHere('java.util.Map')/] -[genModel.addImportHere('java.util.MissingResourceException')/] -[genModel.addImportHere('java.util.StringTokenizer')/] - -[if (not genModel.richClientPlatform and genModel.complianceLevel <> GenJDKLevel::JDK14)] -[genModel.addImportHere('org.eclipse.emf.common.CommonPlugin')/] - -[/if] -[genModel.addImportHere('org.eclipse.emf.common.util.URI')/] - -[genModel.addImportHere('org.eclipse.emf.ecore.EClass')/] -[genModel.addImportHere('org.eclipse.emf.ecore.EClassifier')/] - -[genModel.addImportHere('org.eclipse.emf.ecore.resource.Resource')/] -[genModel.addImportHere('org.eclipse.emf.ecore.resource.ResourceSet')/] - -[genModel.addImportHere('org.eclipse.emf.ecore.resource.impl.ResourceSetImpl')/] - -[genModel.addImportHere('org.eclipse.emf.ecore.EObject')/] - -[genModel.addImportHere('org.eclipse.emf.ecore.xmi.XMLResource')/] - -[genModel.addImportHere('org.eclipse.emf.edit.ui.provider.ExtendedImageRegistry')/] - -[if (not genModel.richClientPlatform)] -[genModel.addImportHere('org.eclipse.core.resources.IContainer')/] -[genModel.addImportHere('org.eclipse.core.resources.IFile')/] -[genModel.addImportHere('org.eclipse.core.resources.IFolder')/] -[genModel.addImportHere('org.eclipse.core.resources.IProject')/] -[genModel.addImportHere('org.eclipse.core.resources.IResource')/] -[genModel.addImportHere('org.eclipse.core.resources.ResourcesPlugin')/] - -[/if] -[genModel.addImportHere('org.eclipse.core.runtime.IProgressMonitor')/] - -[genModel.addImportHere('org.eclipse.jface.dialogs.MessageDialog')/] - -[genModel.addImportHere('org.eclipse.jface.viewers.IStructuredSelection')/] - -[genModel.addImportHere('org.eclipse.jface.wizard.Wizard')/] -[genModel.addImportHere('org.eclipse.jface.wizard.WizardPage')/] - -[genModel.addImportHere('org.eclipse.swt.SWT')/] - -[genModel.addImportHere('org.eclipse.swt.events.ModifyListener')/] -[genModel.addImportHere('org.eclipse.swt.events.ModifyEvent')/] - -[genModel.addImportHere('org.eclipse.swt.layout.GridData')/] -[genModel.addImportHere('org.eclipse.swt.layout.GridLayout')/] - -[genModel.addImportHere('org.eclipse.swt.widgets.Combo')/] -[genModel.addImportHere('org.eclipse.swt.widgets.Composite')/] -[genModel.addImportHere('org.eclipse.swt.widgets.Label')/] - -[genModel.addImportHere('org.eclipse.ui.INewWizard')/] -[genModel.addImportHere('org.eclipse.ui.IWorkbench')/] - -[if (not genModel.richClientPlatform)] -[genModel.addImportHere('org.eclipse.ui.actions.WorkspaceModifyOperation')/] - -[genModel.addImportHere('org.eclipse.ui.dialogs.WizardNewFileCreationPage')/] - -[genModel.addImportHere('org.eclipse.ui.part.FileEditorInput')/] -[genModel.addImportHere('org.eclipse.ui.part.ISetSelectionTarget')/] - -[/if] -[if (not genModel.suppressEMFMetaData)] -[genModel.addImportHere(genPackage.getQualifiedFactoryInterfaceName())/] -[/if] -[genModel.addImportHere(genPackage.getQualifiedPackageInterfaceName())/] -[genModel.addImportHere(genPackage.getQualifiedEditPluginClassName())/] - -[let content : String = genPackage.fileContent(genModel, packageName, className)] -[genModel.genSortedImports()/] - -[content/] -[/let] -[/file] -[/template] - -[template public fileContent(genPackage : GenPackage, genModel : GenModel, packageName : String, className : String)] -/** - * This is a simple wizard for creating a new model file. - * - * - * @generated - */ -public class [className/] extends Wizard implements INewWizard -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - /** - * The supported extensions for created files. - * - * - * @generated - */ - public static final [genModel._ListOfString()/] FILE_EXTENSIONS = - Collections.unmodifiableList(Arrays.asList([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_[genPackage.getEditorClassName()/]FilenameExtensions").split("\\s*,\\s*")));[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - - /** - * A formatted list of supported file extensions, suitable for display. - * - * - * @generated - */ - public static final String FORMATTED_FILE_EXTENSIONS = - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_[genPackage.getEditorClassName()/]FilenameExtensions").replaceAll("\\s*,\\s*", ", ");[genModel.getNonNLS()/][genModel.getNonNLS(2)/][genModel.getNonNLS(3)/] - - /** - * This caches an instance of the model package. - * - * - * @generated - */ - protected [if genModel.suppressEMFMetaData][genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/][else][genPackage.getPackageInterfaceName()/][/if] [genPackage.getUncapPackageName()/] = [genPackage.getPackageInterfaceName()/].eINSTANCE; - - /** - * This caches an instance of the model factory. - * - * - * @generated - */ - protected [if genModel.suppressEMFMetaData][genModel.getImportedName('org.eclipse.emf.ecore.EFactory')/][else][genPackage.getFactoryInterfaceName()/][/if] [genPackage.getUncapFactoryName()/] = [genPackage.getUncapPackageName()/].get[if genModel.suppressEMFMetaData]EFactoryInstance[else][genPackage.getFactoryName()/][/if](); - -[if (not genModel.richClientPlatform)] - /** - * This is the file creation page. - * - * - * @generated - */ - protected [genPackage.getModelWizardClassName()/]NewFileCreationPage newFileCreationPage; - -[/if] - /** - * This is the initial object creation page. - * - * - * @generated - */ - protected [genPackage.getModelWizardClassName()/]InitialObjectCreationPage initialObjectCreationPage; - - /** - * Remember the selection during initialization for populating the default container. - * - * - * @generated - */ - protected IStructuredSelection selection; - - /** - * Remember the workbench during initialization. - * - * - * @generated - */ - protected IWorkbench workbench; - - /** -[if (not genPackage.hasDocumentRoot())] - * Caches the names of the types that can be created as the root object. -[else] - * Caches the names of the features representing global elements. -[/if] - * - * - * @generated - */ - protected [genModel._ListOfString()/] initialObjectNames; - - /** - * This just records the information. - * - * - * @generated - */ - public void init(IWorkbench workbench, IStructuredSelection selection) - { - this.workbench = workbench; - this.selection = selection; - setWindowTitle([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_Wizard_label"));[genModel.getNonNLS()/] - setDefaultPageImageDescriptor(ExtendedImageRegistry.INSTANCE.getImageDescriptor([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getImage("full/wizban/New[genPackage.prefix/]")));[genModel.getNonNLS()/] - } - - /** -[if (not genPackage.hasDocumentRoot())] - * Returns the names of the types that can be created as the root object. -[else] - * Returns the names of the features representing global elements. -[/if] - * - * - * @generated - */ - protected [genModel._CollectionOfString()/] getInitialObjectNames() - { - if (initialObjectNames == null) - { - initialObjectNames = new [genModel._ArrayListOfString()/](); -[if (not genPackage.hasDocumentRoot())] - [if (genModel.useGenerics())] - for (EClassifier eClassifier : [genPackage.getUncapPackageName()/].getEClassifiers()) - [else] - for (Iterator classifiers = [genPackage.getUncapPackageName()/].getEClassifiers().iterator(); classifiers.hasNext(); ) - [/if] - { - [if (not genModel.useGenerics())] - EClassifier eClassifier = (EClassifier)classifiers.next(); - [/if] - if (eClassifier instanceof EClass) - { - EClass eClass = (EClass)eClassifier; - if (!eClass.isAbstract()) - { - initialObjectNames.add(eClass.getName()); - } - } - } -[else] - [if (genModel.useGenerics())] - for ([genModel.getImportedName('org.eclipse.emf.ecore.EStructuralFeature')/] eStructuralFeature : [genModel.getImportedName('org.eclipse.emf.ecore.util.ExtendedMetaData')/].INSTANCE.getAllElements([genModel.getImportedName('org.eclipse.emf.ecore.util.ExtendedMetaData')/].INSTANCE.getDocumentRoot([genPackage.getUncapPackageName()/]))) - [else] - for (Iterator elements = [genModel.getImportedName('org.eclipse.emf.ecore.util.ExtendedMetaData')/].INSTANCE.getAllElements([genModel.getImportedName('org.eclipse.emf.ecore.util.ExtendedMetaData')/].INSTANCE.getDocumentRoot([genPackage.getUncapPackageName()/])).iterator(); elements.hasNext(); ) - [/if] - { - [if (not genModel.useGenerics())] - [genModel.getImportedName('org.eclipse.emf.ecore.EStructuralFeature')/] eStructuralFeature = ([genModel.getImportedName('org.eclipse.emf.ecore.EStructuralFeature')/])elements.next(); - [/if] - if (eStructuralFeature.isChangeable()) - { - EClassifier eClassifier = eStructuralFeature.getEType(); - if (eClassifier instanceof EClass) - { - EClass eClass = (EClass)eClassifier; - if (!eClass.isAbstract()) - { - initialObjectNames.add(eStructuralFeature.getName()); - } - } - } - } -[/if] - Collections.sort(initialObjectNames, [if (not genModel.richClientPlatform and genModel.complianceLevel <> GenJDKLevel::JDK14)]CommonPlugin.INSTANCE.getComparator()[else]java.text.Collator.getInstance()[/if]); - } - return initialObjectNames; - } - - /** - * Create a new model. - * - * - * @generated - */ - protected EObject createInitialModel() - { -[if (not genPackage.hasDocumentRoot())] - EClass eClass = (EClass)[genPackage.getUncapPackageName()/].getEClassifier(initialObjectCreationPage.getInitialObjectName()); - EObject rootObject = [genPackage.getUncapFactoryName()/].create(eClass); -[else] - EClass eClass = [genModel.getImportedName('org.eclipse.emf.ecore.util.ExtendedMetaData')/].INSTANCE.getDocumentRoot([genPackage.getUncapPackageName()/]); - EStructuralFeature eStructuralFeature = eClass.getEStructuralFeature(initialObjectCreationPage.getInitialObjectName()); - EObject rootObject = [genPackage.getUncapFactoryName()/].create(eClass); - rootObject.eSet(eStructuralFeature, [genModel.getImportedName('org.eclipse.emf.ecore.util.EcoreUtil')/].create((EClass)eStructuralFeature.getEType())); -[/if] - return rootObject; - } - - /** - * Do the work after everything is specified. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public boolean performFinish() - { - try - { -[if (genModel.richClientPlatform)] - // Get the URI of the model file. - // - final URI fileURI = getModelURI(); - if (new [genModel.getImportedName('java.io.File')/](fileURI.toFileString()).exists()) - { - if (!MessageDialog.openQuestion - (getShell(), - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_Question_title"),[genModel.getNonNLS()/] - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_WARN_FileConflict", new String [genModel.genSquareBrackets('')/]{ fileURI.toFileString() })))[genModel.getNonNLS()/] - { - initialObjectCreationPage.selectFileField(); - return false; - } - } - - // Do the work within an operation. - // - [genModel.getImportedName('org.eclipse.jface.operation.IRunnableWithProgres')/] operation = new [genModel.getImportedName('org.eclipse.jface.operation.IRunnableWithProgress')/]() - { - public void run(IProgressMonitor progressMonitor) -[else] - // Remember the file. - // - final IFile modelFile = getModelFile(); - - // Do the work within an operation. - // - WorkspaceModifyOperation operation = - new WorkspaceModifyOperation() - { -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected void execute(IProgressMonitor progressMonitor) -[/if] - { - try - { - // Create a resource set - // - ResourceSet resourceSet = new ResourceSetImpl(); - -[if (not genModel.richClientPlatform)] - // Get the URI of the model file. - // - URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true); - -[/if] - // Create a resource for this file. - // - Resource resource = resourceSet.createResource(fileURI[if (genPackage.isContentType())], [genPackage.getImportedPackageInterfaceName()/].eCONTENT_TYPE[/if]); - - // Add the initial model object to the contents. - // - EObject rootObject = createInitialModel(); - if (rootObject != null) - { - resource.getContents().add(rootObject); - } - - // Save the contents of the resource to the file system. - // - [genModel._MapOfObjectToObject()/] options = new [genModel._HashMapOfObjectToObject()/](); - options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding()); - resource.save(options); - } - catch (Exception exception) - { - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.log(exception); - } - finally - { - progressMonitor.done(); - } - } - }; - - getContainer().run(false, false, operation); - -[if (genModel.richClientPlatform)] - return genModel.getQualifiedEditorAdvisorClassName().openEditor(workbench, fileURI); -[else] - // Select the new file resource in the current view. - // - [genModel.getImportedName('org.eclipse.ui.IWorkbenchWindow')/] workbenchWindow = workbench.getActiveWorkbenchWindow(); - [genModel.getImportedName('org.eclipse.ui.IWorkbenchPage')/] page = workbenchWindow.getActivePage(); - final [genModel.getImportedName('org.eclipse.ui.IWorkbenchPart')/] activePart = page.getActivePart(); - if (activePart instanceof ISetSelectionTarget) - { - final [genModel.getImportedName('org.eclipse.jface.viewers.ISelection')/] targetSelection = new [genModel.getImportedName('org.eclipse.jface.viewers.StructuredSelection')/](modelFile); - getShell().getDisplay().asyncExec - (new Runnable() - { - public void run() - { - ((ISetSelectionTarget)activePart).selectReveal(targetSelection); - } - }); - } - - // Open an editor on the new file. - // - try - { - page.openEditor - (new FileEditorInput(modelFile), - workbench.getEditorRegistry().getDefaultEditor[if (not genPackage.isContentType())](modelFile.getFullPath().toString()).getId());[else](modelFile.getFullPath().toString(), - [genModel.getImportedName('org.eclipse.core.runtime.Platform')/].getContentTypeManager().getContentType([genPackage.getImportedPackageInterfaceName()/].eCONTENT_TYPE)).getId());[/if] - } - catch ([genModel.getImportedName('org.eclipse.ui.PartInitException')/] exception) - { - MessageDialog.openError(workbenchWindow.getShell(), [genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage());[genModel.getNonNLS()/] - return false; - } - - return true; -[/if] - } - catch (Exception exception) - { - [genPackage.getImportedEditorPluginClassName()/].INSTANCE.log(exception); - return false; - } - } - -[if (not genModel.richClientPlatform)] - /** - * This is the one page of the wizard. - * - * - * @generated - */ - public class [genPackage.getModelWizardClassName()/]NewFileCreationPage extends WizardNewFileCreationPage - { - /** - * Pass in the selection. - * - * - * @generated - */ - public [genPackage.getModelWizardClassName()/]NewFileCreationPage(String pageId, IStructuredSelection selection) - { - super(pageId, selection); - } - - /** - * The framework calls this to see if the file is correct. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - protected boolean validatePage() - { - if (super.validatePage()) - { - String extension = new [genModel.getImportedName('org.eclipse.core.runtime.Path')/](getFileName()).getFileExtension(); - if (extension == null || !FILE_EXTENSIONS.contains(extension)) - { - String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension";[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - setErrorMessage([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString(key, new Object [genModel.genSquareBrackets('')/] { FORMATTED_FILE_EXTENSIONS })); - return false; - } - return true; - } - return false; - } - - /** - * - * - * @generated - */ - public IFile getModelFile() - { - return ResourcesPlugin.getWorkspace().getRoot().getFile(getContainerFullPath().append(getFileName())); - } - } - -[/if] - /** - * This is the page where the type of object to create is selected. - * - * - * @generated - */ - public class [genPackage.getModelWizardClassName()/]InitialObjectCreationPage extends WizardPage - { -[if (genModel.richClientPlatform)] - /** - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.swt.widgets.Text')/] fileField; - -[/if] - /** - * - * - * @generated - */ - protected Combo initialObjectField; - - /** - * @generated - * - * - */ - protected [genModel._ListOfString()/] encodings; - - /** - * - * - * @generated - */ - protected Combo encodingField; - - /** - * Pass in the selection. - * - * - * @generated - */ - public [genPackage.getModelWizardClassName()/]InitialObjectCreationPage(String pageId) - { - super(pageId); - } - - /** - * - * - * @generated - */ - public void createControl(Composite parent) - { - Composite composite = new Composite(parent, SWT.NONE); - { - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - layout.verticalSpacing = 12; - composite.setLayout(layout); - - GridData data = new GridData(); - data.verticalAlignment = GridData.FILL; - data.grabExcessVerticalSpace = true; - data.horizontalAlignment = GridData.FILL; - composite.setLayoutData(data); - } - -[if (genModel.richClientPlatform)] - Label resourceURILabel = new Label(composite, SWT.LEFT); - { - resourceURILabel.setText([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_File_label"));[genModel.getNonNLS()/] - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - resourceURILabel.setLayoutData(data); - } - - Composite fileComposite = new Composite(composite, SWT.NONE); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.END; - fileComposite.setLayoutData(data); - - GridLayout layout = new GridLayout(); - data.horizontalAlignment = GridData.FILL; - layout.marginHeight = 0; - layout.marginWidth = 0; - layout.numColumns = 2; - fileComposite.setLayout(layout); - } - - fileField = new [genModel.getImportedName('org.eclipse.swt.widgets.Text')/](fileComposite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - data.horizontalSpan = 1; - fileField.setLayoutData(data); - } - - fileField.addModifyListener(validator); - - [if (not genModel.richAjaxPlatform)] - [genModel.getImportedName('org.eclipse.swt.widgets.Button')/] resourceURIBrowseFileSystemButton = new [genModel.getImportedName('org.eclipse.swt.widgets.Button')/](fileComposite, SWT.PUSH); - resourceURIBrowseFileSystemButton.setText([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_Browse_label"));[genModel.getNonNLS()/] - - resourceURIBrowseFileSystemButton.addSelectionListener - (new [genModel.getImportedName('org.eclipse.swt.events.SelectionAdapter')/]() - { - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public void widgetSelected([genModel.getImportedName('org.eclipse.swt.events.SelectionEvent')/] event) - { - String[genModel.genSquareBrackets('')/] filters = [if (not genModel.useGenerics())](String[genModel.genSquareBrackets('')/])[/if][genPackage.getImportedEditorClassName()/].FILE_EXTENSION_FILTERS.toArray(new String[genModel.genSquareBrackets(genPackage.getImportedEditorClassName().concat('.FILE_EXTENSION_FILTERS.size()'))/]; - String[genModel.genSquareBrackets('')/] files = [genModel.getImportedName(genModel.getQualifiedEditorAdvisorClassName())/].openFilePathDialog(getShell(), [genModel.getImportedName('org.eclipse.swt.SWT')/].SAVE, filters); - if (files.length > 0) - { - fileField.setText(files[genModel.genSquareBrackets('0')/]); - } - } - }); - [/if] -[/if] - Label containerLabel = new Label(composite, SWT.LEFT); - { - containerLabel.setText([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_ModelObject"));[genModel.getNonNLS()/] - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - containerLabel.setLayoutData(data); - } - - initialObjectField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - initialObjectField.setLayoutData(data); - } - - [if (genModel.useGenerics())] - for (String objectName : getInitialObjectNames()) - { - initialObjectField.add(getLabel(objectName)); - } - [else] - for (Iterator i = getInitialObjectNames().iterator(); i.hasNext(); ) - { - initialObjectField.add(getLabel((String)i.next())); - } - [/if] - - if (initialObjectField.getItemCount() == 1) - { - initialObjectField.select(0); - } - initialObjectField.addModifyListener(validator); - - Label encodingLabel = new Label(composite, SWT.LEFT); - { - encodingLabel.setText([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_XMLEncoding"));[genModel.getNonNLS()/] - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - encodingLabel.setLayoutData(data); - } - encodingField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - encodingField.setLayoutData(data); - } - - [if (genModel.useGenerics())] - for (String encoding : getEncodings()) - { - encodingField.add(encoding); - } - [else] - for (Iterator i = getEncodings().iterator(); i.hasNext(); ) - { - encodingField.add((String)i.next()); - } - [/if] - - encodingField.select(0); - encodingField.addModifyListener(validator); - - setPageComplete(validatePage()); - setControl(composite); - } - - /** - * - * - * @generated - */ - protected ModifyListener validator = - new ModifyListener() - { - public void modifyText(ModifyEvent e) - { - setPageComplete(validatePage()); - } - }; - - /** - * - * - * @generated - */ - protected boolean validatePage() - { -[if (genModel.richClientPlatform)] - URI fileURI = getFileURI(); - if (fileURI == null || fileURI.isEmpty()) - { - setErrorMessage(null); - return false; - } - - String extension = fileURI.fileExtension(); - if (extension == null || !FILE_EXTENSIONS.contains(extension)) - { - String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension";[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - setErrorMessage([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString(key, new Object [genModel.genSquareBrackets('')/] { FORMATTED_FILE_EXTENSIONS })); - return false; - } - - setErrorMessage(null); -[/if] - return getInitialObjectName() != null && getEncodings().contains(encodingField.getText()); - } - - /** - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void setVisible(boolean visible) - { - super.setVisible(visible); - if (visible) - { -[if (not genModel.richClientPlatform)] - if (initialObjectField.getItemCount() == 1) - { - initialObjectField.clearSelection(); - encodingField.setFocus(); - } - else - { - encodingField.clearSelection(); - initialObjectField.setFocus(); - } -[else] - initialObjectField.clearSelection(); - encodingField.clearSelection(); - fileField.setFocus(); -[/if] - } - } - - /** - * - * - * @generated - */ - public String getInitialObjectName() - { - String label = initialObjectField.getText(); - - [if (genModel.useGenerics())] - for (String name : getInitialObjectNames()) - [else] - for (Iterator i = getInitialObjectNames().iterator(); i.hasNext(); ) - [/if] - { - [if (not genModel.useGenerics())] - String name = (String)i.next(); - [/if] - if (getLabel(name).equals(label)) - { - return name; - } - } - return null; - } - - /** - * - * - * @generated - */ - public String getEncoding() - { - return encodingField.getText(); - } -[if (genModel.richClientPlatform)] - - /** - * - * - * @generated - */ - public URI getFileURI() - { - try - { - return URI.createFileURI(fileField.getText()); - } - catch (Exception exception) - { - // Ignore - } - return null; - } - - /** - * - * - * @generated - */ - public void selectFileField() - { - initialObjectField.clearSelection(); - encodingField.clearSelection(); - fileField.selectAll(); - fileField.setFocus(); - } -[/if] - - - /** - * Returns the label for the specified [genPackage._type()/] name. - * - * - * @generated - */ - protected String getLabel(String [genPackage._type()/]Name) - { - try - { - return [genPackage.getEditPluginClassName()/].INSTANCE.getString("[genPackage._prefix()/]" + [genPackage._type()/]Name + "_[genPackage._type()/]");[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - } - catch(MissingResourceException mre) - { - [genModel.getImportedName(genModel.getQualifiedEditorPluginClassName())/].INSTANCE.log(mre); - } - return [genPackage._type()/]Name; - } - - /** - * - * - * @generated - */ - protected [genModel._CollectionOfString()/] getEncodings() - { - if (encodings == null) - { - encodings = new [genModel._ArrayListOfString()/](); - for (StringTokenizer stringTokenizer = new StringTokenizer([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens(); )[genModel.getNonNLS()/] - { - encodings.add(stringTokenizer.nextToken()); - } - } - return encodings; - } - } - - /** - * The framework calls this to create the contents of the wizard. - * - * - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public void addPages() - { -[if (not genModel.richClientPlatform)] - // Create a page, set the title, and the initial model file name. - // - newFileCreationPage = new [genPackage.getModelWizardClassName()/]NewFileCreationPage("Whatever", selection);[genModel.getNonNLS()/] - newFileCreationPage.setTitle([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_[genPackage.getModelWizardClassName()/]_label"));[genModel.getNonNLS()/] - newFileCreationPage.setDescription([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_[genPackage.getModelWizardClassName()/]_description"));[genModel.getNonNLS()/] - newFileCreationPage.setFileName([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_[genPackage.getEditorClassName()/]FilenameDefaultBase") + "." + [if (not genModel.useGenerics())](String)[/if]FILE_EXTENSIONS.get(0));[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - addPage(newFileCreationPage); - - // Try and get the resource selection to determine a current directory for the file dialog. - // - if (selection != null && !selection.isEmpty()) - { - // Get the resource... - // - Object selectedElement = selection.iterator().next(); - if (selectedElement instanceof IResource) - { - // Get the resource parent, if its a file. - // - IResource selectedResource = (IResource)selectedElement; - if (selectedResource.getType() == IResource.FILE) - { - selectedResource = selectedResource.getParent(); - } - - // This gives us a directory... - // - if (selectedResource instanceof IFolder || selectedResource instanceof IProject) - { - // Set this for the container. - // - newFileCreationPage.setContainerFullPath(selectedResource.getFullPath()); - - // Make up a unique new name here. - // - String defaultModelBaseFilename = [genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_[genPackage.getEditorClassName()/]FilenameDefaultBase");[genModel.getNonNLS()/] - String defaultModelFilenameExtension = [if (not genModel.useGenerics())](String)[/if]FILE_EXTENSIONS.get(0); - String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension;[genModel.getNonNLS()/] - for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) - { - modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension;[genModel.getNonNLS()/] - } - newFileCreationPage.setFileName(modelFilename); - } - } - } -[/if] - initialObjectCreationPage = new [genPackage.getModelWizardClassName()/]InitialObjectCreationPage("Whatever2");[genModel.getNonNLS()/] - initialObjectCreationPage.setTitle([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_[genPackage.getModelWizardClassName()/]_label"));[genModel.getNonNLS()/] - initialObjectCreationPage.setDescription([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_Wizard_initial_object_description"));[genModel.getNonNLS()/] - addPage(initialObjectCreationPage); - } - -[if (genModel.richClientPlatform)] - /** - * Get the URI from the page. - * - * - * @generated - */ - public URI getModelURI() - { - return initialObjectCreationPage.getFileURI(); - } - -[else] - /** - * Get the file from the page. - * - * - * @generated - */ - public IFile getModelFile() - { - return newFileCreationPage.getModelFile(); - } - -[/if] -} -[/template] - -[template protected _ListOfString (genModel : GenModel)] -[if genModel.useGenerics()]List<[genModel.getImportedName('java.lang.String')/]>[else]List[/if] -[/template] - -[template protected _ArrayListOfString (genModel : GenModel)] -[if genModel.useGenerics()]ArrayList<[genModel.getImportedName('java.lang.String')/]>[else]ArrayList[/if] -[/template] - -[template protected _CollectionOfString (genModel : GenModel)] -[if genModel.useGenerics()]Collection<[genModel.getImportedName('java.lang.String')/]>[else]Collection[/if] -[/template] - -[template protected _MapOfObjectToObject (genModel : GenModel)] -[if genModel.useGenerics()]Map<[genModel.getImportedName('java.lang.Object')/], [genModel.getImportedName('java.lang.Object')/]>[else]Map[/if] -[/template] - -[template protected _HashMapOfObjectToObject (genModel : GenModel)] -[if genModel.useGenerics()]HashMap<[genModel.getImportedName('java.lang.Object')/], [genModel.getImportedName('java.lang.Object')/]>[else]HashMap[/if] -[/template] - -[query protected _type(genPackage : GenPackage) : String = if genPackage.hasDocumentRoot() then 'feature' else 'type' endif/] - -[query protected _prefix(genPackage : GenPackage) : String = if genPackage.hasDocumentRoot() then '_UI_DocumentRoot_' else '_UI_' endif/] - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/Plugin.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/Plugin.mtl deleted file mode 100755 index 722eb5f53..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/Plugin.mtl +++ /dev/null @@ -1,160 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module Plugin('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnumLiteral /] - -[template public Plugin(genModel : GenModel) { packageName : String = genModel.getEditorPluginPackageName() ; className : String = genModel.getEditorPluginClassName() }] -[genModel.initializeImportManager(packageName, className)/] -[genModel.addImport('org.eclipse.emf.common.EMFPlugin')/] -[genModel.addImport('org.eclipse.emf.common.util.ResourceLocator')/] - -[file (genModel.editorPath(packageName, className), false, 'UTF-8')] -[includeHeader()/] -package [packageName/]; -[let content : String = genModel.fileContent(genModel, packageName, className)] -[genModel.genSortedImports()/] - -[content/] -[/let] -[/file] -[/template] - -[template public fileContent(genModel : GenModel, packageName : String, className : String)] -/** - * This is the central singleton for the [genModel.modelName/] editor plugin. - * - * - * @generated - */ -public final class [className/] extends EMFPlugin -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - /** - * Keep track of the singleton. - * - * - * @generated - */ - public static final [className/] INSTANCE = new [className/](); - -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - /** - * Keep track of the singleton. - * - * - * @generated - */ - private static Implementation plugin; - -[/if] - /** - * Create the instance. - * - * - * @generated - */ - public [className/]() - { - super - (new ResourceLocator [genModel.genSquareBrackets('')/] - { -[for (pluginClassName : String | genModel.getEditResourceDelegateImportedPluginClassNames(packageName, className))] - [pluginClassName/].INSTANCE, -[/for] - }); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public ResourceLocator getPluginResourceLocator() - { -[if (genModel.runtimePlatform = GenRuntimePlatform::GWT)] - return null; -[else] - return plugin; -[/if] - } - -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() - { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * - * @generated - */ - public static class Implementation extends [genModel.getImportedName('org.eclipse.emf.common.ui.EclipseUIPlugin')/] - { - /** - * Creates an instance. - * - * -[if (genModel.needsRuntimeCompatibility())] - * @param descriptor the description of the plugin. -[/if] - * @generated - */ - public Implementation([if (genModel.needsRuntimeCompatibility())][genModel.getImportedName('org.eclipse.core.runtime.IPluginDescriptor')/] descriptor[/if]) - { - super([if (genModel.needsRuntimeCompatibility())]descriptor[/if]); - - // Remember the static instance. - // - plugin = this; - } - } - -[/if] -} -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/buildproperties.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/buildproperties.mtl deleted file mode 100644 index 05e485ad2..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/buildproperties.mtl +++ /dev/null @@ -1,48 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module buildproperties('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] - -[template public buildproperties(genModel : GenModel)] -[file (buildpropertiesPath(), false, 'UTF-8')] -[includeHeaderProperties()/] -bin.includes = [pluginClassesLocation()/],\ - icons/,\ -[if (genModel.bundleManifest)] - META-INF/,\ -[/if] -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - plugin.xml,\ -[/if] - plugin.properties -jars.compile.order = [pluginClassesLocation()/] -source.[pluginClassesLocation()/] = [for (sourceFolder : String | genModel.getEditorSourceFolders()) separator (',\\ ')] -[sourceFolder/] -[/for] -output.[pluginClassesLocation()/] = [if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)]bin[else]war/WEB-INF/classes[/if] -[/file] -[/template] - -[query public buildpropertiesPath(genModel : GenModel) : String = 'build.properties' /] - -[query public pluginClassesLocation(genModel : GenModel) : String - = if genModel.runtimeJar then genModel.editorPluginID + '.jar' else '.' endif/] - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/editorIcons.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/editorIcons.mtl deleted file mode 100644 index f455e374e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/editorIcons.mtl +++ /dev/null @@ -1,24 +0,0 @@ -[comment encoding = UTF-8 -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - Initial API and implementation - *******************************************************************************/ -/] -[module editorIcons('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] - -[template public ModelIcon(genPackage : GenPackage)] -[genPackage.generateModelIcon()/] -[/template] - -[template public ModelWizardIcon(genPackage : GenPackage)] -[genPackage.generateModelWizardIcon()/] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/manifestmf.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/manifestmf.mtl deleted file mode 100755 index 404eb5e22..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/manifestmf.mtl +++ /dev/null @@ -1,87 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module manifestmf('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] - -[template public manifestmf(genModel : GenModel)] -[file (manifestmfPath(), false, 'UTF-8')] -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: %pluginName -Bundle-SymbolicName: [genModel.editorPluginID/];singleton:=true -Bundle-Version: 1.0.0.qualifier -Bundle-ClassPath: [if (genModel.runtimeJar)][genModel.editorPluginID/].jar[else].[/if] -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] -Bundle-Activator: [genModel.getQualifiedEditorPluginClassName()/]$Implementation -[/if] -Bundle-Vendor: %providerName -Bundle-Localization: plugin -[if (genModel.complianceLevel = GenJDKLevel::JDK50)] -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -[elseif (genModel.complianceLevel = GenJDKLevel::JDK60)] -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -[/if] -[for (pack : String | genModel.getEditorQualifiedPackageNames()) before ('Export-Package:') separator (',' + genModel.getLineDelimiter())] - [pack/][/for] - -[for (pluginID : String | genModel.getEditorRequiredPlugins()) before ('Require-Bundle:') separator (',' + genModel.getLineDelimiter())] - [pluginID/][if (not pluginID.startsWith('org.eclipse.core.runtime'))];visibility:=reexport[/if][/for] - -[if (genModel.richAjaxPlatform)] -Import-Package: org.eclipse.emf.common.ui, - org.eclipse.emf.common.ui.action, - org.eclipse.emf.common.ui.dialogs, - org.eclipse.emf.common.ui.editor, - org.eclipse.emf.common.ui.viewer, - org.eclipse.emf.edit.ui, - org.eclipse.emf.edit.ui.action, - org.eclipse.emf.edit.ui.celleditor, - org.eclipse.emf.edit.ui.dnd, - org.eclipse.emf.edit.ui.provider, - org.eclipse.emf.edit.ui.util, - org.eclipse.emf.edit.ui.view, - org.eclipse.jface.action, - org.eclipse.jface.dialogs, - org.eclipse.jface.operation, - org.eclipse.jface.viewers, - org.eclipse.jface.window, - org.eclipse.jface.wizard, - org.eclipse.swt, - org.eclipse.swt.custom, - org.eclipse.swt.dnd, - org.eclipse.swt.events, - org.eclipse.swt.graphics, - org.eclipse.swt.layout, - org.eclipse.swt.widgets, - org.eclipse.ui;ui.workbench="split", - org.eclipse.ui.actions;ui.workbench="split", - org.eclipse.ui.application, - org.eclipse.ui.part;ui.workbench="split", - org.eclipse.ui.views, - org.eclipse.ui.views.contentoutline, - org.eclipse.ui.views.properties;ui.views="split" -[/if] -[if (genModel.runtimeVersion = GenRuntimeVersion::EMF22 or genModel.runtimeVersion = GenRuntimeVersion::EMF23)] -Eclipse-LazyStart: true -[/if] -Bundle-ActivationPolicy: lazy -[/file] -[/template] - -[query public manifestmfPath(genModel : GenModel) : String = 'META-INF/MANIFEST.MF' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/pluginproperties.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/pluginproperties.mtl deleted file mode 100755 index 428b15536..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/pluginproperties.mtl +++ /dev/null @@ -1,132 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module pluginproperties('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnumLiteral /] - -[template public pluginproperties(genModel : GenModel)] -[file (pluginpropertiesPath(), false, 'UTF-8')] -[includeHeaderProperties()/] -pluginName = [genModel.modelName/] Editor -providerName = www.example.org -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - -[for (genPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers())] -_UI_[genPackage.getEditorClassName()/]_menu = &[genPackage.prefix/] Editor -[/for] - -[if (genModel.creationCommands)] -_UI_CreateChild_menu_item = &New Child -_UI_CreateSibling_menu_item = N&ew Sibling - -[/if] -_UI_ShowPropertiesView_menu_item = Show &Properties View -_UI_RefreshViewer_menu_item = &Refresh - -_UI_SelectionPage_label = Selection -[if (genModel.getAllGenPackagesWithClassifiers()->select(multipleEditorPages)->notEmpty())] -_UI_ParentPage_label = Parent -_UI_ListPage_label = List -_UI_TreePage_label = Tree -_UI_TablePage_label = Table -_UI_TreeWithColumnsPage_label = Tree with Columns -_UI_ObjectColumn_label = Object -_UI_SelfColumn_label = Self -[/if] - -_UI_NoObjectSelected = Selected Nothing -_UI_SingleObjectSelected = Selected Object: {0} -_UI_MultiObjectSelected = Selected {0} Objects - -_UI_OpenEditorError_label = Open Editor - -_UI_Wizard_category = Example EMF Model Creation Wizards - -_UI_CreateModelError_message = Problems encountered in file "{0}" - -[for (genPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers())] - [if (genPackage.generateModelWizard)] -_UI_[genPackage.getModelWizardClassName()/]_label = [genPackage.prefix/] Model -_UI_[genPackage.getModelWizardClassName()/]_description = Create a new [genPackage.prefix/] model - - [/if] -_UI_[genPackage.getEditorClassName()/]_label = [genPackage.prefix/] Model Editor - -_UI_[genPackage.getEditorClassName()/]FilenameDefaultBase = My -_UI_[genPackage.getEditorClassName()/]FilenameExtensions = [if (genPackage.isMultipleFileExtensions())][genPackage.fileExtensions/][else][genPackage.getFileExtension()/][/if] - -[/for] -_UI_Wizard_label = New - -_WARN_FilenameExtension = The file name must end in ''.{0}'' -_WARN_FilenameExtensions = The file name must have one of the following extensions: {0} - -_UI_ModelObject = &Model Object -_UI_XMLEncoding = &XML Encoding -_UI_XMLEncodingChoices = [genModel.getXMLEncodingChoices()/] -[if (genModel.richClientPlatform)] -_UI_Wizard_initial_object_description = Specify a file name and select a model object to create -[else] -_UI_Wizard_initial_object_description = Select a model object to create -[/if] - -_UI_FileConflict_label = File Conflict -_WARN_FileConflict = There are unsaved changes that conflict with changes made outside the editor. Do you wish to discard this editor's changes? - -[if (genModel.richClientPlatform)] -_UI_[genModel.getEditorAdvisorClassName()/]_ActionSet_label = [genModel.modelName/] Action Set -_UI_Perspective_label = [genModel.modelName/] - -_UI_Browse_label = &Browse... -_UI_File_label = &File -_UI_Question_title = Question -_WARN_FileConflict = The file "{0}" already exists. Do you want to replace the existing file? -_UI_Error_title = Error -_WARN_No_Editor = There is no editor registered for the file "{0}". - -_UI_Application_title = [genModel.modelName/] Application -_UI_Menu_File_label = &File -_UI_Menu_New_label = &New -_UI_Menu_Open_label = &Open... -_UI_Menu_Open_description = Opens a model object file -_UI_Menu_OpenURI_label = &Open URI... -_UI_Menu_OpenURI_description = Opens a model object loading it from a URI -_UI_Menu_Edit_label = &Edit -_UI_Menu_Window_label = &Window -_UI_Menu_Help_label = &Help -_UI_Menu_About_label = [genModel.modelName/] &About... -_UI_About_title = [genModel.modelName/] Application -_UI_About_text = [genModel.modelName/] Application about box goes here. - -[for (genPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers())][if (genPackage.generateModelWizard)] -_UI_[genPackage.getModelWizardClassName()/]_ActionSet_label = [genPackage.prefix/] Model Action Set -[/if][/for] - -[/if] -[/if] -[/file] -[/template] - -[query public pluginpropertiesPath(genModel : GenModel) : String = 'plugin.properties' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/pluginxml.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/pluginxml.mtl deleted file mode 100644 index daac4cce1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/editor/pluginxml.mtl +++ /dev/null @@ -1,264 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo - * - * - */ -/] -[module pluginxml('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage/] - -[template public pluginxml(genModel : GenModel)] -[file (pluginxmlPath(), false, 'UTF-8')] - - - -[includeHeaderXml()/] - -[if (genModel.bundleManifest)] - -[else] - - - - [for (pluginID : String | genModel.getEditorRequiredPlugins())] - - [/for] - - - - [if (genModel.runtimeJar)] - - [else] - - [/if] - - - -[/if] -[if (genModel.sameEditEditorProject())] - [for (genPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers())] - [if (not genPackage.genClasses->isEmpty())] - - - ') ][supported/][/for] - - [comment]<%if (genPackage.isChildCreationExtenders()) { Map>> extendedChildCreationData = genPackage.getExtendedChildCreationData();%> - <%if (!extendedChildCreationData.isEmpty()) {%>[/comment] -[if (genPackage.childCreationExtenders)] - - [for (genPackage.getExtendedChildCreationDataEntrySet())] - [let key : GenPackage = getPackageEntryKey()] - - [/let] - [/for] - -[/if] - [/if] - [/for] -[/if] -[if (genModel.sameModelEditorProject())] - [for (genPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers())] - - - - [else] - class="[genPackage.getQualifiedPackageInterfaceName()/]"/> - [/if] - - [if (genPackage.isContentType())] - - - - - - - - - [if (genPackage.hasTargetNamespace())] - - [/if] - [if (genPackage.isXMIResource())] - - [/if] - - - - [elseif (genPackage.getResource() <> GenResourceKind::None)] - - - - - [/if] - [/for] -[/if] -[if (genModel.richClientPlatform)] - - - - - - - - - - - - - - - [if (not genModel.richAjaxPlatform)] - - [/if] - - -[if (not genModel.richAjaxPlatform)] - - - - -[/if] - - - - - - [if (not genModel.richAjaxPlatform)] - - [/if] - - -[/if] -[for (genPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers())] - [if (genPackage.hasConcreteClasses())] - [if (genPackage.generateModelWizard)] - [if (genModel.richClientPlatform)] - - - - - - - [else] - - - - - %_UI_[genPackage.getModelWizardClassName()/]_description - - - - [/if] - [/if] - - - - [if (genPackage.isContentType())] - - [/if] - - - [/if] -[/for] - - -[/file] -[/template] - -[query public pluginxmlPath (genModel : GenModel) : String = 'plugin.xml' /] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEdit.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEdit.java deleted file mode 100644 index 3ec9a0fad..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEdit.java +++ /dev/null @@ -1,436 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.main; - -import java.io.File; -import java.io.IOException; -import java.net.URL; -import java.util.ArrayList; -import java.util.Enumeration; -import java.util.List; - -import org.eclipse.acceleo.common.preference.AcceleoPreferences; -import org.eclipse.acceleo.engine.event.IAcceleoTextGenerationListener; -import org.eclipse.acceleo.engine.generation.strategy.IAcceleoGenerationStrategy; -import org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.osgi.framework.Bundle; - -/** - * Entry point of the 'GenAll' generation module. - * - * @author Stephane Bouchet - * @generated - */ -public class GenEdit extends AbstractAcceleoGenerator { - /** - * The name of the module. - * - * @generated - */ - public static final String MODULE_FILE_NAME = "/org/eclipse/emf/eef/codegen/ecore/main/GenEdit"; - - /** - * The name of the templates that are to be generated. - * - * @generated - */ - public static final String[] TEMPLATE_NAMES = { "GenAllGenClass" }; - - /** - * The list of properties files from the launch parameters (Launch configuration). - * - * @generated - */ - private List propertiesFiles = new ArrayList(); - - /** - * Allows the public constructor to be used. Note that a generator created this way cannot be used to - * launch generations before one of {@link #initialize(EObject, File, List)} or - * {@link #initialize(URI, File, List)} is called. - *

- * The main reason for this constructor is to allow clients of this generation to call it from another - * Java file, as it allows for the retrieval of {@link #getProperties()} and - * {@link #getGenerationListeners()}. - *

- * - * @generated - */ - public GenEdit() { - // Empty implementation - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param modelURI - * URI where the model on which this generator will be used is located. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in three scenarios : the module cannot be found, it cannot be loaded, or - * the model cannot be loaded. - * @generated - */ - public GenEdit(URI modelURI, File targetFolder, List arguments) throws IOException { - initialize(modelURI, targetFolder, arguments); - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param model - * We'll iterate over the content of this element to find Objects matching the first parameter - * of the template we need to call. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in two scenarios : the module cannot be found, or it cannot be loaded. - * @generated - */ - public GenEdit(EObject model, File targetFolder, List arguments) throws IOException { - initialize(model, targetFolder, arguments); - } - -// /** -// * FIX the build for Acceleo 3.1.3 -// * @see org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator#createTemplateURI(java.lang.String) -// */ -// @Override -// protected URI createTemplateURI(String entry) { -// if (EMFPlugin.IS_ECLIPSE_RUNNING) { -// Bundle bundle = Platform.getBundle("org.eclipse.emf.eef.codegen.ecore"); -// Enumeration e = bundle.findEntries("/", "*.emtl", true); -// while (e.hasMoreElements()) { -// URL anUrl = e.nextElement(); -// if (anUrl.toString().endsWith("org/eclipse/emf/eef/codegen/ecore/main/GenEdit.emtl")) { -// return URI.createURI("org.eclipse.emf.eef.codegen.ecore" + anUrl.getPath()); -// } -// } -// } -// return super.createTemplateURI(entry); -// } -// - /** - * This can be used to launch the generation from a standalone application. - * - * @param args - * Arguments of the generation. - * @generated - */ - public static void main(String[] args) { - try { - if (args.length < 2) { - System.out.println("Arguments not valid : {model, folder}."); - } else { - URI modelURI = URI.createFileURI(args[0]); - File folder = new File(args[1]); - - List arguments = new ArrayList(); - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * Add in this list all the arguments used by the starting point of the generation - * If your main template is called on an element of your model and a String, you can - * add in "arguments" this "String" attribute. - */ - - GenEdit generator = new GenEdit(modelURI, folder, arguments); - - /* - * Add the properties from the launch arguments. - * If you want to programmatically add new properties, add them in "propertiesFiles" - * You can add the absolute path of a properties files, or even a project relative path. - * If you want to add another "protocol" for your properties files, please override - * "getPropertiesLoaderService(AcceleoService)" in order to return a new property loader. - * The behavior of the properties loader service is explained in the Acceleo documentation - * (Help -> Help Contents). - */ - - for (int i = 2; i < args.length; i++) { - generator.addPropertiesFile(args[i]); - } - - generator.doGenerate(new BasicMonitor()); - } - } catch (IOException e) { - e.printStackTrace(); - } - } - - /** - * Launches the generation described by this instance. - * - * @param monitor - * This will be used to display progress information to the user. - * @throws IOException - * This will be thrown if any of the output files cannot be saved to disk. - * @generated NOT - */ - @Override - public void doGenerate(Monitor monitor) throws IOException { - /* - * TODO if you wish to change the generation as a whole, override this. The default behavior should be - * sufficient in most cases. If you want to change the content of this method, do NOT forget to change - * the "@generated" tag in the Javadoc of this method to "@generated NOT". Without this new tag, any - * compilation of the Acceleo module with the main template that has caused the creation of this class - * will revert your modifications. If you encounter a problem with an unresolved proxy during the - * generation, you can remove the comments in the following instructions to check for problems. Please - * note that those instructions may have a significant impact on the performances. - */ - - // org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(model); - - // if (model != null && model.eResource() != null) { - // List errors = model.eResource().getErrors(); - // for (org.eclipse.emf.ecore.resource.Resource.Diagnostic diagnostic : errors) { - // System.err.println(diagnostic.toString()); - // } - // } - AcceleoPreferences.switchQueryCache(false); - super.doGenerate(monitor); - AcceleoPreferences.switchQueryCache(true); - } - - /** - * If this generator needs to listen to text generation events, listeners can be returned from here. - * - * @return List of listeners that are to be notified when text is generated through this launch. - * @generated - */ - @Override - public List getGenerationListeners() { - List listeners = super.getGenerationListeners(); - /* - * TODO if you need to listen to generation event, add listeners to the list here. If you want to change - * the content of this method, do NOT forget to change the "@generated" tag in the Javadoc of this method - * to "@generated NOT". Without this new tag, any compilation of the Acceleo module with the main template - * that has caused the creation of this class will revert your modifications. - */ - return listeners; - } - - /** - * If you need to change the way files are generated, this is your entry point. - *

- * The default is {@link org.eclipse.acceleo.engine.generation.strategy.DefaultStrategy}; it generates - * files on the fly. If you only need to preview the results, return a new - * {@link org.eclipse.acceleo.engine.generation.strategy.PreviewStrategy}. Both of these aren't aware of - * the running Eclipse and can be used standalone. - *

- *

- * If you need the file generation to be aware of the workspace (A typical example is when you wanna - * override files that are under clear case or any other VCS that could forbid the overriding), then - * return a new {@link org.eclipse.acceleo.engine.generation.strategy.WorkspaceAwareStrategy} . - * Note, however, that this cannot be used standalone. - *

- *

- * All three of these default strategies support merging through JMerge. - *

- * - * @return The generation strategy that is to be used for generations launched through this launcher. - * @generated - */ - @Override - public IAcceleoGenerationStrategy getGenerationStrategy() { - return super.getGenerationStrategy(); - } - - /** - * This will be called in order to find and load the module that will be launched through this launcher. - * We expect this name not to contain file extension, and the module to be located beside the launcher. - * - * @return The name of the module that is to be launched. - * @generated - */ - @Override - public String getModuleName() { - return MODULE_FILE_NAME; - } - - /** - * If the module(s) called by this launcher require properties files, return their qualified path from - * here.Take note that the first added properties files will take precedence over subsequent ones if they - * contain conflicting keys. - *

- * Properties need to be in source folders, the path that we expect to get as a result of this call are of - * the form <package>.<properties file name without extension>. For example, if you have a file - * named "messages.properties" in package "org.eclipse.acceleo.sample", the path that needs be returned by - * a call to {@link #getProperties()} is "org.eclipse.acceleo.sample.messages". - *

- * - * @return The list of properties file we need to add to the generation context. - * @see java.util.ResourceBundle#getBundle(String) - * @generated - */ - @Override - public List getProperties() { - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO if your generation module requires access to properties files, add their qualified path to the list here. - * - * Properties files can be located in an Eclipse plug-in or in the file system (all Acceleo projects are Eclipse - * plug-in). In order to use properties files located in an Eclipse plugin, you need to add the path of the properties - * files to the "propertiesFiles" list: - * - * final String prefix = "platform:/plugin/"; - * final String pluginName = "org.eclipse.acceleo.module.sample"; - * final String packagePath = "/org/eclipse/acceleo/module/sample/properties/"; - * final String fileName = "default.properties"; - * propertiesFiles.add(prefix + pluginName + packagePath + fileName); - * - * With this mechanism, you can load properties files from your plugin or from another plugin. - * - * You may want to load properties files from the file system, for that you need to add the absolute path of the file: - * - * propertiesFiles.add("C:\Users\MyName\MyFile.properties"); - * - * If you want to let your users add properties files located in the same folder as the model: - * - * if (EMFPlugin.IS_ECLIPSE_RUNNING && model != null && model.eResource() != null) { - * propertiesFiles.addAll(AcceleoEngineUtils.getPropertiesFilesNearModel(model.eResource())); - * } - * - * To learn more about Properties Files, have a look at the Acceleo documentation (Help -> Help Contents). - */ - return propertiesFiles; - } - - /** - * Adds a properties file in the list of properties files. - * - * @param propertiesFile - * The properties file to add. - * @generated - * @since 3.1 - */ - @Override - public void addPropertiesFile(String propertiesFile) { - this.propertiesFiles.add(propertiesFile); - } - - /** - * This will be used to get the list of templates that are to be launched by this launcher. - * - * @return The list of templates to call on the module {@link #getModuleName()}. - * @generated - */ - @Override - public String[] getTemplateNames() { - return TEMPLATE_NAMES; - } - - /** - * This can be used to update the resource set's package registry with all needed EPackages. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerPackages(ResourceSet resourceSet) { - super.registerPackages(resourceSet); - if (!isInWorkspace(org.eclipse.emf.ecore.EcorePackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - } - if (!isInWorkspace(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE.getNsURI(), org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE); - } - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * If you need additional package registrations, you can register them here. The following line - * (in comment) is an example of the package registration for UML. - * - * You can use the method "isInWorkspace(Class c)" to check if the package that you are about to - * register is in the workspace. - * - * To register a package properly, please follow the following conventions: - * - * If the package is located in another plug-in, already installed in Eclipse. The following content should - * have been generated at the beginning of this method. Do not register the package using this mechanism if - * the metamodel is located in the workspace. - * - * if (!isInWorkspace(UMLPackage.class)) { - * // The normal package registration if your metamodel is in a plugin. - * resourceSet.getPackageRegistry().put(UMLPackage.eNS_URI, UMLPackage.eINSTANCE); - * } - * - * If the package is located in another project in your workspace, the plugin containing the package has not - * been register by EMF and Acceleo should register it automatically. If you want to use the generator in - * stand alone, the regular registration (seen a couple lines before) is needed. - * - * To learn more about Package Registration, have a look at the Acceleo documentation (Help -> Help Contents). - */ - } - - /** - * This can be used to update the resource set's resource factory registry with all needed factories. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerResourceFactories(ResourceSet resourceSet) { - super.registerResourceFactories(resourceSet); - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO If you need additional resource factories registrations, you can register them here. the following line - * (in comment) is an example of the resource factory registration for UML. - * - * If you want to use the generator in stand alone, the resource factory registration will be required. - * - * To learn more about the registration of Resource Factories, have a look at the Acceleo documentation (Help -> Help Contents). - */ - - // resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEdit.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEdit.mtl deleted file mode 100644 index 7933b8ff1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEdit.mtl +++ /dev/null @@ -1,68 +0,0 @@ -[comment encoding = UTF-8 -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - Initial API and implementation - *******************************************************************************/ -/] -[module GenEdit('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::edit::ItemProvider/] -[import org::eclipse::emf::eef::codegen::ecore::edit::ItemProviderAdapterFactory/] -[import org::eclipse::emf::eef::codegen::ecore::edit::buildproperties/] -[import org::eclipse::emf::eef::codegen::ecore::edit::manifestmf /] -[import org::eclipse::emf::eef::codegen::ecore::edit::Plugin /] -[import org::eclipse::emf::eef::codegen::ecore::edit::pluginproperties /] -[import org::eclipse::emf::eef::codegen::ecore::edit::pluginxml /] -[import org::eclipse::emf::eef::codegen::ecore::edit::editIcons /] -[import org::eclipse::emf::eef::codegen::ecore::services::fileUtil /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] - -[template public GenAllGenClass(model : GenModel) ? (model.canGenerateEdit())] -[comment @main /] -[comment edit generation/] -[for (p : GenPackage | model.eAllContents(GenPackage))] - [if (p.canGenerateEdit() and p.genClasses->notEmpty())] - [p.ItemProviderAdapterFactory()/] - [p.CreateChildIcons()/][comment @TODO Check this line is necessary/] - [for (c : GenClass | p.genClasses)] - [if (c.canGenerateEdit())] - [c.ItemProvider()/] - [if (c.image)] - [c.ItemIcon()/] - [/if] - [if (model.creationCommands and model.creationIcons)] - [c.CreateChildIcons()/] - [/if] - [/if] - [/for] - [/if] -[/for] - -[if (not model.sameEditEditorProject())] - [model.Plugin()/] - - [if (model.bundleManifest and not model.fileExistsEdit(model.manifestmfPath()))] - [model.manifestmf()/] - [/if] - - [if (not model.fileExistsEdit(model.pluginxmlPath()))] - [model.pluginxml()/] - [/if] -[/if] - -[if (not model.fileExistsEdit(model.pluginpropertiesPath()))] - [model.pluginproperties()/] -[/if] - -[if (not model.fileExistsEdit(model.buildpropertiesPath()))] - [model.buildproperties()/] -[/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEditor.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEditor.java deleted file mode 100644 index 1d4922eaf..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEditor.java +++ /dev/null @@ -1,437 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.main; - -import java.io.File; -import java.io.IOException; -import java.net.URL; -import java.util.ArrayList; -import java.util.Enumeration; -import java.util.List; - -import org.eclipse.acceleo.common.preference.AcceleoPreferences; -import org.eclipse.acceleo.engine.event.IAcceleoTextGenerationListener; -import org.eclipse.acceleo.engine.generation.strategy.IAcceleoGenerationStrategy; -import org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.osgi.framework.Bundle; - -/** - * Entry point of the 'GenEditor' generation module. - * - * @author Stephane Bouchet - * @generated - */ -public class GenEditor extends AbstractAcceleoGenerator { - /** - * The name of the module. - * - * @generated - */ - public static final String MODULE_FILE_NAME = "/org/eclipse/emf/eef/codegen/ecore/main/GenEditor"; - - /** - * The name of the templates that are to be generated. - * - * @generated - */ - public static final String[] TEMPLATE_NAMES = { "GenAllGenClass" }; - - /** - * The list of properties files from the launch parameters (Launch configuration). - * - * @generated - */ - private List propertiesFiles = new ArrayList(); - - /** - * Allows the public constructor to be used. Note that a generator created this way cannot be used to - * launch generations before one of {@link #initialize(EObject, File, List)} or - * {@link #initialize(URI, File, List)} is called. - *

- * The main reason for this constructor is to allow clients of this generation to call it from another - * Java file, as it allows for the retrieval of {@link #getProperties()} and - * {@link #getGenerationListeners()}. - *

- * - * @generated - */ - public GenEditor() { - // Empty implementation - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param modelURI - * URI where the model on which this generator will be used is located. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in three scenarios : the module cannot be found, it cannot be loaded, or - * the model cannot be loaded. - * @generated - */ - public GenEditor(URI modelURI, File targetFolder, List arguments) throws IOException { - initialize(modelURI, targetFolder, arguments); - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param model - * We'll iterate over the content of this element to find Objects matching the first parameter - * of the template we need to call. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in two scenarios : the module cannot be found, or it cannot be loaded. - * @generated - */ - public GenEditor(EObject model, File targetFolder, List arguments) throws IOException { - initialize(model, targetFolder, arguments); - } - -// /** -// * FIX the build for Acceleo 3.1.3 -// * @see org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator#createTemplateURI(java.lang.String) -// */ -// @Override -// protected URI createTemplateURI(String entry) { -// if (EMFPlugin.IS_ECLIPSE_RUNNING) { -// Bundle bundle = Platform.getBundle("org.eclipse.emf.eef.codegen.ecore"); -// Enumeration e = bundle.findEntries("/", "*.emtl", true); -// while (e.hasMoreElements()) { -// URL anUrl = e.nextElement(); -// if (anUrl.toString().endsWith("org/eclipse/emf/eef/codegen/ecore/main/GenEditor.emtl")) { -// return URI.createURI("org.eclipse.emf.eef.codegen.ecore" + anUrl.getPath()); -// } -// } -// } -// return super.createTemplateURI(entry); -// } - - /** - * This can be used to launch the generation from a standalone application. - * - * @param args - * Arguments of the generation. - * @generated - */ - public static void main(String[] args) { - try { - if (args.length < 2) { - System.out.println("Arguments not valid : {model, folder}."); - } else { - URI modelURI = URI.createFileURI(args[0]); - File folder = new File(args[1]); - - List arguments = new ArrayList(); - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * Add in this list all the arguments used by the starting point of the generation - * If your main template is called on an element of your model and a String, you can - * add in "arguments" this "String" attribute. - */ - - GenEditor generator = new GenEditor(modelURI, folder, arguments); - - /* - * Add the properties from the launch arguments. - * If you want to programmatically add new properties, add them in "propertiesFiles" - * You can add the absolute path of a properties files, or even a project relative path. - * If you want to add another "protocol" for your properties files, please override - * "getPropertiesLoaderService(AcceleoService)" in order to return a new property loader. - * The behavior of the properties loader service is explained in the Acceleo documentation - * (Help -> Help Contents). - */ - - for (int i = 2; i < args.length; i++) { - generator.addPropertiesFile(args[i]); - } - - generator.doGenerate(new BasicMonitor()); - } - } catch (IOException e) { - e.printStackTrace(); - } - } - - /** - * Launches the generation described by this instance. - * - * @param monitor - * This will be used to display progress information to the user. - * @throws IOException - * This will be thrown if any of the output files cannot be saved to disk. - * @generated NOT - */ - @Override - public void doGenerate(Monitor monitor) throws IOException { - /* - * TODO if you wish to change the generation as a whole, override this. The default behavior should - * be sufficient in most cases. If you want to change the content of this method, do NOT forget to - * change the "@generated" tag in the Javadoc of this method to "@generated NOT". Without this new tag, - * any compilation of the Acceleo module with the main template that has caused the creation of this - * class will revert your modifications. If you encounter a problem with an unresolved proxy during the - * generation, you can remove the comments in the following instructions to check for problems. Please - * note that those instructions may have a significant impact on the performances. - */ - - //org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(model); - - //if (model != null && model.eResource() != null) { - // List errors = model.eResource().getErrors(); - // for (org.eclipse.emf.ecore.resource.Resource.Diagnostic diagnostic : errors) { - // System.err.println(diagnostic.toString()); - // } - //} - - AcceleoPreferences.switchQueryCache(false); - super.doGenerate(monitor); - AcceleoPreferences.switchQueryCache(true); - } - - /** - * If this generator needs to listen to text generation events, listeners can be returned from here. - * - * @return List of listeners that are to be notified when text is generated through this launch. - * @generated - */ - @Override - public List getGenerationListeners() { - List listeners = super.getGenerationListeners(); - /* - * TODO if you need to listen to generation event, add listeners to the list here. If you want to change - * the content of this method, do NOT forget to change the "@generated" tag in the Javadoc of this method - * to "@generated NOT". Without this new tag, any compilation of the Acceleo module with the main template - * that has caused the creation of this class will revert your modifications. - */ - return listeners; - } - - /** - * If you need to change the way files are generated, this is your entry point. - *

- * The default is {@link org.eclipse.acceleo.engine.generation.strategy.DefaultStrategy}; it generates - * files on the fly. If you only need to preview the results, return a new - * {@link org.eclipse.acceleo.engine.generation.strategy.PreviewStrategy}. Both of these aren't aware of - * the running Eclipse and can be used standalone. - *

- *

- * If you need the file generation to be aware of the workspace (A typical example is when you wanna - * override files that are under clear case or any other VCS that could forbid the overriding), then - * return a new {@link org.eclipse.acceleo.engine.generation.strategy.WorkspaceAwareStrategy} . - * Note, however, that this cannot be used standalone. - *

- *

- * All three of these default strategies support merging through JMerge. - *

- * - * @return The generation strategy that is to be used for generations launched through this launcher. - * @generated - */ - @Override - public IAcceleoGenerationStrategy getGenerationStrategy() { - return super.getGenerationStrategy(); - } - - /** - * This will be called in order to find and load the module that will be launched through this launcher. - * We expect this name not to contain file extension, and the module to be located beside the launcher. - * - * @return The name of the module that is to be launched. - * @generated - */ - @Override - public String getModuleName() { - return MODULE_FILE_NAME; - } - - /** - * If the module(s) called by this launcher require properties files, return their qualified path from - * here.Take note that the first added properties files will take precedence over subsequent ones if they - * contain conflicting keys. - *

- * Properties need to be in source folders, the path that we expect to get as a result of this call are of - * the form <package>.<properties file name without extension>. For example, if you have a file - * named "messages.properties" in package "org.eclipse.acceleo.sample", the path that needs be returned by - * a call to {@link #getProperties()} is "org.eclipse.acceleo.sample.messages". - *

- * - * @return The list of properties file we need to add to the generation context. - * @see java.util.ResourceBundle#getBundle(String) - * @generated - */ - @Override - public List getProperties() { - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO if your generation module requires access to properties files, add their qualified path to the list here. - * - * Properties files can be located in an Eclipse plug-in or in the file system (all Acceleo projects are Eclipse - * plug-in). In order to use properties files located in an Eclipse plugin, you need to add the path of the properties - * files to the "propertiesFiles" list: - * - * final String prefix = "platform:/plugin/"; - * final String pluginName = "org.eclipse.acceleo.module.sample"; - * final String packagePath = "/org/eclipse/acceleo/module/sample/properties/"; - * final String fileName = "default.properties"; - * propertiesFiles.add(prefix + pluginName + packagePath + fileName); - * - * With this mechanism, you can load properties files from your plugin or from another plugin. - * - * You may want to load properties files from the file system, for that you need to add the absolute path of the file: - * - * propertiesFiles.add("C:\Users\MyName\MyFile.properties"); - * - * If you want to let your users add properties files located in the same folder as the model: - * - * if (EMFPlugin.IS_ECLIPSE_RUNNING && model != null && model.eResource() != null) { - * propertiesFiles.addAll(AcceleoEngineUtils.getPropertiesFilesNearModel(model.eResource())); - * } - * - * To learn more about Properties Files, have a look at the Acceleo documentation (Help -> Help Contents). - */ - return propertiesFiles; - } - - /** - * Adds a properties file in the list of properties files. - * - * @param propertiesFile - * The properties file to add. - * @generated - * @since 3.1 - */ - @Override - public void addPropertiesFile(String propertiesFile) { - this.propertiesFiles.add(propertiesFile); - } - - /** - * This will be used to get the list of templates that are to be launched by this launcher. - * - * @return The list of templates to call on the module {@link #getModuleName()}. - * @generated - */ - @Override - public String[] getTemplateNames() { - return TEMPLATE_NAMES; - } - - /** - * This can be used to update the resource set's package registry with all needed EPackages. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerPackages(ResourceSet resourceSet) { - super.registerPackages(resourceSet); - if (!isInWorkspace(org.eclipse.emf.ecore.EcorePackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - } - if (!isInWorkspace(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE.getNsURI(), org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE); - } - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * If you need additional package registrations, you can register them here. The following line - * (in comment) is an example of the package registration for UML. - * - * You can use the method "isInWorkspace(Class c)" to check if the package that you are about to - * register is in the workspace. - * - * To register a package properly, please follow the following conventions: - * - * If the package is located in another plug-in, already installed in Eclipse. The following content should - * have been generated at the beginning of this method. Do not register the package using this mechanism if - * the metamodel is located in the workspace. - * - * if (!isInWorkspace(UMLPackage.class)) { - * // The normal package registration if your metamodel is in a plugin. - * resourceSet.getPackageRegistry().put(UMLPackage.eNS_URI, UMLPackage.eINSTANCE); - * } - * - * If the package is located in another project in your workspace, the plugin containing the package has not - * been register by EMF and Acceleo should register it automatically. If you want to use the generator in - * stand alone, the regular registration (seen a couple lines before) is needed. - * - * To learn more about Package Registration, have a look at the Acceleo documentation (Help -> Help Contents). - */ - } - - /** - * This can be used to update the resource set's resource factory registry with all needed factories. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerResourceFactories(ResourceSet resourceSet) { - super.registerResourceFactories(resourceSet); - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO If you need additional resource factories registrations, you can register them here. the following line - * (in comment) is an example of the resource factory registration for UML. - * - * If you want to use the generator in stand alone, the resource factory registration will be required. - * - * To learn more about the registration of Resource Factories, have a look at the Acceleo documentation (Help -> Help Contents). - */ - - // resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEditor.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEditor.mtl deleted file mode 100644 index 1e8d3e423..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenEditor.mtl +++ /dev/null @@ -1,60 +0,0 @@ -[comment encoding = UTF-8 -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - Initial API and implementation - *******************************************************************************/ -/] -[module GenEditor('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::editor::ActionBarContributor/] -[import org::eclipse::emf::eef::codegen::ecore::editor::buildproperties /] -[import org::eclipse::emf::eef::codegen::ecore::editor::manifestmf /] -[import org::eclipse::emf::eef::codegen::ecore::editor::Editor /] -[import org::eclipse::emf::eef::codegen::ecore::editor::Plugin /] -[import org::eclipse::emf::eef::codegen::ecore::editor::pluginproperties /] -[import org::eclipse::emf::eef::codegen::ecore::editor::ModelWizard /] -[import org::eclipse::emf::eef::codegen::ecore::editor::pluginxml /] -[import org::eclipse::emf::eef::codegen::ecore::editor::editorIcons /] -[import org::eclipse::emf::eef::codegen::ecore::services::fileUtil /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] - -[template public GenAllGenClass(model : GenModel) ? (model.canGenerateEditor())] -[comment @main /] -[comment editor generation/] -[for (p : GenPackage | model.eAllContents(GenPackage))] - [if (p.canGenerateEditor() and p.hasConcreteClasses())] - [p.Editor()/] - [p.ModelWizard()/] - [p.ActionBarContributor()/] - [p.ModelIcon()/] - [p.ModelWizardIcon()/] - [/if] -[/for] - -[model.Plugin()/] - -[if (model.bundleManifest and not model.fileExistsEditor(model.manifestmfPath()))] - [model.manifestmf()/] -[/if] - -[if (not model.fileExistsEditor(model.pluginxmlPath()))] - [model.pluginxml()/] -[/if] - -[if (not model.fileExistsEditor(model.pluginpropertiesPath()))] - [model.pluginproperties()/] -[/if] - -[if (not model.fileExistsEditor(model.buildpropertiesPath()))] - [model.buildproperties()/] -[/if] - -[comment @TODO EditorAdvisor ??? if model.isRichClientPlatform()/] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenModel.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenModel.java deleted file mode 100644 index 7349903cc..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenModel.java +++ /dev/null @@ -1,484 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.main; - -import java.io.File; -import java.io.IOException; -import java.net.URL; -import java.util.ArrayList; -import java.util.Enumeration; -import java.util.List; - -import org.eclipse.acceleo.common.preference.AcceleoPreferences; -import org.eclipse.acceleo.engine.event.IAcceleoTextGenerationListener; -import org.eclipse.acceleo.engine.generation.strategy.IAcceleoGenerationStrategy; -import org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.osgi.framework.Bundle; - -/** - * Entry point of the 'GenModel' generation module. - * - * @author Stephane Bouchet - * @generated - */ -public class GenModel extends AbstractAcceleoGenerator { - /** - * The name of the module. - * - * @generated - */ - public static final String MODULE_FILE_NAME = "/org/eclipse/emf/eef/codegen/ecore/main/GenModel"; - - /** - * The name of the templates that are to be generated. - * - * @generated - */ - public static final String[] TEMPLATE_NAMES = { "GenAllGenClass" }; - - /** - * The list of properties files from the launch parameters (Launch - * configuration). - * - * @generated - */ - private List propertiesFiles = new ArrayList(); - - /** - * Allows the public constructor to be used. Note that a generator created - * this way cannot be used to launch generations before one of - * {@link #initialize(EObject, File, List)} or - * {@link #initialize(URI, File, List)} is called. - *

- * The main reason for this constructor is to allow clients of this - * generation to call it from another Java file, as it allows for the - * retrieval of {@link #getProperties()} and - * {@link #getGenerationListeners()}. - *

- * - * @generated - */ - public GenModel() { - // Empty implementation - } - - /** - * This allows clients to instantiates a generator with all required - * information. - * - * @param modelURI - * URI where the model on which this generator will be used is - * located. - * @param targetFolder - * This will be used as the output folder for this generation : - * it will be the base path against which all file block URLs - * will be resolved. - * @param arguments - * If the template which will be called requires more than one - * argument taken from the model, pass them here. - * @throws IOException - * This can be thrown in three scenarios : the module cannot be - * found, it cannot be loaded, or the model cannot be loaded. - * @generated - */ - public GenModel(URI modelURI, File targetFolder, - List arguments) throws IOException { - initialize(modelURI, targetFolder, arguments); - } - -// /** -// * FIX the build for Acceleo 3.1.3 -// * @see org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator#createTemplateURI(java.lang.String) -// */ -// @Override -// protected URI createTemplateURI(String entry) { -// if (EMFPlugin.IS_ECLIPSE_RUNNING) { -// Bundle bundle = Platform.getBundle("org.eclipse.emf.eef.codegen.ecore"); -// Enumeration e = bundle.findEntries("/", "*.emtl", true); -// while (e.hasMoreElements()) { -// URL anUrl = e.nextElement(); -// if (anUrl.toString().endsWith("org/eclipse/emf/eef/codegen/ecore/main/GenModel.emtl")) { -// return URI.createURI("org.eclipse.emf.eef.codegen.ecore" + anUrl.getPath()); -// } -// } -// } -// return super.createTemplateURI(entry); -// } - - /** - * This allows clients to instantiates a generator with all required - * information. - * - * @param model - * We'll iterate over the content of this element to find Objects - * matching the first parameter of the template we need to call. - * @param targetFolder - * This will be used as the output folder for this generation : - * it will be the base path against which all file block URLs - * will be resolved. - * @param arguments - * If the template which will be called requires more than one - * argument taken from the model, pass them here. - * @throws IOException - * This can be thrown in two scenarios : the module cannot be - * found, or it cannot be loaded. - * @generated - */ - public GenModel(EObject model, File targetFolder, - List arguments) throws IOException { - initialize(model, targetFolder, arguments); - } - - /** - * This can be used to launch the generation from a standalone application. - * - * @param args - * Arguments of the generation. - * @generated - */ - public static void main(String[] args) { - try { - if (args.length < 2) { - System.out.println("Arguments not valid : {model, folder}."); - } else { - URI modelURI = URI.createFileURI(args[0]); - File folder = new File(args[1]); - - List arguments = new ArrayList(); - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * Add in this list all the arguments used by the starting point of the generation - * If your main template is called on an element of your model and a String, you can - * add in "arguments" this "String" attribute. - */ - - GenModel generator = new GenModel(modelURI, folder, arguments); - - /* - * Add the properties from the launch arguments. - * If you want to programmatically add new properties, add them in "propertiesFiles" - * You can add the absolute path of a properties files, or even a project relative path. - * If you want to add another "protocol" for your properties files, please override - * "getPropertiesLoaderService(AcceleoService)" in order to return a new property loader. - * The behavior of the properties loader service is explained in the Acceleo documentation - * (Help -> Help Contents). - */ - - for (int i = 2; i < args.length; i++) { - generator.addPropertiesFile(args[i]); - } - - generator.doGenerate(new BasicMonitor()); - } - } catch (IOException e) { - e.printStackTrace(); - } - } - - /** - * Launches the generation described by this instance. - * - * @param monitor - * This will be used to display progress information to the user. - * @throws IOException - * This will be thrown if any of the output files cannot be - * saved to disk. - * @generated NOT - */ - @Override - public void doGenerate(Monitor monitor) throws IOException { - /* - * TODO if you wish to change the generation as a whole, override this. The default behavior should - * be sufficient in most cases. If you want to change the content of this method, do NOT forget to - * change the "@generated" tag in the Javadoc of this method to "@generated NOT". Without this new tag, - * any compilation of the Acceleo module with the main template that has caused the creation of this - * class will revert your modifications. If you encounter a problem with an unresolved proxy during the - * generation, you can remove the comments in the following instructions to check for problems. Please - * note that those instructions may have a significant impact on the performances. - */ - - //org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(model); - - //if (model != null && model.eResource() != null) { - // List errors = model.eResource().getErrors(); - // for (org.eclipse.emf.ecore.resource.Resource.Diagnostic diagnostic : errors) { - // System.err.println(diagnostic.toString()); - // } - //} - EObject model = getModel(); - if (model instanceof org.eclipse.emf.codegen.ecore.genmodel.GenModel) { - ((org.eclipse.emf.codegen.ecore.genmodel.GenModel) model).getStaticGenPackages(); - } - boolean formerCacheFlag = AcceleoPreferences.isQueryCacheEnabled(); - try { - AcceleoPreferences.switchQueryCache(false); - super.doGenerate(monitor); - } finally { - AcceleoPreferences.switchQueryCache(formerCacheFlag); - } - } - -// @Override -// protected void postGenerate(ResourceSet rs) { -// org.eclipse.emf.codegen.ecore.genmodel.GenModel genModel = (org.eclipse.emf.codegen.ecore.genmodel.GenModel) getModel(); -// ImportManager importManager = genModel.getImportManager(); -// String sortedImports = importManager.computeSortedImports(); -// -// // Finally, we clear the loaded resources, and do whatever the super -// // implementation does. -// super.postGenerate(rs); -// } - - /** - * If this generator needs to listen to text generation events, listeners - * can be returned from here. - * - * @return List of listeners that are to be notified when text is generated - * through this launch. - * @generated - */ - @Override - public List getGenerationListeners() { - List listeners = super.getGenerationListeners(); - /* - * TODO if you need to listen to generation event, add listeners to the list here. If you want to change - * the content of this method, do NOT forget to change the "@generated" tag in the Javadoc of this method - * to "@generated NOT". Without this new tag, any compilation of the Acceleo module with the main template - * that has caused the creation of this class will revert your modifications. - */ - return listeners; - } - - /** - * If you need to change the way files are generated, this is your entry - * point. - *

- * The default is - * {@link org.eclipse.acceleo.engine.generation.strategy.DefaultStrategy}; - * it generates files on the fly. If you only need to preview the results, - * return a new - * {@link org.eclipse.acceleo.engine.generation.strategy.PreviewStrategy}. - * Both of these aren't aware of the running Eclipse and can be used - * standalone. - *

- *

- * If you need the file generation to be aware of the workspace (A typical - * example is when you wanna override files that are under clear case or any - * other VCS that could forbid the overriding), then return a new - * {@link org.eclipse.acceleo.engine.generation.strategy.WorkspaceAwareStrategy} - * . Note, however, that this cannot be used standalone. - *

- *

- * All three of these default strategies support merging through JMerge. - *

- * - * @return The generation strategy that is to be used for generations - * launched through this launcher. - * @generated - */ - @Override - public IAcceleoGenerationStrategy getGenerationStrategy() { - return super.getGenerationStrategy(); - } - - /** - * This will be called in order to find and load the module that will be - * launched through this launcher. We expect this name not to contain file - * extension, and the module to be located beside the launcher. - * - * @return The name of the module that is to be launched. - * @generated - */ - @Override - public String getModuleName() { - return MODULE_FILE_NAME; - } - - /** - * If the module(s) called by this launcher require properties files, return - * their qualified path from here.Take note that the first added properties - * files will take precedence over subsequent ones if they contain - * conflicting keys. - *

- * Properties need to be in source folders, the path that we expect to get - * as a result of this call are of the form <package>.<properties file - * name without extension>. For example, if you have a file named - * "messages.properties" in package "org.eclipse.acceleo.sample", the path - * that needs be returned by a call to {@link #getProperties()} is - * "org.eclipse.acceleo.sample.messages". - *

- * - * @return The list of properties file we need to add to the generation - * context. - * @see java.util.ResourceBundle#getBundle(String) - * @generated - */ - @Override - public List getProperties() { - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO if your generation module requires access to properties files, add their qualified path to the list here. - * - * Properties files can be located in an Eclipse plug-in or in the file system (all Acceleo projects are Eclipse - * plug-in). In order to use properties files located in an Eclipse plugin, you need to add the path of the properties - * files to the "propertiesFiles" list: - * - * final String prefix = "platform:/plugin/"; - * final String pluginName = "org.eclipse.acceleo.module.sample"; - * final String packagePath = "/org/eclipse/acceleo/module/sample/properties/"; - * final String fileName = "default.properties"; - * propertiesFiles.add(prefix + pluginName + packagePath + fileName); - * - * With this mechanism, you can load properties files from your plugin or from another plugin. - * - * You may want to load properties files from the file system, for that you need to add the absolute path of the file: - * - * propertiesFiles.add("C:\Users\MyName\MyFile.properties"); - * - * If you want to let your users add properties files located in the same folder as the model: - * - * if (EMFPlugin.IS_ECLIPSE_RUNNING && model != null && model.eResource() != null) { - * propertiesFiles.addAll(AcceleoEngineUtils.getPropertiesFilesNearModel(model.eResource())); - * } - * - * To learn more about Properties Files, have a look at the Acceleo documentation (Help -> Help Contents). - */ - return propertiesFiles; - } - - /** - * Adds a properties file in the list of properties files. - * - * @param propertiesFile - * The properties file to add. - * @generated - * @since 3.1 - */ - @Override - public void addPropertiesFile(String propertiesFile) { - this.propertiesFiles.add(propertiesFile); - } - - /** - * This will be used to get the list of templates that are to be launched by - * this launcher. - * - * @return The list of templates to call on the module - * {@link #getModuleName()}. - * @generated - */ - @Override - public String[] getTemplateNames() { - return TEMPLATE_NAMES; - } - - /** - * This can be used to update the resource set's package registry with all - * needed EPackages. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerPackages(ResourceSet resourceSet) { - super.registerPackages(resourceSet); - if (!isInWorkspace(org.eclipse.emf.ecore.EcorePackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - } - if (!isInWorkspace(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE.getNsURI(), org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE); - } - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * If you need additional package registrations, you can register them here. The following line - * (in comment) is an example of the package registration for UML. - * - * You can use the method "isInWorkspace(Class c)" to check if the package that you are about to - * register is in the workspace. - * - * To register a package properly, please follow the following conventions: - * - * If the package is located in another plug-in, already installed in Eclipse. The following content should - * have been generated at the beginning of this method. Do not register the package using this mechanism if - * the metamodel is located in the workspace. - * - * if (!isInWorkspace(UMLPackage.class)) { - * // The normal package registration if your metamodel is in a plugin. - * resourceSet.getPackageRegistry().put(UMLPackage.eNS_URI, UMLPackage.eINSTANCE); - * } - * - * If the package is located in another project in your workspace, the plugin containing the package has not - * been register by EMF and Acceleo should register it automatically. If you want to use the generator in - * stand alone, the regular registration (seen a couple lines before) is needed. - * - * To learn more about Package Registration, have a look at the Acceleo documentation (Help -> Help Contents). - */ - } - - /** - * This can be used to update the resource set's resource factory registry - * with all needed factories. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerResourceFactories(ResourceSet resourceSet) { - super.registerResourceFactories(resourceSet); - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO If you need additional resource factories registrations, you can register them here. the following line - * (in comment) is an example of the resource factory registration for UML. - * - * If you want to use the generator in stand alone, the resource factory registration will be required. - * - * To learn more about the registration of Resource Factories, have a look at the Acceleo documentation (Help -> Help Contents). - */ - - // resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenModel.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenModel.mtl deleted file mode 100644 index 14024a7ad..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/main/GenModel.mtl +++ /dev/null @@ -1,145 +0,0 @@ -[comment encoding = UTF-8 -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - Initial API and implementation - *******************************************************************************/ -/] -[module GenModel('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::model::buildproperties /] -[import org::eclipse::emf::eef::codegen::ecore::model::AdapterFactoryClass /] -[import org::eclipse::emf::eef::codegen::ecore::model::FactoryClass /] -[import org::eclipse::emf::eef::codegen::ecore::model::PackageClass /] -[import org::eclipse::emf::eef::codegen::ecore::model::Class /] -[import org::eclipse::emf::eef::codegen::ecore::model::EnumClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::model::manifest /] -[import org::eclipse::emf::eef::codegen::ecore::model::module_gwt_xml /] -[import org::eclipse::emf::eef::codegen::ecore::model::Plugin /] -[import org::eclipse::emf::eef::codegen::ecore::model::plugin_properties /] -[import org::eclipse::emf::eef::codegen::ecore::model::plugin_xml /] -[import org::eclipse::emf::eef::codegen::ecore::model::ResourceClass /] -[import org::eclipse::emf::eef::codegen::ecore::model::ResourceFactoryClass /] -[import org::eclipse::emf::eef::codegen::ecore::model::SwitchClass /] -[import org::eclipse::emf::eef::codegen::ecore::model::ValidatorClass /] -[import org::eclipse::emf::eef::codegen::ecore::model::XmlProcessorClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::fileUtil /] - -[** - * Generates all the classes of the Model plug-in from a genModel. - * - * WARNING: The genModel passed to this template MUST be loaded and reconciled as in - * org.eclipse.emf.codegen.ecore.genmodel.presentation.GeneratorUIUtil.loadGenModels() - * Otherwise canGenerate() will always return false, and invalid reference in the GenModel will cause problems. - * In order to prevent a reference to an Ecore UI plug-in, this is done in the eef ui plug-in. - * -*/] -[template public GenAllGenClass(genModel : GenModel) ? (genModel.canGenerate())] - [comment @main /] - [if (not genModel.fileExistsModel(genModel.buildPropertiesFilePath()))] - [genModel.buildProperties()/] - [/if] - - [comment from EMF codegen : Do allow an existing MANIFEST.MF to be overwritten, since it may have been created as part of an empty EMF project. - Use the existence of a plugin.xml as a guard against overwriting in a project that has already been generated. /] - [if (not genModel.fileExistsModel(genModel.pluginXmlFilePath()))] - [genModel.manifest()/] - [/if] - - [comment @TODO See when and where GWT files are generated/] - [comment][genModel.moduleGwt()/][/comment] - - [if (genModel.hasModelPluginClass())] - [genModel.plugin()/] - [/if] - - [if (genModel.hasPluginSupport())] - [if (not genModel.sameModelEditProject() and not genModel.sameModelEditorProject())] - [if (genModel.bundleManifest and not genModel.fileExistsModel(genModel.manifestFilePath()))] - [genModel.manifest()/] - [/if] - - [if (not genModel.fileExistsModel(genModel.pluginXmlFilePath()))] - [genModel.pluginXml()/] - [/if] - [/if] - - [if (not genModel.fileExistsModel(genModel.pluginPropertiesFilePath()))] - [genModel.pluginProperties()/] - [/if] - - [if (not genModel.fileExistsModel(genModel.buildPropertiesFilePath()))] - [genModel.buildProperties()/] - [/if] - [/if] - - [for (p : GenPackage | genModel.eAllContents(GenPackage))] - [if (p.canGenerate())] - [p.prepareCache()/][comment Create helpers to cache and supply information for unique naming./] - - [for (genClass : GenClass | p.genClasses)] - [if (genClass.canGenerate())] - [if (not genClass.isExternalInterface() and (not genModel.suppressInterfaces or genClass.isInterface()))] - [genClass.genGenClass(true, false)/] - [/if] - [if (not genClass.isInterface())] - [genClass.genGenClass(if genModel.suppressInterfaces then true else false endif, true)/] - [/if] - [/if] - [/for] - [for (genEnum : GenEnum | p.genEnums)] - [if (genEnum.canGenerate())] - [genEnum.enumClass()/] - [/if] - [/for] - - [if (p.hasClassifiers())] - - [comment @TODO - if genModel.generateSchema -> generateSchema, - if p.loadingInitialization -> generateSerialization/] - - [if (not genModel.suppressEMFMetaData and not genModel.suppressInterfaces)] - [p.packageClass(true, false)/] - [/if] - - [p.packageClass(if genModel.suppressEMFMetaData or genModel.suppressInterfaces then true else false endif, true)/] - - [if (not genModel.suppressInterfaces)] - [p.factoryClass(true, false)/] - [/if] - - [p.factoryClass(if genModel.suppressInterfaces then true else false endif, true)/] - - [if (p.resource = GenResourceKind::XML)] - [p.xmlProcessorClass()/] - [/if] - - [if (p.hasConstraints())] - [p.validatorClass()/] - [/if] - - [if (p.adapterFactory and p.genClasses->notEmpty())] - [p.switchClass()/] - [p.adapterFactoryClass()/] - [/if] - [/if] - - [if (p.resource <> GenResourceKind::None)] - [p.resourceFactoryClass()/] - [p.resourceClass()/] - [/if] - - [p.clearCache()/] - [/if] - [/for] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/AdapterFactoryClass.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/AdapterFactoryClass.mtl deleted file mode 100644 index 1342193bc..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/AdapterFactoryClass.mtl +++ /dev/null @@ -1,180 +0,0 @@ -[comment encoding = UTF-8 /] -[module AdapterFactoryClass('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[template public adapterFactoryClass(genPackage : GenPackage)] -[let genModel : GenModel = genPackage.genModel] -[let packageName : String = genPackage.getUtilitiesPackageName()] -[let className :String = genPackage.getAdapterFactoryClassName()] -[genModel.initializeImportManager(packageName, className)/] -[genModel.addImport('org.eclipse.emf.common.notify.Adapter')/] -[genModel.addImport('org.eclipse.emf.common.notify.Notifier')/] -[genModel.addImport('org.eclipse.emf.common.notify.impl.AdapterFactoryImpl')/] -[genModel.addImport('org.eclipse.emf.ecore.EObject')/] -[if (not genPackage.hasJavaLangConflict() and genPackage.getUtilitiesPackageName() <> genPackage.getInterfacePackageName())][genModel.addImport(genPackage.getInterfacePackageName() + '.*')/][/if] - -[let typeArgument : String = if genModel.useGenerics() then '' else '' endif] -[let returnType : String = if genModel.useGenerics() then 'Adapter' else genModel.getImportedName('java.lang.Object') endif] -[let adapterCast : String = if genModel.useGenerics() then '' else '(Adapter)' endif] - - - -[file (adapterFactoryClassPath(genPackage), false, 'UTF-8')] -[genModel.includeHeader()/] -package [packageName/]; -[let content : String = genPackage.adapterFactoryFileContent(genModel, typeArgument, returnType, adapterCast)] -[genModel.genSortedImports()/] - -[content.trim()/] -[/let] -[/file] - - - -[/let] -[/let] -[/let] -[/let] -[/let] -[/let] -[/template] - -[template protected adapterFactoryFileContent(genPackage : GenPackage, genModel : GenModel, typeArgument : String, returnType : String, adapterCast : String) ] -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see [genPackage.getQualifiedPackageInterfaceName()/] - * @generated - */ -public class [genPackage.getAdapterFactoryClassName()/] extends AdapterFactoryImpl { -[if (genModel.hasCopyrightField()) ] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - /** - * The cached model package. - * - * - * @generated - */ - protected static [genPackage.getImportedPackageInterfaceName()/] modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public [genPackage.getAdapterFactoryClassName()/]() { - if (modelPackage == null) { - modelPackage = [genPackage.getImportedPackageInterfaceName()/].eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - [if genModel.useClassOverrideAnnotation() ] - @Override - [/if] - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject)object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected [genPackage.getSwitchClassName()/][typeArgument/] modelSwitch = - new [genPackage.getSwitchClassName()/][typeArgument/]() { -[for (genClass : GenClass | genPackage.getAllSwitchGenClasses()) ] - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public [genClass.getTypeParameters()/][returnType/] case[genPackage.getClassUniqueName(genClass)/]([genClass.getImportedInterfaceName()/][genClass.getInterfaceTypeArguments()/] object) { - return create[genPackage.getClassUniqueName(genClass)/]Adapter(); - } -[/for] - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public [returnType/] defaultCase(EObject object) { - return create[genPackage.getDefaultClassUniqueName()/]Adapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public Adapter createAdapter(Notifier target) { - return [adapterCast/]modelSwitch.doSwitch((EObject)target); - } - -[for (genClass : GenClass | genPackage.getAllSwitchGenClasses()) ] - - /** - * Creates a new adapter for an object of class '{@link [genClass.getQualifiedInterfaceName()/] [genClass.getFormattedName()/]}'. - * - * 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. - * - * @return the new adapter. - * @see [genClass.getQualifiedInterfaceName()/] - * @generated - */ - public Adapter create[genPackage.getClassUniqueName(genClass)/]Adapter() { - return null; - } -[/for] - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter create[genPackage.getDefaultClassUniqueName()/]Adapter() { - return null; - } - -} //[genPackage.getAdapterFactoryClassName()/] -[/template] - -[query public adapterFactoryClassPath(genPackage : GenPackage) : String - = genPackage.genModel.modelPath(genPackage.getUtilitiesPackageName().toPath(), genPackage.getAdapterFactoryClassName()) /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/Class.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/Class.mtl deleted file mode 100644 index d4158da48..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/Class.mtl +++ /dev/null @@ -1,962 +0,0 @@ -[comment encoding = UTF-8 /] -[module Class('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenOperation /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenParameter /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::model::genclass::genDeclaredFields /] -[import org::eclipse::emf::eef::codegen::ecore::model::genclass::genFeature /] -[import org::eclipse::emf::eef::codegen::ecore::model::genclass::genOperation /] -[import org::eclipse::emf::eef::codegen::ecore::model::genclass::eUnset /] -[import org::eclipse::emf::eef::codegen::ecore::model::genclass::eIsSet /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[template public genGenClass(genClass : GenClass, isInterface : Boolean, isImplementation : Boolean)] -[let genPackage : GenPackage = genClass.genPackage] -[let genModel : GenModel = genPackage.genModel] -[let isJDK50 : Boolean = genModel.isJDK50()] -[comment the two following booleans are passed as arguments to this template/] -[comment] final boolean isInterface = Boolean.TRUE.equals(((Object['[]'/])argument)[1]); final boolean isImplementation = Boolean.TRUE.equals(((Object['[]'/])argument)[2]);[/comment] -[let isGWT : Boolean = genModel.runtimePlatform = GenRuntimePlatform::GWT] -[let publicStaticFinalFlag : String = if isImplementation then 'public static final ' else '' endif] -[let singleWildcard : String = if isJDK50 then '' else '' endif] -[let negativeOffsetCorrection : String = if genClass.hasOffsetCorrection() then ' - ' + genClass.getDefaultOffsetCorrectionField(genClass) else '' endif] -[let positiveOffsetCorrection : String = if genClass.hasOffsetCorrection() then ' + ' + genClass.getDefaultOffsetCorrectionField(genClass) else '' endif] -[let negativeOperationOffsetCorrection : String = if genClass.hasOffsetCorrection() then ' - EOPERATION_OFFSET_CORRECTION' + genClass.getDefaultOffsetCorrectionField(genClass) else '' endif] -[let positiveOperationOffsetCorrection : String = if genClass.hasOffsetCorrection() then ' + EOPERATION_OFFSET_CORRECTION' + genClass.getDefaultOffsetCorrectionField(genClass) else '' endif] - -[let packageName : String = if (isInterface) then - genPackage.getInterfacePackageName() - else - genPackage.getClassPackageName() - endif] -[let className : String = if (isImplementation) then - genClass.getClassName() - else - genClass.getInterfaceName() - endif] - -[genModel.initializeImportManager(genPackage, packageName, className)/] -[if (isImplementation)] - [genClass.addClassPseudoImports()/] -[/if] - - - -[file (genClass.classFilePath(isInterface, isImplementation), false, 'UTF-8')] -[genClass.includeHeader()/] -[if (isInterface) ] -package [genPackage.getInterfacePackageName()/]; -[else] -package [genPackage.getClassPackageName()/]; -[/if] -[let content : String = genClass.classFileContent(isInterface, isImplementation, genPackage, genModel, isJDK50, isGWT, publicStaticFinalFlag, singleWildcard, negativeOffsetCorrection, positiveOffsetCorrection, negativeOperationOffsetCorrection, positiveOperationOffsetCorrection)] - -[genClass.genSortedImports(isInterface, isImplementation).trim()/] - -[content/] -[/let] -[/file] - - - -[/let] -[/let] - -[/let] -[/let] -[/let] -[/let] -[/let] -[/let] -[/let] -[/let] -[/let] -[/let] -[/template] - -[template protected classFileContent(genClass : GenClass, isInterface : Boolean, isImplementation : Boolean, genPackage : GenPackage, genModel : GenModel, isJDK50 : Boolean, isGWT : Boolean, publicStaticFinalFlag : String, singleWildcard : String, negativeOffsetCorrection : String, positiveOffsetCorrection : String, negativeOperationOffsetCorrection : String, positiveOperationOffsetCorrection : String) post(trim())] -[if (isInterface)] -/** - * - * A representation of the model object '[genClass.getFormattedName()/]'. - * - [if (genClass.hasDocumentation())] - * - * - * [genClass.getDocumentation(genModel.getIndentation())/] - * - [/if] - * - [if (not genClass.genFeatures->isEmpty())] - *

- * The following features are supported: - *

    - [for (genFeature : GenFeature | genClass.genFeatures)] - [if (not genFeature.isSuppressedGetVisibility())] - *
  • {@link [genClass.getQualifiedInterfaceName()/]#[genFeature.getGetAccessor()/] [genFeature.getFormattedName()/]}
  • - [/if] - [/for] - *
- *

- [/if] - * - [if (not genModel.suppressEMFMetaData)] - * @see [genPackage.getQualifiedPackageInterfaceName()/]#get[genClass.getClassifierAccessorName()/]() - [/if] - [if (not genModel.suppressEMFModelTags)] - [let modelInfoLines : Sequence(String) = genClass.getModelInfo().tokenize(genModel.getLineDelimiter() + '\r')] - [if (modelInfoLines->isEmpty())] - * @model - [else] - * @model [modelInfoLines->sep(genModel.getLineDelimiter() + ' * ')/] - [/if] - [/let] - [/if] - [if (genClass.needsRootExtendsInterfaceExtendsTag())] - * @extends [genModel.getImportedName(genModel.rootExtendsInterface)/] - [/if] - * @generated - */ -[else] -/** - * - * An implementation of the model object '[genClass.getFormattedName()/]'. - * - *

- [if (not genClass.getImplementedGenFeatures()->isEmpty())] - * The following features are implemented: - *

    - [for (genFeature : GenFeature | genClass.getImplementedGenFeatures())] - *
  • {@link [genClass.getQualifiedClassName()/]#[genFeature.getGetAccessor()/] [genFeature.getFormattedName()/]}
  • - [/for] - *
- [/if] - *

- * - * @generated - */ -[/if] -[if (isImplementation) ] -public[if (genClass.isAbstract()) ] abstract[/if] class [genClass.getClassName()/][genClass.getTypeParameters().trim()/][genClass.getClassExtends()/][genClass.getClassImplements()/] { -[else] -public interface [genClass.getInterfaceName()/][genClass.getTypeParameters().trim()/][genClass.getInterfaceExtends()/] { -[/if] -[if (genModel.hasCopyrightField()) ] - /** - * - * - * @generated - */ - [publicStaticFinalFlag/][genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] -[if (isImplementation and genModel.getDriverNumber() <> null) ] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] mofDriverNumber = "[genModel.getDriverNumber()/]";[genModel.getNonNLS()/] - -[/if] -[if (isImplementation and genClass.isJavaIOSerializable()) ] - /** - * - * - * @generated - */ - private static final long serialVersionUID = 1L; - -[/if] -[if (isImplementation and genModel.isVirtualDelegation())] - [let eVirtualValuesField : String = genClass.getEVirtualValuesField()] - [if (genClass.getEVirtualValuesField() <> null) ] - /** - * An array of objects representing the values of non-primitive features. - * - * - * @generated - */ - [if (isGWT) ] - @[genModel.getImportedName('com.google.gwt.user.client.rpc.GwtTransient')/] - [/if] - protected Object['[]'/] [genClass.getEVirtualValuesField()/]; - - [/if] - [let eVirtualIndexBitFields : Sequence(String) = genClass.getEVirtualIndexBitFields()] - [if (not eVirtualIndexBitFields->isEmpty()) ] - [for (eVirtualIndexBitField : String | eVirtualIndexBitFields)] - /** - * A bit field representing the indices of non-primitive feature values. - * - * - * @generated - */ - [if (isGWT) ] - @[genModel.getImportedName('com.google.gwt.user.client.rpc.GwtTransient')/] - [/if] - protected int [eVirtualIndexBitField/]; - - [/for] - [/if] - [/let] - [/let] -[/if] -[if (isImplementation and genClass.isModelRoot() and genModel.isBooleanFlagsEnabled() and genModel.booleanFlagsReservedBits = -1) ] - /** - * A set of bit flags representing the values of boolean attributes and whether unsettable features have been set. - * - * - * @generated - * @ordered - */ - [if (isGWT) ] - @[genModel.getImportedName('com.google.gwt.user.client.rpc.GwtTransient')/] - [/if] - protected int [genModel.booleanFlagsField/] = 0; - -[/if] -[if (isImplementation and not genModel.reflectiveDelegation) ] - [for (genFeature : GenFeature | genClass.getDeclaredFieldGenFeatures())] -[genFeature.genDeclaredFields(genClass, genModel, isGWT, isJDK50)/][/for] -[/if] -[if (isImplementation and genClass.hasOffsetCorrection() and not genClass.getImplementedGenFeatures()->isEmpty()) ] - /** - * - * - * @generated - */ - private static final int [genClass.getDefaultOffsetCorrectionField()/] = [genClass.getQualifiedClassifierAccessor()/].getFeatureID([genClass.getImplementedGenFeatures()->at(1).oclAsType(GenFeature).getQualifiedFeatureAccessor()/]) - [genClass.getQualifiedFeatureID(genClass.getImplementedGenFeatures()->at(1).oclAsType(GenFeature))/]; - -[/if] -[if (isImplementation and not genModel.reflectiveDelegation) ] - [for (genFeature : GenFeature | genClass.getImplementedGenFeatures())] - [let reverseFeature : GenFeature = genFeature.getReverse()] - [if (reverseFeature <> null and reverseFeature.genClass.hasOffsetCorrection()) ] - /** - * - * - * @generated - */ - private static final int [genClass.getOffsetCorrectionField(genFeature)/] = [reverseFeature.genClass.getQualifiedClassifierAccessor()/].getFeatureID([reverseFeature.getQualifiedFeatureAccessor()/]) - [reverseFeature.genClass.getQualifiedFeatureID(reverseFeature)/]; - - [/if] - [/let] - [/for] -[/if] -[if (genModel.operationReflection and isImplementation and genClass.hasOffsetCorrection() and not genClass.getImplementedGenOperations()->isEmpty()) ] - /** - * - * - * @generated - */ - private static final int "EOPERATION_OFFSET_CORRECTION" = [genClass.getQualifiedClassifierAccessor()/].getOperationID([genClass.getImplementedGenOperations()->at(1).oclAsType(GenOperation).getQualifiedOperationAccessor()/]) - [genClass.getQualifiedOperationID(genClass.getImplementedGenOperations()->at(1).oclAsType(GenOperation))/]; - -[/if] -[if (isImplementation) ] - /** - * - * - * @generated - */ - [if (genModel.publicConstructors) ]public[else]protected[/if] [genClass.getClassName()/]() { - super(); - [for (genFeature : GenFeature | genClass.getFlagGenFeaturesWithDefault()) ] - [genClass.getFlagsField(genFeature)/] |= [genFeature.getUpperName()/]_EFLAG[if (not genFeature.isBooleanType()) ]_DEFAULT[/if]; - [/for] - } - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - protected [genModel.getImportedName('org.eclipse.emf.ecore.EClass')/] eStaticClass() { - return [genClass.getQualifiedClassifierAccessor()/]; - } - -[/if] -[for (genFeature : GenFeature | if isImplementation then genClass.getImplementedGenFeatures() else genClass.getDeclaredGenFeatures() endif)] -[genFeature.genFeature(genClass, genPackage, genModel, isJDK50, isInterface, isImplementation, positiveOffsetCorrection, negativeOffsetCorrection, singleWildcard)/][/for] -[for (genOperation : GenOperation | if isImplementation then genClass.getImplementedGenOperations() else genClass.getDeclaredGenOperations() endif)] -[genOperation.genOperation(genClass, genPackage, genModel, isJDK50, isInterface, isImplementation, isGWT)/][/for] -[if (isImplementation and not genModel.reflectiveDelegation and genClass.implementsAnyEInverseAddGenFeatures()) ] - /** - * - * - * @generated - */ - [if (genModel.useGenerics())] - [if (genClass.getEInverseAddGenFeatures()->filter(GenFeature)->select(f : GenFeature | f.isUncheckedCast(genClass))->size() > 0)] - @SuppressWarnings("unchecked") - [/if] - [/if] - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] eInverseAdd([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/] otherEnd, int featureID, [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] msgs) { - switch (featureID[negativeOffsetCorrection/]) { -[for (genFeature : GenFeature | genClass.getEInverseAddGenFeatures())] - case [genClass.getQualifiedFeatureID(genFeature)/]: - [if (genFeature.isListType())] - [let cast : String = '(' - + genModel.getImportedName('org.eclipse.emf.ecore.util.InternalEList') - + if (not genModel.useGenerics()) then - ')' - else - '<' - + genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject') - + '>)(' - + genModel.getImportedName('org.eclipse.emf.ecore.util.InternalEList') - + ')' - endif] - [if (genFeature.isMapType() and genFeature.isEffectiveSuppressEMFTypes()) ] - return (([cast/]([genModel.getImportedName('org.eclipse.emf.common.util.EMap')/].InternalMapView[genFeature.getImportedMapTemplateArguments(genClass)/])[genFeature.getGetAccessor()/]()).eMap()).basicAdd(otherEnd, msgs); - [else] - return ([cast/][genFeature.getGetAccessor()/]()).basicAdd(otherEnd, msgs); - [/if] - [/let] - [else][if (genFeature.isContainer()) ] - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - [if (genFeature.isBasicSet()) ] - return basicSet[genFeature.getAccessorName()/](([genFeature.getImportedType(genClass)/])otherEnd, msgs); - [else] - return eBasicSetContainer(otherEnd, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], msgs); - [/if] - [else] - [if (genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [else][if (genFeature.isVolatile() or genClass.getImplementingGenModel(genFeature).isDynamicDelegation()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = [if (genFeature.isResolveProxies()) ]basicGet[genFeature.getAccessorName()/][else][genFeature.getGetAccessor()/][/if](); - [/if][/if] - if ([genFeature.getSafeName()/] != null) - [if (genFeature.isEffectiveContains()) ] - msgs = (([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])[genFeature.getSafeName()/]).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - [genClass.getQualifiedFeatureID(genFeature)/][negativeOffsetCorrection/], null, msgs); - [else] - [let reverseFeature : GenFeature = genFeature.getReverse()] - [let targetClass : GenClass = reverseFeature.genClass] - [let reverseOffsetCorrection : String = if (targetClass.hasOffsetCorrection()) then ' + ' + genClass.getOffsetCorrectionField(genFeature) else '' endif] - msgs = (([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])[genFeature.getSafeName()/]).eInverseRemove(this, [targetClass.getQualifiedFeatureID(reverseFeature)/][reverseOffsetCorrection/], [targetClass.getRawImportedInterfaceName()/].class, msgs); - [/let] - [/let] - [/let] - [/if] - return basicSet[genFeature.getAccessorName()/](([genFeature.getImportedType(genClass)/])otherEnd, msgs); - [/if][/if] -[/for] - } -[if (genModel.minimalReflectiveMethods) ] - return super.eInverseAdd(otherEnd, featureID, msgs); -[else] - return eDynamicInverseAdd(otherEnd, featureID, msgs); -[/if] - } - -[/if] -[if (isImplementation and not genModel.reflectiveDelegation and genClass.implementsAnyEInverseRemoveGenFeatures()) ] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] eInverseRemove([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/] otherEnd, int featureID, [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] msgs) { - switch (featureID[negativeOffsetCorrection/]) { -[for (genFeature : GenFeature | genClass.getEInverseRemoveGenFeatures())] - case [genClass.getQualifiedFeatureID(genFeature)/]: - [if (genFeature.isListType()) ] - [if (genFeature.isMapType() and genFeature.isEffectiveSuppressEMFTypes()) ] - return (([genModel.getImportedName('org.eclipse.emf.ecore.util.InternalEList')/][singleWildcard/])(([genModel.getImportedName('org.eclipse.emf.common.util.EMap')/].InternalMapView[genFeature.getImportedMapTemplateArguments(genClass)/])[genFeature.getGetAccessor()/]()).eMap()).basicRemove(otherEnd, msgs); - [else][if (genFeature.isWrappedFeatureMapType()) ] - return (([genModel.getImportedName('org.eclipse.emf.ecore.util.InternalEList')/][singleWildcard/])(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)[genFeature.getGetAccessor()/]()).featureMap()).basicRemove(otherEnd, msgs); - [else] - return (([genModel.getImportedName('org.eclipse.emf.ecore.util.InternalEList')/][singleWildcard/])[genFeature.getGetAccessor()/]()).basicRemove(otherEnd, msgs); - [/if][/if] - [else ][if (genFeature.isContainer() and not genFeature.isBasicSet()) ] - return eBasicSetContainer(null, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], msgs); - [else][if (genFeature.isUnsettable()) ] - return basicUnset[genFeature.getAccessorName()/](msgs); - [else] - return basicSet[genFeature.getAccessorName()/](null, msgs); - [/if][/if][/if] -[/for] - } -[if (genModel.minimalReflectiveMethods) ] - return super.eInverseRemove(otherEnd, featureID, msgs); -[else] - return eDynamicInverseRemove(otherEnd, featureID, msgs); -[/if] - } - -[/if] -[if (isImplementation and not genModel.reflectiveDelegation and genClass.implementsAnyEBasicRemoveFromContainerGenFeatures()) ] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] eBasicRemoveFromContainerFeature([genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] msgs) { - switch (eContainerFeatureID()[negativeOffsetCorrection/]) { -[for (genFeature : GenFeature | genClass.getEBasicRemoveFromContainerGenFeatures())] - [let reverseFeature : GenFeature = genFeature.getReverse()] - [let targetClass : GenClass = reverseFeature.genClass] - [let reverseOffsetCorrection : String = if (targetClass.hasOffsetCorrection()) then ' + ' + genClass.getOffsetCorrectionField(genFeature) else '' endif] - case [genClass.getQualifiedFeatureID(genFeature)/]: - return eInternalContainer().eInverseRemove(this, [targetClass.getQualifiedFeatureID(reverseFeature)/][reverseOffsetCorrection/], [targetClass.getRawImportedInterfaceName()/].class, msgs); - [/let] - [/let] - [/let] -[/for] - } -[if (genModel.minimalReflectiveMethods) ] - return super.eBasicRemoveFromContainerFeature(msgs); -[else] - return eDynamicBasicRemoveFromContainer(msgs); -[/if] - } - -[/if] -[if (isImplementation and not genModel.reflectiveDelegation and genClass.implementsAnyEGetGenFeatures()) ] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID[negativeOffsetCorrection/]) { -[for (genFeature : GenFeature | genClass.getEGetGenFeatures())] - case [genClass.getQualifiedFeatureID(genFeature)/]: - [if (genFeature.isPrimitiveType()) ] - [if (isJDK50) ] - return [genFeature.getGetAccessor()/](); - [else][if (genFeature.isBooleanType()) ] - return [genFeature.getGetAccessor()/]() ? Boolean.TRUE : Boolean.FALSE; - [else] - return new [genFeature.getObjectType(genClass)/]([genFeature.getGetAccessor()/]()); - [/if][/if] - [else][if (genFeature.isResolveProxies() and not genFeature.isListType()) ] - if (resolve) return [genFeature.getGetAccessor()/](); - return basicGet[genFeature.getAccessorName()/](); - [else][if (genFeature.isMapType()) ] - [if (genFeature.isEffectiveSuppressEMFTypes()) ] - if (coreType) return (([genModel.getImportedName('org.eclipse.emf.common.util.EMap')/].InternalMapView[genFeature.getImportedMapTemplateArguments(genClass)/])[genFeature.getGetAccessor()/]()).eMap(); - else return [genFeature.getGetAccessor()/](); - [else] - if (coreType) return [genFeature.getGetAccessor()/](); - else return [genFeature.getGetAccessor()/]().map(); - [/if] - [else][if (genFeature.isWrappedFeatureMapType()) ] - if (coreType) return (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)[genFeature.getGetAccessor()/]()).featureMap(); - return [genFeature.getGetAccessor()/](); - [else][if (genFeature.isFeatureMapType()) ] - if (coreType) return [genFeature.getGetAccessor()/](); - return (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)[genFeature.getGetAccessor()/]()).getWrapper(); - [else] - return [genFeature.getGetAccessor()/](); - [/if][/if][/if][/if][/if] -[/for] - } -[if (genModel.minimalReflectiveMethods) ] - return super.eGet(featureID, resolve, coreType); -[else] - return eDynamicGet(featureID, resolve, coreType); -[/if] - } - -[/if] -[if (isImplementation and not genModel.reflectiveDelegation and genClass.implementsAnyESetGenFeatures()) ] - /** - * - * - * @generated - */ - [if (genModel.useGenerics()) ] - [if (genClass.getESetGenFeatures()->filter(GenFeature)->select(f : GenFeature| f.isUncheckedCast(genClass) and not f.isFeatureMapType() and not f.isMapType())->notEmpty()) ] - @SuppressWarnings("unchecked") - [/if] - [/if] - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public void eSet(int featureID, Object newValue) { - switch (featureID[negativeOffsetCorrection/]) { - [for (genFeature : GenFeature | genClass.getESetGenFeatures())] - case [genClass.getQualifiedFeatureID(genFeature)/]: - [if (genFeature.isListType()) ] - [if (genFeature.isWrappedFeatureMapType()) ] - (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)[genFeature.getGetAccessor()/]()).featureMap()).set(newValue); - [else][if (genFeature.isFeatureMapType()) ] - (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)[genFeature.getGetAccessor()/]()).set(newValue); - [else][if (genFeature.isMapType()) ] - [if (genFeature.isEffectiveSuppressEMFTypes()) ] - (([genModel.getImportedName('org.eclipse.emf.ecore.EStructuralFeature')/].Setting)(([genModel.getImportedName('org.eclipse.emf.common.util.EMap')/].InternalMapView[genFeature.getImportedMapTemplateArguments(genClass)/])[genFeature.getGetAccessor()/]()).eMap()).set(newValue); - [else] - (([genModel.getImportedName('org.eclipse.emf.ecore.EStructuralFeature')/].Setting)[genFeature.getGetAccessor()/]()).set(newValue); - [/if] - [else] - [genFeature.getGetAccessor()/]().clear(); - [genFeature.getGetAccessor()/]().addAll(([genModel.getImportedName('java.util.Collection')/][if (isJDK50) ][/if])newValue); - [/if][/if][/if] - [else][if (not isJDK50 and genFeature.isPrimitiveType()) ] - set[genFeature.getAccessorName()/]((([genFeature.getObjectType(genClass)/])newValue).[genFeature.getPrimitiveValueFunction()/]()); - [else] - set[genFeature.getAccessorName()/]([if (genFeature.getTypeGenDataType() = null or not genFeature.getTypeGenDataType().isObjectType() or genFeature.getRawType() <> genFeature.getType(genClass)) ]([genFeature.getObjectType(genClass)/])[/if]newValue); - [/if][/if] - return; - [/for] - } - [if (genModel.minimalReflectiveMethods) ] - super.eSet(featureID, newValue); - [else] - eDynamicSet(featureID, newValue); - [/if] - } - -[/if] -[if (isImplementation and not genModel.reflectiveDelegation and genClass.implementsAnyEUnsetGenFeatures()) ] -[genClass.eUnset(genModel, negativeOffsetCorrection)/] -[/if] -[if (isImplementation and not genModel.reflectiveDelegation and genClass.implementsAnyEIsSetGenFeatures()) ] -[genClass.eIsSet(genModel, positiveOffsetCorrection, negativeOffsetCorrection)/] -[/if] -[if (isImplementation and (not genClass.getMixinGenFeatures()->isEmpty() or genClass.hasOffsetCorrection() and not genClass.genFeatures->isEmpty())) ] - [if (not genClass.getMixinGenFeatures()->isEmpty()) ] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public int eBaseStructuralFeatureID(int derivedFeatureID, Class[singleWildcard/] baseClass) { - [for (mixinGenClass : GenClass | genClass.getMixinGenClasses())] - if (baseClass == [mixinGenClass.getRawImportedInterfaceName()/].class) { - switch (derivedFeatureID[negativeOffsetCorrection/]) { - [for (genFeature : GenFeature | mixinGenClass.genFeatures)] - case [genClass.getQualifiedFeatureID(genFeature)/]: return [mixinGenClass.getQualifiedFeatureID(genFeature)/]; - [/for] - default: return -1; - } - } - [/for] - return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); - } - [/if] - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public int eDerivedStructuralFeatureID(int baseFeatureID, Class[singleWildcard/] baseClass) { - [for (mixinGenClass : GenClass | genClass.getMixinGenClasses())] - if (baseClass == [mixinGenClass.getRawImportedInterfaceName()/].class) { - switch (baseFeatureID) { - [for (genFeature : GenFeature | mixinGenClass.genFeatures)] - case [mixinGenClass.getQualifiedFeatureID(genFeature)/]: return [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]; - [/for] - default: return -1; - } - } - [/for] - [if (genClass.hasOffsetCorrection() and not genClass.genFeatures->isEmpty()) ] - if (baseClass == [genClass.getRawImportedInterfaceName()/].class) { - switch (baseFeatureID[negativeOffsetCorrection/]) { - [for (genFeature : GenFeature | genClass.genFeatures)] - case [genClass.getQualifiedFeatureID(genFeature)/]: return [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]; - [/for] - default: return -1; - } - } - [/if] - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - -[/if] -[if (genModel.operationReflection - and isImplementation - and (not genClass.getMixinGenOperations()->isEmpty() - or not genClass.overridesGenOperations() - or genClass.hasOffsetCorrection() and not genClass.genOperations->isEmpty()))] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public int eDerivedOperationID(int baseOperationID, Class[singleWildcard/] baseClass) { - [for (extendedGenClass : GenClass | genClass.getExtendedGenClasses())] - [let extendedImplementedGenOperations : Sequence(GenOperation) = extendedGenClass.getImplementedGenOperations()] - [let implementedGenOperations : Sequence(GenOperation) = genClass.getImplementedGenOperations()] - [if (not genClass.overridesExtendedGenOperations(extendedGenClass)) ] - if (baseClass == [extendedGenClass.getRawImportedInterfaceName()/].class) { - switch (baseOperationID) { - [for (genOperation : GenOperation | extendedImplementedGenOperations)] - [let overrideGenOperation : GenOperation = genClass.getOverrideGenOperation(genOperation)] - [if (implementedGenOperations->includes(overrideGenOperation)) ] - case [extendedGenClass.getQualifiedOperationID(genOperation)/]: return [genClass.getQualifiedOperationID(overrideGenOperation)/][positiveOperationOffsetCorrection/]; - [/if] - [/let] - [/for] - default: return super.eDerivedOperationID(baseOperationID, baseClass); - } - } - [/if] - [/let] - [/let] - [/for] - [for (mixinGenClass : GenClass | genClass.getMixinGenClasses())] - if (baseClass == [mixinGenClass.getRawImportedInterfaceName()/].class) { - switch (baseOperationID) { - [for (genOperation : GenOperation | mixinGenClass.genOperations)] - [let overrideGenOperation : GenOperation = genClass.getOverrideGenOperation(genOperation)] - case [mixinGenClass.getQualifiedOperationID(genOperation)/]: return [genClass.getQualifiedOperationID(if (overrideGenOperation <> null) then overrideGenOperation else genOperation endif)/][positiveOperationOffsetCorrection/]; - [/let] - [/for] - default: return -1; - } - } - [/for] - [if (genClass.hasOffsetCorrection() and not genClass.genOperations->isEmpty()) ] - if (baseClass == [genClass.getRawImportedInterfaceName()/].class) { - switch (baseOperationID[negativeOperationOffsetCorrection/]) { - [for (genOperation : GenOperation | genClass.genOperations)] - case [genClass.getQualifiedOperationID(genOperation)/]: return [genClass.getQualifiedOperationID(genOperation)/][positiveOperationOffsetCorrection/]; - [/for] - default: return -1; - } - } - [/if] - return super.eDerivedOperationID(baseOperationID, baseClass); - } - -[/if] -[if (isImplementation and genModel.isVirtualDelegation())] - [comment][let eVirtualValuesField : String = genClass.getEVirtualValuesField()][/comment] - [if (genClass.getEVirtualValuesField() <> null) ] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - protected Object['[]'/] eVirtualValues() { - return [genClass.getEVirtualValuesField()/]; - } - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - protected void eSetVirtualValues(Object['[]'/] newValues) { - [genClass.getEVirtualValuesField()/] = newValues; - } - - [/if] - [let eVirtualIndexBitFields : Sequence(String) = genClass.getEVirtualIndexBitFields()] - [if (not eVirtualIndexBitFields->isEmpty())] - [let allEVirtualIndexBitFields : Sequence(String) = genClass.getAllEVirtualIndexBitFields()] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - protected int eVirtualIndexBits(int offset) { - switch (offset) { - [for (field : String | allEVirtualIndexBitFields)] - case [i - 1/] : - return [field/]; - [/for] - default : - throw new IndexOutOfBoundsException(); - } - } - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - protected void eSetVirtualIndexBits(int offset, int newIndexBits) { - switch (offset) { - [for (field : String | allEVirtualIndexBitFields)] - case [i - 1/] : - [field/] = newIndexBits; - break; - [/for] - default : - throw new IndexOutOfBoundsException(); - } - } - - [/let] - [/if] - [/let] - [comment][/let][/comment] -[/if] -[if (genModel.operationReflection and isImplementation and not genClass.getImplementedGenOperations()->isEmpty()) ] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - [let genOpList : Sequence(GenOperation) = if (genModel.minimalReflectiveMethods) then genClass.getImplementedGenOperations() else genClass.getAllGenOperations() endif] - [if (genOpList.genParameters - ->flatten() - ->filter(GenParameter) - ->select(genParameter : GenParameter | genParameter.isUncheckedCast()) - ->notEmpty())] - @SuppressWarnings("unchecked") - [/if] - public Object eInvoke(int operationID, [genModel.getImportedName('org.eclipse.emf.common.util.EList')/][singleWildcard/] arguments) throws [genModel.getImportedName(if (isGWT) then 'org.eclipse.emf.common.util.InvocationTargetException' else 'java.lang.reflect.InvocationTargetException' endif)/] { - switch (operationID[negativeOperationOffsetCorrection/]) { -[for (genOperation : GenOperation | genOpList)] - [let genParameters : OrderedSet(GenParameter) = genOperation.genParameters] - [let size : Integer = genParameters->size()] - case [genClass.getQualifiedOperationID(genOperation)/]: - [if (genOperation.isVoid()) ] - [genOperation.getName()/]([for (genParameter : GenParameter | genParameters)][if (not isJDK50 and genParameter.isPrimitiveType()) ]([/if][if (genParameter.getTypeGenDataType() = null or not genParameter.getTypeGenDataType().isObjectType() or genParameter.getRawType() <> genParameter.getType(genClass)) ]([genParameter.getObjectType(genClass)/])[/if]arguments.get([i/])[if (not isJDK50 and genParameter.isPrimitiveType()) ]).[genParameter.getPrimitiveValueFunction()/]()[/if][if (i < (size - 1)) ], [/if][/for]); - return null; - [else] - return [if (not isJDK50 and genOperation.isPrimitiveType())]new [genOperation.getObjectType(genClass)/]([/if][genOperation.getName()/]([for (genParameter : GenParameter | genParameters)][if (not isJDK50 and genParameter.isPrimitiveType())]([/if][if (genParameter.getTypeGenDataType() = null or not genParameter.getTypeGenDataType().isObjectType() or genParameter.getRawType() <> genParameter.getType(genClass)) ]([genParameter.getObjectType(genClass)/])[/if]arguments.get([i - 1/])[if (not isJDK50 and genParameter.isPrimitiveType()) ]).[genParameter.getPrimitiveValueFunction()/]()[/if][if (i < size) ], [/if][/for])[if (not isJDK50 and genOperation.isPrimitiveType()) ])[/if]; - [/if] - [/let] - [/let] -[/for] - [/let] - } -[if (genModel.minimalReflectiveMethods) ] - return super.eInvoke(operationID, arguments); -[else] - return eDynamicInvoke(operationID, arguments); -[/if] - } - -[/if] -[if (not genClass.hasImplementedToStringGenOperation() and isImplementation and not genModel.reflectiveDelegation and not genModel.isDynamicDelegation() and not genClass.getToStringGenFeatures()->isEmpty()) ] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - [for (genFeature : GenFeature | genClass.getToStringGenFeatures())] - [if (i = 1)] - result.append(" ([genFeature.getName()/]: ");[genModel.getNonNLS()/] - [else] - result.append(", [genFeature.getName()/]: ");[genModel.getNonNLS()/] - [/if] - [if (genFeature.isUnsettable() and not genFeature.isListType()) ] - [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ] - if (eVirtualIsSet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/])) result.append(eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/])); else result.append("");[genModel.getNonNLS()/] - [else] - [if (genClass.isFlag(genFeature)) ] - [if (genFeature.isBooleanType()) ] - if ([if (genClass.isESetFlag(genFeature)) ]([genClass.getESetFlagsField(genFeature)/] & [genFeature.getUpperName()/]_ESETFLAG) != 0[else][genFeature.getUncapName()/]ESet[/if]) result.append(([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) != 0); else result.append("");[genModel.getNonNLS()/] - [else] - if ([if (genClass.isESetFlag(genFeature)) ]([genClass.getESetFlagsField(genFeature)/] & [genFeature.getUpperName()/]_ESETFLAG) != 0[else][genFeature.getUncapName()/]ESet[/if]) result.append([genFeature.getUpperName()/]_EFLAG_VALUES['['/]([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) >>> [genFeature.getUpperName()/]_EFLAG_OFFSET]); else result.append("");[genModel.getNonNLS()/] - [/if] - [else] - if ([if (genClass.isESetFlag(genFeature)) ]([genClass.getESetFlagsField(genFeature)/] & [genFeature.getUpperName()/]_ESETFLAG) != 0[else][genFeature.getUncapName()/]ESet[/if]) result.append([genFeature.getSafeName()/]); else result.append("");[genModel.getNonNLS()/] - [/if] - [/if] - [else] - [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ] - result.append(eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/][if (not genFeature.isListType() and not genFeature.isReferenceType())], [genFeature.getEDefault()/][/if])); - [else] - [if (genClass.isFlag(genFeature)) ] - [if (genFeature.isBooleanType()) ] - result.append(([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) != 0); - [else] - result.append([genFeature.getUpperName()/]_EFLAG_VALUES['['/]([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) >>> [genFeature.getUpperName()/]_EFLAG_OFFSET]); - [/if] - [else] - result.append([genFeature.getSafeName()/]); - [/if] - [/if] - [/if] - [/for] - result.append(')'); - return result.toString(); - } - -[/if] -[if (isImplementation and genClass.isMapEntry())] -[let keyFeature : GenFeature = genClass.getMapEntryKeyFeature()] -[let valueFeature : GenFeature = genClass.getMapEntryValueFeature()] -[let objectType : String = genModel.getImportedName('java.lang.Object')] -[let keyType : String = if isJDK50 then keyFeature.getObjectType(genClass) else objectType endif] -[let valueType : String = if isJDK50 then valueFeature.getObjectType(genClass) else objectType endif] -[let eMapType : String = genModel.getImportedName('org.eclipse.emf.common.util.EMap') + (if isJDK50 then '<' + keyType + ', ' + valueType + '>' else '' endif)] - /** - * - * - * @generated - */ - [if (isGWT) ] - @[genModel.getImportedName('com.google.gwt.user.client.rpc.GwtTransient')/] - [/if] - protected int hash = -1; - - /** - * - * - * @generated - */ - public int getHash() { - if (hash == -1) { - [objectType/] theKey = getKey(); - hash = (theKey == null ? 0 : theKey.hashCode()); - } - return hash; - } - - /** - * - * - * @generated - */ - public void setHash(int hash) { - this.hash = hash; - } - - /** - * - * - * @generated - */ - public [keyType/] getKey() { - [if (not isJDK50 and keyFeature.isPrimitiveType()) ] - return new [keyFeature.getObjectType(genClass)/](getTypedKey()); - [else] - return getTypedKey(); - [/if] - } - - /** - * - * - * @generated - */ - public void setKey([keyType/] key) { - [if (keyFeature.isListType()) ] - getTypedKey().addAll([if (not genModel.useGenerics()) ]([genModel.getImportedName('java.util.Collection')/])[/if]key); - [else][if (isJDK50)] - setTypedKey(key); - [else][if (keyFeature.isPrimitiveType())] - setTypedKey((([keyFeature.getObjectType(genClass)/])key).[keyFeature.getPrimitiveValueFunction()/]()); - [else] - setTypedKey(([keyFeature.getImportedType(genClass)/])key); - [/if][/if][/if] - } - - /** - * - * - * @generated - */ - public [valueType/] getValue() { - [if (not isJDK50 and valueFeature.isPrimitiveType()) ] - return new [valueFeature.getObjectType(genClass)/](getTypedValue()); - [else] - return getTypedValue(); - [/if] - } - - /** - * - * - * @generated - */ - public [valueType/] setValue([valueType/] value) { - [valueType/] oldValue = getValue(); - [if (valueFeature.isListType()) ] - getTypedValue().clear(); - getTypedValue().addAll([if (not genModel.useGenerics()) ]([genModel.getImportedName('java.util.Collection')/])[/if]value); - [else][if (isJDK50)] - setTypedValue(value); - [else][if (valueFeature.isPrimitiveType()) ] - setTypedValue((([valueFeature.getObjectType(genClass)/])value).[valueFeature.getPrimitiveValueFunction()/]()); - [else] - setTypedValue(([valueFeature.getImportedType(genClass)/])value); - [/if][/if][/if] - return oldValue; - } - - /** - * - * - * @generated - */ - [if (genModel.useGenerics()) ] - @SuppressWarnings("unchecked") - [/if] - public [eMapType/] getEMap() { - [genModel.getImportedName('org.eclipse.emf.ecore.EObject')/] container = eContainer(); - return container == null ? null : ([eMapType/])container.eGet(eContainmentFeature()); - } - -[/let] -[/let] -[/let] -[/let] -[/let] -[/let] -[/if] -} //[if (isInterface)] [genClass.getInterfaceName()/][else][genClass.getClassName()/][/if] -[/template] - -[query public classFilePath(genClass : GenClass, isInterface : Boolean, isImplementation : Boolean) : String - = genClass.getGenModel().extractSourceDirectory(genClass.getGenModel().modelDirectory) + '/' + - if isInterface then - genClass.getQualifiedInterfaceName().toPath() - else - genClass.getQualifiedClassName().toPath() - endif + - '.java' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/EnumClass.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/EnumClass.mtl deleted file mode 100644 index acdbd4b8a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/EnumClass.mtl +++ /dev/null @@ -1,343 +0,0 @@ -[comment encoding = UTF-8 /] -[module EnumClass('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnumLiteral /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[template public enumClass(genEnum : GenEnum)] -[comment -/** - * - * - * Copyright (c) 2002-2007 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -/] -[let genPackage : GenPackage = genEnum.genPackage] -[let genModel : GenModel = genPackage.genModel] -[let packageName : String = genPackage.getInterfacePackageName()] -[let enumName : String = genEnum.getName()] - -[genModel.initializeImportManager(genPackage, packageName, enumName)/] -[genModel.addImport('java.util.Arrays')/] -[genModel.addImport('java.util.List')/] -[genModel.addImport('java.util.Collections')/] - - - -[file (genEnum.enumFilePath(), false, 'UTF-8')] -[genModel.includeHeader()/] -package [packageName/]; -[let content : String = genEnum.enumFileContent(genModel, genPackage)] -[genModel.genSortedImports()/] -[content/][/let] -[/file] - - - -[/let][comment enumName /] -[/let][comment packageName /] -[/let][comment genModel /] -[/let][comment genPackage /] -[/template] - -[template protected enumFileContent(genEnum : GenEnum, genModel : GenModel, genPackage : GenPackage) ] -[let isEnum : Boolean = genModel.useGenerics()] -/** - * - * A representation of the literals of the enumeration '[genEnum.getFormattedName()/]', - * and utility methods for working with them. - * -[if (genEnum.hasDocumentation())] - * - * [genEnum.getDocumentation(genModel.getIndentation())/] - * -[/if] - * @see [genPackage.getQualifiedPackageInterfaceName()/]#get[genEnum.getName()/]() - [if (not genModel.suppressEMFModelTags)] - [let modelInfoLines : Sequence(String) = genEnum.getModelInfo().tokenize(genModel.getLineDelimiter() + '\r')] - [if (modelInfoLines->isEmpty())] - * @model - [else] - * @model [modelInfoLines->sep(genModel.getLineDelimiter() + ' * ')/] - [/if] - [/let] - [/if] - * @generated - */ -public [if (isEnum)]enum[else]final class[/if] [genEnum.getName()/] [if (isEnum)]implements[else]extends[/if] [if (genModel.suppressEMFMetaData and not genModel.suppressInterfaces)]Internal[genEnum.getName()/][else][genModel.getImportedName(if (isEnum) then 'org.eclipse.emf.common.util.Enumerator' else 'org.eclipse.emf.common.util.AbstractEnumerator' endif)/][/if] { -[if (isEnum)] - [if (genEnum.genEnumLiterals->isEmpty())] - ; - - [else] -[genEnum.genEnumLiterals.genEnumLiteralTemplate(genModel)->sep(',' + genModel.getNonNLS() + genModel.getNonNLS(2) + genModel.getLineDelimiter() + genModel.getLineDelimiter())/];[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - - [/if] -[/if] -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] -[for (genEnumLiteral : GenEnumLiteral | genEnum.genEnumLiterals)] - /** - * The '[genEnumLiteral.getFormattedName()/]' literal value. - * -[if (not genEnumLiteral.hasDocumentation())] - *

- * If the meaning of '[genEnumLiteral.getFormattedName()/]' literal object isn't clear, - * there really should be more of a description here... - *

-[/if] - * -[if (genEnumLiteral.hasDocumentation())] - * - * [genEnumLiteral.getDocumentation(genModel.getIndentation())/] - * -[/if] - * @see #[genEnumLiteral.getEnumLiteralInstanceConstantName()/] - [if (not genModel.suppressEMFModelTags)] - [let modelInfoLines : Sequence(String) = genEnumLiteral.getModelInfo().tokenize(genModel.getLineDelimiter() + '\r')] - [if (modelInfoLines->isEmpty())] - * @model - [else] - * @model [modelInfoLines->sep(genModel.getLineDelimiter() + '\t * ')/] - [/if] - [/let] - [/if] - * @generated - * @ordered - */ - public static final int [genEnumLiteral.getEnumLiteralValueConstantName()/] = [genEnumLiteral.getValue()/]; - -[/for] -[if (not isEnum)] - [for (genEnumLiteral : GenEnumLiteral | genEnum.genEnumLiterals)] - /** - * The '[genEnumLiteral.getFormattedName()/]' literal object. - * - * - * @see #[genEnumLiteral.getEnumLiteralValueConstantName()/] - * @generated - * @ordered - */ - public static final [genEnum.getName()/] [genEnumLiteral.getEnumLiteralInstanceConstantName()/] = new [genEnum.getName()/]([genEnumLiteral.getEnumLiteralValueConstantName()/], "[genEnumLiteral.getName()/]", [genModel.toStringLiteral(genEnumLiteral.getLiteral())/]);[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - - [/for] -[/if] - /** - * An array of all the '[genEnum.getFormattedName()/]' enumerators. - * - * - * @generated - */ - private static final [genEnum.getName()/]['[]'/] VALUES_ARRAY = - new [genEnum.getName()/]['[]'/] { -[for (genEnumLiteral : GenEnumLiteral | genEnum.genEnumLiterals)] - [genEnumLiteral.getEnumLiteralInstanceConstantName()/], -[/for] - }; - - /** - * A public read-only list of all the '[genEnum.getFormattedName()/]' enumerators. - * - * - * @generated - */ - public static final List[if (isEnum)]<[genEnum.getName()/]>[/if] VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the '[genEnum.getFormattedName()/]' literal with the specified literal value. - * - * - * @generated - */ - public static [genEnum.getName()/] get([genModel.getImportedName('java.lang.String')/] literal) { - for (int i = 0; i < VALUES_ARRAY.length; ++i) { - [genEnum.getName()/] result = VALUES_ARRAY['[i]'/]; - if (result.toString().equals(literal)) { - return result; - } - } - return null; - } - - /** - * Returns the '[genEnum.getFormattedName()/]' literal with the specified name. - * - * - * @generated - */ - public static [genEnum.getName()/] getByName([genModel.getImportedName('java.lang.String')/] name) { - for (int i = 0; i < VALUES_ARRAY.length; ++i) { - [genEnum.getName()/] result = VALUES_ARRAY['[i]'/]; - if (result.getName().equals(name)) { - return result; - } - } - return null; - } - - /** - * Returns the '[genEnum.getFormattedName()/]' literal with the specified integer value. - * - * - * @generated - */ - public static [genEnum.getName()/] get(int value) { - switch (value) { -[for (genEnumLiteral : GenEnumLiteral | genEnum.getUniqueValuedGenEnumLiterals())] - case [genEnumLiteral.getEnumLiteralValueConstantName()/]: return [genEnumLiteral.getEnumLiteralInstanceConstantName()/]; -[/for] - } - return null; - } - -[if (isEnum)] - /** - * - * - * @generated - */ - private final int value; - - /** - * - * - * @generated - */ - private final [genModel.getImportedName('java.lang.String')/] name; - - /** - * - * - * @generated - */ - private final [genModel.getImportedName('java.lang.String')/] literal; - -[/if] - /** - * Only this class can construct instances. - * - * - * @generated - */ - private [genEnum.getName()/](int value, [genModel.getImportedName('java.lang.String')/] name, [genModel.getImportedName('java.lang.String')/] literal) { -[if (isEnum)] - this.value = value; - this.name = name; - this.literal = literal; -[else] - super(value, name, literal); -[/if] - } - -[if (isEnum)] - /** - * - * - * @generated - */ - public int getValue() { - return value; - } - - /** - * - * - * @generated - */ - public [genModel.getImportedName('java.lang.String')/] getName() { - return name; - } - - /** - * - * - * @generated - */ - public [genModel.getImportedName('java.lang.String')/] getLiteral() { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public [genModel.getImportedName('java.lang.String')/] toString() { - return literal; - } - -[/if] -} //[genEnum.getName()/] -[if (genModel.suppressEMFMetaData and not genModel.suppressInterfaces )] - - [if (isEnum)] -/** - * A private implementation interface used to hide the inheritance from Enumerator. - * - * - * @generated - */ -interface Internal[genEnum.getName()/] extends org.eclipse.emf.common.util.Enumerator { - // Empty -} - [else] -/** - * A private implementation class to construct the instances. - * - * - * @generated - */ -class Internal[genEnum.getName()/] extends org.eclipse.emf.common.util.AbstractEnumerator { - /** - * Only this class can construct instances. - * - * - * @generated - */ - protected Internal[genEnum.getName()/](int value, [genModel.getImportedName('java.lang.String')/] name, [genModel.getImportedName('java.lang.String')/] literal) { - super(value, name, literal); - } -} - [/if][comment isEnum /] -[/if] -[/let][comment isEnum /] -[/template] - -[template public genEnumLiteralTemplate (genEnumLiteral : GenEnumLiteral, genModel : GenModel) ] - /** - * The '[genEnumLiteral.getFormattedName()/]' literal object. - * - * - * @see #[genEnumLiteral.getEnumLiteralValueConstantName()/] - * @generated - * @ordered - */ - [genEnumLiteral.getEnumLiteralInstanceConstantName()/]([genEnumLiteral.getValue()/], "[genEnumLiteral.getName()/]", [genModel.toStringLiteral(genEnumLiteral.getLiteral())/])[/template] - -[query public enumFilePath(genEnum : GenEnum) : String - = genEnum.getGenModel().extractSourceDirectory(genEnum.getGenModel().modelDirectory) + '/' + genEnum.getQualifiedName().toPath() + '.java' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/FactoryClass.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/FactoryClass.mtl deleted file mode 100644 index fb6ed4f8a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/FactoryClass.mtl +++ /dev/null @@ -1,750 +0,0 @@ -[comment encoding = UTF-8 /] -[module FactoryClass('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[template public factoryClass(genPackage : GenPackage, isInterface : Boolean, isImplementation : Boolean)] -[comment] - /** - * - * - * Copyright (c) 2002-2010 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -[/comment] -[let genModel : GenModel = genPackage.genModel] -[let packageName : String = genPackage.factoryClassPackageName(isInterface)] -[let className : String = genPackage.factoryClassName(isImplementation)] -[genModel.initializeImportManager(packageName, className)/] -[if (isImplementation)] -[genModel.addPseudoImport('org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container.Dynamic')/] -[genModel.addImport('org.eclipse.emf.ecore.EClass')/] -[genModel.addImport('org.eclipse.emf.ecore.EObject')/] -[if (not genPackage.hasJavaLangConflict() and not genPackage.hasInterfaceImplConflict() and genPackage.getClassPackageName() <> genPackage.getInterfacePackageName())][genModel.addImport(genPackage.getInterfacePackageName() + '.*')/][/if] -[/if] - - - -[file (factoryClassPath(genPackage, isInterface, isImplementation), false, 'UTF-8')] -[genModel.includeHeader()/] -package [packageName/]; -[let content : String = genPackage.factoryClassFileContent(isInterface, isImplementation, genModel, className)] -[genModel.genSortedImports()/] - -[content/] -[/let] -[/file] - - - -[/let][comment className /] -[/let][comment packageName /] -[/let][comment genModel /] -[/template] - -[template protected factoryClassFileContent(genPackage : GenPackage, isInterface : Boolean, isImplementation : Boolean, genModel : GenModel, className : String) post(trim())] -[let publicStaticFinalFlag : String = if (isImplementation) then 'public static final ' else '' endif] -[if (isInterface)] -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - [if (not genModel.suppressEMFMetaData)] - * @see [genPackage.getQualifiedPackageInterfaceName()/] - [/if] - * @generated - */ -[else][comment isInterface /] -/** - * - * An implementation of the model Factory. - * - * @generated - */ -[/if][comment isInterface /] -[if (isImplementation)] -public class [className/] extends [genModel.getImportedName('org.eclipse.emf.ecore.impl.EFactoryImpl')/][if (not genModel.suppressInterfaces)] implements [genPackage.getImportedFactoryInterfaceName()/][/if] { -[else] -public interface [className/][if (not genModel.suppressEMFMetaData)] extends [genModel.getImportedName('org.eclipse.emf.ecore.EFactory')/][/if] { -[/if] -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - [publicStaticFinalFlag/][genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] -[if (isImplementation and (genModel.suppressEMFMetaData or genModel.suppressInterfaces))] - /** - * The singleton instance of the factory. - * - * - * @generated - */ - [publicStaticFinalFlag/][genPackage.getFactoryClassName()/] eINSTANCE = init(); - -[/if] -[if (isInterface and genModel.suppressEMFMetaData)] - /** - * The singleton instance of the factory. - * - * - * @generated - */ - [publicStaticFinalFlag/][genPackage.getFactoryInterfaceName()/] INSTANCE = [genPackage.getQualifiedFactoryClassName()/].eINSTANCE; - -[else][if (isInterface and not genModel.suppressInterfaces)] - /** - * The singleton instance of the factory. - * - * - * @generated - */ - [publicStaticFinalFlag/][genPackage.getFactoryInterfaceName()/] eINSTANCE = [genPackage.getQualifiedFactoryClassName()/].init(); - -[/if][/if] -[if (isImplementation)] - /** - * Creates the default factory implementation. - * - * - * @generated - */ - [let factoryType : String = if (genModel.suppressEMFMetaData) then genPackage.getFactoryClassName() else genPackage.getImportedFactoryInterfaceName() endif] - public static [factoryType/] init() { - try { - [factoryType/] the[genPackage.getFactoryName()/] = ([factoryType/])[genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE.getEFactory("[genPackage.getNSURI()/]");[genModel.getNonNLS()/] - if (the[genPackage.getFactoryName()/] != null) { - return the[genPackage.getFactoryName()/]; - } - } catch (Exception exception) { - [genModel.getImportedName('org.eclipse.emf.ecore.plugin.EcorePlugin')/].INSTANCE.log(exception); - } - return new [genPackage.getImportedFactoryClassName()/](); - } - [/let] - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public [genPackage.getFactoryClassName()/]() { - super(); - } - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - [for (genClass : GenClass | genPackage.genClasses)] - [if (not genClass.isAbstract())] - case [genPackage.getImportedPackageInterfaceName()/].[genClass.getClassifierID()/]: return [if (not genClass.isEObjectExtension())](EObject)[/if]create[genClass.getName()/](); - [/if] - [/for] - default: - throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - } - } - - [if (genPackage.getAllGenDataTypes()->notEmpty())] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public Object createFromString([genModel.getImportedName('org.eclipse.emf.ecore.EDataType')/] eDataType, String initialValue) { - switch (eDataType.getClassifierID()) { - [for (genDataType : GenDataType | genPackage.getAllGenDataTypes())] - [if (genDataType.isSerializable())] - case [genPackage.getImportedPackageInterfaceName()/].[genDataType.getClassifierID()/]: - return create[genDataType.getName()/]FromString(eDataType, initialValue); - [/if] - [/for] - default: - throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - } - } - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public String convertToString([genModel.getImportedName('org.eclipse.emf.ecore.EDataType')/] eDataType, Object instanceValue) { - switch (eDataType.getClassifierID()) { - [for (genDataType : GenDataType | genPackage.getAllGenDataTypes())] - [if (genDataType.isSerializable())] - case [genPackage.getImportedPackageInterfaceName()/].[genDataType.getClassifierID()/]: - return convert[genDataType.getName()/]ToString(eDataType, instanceValue); - [/if] - [/for] - default: - throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - } - } - - [/if] - [for (genClass : GenClass | genPackage.genClasses)] - [if (not genClass.isAbstract())] - /** - * - * - * @generated - */ - public [genClass.getTypeParameters()/][genClass.getImportedInterfaceName()/][genClass.getInterfaceTypeArguments()/] create[genClass.getName()/]() { - [if (genClass.dynamic)] - [genClass.getImportedInterfaceName()/][genClass.getInterfaceTypeArguments()/] [genClass.getSafeUncapName()/] = [genClass.getCastFromEObject()/]super.create([genClass.getQualifiedClassifierAccessor()/]); - [else] - [genClass.getImportedClassName()/][genClass.getClassTypeArguments()/] [genClass.getSafeUncapName()/] = new [genClass.getImportedClassName()/][genClass.getClassTypeArguments()/]()[if (genModel.suppressInterfaces and genPackage.getReflectionPackageName() <> genPackage.getInterfacePackageName())]{}[/if]; - [/if] - return [genClass.getSafeUncapName()/]; - } - - [/if] - [/for] - - [for (genDataType : GenDataType | genPackage.getAllGenDataTypes())] - [if (genDataType.isSerializable())] - [if (genPackage.dataTypeConverters)] - [let eDataType : String = genDataType.getQualifiedClassifierAccessor()] - /** - * - * - * @generated - */ - [if (genModel.useGenerics() and genDataType.isUncheckedCast())] - @SuppressWarnings("unchecked") - [/if] - public [genDataType.getImportedParameterizedInstanceClassName()/] create[genDataType.getName()/](String literal) { - [if (genDataType.oclIsKindOf(GenEnum))] - [genDataType.getImportedInstanceClassName()/] result = [genDataType.getImportedInstanceClassName()/].get(literal); - if (result == null) throw new IllegalArgumentException("The value '" + literal + "' is not a valid enumerator of '" + [eDataType/].getName() + "'");[genModel.getNonNLS()/][genModel.getNonNLS(2)/][genModel.getNonNLS(3)/] - return result; - [else][if (genDataType.getBaseType() <> null)] - [let genBaseType : GenDataType = genDataType.getBaseType()] - [let isPrimitiveConversion : Boolean = not genDataType.isPrimitiveType() and genBaseType.isPrimitiveType()] - [if (genBaseType.genPackage = genPackage)] - [if (isPrimitiveConversion and not genModel.isJDK50())] - return new [genDataType.getObjectInstanceClassName()/](create[genBaseType.getName()/](literal)); - [else] - return create[genBaseType.getName()/](literal); - [/if] - [else][if (genBaseType.genPackage.dataTypeConverters)] - [if (isPrimitiveConversion and not genModel.isJDK50())] - return new [genDataType.getObjectInstanceClassName()/]([genBaseType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].create[genBaseType.getName()/](literal)); - [else] - return [genBaseType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].create[genBaseType.getName()/](literal); - [/if] - [else] - return [if (not genDataType.isObjectType())]([genDataType.getObjectInstanceClassName()/])[/if][genBaseType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].createFromString([genBaseType.getQualifiedClassifierAccessor()/], literal); - [/if][/if] - [/let] - [/let] - [else][if (genDataType.getItemType() <> null)] - [let genItemType : GenDataType = genDataType.getItemType()] - if (literal == null) return null; - [genDataType.getImportedParameterizedInstanceClassName()/] result = new [genModel.getImportedName('java.util.ArrayList')/][if (genModel.useGenerics())]<[genItemType.getObjectType().getImportedParameterizedInstanceClassName()/]>[/if](); - [if (not genModel.isEMF26())] - for ([genModel.getImportedName('java.util.StringTokenizer')/] stringTokenizer = new [genModel.getImportedName('java.util.StringTokenizer')/](literal); stringTokenizer.hasMoreTokens(); ) - [else] - for (String item : split(literal)) - [/if] - { - [if (not genModel.isEMF26())] - String item = stringTokenizer.nextToken(); - [/if] - [if (genItemType.genPackage = genPackage)] - [if (genPackage.dataTypeConverters)] - result.add(create[genItemType.getObjectType().getName()/](item)); - [else] - result.add(create[genItemType.getName()/]FromString([genItemType.getQualifiedClassifierAccessor()/], item)); - [/if] - [else] - [if (genItemType.genPackage.dataTypeConverters)] - result.add([genItemType.getObjectType().genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].create[genItemType.getObjectType().getName()/](item)); - [else] - result.add([genItemType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].createFromString([genItemType.getQualifiedClassifierAccessor()/], item)); - [/if] - [/if] - [/let] - } - return result; - [else][if (genDataType.getMemberTypes()->notEmpty())] - if (literal == null) return [genDataType.getStaticValue(null)/]; - [genDataType.getImportedInstanceClassName()/] result = [genDataType.getStaticValue(null)/]; - RuntimeException exception = null; - [for (genMemberType : GenDataType | genDataType.getMemberTypes())] - try { - [if (genMemberType.genPackage = genPackage)] - [if (genPackage.dataTypeConverters)] - [if (not genDataType.isPrimitiveType())] - result = create[genMemberType.getObjectType().getName()/](literal); - [else] - result = create[genMemberType.getName()/](literal); - [/if] - [else] - result = ([genDataType.getObjectInstanceClassName()/])create[genMemberType.getName()/]FromString([genMemberType.getQualifiedClassifierAccessor()/], literal); - [/if] - [else] - [if (genPackage.dataTypeConverters)] - [if (not genDataType.isPrimitiveType())] - result = [genMemberType.getObjectType().genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].create[genMemberType.getObjectType().getName()/](literal); - [else] - result = ([genDataType.getObjectInstanceClassName()/])[genMemberType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].createFromString([genMemberType.getQualifiedClassifierAccessor()/], literal); - [/if] - [/if] - [/if] - if ([if (not genDataType.isPrimitiveType())]result != null && [/if][genModel.getImportedName('org.eclipse.emf.ecore.util.Diagnostician')/].INSTANCE.validate([eDataType/], [if (genDataType.isPrimitiveType() and not genModel.isJDK50())]new [genDataType.getObjectInstanceClassName()/](result)[else]result[/if], null, null)) { - return result; - } - } - catch (RuntimeException e) { - exception = e; - } - [/for] - if ([if (not genDataType.isPrimitiveType())]result != null || [/if]exception == null) return result; - - throw exception; - [else][if (genModel.useGenerics() and (genDataType.isArrayType() or genDataType.ecoreDataType.eTypeParameters->notEmpty() or genDataType.ecoreDataType.instanceTypeName.contains('<')))] - return ([genDataType.getImportedParameterizedObjectInstanceClassName()/])super.createFromString(literal); - [else][if (genDataType.isArrayType())] - // TODO: implement this method - // Ensure that you remove @generated or mark it @generated NOT - throw new [genModel.getImportedName('java.lang.UnsupportedOperationException')/](); - [else][if (genDataType.isPrimitiveType() and not genModel.isJDK50())] - return (([genDataType.getObjectInstanceClassName()/])super.createFromString([eDataType/], literal)).[genDataType.getPrimitiveValueFunction()/](); - [else] - return [if (not genDataType.isObjectType())]([genDataType.getObjectInstanceClassName()/])[/if]super.createFromString([eDataType/], literal); - [/if][/if][/if][/if][/if][/if][/if] - } - - [/let] - [/if] - /** - * - * - * @generated - */ - [if (genModel.useGenerics() and genDataType.isUncheckedCast())] - @SuppressWarnings("unchecked") - [/if] - public [genDataType.getImportedParameterizedObjectInstanceClassName()/] create[genDataType.getName()/]FromString([genModel.getImportedName('org.eclipse.emf.ecore.EDataType')/] eDataType, String initialValue) { - [if (genDataType.oclIsKindOf(GenEnum))] - [if (genPackage.dataTypeConverters)] - return create[genDataType.getName()/](initialValue); - [else] - [genDataType.oclAsType(GenEnum).getImportedInstanceClassName()/] result = [genDataType.oclAsType(GenEnum).getImportedInstanceClassName()/].get(initialValue); - if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'");[genModel.getNonNLS()/][genModel.getNonNLS(2)/][genModel.getNonNLS(3)/] - return result; - [/if] - [else][if (genDataType.getBaseType() <> null)] - [let genBaseType : GenDataType = genDataType.getBaseType()] - [if (genBaseType.genPackage = genPackage)] - return [if (genDataType.getObjectInstanceClassName() <> genBaseType.getObjectInstanceClassName())]([genDataType.getObjectInstanceClassName()/])[/if]create[genBaseType.getName()/]FromString([genBaseType.getQualifiedClassifierAccessor()/], initialValue); - [else] - return [if (not genDataType.isObjectType())]([genDataType.getObjectInstanceClassName()/])[/if][genBaseType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].createFromString([genBaseType.getQualifiedClassifierAccessor()/], initialValue); - [/if] - [/let][comment genBaseType /] - [else][if (genDataType.getItemType() <> null)] - [let genItemType : GenDataType = genDataType.getItemType()] - [if (genPackage.dataTypeConverters)] - return create[genDataType.getName()/](initialValue); - [else] - if (initialValue == null) return null; - [genDataType.getImportedParameterizedObjectInstanceClassName()/] result = new [genModel.getImportedName('java.util.ArrayList')/][if (genModel.useGenerics())]<[genItemType.getObjectType().getImportedParameterizedInstanceClassName()/]>[/if](); - [if (not genModel.isEMF26())] - for ([genModel.getImportedName('java.util.StringTokenizer')/] stringTokenizer = new [genModel.getImportedName('java.util.StringTokenizer')/](initialValue); stringTokenizer.hasMoreTokens(); ) - [else] - for (String item : split(initialValue)) - [/if] - { - [if (not genModel.isEMF26())] - String item = stringTokenizer.nextToken(); - [/if] - [if (genItemType.genPackage = genPackage)] - result.add(create[genItemType.getName()/]FromString([genItemType.getQualifiedClassifierAccessor()/], item)); - [else] - result.add([if (not genItemType.isObjectType())]([genItemType.getObjectInstanceClassName()/])[/if][genItemType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].createFromString([genItemType.getQualifiedClassifierAccessor()/], item)); - [/if] - } - return result; - [/if] - [/let][comment genItemType /] - [else][if (genDataType.getMemberTypes()->notEmpty())] - [if (genPackage.dataTypeConverters)] - [if (genDataType.isPrimitiveType() and not genModel.isJDK50())] - return new [genDataType.getObjectInstanceClassName()/](create[genDataType.getName()/](initialValue)); - [else] - return create[genDataType.getName()/](initialValue); - [/if] - [else] - if (initialValue == null) return null; - [genDataType.getObjectInstanceClassName()/] result = null; - RuntimeException exception = null; - [for (genMemberType : GenDataType | genDataType.getMemberTypes())] - try { - [if (genMemberType.genPackage = genPackage)] - result = [if (not genDataType.isObjectType() and genDataType.getObjectInstanceClassName() <> genMemberType.getObjectInstanceClassName())]([genDataType.getObjectInstanceClassName()/])[/if]create[genMemberType.getName()/]FromString([genMemberType.getQualifiedClassifierAccessor()/], initialValue); - [else] - result = [if (not genDataType.isObjectType())]([genDataType.getObjectInstanceClassName()/])[/if][genMemberType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].createFromString([genMemberType.getQualifiedClassifierAccessor()/], initialValue); - [/if] - if (result != null && [genModel.getImportedName('org.eclipse.emf.ecore.util.Diagnostician')/].INSTANCE.validate(eDataType, result, null, null)) { - return result; - } - } catch (RuntimeException e) { - exception = e; - } - [/for] - if (result != null || exception == null) return result; - - throw exception; - [/if] - [else][if (genModel.useGenerics() and (genDataType.isArrayType() or genDataType.ecoreDataType.eTypeParameters->notEmpty() or genDataType.ecoreDataType.instanceTypeName.contains('<')))] - return [if (not genDataType.isObjectType())]([genDataType.getImportedParameterizedObjectInstanceClassName()/])[/if]super.createFromString(initialValue); - [else][if (genDataType.isArrayType())] - // TODO: implement this method - // Ensure that you remove @generated or mark it @generated NOT - throw new [genModel.getImportedName('java.lang.UnsupportedOperationException')/](); - [else] - return [if (not genDataType.isObjectType())]([genDataType.getObjectInstanceClassName()/])[/if]super.createFromString(eDataType, initialValue); - [/if][/if][/if][/if][/if][/if] - } - - [if (genPackage.dataTypeConverters)] - [let eDataType : String = genDataType.getQualifiedClassifierAccessor()] - /** - * - * - * @generated - */ - public String convert[genDataType.getName()/]([genDataType.getImportedBoundedWildcardInstanceClassName()/] instanceValue) { - [if (genDataType.oclIsKindOf(GenEnum))] - return instanceValue == null ? null : instanceValue.toString(); - [else][if (genDataType.getBaseType() <> null)] - [let genBaseType : GenDataType = genDataType.getBaseType()] - [let isPrimitiveConversion : Boolean = not genDataType.isPrimitiveType() and genBaseType.isPrimitiveType()] - [if (genBaseType.genPackage = genPackage)] - [if (isPrimitiveConversion)] - return instanceValue == null ? null : convert[genBaseType.getName()/](instanceValue[if (not genModel.isJDK50())].[genBaseType.getPrimitiveValueFunction()/]()[/if]); - [else] - return convert[genBaseType.getName()/](instanceValue); - [/if] - [else][if (genBaseType.genPackage.dataTypeConverters)] - return [genBaseType.genPackage.getQualifiedFactoryInstanceAccessor()/].convert[genBaseType.getName()/](instanceValue); - [else] - return [genBaseType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].convertToString([genBaseType.getQualifiedClassifierAccessor()/], instanceValue); - [/if][/if] - [/let] - [/let] - [else][if (genDataType.getItemType() <> null)] - [let genItemType : GenDataType = genDataType.getItemType()] - if (instanceValue == null) return null; - if (instanceValue.isEmpty()) return ""; - [genModel.getImportedName('java.lang.StringBuffer')/] result = new [genModel.getImportedName('java.lang.StringBuffer')/](); - [let item : String = if (genModel.useGenerics()) then 'item' else 'i.next()' endif] - [if (not genModel.useGenerics())] - for ([genModel.getImportedName('java.util.Iterator')/] i = instanceValue.iterator(); i.hasNext(); ) - [else] - for ([genModel.getImportedName('java.lang.Object')/] item : instanceValue) - [/if] - { - [if (genItemType.genPackage = genPackage)] - [if (genPackage.dataTypeConverters)] - result.append(convert[genItemType.getObjectType().getName()/](([genItemType.getObjectType().getObjectInstanceClassName()/])[item/])); - [else] - result.append(convert[genItemType.getName()/]ToString([genItemType.getQualifiedClassifierAccessor()/], [item/])); - [/if] - [else] - [if (genItemType.genPackage.dataTypeConverters)] - result.append([genItemType.getObjectType().genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].convert[genItemType.getObjectType().getName()/](([genItemType.getObjectType().getObjectInstanceClassName()/])[item/])); - [else] - result.append([genItemType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].convertToString([genItemType.getQualifiedClassifierAccessor()/], [item/])); - [/if] - [/if] - [/let][comment item /] - result.append(' '); - } - return result.substring(0, result.length() - 1); - [/let][comment genItemType /] - [else][if (not genDataType.getMemberTypes()->isEmpty())] - [if (not genDataType.isPrimitiveType())] - if (instanceValue == null) return null; - [for (genMemberType : GenDataType | genDataType.getMemberTypes())] - if ([genMemberType.getQualifiedClassifierAccessor()/].isInstance(instanceValue)) { - try { - [if (genMemberType.genPackage = genPackage)] - [if (genPackage.dataTypeConverters)] - [if (genMemberType.getQualifiedInstanceClassName() = genDataType.getQualifiedInstanceClassName())] - String value = convert[genMemberType.getName()/](instanceValue); - [else][if (genMemberType.isPrimitiveType() and not genModel.isJDK50())] - String value = convert[genMemberType.getName()/]((([genMemberType.getObjectType().getImportedInstanceClassName()/])instanceValue).[genMemberType.getPrimitiveValueFunction()/]()); - [else] - String value = convert[genMemberType.getName()/](([genMemberType.getObjectType().getImportedBoundedWildcardInstanceClassName()/])instanceValue); - [/if][/if] - [else] - String value = convert[genMemberType.getName()/]ToString([genMemberType.getQualifiedClassifierAccessor()/], instanceValue); - [/if] - [else] - [if (genMemberType.genPackage.dataTypeConverters)] - String value = [genMemberType.getObjectType().genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].convert[genMemberType.getObjectType().getName()/](([genMemberType.getObjectType().getObjectInstanceClassName()/])instanceValue); - [else] - String value = [genMemberType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].convertToString([genMemberType.getQualifiedClassifierAccessor()/], instanceValue); - [/if] - [/if] - if (value != null) return value; - } catch (Exception e) { - // Keep trying other member types until all have failed. - } - } - [/for] - [else] - [for (genMemberType : GenDataType | genDataType.getMemberTypes())] - try { - [if (genMemberType.genPackage = genPackage)] - [if (genPackage.dataTypeConverters)] - String value = convert[genMemberType.getName()/](instanceValue); - [else] - String value = convert[genMemberType.getName()/]ToString([genMemberType.getQualifiedClassifierAccessor()/], [if (not genModel.isJDK50())]new [genMemberType.getObjectInstanceClassName()/](instanceValue)[else]instanceValue[/if]); - [/if] - [else] - [if (genMemberType.genPackage.dataTypeConverters)] - String value = [genMemberType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].convert[genMemberType.getName()/](instanceValue); - [else] - String value = [genMemberType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].convertToString([genMemberType.getQualifiedClassifierAccessor()/], [if (not genModel.isJDK50())]new [genMemberType.getObjectInstanceClassName()/](instanceValue)[else]instanceValue[/if]); - [/if] - [/if] - if (value != null) return value; - } catch (Exception e) { - // Keep trying other member types until all have failed. - } - [/for] - [/if] - throw new IllegalArgumentException("Invalid value: '"+instanceValue+"' for datatype :"+[eDataType/].getName()); - [else][if (genModel.useGenerics() and (genDataType.isArrayType() or genDataType.ecoreDataType.eTypeParameters->notEmpty() or genDataType.ecoreDataType.instanceTypeName.contains('<')))] - return super.convertToString(instanceValue); - [else][if (genDataType.isArrayType())] - // TODO: implement this method - // Ensure that you remove @generated or mark it @generated NOT - throw new [genModel.getImportedName('java.lang.UnsupportedOperationException')/](); - [else][if (genDataType.isPrimitiveType() and not genModel.isJDK50())] - return super.convertToString([eDataType/], new [genDataType.getObjectInstanceClassName()/](instanceValue)); - [else] - return super.convertToString([eDataType/], instanceValue); - [/if][/if][/if][/if][/if][/if][/if] - } - [/let] - [/if] - /** - * - * - * @generated - */ - [if (genModel.useGenerics() and genDataType.getItemType() <> null and genPackage.dataTypeConverters)] - @SuppressWarnings("unchecked") - [/if] - public String convert[genDataType.getName()/]ToString([genModel.getImportedName('org.eclipse.emf.ecore.EDataType')/] eDataType, Object instanceValue) { - [if (genDataType.oclIsKindOf(GenEnum))] - return instanceValue == null ? null : instanceValue.toString(); - [else][if (genDataType.getBaseType() <> null)] - [let genBaseType : GenDataType = genDataType.getBaseType()] - [if (genBaseType.genPackage = genPackage)] - return convert[genBaseType.getName()/]ToString([genBaseType.getQualifiedClassifierAccessor()/], instanceValue); - [else] - return [genBaseType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].convertToString([genBaseType.getQualifiedClassifierAccessor()/], instanceValue); - [/if] - [/let] - [else][if (genDataType.getItemType() <> null)] - [let genItemType : GenDataType = genDataType.getItemType()] - [if (genPackage.dataTypeConverters)] - return convert[genDataType.getName()/](([genDataType.getImportedBoundedWildcardInstanceClassName()/])instanceValue); - [else] - [let singleWildcard : String = if (genModel.useGenerics()) then '' else '' endif] - if (instanceValue == null) return null; - [genModel.getImportedName('java.util.List')/][singleWildcard/] list = ([genModel.getImportedName('java.util.List')/][singleWildcard/])instanceValue; - if (list.isEmpty()) return ""; - [genModel.getImportedName('java.lang.StringBuffer')/] result = new [genModel.getImportedName('java.lang.StringBuffer')/](); - [let item : String = if (genModel.useGenerics()) then 'item' else 'i.next()' endif] - [if (not genModel.useGenerics())] - for ([genModel.getImportedName('java.util.Iterator')/] i = list.iterator(); i.hasNext(); ) { - [else] - for ([genModel.getImportedName('java.lang.Object')/] item : list) { - [/if] - [if (genItemType.genPackage = genPackage)] - result.append(convert[genItemType.getName()/]ToString([genItemType.getQualifiedClassifierAccessor()/], [item/])); - [else] - result.append([genItemType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].convertToString([genItemType.getQualifiedClassifierAccessor()/], [item/])); - [/if] - [/let] - result.append(' '); - } - return result.substring(0, result.length() - 1); - [/let][comment singleWildcard /] - [/if] - [/let][comment genItemType /] - [else][if (not genDataType.getMemberTypes()->isEmpty())] - [if (genPackage.dataTypeConverters)] - [if (genDataType.isPrimitiveType())] - return instanceValue == null ? null : convert[genDataType.getName()/]((([genDataType.getObjectInstanceClassName()/])instanceValue)[if (not genModel.isJDK50())].[genDataType.getPrimitiveValueFunction()/]()[/if]); - [else] - return convert[genDataType.getName()/](instanceValue); - [/if] - [else] - if (instanceValue == null) return null; - [for (genMemberType : GenDataType | genDataType.getMemberTypes())] - if ([genMemberType.getQualifiedClassifierAccessor()/].isInstance(instanceValue)) { - try { - [if (genMemberType.genPackage = genPackage)] - String value = convert[genMemberType.getName()/]ToString([genMemberType.getQualifiedClassifierAccessor()/], instanceValue); - [else] - String value = [genMemberType.genPackage.getQualifiedEFactoryInternalInstanceAccessor()/].convertToString([genMemberType.getQualifiedClassifierAccessor()/], instanceValue); - [/if] - if (value != null) return value; - } catch (Exception e) { - // Keep trying other member types until all have failed. - } - } - [/for] - throw new IllegalArgumentException("Invalid value: '"+instanceValue+"' for datatype :"+eDataType.getName()); - [/if] - [else][if (genModel.useGenerics() and (genDataType.isArrayType() or genDataType.ecoreDataType.eTypeParameters->notEmpty() or genDataType.ecoreDataType.instanceTypeName.contains('<')))] - return super.convertToString(instanceValue); - [else][if (genDataType.isArrayType())] - // TODO: implement this method - // Ensure that you remove @generated or mark it @generated NOT - throw new [genModel.getImportedName('java.lang.UnsupportedOperationException')/](); - [else] - return super.convertToString(eDataType, instanceValue); - [/if][/if][/if][/if][/if][/if] - } - - [/if][comment genDataType.isSerializable() /] - [/for] -[else] - [for (genClass : GenClass | genPackage.genClasses)] - [if (genClass.hasFactoryInterfaceCreateMethod())] - /** - * Returns a new object of class '[genClass.getFormattedName()/]'. - * - * - * @return a new object of class '[genClass.getFormattedName()/]'. - * @generated - */ - [genClass.getTypeParameters()/][genClass.getImportedInterfaceName()/][genClass.getInterfaceTypeArguments()/] create[genClass.getName()/](); - - [/if] - [/for] - [if (genPackage.dataTypeConverters)] - [for (genDataType : GenDataType | genPackage.getAllGenDataTypes())] - [if (genDataType.isSerializable())] - /** - * Returns an instance of data type '[genDataType.getFormattedName()/]' corresponding the given literal. - * - * - * @param literal a literal of the data type. - * @return a new instance value of the data type. - * @generated - */ - [genDataType.getImportedParameterizedInstanceClassName()/] create[genDataType.getName()/](String literal); - - /** - * Returns a literal representation of an instance of data type '[genDataType.getFormattedName()/]'. - * - * - * @param instanceValue an instance value of the data type. - * @return a literal representation of the instance value. - * @generated - */ - String convert[genDataType.getName()/]([genDataType.getImportedBoundedWildcardInstanceClassName()/] instanceValue); - - [/if] - [/for] - [/if] -[/if] -[if (not isImplementation and not genModel.suppressEMFMetaData)] - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - [genPackage.getPackageInterfaceName()/] get[genPackage.getBasicPackageName()/](); - -[else][if (isImplementation)] - /** - * - * - * @generated - */ - public [genPackage.getImportedPackageInterfaceName()/] get[genPackage.getBasicPackageName()/]() { - return ([genPackage.getImportedPackageInterfaceName()/])getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Deprecated - [/if] - public static [genPackage.getImportedPackageInterfaceName()/] getPackage() { - return [genPackage.getImportedPackageInterfaceName()/].eINSTANCE; - } - -[/if][/if] -} //[className/] -[/let][comment publicStaticFinalFlag /] -[/template] - -[query public factoryClassPackageName(genPackage : GenPackage, isInterface : Boolean) : String = - if (isInterface or genPackage.genModel.suppressInterfaces) then - genPackage.getReflectionPackageName() - else - genPackage.getClassPackageName() - endif -/] - -[query public factoryClassName(genPackage : GenPackage, isImplementation : Boolean) : String = - if (isImplementation) then - genPackage.getFactoryClassName() - else - genPackage.getFactoryInterfaceName() - endif -/] - -[query public factoryClassPath(genPackage : GenPackage, isInterface : Boolean, isImplementation : Boolean) : String - = genPackage.genModel.modelPath(genPackage.factoryClassPackageName(isInterface), genPackage.factoryClassName(isImplementation)) /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/PackageClass.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/PackageClass.mtl deleted file mode 100644 index 4ee9f8b4e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/PackageClass.mtl +++ /dev/null @@ -1,1279 +0,0 @@ -[comment encoding = UTF-8 /] -[module PackageClass('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnumLiteral /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenOperation /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenParameter /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenTypeParameter /] -[import org::eclipse::emf::eef::codegen::ecore::model::genpackage::EGenericType /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::EAnnotation /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[template public packageClass(genPackage : GenPackage, isInterface : Boolean, isImplementation : Boolean)] -[comment] - /** - * - * - * Copyright (c) 2002-2010 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -[/comment] -[let genModel : GenModel = genPackage.genModel] -[let packageName : String = genPackage.packageClassPackageName(isInterface)] -[let className : String = genPackage.packageClassName(isImplementation)] - -[genModel.initializeImportManager(genPackage, packageName, className)/] - -[if (isImplementation)] -[genModel.addPseudoImport('org.eclipse.emf.ecore.EPackage.Registry')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.EPackage.Descriptor')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.impl.EPackageImpl.EBasicWhiteList')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.impl.EPackageImpl.EBasicWhiteList')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container.Dynamic')/] -[if (genPackage.isLiteralsInterface())] - [genModel.addPseudoImport(genPackage.getQualifiedPackageInterfaceName() + '.Literals')/] -[/if] -[for (genClassifier : GenClassifier | genPackage.getOrderedGenClassifiers())] - [genModel.addPseudoImport(genPackage.getQualifiedPackageInterfaceName() + '.' + genPackage.getClassifierID(genClassifier))/] -[/for] -[/if] - - - -[file (packageClassPath(genPackage, isInterface, isImplementation), false, 'UTF-8')] -[genModel.includeHeader()/] -package [packageName/]; -[let content : String = genPackage.packageClassFileContent(isInterface, isImplementation, genModel, className)] -[genModel.genSortedImports()/] - -[content.trim()/] -[/let] -[/file] - - - -[/let][comment className /] -[/let][comment packageName /] -[/let][comment genModel /] -[/template] - -[template protected packageClassFileContent(genPackage : GenPackage, isInterface : Boolean, isImplementation : Boolean, genModel : GenModel, className : String)] -[let publicStaticFinalFlag : String = if (isImplementation) then 'public static final ' else '' endif] -[if (isImplementation)] -[genModel.addPseudoImport('org.eclipse.emf.ecore.EPackage.Registry')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.EPackage.Descriptor')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.impl.EPackageImpl.EBasicWhiteList')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container.Dynamic')/] - [if (genPackage.isLiteralsInterface())] -[genModel.addPseudoImport(genPackage.getQualifiedPackageInterfaceName() + '.Literals')/] - [/if] - [for (genClassifier : GenClassifier | genPackage.getOrderedGenClassifiers())] - [genModel.addPseudoImport(genPackage.getQualifiedPackageInterfaceName() + '.' + genPackage.getClassifierID(genClassifier))/] - [/for] -[/if] -[if (isInterface)] -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - [if (genModel.operationReflection)] - *
  • each operation of each class,
  • - [/if] - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - [if (genPackage.hasDocumentation())] - * - * [genPackage.getDocumentation(genModel.getIndentation())/] - * - [/if] - * @see [genPackage.getQualifiedFactoryInterfaceName()/] - [if (not genModel.suppressEMFModelTags)] - [let modelInfoLines : Sequence(String) = genPackage.getModelInfo().tokenize(genModel.getLineDelimiter() + '\r')] - [if (modelInfoLines->isEmpty())] - * @model - [else] - * @model [modelInfoLines->sep(genModel.getLineDelimiter() + ' * ')/] - [/if] - [/let] - [/if] - * @generated - */ -[else][comment isInterface /] -/** - * - * An implementation of the model Package. - * - * @generated - */ -[/if][comment isInterface /] -[if (isImplementation)] -public class [className/] extends [genModel.getImportedName('org.eclipse.emf.ecore.impl.EPackageImpl')/][if (not isInterface)] implements [genPackage.getImportedPackageInterfaceName()/][/if] { -[else] -public interface [className/] extends [genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/] { -[/if] -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - [publicStaticFinalFlag/][genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] -[if (isInterface)] - /** - * The package name. - * - * - * @generated - */ - [publicStaticFinalFlag/][genModel.getImportedName('java.lang.String')/] eNAME = "[genPackage.getPackageName()/]";[genModel.getNonNLS()/] - - /** - * The package namespace URI. - * - * - * @generated - */ - [publicStaticFinalFlag/][genModel.getImportedName('java.lang.String')/] eNS_URI = "[genPackage.getNSURI()/]";[genModel.getNonNLS()/] - - /** - * The package namespace name. - * - * - * @generated - */ - [publicStaticFinalFlag/][genModel.getImportedName('java.lang.String')/] eNS_PREFIX = "[genPackage.getNSName()/]";[genModel.getNonNLS()/] - [if (genPackage.isContentType())] - - /** - * The package content type ID. - * - * - * @generated - */ - [publicStaticFinalFlag/][genModel.getImportedName('java.lang.String')/] eCONTENT_TYPE = "[genPackage.contentTypeIdentifier/]";[genModel.getNonNLS()/] - [/if] - - /** - * The singleton instance of the package. - * - * - * @generated - */ - [publicStaticFinalFlag/][genPackage.getPackageInterfaceName()/] eINSTANCE = [genPackage.getQualifiedPackageClassName()/].init(); - - [for (genClassifier : GenClassifier | genPackage.getOrderedGenClassifiers())] - /** - [if (genClassifier.oclIsKindOf(GenClass))] - [let genClass : GenClass = genClassifier.oclAsType(GenClass)] - [if (not genClass.isInterface())] - * The meta object id for the '{@link [genClass.getQualifiedClassName()/] [genClass.getFormattedName()/]}' class. - * - * - * @see [genClass.getQualifiedClassName()/] - [else] - * The meta object id for the '{@link [genClass.getQualifiedInterfaceName()/] [genClass.getFormattedName()/]}' class. - * - * - * @see [genClass.getQualifiedInterfaceName()/] - [/if] - [/let] - [else][if (genClassifier.oclIsKindOf(GenEnum))] - [let genEnum : GenEnum = genClassifier.oclAsType(GenEnum)] - * The meta object id for the '{@link [genEnum.getQualifiedName()/] [genEnum.getFormattedName()/]}' enum. - * - * - * @see [genEnum.getQualifiedName()/] - [/let] - [else][if (genClassifier.oclIsKindOf(GenDataType))] - [let genDataType : GenDataType = genClassifier.oclAsType(GenDataType)] - * The meta object id for the '[genDataType.getFormattedName()/]' data type. - * - * - [if (not genDataType.isPrimitiveType() and not genDataType.isArrayType())] - * @see [genDataType.getRawInstanceClassName()/] - [/if] - [/let] - [/if][/if][/if] - * @see [genPackage.getQualifiedPackageClassName()/]#get[genClassifier.getClassifierAccessorName()/]() - * @generated - */ - [publicStaticFinalFlag/]int [genPackage.getClassifierID(genClassifier)/] = [genPackage.getClassifierValue(genClassifier)/]; - - [if (genClassifier.oclIsKindOf(GenClass))] - [let genClass : GenClass = genClassifier.oclAsType(GenClass)] - [for (genFeature : GenFeature | genClass.getAllGenFeatures())] - /** - * The feature id for the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/]. - * - * - * @generated - * @ordered - */ - [publicStaticFinalFlag/]int [genClass.getFeatureID(genFeature)/] = [genClass.getFeatureValue(genFeature)/]; - - [/for] - /** - * The number of structural features of the '[genClass.getFormattedName()/]' class. - * - * - * @generated - * @ordered - */ - [publicStaticFinalFlag/]int [genClass.getFeatureCountID()/] = [genClass.getFeatureCountValue()/]; - - [if (genModel.operationReflection)] - [for (genOperation : GenOperation | genClass.getAllGenOperations(false))] - [if (genClass.getOverrideGenOperation(genOperation) = null)] - /** - * The operation id for the '[genOperation.getFormattedName()/]' operation. - * - * - * @generated - * @ordered - */ - [publicStaticFinalFlag/]int [genClass.getOperationID(genOperation, false)/] = [genClass.getOperationValue(genOperation)/]; - - [/if] - [/for] - /** - * The number of operations of the '[genClass.getFormattedName()/]' class. - * - * - * @generated - * @ordered - */ - [publicStaticFinalFlag/]int [genClass.getOperationCountID()/] = [genClass.getOperationCountValue()/]; - - [/if] - [/let] - [/if] - [/for] -[/if] -[if (isImplementation)] - [if (genPackage.isLoadingInitialization())] - /** - * - * - * @generated - */ - protected String packageFilename = "[genPackage.getSerializedPackageFilename()/]";[genModel.getNonNLS()/] - - [/if] - [for (genClassifier : GenClassifier | genPackage.genClassifiers)] - /** - * - * - * @generated - */ - private [genClassifier.getImportedMetaType()/] [genClassifier.getClassifierInstanceName()/] = null; - - [/for] - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see [genPackage.getQualifiedPackageInterfaceName()/]#eNS_URI - * @see #init() - * @generated - */ - private [genPackage.getPackageClassName()/]() { - super(eNS_URI, [genPackage.getQualifiedEFactoryInstanceAccessor()/]); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link [genPackage.getImportedPackageInterfaceName()/]#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - [if (not genPackage.isLoadedInitialization())] - * @see #createPackageContents() - * @see #initializePackageContents() - [/if] - * @generated - */ - public static [genPackage.getImportedPackageInterfaceName()/] init() { - if (isInited) return ([genPackage.getImportedPackageInterfaceName()/])[genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE.getEPackage([genPackage.getImportedPackageInterfaceName()/].eNS_URI); - - [if (genModel.runtimePlatform = GenRuntimePlatform::GWT)] - initializeRegistryHelpers(); - - [/if] - // Obtain or create and register package - [genPackage.getPackageClassName()/] the[genPackage.getBasicPackageName()/] = ([genPackage.getPackageClassName()/])([genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE.get(eNS_URI) instanceof [genPackage.getPackageClassName()/] ? [genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE.get(eNS_URI) : new [genPackage.getPackageClassName()/]()); - - isInited = true; - - [if (genPackage.getPackageSimpleDependencies()->notEmpty())] - // Initialize simple dependencies - [for (dep : GenPackage | genPackage.getPackageSimpleDependencies())] - [dep.getImportedPackageInterfaceName()/].eINSTANCE.eClass(); - [/for] - - [/if] - [if (genPackage.getPackageInterDependencies()->notEmpty())] - // Obtain or create and register interdependencies - [for (interdep : GenPackage | genPackage.getPackageInterDependencies())] - [interdep.getImportedPackageClassName()/] [genPackage.getPackageInstanceVariable(interdep)/] = ([interdep.getImportedPackageClassName()/])([genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE.getEPackage([interdep.getImportedPackageInterfaceName()/].eNS_URI) instanceof [interdep.getImportedPackageClassName()/] ? [genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE.getEPackage([interdep.getImportedPackageInterfaceName()/].eNS_URI) : [interdep.getImportedPackageInterfaceName()/].eINSTANCE); - [/for] - - [/if] - [if (genPackage.isLoadedInitialization() or genPackage.getPackageLoadInterDependencies()->notEmpty())] - // Load packages - [if (genPackage.isLoadingInitialization())] - the[genPackage.getBasicPackageName()/].loadPackage(); - [/if] - [for (interdep : GenPackage | genPackage.getPackageLoadInterDependencies())] - [if (interdep.isLoadingInitialization())] - [genPackage.getPackageInstanceVariable(interdep)/].loadPackage(); - [/if] - [/for] - - [/if] - [if (not genPackage.isLoadedInitialization() or genPackage.getPackageBuildInterDependencies()->notEmpty())] - // Create package meta-data objects - [if (not genPackage.isLoadedInitialization())] - the[genPackage.getBasicPackageName()/].createPackageContents(); - [/if] - [for (interdep : GenPackage | genPackage.getPackageBuildInterDependencies())] - [genPackage.getPackageInstanceVariable(interdep)/].createPackageContents(); - [/for] - - // Initialize created meta-data - [if (not genPackage.isLoadedInitialization())] - the[genPackage.getBasicPackageName()/].initializePackageContents(); - [/if] - [for (interdep : GenPackage | genPackage.getPackageBuildInterDependencies())] - [genPackage.getPackageInstanceVariable(interdep)/].initializePackageContents(); - [/for] - - [/if] - [if (genPackage.isLoadedInitialization() or genPackage.getPackageLoadInterDependencies()->notEmpty())] - // Fix loaded packages - [if (genPackage.isLoadedInitialization())] - the[genPackage.getBasicPackageName()/].fixPackageContents(); - [/if] - [for (interdep : GenPackage | genPackage.getPackageLoadInterDependencies())] - [genPackage.getPackageInstanceVariable(interdep)/].fixPackageContents(); - [/for] - - [/if] - [if (genPackage.hasConstraints())] - // Register package validator - [genModel.getImportedName('org.eclipse.emf.ecore.EValidator')/].Registry.INSTANCE.put - (the[genPackage.getBasicPackageName()/], - new [genModel.getImportedName('org.eclipse.emf.ecore.EValidator')/].Descriptor() - { - public [genModel.getImportedName('org.eclipse.emf.ecore.EValidator')/] getEValidator() - { - return [genPackage.getImportedValidatorClassName()/].INSTANCE; - } - }); - - [/if] - [if (not genPackage.isEcorePackage())] - // Mark meta-data to indicate it can't be changed - the[genPackage.getBasicPackageName()/].freeze(); - - [/if] - - // Update the registry and return the package - [genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE.put([genPackage.getImportedPackageInterfaceName()/].eNS_URI, the[genPackage.getBasicPackageName()/]); - return the[genPackage.getBasicPackageName()/]; - } - [if (genModel.runtimePlatform = GenRuntimePlatform::GWT)] - - /** - * - * - * @generated - */ - public static void initializeRegistryHelpers() { - [for (genClassifier : GenClassifier | genPackage.genClassifiers)] - [if (genClassifier.oclIsKindOf(GenClass))] - [let genClass : GenClass = genClassifier.oclAsType(GenClass)] - [if (not genClass.dynamic)] - [genModel.getImportedName('org.eclipse.emf.common.util.Reflect')/].register - ([if (genClass.isMapEntry())][genClass.getImportedClassName()/][else][genClass.getRawImportedInterfaceName()/][/if].class, - new [genModel.getImportedName('org.eclipse.emf.common.util.Reflect')/].Helper() - { - public boolean isInstance(Object instance) - { - return instance instanceof [if (genClass.isMapEntry())][genClass.getImportedClassName()/][else][genClass.getRawImportedInterfaceName()/][genClass.getInterfaceWildTypeArguments()/][/if]; - } - - public Object newArrayInstance(int size) - { - return new [if (genClass.isMapEntry())][genClass.getImportedClassName()/][else][genClass.getRawImportedInterfaceName()/][/if]['[size]'/]; - } - }); - [/if] - [/let] - [else][if (genClassifier.oclIsKindOf(GenDataType))] - [let genDataType : GenDataType = genClassifier.oclAsType(GenDataType)] - [if (not genDataType.isPrimitiveType() and not genDataType.isObjectType())] - [genModel.getImportedName('org.eclipse.emf.common.util.Reflect')/].register - ([genDataType.getRawImportedInstanceClassName()/].class, - new [genModel.getImportedName('org.eclipse.emf.common.util.Reflect')/].Helper() { - public boolean isInstance(Object instance) { - return instance instanceof [genDataType.getImportedWildcardInstanceClassName()/]; - } - - public Object newArrayInstance(int size) { - [if (genDataType.isArrayType())] - [let componentType :String = genDataType.getRawImportedInstanceClassName().replaceAll('(?:\\[\\])+$', '')] - [let indices : String = genDataType.getRawImportedInstanceClassName().replaceAll('.*(?:\\[\\])+$', '$1')] - return new [componentType/]['[size]'/][indices/]; - [/let] - [/let] - [else] - return new [genDataType.getRawImportedInstanceClassName()/]['[size]'/]; - [/if] - } - }); - [/if] - [/let] - [/if][/if] - [/for] - } - - /** - * - * - * @generated - */ - public static class WhiteList implements [genModel.getImportedName('com.google.gwt.user.client.rpc.IsSerializable')/], EBasicWhiteList { - [for (genClassifier : GenClassifier | genPackage.genClassifiers)] - [if (genClassifier.oclIsKindOf(GenClass))] - [let genClass : GenClass = genClassifier.oclAsType(GenClass)] - [if (not genClass.dynamic)] - /** - * - * - * @generated - */ - protected [if (genClass.isMapEntry())][genClass.getImportedClassName()/][else][genClass.getImportedWildcardInstanceClassName()/][/if] [genClass.getSafeUncapName()/]; - - [/if] - [/let] - [else][if (genClassifier.oclIsKindOf(GenDataType))] - [let genDataType : GenDataType = genClassifier.oclAsType(GenDataType)] - [if (not genDataType.isObjectType() and genDataType.isSerializable())] - /** - * - * - * @generated - */ - protected [genDataType.getImportedWildcardInstanceClassName()/] [genDataType.getSafeUncapName()/]; - - [/if] - [/let] - [/if][/if] - [/for] - } - [/if] - -[/if] -[if (isInterface)][comment TODO REMOVE THIS BOGUS EMPTY LINE /] - -[/if] -[for (genClassifier : GenClassifier | genPackage.genClassifiers)] - [if (isInterface)] - /** - [if (genClassifier.oclIsKindOf(GenClass))] - [let genClass : GenClass = genClassifier.oclAsType(GenClass)] - * Returns the meta object for class '{@link [genClass.getQualifiedInterfaceName()/] [genClass.getFormattedName()/]}'. - * - * - * @return the meta object for class '[genClass.getFormattedName()/]'. - * @see [genClass.getQualifiedInterfaceName()/] - [if (not genModel.suppressEMFModelTags and (genClass.isExternalInterface() or genClass.dynamic))] - [let modelInfoLines : Sequence(String) = genClass.getModelInfo().tokenize(genModel.getLineDelimiter() + '\r')] - [if (modelInfoLines->isEmpty())] - * @model - [else] - * @model [modelInfoLines->sep(genModel.getLineDelimiter() + '\t * ')/] - [/if] - [/let] - [/if] - [/let] - [else][if (genClassifier.oclIsKindOf(GenEnum))] - [let genEnum : GenEnum = genClassifier.oclAsType(GenEnum)] - * Returns the meta object for enum '{@link [genEnum.getQualifiedName()/] [genEnum.getFormattedName()/]}'. - * - * - * @return the meta object for enum '[genEnum.getFormattedName()/]'. - * @see [genEnum.getQualifiedName()/] - [/let] - [else][if (genClassifier.oclIsKindOf(GenDataType))] - [let genDataType : GenDataType = genClassifier.oclAsType(GenDataType)] - [if (genDataType.isPrimitiveType() or genDataType.isArrayType())] - * Returns the meta object for data type '[genDataType.getFormattedName()/]'. - [else] - * Returns the meta object for data type '{@link [genDataType.getRawInstanceClassName()/] [genDataType.getFormattedName()/]}'. - [/if] - * - * - * @return the meta object for data type '[genDataType.getFormattedName()/]'. - [if (not genDataType.isPrimitiveType() and not genDataType.isArrayType())] - * @see [genDataType.getRawInstanceClassName()/] - [/if] - [if (not genModel.suppressEMFModelTags)] - [let modelInfoLines : Sequence(String) = genDataType.getModelInfo().tokenize(genModel.getLineDelimiter() + '\r')] - [if (modelInfoLines->isEmpty())] - * @model - [else] - * @model [modelInfoLines->sep(genModel.getLineDelimiter() + '\t * ')/] - [/if] - [/let] - [/if] - [/let] - [/if][/if][/if] - * @generated - */ - [else] - /** - * - * - * @generated - */ - [/if] - [if (isImplementation)] - public [genClassifier.getImportedMetaType()/] get[genClassifier.getClassifierAccessorName()/]() { - [if (genPackage.isLoadedInitialization())] - if ([genClassifier.getClassifierInstanceName()/] == null) { - [genClassifier.getClassifierInstanceName()/] = ([genClassifier.getImportedMetaType()/])[genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE.getEPackage([genPackage.getImportedPackageInterfaceName()/].eNS_URI).getEClassifiers().get([genPackage.getLocalClassifierIndex(genClassifier)/]); - } - [/if] - return [genClassifier.getClassifierInstanceName()/]; - } - - [else] - [genClassifier.getImportedMetaType()/] get[genClassifier.getClassifierAccessorName()/](); - - [/if] - [if (genClassifier.oclIsKindOf(GenClass))] - [let genClass : GenClass = genClassifier.oclAsType(GenClass)] - [for (genFeature : GenFeature | genClass.genFeatures)] - [if (isInterface)] - /** - * Returns the meta object for the [genFeature.getFeatureKind()/] '{@link [genClass.getQualifiedInterfaceName()/][if (not genClass.isMapEntry() and not genFeature.isSuppressedGetVisibility())]#[genFeature.getGetAccessor()/][/if] [genFeature.getFormattedName()/]}'. - * - * - * @return the meta object for the [genFeature.getFeatureKind()/] '[genFeature.getFormattedName()/]'. - * @see [genClass.getQualifiedInterfaceName()/][if (not genClass.isMapEntry() and not genFeature.isSuppressedGetVisibility())]#[genFeature.getGetAccessor()/]()[/if] - * @see #get[genClass.getClassifierAccessorName()/]() - * @generated - */ - [else] - /** - * - * - * @generated - */ - [/if] - [if (isImplementation)] - public [genFeature.getImportedMetaType()/] get[genFeature.getFeatureAccessorName()/]() { - [if (not genPackage.isLoadedInitialization())] - return ([genFeature.getImportedMetaType()/])[genClass.getClassifierInstanceName()/].getEStructuralFeatures().get([genClass.getLocalFeatureIndex(genFeature)/]); - [else] - return ([genFeature.getImportedMetaType()/])get[genClassifier.getClassifierAccessorName()/]().getEStructuralFeatures().get([genClass.getLocalFeatureIndex(genFeature)/]); - [/if] - } - [else] - [genFeature.getImportedMetaType()/] get[genFeature.getFeatureAccessorName()/](); - [/if] - - [/for] - [if (genModel.operationReflection)] - [for (genOperation : GenOperation | genClass.genOperations)] - [if (isInterface)] - /** - * Returns the meta object for the '{@link [genClass.getQualifiedInterfaceName()/]#[genOperation.getName()/]([genOperation.getParameterTypes(', ')/]) [genOperation.getFormattedName()/]}' operation. - * - * - * @return the meta object for the '[genOperation.getFormattedName()/]' operation. - * @see [genClass.getQualifiedInterfaceName()/]#[genOperation.getName()/]([genOperation.getParameterTypes(', ')/]) - * @generated - */ - [else] - /** - * - * - * @generated - */ - [/if] - [if (isImplementation)] - public [genOperation.getImportedMetaType()/] get[genOperation.getOperationAccessorName()/]() { - [if (not genPackage.isLoadedInitialization())] - return [genClass.getClassifierInstanceName()/].getEOperations().get([genClass.getLocalOperationIndex(genOperation)/]); - [else] - return get[genClassifier.getClassifierAccessorName()/]().getEOperations().get([genClass.getLocalOperationIndex(genOperation)/]); - [/if] - } - [else] - [genOperation.getImportedMetaType()/] get[genOperation.getOperationAccessorName()/](); - [/if] - - [/for] - [/if] - [/let] - [/if] -[/for] -[if (isInterface)] - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ -[else] - /** - * - * - * @generated - */ -[/if] -[if (isImplementation)] - public [genPackage.getImportedFactoryInterfaceName()/] get[genPackage.getFactoryName()/]() { - return ([genPackage.getImportedFactoryInterfaceName()/])getEFactoryInstance(); - } -[else] - [genPackage.getFactoryInterfaceName()/] get[genPackage.getFactoryName()/](); -[/if] - -[if (isImplementation)] - [if (not genPackage.isLoadedInitialization())] - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) return; - isCreated = true; - - [if (genPackage.genClasses->notEmpty())] - // Create classes and their features - [for (genClass : GenClass | genPackage.genClasses) separator (genModel.getLineDelimiter())] - [genClass.getClassifierInstanceName()/] = create[genClass.getMetaType()/]([genClass.getClassifierID()/]); - [for (genFeature : GenFeature | genClass.genFeatures)] - create[genFeature.getMetaType()/]([genClass.getClassifierInstanceName()/], [genClass.getFeatureID(genFeature)/]); - [/for] - [if (genModel.operationReflection)] - [for (genOperation : GenOperation | genClass.genOperations)] - createEOperation([genClass.getClassifierInstanceName()/], [genClass.getOperationID(genOperation, false)/]); - [/for] - [/if] - [/for] - [/if] - [if (genPackage.genEnums->notEmpty())] - - // Create enums - [for (genEnum : GenEnum | genPackage.genEnums)] - [genEnum.getClassifierInstanceName()/] = createEEnum([genEnum.getClassifierID()/]); - [/for] - [/if] - [if (genPackage.genDataTypes->notEmpty())] - - // Create data types - [for (genDataType : GenDataType | genPackage.genDataTypes)] - [genDataType.getClassifierInstanceName()/] = createEDataType([genDataType.getClassifierID()/]); - [/for] - [/if] - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - [if (genPackage.getPackageInitializationDependencies()->notEmpty())] - - // Obtain other dependent packages - [for (dep : GenPackage | genPackage.getPackageInitializationDependencies())] - [dep.getImportedPackageInterfaceName()/] [genPackage.getPackageInstanceVariable(dep)/] = ([dep.getImportedPackageInterfaceName()/])[genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE.getEPackage([dep.getImportedPackageInterfaceName()/].eNS_URI); - [/for] - [/if] - [if (genPackage.getSubGenPackages()->notEmpty())] - - // Add subpackages - [for (sub : GenPackage | genPackage.getSubGenPackages())] - getESubpackages().add([genPackage.getPackageInstanceVariable(sub)/]); - [/for] - [/if] - [if (genPackage.genClasses->notEmpty())] - [comment { boolean firstOperationAssignment = true; int maxTypeParameterAssignment = 0;/] - [if (genModel.useGenerics())] - - // Create type parameters - [for (genClassifier : GenClassifier | genPackage.genClassifiers)] - [for (genTypeParameter : GenTypeParameter | genClassifier.genTypeParameters)] - [if (genTypeParameter.ecoreTypeParameter.eBounds->notEmpty() or genTypeParameter.isUsed())] - [genModel.getImportedName('org.eclipse.emf.ecore.ETypeParameter')/] [genClassifier.getClassifierInstanceName()/]_[genTypeParameter.getName()/] = addETypeParameter([genClassifier.getClassifierInstanceName()/], "[genTypeParameter.getName()/]");[genModel.getNonNLS()/] - [else] - addETypeParameter([genClassifier.getClassifierInstanceName()/], "[genTypeParameter.getName()/]");[genModel.getNonNLS()/] - [/if] - [/for] - [/for] - [/if] - - [if (genModel.useGenerics())] - - // Set bounds for type parameters[genPackage.resetMaxGenericTypeAssignment()/][genPackage.resetGenOperationPrefix()/] - [for (genClassifier : GenClassifier |genPackage.genClassifiers)] - [for (genTypeParameter : GenTypeParameter | genClassifier.genTypeParameters)] - [for (bound : EGenericType | genTypeParameter.ecoreTypeParameter.eBounds)] - [genPackage.prefix(0)/]g1 = createEGenericType([bound.type(genModel, genPackage)/]); - [for (eGenericType : EGenericType | bound.eAllContents(EGenericType))] - [comment]<%for (InformationIterator i=new InformationIterator(bound); i.hasNext(); ) { Information info = i.next(); String prefix = ""; if (maxGenericTypeAssignment <= eGenericType.depth()) { ++maxGenericTypeAssignment; prefix = genModel.getImportedName("org.eclipse.emf.ecore.EGenericType") + " "; }%>[/comment] - [genPackage.prefix(eGenericType.depth())/]g[eGenericType.depth() + 1/] = createEGenericType([eGenericType.type(genModel, genPackage)/]); - g[eGenericType.depth()/].[eGenericType.accessor()/](g[eGenericType.depth() + 1/]); - [/for] - [genClassifier.getClassifierInstanceName()/]_[genTypeParameter.getName()/].getEBounds().add(g1); - [/for] - [/for] - [/for] - [/if] - - // Add supertypes to classes - [for (genClass : GenClass | genPackage.genClasses)] - [if (not genClass.hasGenericSuperTypes())] - [for (baseGenClass : GenClass | genClass.getBaseGenClasses())] - [genClass.getClassifierInstanceName()/].getESuperTypes().add([genPackage.getPackageInstanceVariable(baseGenClass.genPackage)/].get[baseGenClass.getClassifierAccessorName()/]()); - [/for] - [else] - [for (superType : EGenericType | genClass.ecoreClass.eGenericSuperTypes)] - [genPackage.prefix(0)/]g1 = createEGenericType([superType.type(genModel, genPackage)/]); - [for (eGenericType : EGenericType | superType.eAllContents(EGenericType))] - [comment]<%for (InformationIterator i=new InformationIterator(superType); i.hasNext(); ) { Information info = i.next(); String prefix = ""; if (maxGenericTypeAssignment <= eGenericType.depth()) { ++maxGenericTypeAssignment; prefix = genModel.getImportedName("org.eclipse.emf.ecore.EGenericType") + " "; }%>[/comment] - [genPackage.prefix(eGenericType.depth())/]g[eGenericType.depth() + 1/] = createEGenericType([eGenericType.type(genModel, genPackage)/]); - g[eGenericType.depth()/].[eGenericType.accessor()/](g[eGenericType.depth() + 1/]); - [/for] - [genClass.getClassifierInstanceName()/].getEGenericSuperTypes().add(g1); - [/for] - [/if] - [/for] - - // Initialize classes[if (genModel.operationReflection)], features, and operations; add parameters[else] and features; add operations and parameters[/if] - [for (genClass : GenClass | genPackage.genClasses) separator(genModel.getLineDelimiter())] - [let hasInstanceTypeName : Boolean = genModel.useGenerics() and genClass.ecoreClass.instanceTypeName <> null and genClass.ecoreClass.instanceTypeName.contains('<')] - initEClass([genClass.getClassifierInstanceName()/], [if (genClass.dynamic)]null[else][genClass.getRawImportedInterfaceName()/].class[/if], "[genClass.getName()/]", [genClass.getAbstractFlag()/], [genClass.getInterfaceFlag()/], [genClass.getGeneratedInstanceClassFlag()/][if (hasInstanceTypeName)], "[genClass.ecoreClass.instanceTypeName/]"[/if]);[genModel.getNonNLS()/][if (hasInstanceTypeName)][genModel.getNonNLS(2)/][/if] - [for (genFeature : GenFeature |genClass.genFeatures)] - [if (genFeature.hasGenericType())] - [let genericType : EGenericType = genFeature.ecoreFeature.eGenericType] - [genPackage.prefix(0)/]g1 = createEGenericType([genericType.type(genModel, genPackage)/]); - [for (eGenericType : EGenericType | genericType.eAllContents(EGenericType))] - [comment]<%for (InformationIterator i=new InformationIterator(genFeature.getEcoreFeature().getEGenericType()); i.hasNext(); ) { Information info = i.next(); String prefix = ""; if (maxGenericTypeAssignment <= eGenericType.depth()) { ++maxGenericTypeAssignment; prefix = genModel.getImportedName("org.eclipse.emf.ecore.EGenericType") + " "; }%>[/comment] - [genPackage.prefix(eGenericType.depth())/]g[eGenericType.depth() + 1/] = createEGenericType([eGenericType.type(genModel, genPackage)/]); - g[eGenericType.depth()/].[eGenericType.accessor()/](g[eGenericType.depth() + 1/]); - [/for] - [/let] - [/if] - [if (genFeature.isReferenceType())] - [let reverse : String = if (genFeature.getReverse() = null) then 'null' else genPackage.getPackageInstanceVariable(genFeature.getReverse().getGenPackage()) + '.get' + genFeature.getReverse().getFeatureAccessorName() + '()' endif] - initEReference(get[genFeature.getFeatureAccessorName()/](), [if (genFeature.hasGenericType())]g1[else][genPackage.getPackageInstanceVariable(genFeature.getTypeGenPackage())/].get[genFeature.getTypeClassifierAccessorName()/]()[/if], [reverse/], "[genFeature.getName()/]", [genFeature.getDefaultValue()/], [genFeature.getLowerBound()/], [genFeature.getUpperBound()/], [genFeature.getContainerClass()/], [genFeature.getTransientFlag()/], [genFeature.getVolatileFlag()/], [genFeature.getChangeableFlag()/], [genFeature.getContainmentFlag()/], [genFeature.getResolveProxiesFlag()/], [genFeature.getUnsettableFlag()/], [genFeature.getUniqueFlag()/], [genFeature.getDerivedFlag()/], [genFeature.getOrderedFlag()/]);[genModel.getNonNLS()/][genModel.getNonNLS(genFeature.getDefaultValue(), 2)/] - [for (keyFeature : GenFeature |genFeature.getKeys())] - get[genFeature.getFeatureAccessorName()/]().getEKeys().add([genPackage.getPackageInstanceVariable(keyFeature.getGenPackage())/].get[keyFeature.getFeatureAccessorName()/]()); - [/for] - [/let] - [else] - initEAttribute(get[genFeature.getFeatureAccessorName()/](), [if (genFeature.hasGenericType())]g1[else][genPackage.getPackageInstanceVariable(genFeature.getTypeGenPackage())/].get[genFeature.getTypeClassifierAccessorName()/]()[/if], "[genFeature.getName()/]", [genFeature.getDefaultValue()/], [genFeature.getLowerBound()/], [genFeature.getUpperBound()/], [genFeature.getContainerClass()/], [genFeature.getTransientFlag()/], [genFeature.getVolatileFlag()/], [genFeature.getChangeableFlag()/], [genFeature.getUnsettableFlag()/], [genFeature.getIDFlag()/], [genFeature.getUniqueFlag()/], [genFeature.getDerivedFlag()/], [genFeature.getOrderedFlag()/]);[genModel.getNonNLS()/][genModel.getNonNLS(genFeature.getDefaultValue(), 2)/] - [/if] - [/for] - [for (genOperation : GenOperation | genClass.genOperations)] - - [if (genModel.useGenerics())] - [genOperation.prefix()/][if (genModel.operationReflection)]initEOperation(get[genOperation.getOperationAccessorName()/]()[else]addEOperation([genClass.getClassifierInstanceName()/][/if], [if (genOperation.isVoid() or genOperation.hasGenericType())]null[else][genPackage.getPackageInstanceVariable(genOperation.getTypeGenPackage())/].get[genOperation.getTypeClassifierAccessorName()/]()[/if], "[genOperation.getName()/]", [genOperation.getLowerBound()/], [genOperation.getUpperBound()/], [genOperation.getUniqueFlag()/], [genOperation.getOrderedFlag()/]);[genModel.getNonNLS()/] - [else][if (not genOperation.isVoid())] - [if (not genOperation.ecoreOperation.ordered or not genOperation.ecoreOperation.unique)] - [genPackage.requireAddEOperation()/][genOperation.prefix()/][if (genModel.operationReflection)]initEOperation(get[genOperation.getOperationAccessorName()/]()[else]addEOperation([genClass.getClassifierInstanceName()/][/if], [genPackage.getPackageInstanceVariable(genOperation.getTypeGenPackage())/].get[genOperation.getTypeClassifierAccessorName()/](), "[genOperation.getName()/]", [genOperation.getLowerBound()/], [genOperation.getUpperBound()/], [genOperation.getUniqueFlag()/], [genOperation.getOrderedFlag()/]);[genModel.getNonNLS()/] - [else] - [genOperation.prefix()/][if (genModel.operationReflection)]initEOperation(get[genOperation.getOperationAccessorName()/]()[else]addEOperation([genClass.getClassifierInstanceName()/][/if], [genPackage.getPackageInstanceVariable(genOperation.getTypeGenPackage())/].get[genOperation.getTypeClassifierAccessorName()/](), "[genOperation.getName()/]", [genOperation.getLowerBound()/], [genOperation.getUpperBound()/]);[genModel.getNonNLS()/] - [/if] - [else] - [genOperation.prefix()/][if (genModel.operationReflection)]initEOperation(get[genOperation.getOperationAccessorName()/]()[else]addEOperation([genClass.getClassifierInstanceName()/][/if], null, "[genOperation.getName()/]");[genModel.getNonNLS()/] - [/if][/if] - [if (genModel.useGenerics())] - [for (genTypeParameter : GenTypeParameter | genOperation.genTypeParameters)][comment @TODO remove let typeParameterVariable /] - [let typeParameterVariable : String = - if (genTypeParameter.ecoreTypeParameter.eBounds->notEmpty() or genTypeParameter.isUsed()) then - if (i = 1) then - genModel.getImportedName('org.eclipse.emf.ecore.ETypeParameter') + ' t' + i + ' = ' - else - 't' + i + ' = ' - endif - else - '' - endif - ] - [comment for (ListIterator t=genOperation.getGenTypeParameters().listIterator(); t.hasNext(); ) { - GenTypeParameter genTypeParameter = t.next(); - String typeParameterVariable = ""; - if (genTypeParameter.getEcoreTypeParameter().getEBounds()->notEmpty() || genTypeParameter.isUsed()) { - if (maxTypeParameterAssignment <= t.previousIndex()) { - ++maxTypeParameterAssignment; - typeParameterVariable = genModel.getImportedName("org.eclipse.emf.ecore.ETypeParameter") + " t" + t.nextIndex() + " = "; - } else { - typeParameterVariable = "t" + t.nextIndex() + " = "; - } - } /] - [typeParameterVariable/]addETypeParameter(op, "[genTypeParameter.getName()/]");[genModel.getNonNLS()/] - [for (typeParameter : EGenericType | genTypeParameter.ecoreTypeParameter.eBounds)] -[comment <%for (InformationIterator i=new InformationIterator(typeParameter); i.hasNext(); ) { - Information info = i.next(); String typePrefix = ""; - if (maxGenericTypeAssignment <= eGenericType.depth()) { - ++maxGenericTypeAssignment; - typePrefix = genModel.getImportedName("org.eclipse.emf.ecore.EGenericType") + " "; - }%>/] - [for (eGenericType : EGenericType | Sequence{typeParameter}->union(typeParameter.eAllContents(EGenericType)))] - [genPackage.typePrefix(eGenericType.depth())/]g[eGenericType.depth() + 1/] = createEGenericType([eGenericType.type(genModel, genPackage)/]); - [if (eGenericType.depth() > 0)] - g[eGenericType.depth()/].[eGenericType.accessor()/](g[eGenericType.depth() + 1/]); - [/if] - [/for] - t[i + 1/].getEBounds().add(g1); - [/for] - [/let] - [/for] - [/if] - [for (genParameter : GenParameter | genOperation.genParameters)] - [if (genParameter.hasGenericType())] - [for (eGenericType : EGenericType | genParameter.ecoreParameter.eAllContents(EGenericType))] - [comment <%for (InformationIterator i=new InformationIterator(genParameter.getEcoreParameter().getEGenericType()); i.hasNext(); ) { Information info = i.next(); String typePrefix = ""; if (maxGenericTypeAssignment <= eGenericType.depth()) { ++maxGenericTypeAssignment; typePrefix = genModel.getImportedName("org.eclipse.emf.ecore.EGenericType") + " "; }%>/] - [genPackage.typePrefix(eGenericType.depth())/]g[eGenericType.depth() + 1/] = createEGenericType([eGenericType.type(genModel, genPackage)/]); - [if (eGenericType.depth() > 0)] - g[eGenericType.depth()/].[eGenericType.accessor()/](g[eGenericType.depth() + 1/]); - [/if] - [/for] - [/if] - [if (genModel.useGenerics())] - addEParameter(op, [if (genParameter.hasGenericType())]g1[else][genPackage.getPackageInstanceVariable(genParameter.getTypeGenPackage())/].get[genParameter.getTypeClassifierAccessorName()/]()[/if], "[genParameter.getName()/]", [genParameter.getLowerBound()/], [genParameter.getUpperBound()/], [genParameter.getUniqueFlag()/], [genParameter.getOrderedFlag()/]);[genModel.getNonNLS()/] - [else][if (not genParameter.ecoreParameter.ordered or not genParameter.ecoreParameter.unique)] - [genPackage.requireAddEParameter()/]addEParameter(op, [if (genParameter.hasGenericType())]g1[else][genPackage.getPackageInstanceVariable(genParameter.getTypeGenPackage())/].get[genParameter.getTypeClassifierAccessorName()/]()[/if], "[genParameter.getName()/]", [genParameter.getLowerBound()/], [genParameter.getUpperBound()/], [genParameter.getUniqueFlag()/], [genParameter.getOrderedFlag()/]);[genModel.getNonNLS()/] - [else] - addEParameter(op, [if (genParameter.hasGenericType())]g1[else][genPackage.getPackageInstanceVariable(genParameter.getTypeGenPackage())/].get[genParameter.getTypeClassifierAccessorName()/]()[/if], "[genParameter.getName()/]", [genParameter.getLowerBound()/], [genParameter.getUpperBound()/]);[genModel.getNonNLS()/] - [/if][/if] - [/for] - [if (genOperation.hasGenericExceptions())] - [for (genericExceptions : EGenericType | genOperation.ecoreOperation.eGenericExceptions)] - [for (eGenericType : EGenericType | genericExceptions.eAllContents(EGenericType)->flatten())] - [comment <%for (InformationIterator i=new InformationIterator(genericExceptions); i.hasNext(); ) { Information info = i.next(); String typePrefix = ""; if (maxGenericTypeAssignment <= eGenericType.depth()) { ++maxGenericTypeAssignment; typePrefix = genModel.getImportedName("org.eclipse.emf.ecore.EGenericType") + " "; }%>/] - [genPackage.typePrefix(eGenericType.depth())/]g[eGenericType.depth() + 1/] = createEGenericType([eGenericType.type(genModel, genPackage)/]); - [if (eGenericType.depth() > 0)] - g[eGenericType.depth()/].[eGenericType.accessor()/](g[eGenericType.depth() + 1/]); - [/if] - addEException(op, g[eGenericType.depth() + 1/]); - [/for] - [/for] - [else] - [for (genException : GenClassifier | genOperation.getGenExceptions())] - addEException(op, [genPackage.getPackageInstanceVariable(genException.genPackage)/].get[genException.getClassifierAccessorName()/]()); - [/for] - [/if] - [if (not genOperation.isVoid() and genOperation.hasGenericType())] - [for (eGenericType : EGenericType | Sequence{genOperation.ecoreOperation.eGenericType}->union(genOperation.ecoreOperation.eGenericType.eAllContents(EGenericType)))] - [comment]<%for (InformationIterator i=new InformationIterator(genOperation.getEcoreOperation().getEGenericType()); i.hasNext(); ) { Information info = i.next(); String typePrefix = ""; if (maxGenericTypeAssignment <= eGenericType.depth()) { ++maxGenericTypeAssignment; typePrefix = genModel.getImportedName("org.eclipse.emf.ecore.EGenericType") + " "; }%>[/comment] - [genPackage.typePrefix(eGenericType.depth())/]g[eGenericType.depth() + 1/] = createEGenericType([eGenericType.type(genModel, genPackage)/]); - [if (eGenericType.depth() > 0)] - g[eGenericType.depth()/].[eGenericType.accessor()/](g[eGenericType.depth() + 1/]); - [/if] - [/for] - initEOperation(op, g1); - [/if] - [/for][comment genOperation/] - [/let] - [/for] - [/if] - [if (genPackage.genEnums->notEmpty())] - - // Initialize enums and add enum literals - [for (genEnum : GenEnum | genPackage.genEnums) separator(genModel.getLineDelimiter())] - initEEnum([genEnum.getClassifierInstanceName()/], [genModel.getImportedName(genEnum.getQualifiedName())/].class, "[genEnum.getName()/]");[genModel.getNonNLS()/] - [for (genEnumLiteral : GenEnumLiteral |genEnum.genEnumLiterals)] - addEEnumLiteral([genEnum.getClassifierInstanceName()/], [if (genModel.getImportedName(genEnum.getQualifiedName()) = genEnum.getClassifierID())][genEnum.getQualifiedName()/][else][genModel.getImportedName(genEnum.getQualifiedName())/][/if].[genEnumLiteral.getEnumLiteralInstanceConstantName()/]); - [/for] - [/for] - [/if] - [if (genPackage.genDataTypes->notEmpty())] - - // Initialize data types - [for (genDataType : GenDataType | genPackage.genDataTypes)] - [let hasInstanceTypeName : Boolean = genModel.useGenerics() and genDataType.ecoreDataType.instanceTypeName <> null and genDataType.ecoreDataType.instanceTypeName.contains('<')] - initEDataType([genDataType.getClassifierInstanceName()/], [genDataType.getRawImportedInstanceClassName()/].class, "[genDataType.getName()/]", [genDataType.getSerializableFlag()/], [genDataType.getGeneratedInstanceClassFlag()/][if (hasInstanceTypeName)], "[genDataType.ecoreDataType.instanceTypeName/]"[/if]);[genModel.getNonNLS()/][if (hasInstanceTypeName)][genModel.getNonNLS(2)/][/if] - [/let] - [/for] - [/if] - [if (genPackage.getSuperGenPackage() = null)] - - // Create resource - createResource(eNS_URI); - [/if] - [if (not genPackage.isEcorePackage() and genPackage.getAnnotationSources()->notEmpty())] - - // Create annotations - [for (annotationSource : String |genPackage.getAnnotationSources())] - // [annotationSource/] - create[genPackage.getAnnotationSourceIdentifier(annotationSource)/]Annotations(); - [/for] - [/if] - } - - [for (annotationSource : String | genPackage.getAnnotationSources())] - /** - * Initializes the annotations for [annotationSource/]. - * - * - * @generated - */ - protected void create[genPackage.getAnnotationSourceIdentifier(annotationSource)/]Annotations() { - String source = [if (annotationSource = null)]null;[else]"[annotationSource/]";[genModel.getNonNLS()/][/if] - [for (eAnnotation : EAnnotation | genPackage.getAllAnnotations())] - [let annotationReferenceDataList : Sequence(Sequence(OclAny)) = eAnnotation.getReferenceData(genPackage)] - [comment] @TODO How? use collect(some transformation) on annotationSource creation -[if (annotationSource = null)][eAnnotation.source = null/][else][annotationSource = eAnnotation.source/][/if][/comment] - addAnnotation - ([genPackage.getAnnotatedModelElementAccessor(eAnnotation)/], - source, - new String['[]'/] - { - [eAnnotation.writeKeyValuePairs(genModel)/] - }[if (eAnnotation.hasReferenceData(genPackage))]);[else],[/if] - [if (not eAnnotation.hasReferenceData(genPackage))] - new [genModel.getImportedName('org.eclipse.emf.common.util.URI')/]['[]'/] - { - [for (annotationReferenceData : Sequence(OclAny) | annotationReferenceDataList) separator (',' + genModel.getNonNLS())] - [genModel.getImportedName('org.eclipse.emf.common.util.URI')/].createURI([if (annotationReferenceData->at(1) <> genPackage)][annotationReferenceData->at(1).oclAsType(GenPackage).getImportedPackageInterfaceName()/].[/if]eNS_URI).appendFragment("[annotationReferenceData->at(2)/]")[/for][genModel.getNonNLS()/] - }); - [/if] - [for (nestedEAnnotation : EAnnotation | genPackage.getAllNestedAnnotations(eAnnotation))] - [let nestedAnnotationSource : String = nestedEAnnotation.source] - [let depth : Integer = nestedEAnnotation.depth()] - [let nestedAnnotationReferenceDataList : Sequence(Sequence(OclAny)) = nestedEAnnotation.getReferenceData(genPackage)] - addAnnotation - ([genPackage.getAnnotatedModelElementAccessor(eAnnotation)/], - [depth/], - [if (nestedAnnotationSource = null)]null,[else]"[nestedAnnotationSource/]",[genModel.getNonNLS()/][/if] - new String['[]'/] - { - [nestedEAnnotation.writeKeyValuePairs(genModel)/] - }[if (nestedEAnnotation.hasReferenceData(genPackage))]);[else],[/if] - [if (not nestedEAnnotation.hasReferenceData(genPackage))] - new [genModel.getImportedName('org.eclipse.emf.common.util.URI')/]['[]'/] - { - [for (annotationReferenceData : Sequence(OclAny) | nestedAnnotationReferenceDataList) separator (',' + genModel.getNonNLS())] - [genModel.getImportedName('org.eclipse.emf.common.util.URI')/].createURI([if (annotationReferenceData->at(1) <> genPackage)][annotationReferenceData->at(1).oclAsType(GenPackage).getImportedPackageInterfaceName()/].[/if]eNS_URI).appendFragment("[annotationReferenceData->at(2)/]")[/for][genModel.getNonNLS()/] - }); - [/if] - [/let] - [/let] - [/let] - [/for] - [/let] - [/for] - } - - [/for] - [else] - [if (genPackage.isLoadingInitialization())] - /** - * - * - * @generated - */ - private boolean isLoaded = false; - - /** - * Laods the package and any sub-packages from their serialized form. - * - * - * @generated - */ - public void loadPackage() { - if (isLoaded) return; - isLoaded = true; - - [genModel.getImportedName('java.net.URL')/] url = getClass().getResource(packageFilename); - if (url == null) { - throw new RuntimeException("Missing serialized package: " + packageFilename);[genModel.getNonNLS()/] - } - [genModel.getImportedName('org.eclipse.emf.common.util.URI')/] uri = [genModel.getImportedName('org.eclipse.emf.common.util.URI')/].createURI(url.toString()); - [genModel.getImportedName('org.eclipse.emf.ecore.resource.Resource')/] resource = new [genModel.getImportedName('org.eclipse.emf.ecore.xmi.impl.EcoreResourceFactoryImpl')/]().createResource(uri); - try { - resource.load(null); - } - catch ([genModel.getImportedName('java.io.IOException')/] exception) { - throw new [genModel.getImportedName('org.eclipse.emf.common.util.WrappedException')/](exception); - } - initializeFromLoadedEPackage(this, ([genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/])resource.getContents().get(0)); - createResource(eNS_URI); - } - - [/if] - - /** - * - * - * @generated - */ - private boolean isFixed = false; - - /** - * Fixes up the loaded package, to make it appear as if it had been programmatically built. - * - * - * @generated - */ - public void fixPackageContents() { - if (isFixed) return; - isFixed = true; - fixEClassifiers(); - } - - /** - * Sets the instance class on the given classifier. - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - protected void fixInstanceClass([genModel.getImportedName('org.eclipse.emf.ecore.EClassifier')/] eClassifier) { - if (eClassifier.getInstanceClassName() == null) { - [let dynamicGenClasses : OrderedSet(GenClass) = genPackage.genClasses->select(c : GenClass | c.dynamic)] - [if (dynamicGenClasses->isEmpty())] - eClassifier.setInstanceClassName("[genPackage.getInterfacePackageName()/]." + eClassifier.getName());[genModel.getNonNLS()/] - setGeneratedClassName(eClassifier); - [else] - switch (eClassifier.getClassifierID()) { - [for (genClass : GenClass | dynamicGenClasses)] - [if (genClass.dynamic)] - case [genPackage.getClassifierID(genClass)/]: - [/if] - [/for] - { - break; - } - default: - { - eClassifier.setInstanceClassName("[genPackage.getInterfacePackageName()/]." + eClassifier.getName());[genModel.getNonNLS()/] - setGeneratedClassName(eClassifier); - break; - } - } - [/if] - [/let] - } - } - - [/if] - [if (needsAddEOperation())] - /** - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.emf.ecore.EOperation')/] addEOperation([genModel.getImportedName('org.eclipse.emf.ecore.EClass')/] owner, [genModel.getImportedName('org.eclipse.emf.ecore.EClassifier')/] type, String name, int lowerBound, int upperBound, boolean isUnique, boolean isOrdered) { - [genModel.getImportedName('org.eclipse.emf.ecore.EOperation')/] o = addEOperation(owner, type, name, lowerBound, upperBound); - o.setUnique(isUnique); - o.setOrdered(isOrdered); - return o; - } - - [/if][comment needsAddEOperation /] - [if (needsAddEParameter())] - /** - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.emf.ecore.EParameter')/] addEParameter([genModel.getImportedName('org.eclipse.emf.ecore.EOperation')/] owner, [genModel.getImportedName('org.eclipse.emf.ecore.EClassifier')/] type, String name, int lowerBound, int upperBound, boolean isUnique, boolean isOrdered) { - [genModel.getImportedName('org.eclipse.emf.ecore.EParameter')/] p = ecoreFactory.createEParameter(); - p.setEType(type); - p.setName(name); - p.setLowerBound(lowerBound); - p.setUpperBound(upperBound); - p.setUnique(isUnique); - p.setOrdered(isOrdered); - owner.getEParameters().add(p); - return p; - } - - [/if][comment needsAddEParameter /] -[/if][comment isImplementation) /] -[if (isInterface and genPackage.isLiteralsInterface())] - /** - * - * Defines literals for the meta objects that represent - *

    - *
  • each class,
  • - *
  • each feature of each class,
  • - [if (genModel.operationReflection)] - *
  • each operation of each class,
  • - [/if] - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - [if (isImplementation)]public [/if]interface Literals { - [for (genClassifier : GenClassifier | genPackage.genClassifiers)] - /** - [if (genClassifier.oclIsKindOf(GenClass))] - [let genClass : GenClass = genClassifier.oclAsType(GenClass)] - [if (not genClass.isInterface())] - * The meta object literal for the '{@link [genClass.getQualifiedClassName()/] [genClass.getFormattedName()/]}' class. - * - * - * @see [genClass.getQualifiedClassName()/] - [else] - * The meta object literal for the '{@link [genClass.getQualifiedInterfaceName()/] [genClass.getFormattedName()/]}' class. - * - * - * @see [genClass.getQualifiedInterfaceName()/] - [/if] - [/let] - [else][if (genClassifier.oclIsKindOf(GenEnum))] - [let genEnum : GenEnum = genClassifier.oclAsType(GenEnum)] - * The meta object literal for the '{@link [genEnum.getQualifiedName()/] [genEnum.getFormattedName()/]}' enum. - * - * - * @see [genEnum.getQualifiedName()/] - [/let] - [else][if (genClassifier.oclIsKindOf(GenDataType))] - [let genDataType : GenDataType = genClassifier.oclAsType(GenDataType)] - * The meta object literal for the '[genDataType.getFormattedName()/]' data type. - * - * - [if (not genDataType.isPrimitiveType() and not genDataType.isArrayType())] - * @see [genDataType.getRawInstanceClassName()/] - [/if] - [/let] - [/if][/if][/if] - * @see [genPackage.getQualifiedPackageClassName()/]#get[genClassifier.getClassifierAccessorName()/]() - * @generated - */ - [publicStaticFinalFlag/][genClassifier.getImportedMetaType()/] [genPackage.getClassifierID(genClassifier)/] = eINSTANCE.get[genClassifier.getClassifierAccessorName()/](); - - [if (genClassifier.oclIsKindOf(GenClass))] - [let genClass : GenClass = genClassifier.oclAsType(GenClass)] - [for (genFeature : GenFeature |genClass.genFeatures)] - /** - * The meta object literal for the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/] feature. - * - * - * @generated - */ - [publicStaticFinalFlag/][genFeature.getImportedMetaType()/] [genClass.getFeatureID(genFeature)/] = eINSTANCE.get[genFeature.getFeatureAccessorName()/](); - - [/for] - [if (genModel.operationReflection)] - [for (genOperation : GenOperation | genClass.genOperations)] - /** - * The meta object literal for the '[genOperation.getFormattedName()/]' operation. - * - * - * @generated - */ - [publicStaticFinalFlag/][genOperation.getImportedMetaType()/] [genClass.getOperationID(genOperation, false)/] = eINSTANCE.get[genOperation.getOperationAccessorName()/](); - - [/for] - [/if] - [/let] - [/if] - [/for] - } - -[/if] -} //[className/] -[/let][comment publicStaticFinalFlag /] -[/template] - -[query public packageClassPackageName(genPackage : GenPackage, isInterface : Boolean) : String = - if (isInterface and not genPackage.genModel.suppressInterfaces) then - genPackage.getReflectionPackageName() - else - genPackage.getClassPackageName() - endif -/] - -[query public packageClassName(genPackage : GenPackage, isImplementation : Boolean) : String = - if (isImplementation) then - genPackage.getPackageClassName() - else - genPackage.getPackageInterfaceName() - endif -/] - -[query public packageClassPath(genPackage : GenPackage, isInterface : Boolean, isImplementation : Boolean) : String - = genPackage.genModel.modelPath(genPackage.packageClassPackageName(isInterface), genPackage.packageClassName(isImplementation)) /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/Plugin.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/Plugin.mtl deleted file mode 100644 index 7ed0a52cb..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/Plugin.mtl +++ /dev/null @@ -1,155 +0,0 @@ -[comment encoding = UTF-8 /] -[module Plugin('http://www.eclipse.org/emf/2002/GenModel')/] - -[comment -/** - * - * - * Copyright (c) 2002-2004 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[template public plugin(genModel : GenModel) ? (genModel.hasModelPluginClass()) { packageName : String = genModel.getModelPluginPackageName(); className : String = genModel.getModelPluginClassName(); }] -[genModel.initializeImportManager(packageName, className)/] -[file (genModel.pluginFilePath(), false, 'UTF-8')] -[genModel.includeHeader()/] -package [genModel.getModelPluginPackageName()/]; -[comment]<%genModel.markImportLocation(stringBuffer, genPackage);%>[/comment] -[let content : String = genModel.pluginFileContent()] -[genModel.genSortedImports()/] -[content/] -[/let] -[/file] -[/template] - -[template protected pluginFileContent(genModel : GenModel)] -[genModel.addImport('org.eclipse.emf.common.EMFPlugin')/] -[genModel.addImport('org.eclipse.emf.common.util.ResourceLocator')/] - -/** - * This is the central singleton for the [genModel.modelName/] model plugin. - * - * - * @generated - */ -public final class [genModel.getModelPluginClassName()/] extends EMFPlugin -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - /** - * Keep track of the singleton. - * - * - * @generated - */ - public static final [genModel.getModelPluginClassName()/] INSTANCE = new [genModel.getModelPluginClassName()/](); - -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - /** - * Keep track of the singleton. - * - * - * @generated - */ - private static Implementation plugin; - -[/if] - /** - * Create the instance. - * - * - * @generated - */ - public [genModel.getModelPluginClassName()/]() - { - super(new ResourceLocator ['[]'/] {}); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ -[if (genModel.useClassOverrideAnnotation())] - @Override -[/if] - public ResourceLocator getPluginResourceLocator() - { -[if (genModel.runtimePlatform = GenRuntimePlatform::GWT)] - return null; -[else] - return plugin; -[/if] - } - -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT)] - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() - { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * - * @generated - */ - public static class Implementation extends EclipsePlugin - { - /** - * Creates an instance. - * - * -[if (genModel.needsRuntimeCompatibility())] - * @param descriptor the description of the plugin. -[/if] - * @generated - */ - public Implementation([if (genModel.needsRuntimeCompatibility())][genModel.getImportedName('org.eclipse.core.runtime.IPluginDescriptor')/] descriptor[/if]) - { - super([if (genModel.needsRuntimeCompatibility())]descriptor[/if]); - - // Remember the static instance. - // - plugin = this; - } - } - -[/if] -} - -[/template] - -[query public pluginFilePath(genModel : GenModel) : String - = genModel.extractSourceDirectory(genModel.modelDirectory) + '/' - + genModel.getQualifiedModelPluginClassName().toPath() + '.java' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ResourceClass.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ResourceClass.mtl deleted file mode 100644 index dce13b0c4..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ResourceClass.mtl +++ /dev/null @@ -1,508 +0,0 @@ -[comment encoding = UTF-8 /] -[module ResourceClass('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[comment] -/** - * - * - * Copyright (c) 2002-2006 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -[/comment] - -[template public resourceClass(genPackage : GenPackage) { genModel : GenModel = genPackage.genModel; packageName : String = genPackage.getUtilitiesPackageName(); className : String = genPackage.getResourceClassName();} ] -[genModel.initializeImportManager(packageName, className)/] - -[genModel.getImportedName('org.eclipse.emf.common.util.URI')/] - -[file (genPackage.resourceClassPath(), false, 'UTF-8')] -[genModel.includeHeader()/] -package [packageName/]; -[let content : String = genPackage.resourceFileContent(genModel, className)] -[genModel.genSortedImports()/] -[content/] -[/let] -[/file] -[/template] - -[template protected resourceFileContent(genPackage : GenPackage, genModel : GenModel, className : String)] -/** - * - * The Resource associated with the package. - * - * @see [genPackage.getQualifiedResourceFactoryClassName()/] - * @generated - */ -public class [className/] extends [genPackage.getImportedResourceBaseClassName()/] -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - /** - * Creates an instance of the resource. - * - * - * @param uri the URI of the new resource. - * @generated - */ - public [className/](URI uri) - { - super(uri); -[if (genPackage.getResource() = GenResourceKind::XML)][comment Do nothing/] -[/if] - } - -[if (genPackage.dataTypeConverters and (genPackage.hasDocumentRoot() or genPackage.isXMLTypePackage()))] -[let _Map : String = if (genModel.useGenerics()) then 'Map' else 'Map' endif] -[let _MapStringBoolean : String = if (genModel.useGenerics()) then 'Map' else 'Map' endif] -[let _MapStringWildcard : String = if (genModel.useGenerics()) then 'Map' else 'Map' endif] -[comment || org.eclipse.emf.ecore.xml.type.XMLTypePackage.eNS_URI.equals(genPackage.getNSURI()))) { boolean isXMLTypePackage = org.eclipse.emf.ecore.xml.type.XMLTypePackage.eNS_URI.equals(genPackage.getNSURI());%>/] - [if (not genPackage.isXMLTypePackage())] -[genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/] -[genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLParserPool')/] -[genModel.getImportedName('org.eclipse.emf.ecore.xmi.impl.XMLParserPoolImpl')/] -[genModel.getImportedName('java.io.InputStream')/] -[genModel.getImportedName('java.io.IOException')/] -[genModel.getImportedName('org.eclipse.emf.ecore.EObject')/] -[genModel.getImportedName('java.util.Collections')/] -[genModel.getImportedName('java.util.HashMap')/] -[genModel.getImportedName('java.util.Map')/] -[genModel.getImportedName('org.xml.sax.InputSource')/] -[genModel.getImportedName('javax.xml.parsers.SAXParser')/] - [/if] -[genModel.getImportedName('org.xml.sax.Attributes')/] -[genModel.getImportedName('org.xml.sax.SAXException')/] -[let _StackFrame : String = genModel.getImportedName('org.eclipse.emf.ecore.xml.type.util.XMLTypeResourceImpl') + '.StackFrame'] -[let _DataFrame : String = genModel.getImportedName('org.eclipse.emf.ecore.xml.type.util.XMLTypeResourceImpl') + '.DataFrame'] - [if (not genPackage.isXMLTypePackage())] - /** - * A load option that turns of the use of the generate data converters. - * - * - * @generated - */ - public static final String OPTION_USE_DATA_CONVERTER = "USE_DATA_CONVERTER"; - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public void doLoad(InputStream inputStream, [_Map/] options) throws IOException - { - if (options != null && Boolean.TRUE.equals(options.get(OPTION_USE_DATA_CONVERTER))) - { - getContents().add - (load - (new InputSource(inputStream), - ([_MapStringBoolean/])options.get(XMLResource.OPTION_PARSER_FEATURES), - ([_MapStringWildcard/])options.get(XMLResource.OPTION_PARSER_PROPERTIES), - Boolean.TRUE.equals(options.get(XMLResource.OPTION_USE_LEXICAL_HANDLER))).eContainer()); - } - else - { - super.doLoad(inputStream, options); - } - } - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public void doLoad(InputSource inputSource, [_Map/] options) throws IOException - { - if (options != null && Boolean.TRUE.equals(options.get(OPTION_USE_DATA_CONVERTER))) - { - getContents().add - (load - (inputSource, - ([_MapStringBoolean/])options.get(XMLResource.OPTION_PARSER_FEATURES), - ([_MapStringWildcard/])options.get(XMLResource.OPTION_PARSER_PROPERTIES), - Boolean.TRUE.equals(options.get(XMLResource.OPTION_USE_LEXICAL_HANDLER))).eContainer()); - } - else - { - super.doLoad(inputSource, options); - } - } - - /** - * - * - * @generated - */ - protected static final XMLParserPool parserPool = new XMLParserPoolImpl(); - - /** - * Loads an instance from the input. - * - * - * @param inputSource the input from which to load. - * @param features a map of the parser features and their values. - * @param properties a map of a parser properties and their values. - * @param useLexicalHandler whether a lexical handler should be used during loading. - * @return the root object; for the case of a document root, the child of that document root is return. - * @throws ParserConfigurationException - * @throws SAXException - * @generated - */ - public static EObject load(InputSource inputSource, [_MapStringBoolean/] features, [_MapStringWildcard/] properties, boolean useLexicalHandler) throws IOException - { - [_MapStringBoolean/] requiredFeatures = new [_MapStringBoolean.replaceAll('Map','HashMap')/](); - requiredFeatures.put("http://xml.org/sax/features/namespaces", Boolean.TRUE); - if (features != null) - { - requiredFeatures.putAll(features); - } - - if (properties == null) - { - properties = Collections.[if (genModel.useGenerics())]emptyMap()[else]EMPTY_MAP[/if]; - } - - SAXParser saxParser = null; - try - { - saxParser = parserPool.get(requiredFeatures, properties, useLexicalHandler); - final FrameFactory.DocumentRootStackFrame documentRoot = FrameFactory.INSTANCE.pushDocumentRoot(null, null); - XMLTypeResourceImpl.Handler handler = new XMLTypeResourceImpl.Handler(documentRoot); - saxParser.parse(inputSource, handler); - [if (genModel.suppressEMFTypes)] - return (EObject)((EObject)FrameFactory.INSTANCE.popDocumentRoot(documentRoot)).eContents().get(0); - [else] - return FrameFactory.INSTANCE.popDocumentRoot(documentRoot).eContents().get(0); - [/if] - } - catch (Exception exception) - { - throw new IOWrappedException(exception); - } - finally - { - parserPool.release(saxParser, requiredFeatures, properties, useLexicalHandler); - } - } - - [/if] - /** - * - * - * @generated - */ - public final static class FrameFactory - { - /** - * - * - * @generated - */ - public static final FrameFactory INSTANCE = new FrameFactory(); - - [for (genClass : GenClass | genPackage.genClasses)] - /** - * - * - * @generated - */ - protected [genClass.getName()/]StackFrame [genClass.getSafeUncapName()/]; - - [/for] - [for (genDataType : GenDataType | genPackage.getAllGenDataTypes())] - /** - * - * - * @generated - */ - protected [_DataFrame/] [genDataType.getSafeUncapName()/]; - - [/for] - [for (genClass : GenClass | genPackage.genClasses)] - [let attributes : Sequence(EStructuralFeature) = genModel.getAllExtendedMetaDataAttributes(genClass.ecoreClass)] - [let elements : Sequence(EStructuralFeature) = genModel.getAllExtendedMetaDataElements(genClass.ecoreClass)] - /** - * - * - * @generated - */ - public [genClass.getName()/]StackFrame push[genClass.getName()/]([_StackFrame/] previous, Attributes attributes) - { - [genClass.getName()/]StackFrame result[genClass.getName()/] = [genClass.getSafeUncapName()/] == null ? new [genClass.getName()/]StackFrame() : [genClass.getSafeUncapName()/]; - [genClass.getSafeUncapName()/] = null; - result[genClass.getName()/].pushOnto(previous); - result[genClass.getName()/].handleAttributes(attributes); - return result[genClass.getName()/]; - } - - /** - * - * - * @generated - */ - public [genClass.getImportedInterfaceName()/] pop[genClass.getName()/]([genClass.getName()/]StackFrame [genClass.getSafeUncapName()/]) - { - [genClass.getImportedInterfaceName()/] result[genClass.getName()/]Value = [genClass.getSafeUncapName()/].pop[genClass.getName()/](); - this.[genClass.getSafeUncapName()/] = [genClass.getSafeUncapName()/]; - return result[genClass.getName()/]Value; - } - - /** - * - * - * @generated - */ - public static class [genClass.getName()/]StackFrame extends [_StackFrame/] - { - /** - * - * - * @generated - */ - protected [genClass.getImportedInterfaceName()/] the[genClass.getName()/]; - - [for (genFeature : GenFeature | genClass.getAllGenFeatures())] - [let name : String = genModel.getExtendedMetaDataName(genFeature.ecoreFeature)] - [if ((elements->includes(genFeature.ecoreFeature) or attributes->includes(genFeature.ecoreFeature)) and name.index(':') < 0)] - [if (genFeature.isReferenceType())] - /** - * - * - * @generated - */ - protected [genFeature.getTypeGenClass().genPackage.getImportedResourceClassName()/].FrameFactory.[genFeature.getTypeGenClass().getName()/]StackFrame [genFeature.getSafeName()/]; - - [else] - /** - * - * - * @generated - */ - protected [_DataFrame/] [genFeature.getSafeName()/]; - - [/if] - [/if] - [/let] - [/for] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public void handleAttributes(Attributes attributes) - { - [comment int count = 0; for (GenFeature genFeature : genClass.getAllGenFeatures()) /] - [let featuresToHandle : Sequence(GenFeature) = genClass.getAllGenFeatures()->filter(GenFeature) - ->select(f : GenFeature| attributes->includes(f.ecoreFeature) - and not f.isDerived() - and genModel.getExtendedMetaDataName(f.ecoreFeature).index(':') < 0 - and not f.isReferenceType())] - [for (genFeature : GenFeature | featuresToHandle)] - [let name : String = genModel.getExtendedMetaDataName(genFeature.ecoreFeature)] - [let namespace : String = genModel.getExtendedMetaDataNamespaceAsLiteral(genFeature.ecoreFeature)] - [let genClassifier : GenClassifier = genFeature.getTypeGenClassifier()] - [if (i = 0)] - String theValue = attributes.getValue([namespace/], "[name/]"); - [else] - theValue = attributes.getValue([namespace/], "[name/]"); - [/if] - if (theValue != null) - { - [if (genClassifier.genPackage.dataTypeConverters)] - the[genClass.getName()/].set[genFeature.getAccessorName()/]([genClassifier.genPackage.getQualifiedFactoryInstanceAccessor()/].create[genClassifier.getName()/](theValue)); - [else] - the[genClass.getName()/].set[genFeature.getAccessorName()/](([genFeature.getImportedType(null)/])[genClassifier.genPackage.getQualifiedEFactoryInstanceAccessor()/].createFromString([genClassifier.getQualifiedClassifierAccessor()/], theValue)); - [/if] - } - [/let] - [/let] - [/let] - [/for] - [if (featuresToHandle->isEmpty())] - // There are attributes to handle. - [/if] - [/let] - } - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public [_StackFrame/] startElement(String namespace, String localName, String qName, Attributes attributes) throws SAXException - { - [let featuresToHandle : Sequence(GenFeature) = genClass.getAllGenFeatures()->filter(GenFeature) - ->select(f : GenFeature | elements->includes(f.ecoreFeature) - and genModel.getExtendedMetaDataName(f.ecoreFeature).index(':') < 0)] - [for (genFeature : GenFeature | featuresToHandle)] - [let name : String = genModel.getExtendedMetaDataName(genFeature.ecoreFeature)] - [let namespace : String = genModel.getExtendedMetaDataNamespaceAsLiteral(genFeature.ecoreFeature)] - [if (i > 0)]else [/if]if ("[name/]".equals(localName) && [namespace/].equals(namespace)) - { - return [genFeature.getSafeName()/] = [genFeature.getTypeGenClassifier().genPackage.getImportedResourceClassName()/].FrameFactory.INSTANCE.push[genFeature.getTypeGenClassifier().getName()/](this, attributes); - } - [/let] - [/let] - [/for] - [if (featuresToHandle->isEmpty())] - return super.startElement(namespace, localName, qName, attributes); - [else] - else - { - return super.startElement(namespace, localName, qName, attributes); - } - [/if] - [/let] - } - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public void endElement([_StackFrame/] child) throws SAXException - { - [let featuresToHandle : Sequence(GenFeature) = genClass.getAllGenFeatures()->filter(GenFeature) - ->select(f : GenFeature | elements->includes(f.ecoreFeature) - and genModel.getExtendedMetaDataName(f.ecoreFeature).index(':') < 0)] - [for (genFeature : GenFeature | featuresToHandle)] - [let name : String = genModel.getExtendedMetaDataName(genFeature.ecoreFeature)] - [if (i > 0)]else [/if]if (child == [genFeature.getSafeName()/]) - { - [if (genFeature.isListType())] - the[genClass.getName()/].[genFeature.getGetAccessor()/]().add([genFeature.getTypeGenClassifier().genPackage.getImportedResourceClassName()/].FrameFactory.INSTANCE.pop[genFeature.getTypeGenClassifier().getName()/]([genFeature.getSafeName()/])); - [else] - the[genClass.getName()/].set[genFeature.getAccessorName()/]([genFeature.getTypeGenClassifier().genPackage.getImportedResourceClassName()/].FrameFactory.INSTANCE.pop[genFeature.getTypeGenClassifier().getName()/]([genFeature.getSafeName()/])); - [/if] - [genFeature.getSafeName()/] = null; - } - [/let] - [/for] - [if (featuresToHandle->isEmpty())] - super.endElement(child); - [else] - else - { - super.endElement(child); - } - [/if] - [/let] - } - - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public void create() - { - the[genClass.getName()/] = [genPackage.getQualifiedFactoryInstanceAccessor()/].create[genClass.getName()/](); - } - - /** - * - * - * @generated - */ - protected [genClass.getImportedInterfaceName()/] pop[genClass.getName()/]() - { - pop(); - [genClass.getImportedInterfaceName()/] result[genClass.getName()/]Value = the[genClass.getName()/]; - the[genClass.getName()/] = null; - return result[genClass.getName()/]Value; - } - - } - - [/let] - [/let] - [/for] - [for (genDataType : GenDataType | genPackage.getAllGenDataTypes())] - /** - * - * - * @generated - */ - public [_DataFrame/] push[genDataType.getName()/]([_StackFrame/] previous, Attributes attributes) - { - [_DataFrame/] result[genDataType.getName()/] = [genDataType.getSafeUncapName()/] == null ? new [_DataFrame/]() : [genDataType.getSafeUncapName()/]; - [genDataType.getSafeUncapName()/] = null; - result[genDataType.getName()/].pushOnto(previous); - result[genDataType.getName()/].handleAttributes(attributes); - return result[genDataType.getName()/]; - } - - /** - * - * - * @generated - */ - public [genDataType.getImportedParameterizedInstanceClassName()/] pop[genDataType.getName()/]([_DataFrame/] [genDataType.getSafeUncapName()/]) - { - [if (genDataType.genPackage.dataTypeConverters)] - [genDataType.getImportedParameterizedInstanceClassName()/] result[genDataType.getName()/]Value = [genDataType.genPackage.getQualifiedFactoryInstanceAccessor()/].create[genDataType.getName()/]([genDataType.getSafeUncapName()/].popValue()); - [else][if (genDataType.isPrimitiveType() and not genModel.isJDK50())] - [genDataType.getImportedInstanceClassName()/] result[genDataType.getName()/]Value = (([genDataType.getObjectInstanceClassName()/])[genDataType.genPackage.getQualifiedEFactoryInstanceAccessor()/].createFromString([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/].popValue())).[genDataType.getPrimitiveValueFunction()/](); - [else] - [genDataType.getImportedInstanceClassName()/] result[genDataType.getName()/]Value = ([genDataType.getObjectInstanceClassName()/])[genDataType.genPackage.getQualifiedEFactoryInstanceAccessor()/].createFromString([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/].popValue()); - [/if][/if] - this.[genDataType.getSafeUncapName()/] = [genDataType.getSafeUncapName()/]; - return result[genDataType.getName()/]Value; - } - - [/for] - } - -[/let] -[/let] -[/let] -[/let] -[/let] -[/if] -} //[className/] -[/template] - -[query public resourceClassPath(genPackage : GenPackage) : String - = genPackage.genModel.extractSourceDirectory(genPackage.genModel.modelDirectory) + '/' - + genPackage.getQualifiedResourceClassName().toPath() + '.java'/] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ResourceFactoryClass.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ResourceFactoryClass.mtl deleted file mode 100644 index a4b5943b6..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ResourceFactoryClass.mtl +++ /dev/null @@ -1,140 +0,0 @@ -[comment encoding = UTF-8 /] -[module ResourceFactoryClass('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[comment] -/** - * - * - * Copyright (c) 2002-2006 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -[/comment] - -[template public resourceFactoryClass(genPackage : GenPackage) { genModel : GenModel = genPackage.genModel; packageName : String = genPackage.getUtilitiesPackageName(); className : String = genPackage.getResourceFactoryClassName();} ] -[genModel.initializeImportManager(packageName, className)/] - -[genModel.getImportedName('org.eclipse.emf.common.util.URI')/] -[genModel.getImportedName('org.eclipse.emf.ecore.resource.Resource')/] - -[file (genPackage.resourceFactoryClassPath(), false, 'UTF-8')] -[genModel.includeHeader()/] -package [packageName/]; -[let content : String = genPackage.resourceFactoryFileContent(genModel)] -[genModel.genSortedImports()/] - -[content/] -[/let] -[/file] -[/template] - -[template protected resourceFactoryFileContent(genPackage : GenPackage, genModel : GenModel)] -/** - * - * The Resource Factory associated with the package. - * - * @see [genPackage.getQualifiedResourceClassName()/] - * @generated - */ -public class [genPackage.getResourceFactoryClassName()/] extends [genPackage.getImportedResourceFactoryBaseClassName()/] { -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] -[if (genPackage.hasExtendedMetaData() and not genPackage.hasTargetNamespace())] - /** - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.emf.ecore.util.ExtendedMetaData')/] extendedMetaData; - -[else][if (genPackage.hasXMLMap())] - /** - * - * - * @generated - */ - protected [genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource$XMLMap')/] xmlMap = new [genModel.getImportedName('org.eclipse.emf.ecore.xmi.impl.XMLMapImpl')/](); - -[/if][/if] - /** - * Creates an instance of the resource factory. - * - * - * @generated - */ - public [genPackage.getResourceFactoryClassName()/]() - { - super(); -[if (genPackage.hasExtendedMetaData() and not genPackage.hasTargetNamespace())] - extendedMetaData = new [genModel.getImportedName('org.eclipse.emf.ecore.util.BasicExtendedMetaData')/](new [genModel.getImportedName('org.eclipse.emf.ecore.impl.EPackageRegistryImpl')/]([genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE)); - extendedMetaData.putPackage(null, [genPackage.getImportedPackageInterfaceName()/].eINSTANCE); -[else][if (genPackage.hasXMLMap() and not genPackage.hasTargetNamespace())] - xmlMap.setNoNamespacePackage([genPackage.getImportedPackageInterfaceName()/].eINSTANCE); -[/if][/if] - } - - /** - * Creates an instance of the resource. - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public Resource createResource(URI uri) - { -[if (genPackage.hasExtendedMetaData())] - [genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/] result = new [genPackage.getResourceClassName()/](uri); - result.getDefaultSaveOptions().put([genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/].OPTION_EXTENDED_META_DATA, [if (genPackage.hasTargetNamespace())]Boolean.TRUE[else]extendedMetaData[/if]); - result.getDefaultLoadOptions().put([genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/].OPTION_EXTENDED_META_DATA, [if (genPackage.hasTargetNamespace())]Boolean.TRUE[else]extendedMetaData[/if]); - - result.getDefaultSaveOptions().put([genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/].OPTION_SCHEMA_LOCATION, Boolean.TRUE); - - result.getDefaultLoadOptions().put([genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/].OPTION_USE_ENCODED_ATTRIBUTE_STYLE, Boolean.TRUE); - result.getDefaultSaveOptions().put([genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/].OPTION_USE_ENCODED_ATTRIBUTE_STYLE, Boolean.TRUE); - - result.getDefaultLoadOptions().put([genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/].OPTION_USE_LEXICAL_HANDLER, Boolean.TRUE); - [if (genPackage.dataTypeConverters and genPackage.hasDocumentRoot())] - result.getDefaultLoadOptions().put([genPackage.getResourceClassName()/].OPTION_USE_DATA_CONVERTER, Boolean.TRUE); - [/if] -[else][if (genPackage.hasXMLMap())] - [genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/] result = new [genPackage.getResourceClassName()/](uri); - result.getDefaultSaveOptions().put([genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/].OPTION_XML_MAP, xmlMap); - result.getDefaultLoadOptions().put([genModel.getImportedName('org.eclipse.emf.ecore.xmi.XMLResource')/].OPTION_XML_MAP, xmlMap); -[else] - Resource result = new [genPackage.getResourceClassName()/](uri); -[/if][/if] - return result; - } - -} //[genPackage.getResourceFactoryClassName()/] -[/template] - -[query public resourceFactoryClassPath(genPackage : GenPackage) : String - = genPackage.genModel.extractSourceDirectory(genPackage.genModel.modelDirectory) + '/' - + genPackage.getQualifiedResourceFactoryClassName().toPath() + '.java'/] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/SwitchClass.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/SwitchClass.mtl deleted file mode 100644 index 5f8582af5..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/SwitchClass.mtl +++ /dev/null @@ -1,227 +0,0 @@ -[comment encoding = UTF-8 /] -[module SwitchClass('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenParameter /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[comment] -/** - * - * - * Copyright (c) 2002-2006 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -[/comment] - -[template public switchClass(genPackage : GenPackage) { genModel : GenModel = genPackage.genModel; - packageName : String = genPackage.getUtilitiesPackageName(); - className : String = genPackage.getSwitchClassName(); - supportsComposition : Boolean = genModel.supportsComposition();} ] -[genModel.initializeImportManager(packageName, className)/] - -[if (supportsComposition)] -[genModel.addImport('org.eclipse.emf.ecore.EObject')/] -[genModel.addImport('org.eclipse.emf.ecore.EPackage')/] -[genModel.addImport('org.eclipse.emf.ecore.util.Switch')/] -[else] -[genModel.addImport('org.eclipse.emf.ecore.EClass')/] -[genModel.addImport('org.eclipse.emf.ecore.EObject')/] -[/if] -[if (not genPackage.hasJavaLangConflict() and genPackage.getUtilitiesPackageName() <> genPackage.getInterfacePackageName())] -[genModel.addImport(genPackage.getInterfacePackageName() + '.*')/] -[/if] - -[file (genPackage.switchClassPath(), false, 'UTF-8')] -[genModel.includeHeader()/] -package [packageName/]; -[let templateParameterName : String = genPackage.computeSwitchGenericTypeName()] - [let templateParameters : String = if (genModel.useGenerics()) then '<' + templateParameterName + '>' else '' endif] - [let returnType : String = if (genModel.useGenerics()) then templateParameterName else genModel.getImportedName('java.lang.Object') endif] - [let content : String = genPackage.switchFileContent(genModel, templateParameters, returnType, supportsComposition, className)] -[genModel.genSortedImports()/] - -[content/] - [/let] - [/let] - [/let] -[/let] -[/file] -[/template] - -[template protected switchFileContent(genPackage : GenPackage, genModel : GenModel, templateParameters : String, returnType : String, supportsComposition : Boolean, className : String)] -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see [genPackage.getQualifiedPackageInterfaceName()/] - * @generated - */ -public class [className/][templateParameters/][if (supportsComposition)] extends Switch[templateParameters/][/if] { -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - /** - * The cached model package - * - * - * @generated - */ - protected static [genPackage.getImportedPackageInterfaceName()/] modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public [genPackage.getSwitchClassName()/]() { - if (modelPackage == null) { - modelPackage = [genPackage.getImportedPackageInterfaceName()/].eINSTANCE; - } - } - -[if (supportsComposition)] - /** - * Checks whether this is a switch for the given package. - * - * - * @parameter ePackage the package in question. - * @return whether this is a switch for the given package. - * @generated - */ - @Override - protected boolean isSwitchFor(EPackage ePackage) { - return ePackage == modelPackage; - } -[else] - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public [returnType/] doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected [returnType/] doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } else { - [genModel.getImportedName('java.util.List')/][if (genModel.useGenerics())]<[genModel.getImportedName('org.eclipse.emf.ecore.EClass')/]>[/if] eSuperTypes = theEClass.getESuperTypes(); - return - eSuperTypes.isEmpty() ? - defaultCase(theEObject) : - doSwitch([if (not genModel.useGenerics())](EClass)[/if]eSuperTypes.get(0), theEObject); - } - } -[/if] - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ -[if (supportsComposition)] - @Override -[/if] - protected [returnType/] doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { -[for (genClass : GenClass | genPackage.genClasses)] -[if (not genClass.isExternalInterface() and not genClass.isEObject() or genClass.isMapEntry())] - [let result : String = if ('result' = genClass.getSafeUncapName()) then 'theResult' else 'result' endif] - case [genPackage.getImportedPackageInterfaceName()/].[genPackage.getClassifierID(genClass)/]: { - [if (genClass.isUncheckedCast() or genClass.isMapEntry() and genModel.isJDK50())]@SuppressWarnings("unchecked") [/if][genClass.getImportedInterfaceName()/][genClass.getInterfaceWildTypeArguments()/] [genClass.getSafeUncapName()/] = ([genClass.getImportedInterfaceName()/][genClass.getInterfaceWildTypeArguments()/])theEObject; - [returnType/] [result/] = case[genPackage.getClassUniqueName(genClass)/]([genClass.getSafeUncapName()/]); - [for (baseGenClass : GenClass | genClass.getSwitchGenClasses())] - if ([result/] == null) [result/] = case[genPackage.getClassUniqueName(baseGenClass)/]([if (genClass.isMapEntry())]([baseGenClass.getImportedInterfaceName()/][baseGenClass.getInterfaceTypeArguments()/])[/if][genClass.getSafeUncapName()/]); - [/for] - if ([result/] == null) [result/] = defaultCase(theEObject); - return [result/]; - } - [/let] -[/if] -[/for] - default: return defaultCase(theEObject); - } - } -[for (genClass : GenClass | genPackage.getAllSwitchGenClasses())] - - /** - * Returns the result of interpreting the object as an instance of '[genClass.getFormattedName()/]'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of '[genClass.getFormattedName()/]'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public [genClass.getTypeParameters()/][returnType/] case[genPackage.getClassUniqueName(genClass)/]([genClass.getImportedInterfaceName()/][genClass.getInterfaceTypeArguments()/] object) { - return null; - } -[/for] - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ -[if (supportsComposition)] - @Override -[/if] - public [returnType/] defaultCase(EObject object) { - return null; - } - -} //[className/] -[/template] - -[query public switchClassPath(genPackage : GenPackage) : String - = genPackage.genModel.extractSourceDirectory(genPackage.genModel.modelDirectory) + '/' - + genPackage.getQualifiedSwitchClassName().toPath() + '.java'/] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ValidatorClass.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ValidatorClass.mtl deleted file mode 100644 index 3d3715991..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/ValidatorClass.mtl +++ /dev/null @@ -1,749 +0,0 @@ -[comment encoding = UTF-8 /] -[module ValidatorClass('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenOperation /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenParameter /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[comment] -/** - * - * - * Copyright (c) 2002-2011 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -[/comment] - -[template public validatorClass(genPackage : GenPackage) { genModel : GenModel = genPackage.genModel; - packageName : String = genPackage.getUtilitiesPackageName(); - className : String = genPackage.getValidatorClassName(); - singleWildcard : String = if genModel.isJDK50() then '' else '' endif;} ] -[genModel.initializeImportManager(packageName, className)/] - -[genModel.addImport('java.util.Map')/] -[let _Map : String = if genModel.useGenerics() then - 'Map<' + genModel.getImportedName('java.lang.Object') + ', ' + genModel.getImportedName('java.lang.Object') + '>' - else - 'Map' - endif] - [let objectArgument : String = if genModel.useGenerics() then - '<' + genModel.getImportedName('java.lang.Object') + '>' - else - '' - endif] -[genModel.addImport('org.eclipse.emf.common.util.DiagnosticChain')/] -[genModel.addImport('org.eclipse.emf.ecore.EPackage')/] -[if (not genPackage.hasJavaLangConflict() and genPackage.getUtilitiesPackageName() <> genPackage.getInterfacePackageName())] - [genModel.addImport(genPackage.getInterfacePackageName() + '.*')/] -[/if] -[genModel.addPseudoImport('org.eclipse.emf.ecore.EValidator.Descriptor')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.EValidator.Registry')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.EValidator.SubstitutionLabelProvider')/] -[genModel.addPseudoImport('org.eclipse.emf.ecore.EValidator.PatternMatcher')/] - - [file (genPackage.validatorClassPath(), false, 'UTF-8')] -[genModel.includeHeader()/] -package [packageName/]; - [let content : String = genPackage.validatorFileContent(genModel, singleWildcard, _Map, objectArgument)] -[genModel.genSortedImports()/] -[content/] - [/let] - [/file] - [/let] -[/let] -[/template] - -[template protected validatorFileContent(genPackage : GenPackage, genModel : GenModel, singleWildcard : String, _Map : String, objectArgument : String)] -/** - * - * The Validator for the model. - * - * @see [genPackage.getQualifiedPackageInterfaceName()/] - * @generated - */ -public class [genPackage.getValidatorClassName()/] extends [genModel.getImportedName('org.eclipse.emf.ecore.util.EObjectValidator')/] -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - /** - * The cached model package - * - * - * @generated - */ - public static final [genPackage.getValidatorClassName()/] INSTANCE = new [genPackage.getValidatorClassName()/](); - - /** - * A constant for the {@link org.eclipse.emf.common.util.Diagnostic#getSource() source} of diagnostic {@link org.eclipse.emf.common.util.Diagnostic#getCode() codes} from this package. - * - * - * @see org.eclipse.emf.common.util.Diagnostic#getSource() - * @see org.eclipse.emf.common.util.Diagnostic#getCode() - * @generated - */ - public static final String DIAGNOSTIC_SOURCE = "[genPackage.getInterfacePackageName()/]";[genModel.getNonNLS()/] - -[for (genClass : GenClass | genPackage.genClasses)] - [let ic : Integer = i] - [for (genOperation : GenOperation | genClass.getInvariantOperations())] - [let io : Integer = i] - /** - * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint '[genOperation.getFormattedName()/]' of '[genClass.getFormattedName()/]'. - * - * - * @generated - */ - public static final int [genClass.getOperationID(genOperation)/] = [ic + io/]; - - [/let] - [/for] - [/let] -[/for] - /** - * A constant with a fixed name that can be used as the base value for additional hand written constants. - * - * - * @generated - */ - private static final int GENERATED_DIAGNOSTIC_CODE_COUNT = [genPackage.genClasses.getInvariantOperations()->flatten()->size()/]; - - /** - * A constant with a fixed name that can be used as the base value for additional hand written constants in a derived class. - * - * - * @generated - */ - protected static final int DIAGNOSTIC_CODE_COUNT = GENERATED_DIAGNOSTIC_CODE_COUNT; - -[for (baseGenPackage : GenPackage | genPackage.getAllValidatorBaseGenPackages())] - /** - * The cached base package validator. - * - * - * @generated - */ - protected [baseGenPackage.getImportedValidatorClassName()/] [genPackage.getValidatorPackageUniqueSafeName(baseGenPackage)/]Validator; - -[/for] -[if (genPackage.hasInvariantExpressions())] - /** - * Delegates evaluation of the given invariant expression against the object in the given context. - * - * - * @generated - */ - public static boolean validate([genModel.getImportedName('org.eclipse.emf.ecore.EClass')/] eClass, [genModel.getImportedName('org.eclipse.emf.ecore.EObject')/] eObject, DiagnosticChain diagnostics, [_Map/] context, [genModel.getImportedName('java.lang.String')/] validationDelegate, [genModel.getImportedName('org.eclipse.emf.ecore.EOperation')/] invariant, [genModel.getImportedName('java.lang.String')/] expression, int severity, [genModel.getImportedName('java.lang.String')/] source, int code) - { - return [genModel.getImportedName('org.eclipse.emf.ecore.util.EObjectValidator')/].validate(eClass, eObject, diagnostics, context, validationDelegate, invariant, expression, severity, source, code); - } - -[/if] - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public [genPackage.getValidatorClassName()/]() - { - super(); -[for (baseGenPackage : GenPackage | genPackage.getAllValidatorBaseGenPackages())] - [genPackage.getValidatorPackageUniqueSafeName(baseGenPackage)/]Validator = [baseGenPackage.getImportedValidatorClassName()/].INSTANCE; -[/for] - } - - /** - * Returns the package of this validator switch. - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - protected EPackage getEPackage() - { - return [genPackage.getImportedPackageInterfaceName()/].eINSTANCE; - } - - /** - * Calls validateXXX for the corresponding classifier of the model. - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - [if (genPackage.genClassifiers->exists(genClassifier : GenClassifier | genClassifier.isUncheckedCast()))] - @SuppressWarnings("unchecked") - [/if] - protected boolean validate(int classifierID, Object value, DiagnosticChain diagnostics, [_Map/] context) - { - switch (classifierID) - { -[for (genClassifier : GenClassifier | genPackage.genClassifiers)] - case [genPackage.getImportedPackageInterfaceName()/].[genPackage.getClassifierID(genClassifier)/]: - [if (genClassifier.oclIsKindOf(GenDataType))] - [let genDataType : GenDataType = genClassifier.oclAsType(GenDataType)] - [if (genDataType.isPrimitiveType())] - [if (not genModel.isJDK50())] - return validate[genDataType.getName()/]((([genDataType.getObjectInstanceClassName()/])value).[genDataType.getPrimitiveValueFunction()/](), diagnostics, context); - [else] - return validate[genDataType.getName()/](([genDataType.getObjectInstanceClassName()/])value, diagnostics, context); - [/if] - [else][if (genDataType.isObjectType())] - return validate[genDataType.getName()/](value, diagnostics, context); - [else] - return validate[genDataType.getName()/](([genDataType.getObjectType().getImportedWildcardInstanceClassName()/])value, diagnostics, context); - [/if][/if] - [/let] - [else] - [let genClass : GenClass = genClassifier.oclAsType(GenClass)] - return validate[genClass.getName()/](([genClass.getImportedWildcardInstanceClassName()/])value, diagnostics, context); - [/let] - [/if] -[/for] - default: - return true; - } - } - -[for (genClassifier : GenClassifier | genPackage.genClassifiers)][comment Due to a bug in Acceleo (or MTL's spec), we can't use properly init sections on for blocks... That's why we use "let".../] - [let result : String = if ('result' = genClassifier.getSafeUncapName()) then 'theResult' else 'result' endif] - [let diagnostics : String = if ('diagnostics' = genClassifier.getSafeUncapName()) then 'theDiagnostics' else 'diagnostics' endif] - [let item : String = if ('item' = genClassifier.getSafeUncapName()) then 'theItem' else 'item' endif] - [let _context : String = if ('context' = genClassifier.getSafeUncapName()) then 'theContext' else 'context' endif] - /** - * - * - * @generated - */ - public boolean validate[genClassifier.getName()/]([genClassifier.getImportedWildcardInstanceClassName()/] [genClassifier.getSafeUncapName()/], DiagnosticChain [diagnostics/], [_Map/] [_context/]) - { - [if (genClassifier.getAllGenConstraints()->isEmpty())] - return true; - [else][if (genClassifier.hasOnlyDefaultConstraints())] - return validate_EveryDefaultConstraint([if (not genClassifier.oclAsType(GenClass).isEObjectExtension())]([genModel.getImportedName('org.eclipse.emf.ecore.EObject')/])[/if][genClassifier.getSafeUncapName()/], [diagnostics/], [_context/]); - [else] - [for (constraint : String | genClassifier.getAllGenConstraints())] - [let constraintImplementor : GenClassifier = genClassifier.getConstraintImplementor(constraint)] - [let delegate : String = if (constraintImplementor = null or constraintImplementor.genPackage = genPackage) then '' else genPackage.getValidatorPackageUniqueSafeName(constraintImplementor.genPackage) + 'Validator.' endif] - [let cast : String = if (constraintImplementor = null and genClassifier.oclIsKindOf(GenClass) and not genClassifier.oclAsType(GenClass).isEObjectExtension()) then '(' + genModel.getImportedName('org.eclipse.emf.ecore.EObject') + ')' else '' endif] - [let accessor : String = if (constraintImplementor <> null and genClassifier.oclIsKindOf(GenDataType) and not genClassifier.oclAsType(GenDataType).isPrimitiveType() and constraintImplementor.oclAsType(GenDataType).isPrimitiveType() and not genModel.isJDK50()) then '.' + constraintImplementor.oclAsType(GenDataType).getPrimitiveValueFunction() + '()' else '' endif] - [if ('NoCircularContainment' = constraint)] - if (!validate_NoCircularContainment([if (not genClassifier.oclAsType(GenClass).isEObjectExtension())]([genModel.getImportedName('org.eclipse.emf.ecore.EObject')/])[/if][genClassifier.getSafeUncapName()/], [diagnostics/], [_context/])) return false; - [else][if (i = genClassifier.getIndexOfFirstConstraintDifferentFromNoCircular())] - boolean [result/] = [delegate/]validate[if (constraintImplementor <> null)][constraintImplementor.getName()/][/if]_[constraint/]([cast/][genClassifier.getSafeUncapName()/][accessor/], [diagnostics/], [_context/]); - [else] - if ([result/] || [diagnostics/] != null) [result/] &= [delegate/]validate[if (constraintImplementor <> null)][constraintImplementor.getName()/][/if]_[constraint/]([cast/][genClassifier.getSafeUncapName()/][accessor/], [diagnostics/], [_context/]); - [/if][/if] - [/let] - [/let] - [/let] - [/let] - [/for] - return [result/]; - [/if][/if] - } - -[for (constraint : String | genClassifier.getGenConstraints())][comment Due to a bug in Acceleo (or MTL's spec), we can't use properly init sections on for blocks... That's why we use "let".../] - [let constraintDelegate : GenClassifier = genClassifier.getConstraintDelegate(constraint)] - [let constant : String = genClassifier.getClassifierID() + '__' + genModel.formatConstraint(constraint)] - [let delegate : String = if (constraintDelegate = null or constraintDelegate.genPackage = genPackage) then '' else genPackage.getValidatorPackageUniqueSafeName(constraintDelegate.genPackage) + 'Validator.' endif] - [let cast : String = if (constraintDelegate = null and genClassifier.oclIsKindOf(GenClass) and not genClassifier.oclAsType(GenClass).isEObjectExtension()) then '(' + genModel.getImportedName('org.eclipse.emf.ecore.EObject') + ')' else '' endif] - [let accessor : String = if (constraintDelegate <> null and genClassifier.oclIsKindOf(GenDataType) and not genClassifier.oclAsType(GenDataType).isPrimitiveType() and constraintDelegate.oclAsType(GenDataType).isPrimitiveType() and not genModel.isJDK50()) then '.' + constraintDelegate.oclAsType(GenDataType).getPrimitiveValueFunction() + '()' else '' endif] -[if (genClassifier.oclIsKindOf(GenDataType))] - [let genDataType : GenDataType = genClassifier.oclAsType(GenDataType)] -[if (constraint = 'Min' and genDataType.getMinLiteral() <> null)] - /** - * - * - * @generated - * @see #validate[genDataType.getName()/]_[constraint/] - */ - public static final [genDataType.getImportedInstanceClassName()/] [constant/]__VALUE = [genDataType.getStaticValue(genDataType.getMinLiteral())/]; - -[else][if (constraint = 'Max' and genDataType.getMaxLiteral() <> null)] - /** - * - * - * @generated - * @see #validate[genDataType.getName()/]_[constraint/] - */ - public static final [genDataType.getImportedInstanceClassName()/] [constant/]__VALUE = [genDataType.getStaticValue(genDataType.getMaxLiteral())/]; - -[else][if (constraint = 'TotalDigits' and genDataType.getTotalDigits() > -1 and 'java.math.BigDecimal' <> genDataType.getQualifiedInstanceClassName())] - /** - * - * - * @generated - * @see #validate[genDataType.getName()/]_[constraint/] - */' - public static final [genDataType.getImportedInstanceClassName()/] [constant/]__UPPER_BOUND = [genDataType.getStaticPositiveValue()/]; - - /** - * - * - * @generated - * @see #validate[genDataType.getName()/]_[constraint/] - */ - public static final [genDataType.getImportedInstanceClassName()/] [constant/]__LOWER_BOUND = [genDataType.getStaticNegativeValue()/]; - -[else][if (constraint = 'Pattern' and genDataType.getPatterns()->notEmpty())] - /** - * - * - * @generated - * @see #validate[genDataType.getName()/]_[constraint/] - */ - public static final PatternMatcher ['[][]'/] [constant/]__VALUES = - new PatternMatcher ['[][]'/] - { - [for (patternList : Sequence(String) | genDataType.getPatterns()) separator (',' + genModel.getLineDelimiter())] - new PatternMatcher ['[]'/] - { - [for (pattern : String | patternList) separator (',' + genModel.getLineDelimiter())] - [genModel.getImportedName('org.eclipse.emf.ecore.xml.type.util.XMLTypeUtil')/].createPatternMatcher([pattern/])[/for] - }[/for] - }; - -[else][if (constraint = 'Enumeration' and genDataType.getEnumerationLiterals()->notEmpty())] - /** - * - * - * @generated - * @see #validate[genDataType.getName()/]_[constraint/] - */ - [if (genDataType.isUncheckedCast())] - @SuppressWarnings("unchecked") - [/if] - public static final [genModel.getImportedName('java.util.Collection')/][objectArgument/] [constant/]__VALUES = - wrapEnumerationValues - (new Object['[]'/] - { - [for (literal : String | genDataType.getEnumerationLiterals()) separator (',' + genModel.getLineDelimiter())] - [if (genDataType.isPrimitiveType() and not genModel.isJDK50())]new [genDataType.getObjectInstanceClassName()/]([/if][genDataType.getStaticValue(literal, false)/][if (genDataType.isPrimitiveType() and not genModel.isJDK50())])[/if][/for] - }); - -[/if][/if][/if][/if][/if] - [/let] -[/if] -[if (genClassifier.hasConstraintExpression(constraint))] - /** - * The cached validation expression for the [constraint/] constraint of '[genClassifier.getFormattedName()/]'. - * - * - * @generated - */ - protected static final [genModel.getImportedName('java.lang.String')/] [genClassifier.getClassifierID()/]__[constraint.upperNameConstraint()/]__EEXPRESSION = "[genClassifier.getConstraintExpression(constraint, '\t\t')/]";[genModel.getNonNLS()/] - -[/if] - /** - * Validates the [constraint/] constraint of '[genClassifier.getFormattedName()/]'. - * - * - * @generated - */ - public boolean validate[genClassifier.getName()/]_[constraint/]([genClassifier.getImportedWildcardInstanceClassName()/] [genClassifier.getSafeUncapName()/], DiagnosticChain [diagnostics/], [_Map/] [_context/]) - { -[if (genClassifier.oclIsKindOf(GenDataType))] - [let genDataType : GenDataType = genClassifier.oclAsType(GenDataType)] -[if (constraint = 'ItemType' and genDataType.getItemType() <> null)] - [let itemType : GenDataType = genDataType.getItemType()] - [let itemDelegate : String = if (itemType.genPackage = genPackage) then '' else genPackage.getValidatorPackageUniqueSafeName(itemType.genPackage) + 'Validator.' endif] - boolean [result/] = true; - for ([genModel.getImportedName('java.util.Iterator')/][singleWildcard/] i = [genClassifier.getSafeUncapName()/].iterator(); i.hasNext() && (result || diagnostics != null); ) - { - Object item = i.next(); - [if (itemType.genPackage.hasConstraints())] - if ([itemType.getQualifiedClassifierAccessor()/].isInstance(item)) - { - result &= [itemDelegate/]validate[itemType.getName()/]([if (itemType.isPrimitiveType() and not genModel.isJDK50())]([/if][if (not itemType.isObjectType())]([itemType.getObjectInstanceClassName()/])[/if][item/][if (itemType.isPrimitiveType() and not genModel.isJDK50())]).[itemType.getPrimitiveValueFunction()/]()[/if], [diagnostics/], [_context/]); - } - else - [else] - if (![itemType.getQualifiedClassifierAccessor()/].isInstance(item)) - [/if] - { - result = false; - reportDataValueTypeViolation([itemType.getQualifiedClassifierAccessor()/], item, [diagnostics/], [_context/]); - } - } - return result; - [/let] - [/let] -[else][if (constraint = 'MemberTypes' and genDataType.getMemberTypes()->notEmpty())] - if (diagnostics != null) - { - [genModel.getImportedName('org.eclipse.emf.common.util.BasicDiagnostic')/] tempDiagnostics = new BasicDiagnostic(); - [for (memberType : GenDataType | genDataType.getMemberTypes())] - [let memberDelegate : String = if (memberType.genPackage = genPackage) then '' else genPackage.getValidatorPackageUniqueSafeName(memberType.genPackage) + 'Validator.' endif] - [if (genDataType.isPrimitiveType())] - if ([memberDelegate/]validate[memberType.getName()/]([genClassifier.getSafeUncapName()/], tempDiagnostics, [_context/])) return true; - [else] - if ([memberType.getQualifiedClassifierAccessor()/].isInstance([genClassifier.getSafeUncapName()/])) - { - [if (memberType.genPackage.hasConstraints())]if ([memberDelegate/]validate[memberType.getName()/]([if (memberType.isPrimitiveType() and not genModel.isJDK50())]([/if][if (not memberType.isObjectType() and memberType.getQualifiedInstanceClassName() <> genDataType.getQualifiedInstanceClassName())]([memberType.getImportedWildcardObjectInstanceClassName()/])[/if][genClassifier.getSafeUncapName()/][if (memberType.isPrimitiveType() and not genModel.isJDK50())]).[memberType.getPrimitiveValueFunction()/]()[/if], tempDiagnostics, [_context/])) [/if]return true; - } - [/if] - [/let] - [/for] - [if (genModel.useGenerics())] - for ([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/] diagnostic : tempDiagnostics.getChildren()) - { - diagnostics.add(diagnostic); - } - [else] - [genModel.getImportedName('java.util.List')/] children = tempDiagnostics.getChildren(); - for (int i = 0; i < children.size(); i++) - { - diagnostics.add(([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/])children.get(i)); - } - [/if] - } - else - { - [for (memberType : GenDataType | genDataType.getMemberTypes())] - [let memberDelegate : String = if (memberType.genPackage = genPackage) then '' else genPackage.getValidatorPackageUniqueSafeName(memberType.genPackage) + 'Validator.' endif] - [if (genDataType.isPrimitiveType())] - if ([memberDelegate/]validate[memberType.getName()/]([genClassifier.getSafeUncapName()/], null, [_context/])) return true; - [else] - if ([memberType.getQualifiedClassifierAccessor()/].isInstance([genClassifier.getSafeUncapName()/])) - { - [if (memberType.genPackage.hasConstraints())]if ([memberDelegate/]validate[memberType.getName()/]([if (memberType.isPrimitiveType() and not genModel.isJDK50())]([/if][if (not memberType.isObjectType() and memberType.getQualifiedInstanceClassName() <> genDataType.getQualifiedInstanceClassName())]([memberType.getImportedWildcardObjectInstanceClassName()/])[/if][genClassifier.getSafeUncapName()/][if (memberType.isPrimitiveType() and not genModel.isJDK50())]).[memberType.getPrimitiveValueFunction()/]()[/if], null, [_context/])) [/if]return true; - } - [/if] - [/let] - [/for] - } - return false; -[else][if (constraint = 'Pattern' and genDataType.getPatterns()->notEmpty())] - return validatePattern([genDataType.getQualifiedClassifierAccessor()/], [if (genDataType.isPrimitiveType() and not genModel.isJDK50())]new [genDataType.getObjectInstanceClassName()/]([/if][genDataType.getSafeUncapName()/][if (genDataType.isPrimitiveType() and not genModel.isJDK50())])[/if], [constant/]__VALUES, [diagnostics/], [_context/]); -[else][if (constraint = 'Enumeration' and genDataType.getEnumerationLiterals()->notEmpty())] - [let variable : String = genDataType.getSafeUncapName() + if (genDataType.isPrimitiveType() and not genModel.isJDK50()) then 'Object' else '' endif] - [if (genDataType.isPrimitiveType() and not genModel.isJDK50())] - [genDataType.getObjectInstanceClassName()/] [variable/] = new [genDataType.getObjectInstanceClassName()/]([genDataType.getSafeUncapName()/]); - [/if] - boolean [result/] = [constant/]__VALUES.contains([variable/]); - if (![result/] && [diagnostics/] != null) - reportEnumerationViolation([genDataType.getQualifiedClassifierAccessor()/], [variable/], [constant/]__VALUES, [diagnostics/], [_context/]); - return [result/]; - [/let] -[else][if (constraint = 'Min' and genDataType.getMinLiteral() <> null)] - [if (genDataType.isPrimitiveType())] - boolean [result/] = [genDataType.getSafeUncapName()/] [if (genDataType.isMinInclusive())]>=[else]>[/if] [constant/]__VALUE; - if (![result/] && [diagnostics/] != null) - [if (not genModel.isJDK50())] - reportMinViolation([genDataType.getQualifiedClassifierAccessor()/], new [genDataType.getObjectInstanceClassName()/]([genDataType.getSafeUncapName()/]), new [genDataType.getObjectInstanceClassName()/]([constant/]__VALUE), [if (genDataType.isMinInclusive())]true[else]false[/if], [diagnostics/], [_context/]); - [else] - reportMinViolation([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/], [constant/]__VALUE, [if (genDataType.isMinInclusive())]true[else]false[/if], [diagnostics/], [_context/]); - [/if] - return [result/]; - [else] - [let comparison : String = if ('comparison' = genClassifier.getSafeUncapName()) then 'theComparison' else 'comparison' endif] - [if (genDataType.isXMLCalendar())] - int [comparison/] = [genModel.getImportedName('org.eclipse.emf.ecore.xml.type.util.XMLTypeUtil')/].compareCalendar([genDataType.getSafeUncapName()/], [constant/]__VALUE); - boolean [result/] = [if (genDataType.isMinInclusive())][comparison/] == 0 || [/if][comparison/] == 1; - [else][if (genDataType.isXMLDuration())] - int [comparison/] = [genModel.getImportedName('org.eclipse.emf.ecore.xml.type.util.XMLTypeUtil')/].compareDuration([genDataType.getSafeUncapName()/], [constant/]__VALUE); - boolean [result/] = [if (genDataType.isMinInclusive())][comparison/] == 0 || [/if][comparison/] == 1; - [else] - boolean [result/] = [genDataType.getSafeUncapName()/].compareTo([constant/]__VALUE) [if (genDataType.isMinInclusive())]>=[else]>[/if] 0; - [/if][/if] - if (![result/] && [diagnostics/] != null) - reportMinViolation([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/], [constant/]__VALUE, [if (genDataType.isMinInclusive())]true[else]false[/if], [diagnostics/], [_context/]); - return [result/]; - [/let] - [/if] -[else][if (constraint = 'Max' and genDataType.getMaxLiteral() <> null)] - [if (genDataType.isPrimitiveType())] - boolean [result/] = [genDataType.getSafeUncapName()/] [if (genDataType.isMaxInclusive())]<=[else]<[/if] [constant/]__VALUE; - if (![result/] && [diagnostics/] != null) - [if (not genModel.isJDK50())] - reportMaxViolation([genDataType.getQualifiedClassifierAccessor()/], new [genDataType.getObjectInstanceClassName()/]([genDataType.getSafeUncapName()/]), new [genDataType.getObjectInstanceClassName()/]([constant/]__VALUE), [if (genDataType.isMaxInclusive())]true[else]false[/if], [diagnostics/], [_context/]); - [else] - reportMaxViolation([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/], [constant/]__VALUE, [if (genDataType.isMaxInclusive())]true[else]false[/if], [diagnostics/], [_context/]); - [/if] - return [result/]; - [else] - [let comparison : String = if ('comparison' = genClassifier.getSafeUncapName()) then 'theComparison' else 'comparison' endif] - [if (genDataType.isXMLCalendar())] - int [comparison/] = [genModel.getImportedName('org.eclipse.emf.ecore.xml.type.util.XMLTypeUtil')/].compareCalendar([genDataType.getSafeUncapName()/], [constant/]__VALUE); - boolean [result/] = [if (genDataType.isMaxInclusive())][comparison/] == 0 || [/if][comparison/] == -1; - [else][if (genDataType.isXMLDuration())] - int [comparison/] = [genModel.getImportedName('org.eclipse.emf.ecore.xml.type.util.XMLTypeUtil')/].compareDuration([genDataType.getSafeUncapName()/], [constant/]__VALUE); - boolean [result/] = [if (genDataType.isMaxInclusive())][comparison/] == 0 || [/if][comparison/] == -1; - [else] - boolean [result/] = [genDataType.getSafeUncapName()/].compareTo([constant/]__VALUE) [if (genDataType.isMaxInclusive())]<=[else]<[/if] 0; - [/if][/if] - if (![result/] && [diagnostics/] != null) - reportMaxViolation([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/], [constant/]__VALUE, [if (genDataType.isMaxInclusive())]true[else]false[/if], [diagnostics/], [_context/]); - return [result/]; - [/let] - [/if] -[else][if (constraint = 'MinLength' and genDataType.getMinLength() <> -1)] - int length = [genDataType.getSafeUncapName()/].[genDataType.getLengthAccessorFunction()/]; - boolean [result/] = length >= [genDataType.getMinLength()/]; - if (![result/] && [diagnostics/] != null) - reportMinLengthViolation([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/], length, [genDataType.getMinLength()/], [diagnostics/], [_context/]); - return [result/]; -[else][if (constraint = 'MaxLength' and genDataType.getMaxLength() <> -1)] - int length = [genDataType.getSafeUncapName()/].[genDataType.getLengthAccessorFunction()/]; - boolean [result/] = length <= [genDataType.getMaxLength()/]; - if (![result/] && [diagnostics/] != null) - reportMaxLengthViolation([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/], length, [genDataType.getMaxLength()/], [diagnostics/], [_context/]); - return [result/]; -[else][if (constraint = 'TotalDigits' and genDataType.getTotalDigits() <> -1)] - [if (genDataType.isPrimitiveType())] - boolean [result/] = [genDataType.getSafeUncapName()/] > [constant/]__LOWER_BOUND && [genDataType.getSafeUncapName()/] < [constant/]__UPPER_BOUND; - if (![result/] && [diagnostics/] != null) - [if (not genModel.isJDK50())] - reportTotalDigitsViolation([genDataType.getQualifiedClassifierAccessor()/], new [genDataType.getObjectInstanceClassName()/]([genDataType.getSafeUncapName()/]), [genDataType.getTotalDigits()/], [diagnostics/], [_context/]); - [else] - reportTotalDigitsViolation([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/], [genDataType.getTotalDigits()/], [diagnostics/], [_context/]); - [/if] - [else][if (genDataType.getQualifiedInstanceClassName() = 'java.math.BigDecimal')] - boolean [result/] = [genDataType.getSafeUncapName()/].unscaledValue().abs().toString().length() <= [genDataType.getTotalDigits()/]; - if (![result/] && [diagnostics/] != null) - reportTotalDigitsViolation([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/], [genDataType.getTotalDigits()/], [diagnostics/], [_context/]); - [else] - boolean [result/] = [genDataType.getSafeUncapName()/].compareTo([constant/]__LOWER_BOUND) > 0 && [genDataType.getSafeUncapName()/].compareTo([constant/]__UPPER_BOUND) < 0; - if (![result/] && [diagnostics/] != null) - reportTotalDigitsViolation([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/], [genDataType.getTotalDigits()/], [diagnostics/], [_context/]); - [/if][/if] - return [result/]; -[else][if (constraint = 'FractionDigits' and genDataType.getFractionDigits() <> -1 and genDataType.getQualifiedInstanceClassName() = 'java.math.BigDecimal')] - boolean [result/] = [genDataType.getSafeUncapName()/].scale() <= [genDataType.getFractionDigits()/]; - if (![result/] && [diagnostics/] != null) - reportFractionDigitsViolation([genDataType.getQualifiedClassifierAccessor()/], [genDataType.getSafeUncapName()/], [genDataType.getFractionDigits()/], [diagnostics/], [_context/]); - return [result/]; -[else][if (constraintDelegate <> null)] - // TODO override the constraint, if desired - // -> uncomment the scaffolding - // -> specify the condition that violates the constraint - // -> verify the diagnostic details, including severity, code, and message - // Ensure that you remove @generated or mark it @generated NOT - if (false) - { - if ([diagnostics/] != null) - { - [diagnostics/].add - [if (genModel.isEMF24())] - (createDiagnostic - ([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - DIAGNOSTIC_SOURCE, - 0, - "_UI_GenericConstraint_diagnostic",[genModel.getNonNLS()/] - new Object['[]'/] { "[constraint/]", getValueLabel([genDataType.getQualifiedClassifierAccessor()/], [genClassifier.getSafeUncapName()/], [_context/]) },[genModel.getNonNLS()/] - new Object['[]'/] { [genClassifier.getSafeUncapName()/] }, - context)); - [else] - (new [genModel.getImportedName('org.eclipse.emf.common.util.BasicDiagnostic')/] - ([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - DIAGNOSTIC_SOURCE, - 0, - [genModel.getImportedName('org.eclipse.emf.ecore.plugin.EcorePlugin')/].INSTANCE.getString("_UI_GenericConstraint_diagnostic", new Object['[]'/] { "[constraint/]", getValueLabel([genDataType.getQualifiedClassifierAccessor()/], [genClassifier.getSafeUncapName()/], [_context/]) }),[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - new Object['[]'/] { [genClassifier.getSafeUncapName()/] })); - [/if] - } - return false; - } - return [delegate/]validate[constraintDelegate.getName()/]_[constraint/]([genClassifier.getSafeUncapName()/][accessor/], [diagnostics/], [_context/]); -[else] - [if (genClassifier.hasConstraintExpression(constraint))] - return - validate - ([genClassifier.getQualifiedClassifierAccessor()/], - [genClassifier.getSafeUncapName()/], - [diagnostics/], - [_context/], - "[genClassifier.getValidationDelegate(constraint)/]",[genModel.getNonNLS()/] - "[constraint/]",[genModel.getNonNLS()/] - [genClassifier.getClassifierID()/]__[constraint.upperNameConstraint()/]__EEXPRESSION, - [genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - DIAGNOSTIC_SOURCE, - 0); - [else] - // TODO implement the constraint - // -> specify the condition that violates the constraint - // -> verify the diagnostic details, including severity, code, and message - // Ensure that you remove @generated or mark it @generated NOT - if (false) - { - if ([diagnostics/] != null) - { - [diagnostics/].add - [if (genModel.isEMF24())] - (createDiagnostic - ([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - DIAGNOSTIC_SOURCE, - 0, - "_UI_GenericConstraint_diagnostic",[genModel.getNonNLS()/] - new Object['[]'/] { "[constraint/]", getValueLabel([genDataType.getQualifiedClassifierAccessor()/], [genClassifier.getSafeUncapName()/], [_context/]) },[genModel.getNonNLS()/] - new Object['[]'/] { [genClassifier.getSafeUncapName()/] }, - context)); - [else] - (new [genModel.getImportedName('org.eclipse.emf.common.util.BasicDiagnostic')/] - ([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - DIAGNOSTIC_SOURCE, - 0, - [genModel.getImportedName('org.eclipse.emf.ecore.plugin.EcorePlugin')/].INSTANCE.getString("_UI_GenericConstraint_diagnostic", new Object['[]'/] { "[constraint/]", getValueLabel([genDataType.getQualifiedClassifierAccessor()/], [genClassifier.getSafeUncapName()/], [_context/]) }),[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - new Object['[]'/] { [genClassifier.getSafeUncapName()/] })); - [/if] - } - return false; - } - return true; - [/if] -[/if][/if][/if][/if][/if][/if][/if][/if][/if][/if][/if] - [/let] - [let genOperation : GenOperation = genClassifier.oclAsType(GenClass).getInvariantOperation(constraint)] - [if (genOperation <> null)] - return [genClassifier.getSafeUncapName()/].[constraint/]([diagnostics/], [_context/]); - [/if] - [/let] -[else][if (constraintDelegate <> null)] - // TODO override the constraint, if desired - // -> uncomment the scaffolding - // -> specify the condition that violates the constraint - // -> verify the diagnostic details, including severity, code, and message - // Ensure that you remove @generated or mark it @generated NOT - if (false) - { - if ([diagnostics/] != null) - { - [diagnostics/].add - [if (genModel.isEMF24())] - (createDiagnostic - ([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - DIAGNOSTIC_SOURCE, - 0, - "_UI_GenericConstraint_diagnostic",[genModel.getNonNLS()/] - new Object['[]'/] { "[constraint/]", getObjectLabel([genClassifier.getSafeUncapName()/], [_context/]) },[genModel.getNonNLS()/] - new Object['[]'/] { [genClassifier.getSafeUncapName()/] }, - context)); - [else] - (new [genModel.getImportedName('org.eclipse.emf.common.util.BasicDiagnostic')/] - ([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - DIAGNOSTIC_SOURCE, - 0, - [genModel.getImportedName('org.eclipse.emf.ecore.plugin.EcorePlugin')/].INSTANCE.getString("_UI_GenericConstraint_diagnostic", new Object['[]'/] { "[constraint/]", getObjectLabel([genClassifier.getSafeUncapName()/], [_context/]) }),[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - new Object['[]'/] { [genClassifier.getSafeUncapName()/] })); - [/if] - } - return false; - } - return [delegate/]validate[constraintDelegate.getName()/]_[constraint/]([cast/][genClassifier.getSafeUncapName()/], [diagnostics/], [_context/]); -[else] - [if (genClassifier.hasConstraintExpression(constraint))] - return - validate - ([genClassifier.getQualifiedClassifierAccessor()/], - [genClassifier.getSafeUncapName()/], - [diagnostics/], - [_context/], - "[genClassifier.getValidationDelegate(constraint)/]",[genModel.getNonNLS()/] - "[constraint/]",[genModel.getNonNLS()/] - [genClassifier.getClassifierID()/]__[constraint.upperNameConstraint()/]__EEXPRESSION, - [genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - DIAGNOSTIC_SOURCE, - 0); - [else] - // TODO implement the constraint - // -> specify the condition that violates the constraint - // -> verify the diagnostic details, including severity, code, and message - // Ensure that you remove @generated or mark it @generated NOT - if (false) - { - if ([diagnostics/] != null) - { - [diagnostics/].add - [if (genModel.isEMF24())] - (createDiagnostic - ([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - DIAGNOSTIC_SOURCE, - 0, - "_UI_GenericConstraint_diagnostic",[genModel.getNonNLS()/] - new Object['[]'/] { "[constraint/]", getObjectLabel([genClassifier.getSafeUncapName()/], [_context/]) },[genModel.getNonNLS()/] - new Object['[]'/] { [genClassifier.getSafeUncapName()/] }, - context)); - [else] - (new [genModel.getImportedName('org.eclipse.emf.common.util.BasicDiagnostic')/] - ([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - DIAGNOSTIC_SOURCE, - 0, - [genModel.getImportedName('org.eclipse.emf.ecore.plugin.EcorePlugin')/].INSTANCE.getString("_UI_GenericConstraint_diagnostic", new Object['[]'/] { "[constraint/]", getObjectLabel([genClassifier.getSafeUncapName()/], [_context/]) }),[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - new Object['[]'/] { [genClassifier.getSafeUncapName()/] })); - [/if] - } - return false; - } - return true; - [/if] -[/if][/if] - } - - [/let] - [/let] - [/let] - [/let] - [/let] -[/for] - [/let] - [/let] - [/let] - [/let] -[/for] -[if (genModel.isEMF24())] - /** - * Returns the resource locator that will be used to fetch messages for this validator's diagnostics. - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - public [genModel.getImportedName('org.eclipse.emf.common.util.ResourceLocator')/] getResourceLocator() - { - [if (genModel.hasModelPluginClass())] - return [genModel.getImportedName(genModel.getQualifiedModelPluginClassName())/].INSTANCE; - [else] - // TODO - // Specialize this to return a resource locator for messages specific to this validator. - // Ensure that you remove @generated or mark it @generated NOT - return super.getResourceLocator(); - [/if] - } - -[/if] -} //[genPackage.getValidatorClassName()/] -[/template] - -[query public validatorClassPath(genPackage : GenPackage) : String - = genPackage.genModel.extractSourceDirectory(genPackage.genModel.modelDirectory) + '/' - + genPackage.getQualifiedValidatorClassName().toPath() + '.java'/] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/XmlProcessorClass.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/XmlProcessorClass.mtl deleted file mode 100644 index e255c57d9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/XmlProcessorClass.mtl +++ /dev/null @@ -1,104 +0,0 @@ -[comment encoding = UTF-8 /] -[module XmlProcessorClass('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] - -[comment] -/** - * - * - * Copyright (c) 2005-2006 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -[/comment] - -[template public xmlProcessorClass(genPackage : GenPackage) { genModel : GenModel = genPackage.genModel; packageName : String = genPackage.getUtilitiesPackageName(); className : String = genPackage.getXMLProcessorClassName();} ] -[genModel.initializeImportManager(packageName, className)/] - -[genModel.getImportedName('java.util.Map')/] - -[file (genPackage.xmlProcessorClassPath(), false, 'UTF-8')] -[genModel.includeHeader()/] -package [packageName/]; -[let content : String = genPackage.xmlProcessorFileContent(genModel, className)] -[genModel.genSortedImports()/] - -[content/] -[/let] -[/file] -[/template] - -[template protected xmlProcessorFileContent(genPackage : GenPackage, genModel : GenModel, className : String)] -/** - * This class contains helper methods to serialize and deserialize XML documents - * - * - * @generated - */ -public class [className/] extends [genPackage.getImportedXMLProcessorBaseClassName()/] -{ -[if (genModel.hasCopyrightField())] - /** - * - * - * @generated - */ - public static final [genModel.getImportedName('java.lang.String')/] copyright = [genModel.getCopyrightFieldLiteral()/];[genModel.getNonNLS()/] - -[/if] - - /** - * Public constructor to instantiate the helper. - * - * - * @generated - */ - public [genPackage.getXMLProcessorClassName()/]() - { -[if (genPackage.hasExtendedMetaData() and not genPackage.hasTargetNamespace())] - super(new [genModel.getImportedName('org.eclipse.emf.ecore.impl.EPackageRegistryImpl')/]([genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE)); - extendedMetaData.putPackage(null, [genPackage.getImportedPackageInterfaceName()/].eINSTANCE); -[else] - super(([genModel.getImportedName('org.eclipse.emf.ecore.EPackage')/].Registry.INSTANCE)); - [genPackage.getImportedPackageInterfaceName()/].eINSTANCE.eClass(); -[/if] - } - - /** - * Register for "*" and "xml" file extensions the [genPackage.getResourceFactoryClassName()/] factory. - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation())] - @Override - [/if] - protected Map[if (genModel.isJDK50())]<[genModel.getImportedName('java.lang.String')/], [genModel.getImportedName('org.eclipse.emf.ecore.resource.Resource')/].Factory>[/if] getRegistrations() - { - if (registrations == null) - { - super.getRegistrations(); - registrations.put(XML_EXTENSION, new [genPackage.getResourceFactoryClassName()/]()); - registrations.put(STAR_EXTENSION, new [genPackage.getResourceFactoryClassName()/]()); - } - return registrations; - } - -} //[genPackage.getXMLProcessorClassName()/] -[/template] - -[query public xmlProcessorClassPath(genPackage : GenPackage) : String - = genPackage.genModel.extractSourceDirectory(genPackage.genModel.modelDirectory) + '/' - + genPackage.getQualifiedXMLProcessorClassName().toPath() + '.java'/] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/buildproperties.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/buildproperties.mtl deleted file mode 100644 index b191ba9d1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/buildproperties.mtl +++ /dev/null @@ -1,36 +0,0 @@ -[comment encoding = UTF-8 /] -[module buildproperties('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::common /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] - -[template public buildProperties(genModel : GenModel)] -[let pluginClassesLocation : String = if genModel.runtimeJar then genModel.modelPluginID + '.jar' else '.' endif] -[file (genModel.buildPropertiesFilePath(), false, 'UTF-8')] -[genModel.includeHeaderProperties()/] -bin.includes = [pluginClassesLocation/],\ - model/,\ -[if (genModel.sameModelEditProject() or genModel.sameModelEditorProject()) ] - icons/,\ -[/if] -[if (genModel.bundleManifest) ] - META-INF/,\ -[/if] -[if (genModel.runtimePlatform <> GenRuntimePlatform::GWT) ] - plugin.xml,\ -[/if] - plugin.properties -jars.compile.order = [pluginClassesLocation/] -source.[pluginClassesLocation/] = [for (sourceFolder : String | genModel.getModelSourceFolders()) separator (',\\ ')] -[sourceFolder/] -[/for] -[comment][sourceFolders->sep(',\\'.concat(genModel.getLineDelimiter())/][/comment] -output.[pluginClassesLocation/] = bin/ -[/file] -[/let] -[/template] - -[query public buildPropertiesFilePath(genModel : GenModel) : String = 'build.properties' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/eIsSet.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/eIsSet.mtl deleted file mode 100644 index a438b94e2..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/eIsSet.mtl +++ /dev/null @@ -1,120 +0,0 @@ -[comment encoding = UTF-8 /] -[module eIsSet('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenOperation /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenParameter /] - -[template public eIsSet(genClass : GenClass, genModel : GenModel, positiveOffsetCorrection : String, negativeOffsetCorrection : String)] - /** - * - * - * @generated - */ - [if (genModel.useGenerics()) ] - [if (genClass.getEIsSetGenFeatures()->filter(GenFeature)->select(genFeature : GenFeature | genFeature.isListType() and not genFeature.isUnsettable() and not genFeature.isWrappedFeatureMapType() and not genClass.isField(genFeature) and genFeature.isField() and genClass.getImplementingGenModel(genFeature).isVirtualDelegation()))->notEmpty()] - @SuppressWarnings("unchecked") - [/if] - [/if] - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public boolean eIsSet(int featureID) { - switch (featureID[negativeOffsetCorrection/]) { -[for (genFeature : GenFeature | genClass.getEIsSetGenFeatures())] - [let safeNameAccessor : String = if (genFeature.getSafeName() = 'featureID') then 'this.' + genFeature.getSafeName() else genFeature.getSafeName() endif] - case [genClass.getQualifiedFeatureID(genFeature)/]: - [if (genFeature.hasSettingDelegate()) ] - [if (genFeature.isUnsettable()) ] - return isSet[genFeature.getAccessorName()/](); - [else] - return [genFeature.getUpperName()/]__ESETTING_DELEGATE.dynamicIsSet(this, null, 0); - [/if] - [else][if (genFeature.isListType() and not genFeature.isUnsettable()) ] - [if (genFeature.isWrappedFeatureMapType()) ] - [if (genFeature.isVolatile()) ] - return !(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)[genFeature.getGetAccessor()/]()).featureMap().isEmpty(); - [else] - return [safeNameAccessor/] != null && ![safeNameAccessor/].featureMap().isEmpty(); - [/if] - [else] - [if (genClass.isField(genFeature)) ] - return [safeNameAccessor/] != null && ![safeNameAccessor/].isEmpty(); - [else] - [if (genFeature.isField() and genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) ] - [genFeature.getImportedType(genClass)/] [safeNameAccessor/] = ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - return [safeNameAccessor/] != null && ![safeNameAccessor/].isEmpty(); - [else] - return ![genFeature.getGetAccessor()/]().isEmpty(); - [/if] - [/if] - [/if] - [else][if (genFeature.isUnsettable()) ] - return isSet[genFeature.getAccessorName()/](); - [else][if (genFeature.isResolveProxies()) ] - [if (genClass.isField(genFeature)) ] - return [safeNameAccessor/] != null; - [else] - [if (genFeature.isField() and genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) ] - return eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]) != null; - [else] - return basicGet[genFeature.getAccessorName()/]() != null; - [/if] - [/if] - [else][if (not genFeature.hasEDefault()) ] - [if (genClass.isField(genFeature)) ] - return [safeNameAccessor/] != null; - [else] - [if (genFeature.isField() and genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) ] - return eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]) != null; - [else] - return [genFeature.getGetAccessor()/]() != null; - [/if] - [/if] - [else][if (genFeature.isPrimitiveType() or genFeature.isEnumType()) ] - [if (genClass.isField(genFeature)) ] - [if (genClass.isFlag(genFeature)) ] - [if (genFeature.isBooleanType()) ] - return (([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) != 0) != [genFeature.getEDefault()/]; - [else] - return ([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) != [genFeature.getUpperName()/]_EFLAG_DEFAULT; - [/if] - [else] - return [safeNameAccessor/] != [genFeature.getEDefault()/]; - [/if] - [else] - [if (genFeature.isEnumType() and genFeature.isField() and genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) ] - return eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [genFeature.getEDefault()/]) != [genFeature.getEDefault()/]; - [else] - return [genFeature.getGetAccessor()/]() != [genFeature.getEDefault()/]; - [/if] - [/if] - [else] - [if (genClass.isField(genFeature)) ] - return [genFeature.getEDefault()/] == null ? [safeNameAccessor/] != null : ![genFeature.getEDefault()/].equals([safeNameAccessor/]); - [else] - [if (genFeature.isField() and genClass.getImplementingGenModel(genFeature).isVirtualDelegation()) ] - [genFeature.getImportedType(genClass)/] [safeNameAccessor/] = ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [genFeature.getEDefault()/]); - return [genFeature.getEDefault()/] == null ? [safeNameAccessor/] != null : ![genFeature.getEDefault()/].equals([safeNameAccessor/]); - [else] - return [genFeature.getEDefault()/] == null ? [genFeature.getGetAccessor()/]() != null : ![genFeature.getEDefault()/].equals([genFeature.getGetAccessor()/]()); - [/if] - [/if] - [/if][/if][/if][/if][/if][/if] - [/let] -[/for] - } -[if (genModel.minimalReflectiveMethods) ] - return super.eIsSet(featureID); -[else] - return eDynamicIsSet(featureID); -[/if] - } - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/eUnset.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/eUnset.mtl deleted file mode 100644 index 9a5731775..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/eUnset.mtl +++ /dev/null @@ -1,44 +0,0 @@ -[comment encoding = UTF-8 /] -[module eUnset('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] - -[template public eUnset(genClass : GenClass, genModel : GenModel, negativeOffsetCorrection : String)] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - public void eUnset(int featureID) { - switch (featureID[negativeOffsetCorrection/]) { - [for (genFeature : GenFeature | genClass.getEUnsetGenFeatures())] - case [genClass.getQualifiedFeatureID(genFeature)/]: - [if (genFeature.isListType() and not genFeature.isUnsettable()) ] - [if (genFeature.isWrappedFeatureMapType()) ] - (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)[genFeature.getGetAccessor()/]()).featureMap().clear(); - [else] - [genFeature.getGetAccessor()/]().clear(); - [/if] - [else][if (genFeature.isUnsettable()) ] - unset[genFeature.getAccessorName()/](); - [else][if (not genFeature.hasEDefault()) ] - set[genFeature.getAccessorName()/](([genFeature.getImportedType(genClass)/])null); - [else] - set[genFeature.getAccessorName()/]([genFeature.getEDefault()/]); - [/if][/if][/if] - return; - [/for] - } - [if (genModel.minimalReflectiveMethods) ] - super.eUnset(featureID); - [else] - eDynamicUnset(featureID); - [/if] - } - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genDeclaredFields.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genDeclaredFields.mtl deleted file mode 100644 index 85e96a8eb..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genDeclaredFields.mtl +++ /dev/null @@ -1,196 +0,0 @@ -[comment encoding = UTF-8 /] -[module genDeclaredFields('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] - -[template public genDeclaredFields(genFeature : GenFeature, genClass : GenClass, genModel : GenModel, isGWT : Boolean, isJDK50 : Boolean)] - [if (genFeature.hasSettingDelegate())] - /** - * The cached setting delegate for the '{@link #[genFeature.getGetAccessor()/]() [genFeature.getFormattedName()/]}' [genFeature.getFeatureKind()/]. - * - * - * @see #[genFeature.getGetAccessor()/]() - * @generated - * @ordered - */ - [if (isGWT) ] - @[genModel.getImportedName('com.google.gwt.user.client.rpc.GwtTransient')/] - [/if] - protected [genModel.getImportedName('org.eclipse.emf.ecore.EStructuralFeature')/].Internal.SettingDelegate [genFeature.getUpperName()/]__ESETTING_DELEGATE = (([genModel.getImportedName('org.eclipse.emf.ecore.EStructuralFeature')/].Internal)[genFeature.getQualifiedFeatureAccessor()/]).getSettingDelegate(); - - [else][if (genFeature.isListType() or genFeature.isReferenceType())] - [if (genClass.isField(genFeature)) ] - /** - * The cached value of the '{@link #[genFeature.getGetAccessor()/]() [genFeature.getFormattedName()/]}' [genFeature.getFeatureKind()/]. - * - * - * @see #[genFeature.getGetAccessor()/]() - * @generated - * @ordered - */ - [if (isGWT) ] - @[genModel.getImportedName('com.google.gwt.user.client.rpc.GwtTransient')/] - [/if] - protected [genFeature.getImportedInternalType(genClass)/] [genFeature.getSafeName()/]; - - [/if] - [if (genModel.arrayAccessors and genFeature.isListType() and not genFeature.isFeatureMapType() and not genFeature.isMapType())] - [let rawListItemType : String = genFeature.getRawListItemType()] - [let index : Integer = rawListItemType.index('[')] - [let head : String = if (index <> -1) then rawListItemType.substring(1, index) else rawListItemType endif] - [let tail : String = if (index <> -1) then rawListItemType.substring(index + 1) else '' endif] - /** - * The empty value for the '{@link #[genFeature.getGetArrayAccessor()/]() [genFeature.getFormattedName()/]}' array accessor. - * - * - * @see #[genFeature.getGetArrayAccessor()/]() - * @generated - * @ordered - */ - [if (genFeature.getQualifiedListItemType(genClass).contains('<')) ] - @SuppressWarnings("unchecked") - [/if] - protected static final [rawListItemType/]['[]'/] [genFeature.getUpperName()/]_EEMPTY_ARRAY = new [head/] ['[0]'/][tail/]; - - [/let] - [/let] - [/let] - [/let] - [/if] - [else] - [if (genFeature.hasEDefault() and (not genFeature.isVolatile() or not genModel.reflectiveDelegation and (not genFeature.hasDelegateFeature() or not genFeature.isUnsettable())))] - [let staticDefaultValue : String = genFeature.getStaticDefaultValue()] - /** - * The default value of the '{@link #[genFeature.getGetAccessor()/]() [genFeature.getFormattedName()/]}' [genFeature.getFeatureKind()/]. - * - * - * @see #[genFeature.getGetAccessor()/]() - * @generated - * @ordered - */ - [if (genModel.useGenerics() and genFeature.isListDataType() and genFeature.isSetDefaultValue()) ] - @SuppressWarnings("unchecked") - [/if] - protected static final [genFeature.getImportedType(genClass)/] [genFeature.getEDefault()/][if (staticDefaultValue = '') ]; // TODO The default value literal "[genFeature.ecoreFeature.defaultValueLiteral/]" is not valid.[else] = [staticDefaultValue/];[genModel.getNonNLS(staticDefaultValue)/][/if] - - [/let] - [/if] - [if (genClass.isField(genFeature)) ] - [if (genClass.isFlag(genFeature))] - [let flagIndex : Integer = genClass.getFlagIndex(genFeature)] - [if (flagIndex > 31 and flagIndex.mod(32) = 0)] - /** - * An additional set of bit flags representing the values of boolean attributes and whether unsettable features have been set. - * - * - * @generated - * @ordered - */ - [if (isGWT)] - @[genModel.getImportedName('com.google.gwt.user.client.rpc.GwtTransient')/] - [/if] - protected int [genClass.getFlagsField(genFeature)/] = 0; - - [/if] - [if (genFeature.isEnumType())] - /** - * The offset of the flags representing the value of the '{@link #[genFeature.getGetAccessor()/]() [genFeature.getFormattedName()/]}' [genFeature.getFeatureKind()/]. - * - * - * @generated - * @ordered - */ - protected static final int [genFeature.getUpperName()/]_EFLAG_OFFSET = [flagIndex.mod(32)/]; - - /** - * The flags representing the default value of the '{@link #[genFeature.getGetAccessor()/]() [genFeature.getFormattedName()/]}' [genFeature.getFeatureKind()/]. - * - * - * @generated - * @ordered - */ - protected static final int [genFeature.getUpperName()/]_EFLAG_DEFAULT = [if (isJDK50) ][genFeature.getEDefault()/].ordinal()[else][genFeature.getImportedType(genClass)/].VALUES.indexOf([genFeature.getEDefault()/])[/if] << [genFeature.getUpperName()/]_EFLAG_OFFSET; - - /** - * The array of enumeration values for '{@link [genFeature.getImportedType(genClass)/] [genFeature.getTypeGenClassifier().getFormattedName()/]}' - * - * - * @generated - * @ordered - */ - private static final [genFeature.getImportedType(genClass)/]['[]'/] [genFeature.getUpperName()/]_EFLAG_VALUES = [if (isJDK50) ][genFeature.getImportedType(genClass)/].values()[else]([genFeature.getImportedType(genClass)/]['[]'/])[genFeature.getImportedType(genClass)/].VALUES.toArray(new [genFeature.getImportedType(genClass)/]['['/][genFeature.getImportedType(genClass)/].VALUES->size()])[/if]; - - [/if] - /** - * The flag[if genClass.getFlagSize(genFeature) > 1]s[/if] representing the value of the '{@link #[genFeature.getGetAccessor()/]() [genFeature.getFormattedName()/]}' [genFeature.getFeatureKind()/]. - * - * - * @see #[genFeature.getGetAccessor()/]() - * @generated - * @ordered - */ - protected static final int [genFeature.getUpperName()/]_EFLAG = [genClass.getFlagMask(genFeature)/] << [if (genFeature.isEnumType()) ][genFeature.getUpperName()/]_EFLAG_OFFSET[else][flagIndex.mod(32)/][/if]; - - [/let] - [else] - /** - * The cached value of the '{@link #[genFeature.getGetAccessor()/]() [genFeature.getFormattedName()/]}' [genFeature.getFeatureKind()/]. - * - * - * @see #[genFeature.getGetAccessor()/]() - * @generated - * @ordered - */ - [if (isGWT) ] - @[genModel.getImportedName('com.google.gwt.user.client.rpc.GwtTransient')/] - [/if] - protected [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/][if (genFeature.hasEDefault()) ] = [genFeature.getEDefault()/][/if]; - - [/if] - [/if] - [/if][/if] - [if (genClass.isESetField(genFeature)) ] - [if (genClass.isESetFlag(genFeature))] - [let flagIndex : Integer = genClass.getESetFlagIndex(genFeature)] - [if (flagIndex > 31 and flagIndex.mod(32) = 0) ] - /** - * An additional set of bit flags representing the values of boolean attributes and whether unsettable features have been set. - * - * - * @generated - * @ordered - */ - [if (isGWT) ] - @[genModel.getImportedName('com.google.gwt.user.client.rpc.GwtTransient')/] - [/if] - protected int [genClass.getESetFlagsField(genFeature)/] = 0; - - [/if] - /** - * The flag representing whether the [genFeature.getFormattedName()/] [genFeature.getFeatureKind()/] has been set. - * - * - * @generated - * @ordered - */ - protected static final int [genFeature.getUpperName()/]_ESETFLAG = 1 << [flagIndex.mod(32) /]; - [/let] - [else] - /** - * This is true if the [genFeature.getFormattedName()/] [genFeature.getFeatureKind()/] has been set. - * - * - * @generated - * @ordered - */ - [if (isGWT) ] - @[genModel.getImportedName('com.google.gwt.user.client.rpc.GwtTransient')/] - [/if] - protected boolean [genFeature.getUncapName()/]ESet; - - [/if] - [/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genFeature.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genFeature.mtl deleted file mode 100644 index e7a1f7905..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genFeature.mtl +++ /dev/null @@ -1,913 +0,0 @@ -[comment encoding = UTF-8 /] -[module genFeature('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenOperation /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenParameter /] - -[template public genFeature(genFeature : GenFeature, genClass : GenClass, genPackage : GenPackage, genModel : GenModel, isJDK50 : Boolean, isInterface : Boolean, isImplementation : Boolean, positiveOffsetCorrection : String, negativeOffsetCorrection : String, singleWildcard : String)] -[if (genModel.arrayAccessors and genFeature.isListType() and not genFeature.isFeatureMapType() and not genFeature.isMapType()) ] - /** - * - * - * @generated - */ - [if (not isImplementation) ] - [genFeature.getListItemType(genClass)/]['[]'/] [genFeature.getGetArrayAccessor()/](); - - [else] - public [genFeature.getListItemType(genClass)/]['[]'/] [genFeature.getGetArrayAccessor()/]() { - [if (genFeature.isVolatile()) ] - [genModel.getImportedName('org.eclipse.emf.common.util.BasicEList')/][genFeature.getListTemplateArguments(genClass)/] list = ([genModel.getImportedName('org.eclipse.emf.common.util.BasicEList')/][genFeature.getListTemplateArguments(genClass)/])[genFeature.getGetAccessor()/](); - if (list.isEmpty()) return [if (genModel.useGenerics() and not genFeature.getListItemType(genClass).contains('<') and genFeature.getListItemType(null) <> genFeature.getListItemType(genClass)) ]([genFeature.getListItemType(genClass)/]['[]'/])[/if][genFeature.getUpperName()/]_EEMPTY_ARRAY; - [else] - if ([genFeature.getSafeName()/] == null || [genFeature.getSafeName()/].isEmpty()) return [if (genModel.useGenerics() and not genFeature.getListItemType(genClass).contains('<') and genFeature.getListItemType(null) <> genFeature.getListItemType(genClass)) ]([genFeature.getListItemType(genClass)/]['[]'/])[/if][genFeature.getUpperName()/]_EEMPTY_ARRAY; - [genModel.getImportedName('org.eclipse.emf.common.util.BasicEList')/][genFeature.getListTemplateArguments(genClass)/] list = ([genModel.getImportedName('org.eclipse.emf.common.util.BasicEList')/][genFeature.getListTemplateArguments(genClass)/])[genFeature.getSafeName()/]; - [/if] - list.shrink(); - return ([genFeature.getListItemType(genClass)/]['[]'/])list.data(); - } - - [/if] - /** - * - * - * @generated - */ - [if (not isImplementation) ] - [genFeature.getListItemType(genClass)/] get[genFeature.getAccessorName()/](int index); - - [else] - public [genFeature.getListItemType(genClass)/] get[genFeature.getAccessorName()/](int index) { - return [if (not genModel.useGenerics()) ]([genFeature.getListItemType(genClass)/])[/if][genFeature.getGetAccessor()/]().get(index); - } - - [/if] - /** - * - * - * @generated - */ - [if (not isImplementation) ] - int get[genFeature.getAccessorName()/]Length(); - - [else] - public int get[genFeature.getAccessorName()/]Length() { - [if (genFeature.isVolatile()) ] - return [genFeature.getGetAccessor()/]().size(); - [else] - return [genFeature.getSafeName()/] == null ? 0 : [genFeature.getSafeName()/].size(); - [/if] - } - - [/if] - /** - * - * - * @generated - */ - [if (not isImplementation) ] - void set[genFeature.getAccessorName()/]([genFeature.getListItemType(genClass)/]['[]'/] new[genFeature.getCapName()/]); - - [else] - public void set[genFeature.getAccessorName()/]([genFeature.getListItemType(genClass)/]['[]'/] new[genFeature.getCapName()/]) { - (([genModel.getImportedName('org.eclipse.emf.common.util.BasicEList')/][genFeature.getListTemplateArguments(genClass)/])[genFeature.getGetAccessor()/]()).setData(new[genFeature.getCapName()/].length, new[genFeature.getCapName()/]); - } - - [/if] - /** - * - * - * @generated - */ - [if (not isImplementation) ] - void set[genFeature.getAccessorName()/](int index, [genFeature.getListItemType(genClass)/] element); - - [else] - public void set[genFeature.getAccessorName()/](int index, [genFeature.getListItemType(genClass)/] element) { - [genFeature.getGetAccessor()/]().set(index, element); - } - - [/if] -[/if] -[if (genFeature.isGet() and (isImplementation or not genFeature.isSuppressedGetVisibility()))] - [if (isInterface)] - /** - * Returns the value of the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/]. - [if (genFeature.isListType())] - [if (genFeature.isMapType())] - [let keyFeature : GenFeature = genFeature.getMapEntryTypeGenClass().getMapEntryKeyFeature()] - [let valueFeature : GenFeature = genFeature.getMapEntryTypeGenClass().getMapEntryValueFeature()] - * The key is of type [if (keyFeature.isListType()) ]list of {@link [keyFeature.getQualifiedListItemType(genClass)/]}[else]{@link [keyFeature.getType(genClass)/]}[/if], - * and the value is of type [if (valueFeature.isListType()) ]list of {@link [valueFeature.getQualifiedListItemType(genClass)/]}[else]{@link [valueFeature.getType(genClass)/]}[/if], - [/let] - [/let] - [else][if (not genFeature.isWrappedFeatureMapType() and not (genModel.suppressEMFMetaData and 'org.eclipse.emf.ecore.EObject' = genFeature.getQualifiedListItemType(genClass)))] - [let typeName : String = genFeature.getQualifiedListItemType(genClass)] - [let index : Integer = if typeName.index('<') < 0 then typeName.index('[') else typeName.index('<') endif] - [let head : String = if index < 0 then typeName else typeName.substring(1, index - 1) endif] - [let tail : String = if index < 0 then '' else typeName.substring(index).replaceAll('<', '<') endif] - * The list contents are of type {@link [head/]}[tail/]. - [/let] - [/let] - [/let] - [/let] - [/if][/if] - [else][if (genFeature.isSetDefaultValue()) ] - * The default value is [genFeature.getDefaultValue()/]. - [/if][/if] - [if (genFeature.getTypeGenEnum() <> null) ] - * The literals are from the enumeration {@link [genFeature.getTypeGenEnum().getQualifiedName()/]}. - [/if] - [if (genFeature.isBidirectional() and not genFeature.getReverse().genClass.isMapEntry())] - [let reverseGenFeature : GenFeature = genFeature.getReverse()] - [if (not reverseGenFeature.isSuppressedGetVisibility()) ] - * It is bidirectional and its opposite is '{@link [reverseGenFeature.genClass.getQualifiedInterfaceName()/]#[reverseGenFeature.getGetAccessor()/] [reverseGenFeature.getFormattedName()/]}'. - [/if] - [/let] - [/if] - * - [if (not genFeature.hasDocumentation()) ] - *

- * If the meaning of the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/] isn't clear, - * there really should be more of a description here... - *

- [/if] - * - [if (genFeature.hasDocumentation()) ] - * - * [genFeature.getDocumentation(genModel.getIndentation())/] - * - [/if] - * @return the value of the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/]. - [if (genFeature.getTypeGenEnum() <> null) ] - * @see [genFeature.getTypeGenEnum().getQualifiedName()/] - [/if] - [if (genFeature.isUnsettable()) ] - [if (not genFeature.isSuppressedIsSetVisibility()) ] - * @see #isSet[genFeature.getAccessorName()/]() - [/if] - [if (genFeature.isChangeable() and not genFeature.isSuppressedUnsetVisibility()) ] - * @see #unset[genFeature.getAccessorName()/]() - [/if] - [/if] - [if (genFeature.isChangeable() and not genFeature.isListType() and not genFeature.isSuppressedSetVisibility()) ] - * @see #set[genFeature.getAccessorName()/]([genFeature.getRawImportedBoundType()/]) - [/if] - [if (not genModel.suppressEMFMetaData) ] - * @see [genPackage.getQualifiedPackageInterfaceName()/]#get[genFeature.getFeatureAccessorName()/]() - [/if] - [if (genFeature.isBidirectional() and not genFeature.getReverse().genClass.isMapEntry())] - [let reverseGenFeature : GenFeature = genFeature.getReverse()] - [if (not reverseGenFeature.isSuppressedGetVisibility()) ] - * @see [reverseGenFeature.genClass.getQualifiedInterfaceName()/]#[reverseGenFeature.getGetAccessor()/] - [/if] - [/let] - [/if] - [if (not genModel.suppressEMFModelTags)] - [let modelInfoLines : Sequence(String) = genFeature.getModelInfo().tokenize(genModel.getLineDelimiter())] - [if (modelInfoLines->isEmpty())] - * @model - [else] - * @model [modelInfoLines->sep(genModel.getLineDelimiter() + '\t * ')/] - [/if] - [/let] - [/if] - * @generated - */ - [else][comment isInterface/] - /** - * - * - * @generated - */ - [if (isJDK50)][comment] { //Class/getGenFeature.annotations.insert.javajetinc[/comment] - [/if] - [/if][comment isInterface/] - [if (not isImplementation) ] - [genFeature.getImportedType(genClass)/] [genFeature.getGetAccessor()/](); - - [else] - [if (genModel.useGenerics() and ((genFeature.isContainer() or genFeature.isResolveProxies()) and not genFeature.isListType() and not (genModel.reflectiveDelegation and genModel.isDynamicDelegation()) and genFeature.isUncheckedCast(genClass) or genFeature.isListType() and not genFeature.isFeatureMapType() and (genModel.reflectiveDelegation or genModel.isVirtualDelegation() or genModel.isDynamicDelegation()) or genFeature.isListDataType() and genFeature.hasDelegateFeature() or genFeature.isListType() and genFeature.hasSettingDelegate())) ] - @SuppressWarnings("unchecked") - [/if] - public [genFeature.getImportedType(genClass)/] [genFeature.getGetAccessor()/][if (genClass.hasCollidingGetAccessorOperation(genFeature)) ]_[/if]() { - [if (genModel.isDynamicDelegation()) ] - return [if (not isJDK50 and genFeature.isPrimitiveType()) ]([/if]([genFeature.getObjectType(genClass)/])eDynamicGet([genClass.getQualifiedFeatureID(genFeature)/], [genFeature.getQualifiedFeatureAccessor()/], true, [not genFeature.isEffectiveSuppressEMFTypes()/])[if (not isJDK50 and genFeature.isPrimitiveType()) ]).[genFeature.getPrimitiveValueFunction()/]()[/if]; - [else][if (genModel.reflectiveDelegation) ] - return [if (not isJDK50 and genFeature.isPrimitiveType()) ]([/if]([genFeature.getObjectType(genClass)/])eGet([genFeature.getQualifiedFeatureAccessor()/], true)[if (not isJDK50 and genFeature.isPrimitiveType()) ]).[genFeature.getPrimitiveValueFunction()/]()[/if]; - [else][if (genFeature.hasSettingDelegate()) ] - return [if (not isJDK50 and genFeature.isPrimitiveType()) ]([/if]([genFeature.getObjectType(genClass)/])[genFeature.getUpperName()/]__ESETTING_DELEGATE.dynamicGet(this, null, 0, true, false)[if (not isJDK50 and genFeature.isPrimitiveType()) ]).[genFeature.getPrimitiveValueFunction()/]()[/if]; - [else][if (not genFeature.isVolatile()) ] - [if (genFeature.isListType()) ] - [if (genModel.isVirtualDelegation()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [/if] - if ([genFeature.getSafeName()/] == null) { - [if (genModel.isVirtualDelegation()) ] - eVirtualSet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [genFeature.getSafeName()/] = new [genClass.getListConstructor(genFeature)/]); - [else] - [genFeature.getSafeName()/] = new [genClass.getListConstructor(genFeature)/]; - [/if] - } - return [genFeature.getSafeName()/][if (genFeature.isMapType() and genFeature.isEffectiveSuppressEMFTypes())].map()[/if]; - [else][if (genFeature.isContainer()) ] - if (eContainerFeatureID() != [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]) return null; - return ([genFeature.getImportedType(genClass)/])eContainer(); - [else] - [if (genFeature.isResolveProxies()) ] - [if (genModel.isVirtualDelegation()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/][if (genFeature.hasEDefault()) ], [genFeature.getEDefault()/][/if]); - [/if] - if ([genFeature.getSafeName()/] != null && [genFeature.getSafeNameAsEObject()/].eIsProxy()) { - [genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/] old[genFeature.getCapName()/] = ([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])[genFeature.getSafeName()/]; - [genFeature.getSafeName()/] = [genFeature.getNonEObjectInternalTypeCast(genClass)/]eResolveProxy(old[genFeature.getCapName()/]); - if ([genFeature.getSafeName()/] != old[genFeature.getCapName()/]) { - [if (genFeature.isEffectiveContains()) ] - [genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/] new[genFeature.getCapName()/] = ([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])[genFeature.getSafeName()/]; - [if (not genFeature.isBidirectional()) ] - [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] msgs = old[genFeature.getCapName()/].eInverseRemove(this, EOPPOSITE_FEATURE_BASE - [genClass.getQualifiedFeatureID(genFeature)/][negativeOffsetCorrection/], null, null); - [else] - [let reverseFeature : GenFeature = genFeature.getReverse()] - [let targetClass : GenClass = reverseFeature.genClass] - [let reverseOffsetCorrection : String = if (targetClass.hasOffsetCorrection()) then ' + ' + genClass.getOffsetCorrectionField(genFeature) else '' endif] - [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] msgs = old[genFeature.getCapName()/].eInverseRemove(this, [targetClass.getQualifiedFeatureID(reverseFeature)/][reverseOffsetCorrection/], [targetClass.getRawImportedInterfaceName()/].class, null); - [/let] - [/let] - [/let] - [/if] - if (new[genFeature.getCapName()/].eInternalContainer() == null) { - [if (not genFeature.isBidirectional()) ] - msgs = new[genFeature.getCapName()/].eInverseAdd(this, EOPPOSITE_FEATURE_BASE - [genClass.getQualifiedFeatureID(genFeature)/][negativeOffsetCorrection/], null, msgs); - [else] - [let reverseFeature : GenFeature = genFeature.getReverse()] - [let targetClass : GenClass = reverseFeature.genClass] - [let reverseOffsetCorrection : String = if (targetClass.hasOffsetCorrection()) then ' + ' + genClass.getOffsetCorrectionField(genFeature) else '' endif] - msgs = new[genFeature.getCapName()/].eInverseAdd(this, [targetClass.getQualifiedFeatureID(reverseFeature)/][reverseOffsetCorrection/], [targetClass.getRawImportedInterfaceName()/].class, msgs); - [/let] - [/let] - [/let] - [/if] - } - if (msgs != null) msgs.dispatch(); - [else][if (genModel.isVirtualDelegation()) ] - eVirtualSet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [genFeature.getSafeName()/]); - [/if][/if] - [if (not genModel.suppressNotification) ] - if (eNotificationRequired()) - eNotify(new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].RESOLVE, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], old[genFeature.getCapName()/], [genFeature.getSafeName()/])); - [/if] - } - } - [/if] - [if (not genFeature.isResolveProxies() and genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ] - return ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/][if (genFeature.hasEDefault()) ], [genFeature.getEDefault()/][/if]); - [else][if (genClass.isFlag(genFeature)) ] - [if (genFeature.isBooleanType()) ] - return ([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) != 0; - [else] - return [genFeature.getUpperName()/]_EFLAG_VALUES['['/]([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) >>> [genFeature.getUpperName()/]_EFLAG_OFFSET]; - [/if] - [else] - return [genFeature.getSafeName()/]; - [/if][/if] - [/if][/if] - [else][comment volatile/] - [if (genFeature.isResolveProxies() and not genFeature.isListType()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = basicGet[genFeature.getAccessorName()/](); - return [genFeature.getSafeName()/] != null && [genFeature.getSafeNameAsEObject()/].eIsProxy() ? [genFeature.getNonEObjectInternalTypeCast(genClass)/]eResolveProxy(([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])[genFeature.getSafeName()/]) : [genFeature.getSafeName()/]; - [else][if (genFeature.hasDelegateFeature())] - [let delegateFeature : GenFeature = genFeature.getDelegateFeature()] - [if (genFeature.isFeatureMapType()) ] - [let featureMapEntryTemplateArgument : String = if (isJDK50) then '<' + genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap') + '.Entry>' else '' endif] - [if (delegateFeature.isWrappedFeatureMapType()) ] - return new [genFeature.getImportedEffectiveFeatureMapWrapperClass()/](([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)get[delegateFeature.getAccessorName()/]()).featureMap().[featureMapEntryTemplateArgument/]list([genFeature.getQualifiedFeatureAccessor()/])); - [else] - return ([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/])get[delegateFeature.getAccessorName()/]().[featureMapEntryTemplateArgument/]list([genFeature.getQualifiedFeatureAccessor()/]); - [/if] - [/let] - [else][if (genFeature.isListType()) ] - [if (delegateFeature.isWrappedFeatureMapType()) ] - return (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)get[delegateFeature.getAccessorName()/]()).featureMap().list([genFeature.getQualifiedFeatureAccessor()/]); - [else] - return get[delegateFeature.getAccessorName()/]().list([genFeature.getQualifiedFeatureAccessor()/]); - [/if] - [else] - [if (delegateFeature.isWrappedFeatureMapType()) ] - return [if (not isJDK50 and genFeature.isPrimitiveType()) ]([/if][if (genFeature.getTypeGenDataType() = null or not genFeature.getTypeGenDataType().isObjectType()) ]([genFeature.getObjectType(genClass)/])[/if](([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)get[delegateFeature.getAccessorName()/]()).featureMap().get([genFeature.getQualifiedFeatureAccessor()/], true)[if (not isJDK50 and genFeature.isPrimitiveType()) ]).[genFeature.getPrimitiveValueFunction()/]()[/if]; - [else] - return [if (not isJDK50 and genFeature.isPrimitiveType()) ]([/if][if (genFeature.getTypeGenDataType() = null or not genFeature.getTypeGenDataType().isObjectType()) ]([genFeature.getObjectType(genClass)/])[/if]get[delegateFeature.getAccessorName()/]().get([genFeature.getQualifiedFeatureAccessor()/], true)[if (not isJDK50 and genFeature.isPrimitiveType()) ]).[genFeature.getPrimitiveValueFunction()/]()[/if]; - [/if] - [/if][/if] - [/let] - [else][if (genClass.getGetAccessorOperation(genFeature) <> null) ] - [genClass.getGetAccessorOperation(genFeature).getBody(genModel.getIndentation())/] - [else] - // TODO: implement this method to return the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/] - // Ensure that you remove @generated or mark it @generated NOT - [if (genFeature.isListType()) ] - // The list is expected to implement org.eclipse.emf.ecore.util.InternalEList and org.eclipse.emf.ecore.EStructuralFeature.Setting - // so it's likely that an appropriate subclass of org.eclipse.emf.ecore.util.[if (genFeature.isMapType()) ]EcoreEMap[else][if (genFeature.isFeatureMapType()) ]BasicFeatureMap[else]EcoreEList[/if][/if] should be used. - [/if] - throw new UnsupportedOperationException(); - [/if][/if][/if] - [/if][/if][/if][/if] - } - - [/if] -[/if] -[if (isImplementation and not genModel.reflectiveDelegation and genFeature.isBasicGet()) ] - /** - * - * - * @generated - */ - [if (isJDK50)][comment] { //Class/basicGetGenFeature.annotations.insert.javajetinc[/comment] - [/if] - public [genFeature.getImportedType(genClass)/] basicGet[genFeature.getAccessorName()/]() { - [if (genModel.isDynamicDelegation()) ] - return ([genFeature.getImportedType(genClass)/])eDynamicGet([genClass.getQualifiedFeatureID(genFeature)/], [genFeature.getQualifiedFeatureAccessor()/], false, [not genFeature.isEffectiveSuppressEMFTypes()/]); - [else][if (genFeature.hasSettingDelegate()) ] - return [if (not isJDK50 and genFeature.isPrimitiveType()) ]([/if]([genFeature.getObjectType(genClass)/])[genFeature.getUpperName()/]__ESETTING_DELEGATE.dynamicGet(this, null, 0, false, false)[if (not isJDK50 and genFeature.isPrimitiveType()) ]).[genFeature.getPrimitiveValueFunction()/]()[/if]; - [else][if (genFeature.isContainer()) ] - if (eContainerFeatureID() != [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]) return null; - return ([genFeature.getImportedType(genClass)/])eInternalContainer(); - [else][if (not genFeature.isVolatile()) ] - [if (genModel.isVirtualDelegation()) ] - return ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [else] - return [genFeature.getSafeName()/]; - [/if] - [else][if (genFeature.hasDelegateFeature())] - [let delegateFeature : GenFeature = genFeature.getDelegateFeature()] - [if (delegateFeature.isWrappedFeatureMapType()) ] - return ([genFeature.getImportedType(genClass)/])(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)get[delegateFeature.getAccessorName()/]()).featureMap().get([genFeature.getQualifiedFeatureAccessor()/], false); - [else] - return ([genFeature.getImportedType(genClass)/])get[delegateFeature.getAccessorName()/]().get([genFeature.getQualifiedFeatureAccessor()/], false); - [/if] - [/let] - [else] - // TODO: implement this method to return the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/] - // -> do not perform proxy resolution - // Ensure that you remove @generated or mark it @generated NOT - throw new UnsupportedOperationException(); - [/if][/if][/if][/if][/if] - } - -[/if] -[if (isImplementation and not genModel.reflectiveDelegation and genFeature.isBasicSet()) ] - /** - * - * - * @generated - */ - [if (isJDK50)][comment] { //Class/basicSetGenFeature.annotations.insert.javajetinc[/comment] - [/if] - public [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] basicSet[genFeature.getAccessorName()/]([genFeature.getImportedInternalType(genClass)/] new[genFeature.getCapName()/], [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] msgs) { - [if (genFeature.isContainer()) ] - msgs = eBasicSetContainer(([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])new[genFeature.getCapName()/], [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], msgs); - return msgs; - [else][if (genModel.isDynamicDelegation()) ] - msgs = eDynamicInverseAdd(([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])new[genFeature.getCapName()/], [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], msgs); - return msgs; - [else][if (not genFeature.isVolatile()) ] - [if (genModel.isVirtualDelegation()) ] - Object old[genFeature.getCapName()/] = eVirtualSet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], new[genFeature.getCapName()/]); - [else] - [genFeature.getImportedType(genClass)/] old[genFeature.getCapName()/] = [genFeature.getSafeName()/]; - [genFeature.getSafeName()/] = new[genFeature.getCapName()/]; - [/if] - [if (genFeature.isUnsettable()) ] - [if (genModel.isVirtualDelegation()) ] - [if (not genModel.suppressNotification) ] - boolean isSetChange = old[genFeature.getCapName()/] == EVIRTUAL_NO_VALUE; - [/if] - [else][if (genClass.isESetFlag(genFeature)) ] - boolean old[genFeature.getCapName()/]ESet = ([genClass.getESetFlagsField(genFeature)/] & [genFeature.getUpperName()/]_ESETFLAG) != 0; - [if (not genModel.suppressNotification) ] - [genClass.getESetFlagsField(genFeature)/] |= [genFeature.getUpperName()/]_ESETFLAG; - [/if] - [else] - [if (not genModel.suppressNotification) ] - boolean old[genFeature.getCapName()/]ESet = [genFeature.getUncapName()/]ESet; - [/if] - [genFeature.getUncapName()/]ESet = true; - [/if][/if] - [/if] - [if (not genModel.suppressNotification) ] - if (eNotificationRequired()) { - [if (genFeature.isUnsettable()) ] - [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/] notification = new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].SET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [if (genModel.isVirtualDelegation()) ]isSetChange ? null : old[genFeature.getCapName()/][else]old[genFeature.getCapName()/][/if], new[genFeature.getCapName()/], [if (genModel.isVirtualDelegation()) ]isSetChange[else]!old[genFeature.getCapName()/]ESet[/if]); - [else] - [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/] notification = new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].SET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [if (genModel.isVirtualDelegation()) ]old[genFeature.getCapName()/] == EVIRTUAL_NO_VALUE ? null : old[genFeature.getCapName()/][else]old[genFeature.getCapName()/][/if], new[genFeature.getCapName()/]); - [/if] - if (msgs == null) msgs = notification; else msgs.add(notification); - } - [/if] - return msgs; - [else][if (genFeature.hasDelegateFeature())] - [let delegateFeature : GenFeature = genFeature.getDelegateFeature()] - [if (delegateFeature.isWrappedFeatureMapType()) ] - return (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)get[delegateFeature.getAccessorName()/]()).featureMap()).basicAdd([genFeature.getQualifiedFeatureAccessor()/], new[genFeature.getCapName()/], msgs); - [else] - return (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)get[delegateFeature.getAccessorName()/]()).basicAdd([genFeature.getQualifiedFeatureAccessor()/], new[genFeature.getCapName()/], msgs); - [/if] - [/let] - [else] - // TODO: implement this method to set the contained '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/] - // -> this method is automatically invoked to keep the containment relationship in synch - // -> do not modify other features - // -> return msgs, after adding any generated Notification to it (if it is null, a NotificationChain object must be created first) - // Ensure that you remove @generated or mark it @generated NOT - throw new UnsupportedOperationException(); - [/if][/if][/if][/if] - } - -[/if] -[if (genFeature.isSet() and (isImplementation or not genFeature.isSuppressedSetVisibility())) ] - [if (isInterface) ] - /** - * Sets the value of the '{@link [genClass.getQualifiedInterfaceName()/]#[genFeature.getGetAccessor()/] [genFeature.getFormattedName()/]}' [genFeature.getFeatureKind()/]. - * - * - * @param value the new value of the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/]. - [if (genFeature.isEnumType()) ] - * @see [genFeature.getTypeGenEnum().getQualifiedName()/] - [/if] - [if (genFeature.isUnsettable()) ] - [if (not genFeature.isSuppressedIsSetVisibility()) ] - * @see #isSet[genFeature.getAccessorName()/]() - [/if] - [if (not genFeature.isSuppressedUnsetVisibility()) ] - * @see #unset[genFeature.getAccessorName()/]() - [/if] - [/if] - * @see #[genFeature.getGetAccessor()/]() - * @generated - */ - [else][comment isInterface /] - /** - * - * - * @generated - */ - [if (isJDK50)][comment] { //Class/setGenFeature.annotations.insert.javajetinc[/comment] - [/if] - [/if][comment isInterface /] - [if (not isImplementation)] - void set[genFeature.getAccessorName()/]([genFeature.getImportedType(genClass)/] value); - - [else][comment not isImplementation /] - [comment Using query instead of variable because let does not support null !!! - let setAccessorOperation : GenOperation = genClass.getSetAccessorOperation(genFeature)/] - public void set[genFeature.getAccessorName()/][if (genClass.hasCollidingSetAccessorOperation(genFeature)) ]_[/if]([genFeature.getImportedType(genClass)/] [if (genClass.getSetAccessorOperation(genFeature) = null)]new[genFeature.getCapName()/][else][genClass.getSetAccessorOperation(genFeature).genParameters->at(1).getName()/][/if]) { - [if (genModel.isDynamicDelegation()) ] - eDynamicSet([genClass.getQualifiedFeatureID(genFeature)/], [genFeature.getQualifiedFeatureAccessor()/], [if (not isJDK50 and genFeature.isPrimitiveType()) ]new [genFeature.getObjectType(genClass)/]([/if]new[genFeature.getCapName()/][if (not isJDK50 and genFeature.isPrimitiveType()) ])[/if]); - [else][if (genModel.reflectiveDelegation) ] - eSet([genFeature.getQualifiedFeatureAccessor()/], [if (not isJDK50 and genFeature.isPrimitiveType()) ]new [genFeature.getObjectType(genClass)/]([/if]new[genFeature.getCapName()/][if (not isJDK50 and genFeature.isPrimitiveType()) ])[/if]); - [else][if (genFeature.hasSettingDelegate()) ] - [genFeature.getUpperName()/]__ESETTING_DELEGATE.dynamicSet(this, null, 0, [if (not isJDK50 and genFeature.isPrimitiveType()) ]new [genFeature.getObjectType(genClass)/]([/if]new[genFeature.getCapName()/][if (not isJDK50 and genFeature.isPrimitiveType()) ])[/if]); - [else][if (not genFeature.isVolatile()) ] - [if (genFeature.isContainer())] - [let reverseFeature : GenFeature = genFeature.getReverse()] - [let targetClass : GenClass = reverseFeature.genClass] - [let reverseOffsetCorrection : String = if (targetClass.hasOffsetCorrection()) then ' + ' + genClass.getOffsetCorrectionField(genFeature) else '' endif] - if (new[genFeature.getCapName()/] != eInternalContainer() || (eContainerFeatureID() != [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/] && new[genFeature.getCapName()/] != null)) { - if ([genModel.getImportedName('org.eclipse.emf.ecore.util.EcoreUtil')/].isAncestor(this, [genFeature.getEObjectCast()/]new[genFeature.getCapName()/])) - throw new [genModel.getImportedName('java.lang.IllegalArgumentException')/]("Recursive containment not allowed for " + toString());[genModel.getNonNLS()/] - [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] msgs = null; - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - if (new[genFeature.getCapName()/] != null) - msgs = (([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])new[genFeature.getCapName()/]).eInverseAdd(this, [targetClass.getQualifiedFeatureID(reverseFeature)/][reverseOffsetCorrection/], [targetClass.getRawImportedInterfaceName()/].class, msgs); - msgs = basicSet[genFeature.getAccessorName()/]([genFeature.getInternalTypeCast()/]new[genFeature.getCapName()/], msgs); - if (msgs != null) msgs.dispatch(); - } - [if (not genModel.suppressNotification) ] - else if (eNotificationRequired()) - eNotify(new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].SET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], new[genFeature.getCapName()/], new[genFeature.getCapName()/])); - [/if] - [/let] - [/let] - [/let] - [else][if (genFeature.isBidirectional() or genFeature.isEffectiveContains()) ] - [if (genModel.isVirtualDelegation()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [/if] - if (new[genFeature.getCapName()/] != [genFeature.getSafeName()/]) { - [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] msgs = null; - if ([genFeature.getSafeName()/] != null) - [if (not genFeature.isBidirectional()) ] - msgs = (([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])[genFeature.getSafeName()/]).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - [genClass.getQualifiedFeatureID(genFeature)/][negativeOffsetCorrection/], null, msgs); - if (new[genFeature.getCapName()/] != null) - msgs = (([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])new[genFeature.getCapName()/]).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - [genClass.getQualifiedFeatureID(genFeature)/][negativeOffsetCorrection/], null, msgs); - [else] - [let reverseFeature : GenFeature = genFeature.getReverse()] - [let targetClass : GenClass = reverseFeature.genClass] - [let reverseOffsetCorrection : String = if (targetClass.hasOffsetCorrection()) then ' + ' + genClass.getOffsetCorrectionField(genFeature) else '' endif] - msgs = (([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])[genFeature.getSafeName()/]).eInverseRemove(this, [targetClass.getQualifiedFeatureID(reverseFeature)/][reverseOffsetCorrection/], [targetClass.getRawImportedInterfaceName()/].class, msgs); - if (new[genFeature.getCapName()/] != null) - msgs = (([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])new[genFeature.getCapName()/]).eInverseAdd(this, [targetClass.getQualifiedFeatureID(reverseFeature)/][reverseOffsetCorrection/], [targetClass.getRawImportedInterfaceName()/].class, msgs); - [/let] - [/let] - [/let] - [/if] - msgs = basicSet[genFeature.getAccessorName()/]([genFeature.getInternalTypeCast()/]new[genFeature.getCapName()/], msgs); - if (msgs != null) msgs.dispatch(); - }[if (genFeature.isUnsettable())] else { - [if (genModel.isVirtualDelegation()) ] - boolean old[genFeature.getCapName()/]ESet = eVirtualIsSet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [else][if (genClass.isESetFlag(genFeature)) ] - [if (not genModel.suppressNotification) ] - boolean old[genFeature.getCapName()/]ESet = ([genClass.getESetFlagsField(genFeature)/] & [genFeature.getUpperName()/]_ESETFLAG) != 0; - [/if] - [genClass.getESetFlagsField(genFeature)/] |= [genFeature.getUpperName()/]_ESETFLAG; - [else] - [if (not genModel.suppressNotification) ] - boolean old[genFeature.getCapName()/]ESet = [genFeature.getUncapName()/]ESet; - [/if] - [genFeature.getUncapName()/]ESet = true; - [/if][/if] - [if (not genModel.suppressNotification) ] - if (eNotificationRequired()) - eNotify(new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].SET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], new[genFeature.getCapName()/], new[genFeature.getCapName()/], not old[genFeature.getCapName()/]ESet)); - [/if] - } - [else][comment genFeature.isUnsettable() /] - [if (not genModel.suppressNotification) ] else if (eNotificationRequired()) - eNotify(new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].SET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], new[genFeature.getCapName()/], new[genFeature.getCapName()/])); - [else][comment carriage return /] - - [/if] - [/if][comment genFeature.isUnsettable() /] - [else] - [if (genClass.isFlag(genFeature)) ] - [if (not genModel.suppressNotification) ] - [if (genFeature.isBooleanType()) ] - [genFeature.getImportedType(genClass)/] old[genFeature.getCapName()/] = ([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) != 0; - [else] - [genFeature.getImportedType(genClass)/] old[genFeature.getCapName()/] = [genFeature.getUpperName()/]_EFLAG_VALUES['['/]([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) >>> [genFeature.getUpperName()/]_EFLAG_OFFSET]; - [/if] - [/if] - [if (genFeature.isBooleanType()) ] - if (new[genFeature.getCapName()/]) [genClass.getFlagsField(genFeature)/] |= [genFeature.getUpperName()/]_EFLAG; else [genClass.getFlagsField(genFeature)/] &= ~[genFeature.getUpperName()/]_EFLAG; - [else] - if (new[genFeature.getCapName()/] == null) new[genFeature.getCapName()/] = [genFeature.getUpperName()/]_EDEFAULT; - [genClass.getFlagsField(genFeature)/] = [genClass.getFlagsField(genFeature)/] & ~[genFeature.getUpperName()/]_EFLAG | [if (isJDK50) ]new[genFeature.getCapName()/].ordinal()[else][genFeature.getImportedType(genClass)/].VALUES.indexOf(new[genFeature.getCapName()/])[/if] << [genFeature.getUpperName()/]_EFLAG_OFFSET; - [/if] - [else][comment (genClass.isFlag(genFeature)) /] - [if (not genModel.isVirtualDelegation() or genFeature.isPrimitiveType()) ] - [if (not genModel.suppressNotification) ] - [genFeature.getImportedType(genClass)/] old[genFeature.getCapName()/] = [genFeature.getSafeName()/]; - [/if] - [/if] - [if (genFeature.isEnumType()) ] - [if (genModel.isVirtualDelegation()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = new[genFeature.getCapName()/] == null ? [genFeature.getEDefault()/] : new[genFeature.getCapName()/]; - [else] - [genFeature.getSafeName()/] = new[genFeature.getCapName()/] == null ? [genFeature.getEDefault()/] : new[genFeature.getCapName()/]; - [/if] - [else] - [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = [genFeature.getInternalTypeCast()/]new[genFeature.getCapName()/]; - [else] - [genFeature.getSafeName()/] = [genFeature.getInternalTypeCast()/]new[genFeature.getCapName()/]; - [/if] - [/if] - [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ] - Object old[genFeature.getCapName()/] = eVirtualSet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [genFeature.getSafeName()/]); - [/if] - [/if][comment (genClass.isFlag(genFeature)) /] - [if (genFeature.isUnsettable()) ] - [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ] - boolean isSetChange = old[genFeature.getCapName()/] == EVIRTUAL_NO_VALUE; - [else][if (genClass.isESetFlag(genFeature)) ] - [if (not genModel.suppressNotification) ] - boolean old[genFeature.getCapName()/]ESet = ([genClass.getESetFlagsField(genFeature)/] & [genFeature.getUpperName()/]_ESETFLAG) != 0; - [/if] - [genClass.getESetFlagsField(genFeature)/] |= [genFeature.getUpperName()/]_ESETFLAG; - [else] - [if (not genModel.suppressNotification) ] - boolean old[genFeature.getCapName()/]ESet = [genFeature.getUncapName()/]ESet; - [/if] - [genFeature.getUncapName()/]ESet = true; - [/if][/if] - [if (not genModel.suppressNotification) ] - if (eNotificationRequired()) - eNotify(new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].SET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ]isSetChange ? [genFeature.getEDefault()/] : old[genFeature.getCapName()/][else]old[genFeature.getCapName()/][/if], [if (genClass.isFlag(genFeature)) ]new[genFeature.getCapName()/][else][genFeature.getSafeName()/][/if], [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ]isSetChange[else]!old[genFeature.getCapName()/]ESet[/if])); - [/if] - [else][comment (genFeature.isUnsettable()) /] - [if (not genModel.suppressNotification) ] - if (eNotificationRequired()) - eNotify(new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].SET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ]old[genFeature.getCapName()/] == EVIRTUAL_NO_VALUE ? [genFeature.getEDefault()/] : old[genFeature.getCapName()/][else]old[genFeature.getCapName()/][/if], [if (genClass.isFlag(genFeature)) ]new[genFeature.getCapName()/][else][genFeature.getSafeName()/][/if])); - [/if] - [/if][comment (genFeature.isUnsettable()) /] - [/if][/if] - [else][if (genFeature.hasDelegateFeature())] - [let delegateFeature : GenFeature = genFeature.getDelegateFeature()] - [if (delegateFeature.isWrappedFeatureMapType()) ] - (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)get[delegateFeature.getAccessorName()/]()).featureMap()).set([genFeature.getQualifiedFeatureAccessor()/], [if (not isJDK50 and genFeature.isPrimitiveType()) ]new [genFeature.getObjectType(genClass)/]([/if]new[genFeature.getCapName()/][if (not isJDK50 and genFeature.isPrimitiveType()) ])[/if]); - [else] - (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)get[delegateFeature.getAccessorName()/]()).set([genFeature.getQualifiedFeatureAccessor()/], [if (not isJDK50 and genFeature.isPrimitiveType()) ]new [genFeature.getObjectType(genClass)/]([/if]new[genFeature.getCapName()/][if (not isJDK50 and genFeature.isPrimitiveType()) ])[/if]); - [/if] - [/let] - [else][if (genClass.getSetAccessorOperation(genFeature) <> null) ] - [genClass.getSetAccessorOperation(genFeature).getBody(genModel.getIndentation())/] - [else] - // TODO: implement this method to set the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/] - // Ensure that you remove @generated or mark it @generated NOT - throw new UnsupportedOperationException(); - [/if][/if][/if][/if][/if][/if] - } - - [/if][comment not isImplementation /] -[/if] -[if (isImplementation and not genModel.reflectiveDelegation and genFeature.isBasicUnset()) ] - /** - * - * - * @generated - */ - [if (isJDK50)][comment] { //Class/basicUnsetGenFeature.annotations.insert.javajetinc[/comment] - [/if] - public [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] basicUnset[genFeature.getAccessorName()/]([genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] msgs) { - [if (genModel.isDynamicDelegation()) ] - return eDynamicInverseRemove(([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])[if (genFeature.isResolveProxies()) ]basicGet[genFeature.getAccessorName()/][else][genFeature.getGetAccessor()/][/if](), [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], msgs); - [else][if (not genFeature.isVolatile()) ] - [if (genModel.isVirtualDelegation()) ] - [if (not genModel.suppressNotification) ]Object old[genFeature.getCapName()/] = [/if]eVirtualUnset([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [else] - [if (not genModel.suppressNotification) ] - [genFeature.getImportedType(genClass)/] old[genFeature.getCapName()/] = [genFeature.getSafeName()/]; - [/if] - [genFeature.getSafeName()/] = null; - [/if] - [if (genModel.isVirtualDelegation()) ] - [if (not genModel.suppressNotification) ] - boolean isSetChange = old[genFeature.getCapName()/] != EVIRTUAL_NO_VALUE; - [/if] - [else][if (genClass.isESetFlag(genFeature)) ] - [if (not genModel.suppressNotification) ] - boolean old[genFeature.getCapName()/]ESet = ([genClass.getESetFlagsField(genFeature)/] & [genFeature.getUpperName()/]_ESETFLAG) != 0; - [/if] - [genClass.getESetFlagsField(genFeature)/] &= ~[genFeature.getUpperName()/]_ESETFLAG; - [else] - [if (not genModel.suppressNotification) ] - boolean old[genFeature.getCapName()/]ESet = [genFeature.getUncapName()/]ESet; - [/if] - [genFeature.getUncapName()/]ESet = false; - [/if][/if] - [if (not genModel.suppressNotification) ] - if (eNotificationRequired()) { - [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/] notification = new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].UNSET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [if (genModel.isVirtualDelegation()) ]isSetChange ? old[genFeature.getCapName()/] : null[else]old[genFeature.getCapName()/][/if], null, [if (genModel.isVirtualDelegation()) ]isSetChange[else]old[genFeature.getCapName()/]ESet[/if]); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - [/if] - [else] - // TODO: implement this method to unset the contained '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/] - // -> this method is automatically invoked to keep the containment relationship in synch - // -> do not modify other features - // -> return msgs, after adding any generated Notification to it (if it is null, a NotificationChain object must be created first) - // Ensure that you remove @generated or mark it @generated NOT - throw new UnsupportedOperationException(); - [/if][/if] - } - -[/if] -[if (genFeature.isUnset() and (isImplementation or not genFeature.isSuppressedUnsetVisibility())) ] - [if (isInterface) ] - /** - * Unsets the value of the '{@link [genClass.getQualifiedInterfaceName()/]#[genFeature.getGetAccessor()/] [genFeature.getFormattedName()/]}' [genFeature.getFeatureKind()/]. - * - * - [if (not genFeature.isSuppressedIsSetVisibility()) ] - * @see #isSet[genFeature.getAccessorName()/]() - [/if] - * @see #[genFeature.getGetAccessor()/]() - [if (not genFeature.isListType() and not genFeature.isSuppressedSetVisibility()) ] - * @see #set[genFeature.getAccessorName()/]([genFeature.getRawImportedBoundType()/]) - [/if] - * @generated - */ - [else][comment isInterface/] - /** - * - * - * @generated - */ - [if (isJDK50)][comment] { //Class/unsetGenFeature.annotations.insert.javajetinc[/comment] - [/if] - [/if][comment isInterface/] - [if (not isImplementation) ] - void unset[genFeature.getAccessorName()/](); - - [else][comment not isImplementation/] - public void unset[genFeature.getAccessorName()/][if (genClass.hasCollidingUnsetAccessorOperation(genFeature)) ]_[/if]() { - [if (genModel.isDynamicDelegation()) ] - eDynamicUnset([genClass.getQualifiedFeatureID(genFeature)/], [genFeature.getQualifiedFeatureAccessor()/]); - [else][if (genModel.reflectiveDelegation) ] - eUnset([genFeature.getQualifiedFeatureAccessor()/]); - [else][if (genFeature.hasSettingDelegate()) ] - [genFeature.getUpperName()/]__ESETTING_DELEGATE.dynamicUnset(this, null, 0); - [else][if (not genFeature.isVolatile()) ] - [if (genFeature.isListType()) ] - [if (genModel.isVirtualDelegation()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [/if] - if ([genFeature.getSafeName()/] != null) (([genModel.getImportedName('org.eclipse.emf.ecore.util.InternalEList')/].Unsettable[singleWildcard/])[genFeature.getSafeName()/]).unset(); - [else][if (genFeature.isBidirectional() or genFeature.isEffectiveContains()) ] - [if (genModel.isVirtualDelegation()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [/if] - if ([genFeature.getSafeName()/] != null) { - [genModel.getImportedName('org.eclipse.emf.common.notify.NotificationChain')/] msgs = null; - [if (not genFeature.isBidirectional()) ] - msgs = (([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])[genFeature.getSafeName()/]).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - [genClass.getQualifiedFeatureID(genFeature)/][negativeOffsetCorrection/], null, msgs); - [else] - [let reverseFeature : GenFeature = genFeature.getReverse()] - [let targetClass : GenClass = reverseFeature.genClass] - [let reverseOffsetCorrection : String = if (targetClass.hasOffsetCorrection()) then ' + ' + genClass.getOffsetCorrectionField(genFeature) else '' endif] - msgs = (([genModel.getImportedName('org.eclipse.emf.ecore.InternalEObject')/])[genFeature.getSafeName()/]).eInverseRemove(this, [targetClass.getQualifiedFeatureID(reverseFeature)/][reverseOffsetCorrection/], [targetClass.getRawImportedInterfaceName()/].class, msgs); - [/let] - [/let] - [/let] - [/if] - msgs = basicUnset[genFeature.getAccessorName()/](msgs); - if (msgs != null) msgs.dispatch(); - } else { - [if (genModel.isVirtualDelegation()) ] - boolean old[genFeature.getCapName()/]ESet = eVirtualIsSet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [else][if (genClass.isESetFlag(genFeature)) ] - [if (not genModel.suppressNotification) ] - boolean old[genFeature.getCapName()/]ESet = ([genClass.getESetFlagsField(genFeature)/] & [genFeature.getUpperName()/]_ESETFLAG) != 0; - [/if] - [genClass.getESetFlagsField(genFeature)/] &= ~[genFeature.getUpperName()/]_ESETFLAG; - [else] - [if (not genModel.suppressNotification) ] - boolean old[genFeature.getCapName()/]ESet = [genFeature.getUncapName()/]ESet; - [/if] - [genFeature.getUncapName()/]ESet = false; - [/if][/if] - [if (not genModel.suppressNotification) ] - if (eNotificationRequired()) - eNotify(new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].UNSET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], null, null, old[genFeature.getCapName()/]ESet)); - [/if] - } - [else] - [if (genClass.isFlag(genFeature)) ] - [if (not genModel.suppressNotification) ] - [if (genFeature.isBooleanType()) ] - [genFeature.getImportedType(genClass)/] old[genFeature.getCapName()/] = ([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) != 0; - [else] - [genFeature.getImportedType(genClass)/] old[genFeature.getCapName()/] = [genFeature.getUpperName()/]_EFLAG_VALUES['['/]([genClass.getFlagsField(genFeature)/] & [genFeature.getUpperName()/]_EFLAG) >>> [genFeature.getUpperName()/]_EFLAG_OFFSET]; - [/if] - [/if] - [else][if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ] - Object old[genFeature.getCapName()/] = eVirtualUnset([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [else] - [if (not genModel.suppressNotification) ] - [genFeature.getImportedType(genClass)/] old[genFeature.getCapName()/] = [genFeature.getSafeName()/]; - [/if] - [/if][/if] - [if (not genModel.suppressNotification) ] - [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ] - boolean isSetChange = old[genFeature.getCapName()/] != EVIRTUAL_NO_VALUE; - [else][if (genClass.isESetFlag(genFeature)) ] - boolean old[genFeature.getCapName()/]ESet = ([genClass.getESetFlagsField(genFeature)/] & [genFeature.getUpperName()/]_ESETFLAG) != 0; - [else] - boolean old[genFeature.getCapName()/]ESet = [genFeature.getUncapName()/]ESet; - [/if][/if] - [/if] - [if (genFeature.isReferenceType()) ] - [genFeature.getSafeName()/] = null; - [if (not genModel.isVirtualDelegation()) ] - [if (genClass.isESetFlag(genFeature)) ] - [genClass.getESetFlagsField(genFeature)/] &= ~[genFeature.getUpperName()/]_ESETFLAG; - [else] - [genFeature.getUncapName()/]ESet = false; - [/if] - [/if] - [if (not genModel.suppressNotification) ] - if (eNotificationRequired()) - eNotify(new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].UNSET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [if (genModel.isVirtualDelegation()) ]isSetChange ? old[genFeature.getCapName()/] : null[else]old[genFeature.getCapName()/][/if], null, [if (genModel.isVirtualDelegation()) ]isSetChange[else]old[genFeature.getCapName()/]ESet[/if])); - [/if] - [else] - [if (genClass.isFlag(genFeature)) ] - [if (genFeature.isBooleanType()) ] - if ([genFeature.getEDefault()/]) [genClass.getFlagsField(genFeature)/] |= [genFeature.getUpperName()/]_EFLAG; else [genClass.getFlagsField(genFeature)/] &= ~[genFeature.getUpperName()/]_EFLAG; - [else] - [genClass.getFlagsField(genFeature)/] = [genClass.getFlagsField(genFeature)/] & ~[genFeature.getUpperName()/]_EFLAG | [genFeature.getUpperName()/]_EFLAG_DEFAULT; - [/if] - [else][if (not genModel.isVirtualDelegation() or genFeature.isPrimitiveType()) ] - [genFeature.getSafeName()/] = [genFeature.getEDefault()/]; - [/if][/if] - [if (not genModel.isVirtualDelegation() or genFeature.isPrimitiveType()) ] - [if (genClass.isESetFlag(genFeature)) ] - [genClass.getESetFlagsField(genFeature)/] &= ~[genFeature.getUpperName()/]_ESETFLAG; - [else] - [genFeature.getUncapName()/]ESet = false; - [/if] - [/if] - [if (not genModel.suppressNotification) ] - if (eNotificationRequired()) - eNotify(new [genModel.getImportedName('org.eclipse.emf.ecore.impl.ENotificationImpl')/](this, [genModel.getImportedName('org.eclipse.emf.common.notify.Notification')/].UNSET, [genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/], [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ]isSetChange ? old[genFeature.getCapName()/] : [genFeature.getEDefault()/][else]old[genFeature.getCapName()/][/if], [genFeature.getEDefault()/], [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ]isSetChange[else]old[genFeature.getCapName()/]ESet[/if])); - [/if] - [/if] - [/if][/if] - [else]][if (genFeature.hasDelegateFeature())] - [let delegateFeature : GenFeature = genFeature.getDelegateFeature()] - [if (delegateFeature.isWrappedFeatureMapType()) ] - (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)get[delegateFeature.getAccessorName()/]()).featureMap()).clear([genFeature.getQualifiedFeatureAccessor()/]); - [else] - (([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)get[delegateFeature.getAccessorName()/]()).clear([genFeature.getQualifiedFeatureAccessor()/]); - [/if] - [/let] - [else][if (genClass.getUnsetAccessorOperation(genFeature) <> null) ] - [genClass.getUnsetAccessorOperation(genFeature).getBody(genModel.getIndentation())/] - [else] - // TODO: implement this method to unset the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/] - // Ensure that you remove @generated or mark it @generated NOT - throw new UnsupportedOperationException(); - [/if][/if][/if][/if][/if][/if] - } - - [/if][comment not isImplementation/] -[/if] -[if (genFeature.isIsSet() and (isImplementation or not genFeature.isSuppressedIsSetVisibility())) ] - [if (isInterface) ] - /** - * Returns whether the value of the '{@link [genClass.getQualifiedInterfaceName()/]#[genFeature.getGetAccessor()/] [genFeature.getFormattedName()/]}' [genFeature.getFeatureKind()/] is set. - * - * - * @return whether the value of the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/] is set. - [if (genFeature.isChangeable() and not genFeature.isSuppressedUnsetVisibility()) ] - * @see #unset[genFeature.getAccessorName()/]() - [/if] - * @see #[genFeature.getGetAccessor()/]() - [if (not genFeature.isListType() and genFeature.isChangeable() and not genFeature.isSuppressedSetVisibility()) ] - * @see #set[genFeature.getAccessorName()/]([genFeature.getRawImportedBoundType()/]) - [/if] - * @generated - */ - [else][comment isInterface/] - /** - * - * - * @generated - */ - [comment][if (isJDK50)][comment] { //Class/isSetGenFeature.annotations.insert.javajetinc[/comment] - [/if][/comment] - [/if][comment isInterface/] - [if (not isImplementation) ] - boolean isSet[genFeature.getAccessorName()/](); - - [else][comment not isImplementation/] - public boolean isSet[genFeature.getAccessorName()/][if (genClass.hasCollidingIsSetAccessorOperation(genFeature)) ]_[/if]() { - [if (genModel.isDynamicDelegation()) ] - return eDynamicIsSet([genClass.getQualifiedFeatureID(genFeature)/], [genFeature.getQualifiedFeatureAccessor()/]); - [else][if (genModel.reflectiveDelegation) ] - return eIsSet([genFeature.getQualifiedFeatureAccessor()/]); - [else][if (genFeature.hasSettingDelegate()) ] - return [genFeature.getUpperName()/]__ESETTING_DELEGATE.dynamicIsSet(this, null, 0); - [else][if (not genFeature.isVolatile()) ] - [if (genFeature.isListType()) ] - [if (genModel.isVirtualDelegation()) ] - [genFeature.getImportedType(genClass)/] [genFeature.getSafeName()/] = ([genFeature.getImportedType(genClass)/])eVirtualGet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [/if] - return [genFeature.getSafeName()/] != null && (([genModel.getImportedName('org.eclipse.emf.ecore.util.InternalEList')/].Unsettable[singleWildcard/])[genFeature.getSafeName()/]).isSet(); - [else] - [if (genModel.isVirtualDelegation() and not genFeature.isPrimitiveType()) ] - return eVirtualIsSet([genClass.getQualifiedFeatureID(genFeature)/][positiveOffsetCorrection/]); - [else][if (genClass.isESetFlag(genFeature)) ] - return ([genClass.getESetFlagsField(genFeature)/] & [genFeature.getUpperName()/]_ESETFLAG) != 0; - [else] - return [genFeature.getUncapName()/]ESet; - [/if][/if] - [/if] - [else][if (genFeature.hasDelegateFeature())] - [let delegateFeature : GenFeature = genFeature.getDelegateFeature()] - [if (delegateFeature.isWrappedFeatureMapType()) ] - return !(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal.Wrapper)get[delegateFeature.getAccessorName()/]()).featureMap()).isEmpty([genFeature.getQualifiedFeatureAccessor()/]); - [else] - return !(([genModel.getImportedName('org.eclipse.emf.ecore.util.FeatureMap')/].Internal)get[delegateFeature.getAccessorName()/]()).isEmpty([genFeature.getQualifiedFeatureAccessor()/]); - [/if] - [/let] - [else][if (genClass.getIsSetAccessorOperation(genFeature) <> null) ] - [genClass.getIsSetAccessorOperation(genFeature).getBody(genModel.getIndentation())/] - [else] - // TODO: implement this method to return whether the '[genFeature.getFormattedName()/]' [genFeature.getFeatureKind()/] is set - // Ensure that you remove @generated or mark it @generated NOT - throw new UnsupportedOperationException(); - [/if][/if][/if][/if][/if][/if] - } - - [/if][comment not isImplementation/] -[/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genOperation.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genOperation.mtl deleted file mode 100644 index 3a558b52a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/genOperation.mtl +++ /dev/null @@ -1,160 +0,0 @@ -[comment encoding = UTF-8 /] -[module genOperation('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenEnum /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenOperation /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenParameter /] - -[template public genOperation(genOperation : GenOperation, genClass : GenClass, genPackage : GenPackage, genModel : GenModel, isJDK50 : Boolean, isInterface : Boolean, isImplementation : Boolean, isGWT : Boolean)] -[if (isImplementation) ] - [if (genOperation.isInvariant() and genOperation.hasInvariantExpression()) ] - /** - * The cached validation expression for the '{@link #[genOperation.getName()/]([genOperation.getParameterTypes(', ')/]) [genOperation.getFormattedName()/]}' invariant operation. - * - * - * @see #[genOperation.getName()/]([genOperation.getParameterTypes(', ')/]) - * @generated - * @ordered - */ - protected static final [genModel.getImportedName('java.lang.String')/] [genClass.getUniqueNameUpperCase(genOperation)/]__EEXPRESSION = "[genOperation.getInvariantExpression('\t\t')/]";[genModel.getNonNLS()/] - - [else][if (genOperation.hasInvocationDelegate()) ] - /** - * The cached invocation delegate for the '{@link #[genOperation.getName()/]([genOperation.getParameterTypes(', ')/]) [genOperation.getFormattedName()/]}' operation. - * - * - * @see #[genOperation.getName()/]([genOperation.getParameterTypes(', ')/]) - * @generated - * @ordered - */ - protected static final [genModel.getImportedName('org.eclipse.emf.ecore.EOperation')/].Internal.InvocationDelegate [genClass.getUniqueNameUpperCase(genOperation)/]__EINVOCATION_DELEGATE = (([genModel.getImportedName('org.eclipse.emf.ecore.EOperation')/].Internal)[genOperation.getQualifiedOperationAccessor()/]).getInvocationDelegate(); - - [/if][/if] -[/if] -[if (isInterface) ] -[comment]<%@ include file="Class/genOperation.javadoc.override.javajetinc" fail="alternative" %>[/comment] -[comment]<%@ start %>[/comment] - /** -[comment]<%@ include file="Class/genOperation.javadoc.insert.javajetinc" fail="silent" %>[/comment] - * - * - [if (genOperation.hasDocumentation() or genOperation.hasParameterDocumentation()) ] - * - [if (genOperation.hasDocumentation()) ] - * [genOperation.getDocumentation(genModel.getIndentation())/] - [/if] - [for (genParameter : GenParameter | genOperation.genParameters)] - [if (genParameter.hasDocumentation())] - [let documentation : String = genParameter.getDocumentation('')] - [if (documentation.contains('\n') or documentation.contains('\r')) ] - * @param [genParameter.getName()/] - * [genParameter.getDocumentation(genModel.getIndentation())/] - [else] - * @param [genParameter.getName()/] [genParameter.getDocumentation(genModel.getIndentation())/] - [/if] - [/let] - [/if] - [/for] - * - [/if] - [if (not genModel.suppressEMFModelTags)] - [let modelInfoLines : Sequence(String) = genOperation.getModelInfo().tokenize(genModel.getLineDelimiter())] - [if (modelInfoLines->isEmpty())] - * @model - [else] - * @model [modelInfoLines->sep(genModel.getLineDelimiter() + '\t * ')/] - [/if] - [/let] - [/if] - * @generated - */ -[comment]<%@ end %><%//Class/genOperation.javadoc.override.javajetinc%>[/comment] -[else] - /** - * - * - * @generated - */ - [if (isJDK50)][comment]//Class/genOperation.annotations.insert.javajetinc[/comment] -[comment]<%@ include file="Class/genOperation.annotations.insert.javajetinc" fail="silent" %>[/comment] - [/if] -[/if] -[if (not isImplementation) ] - [genOperation.getTypeParameters(genClass)/][genOperation.getImportedType(genClass)/] [genOperation.getName()/]([genOperation.getParameters(genClass)/])[genOperation.getThrows(genClass)/]; - -[else] - public [genOperation.getTypeParameters(genClass)/][genOperation.getImportedType(genClass)/] [genOperation.getName()/]([genOperation.getParameters(genClass)/])[genOperation.getThrows(genClass)/] { - [if (genOperation.hasBody()) ] - [genOperation.getBody(genModel.getIndentation())/] - [else][if (genOperation.isInvariant())] - [let opClass : GenClass = genOperation.genClass] - [let diagnostics : String = genOperation.genParameters->at(1).oclAsType(GenParameter).getName()] - [let ctx : String = genOperation.genParameters->at(2).oclAsType(GenParameter).getName()] - [if (genOperation.hasInvariantExpression()) ] - return - [opClass.genPackage.getImportedValidatorClassName()/].validate - ([genClass.getQualifiedClassifierAccessor()/], - this, - [diagnostics/], - [ctx/], - "[genOperation.getValidationDelegate()/]",[genModel.getNonNLS()/] - [genOperation.getQualifiedOperationAccessor()/], - [genClass.getUniqueNameUpperCase(genOperation)/]__EEXPRESSION, - [genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - [opClass.genPackage.getImportedValidatorClassName()/].DIAGNOSTIC_SOURCE, - [opClass.genPackage.getImportedValidatorClassName()/].[opClass.getOperationID(genOperation)/]); - [else] - // TODO: implement this method - // -> specify the condition that violates the invariant - // -> verify the details of the diagnostic, including severity and message - // Ensure that you remove @generated or mark it @generated NOT - if (false) { - if ([diagnostics/] != null) { - [diagnostics/].add - (new [genModel.getImportedName('org.eclipse.emf.common.util.BasicDiagnostic')/] - ([genModel.getImportedName('org.eclipse.emf.common.util.Diagnostic')/].ERROR, - [opClass.genPackage.getImportedValidatorClassName()/].DIAGNOSTIC_SOURCE, - [opClass.genPackage.getImportedValidatorClassName()/].[opClass.getOperationID(genOperation)/], - [genModel.getImportedName('org.eclipse.emf.ecore.plugin.EcorePlugin')/].INSTANCE.getString("_UI_GenericInvariant_diagnostic", new Object['[]'/] { "[genOperation.getName()/]", [genModel.getImportedName('org.eclipse.emf.ecore.util.EObjectValidator')/].getObjectLabel(this, [ctx/]) }),[genModel.getNonNLS()/][genModel.getNonNLS(2)/] - new Object ['[]'/] { this })); - } - return false; - } - return true; - [/if] - [/let] - [/let] - [/let] - [else][if (genOperation.hasInvocationDelegate())] - [let size : Integer = genOperation.genParameters->size()] - try { - [if (genOperation.isVoid()) ] - [genClass.getUniqueNameUpperCase(genOperation)/]__EINVOCATION_DELEGATE.dynamicInvoke(this, [if (size > 0) ]new [genModel.getImportedName('org.eclipse.emf.common.util.BasicEList')/].UnmodifiableEList([size/], [genOperation.getParametersArray(genClass)/])[else]null[/if]); - [else] - return [if (not isJDK50 and genOperation.isPrimitiveType()) ]([/if]([genOperation.getObjectType(genClass)/])[genClass.getUniqueNameUpperCase(genOperation)/]__EINVOCATION_DELEGATE.dynamicInvoke(this, [if (size > 0) ]new [genModel.getImportedName('org.eclipse.emf.common.util.BasicEList')/].UnmodifiableEList([size/], [genOperation.getParametersArray(genClass)/])[else]null[/if])[if (not isJDK50 and genOperation.isPrimitiveType()) ]).[genOperation.getPrimitiveValueFunction()/]()[/if]; - [/if] - } - catch ([genModel.getImportedName(if (isGWT) then 'org.eclipse.emf.common.util.InvocationTargetException' else 'java.lang.reflect.InvocationTargetException' endif)/] ite) { - throw new [genModel.getImportedName('org.eclipse.emf.common.util.WrappedException')/](ite); - } - [/let] - [else] -[comment]<%@ include file="Class/implementedGenOperation.TODO.override.javajetinc" fail="alternative" %>[/comment] -[comment]<%@ start %>[/comment] - // TODO: implement this method - // Ensure that you remove @generated or mark it @generated NOT - throw new UnsupportedOperationException(); -[comment]<%@ end %><%//Class/implementedGenOperation.todo.override.javajetinc%>[/comment] - [/if][/if][/if] - } - -[/if] -[comment]<%@ include file="Class/genOperation.insert.javajetinc" fail="silent" %>[/comment] -[comment]<%@ end %><%//Class/implementedGenOperation.override.javajetinc%>[/comment] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/reflectiveDelegationAlternative.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/reflectiveDelegationAlternative.mtl deleted file mode 100644 index 74b614a1e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genclass/reflectiveDelegationAlternative.mtl +++ /dev/null @@ -1,29 +0,0 @@ -[comment encoding = UTF-8 /] -[module reflectiveDelegationAlternative('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] - - -[template public reflectiveDelegationAlternative(genClass : GenClass, isImplementation : Boolean, genModel : GenModel)] -[if (isImplementation - and (genModel.featureDelegation = GenDelegationKind::Reflective - or genModel.isDynamicDelegation()) - and (genClass.getClassExtendsGenClass() = null - or (genClass.getClassExtendsGenClass().getGenModel().featureDelegation <> GenDelegationKind::Reflective - and not genClass.getClassExtendsGenClass().getGenModel().isDynamicDelegation()))) ] - /** - * - * - * @generated - */ - [if (genModel.useClassOverrideAnnotation()) ] - @Override - [/if] - protected int eStaticFeatureCount() - { - return [if genClass.getClassExtendsGenClass() = null]0[else][genClass.getClassExtendsGenClass().getAllGenFeatures()->size()/][/if]; - } - -[/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genpackage/EGenericType.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genpackage/EGenericType.mtl deleted file mode 100644 index e97c80901..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/genpackage/EGenericType.mtl +++ /dev/null @@ -1,44 +0,0 @@ -[comment encoding = UTF-8 /] -[module EGenericType('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] - -[query public depth(eGenericType : EGenericType) : Integer = - eGenericType.ancestors(EGenericType)->size() -/] - -[query public type(eGenericType : EGenericType, genModel : GenModel, genPackage : GenPackage) : String = - if (eGenericType.eClassifier <> null) then - let genClassifier : GenClassifier = genModel.findGenClassifier(eGenericType.eClassifier) in - genPackage.getPackageInstanceVariable(genClassifier.genPackage) - + '.get' + genClassifier.getClassifierAccessorName() + '()' - else - if (eGenericType.eTypeParameter <> null) then - let eTypeParameter : ETypeParameter = eGenericType.eTypeParameter in - if (eTypeParameter.eContainer().oclIsKindOf(EClass)) then - genModel.findGenClassifier( - eTypeParameter.eContainer().oclAsType(EClass)) - .getClassifierInstanceName() - + '_' + eGenericType.eTypeParameter.name - else - 't' + eTypeParameter.eContainer().oclAsType(EOperation).eTypeParameters->indexOf(eTypeParameter) - endif - else - '' - endif - endif -/] - -[query public accessor(eGenericType : EGenericType) : String = - if (eGenericType.depth() > 0) then - if (eGenericType.eContainmentFeature().many) then - 'getE' + eGenericType.eContainmentFeature().name.substring(2) + '().add' - else - 'setE' + eGenericType.eContainmentFeature().name.substring(2) - endif - else - '' - endif -/] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/manifest.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/manifest.mtl deleted file mode 100644 index 9c752eb6e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/manifest.mtl +++ /dev/null @@ -1,52 +0,0 @@ -[comment encoding = UTF-8 -/** - * - * - * Copyright (c) 2005-2007 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -/] -[module manifest('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] - -[template public manifest(genModel : GenModel)] -[file (genModel.manifestFilePath(), false, 'UTF-8')] -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: %pluginName -Bundle-SymbolicName: [genModel.modelPluginID/];singleton:=true -Bundle-Version: 1.0.0.qualifier -Bundle-ClassPath: [if (genModel.runtimeJar) ][genModel.modelPluginID/].jar[else].[/if] -[if (genModel.hasModelPluginClass()) ] -Bundle-Activator: [genModel.getQualifiedModelPluginClassName()/]$Implementation -[/if] -Bundle-Vendor: %providerName -Bundle-Localization: plugin -[if (genModel.complianceLevel = GenJDKLevel::JDK50) ] -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -[else][if (genModel.complianceLevel = GenJDKLevel::JDK60)] -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -[/if][/if] -Export-Package: [for (pack : String | genModel.getModelQualifiedPackageNames()) separator (',' + genModel.getLineDelimiter() + ' ')][pack/][/for] -Require-Bundle: [for (pluginID : String | genModel.getModelRequiredPlugins()) separator (',' + genModel.getLineDelimiter() + ' ')][pluginID.genRequireBundle()/][/for] -[if (genModel.runtimeVersion = GenRuntimeVersion::EMF22 or genModel.runtimeVersion = GenRuntimeVersion::EMF23) ] -Eclipse-LazyStart: true -[/if] -Bundle-ActivationPolicy: lazy -[/file] -[/template] - -[template protected genRequireBundle(pluginID : String) post (trim())] -[pluginID/][if (not pluginID.startsWith('org.eclipse.core.runtime'))];visibility:=reexport[/if] -[/template] - -[query public manifestFilePath(genModel : GenModel) : String = 'META-INF/MANIFEST.MF' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/module_gwt_xml.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/module_gwt_xml.mtl deleted file mode 100644 index 64cae3c61..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/module_gwt_xml.mtl +++ /dev/null @@ -1,42 +0,0 @@ -[comment encoding = UTF-8 /] -[module module_gwt_xml('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::header /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] - -[comment -/** - * - * - * Copyright (c) 2010 Ed Merks 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: - * Ed Merks - Initial API and implementation - * - * - */ -/] - -[template public moduleGwt(genModel : GenModel)] -[file (genModel.moduleGwtFileName(), false, 'UTF-8')] - - - -[includeHeaderXml()/] - - -[for (inherits : String | genModel.getModelModuleInherits())] - -[/for] -[for (source : String | genModel.getModelModuleSources())] - -[/for] - -[/file] -[/template] - -[query public moduleGwtFileName(genModel : GenModel) : String = 'module.gwt.xml' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/plugin_properties.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/plugin_properties.mtl deleted file mode 100644 index 5eafbd30a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/plugin_properties.mtl +++ /dev/null @@ -1,36 +0,0 @@ -[comment encoding = UTF-8 /] -[module plugin_properties('http://www.eclipse.org/emf/2002/GenModel')/] - -[comment -/** - * - * - * Copyright (c) 2002-2004 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] - -[template public pluginProperties(genModel : GenModel)] -[file (genModel.pluginPropertiesFilePath(), false, 'UTF-8')] -[genModel.includeHeaderProperties()/] -pluginName = [genModel.modelName/] Model -providerName = www.example.org -[for (genPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers()->select(isContentType())) before (genModel.getLineDelimiter())] -_UI_[genPackage.prefix/]_content_type = [genPackage.prefix/] File -[/for] -[/file] -[/template] - -[query public pluginPropertiesFilePath(genModel : GenModel) : String = 'plugin.properties' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/plugin_xml.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/plugin_xml.mtl deleted file mode 100644 index 7ef47e83b..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/model/plugin_xml.mtl +++ /dev/null @@ -1,113 +0,0 @@ -[comment encoding = UTF-8 /] -[module plugin_xml('http://www.eclipse.org/emf/2002/GenModel')/] - -[comment -/** - * - * - * Copyright (c) 2002-2005 IBM Corporation 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: - * IBM - Initial API and implementation - * - * - */ -/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::header /] - -[template public pluginXml(genModel : GenModel)] -[file (genModel.pluginXmlFilePath(), false, 'UTF-8')] - - - -[genModel.includeHeaderXml()/] - -[if (genModel.bundleManifest)] - -[else] - - [else] - provider-name="%providerName"> - [/if] - - - [for (pluginID : String | genModel.getModelRequiredPlugins())] - - [/for] - - - - [if (genModel.runtimeJar)] - - [else] - - [/if] - - - -[/if] -[for (genPackage : GenPackage | genModel.getAllGenPackagesWithClassifiers())] - - - - [else] - class="[genPackage.getQualifiedPackageInterfaceName()/]"/> - [/if] - - [if (genPackage.isContentType())] - - - - - - - - - [if (genPackage.hasTargetNamespace())] - - [/if] - [if (genPackage.isXMIResource())] - - [/if] - - - - [else][if (genPackage.resource <> GenResourceKind::None)] - - - - - [/if][/if] -[/for] - - -[/file] -[/template] - -[query public pluginXmlFilePath(genModel : GenModel) : String = 'plugin.xml' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/FileUtil.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/FileUtil.java deleted file mode 100644 index dfee05492..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/FileUtil.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; - -/** - * This class is used to manipulate files. - * - * @author Stephane Bouchet - */ -public class FileUtil { - - private static final String MODEL = "model"; - - private static final String EDIT = "edit"; - - private static final String EDITOR = "editor"; - - private static final String TESTS = "tests"; - - /** - * Indicates if the file matching the given path exists. - * - * @param genModel - * The genmodel. - * @param filePath - * The file path. - * @param generationKind - * The kind of generation (model, edit, editor or test) - * @return true if the file exists, false otherwise. - */ - public boolean fileExists(GenModel genModel, String filePath, String generationKind) { - boolean result = false; - - String outputFolder = null; - - if (EDIT.equals(generationKind)) { - outputFolder = genModel.getEditDirectory(); - } else if (EDITOR.equals(generationKind)) { - outputFolder = genModel.getEditorDirectory(); - } else if (MODEL.equals(generationKind)) { - outputFolder = genModel.getModelDirectory(); - } else if (TESTS.equals(generationKind)) { - outputFolder = genModel.getTestsDirectory(); - } - - if (outputFolder != null) { - IPath location = ResourcesPlugin.getWorkspace().getRoot().getLocation() - .append(new Path(outputFolder)); - IContainer iContainer = ResourcesPlugin.getWorkspace().getRoot() - .getContainerForLocation(location); - if (iContainer != null && iContainer.exists()) { - if (iContainer instanceof IProject) { - result = iContainer.getFile(new Path(filePath)).exists(); - } else { - result = iContainer.getProject().getFile(new Path(filePath)).exists(); - } - } - } - - return result; - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/Information.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/Information.java deleted file mode 100644 index 518cd3ec0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/Information.java +++ /dev/null @@ -1,29 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2002, 2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo generators - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services; - -import org.eclipse.emf.ecore.EGenericType; - -/** - * This class emulates an inner class used by EMF for the generation of Package classes. - * - * @author Stephane Bouchet - */ -public class Information { - EGenericType eGenericType; - - int depth; - - String type; - - String accessor; -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/InformationIterator.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/InformationIterator.java deleted file mode 100644 index 944725312..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/InformationIterator.java +++ /dev/null @@ -1,84 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2002, 2011 IBM Corporation 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: - * IBM - Initial API and implementation - * Obeo - Migrate to Acceleo generators - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services; - -import java.util.Collections; -import java.util.Iterator; - -import org.eclipse.emf.codegen.ecore.genmodel.GenClassifier; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EGenericType; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EOperation; -import org.eclipse.emf.ecore.ETypeParameter; -import org.eclipse.emf.ecore.util.EcoreUtil; - -/** - * This class emulates an inner class used by EMF for the generation of Package classes. - * - * @author Stephane Bouchet - */ -public class InformationIterator { - Iterator iterator; - - GenModel genModel; - - GenPackage genPackage; - - InformationIterator(EGenericType eGenericType, GenModel genModel, GenPackage genPackage) { - this.genModel = genModel; - this.genPackage = genPackage; - iterator = EcoreUtil.getAllContents(Collections.singleton(eGenericType)); - } - - boolean hasNext() { - return iterator.hasNext(); - } - - Information next() { - Information information = new Information(); - EGenericType eGenericType = information.eGenericType = (EGenericType)iterator.next(); - for (EObject container = eGenericType.eContainer(); container instanceof EGenericType; container = container - .eContainer()) { - ++information.depth; - } - if (eGenericType.getEClassifier() != null) { - GenClassifier genClassifier = genModel.findGenClassifier(eGenericType.getEClassifier()); - information.type = genPackage.getPackageInstanceVariable(genClassifier.getGenPackage()) + ".get" - + genClassifier.getClassifierAccessorName() + "()"; - } else if (eGenericType.getETypeParameter() != null) { - ETypeParameter eTypeParameter = eGenericType.getETypeParameter(); - if (eTypeParameter.eContainer() instanceof EClass) { - information.type = genModel.findGenClassifier((EClass)eTypeParameter.eContainer()) - .getClassifierInstanceName() + "_" + eGenericType.getETypeParameter().getName(); - } else { - information.type = "t" - + (((EOperation)eTypeParameter.eContainer()).getETypeParameters().indexOf( - eTypeParameter) + 1); - } - } else { - information.type = ""; - } - if (information.depth > 0) { - if (eGenericType.eContainmentFeature().isMany()) { - information.accessor = "getE" + eGenericType.eContainmentFeature().getName().substring(1) - + "().add"; - } else { - information.accessor = "setE" + eGenericType.eContainmentFeature().getName().substring(1); - } - } - return information; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/StringUtil.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/StringUtil.java deleted file mode 100644 index 3bb0e41af..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/StringUtil.java +++ /dev/null @@ -1,36 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services; - -import java.util.Locale; - -/** - * This class is used to manipulate strings. - * - * @author Stephane Bouchet - */ -public class StringUtil { - - public String toLowerCase(String string, Object locale) { - if (locale instanceof Locale) { - return string.toLowerCase((Locale) locale); - } - return string; - } - - public String genSquareBrackets(String string) { - StringBuffer buf = new StringBuffer(string.length() + 2); - buf.append("["); - buf.append(string); - buf.append("]"); - return buf.toString(); - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/StringUtil.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/StringUtil.mtl deleted file mode 100644 index 67f8fb332..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/StringUtil.mtl +++ /dev/null @@ -1,15 +0,0 @@ -[comment encoding = UTF-8 /] -[module StringUtil('http://www.eclipse.org/emf/2002/GenModel')/] - -[query public toLowerCase(genModel : GenModel, string : String, locale : OclAny) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.StringUtil', 'toLowerCase(java.lang.String, java.lang.Object)', Sequence{string, locale}) /] - -[query public genSquareBrackets(genModel : GenModel, string : String) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.StringUtil', 'genSquareBrackets(java.lang.String)', Sequence{string}) /] - -[query public extractSourceDirectory(genModel : GenModel, string : String) : String - = string.tokenize('/')->last()/] - -[query public toPath(s : String): String = s.substituteAll('.', '/')/] - -[query public isBlank(string : String) : Boolean = string.oclIsUndefined() or string->size() = 0/] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/common.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/common.mtl deleted file mode 100644 index 3ec1f6af3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/common.mtl +++ /dev/null @@ -1,14 +0,0 @@ -[comment encoding = UTF-8 /] -[module common('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::StringUtil /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] - -[query public editPath(genModel : GenModel, packageName : String, className : String) : String - = (extractSourceDirectory(genModel.editDirectory) + '.' + packageName + '.' + className).toPath() + '.java' /] - -[query public editorPath(genModel : GenModel, packageName : String, className : String) : String - = (extractSourceDirectory(genModel.editorDirectory) + '.' + packageName + '.' + className).toPath() + '.java' /] - -[query public modelPath(genModel : GenModel, packageName : String, className : String) : String - = (extractSourceDirectory(genModel.modelDirectory) + '.' + packageName + '.' + className).toPath() + '.java' /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/fileUtil.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/fileUtil.mtl deleted file mode 100644 index 944d93d98..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/fileUtil.mtl +++ /dev/null @@ -1,22 +0,0 @@ -[comment encoding = UTF-8 /] -[module fileUtil('http://www.eclipse.org/emf/2002/GenModel')/] - -[query public fileExistsModel(aGenModel : GenModel, aFilePath : String) : Boolean = - fileExists(aGenModel, aFilePath, 'model') -/] - -[query public fileExistsEdit(aGenModel : GenModel, aFilePath : String) : Boolean = - fileExists(aGenModel, aFilePath, 'edit') -/] - -[query public fileExistsEditor(aGenModel : GenModel, aFilePath : String) : Boolean = - fileExists(aGenModel, aFilePath, 'editor') -/] - -[query public fileExistsTests(aGenModel : GenModel, aFilePath : String) : Boolean = - fileExists(aGenModel, aFilePath, 'tests') -/] - -[query private fileExists(aGenModel : GenModel, aFilePath : String, aGenerationKind : String) : Boolean = - invoke('org.eclipse.emf.eef.codegen.ecore.services.FileUtil', 'fileExists(org.eclipse.emf.codegen.ecore.genmodel.GenModel, java.lang.String, java.lang.String)', Sequence{aGenModel, aFilePath, aGenerationKind}) -/] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/header.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/header.mtl deleted file mode 100644 index d1d70b234..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/header.mtl +++ /dev/null @@ -1,42 +0,0 @@ -[comment encoding = UTF-8 /] -[module header('http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenBase /] - -[template public includeHeader(copyrightHolder : GenBase)] -/** -[if (copyrightHolder.hasCopyright())] - * [copyrightHolder.getCopyright('')/][comment TODO: invoke getCopyright() on copyrightHolder.getGenModel().getIndentation(stringbuffer) when I will know how to have StringBuffer/] -[else] - * - * - * - * $['Id'.toString()/]$ -[/if] - */ -[/template] - -[template public includeHeaderProperties(copyrightHolder : GenBase)] - -[if (copyrightHolder.hasCopyright())] -# [copyrightHolder.getCopyright('')/][comment <%=copyrightHolder.getCopyright(copyrightHolder.getGenModel().getIndentation(stringBuffer))%>/] -[else] -# -# -# -# $['Id'.toString()/]$ -[/if] -[/template] - -[template public includeHeaderXml(copyrightHolder : GenBase)] - -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/EAnnotation.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/EAnnotation.mtl deleted file mode 100644 index a0a5bafb7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/EAnnotation.mtl +++ /dev/null @@ -1,22 +0,0 @@ -[comment encoding = Cp1252 /] -[module EAnnotation('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public writeKeyValuePairs(eAnnotation : EAnnotation, genModel : GenModel) : String = - invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.EAnnotationWrapper', 'writeKeyValuePairs(org.eclipse.emf.ecore.EAnnotation, org.eclipse.emf.codegen.ecore.genmodel.GenModel)', Sequence {eAnnotation, genModel}) -/] - -[query public hasReferenceData(eAnnotation : EAnnotation, genPackage : GenPackage) : Boolean = - invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.EAnnotationWrapper', 'hasReferenceData(org.eclipse.emf.ecore.EAnnotation, org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence {eAnnotation, genPackage}) -/] - -[query public referenceDataSize(eAnnotation : EAnnotation, genPackage : GenPackage) : Integer = - invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.EAnnotationWrapper', 'referenceDataSize(org.eclipse.emf.ecore.EAnnotation, org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence {eAnnotation, genPackage}) -/] - -[query public depth(eAnnotation : EAnnotation) : Integer = - invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.EAnnotationWrapper', 'depth(org.eclipse.emf.ecore.EAnnotation)', Sequence {eAnnotation}) -/] - -[query public getReferenceData(eAnnotation : EAnnotation, genPackage : GenPackage) : Sequence(Sequence(OclAny)) = - invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.EAnnotationWrapper', 'getReferenceData(org.eclipse.emf.ecore.EAnnotation, org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence {eAnnotation, genPackage}) -/] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/EAnnotationWrapper.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/EAnnotationWrapper.java deleted file mode 100644 index 02c792860..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/EAnnotationWrapper.java +++ /dev/null @@ -1,84 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services.wrappers; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Iterator; -import java.util.List; -import java.util.Map; - -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage.AnnotationReferenceData; -import org.eclipse.emf.codegen.ecore.genmodel.impl.Literals; -import org.eclipse.emf.ecore.EAnnotation; -import org.eclipse.emf.ecore.EObject; -/** - * @author Stephane Bouchet - * @since 1.1 - */ -public class EAnnotationWrapper { - - public String writeKeyValuePairs(EAnnotation eAnnotation, GenModel genModel) { - StringBuilder b = new StringBuilder(); - for (Iterator> l = eAnnotation.getDetails() - .iterator(); l.hasNext();) { - Map.Entry detail = l.next(); - String key = Literals.toStringLiteral(detail.getKey(), genModel); - String value = Literals - .toStringLiteral(detail.getValue(), genModel); - b.append(key).append(", ").append(value) - .append(l.hasNext() ? "," : "") - .append(genModel.getNonNLS(key + value)); - if (l.hasNext()) - b.append("\t\t\t "); - } - return b.toString(); - } - - public boolean hasReferenceData(EAnnotation eAnnotation, - GenPackage genPackage) { - List refData = getRefData( - eAnnotation, genPackage); - return refData == null || refData.isEmpty(); - } - - public int referenceDataSize(EAnnotation eAnnotation, - GenPackage genPackage) { - List refData = getRefData( - eAnnotation, genPackage); - return refData == null ? 0 : refData.size(); - } - - public int depth(EAnnotation eAnnotation) { - int depth = 0; - EObject eCont = eAnnotation.eContainer(); - if (eCont instanceof EAnnotation) { - depth = depth((EAnnotation) eCont) + 1; - } - return depth; - } - - public List> getReferenceData(EAnnotation eAnnotation, GenPackage genPackage) { - List refData = genPackage.getReferenceData(eAnnotation); - List> result = new ArrayList>(); - for (AnnotationReferenceData annotationReferenceData : refData) { - result.add(Arrays.asList(annotationReferenceData.containingGenPackage, annotationReferenceData.uriFragment)); - } - return result; - } - - private List getRefData( - EAnnotation nestedEAnnotation, GenPackage genPackage) { - return genPackage.getReferenceData(nestedEAnnotation); - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenBase.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenBase.mtl deleted file mode 100644 index 324406859..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenBase.mtl +++ /dev/null @@ -1,54 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenBase('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public canGenerate(genBase : GenBase) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'canGenerate()', Sequence{genBase}) /] - -[query public canGenerateEdit(genBase : GenBase) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'canGenerateEdit()', Sequence{genBase}) /] - -[query public canGenerateEditor(genBase : GenBase) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'canGenerateEditor()', Sequence{genBase}) /] - -[query public canGenerateSchema(genBase : GenBase) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'canGenerateSchema()', Sequence{genBase}) /] - -[query public canGenerateTests(genBase : GenBase) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'canGenerateTests()', Sequence{genBase}) /] - -[query public capName(genBase : GenBase, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'capName(java.lang.String)', Sequence{genBase, name}) /] - -[query public getCopyright(genBase : GenBase, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'getCopyright(java.lang.String)', Sequence{genBase, indentation}) /] - -[query public getDocumentation(genBase : GenBase, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'getDocumentation(java.lang.String)', Sequence{genBase, indentation}) /] - -[query public getEcoreModelElement(genBase : GenBase) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'getEcoreModelElement()', Sequence{genBase}) /] - -[query public getGenAnnotation(genBase : GenBase, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'getGenAnnotation(java.lang.String)', Sequence{genBase, source}) /] - -[query public getGenModel(genBase : GenBase) : GenModel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'getGenModel()', Sequence{genBase}) /] - -[query public hasCopyright(genBase : GenBase) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'hasCopyright()', Sequence{genBase}) /] - -[query public hasDocumentation(genBase : GenBase) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'hasDocumentation()', Sequence{genBase}) /] - -[query public reconcile(genBase : GenBase) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'reconcile()', Sequence{genBase}) /] - -[query public safeName(genBase : GenBase, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'safeName(java.lang.String)', Sequence{genBase, name}) /] - -[query public uncapName(genBase : GenBase, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'uncapName(java.lang.String)', Sequence{genBase, name}) /] - -[query public uncapPrefixedName(genBase : GenBase, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenBase', 'uncapPrefixedName(java.lang.String)', Sequence{genBase, input}) /] - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClass.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClass.mtl deleted file mode 100644 index f0d35e5a7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClass.mtl +++ /dev/null @@ -1,678 +0,0 @@ -[module GenClass('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenBase /] -[import org::eclipse::emf::eef::codegen::ecore::services::common/] - - -[query public getAbstractFlag(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getAbstractFlag()', Sequence{genClass}) /] - -[query public getAllBaseGenClasses(genClass : GenClass) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getAllBaseGenClasses()', Sequence{genClass}) /] - -[query public getAllChildrenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getAllChildrenFeatures()', Sequence{genClass}) /] - -[query public getAllCreateChildFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getAllCreateChildFeatures()', Sequence{genClass}) /] - -[query public getAllCreateChildFeaturesIncludingDelegation(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getAllCreateChildFeaturesIncludingDelegation()', Sequence{genClass}) /] - -[comment][query public getAllEVirtualIndexBitFields(genClass : GenClass, allEVirtualIndexBitFields : Sequence(String)) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getAllEVirtualIndexBitFields(Sequence(String))', Sequence{genClass, allEVirtualIndexBitFields}) /][/comment] - -[query public getAllGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getAllGenFeatures()', Sequence{genClass}) /] - -[query public getAllGenOperations(genClass : GenClass) : Sequence(GenOperation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getAllGenOperations()', Sequence{genClass}) /] - -[query public getAllGenOperations(genClass : GenClass, excludeOverrides : Boolean) : Sequence(GenOperation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getAllGenOperations(boolean)', Sequence{genClass, excludeOverrides}) /] - -[query public getBaseGenClass(genClass : GenClass) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getBaseGenClass()', Sequence{genClass}) /] - -[query public getBaseGenClasses(genClass : GenClass) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getBaseGenClasses()', Sequence{genClass}) /] - -[query public getCastFromEObject(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getCastFromEObject()', Sequence{genClass}) /] - -[query public getChildrenClasses(genClass : GenClass, genFeature : GenFeature) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getChildrenClasses(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getChildrenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getChildrenFeatures()', Sequence{genClass}) /] - -[query public getClassExtends(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getClassExtends()', Sequence{genClass}) /] - -[query public getClassExtendsGenClass(genClass : GenClass) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getClassExtendsGenClass()', Sequence{genClass}) /] - -[query public getClassImplements(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getClassImplements()', Sequence{genClass}) /] - -[query public getClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getClassName()', Sequence{genClass}) /] - -[query public getClassTypeArguments(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getClassTypeArguments()', Sequence{genClass}) /] - -[query public getContentNotifyFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getContentNotifyFeatures()', Sequence{genClass}) /] - -[query public getCreateChildFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getCreateChildFeatures()', Sequence{genClass}) /] - -[query public getCreateChildFeaturesIncludingDelegation(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getCreateChildFeaturesIncludingDelegation()', Sequence{genClass}) /] - -[query public getCreateChildIconFileName(genClass : GenClass, genModel : GenModel, feature : GenFeature, childClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getCreateChildIconFileName(org.eclipse.emf.codegen.ecore.genmodel.GenModel, org.eclipse.emf.codegen.ecore.genmodel.GenFeature, org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass, genModel, feature, childClass}) /] - -[query public getCreateChildIconFileName(genClass : GenClass, feature : GenFeature, childClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getCreateChildIconFileName(org.eclipse.emf.codegen.ecore.genmodel.GenFeature, org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass, feature, childClass}) /] - -[query public getCrossPackageChildrenClasses(genClass : GenClass, genFeature : GenFeature) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getCrossPackageChildrenClasses(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getCrossPackageCreateChildFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getCrossPackageCreateChildFeatures()', Sequence{genClass}) /] - -[query public getDeclaredFieldGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getDeclaredFieldGenFeatures()', Sequence{genClass}) /] - -[query public getDeclaredGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getDeclaredGenFeatures()', Sequence{genClass}) /] - -[query public getDeclaredGenOperations(genClass : GenClass) : Sequence(GenOperation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getDeclaredGenOperations()', Sequence{genClass}) /] - -[query public getEBasicRemoveFromContainerGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getEBasicRemoveFromContainerGenFeatures()', Sequence{genClass}) /] - -[query public getEGetGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getEGetGenFeatures()', Sequence{genClass}) /] - -[query public getEInverseAddGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getEInverseAddGenFeatures()', Sequence{genClass}) /] - -[query public getEInverseRemoveGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getEInverseRemoveGenFeatures()', Sequence{genClass}) /] - -[query public getEIsSetGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getEIsSetGenFeatures()', Sequence{genClass}) /] - -[query public getESetFlagIndex(genClass : GenClass, genFeature : GenFeature) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getESetFlagIndex(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getESetFlagsField(genClass : GenClass, genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getESetFlagsField(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getESetGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getESetGenFeatures()', Sequence{genClass}) /] - -[query public getEUnsetGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getEUnsetGenFeatures()', Sequence{genClass}) /] - -[comment][query public getEVirtualIndexBitFields(genClass : GenClass, eVirtualIndexBitFields : Sequence(String)) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getEVirtualIndexBitFields(Sequence(String))', Sequence{genClass, eVirtualIndexBitFields}) /][/comment] - -[query public getEVirtualValuesField(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getEVirtualValuesField()', Sequence{genClass}) /] - -[query public getExtendedGenClasses(genClass : GenClass) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getExtendedGenClasses()', Sequence{genClass}) /] - -[query public getExtendedGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getExtendedGenFeatures()', Sequence{genClass}) /] - -[query public getExtendedGenOperations(genClass : GenClass) : Sequence(GenOperation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getExtendedGenOperations()', Sequence{genClass}) /] - -[query public getFeatureCount(genClass : GenClass) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFeatureCount()', Sequence{genClass}) /] - -[query public getFeatureCountID(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFeatureCountID()', Sequence{genClass}) /] - -[query public getFeatureCountValue(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFeatureCountValue()', Sequence{genClass}) /] - -[query public getFeatureID(genClass : GenClass, genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFeatureID(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getFeatureValue(genClass : GenClass, genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFeatureValue(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getFlagGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFlagGenFeatures()', Sequence{genClass}) /] - -[query public getFlagGenFeatures(genClass : GenClass, staticDefaultValue : String) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFlagGenFeatures(java.lang.String)', Sequence{genClass, staticDefaultValue}) /] - -[query public getFlagGenFeaturesWithDefault(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFlagGenFeaturesWithDefault()', Sequence{genClass}) /] - -[query public getFlagIndex(genClass : GenClass, genFeature : GenFeature) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFlagIndex(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getFlagMask(genClass : GenClass, genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFlagMask(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getFlagSize(genClass : GenClass, genFeature : GenFeature) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFlagSize(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getFlagsField(genClass : GenClass, genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFlagsField(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getGetAccessorOperation(genClass : GenClass, genFeature : GenFeature) : GenOperation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getGetAccessorOperation(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getImplementedGenClasses(genClass : GenClass) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImplementedGenClasses()', Sequence{genClass}) /] - -[query public getImplementedGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImplementedGenFeatures()', Sequence{genClass}) /] - -[query public getImplementedGenOperations(genClass : GenClass) : Sequence(GenOperation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImplementedGenOperations()', Sequence{genClass}) /] - -[query public getImplementingGenModel(genClass : GenClass, genFeature : GenFeature) : GenModel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImplementingGenModel(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getImportedClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImportedClassName()', Sequence{genClass}) /] - -[query public getImportedInterfaceName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImportedInterfaceName()', Sequence{genClass}) /] - -[query public getImportedProviderClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImportedProviderClassName()', Sequence{genClass}) /] - -[query public getImportedTestCaseClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImportedTestCaseClassName()', Sequence{genClass}) /] - -[query public getInheritedGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getInheritedGenFeatures()', Sequence{genClass}) /] - -[query public getInterfaceExtends(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getInterfaceExtends()', Sequence{genClass}) /] - -[query public getInterfaceFlag(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getInterfaceFlag()', Sequence{genClass}) /] - -[query public getInterfaceName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getInterfaceName()', Sequence{genClass}) /] - -[query public getInterfaceTypeArguments(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getInterfaceTypeArguments()', Sequence{genClass}) /] - -[query public getInterfaceWildTypeArguments(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getInterfaceWildTypeArguments()', Sequence{genClass}) /] - -[query public getInvariantOperation(genClass : GenClass, constraint : String) : GenOperation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getInvariantOperation(java.lang.String)', Sequence{genClass, constraint}) /] - -[query public getInvariantOperations(genClass : GenClass) : Sequence(GenOperation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getInvariantOperations()', Sequence{genClass}) /] - -[query public getIsSetAccessorOperation(genClass : GenClass, genFeature : GenFeature) : GenOperation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getIsSetAccessorOperation(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getItemIconAccessorName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getItemIconAccessorName()', Sequence{genClass}) /] - -[query public getItemIconFileName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getItemIconFileName()', Sequence{genClass}) /] - -[query public getItemProviderAdapterFactoryClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getItemProviderAdapterFactoryClassName()', Sequence{genClass}) /] - -[query public getLabelAndContentNotifyFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getLabelAndContentNotifyFeatures()', Sequence{genClass}) /] - -[query public getLabelFeatureCandidates(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getLabelFeatureCandidates()', Sequence{genClass}) /] - -[query public getLabelNotifyFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getLabelNotifyFeatures()', Sequence{genClass}) /] - -[query public getListConstructor(genClass : GenClass, genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getListConstructor(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getLocalFeatureIndex(genClass : GenClass, genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getLocalFeatureIndex(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getLocalOperationIndex(genClass : GenClass, genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getLocalOperationIndex(org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genClass, genOperation}) /] - -[query public getMapEntryKeyFeature(genClass : GenClass) : GenFeature - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getMapEntryKeyFeature()', Sequence{genClass}) /] - -[query public getMapEntryValueFeature(genClass : GenClass) : GenFeature - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getMapEntryValueFeature()', Sequence{genClass}) /] - -[query public getMixedGenFeature(genClass : GenClass) : GenFeature - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getMixedGenFeature()', Sequence{genClass}) /] - -[query public getMixinGenClasses(genClass : GenClass) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getMixinGenClasses()', Sequence{genClass}) /] - -[query public getMixinGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getMixinGenFeatures()', Sequence{genClass}) /] - -[query public getMixinGenOperations(genClass : GenClass) : Sequence(GenOperation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getMixinGenOperations()', Sequence{genClass}) /] - -[query public getModelInfo(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getModelInfo()', Sequence{genClass}) /] - -[query public getNotifyFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getNotifyFeatures()', Sequence{genClass}) /] - -[query public getOffsetCorrectionField(genClass : GenClass, genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getOffsetCorrectionField(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getOperationCount(genClass : GenClass) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getOperationCount()', Sequence{genClass}) /] - -[query public getOperationCountID(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getOperationCountID()', Sequence{genClass}) /] - -[query public getOperationCountValue(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getOperationCountValue()', Sequence{genClass}) /] - -[query public getOperationID(genClass : GenClass, genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getOperationID(org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genClass, genOperation}) /] - -[query public getOperationID(genClass : GenClass, genOperation : GenOperation, diagnosticCode : Boolean) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getOperationID(org.eclipse.emf.codegen.ecore.genmodel.GenOperation, boolean)', Sequence{genClass, genOperation, diagnosticCode}) /] - -[query public getOperationValue(genClass : GenClass, genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getOperationValue(org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genClass, genOperation}) /] - -[query public getOverrideGenOperation(genClass : GenClass, genOperation : GenOperation) : GenOperation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getOverrideGenOperation(org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genClass, genOperation}) /] - -[comment][query public getOverrideGenOperations(genClass : GenClass, baseGenOperations : Sequence(GenOperation), derivedGenOperations : Sequence(GenOperation)) : Sequence(GenOperation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getOverrideGenOperations(Sequence(GenOperation), Sequence(GenOperation))', Sequence{genClass, baseGenOperations, derivedGenOperations}) /][/comment] - -[query public getPropertyFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getPropertyFeatures()', Sequence{genClass}) /] - -[query public getProviderBaseClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getProviderBaseClassName()', Sequence{genClass}) /] - -[query public getProviderClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getProviderClassName()', Sequence{genClass}) /] - -[query public getProviderExtendsGenClass(genClass : GenClass) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getProviderExtendsGenClass()', Sequence{genClass}) /] - -[query public getProviderImplementedGenClasses(genClass : GenClass) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getProviderImplementedGenClasses()', Sequence{genClass}) /] - -[query public getQualifiedClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getQualifiedClassName()', Sequence{genClass}) /] - -[query public getQualifiedFeatureCountID(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getQualifiedFeatureCountID()', Sequence{genClass}) /] - -[query public getQualifiedFeatureID(genClass : GenClass, genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getQualifiedFeatureID(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature})/] - -[query public getQualifiedInterfaceName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getQualifiedInterfaceName()', Sequence{genClass}) /] - -[query public getQualifiedOperationCountID(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getQualifiedOperationCountID()', Sequence{genClass}) /] - -[query public getQualifiedOperationID(genClass : GenClass, genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getQualifiedOperationID(org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genClass, genOperation}) /] - -[query public getQualifiedProviderClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getQualifiedProviderClassName()', Sequence{genClass}) /] - -[query public getQualifiedTestCaseClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getQualifiedTestCaseClassName()', Sequence{genClass}) /] - -[query public getRawImportedInterfaceName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getRawImportedInterfaceName()', Sequence{genClass}) /] - -[query public getSetAccessorOperation(genClass : GenClass, genFeature : GenFeature) : GenOperation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getSetAccessorOperation(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public getSharedClassCreateChildFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getSharedClassCreateChildFeatures()', Sequence{genClass}) /] - -[query public getSwitchGenClasses(genClass : GenClass) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getSwitchGenClasses()', Sequence{genClass}) /] - -[query public getTestCaseClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getTestCaseClassName()', Sequence{genClass}) /] - -[query public getToStringGenFeatures(genClass : GenClass) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getToStringGenFeatures()', Sequence{genClass}) /] - -[query public getTypeParameters(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getTypeParameters()', Sequence{genClass}) /] - -[query public getUncapName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getUncapName()', Sequence{genClass}) /] - -[query public getUniqueName(genClass : GenClass, genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getUniqueName(org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genClass, genOperation}) /] - -[query public getUnsetAccessorOperation(genClass : GenClass, genFeature : GenFeature) : GenOperation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getUnsetAccessorOperation(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public hasCollidingGetAccessorOperation(genClass : GenClass, genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasCollidingGetAccessorOperation(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public hasCollidingIsSetAccessorOperation(genClass : GenClass, genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasCollidingIsSetAccessorOperation(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public hasCollidingSetAccessorOperation(genClass : GenClass, genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasCollidingSetAccessorOperation(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public hasCollidingUnsetAccessorOperation(genClass : GenClass, genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasCollidingUnsetAccessorOperation(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public hasFactoryInterfaceCreateMethod(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasFactoryInterfaceCreateMethod()', Sequence{genClass}) /] - -[query public hasFeatureMapCreateChildFeatures(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasFeatureMapCreateChildFeatures()', Sequence{genClass}) /] - -[query public hasGenericSuperTypes(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasGenericSuperTypes()', Sequence{genClass}) /] - -[query public hasImplementedToStringGenOperation(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasImplementedToStringGenOperation()', Sequence{genClass}) /] - -[query public hasOffsetCorrection(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasOffsetCorrection()', Sequence{genClass}) /] - -[query public hasTests(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasTests()', Sequence{genClass}) /] - -[query public isAbstract(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isAbstract()', Sequence{genClass}) /] - -[query public isDocumentRoot(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isDocumentRoot()', Sequence{genClass}) /] - -[query public isEObject(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isEObject()', Sequence{genClass}) /] - -[query public isEObjectExtension(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isEObjectExtension()', Sequence{genClass}) /] - -[query public isESetField(genClass : GenClass, genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isESetField(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public isESetFlag(genClass : GenClass, genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isESetFlag(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public isExternalInterface(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isExternalInterface()', Sequence{genClass}) /] - -[query public isField(genClass : GenClass, genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isField(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public isFlag(genClass : GenClass, genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isFlag(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genClass, genFeature}) /] - -[query public isInterface(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isInterface()', Sequence{genClass}) /] - -[query public isJavaIOSerializable(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isJavaIOSerializable()', Sequence{genClass}) /] - -[query public isMapEntry(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isMapEntry()', Sequence{genClass}) /] - -[query public isModelRoot(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isModelRoot()', Sequence{genClass}) /] - -[query public isProviderSingleton(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isProviderSingleton()', Sequence{genClass}) /] - -[query public needsHasChildrenMethodOverride(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'needsHasChildrenMethodOverride()', Sequence{genClass}) /] - -[query public needsRootExtendsInterfaceExtendsTag(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'needsRootExtendsInterfaceExtendsTag()', Sequence{genClass}) /] - -[query public reconcile(genClass : GenClass, oldGenClassVersion : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass, oldGenClassVersion}) /] - -[comment - Override of services for super interface GenClassifier -/] -[query public getAllGenConstraints(genClass : GenClass) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getAllGenConstraints()', Sequence{genClass}) /] - -[query public getClassifierAccessorName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getClassifierAccessorName()', Sequence{genClass}) /] - -[query public getClassifierID(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getClassifierID()', Sequence{genClass}) /] - -[query public getClassifierInstanceName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getClassifierInstanceName()', Sequence{genClass}) /] - -[query public getConstraintDelegate(genClass : GenClass, constraint : String) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getConstraintDelegate(java.lang.String)', Sequence{genClass, constraint}) /] - -[query public getConstraintExpression(genClass : GenClass, constraint : String, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getConstraintExpression(java.lang.String, java.lang.String)', Sequence{genClass, constraint, indentation}) /] - -[query public getConstraintImplementor(genClass : GenClass, constraint : String) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getConstraintImplementor(java.lang.String)', Sequence{genClass, constraint}) /] - -[query public getEcoreClassifier(genClass : GenClass) : EClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getEcoreClassifier()', Sequence{genClass}) /] - -[query public getFormattedName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getFormattedName()', Sequence{genClass}) /] - -[query public getGenConstraints(genClass : GenClass) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getGenConstraints()', Sequence{genClass}) /] - -[query public getGenModel(genClass : GenClass) : GenModel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getGenModel()', Sequence{genClass}) /] - -[query public getGeneratedInstanceClassFlag(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getGeneratedInstanceClassFlag()', Sequence{genClass}) /] - -[query public getImportedBoundedWildcardInstanceClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImportedBoundedWildcardInstanceClassName()', Sequence{genClass}) /] - -[query public getImportedInstanceClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImportedInstanceClassName()', Sequence{genClass}) /] - -[query public getImportedMetaType(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImportedMetaType()', Sequence{genClass}) /] - -[query public getImportedParameterizedInstanceClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImportedParameterizedInstanceClassName()', Sequence{genClass}) /] - -[query public getImportedWildcardInstanceClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getImportedWildcardInstanceClassName()', Sequence{genClass}) /] - -[query public getMetaType(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getMetaType()', Sequence{genClass}) /] - -[query public getName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getName()', Sequence{genClass}) /] - -[query public getQualifiedClassifierAccessor(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getQualifiedClassifierAccessor()', Sequence{genClass}) /] - -[query public getRawImportedInstanceClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getRawImportedInstanceClassName()', Sequence{genClass}) /] - -[query public getRawInstanceClassName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getRawInstanceClassName()', Sequence{genClass}) /] - -[query public getSafeUncapName(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getSafeUncapName()', Sequence{genClass}) /] - -[query public getValidationDelegate(genClass : GenClass, constraint : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getValidationDelegate(java.lang.String)', Sequence{genClass, constraint}) /] - -[query public hasConstraintExpression(genClass : GenClass, constraint : String) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasConstraintExpression(java.lang.String)', Sequence{genClass, constraint}) /] - -[query public hasOnlyDefaultConstraints(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasOnlyDefaultConstraints()', Sequence{genClass}) /] - -[query public isUncheckedCast(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'isUncheckedCast()', Sequence{genClass}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'canGenerate()', Sequence{genClass}) /] - -[query public canGenerateEdit(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'canGenerateEdit()', Sequence{genClass}) /] - -[query public canGenerateEditor(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'canGenerateEditor()', Sequence{genClass}) /] - -[query public canGenerateSchema(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'canGenerateSchema()', Sequence{genClass}) /] - -[query public canGenerateTests(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'canGenerateTests()', Sequence{genClass}) /] - -[query public capName(genClass : GenClass, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'capName(java.lang.String)', Sequence{genClass, name}) /] - -[query public getCopyright(genClass : GenClass, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getCopyright(java.lang.String)', Sequence{genClass, indentation}) /] - -[query public getDocumentation(genClass : GenClass, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getDocumentation(java.lang.String)', Sequence{genClass, indentation}) /] - -[query public getEcoreModelElement(genClass : GenClass) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getEcoreModelElement()', Sequence{genClass}) /] - -[query public getGenAnnotation(genClass : GenClass, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'getGenAnnotation(java.lang.String)', Sequence{genClass, source}) /] - -[query public hasCopyright(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasCopyright()', Sequence{genClass}) /] - -[query public hasDocumentation(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'hasDocumentation()', Sequence{genClass}) /] - -[query public reconcile(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'reconcile()', Sequence{genClass}) /] - -[query public safeName(genClass : GenClass, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'safeName(java.lang.String)', Sequence{genClass, name}) /] - -[query public uncapName(genClass : GenClass, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'uncapName(java.lang.String)', Sequence{genClass, name}) /] - -[query public uncapPrefixedName(genClass : GenClass, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'uncapPrefixedName(java.lang.String)', Sequence{genClass, input}) /] - -[query public addClassPseudoImports(genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClass', 'addClassPsuedoImports()', Sequence{genClass}) /] - - - - - - -[query public overridesExtendedGenOperations(genClass : GenClass, extendedGenClass : GenClass) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'overridesExtendedGenOperations(org.eclipse.emf.codegen.ecore.genmodel.GenClass, org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass, extendedGenClass}) /] - -[query public overridesGenOperations(genClass : GenClass) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'overridesGenOperations(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public implementsAnyEInverseAddGenFeatures(genClass : GenClass ) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'implementsAnyEInverseAddGenFeatures(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public implementsAnyEInverseRemoveGenFeatures(genClass : GenClass ) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'implementsAnyEInverseRemoveGenFeatures(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public implementsAnyEBasicRemoveFromContainerGenFeatures(genClass : GenClass ) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'implementsAnyEBasicRemoveFromContainerGenFeatures(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public implementsAnyEGetGenFeatures(genClass : GenClass ) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'implementsAnyEGetGenFeatures(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public implementsAnyESetGenFeatures(genClass : GenClass ) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'implementsAnyESetGenFeatures(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public implementsAnyEUnsetGenFeatures(genClass : GenClass ) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'implementsAnyEUnsetGenFeatures(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public implementsAnyEIsSetGenFeatures(genClass : GenClass ) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'implementsAnyEIsSetGenFeatures(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[comment - This query is used to reproduce getOffsetCorrectionField(null), used in EMF, - but which cannot be translated "as is" with Acceleo - because of a bug in OCL when handling 'null' in sequences. -/] -[query public getDefaultOffsetCorrectionField(genClass : GenClass) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'getDefaultOffsetCorrectionField(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public getInternalQualifiedInterfaceName(genClass : GenClass) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'getInternalQualifiedInterfaceName(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public getInternalQualifiedInterfaceName(genClass : GenClass, boolean : Boolean) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'getInternalQualifiedInterfaceName(org.eclipse.emf.codegen.ecore.genmodel.GenClass, java.lang.Boolean)', Sequence{genClass, boolean}) /] - -[query public getChildCreationData(genClass : GenClass) : Sequence(OclAny) - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'getChildCreationData(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public getChildCreationDataCreateFeature(oclAny : OclAny ) : GenFeature - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'getCreateFeature(java.lang.Object)', Sequence{oclAny}) /] - -[query public getChildCreationDataDelegatedFeature(oclAny : OclAny ) : GenFeature - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'getDelegatedFeature(java.lang.Object)', Sequence{oclAny}) /] - -[query public getChildCreationDataCreateClassifier(oclAny : OclAny ) : GenClassifier - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'getCreateClassifier(java.lang.Object)', Sequence{oclAny}) /] - -[query public getEVirtualIndexBitFields(genClass : GenClass) : Sequence(String) - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'getEVirtualIndexBitFields(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public getAllEVirtualIndexBitFields(genClass : GenClass) : Sequence(String) - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'getAllEVirtualIndexBitFields(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public getUniqueNameUpperCase(genClass : GenClass, genOp : GenOperation) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'getUniqueNameUpperCase(org.eclipse.emf.codegen.ecore.genmodel.GenClass, org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genClass, genOp}) /] - -[comment - Returns the imports to insert at the relevant position in the output file. - The 2 parameters are just used to prevent acceleo from caching the result of this query, - which must be evaluated for each generated class. - The same GenClass is used to generate an interface and an implementation class. - @param isInterface is here to prevent Acceleo from caching things. - @param isImplementation is here to prevent Acceleo from caching things. -/] -[query public genSortedImports(genClass : GenClass, isInterface : Boolean, isImplementation : Boolean) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'genSortedImports(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[comment For Icons generation /] -[query public generateItemIcon(genClass: GenClass) : OclVoid - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'generateItemIcon(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - -[query public generateCreateChildIcons(genClass: GenClass) : OclVoid - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassWrapper', 'generateCreateChildIcons(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genClass}) /] - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassWrapper.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassWrapper.java deleted file mode 100644 index d8af63c40..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassWrapper.java +++ /dev/null @@ -1,212 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services.wrappers; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.codegen.ecore.genmodel.GenClass; -import org.eclipse.emf.codegen.ecore.genmodel.GenClass.ChildCreationData; -import org.eclipse.emf.codegen.ecore.genmodel.GenClassifier; -import org.eclipse.emf.codegen.ecore.genmodel.GenFeature; -import org.eclipse.emf.codegen.ecore.genmodel.GenJDKLevel; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.GenOperation; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.codegen.ecore.genmodel.generator.GenClassGeneratorAdapter; -import org.eclipse.emf.codegen.util.CodeGenUtil; -import org.eclipse.emf.codegen.util.GIFEmitter; -import org.eclipse.emf.codegen.util.ImportManager; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.eef.codegen.ecore.EMFCodegenPlugin; - -/** - * @author Stephane Bouchet - */ -public class GenClassWrapper { - - public String getInternalQualifiedInterfaceName(GenClass genClass, Boolean includeTemplateArguments) { - if (genClass.isDynamic()) { - GenClass baseGenClass = genClass.getBaseGenClass(); - return baseGenClass == null ? "org.eclipse.emf.ecore.EObject" - : getInternalQualifiedInterfaceName((GenClass)baseGenClass); - } - - return genClass.getEcoreClass().getInstanceClassName() != null ? includeTemplateArguments ? genClass - .getEcoreClass().getInstanceTypeName() : genClass.getEcoreClass().getInstanceClassName() - : genClass.getGenPackage().getInterfacePackageName() + "." + genClass.getInterfaceName(); - } - - public String getInternalQualifiedInterfaceName(GenClass genClass) { - return getInternalQualifiedInterfaceName(genClass, - getEffectiveComplianceLevel(genClass).getValue() >= GenJDKLevel.JDK50); - } - - protected GenJDKLevel getEffectiveComplianceLevel(GenClass genClass) { - return genClass.getGenModel().getComplianceLevel(); - } - - public List getChildCreationData(GenClass genClass) { - return genClass.getChildCreationData(); - } - - public GenFeature getCreateFeature(Object childCreationData) { - return ((ChildCreationData)childCreationData).createFeature; - } - - public GenFeature getDelegatedFeature(Object childCreationData) { - return ((ChildCreationData)childCreationData).delegatedFeature; - } - - public GenClassifier getCreateClassifier(Object childCreationData) { - return ((ChildCreationData)childCreationData).createClassifier; - } - - public String getDefaultOffsetCorrectionField(GenClass genClass) { - return genClass.getOffsetCorrectionField(null); - } - - public List getEVirtualIndexBitFields(GenClass genClass) { - return genClass.getEVirtualIndexBitFields(new ArrayList()); - } - - public List getAllEVirtualIndexBitFields(GenClass genClass) { - return genClass.getAllEVirtualIndexBitFields(new ArrayList()); - } - - public boolean implementsAnyEInverseAddGenFeatures(GenClass genClass) { - return genClass.implementsAny(genClass.getEInverseAddGenFeatures()); - } - - public boolean implementsAnyEInverseRemoveGenFeatures(GenClass genClass) { - return genClass.implementsAny(genClass.getEInverseRemoveGenFeatures()); - } - - public boolean implementsAnyEBasicRemoveFromContainerGenFeatures(GenClass genClass) { - return genClass.implementsAny(genClass.getEBasicRemoveFromContainerGenFeatures()); - } - - public boolean implementsAnyEGetGenFeatures(GenClass genClass) { - return genClass.implementsAny(genClass.getEGetGenFeatures()); - } - - public boolean implementsAnyESetGenFeatures(GenClass genClass) { - return genClass.implementsAny(genClass.getESetGenFeatures()); - } - - public boolean implementsAnyEUnsetGenFeatures(GenClass genClass) { - return genClass.implementsAny(genClass.getEUnsetGenFeatures()); - } - - public boolean implementsAnyEIsSetGenFeatures(GenClass genClass) { - return genClass.implementsAny(genClass.getEIsSetGenFeatures()); - } - - /** - * @param genClass - * @param extendedGenClass - * @return - */ - public boolean overridesExtendedGenOperations(GenClass genClass, GenClass extendedGenClass) { - return !genClass.getOverrideGenOperations(extendedGenClass.getImplementedGenOperations(), - genClass.getImplementedGenOperations()).isEmpty(); - } - - /** - * @param genClass - * @param extendedGenClass - * @return - */ - public boolean overridesGenOperations(GenClass genClass) { - return !genClass.getOverrideGenOperations(genClass.getExtendedGenOperations(), - genClass.getImplementedGenOperations()).isEmpty(); - } - - /** - * Remplace l'invocation de - * CodeGenUtil.upperName(genClass.getUniqueName(genOperation), genModel.getLocale()) . - * - * @param genClass - * @param genOperation - * @return - */ - public String getUniqueNameUppercase(GenClass genClass, GenOperation genOperation) { - return CodeGenUtil - .upperName(genClass.getUniqueName(genOperation), genClass.getGenModel().getLocale()); - } - - /** - * used to wrap icon creation. - * - * @see GenClassGeneratorAdapter#generateItemIcon(GenClass, Monitor) - * @param genClass - */ - public void generateItemIcon(GenClass genClass) { - if (genClass.isImage()) { - String inputFile = getClass().getResource("/templates/edit/Item.gif").toString(); - GIFEmitter gifEmitter = new GIFEmitter(inputFile); - byte[] contents = gifEmitter.generateGIF(genClass.getName(), null); - Path targetPath = new Path(genClass.getItemIconFileName()); - EMFCodegenPlugin.getDefault().createGIF(contents, targetPath); - } - } - - /** - * used to wrap icon creation. - * - * @see GenClassGeneratorAdapter#generateCreateChildIcons(GenClass, Monitor) - * @param genClass - */ - public void generateCreateChildIcons(GenClass genClass) { - GenModel genModel = genClass.getGenModel(); - if (genModel.isCreationCommands() && genModel.isCreationIcons()) { - for (GenFeature feature : genClass.getCreateChildFeaturesIncludingDelegation()) { - for (GenClass childClass : genClass.getChildrenClasses(feature)) { - String inputFile = getClass().getResource("/templates/edit/CreateChild.gif").toString(); - GIFEmitter gifEmitter = new GIFEmitter(inputFile); - byte[] contents = gifEmitter.generateGIF(genClass.getName(), childClass.getName()); - Path targetPath = new Path(genClass.getCreateChildIconFileName(feature, childClass)); - EMFCodegenPlugin.getDefault().createGIF(contents, targetPath); - } - } - } - } - - /** - * Wraps method addClassPseudoImports from EMF. - * - * @param genClass - * @return the pseudo import - */ - public String addClassPseudoImports(GenClass genClass) { - genClass.addClassPsuedoImports(); - return ""; - } - - /** - * Initialize the importManager used by EMF. - * - * @param genClass - * @param extendedGenClass - * @return - */ - public String initializeImportManager(GenClass genClass, boolean isInterface, boolean isImplementation) { - GenModel genModel = genClass.getGenModel(); - GenPackage genPackage = genClass.getGenPackage(); - String packageName = isInterface ? genPackage.getInterfacePackageName() : genPackage - .getClassPackageName(); - String className = isImplementation ? genClass.getClassName() : genClass.getInterfaceName(); - ImportManager importManager = new ImportManager(packageName, className); - genModel.setImportManager(importManager); - return ""; - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassifier.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassifier.mtl deleted file mode 100644 index bf3eecd3a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassifier.mtl +++ /dev/null @@ -1,138 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenClassifier('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public getAllGenConstraints(genClassifier : GenClassifier) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getAllGenConstraints()', Sequence{genClassifier}) /] - -[query public getClassifierAccessorName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getClassifierAccessorName()', Sequence{genClassifier}) /] - -[query public getClassifierID(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getClassifierID()', Sequence{genClassifier}) /] - -[query public getClassifierInstanceName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getClassifierInstanceName()', Sequence{genClassifier}) /] - -[query public getConstraintDelegate(genClassifier : GenClassifier, constraint : String) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getConstraintDelegate(java.lang.String)', Sequence{genClassifier, constraint}) /] - -[query public getConstraintExpression(genClassifier : GenClassifier, constraint : String, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getConstraintExpression(java.lang.String, java.lang.String)', Sequence{genClassifier, constraint, indentation}) /] - -[query public getConstraintImplementor(genClassifier : GenClassifier, constraint : String) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getConstraintImplementor(java.lang.String)', Sequence{genClassifier, constraint}) /] - -[query public getEcoreClassifier(genClassifier : GenClassifier) : EClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getEcoreClassifier()', Sequence{genClassifier}) /] - -[query public getFormattedName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getFormattedName()', Sequence{genClassifier}) /] - -[query public getGenConstraints(genClassifier : GenClassifier) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getGenConstraints()', Sequence{genClassifier}) /] - -[query public getGeneratedInstanceClassFlag(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getGeneratedInstanceClassFlag()', Sequence{genClassifier}) /] - -[query public getImportedBoundedWildcardInstanceClassName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getImportedBoundedWildcardInstanceClassName()', Sequence{genClassifier}) /] - -[query public getImportedInstanceClassName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getImportedInstanceClassName()', Sequence{genClassifier}) /] - -[query public getImportedMetaType(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getImportedMetaType()', Sequence{genClassifier}) /] - -[query public getQualifiedInterfaceName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getQualifiedInterfaceName()', Sequence{genClassifier}) /] - -[query public getImportedParameterizedInstanceClassName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getImportedParameterizedInstanceClassName()', Sequence{genClassifier}) /] - -[query public getImportedWildcardInstanceClassName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getImportedWildcardInstanceClassName()', Sequence{genClassifier}) /] - -[query public getMetaType(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getMetaType()', Sequence{genClassifier}) /] - -[query public getName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getName()', Sequence{genClassifier}) /] - -[query public getQualifiedClassifierAccessor(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getQualifiedClassifierAccessor()', Sequence{genClassifier}) /] - -[query public getRawImportedInstanceClassName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getRawImportedInstanceClassName()', Sequence{genClassifier}) /] - -[query public getRawInstanceClassName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getRawInstanceClassName()', Sequence{genClassifier}) /] - -[query public getSafeUncapName(genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getSafeUncapName()', Sequence{genClassifier}) /] - -[query public getValidationDelegate(genClassifier : GenClassifier, constraint : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getValidationDelegate(java.lang.String)', Sequence{genClassifier, constraint}) /] - -[query public hasConstraintExpression(genClassifier : GenClassifier, constraint : String) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'hasConstraintExpression(java.lang.String)', Sequence{genClassifier, constraint}) /] - -[query public hasOnlyDefaultConstraints(genClassifier : GenClassifier) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'hasOnlyDefaultConstraints()', Sequence{genClassifier}) /] - -[query public isUncheckedCast(genClassifier : GenClassifier) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'isUncheckedCast()', Sequence{genClassifier}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genClassifier : GenClassifier) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'canGenerate()', Sequence{genClassifier}) /] - -[query public canGenerateEdit(genClassifier : GenClassifier) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'canGenerateEdit()', Sequence{genClassifier}) /] - -[query public canGenerateEditor(genClassifier : GenClassifier) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'canGenerateEditor()', Sequence{genClassifier}) /] - -[query public canGenerateSchema(genClassifier : GenClassifier) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'canGenerateSchema()', Sequence{genClassifier}) /] - -[query public canGenerateTests(genClassifier : GenClassifier) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'canGenerateTests()', Sequence{genClassifier}) /] - -[query public capName(genClassifier : GenClassifier, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'capName(java.lang.String)', Sequence{genClassifier, name}) /] - -[query public getCopyright(genClassifier : GenClassifier, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getCopyright(java.lang.String)', Sequence{genClassifier, indentation}) /] - -[query public getDocumentation(genClassifier : GenClassifier, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getDocumentation(java.lang.String)', Sequence{genClassifier, indentation}) /] - -[query public getEcoreModelElement(genClassifier : GenClassifier) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getEcoreModelElement()', Sequence{genClassifier}) /] - -[query public getGenAnnotation(genClassifier : GenClassifier, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'getGenAnnotation(java.lang.String)', Sequence{genClassifier, source}) /] - -[query public hasCopyright(genClassifier : GenClassifier) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'hasCopyright()', Sequence{genClassifier}) /] - -[query public hasDocumentation(genClassifier : GenClassifier) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'hasDocumentation()', Sequence{genClassifier}) /] - -[query public reconcile(genClassifier : GenClassifier) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'reconcile()', Sequence{genClassifier}) /] - -[query public safeName(genClassifier : GenClassifier, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'safeName(java.lang.String)', Sequence{genClassifier, name}) /] - -[query public uncapName(genClassifier : GenClassifier, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'uncapName(java.lang.String)', Sequence{genClassifier, name}) /] - -[query public uncapPrefixedName(genClassifier : GenClassifier, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenClassifier', 'uncapPrefixedName(java.lang.String)', Sequence{genClassifier, input}) /] - - -[query public getIndexOfFirstConstraintDifferentFromNoCircular(genClassifier : GenClassifier) : Integer - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenClassifierWrapper', 'getIndexOfFirstConstraintDifferentFromNoCircular(org.eclipse.emf.codegen.ecore.genmodel.GenClassifier)', Sequence{genClassifier}) /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassifierWrapper.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassifierWrapper.java deleted file mode 100644 index dfbfe3ba9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenClassifierWrapper.java +++ /dev/null @@ -1,37 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services.wrappers; - -import java.util.List; - -import org.eclipse.emf.codegen.ecore.genmodel.GenClassifier; - -/** - * @author Stephane Bouchet - * @since 1.1 - */ -public class GenClassifierWrapper { - - public int getIndexOfFirstConstraintDifferentFromNoCircular(GenClassifier genClassifier) { - int index = 0; - List constraints = genClassifier.getAllGenConstraints(); - if (constraints != null) { - for (int i = 0; i < constraints.size(); i++) { - String constraint = constraints.get(i); - if (!"NoCircularContainment".equals(constraint)) { - index = ++i; // OCL indexes start at 1 instead of 0 - break; - } - } - } - return index; - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenDataType.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenDataType.mtl deleted file mode 100644 index 283244438..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenDataType.mtl +++ /dev/null @@ -1,236 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenDataType('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public getBaseType(genDataType : GenDataType) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getBaseType()', Sequence{genDataType}) /] - -[query public getEnumerationLiterals(genDataType : GenDataType) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getEnumerationLiterals()', Sequence{genDataType}) /] - -[query public getFractionDigits(genDataType : GenDataType) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getFractionDigits()', Sequence{genDataType}) /] - -[query public getImportedInstanceClassName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getImportedInstanceClassName()', Sequence{genDataType}) /] - -[query public getImportedParameterizedObjectInstanceClassName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getImportedParameterizedObjectInstanceClassName()', Sequence{genDataType}) /] - -[query public getImportedWildcardObjectInstanceClassName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getImportedWildcardObjectInstanceClassName()', Sequence{genDataType}) /] - -[query public getItemType(genDataType : GenDataType) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getItemType()', Sequence{genDataType}) /] - -[query public getLengthAccessorFunction(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getLengthAccessorFunction()', Sequence{genDataType}) /] - -[query public getMaxLength(genDataType : GenDataType) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getMaxLength()', Sequence{genDataType}) /] - -[query public getMaxLiteral(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getMaxLiteral()', Sequence{genDataType}) /] - -[query public getMemberTypes(genDataType : GenDataType) : Sequence(GenDataType) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getMemberTypes()', Sequence{genDataType}) /] - -[query public getMinLength(genDataType : GenDataType) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getMinLength()', Sequence{genDataType}) /] - -[query public getMinLiteral(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getMinLiteral()', Sequence{genDataType}) /] - -[query public getModelInfo(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getModelInfo()', Sequence{genDataType}) /] - -[query public getObjectInstanceClassName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getObjectInstanceClassName()', Sequence{genDataType}) /] - -[query public getObjectType(genDataType : GenDataType) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getObjectType()', Sequence{genDataType}) /] - -[query public getPrimitiveValueFunction(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getPrimitiveValueFunction()', Sequence{genDataType}) /] - -[query public getQualifiedInstanceClassName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getQualifiedInstanceClassName()', Sequence{genDataType}) /] - -[query public getSerializableFlag(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getSerializableFlag()', Sequence{genDataType}) /] - -[query public getStaticValue(genDataType : GenDataType, literal : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getStaticValue(java.lang.String)', Sequence{genDataType, literal}) /] - -[query public getStaticValue(genDataType : GenDataType, literal : String, includeCast : Boolean) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getStaticValue(java.lang.String, boolean)', Sequence{genDataType, literal, includeCast}) /] - -[query public getTotalDigits(genDataType : GenDataType) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getTotalDigits()', Sequence{genDataType}) /] - -[query public getWhiteSpace(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getWhiteSpace()', Sequence{genDataType}) /] - -[query public isArrayType(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'isArrayType()', Sequence{genDataType}) /] - -[query public isMaxInclusive(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'isMaxInclusive()', Sequence{genDataType}) /] - -[query public isMinInclusive(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'isMinInclusive()', Sequence{genDataType}) /] - -[query public isObjectType(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'isObjectType()', Sequence{genDataType}) /] - -[query public isPrimitiveType(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'isPrimitiveType()', Sequence{genDataType}) /] - -[query public isSerializable(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'isSerializable()', Sequence{genDataType}) /] - -[query public isXMLCalendar(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'isXMLCalendar()', Sequence{genDataType}) /] - -[query public isXMLDuration(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'isXMLDuration()', Sequence{genDataType}) /] - -[query public reconcile(genDataType : GenDataType, oldGenDataVersion : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenDataType)', Sequence{genDataType, oldGenDataVersion}) /] - -[comment - Override of services for super interface GenClassifier -/] -[query public getAllGenConstraints(genDataType : GenDataType) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getAllGenConstraints()', Sequence{genDataType}) /] - -[query public getClassifierAccessorName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getClassifierAccessorName()', Sequence{genDataType}) /] - -[query public getClassifierID(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getClassifierID()', Sequence{genDataType}) /] - -[query public getClassifierInstanceName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getClassifierInstanceName()', Sequence{genDataType}) /] - -[query public getConstraintDelegate(genDataType : GenDataType, constraint : String) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getConstraintDelegate(java.lang.String)', Sequence{genDataType, constraint}) /] - -[query public getConstraintExpression(genDataType : GenDataType, constraint : String, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getConstraintExpression(java.lang.String, java.lang.String)', Sequence{genDataType, constraint, indentation}) /] - -[query public getConstraintImplementor(genDataType : GenDataType, constraint : String) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getConstraintImplementor(java.lang.String)', Sequence{genDataType, constraint}) /] - -[query public getEcoreClassifier(genDataType : GenDataType) : EClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getEcoreClassifier()', Sequence{genDataType}) /] - -[query public getFormattedName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getFormattedName()', Sequence{genDataType}) /] - -[query public getGenConstraints(genDataType : GenDataType) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getGenConstraints()', Sequence{genDataType}) /] - -[query public getGeneratedInstanceClassFlag(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getGeneratedInstanceClassFlag()', Sequence{genDataType}) /] - -[query public getImportedBoundedWildcardInstanceClassName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getImportedBoundedWildcardInstanceClassName()', Sequence{genDataType}) /] - -[query public getImportedMetaType(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getImportedMetaType()', Sequence{genDataType}) /] - -[query public getImportedParameterizedInstanceClassName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getImportedParameterizedInstanceClassName()', Sequence{genDataType}) /] - -[query public getImportedWildcardInstanceClassName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getImportedWildcardInstanceClassName()', Sequence{genDataType}) /] - -[query public getMetaType(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getMetaType()', Sequence{genDataType}) /] - -[query public getName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getName()', Sequence{genDataType}) /] - -[query public getPatterns(genDataType : GenDataType) : Sequence(Sequence(String)) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getPatterns()', Sequence{genDataType}) /] - -[query public getQualifiedClassifierAccessor(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getQualifiedClassifierAccessor()', Sequence{genDataType}) /] - -[query public getRawImportedInstanceClassName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getRawImportedInstanceClassName()', Sequence{genDataType}) /] - -[query public getRawInstanceClassName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getRawInstanceClassName()', Sequence{genDataType}) /] - -[query public getSafeUncapName(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getSafeUncapName()', Sequence{genDataType}) /] - -[query public getValidationDelegate(genDataType : GenDataType, constraint : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getValidationDelegate(java.lang.String)', Sequence{genDataType, constraint}) /] - -[query public hasConstraintExpression(genDataType : GenDataType, constraint : String) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'hasConstraintExpression(java.lang.String)', Sequence{genDataType, constraint}) /] - -[query public hasOnlyDefaultConstraints(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'hasOnlyDefaultConstraints()', Sequence{genDataType}) /] - -[query public isUncheckedCast(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'isUncheckedCast()', Sequence{genDataType}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'canGenerate()', Sequence{genDataType}) /] - -[query public canGenerateEdit(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'canGenerateEdit()', Sequence{genDataType}) /] - -[query public canGenerateEditor(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'canGenerateEditor()', Sequence{genDataType}) /] - -[query public canGenerateSchema(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'canGenerateSchema()', Sequence{genDataType}) /] - -[query public canGenerateTests(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'canGenerateTests()', Sequence{genDataType}) /] - -[query public capName(genDataType : GenDataType, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'capName(java.lang.String)', Sequence{genDataType, name}) /] - -[query public getCopyright(genDataType : GenDataType, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getCopyright(java.lang.String)', Sequence{genDataType, indentation}) /] - -[query public getDocumentation(genDataType : GenDataType, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getDocumentation(java.lang.String)', Sequence{genDataType, indentation}) /] - -[query public getEcoreModelElement(genDataType : GenDataType) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getEcoreModelElement()', Sequence{genDataType}) /] - -[query public getGenAnnotation(genDataType : GenDataType, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'getGenAnnotation(java.lang.String)', Sequence{genDataType, source}) /] - -[query public hasCopyright(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'hasCopyright()', Sequence{genDataType}) /] - -[query public hasDocumentation(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'hasDocumentation()', Sequence{genDataType}) /] - -[query public reconcile(genDataType : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'reconcile()', Sequence{genDataType}) /] - -[query public safeName(genDataType : GenDataType, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'safeName(java.lang.String)', Sequence{genDataType, name}) /] - -[query public uncapName(genDataType : GenDataType, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'uncapName(java.lang.String)', Sequence{genDataType, name}) /] - -[query public uncapPrefixedName(genDataType : GenDataType, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenDataType', 'uncapPrefixedName(java.lang.String)', Sequence{genDataType, input}) /] - -[query public getStaticPositiveValue(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers', 'getStaticPositiveValue(org.eclipse.emf.codegen.ecore.genmodel.GenDataType)', Sequence{genDataType}) /] - -[query public getStaticNegativeValue(genDataType : GenDataType) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers', 'getStaticNegativeValue(org.eclipse.emf.codegen.ecore.genmodel.GenDataType)', Sequence{genDataType}) /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenDataTypeWrapper.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenDataTypeWrapper.java deleted file mode 100644 index f91c5da00..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenDataTypeWrapper.java +++ /dev/null @@ -1,35 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services.wrappers; - -import org.eclipse.emf.codegen.ecore.genmodel.GenDataType; - -/** - * @author Stephane Bouchet - * @since 1.1 - */ -public class GenDataTypeWrapper { - - protected String getValueForDigits(GenDataType genDataType) { - String value = "1"; - for (int digitCount = genDataType.getTotalDigits(); digitCount > 0; --digitCount) - value += "0"; - return value; - } - - public String getStaticPositiveValue(GenDataType genDataType) { - return genDataType.getStaticValue(getValueForDigits(genDataType)); - } - - public String getStaticNegativeValue(GenDataType genDataType) { - return genDataType.getStaticValue("-" + getValueForDigits(genDataType)); - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenEnum.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenEnum.mtl deleted file mode 100644 index 919378a0c..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenEnum.mtl +++ /dev/null @@ -1,254 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenEnum('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public getEnumLiteralID(genEnum : GenEnum, genEnumLiteral : GenEnumLiteral) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getEnumLiteralID(org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral)', Sequence{genEnum, genEnumLiteral}) /] - -[query public getEnumLiteralValue(genEnum : GenEnum, genEnumLiteral : GenEnumLiteral) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getEnumLiteralValue(org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral)', Sequence{genEnum, genEnumLiteral}) /] - -[query public getGenEnumLiteral(genEnum : GenEnum, literal : String) : GenEnumLiteral - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getGenEnumLiteral(java.lang.String)', Sequence{genEnum, literal}) /] - -[query public getImportedName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getImportedName()', Sequence{genEnum}) /] - -[query public getQualifiedName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getQualifiedName()', Sequence{genEnum}) /] - -[query public getUniqueValuedGenEnumLiterals(genEnum : GenEnum) : Sequence(GenEnumLiteral) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getUniqueValuedGenEnumLiterals()', Sequence{genEnum}) /] - -[query public reconcile(genEnum : GenEnum, oldGenEnumVersion : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenEnum)', Sequence{genEnum, oldGenEnumVersion}) /] - -[comment - Override of services for super interface GenDataType -/] -[query public getBaseType(genEnum : GenEnum) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getBaseType()', Sequence{genEnum}) /] - -[query public getEnumerationLiterals(genEnum : GenEnum) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getEnumerationLiterals()', Sequence{genEnum}) /] - -[query public getFractionDigits(genEnum : GenEnum) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getFractionDigits()', Sequence{genEnum}) /] - -[query public getImportedInstanceClassName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getImportedInstanceClassName()', Sequence{genEnum}) /] - -[query public getImportedParameterizedObjectInstanceClassName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getImportedParameterizedObjectInstanceClassName()', Sequence{genEnum}) /] - -[query public getImportedWildcardObjectInstanceClassName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getImportedWildcardObjectInstanceClassName()', Sequence{genEnum}) /] - -[query public getItemType(genEnum : GenEnum) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getItemType()', Sequence{genEnum}) /] - -[query public getLengthAccessorFunction(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getLengthAccessorFunction()', Sequence{genEnum}) /] - -[query public getMaxLength(genEnum : GenEnum) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getMaxLength()', Sequence{genEnum}) /] - -[query public getMaxLiteral(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getMaxLiteral()', Sequence{genEnum}) /] - -[query public getMemberTypes(genEnum : GenEnum) : Sequence(GenDataType) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getMemberTypes()', Sequence{genEnum}) /] - -[query public getMinLength(genEnum : GenEnum) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getMinLength()', Sequence{genEnum}) /] - -[query public getMinLiteral(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getMinLiteral()', Sequence{genEnum}) /] - -[query public getModelInfo(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getModelInfo()', Sequence{genEnum}) /] - -[query public getObjectInstanceClassName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getObjectInstanceClassName()', Sequence{genEnum}) /] - -[query public getObjectType(genEnum : GenEnum) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getObjectType()', Sequence{genEnum}) /] - -[query public getPrimitiveValueFunction(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getPrimitiveValueFunction()', Sequence{genEnum}) /] - -[query public getQualifiedInstanceClassName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getQualifiedInstanceClassName()', Sequence{genEnum}) /] - -[query public getSerializableFlag(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getSerializableFlag()', Sequence{genEnum}) /] - -[query public getStaticValue(genEnum : GenEnum, literal : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getStaticValue(java.lang.String)', Sequence{genEnum, literal}) /] - -[query public getStaticValue(genEnum : GenEnum, literal : String, includeCast : Boolean) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getStaticValue(java.lang.String, boolean)', Sequence{genEnum, literal, includeCast}) /] - -[query public getTotalDigits(genEnum : GenEnum) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getTotalDigits()', Sequence{genEnum}) /] - -[query public getWhiteSpace(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getWhiteSpace()', Sequence{genEnum}) /] - -[query public isArrayType(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'isArrayType()', Sequence{genEnum}) /] - -[query public isMaxInclusive(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'isMaxInclusive()', Sequence{genEnum}) /] - -[query public isMinInclusive(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'isMinInclusive()', Sequence{genEnum}) /] - -[query public isObjectType(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'isObjectType()', Sequence{genEnum}) /] - -[query public isPrimitiveType(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'isPrimitiveType()', Sequence{genEnum}) /] - -[query public isSerializable(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'isSerializable()', Sequence{genEnum}) /] - -[query public isXMLCalendar(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'isXMLCalendar()', Sequence{genEnum}) /] - -[query public isXMLDuration(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'isXMLDuration()', Sequence{genEnum}) /] - -[query public reconcile(genEnum : GenEnum, oldGenDataVersion : GenDataType) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenDataType)', Sequence{genEnum, oldGenDataVersion}) /] - -[comment - Override of services for super interface GenClassifier -/] -[query public getAllGenConstraints(genEnum : GenEnum) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getAllGenConstraints()', Sequence{genEnum}) /] - -[query public getClassifierAccessorName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getClassifierAccessorName()', Sequence{genEnum}) /] - -[query public getClassifierID(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getClassifierID()', Sequence{genEnum}) /] - -[query public getClassifierInstanceName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getClassifierInstanceName()', Sequence{genEnum}) /] - -[query public getConstraintDelegate(genEnum : GenEnum, constraint : String) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getConstraintDelegate(java.lang.String)', Sequence{genEnum, constraint}) /] - -[query public getConstraintExpression(genEnum : GenEnum, constraint : String, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getConstraintExpression(java.lang.String, java.lang.String)', Sequence{genEnum, constraint, indentation}) /] - -[query public getConstraintImplementor(genEnum : GenEnum, constraint : String) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getConstraintImplementor(java.lang.String)', Sequence{genEnum, constraint}) /] - -[query public getEcoreClassifier(genEnum : GenEnum) : EClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getEcoreClassifier()', Sequence{genEnum}) /] - -[query public getFormattedName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getFormattedName()', Sequence{genEnum}) /] - -[query public getGenConstraints(genEnum : GenEnum) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getGenConstraints()', Sequence{genEnum}) /] - -[query public getGeneratedInstanceClassFlag(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getGeneratedInstanceClassFlag()', Sequence{genEnum}) /] - -[query public getImportedBoundedWildcardInstanceClassName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getImportedBoundedWildcardInstanceClassName()', Sequence{genEnum}) /] - -[query public getImportedMetaType(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getImportedMetaType()', Sequence{genEnum}) /] - -[query public getImportedParameterizedInstanceClassName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getImportedParameterizedInstanceClassName()', Sequence{genEnum}) /] - -[query public getImportedWildcardInstanceClassName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getImportedWildcardInstanceClassName()', Sequence{genEnum}) /] - -[query public getMetaType(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getMetaType()', Sequence{genEnum}) /] - -[query public getName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getName()', Sequence{genEnum}) /] - -[query public getQualifiedClassifierAccessor(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getQualifiedClassifierAccessor()', Sequence{genEnum}) /] - -[query public getRawImportedInstanceClassName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getRawImportedInstanceClassName()', Sequence{genEnum}) /] - -[query public getRawInstanceClassName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getRawInstanceClassName()', Sequence{genEnum}) /] - -[query public getSafeUncapName(genEnum : GenEnum) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getSafeUncapName()', Sequence{genEnum}) /] - -[query public getValidationDelegate(genEnum : GenEnum, constraint : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getValidationDelegate(java.lang.String)', Sequence{genEnum, constraint}) /] - -[query public hasConstraintExpression(genEnum : GenEnum, constraint : String) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'hasConstraintExpression(java.lang.String)', Sequence{genEnum, constraint}) /] - -[query public hasOnlyDefaultConstraints(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'hasOnlyDefaultConstraints()', Sequence{genEnum}) /] - -[query public isUncheckedCast(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'isUncheckedCast()', Sequence{genEnum}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'canGenerate()', Sequence{genEnum}) /] - -[query public canGenerateEdit(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'canGenerateEdit()', Sequence{genEnum}) /] - -[query public canGenerateEditor(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'canGenerateEditor()', Sequence{genEnum}) /] - -[query public canGenerateSchema(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'canGenerateSchema()', Sequence{genEnum}) /] - -[query public canGenerateTests(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'canGenerateTests()', Sequence{genEnum}) /] - -[query public capName(genEnum : GenEnum, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'capName(java.lang.String)', Sequence{genEnum, name}) /] - -[query public getCopyright(genEnum : GenEnum, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getCopyright(java.lang.String)', Sequence{genEnum, indentation}) /] - -[query public getDocumentation(genEnum : GenEnum, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getDocumentation(java.lang.String)', Sequence{genEnum, indentation}) /] - -[query public getEcoreModelElement(genEnum : GenEnum) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getEcoreModelElement()', Sequence{genEnum}) /] - -[query public getGenAnnotation(genEnum : GenEnum, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getGenAnnotation(java.lang.String)', Sequence{genEnum, source}) /] - -[query public getGenModel(genEnum : GenEnum) : GenModel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'getGenModel()', Sequence{genEnum}) /] - -[query public hasCopyright(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'hasCopyright()', Sequence{genEnum}) /] - -[query public hasDocumentation(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'hasDocumentation()', Sequence{genEnum}) /] - -[query public reconcile(genEnum : GenEnum) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'reconcile()', Sequence{genEnum}) /] - -[query public safeName(genEnum : GenEnum, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'safeName(java.lang.String)', Sequence{genEnum, name}) /] - -[query public uncapName(genEnum : GenEnum, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'uncapName(java.lang.String)', Sequence{genEnum, name}) /] - -[query public uncapPrefixedName(genEnum : GenEnum, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnum', 'uncapPrefixedName(java.lang.String)', Sequence{genEnum, input}) /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenEnumLiteral.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenEnumLiteral.mtl deleted file mode 100644 index e3f028413..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenEnumLiteral.mtl +++ /dev/null @@ -1,89 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenEnumLiteral('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public getCapName(genEnumLiteral : GenEnumLiteral) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getCapName()', Sequence{genEnumLiteral}) /] - -[query public getEnumLiteralAccessorName(genEnumLiteral : GenEnumLiteral) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getEnumLiteralAccessorName()', Sequence{genEnumLiteral}) /] - -[query public getEnumLiteralID(genEnumLiteral : GenEnumLiteral) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getEnumLiteralID()', Sequence{genEnumLiteral}) /] - -[query public getEnumLiteralInstanceConstantName(genEnumLiteral : GenEnumLiteral) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getEnumLiteralInstanceConstantName()', Sequence{genEnumLiteral}) /] - -[query public getEnumLiteralValueConstantName(genEnumLiteral : GenEnumLiteral) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getEnumLiteralValueConstantName()', Sequence{genEnumLiteral}) /] - -[query public getFormattedName(genEnumLiteral : GenEnumLiteral) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getFormattedName()', Sequence{genEnumLiteral}) /] - -[query public getGenPackage(genEnumLiteral : GenEnumLiteral) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getGenPackage()', Sequence{genEnumLiteral}) /] - -[query public getLiteral(genEnumLiteral : GenEnumLiteral) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getLiteral()', Sequence{genEnumLiteral}) /] - -[query public getModelInfo(genEnumLiteral : GenEnumLiteral) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getModelInfo()', Sequence{genEnumLiteral}) /] - -[query public getName(genEnumLiteral : GenEnumLiteral) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getName()', Sequence{genEnumLiteral}) /] - -[query public getValue(genEnumLiteral : GenEnumLiteral) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getValue()', Sequence{genEnumLiteral}) /] - -[query public reconcile(genEnumLiteral : GenEnumLiteral, oldGenEnumLiteralVersion : GenEnumLiteral) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral)', Sequence{genEnumLiteral, oldGenEnumLiteralVersion}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genEnumLiteral : GenEnumLiteral) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'canGenerate()', Sequence{genEnumLiteral}) /] - -[query public canGenerateEdit(genEnumLiteral : GenEnumLiteral) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'canGenerateEdit()', Sequence{genEnumLiteral}) /] - -[query public canGenerateEditor(genEnumLiteral : GenEnumLiteral) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'canGenerateEditor()', Sequence{genEnumLiteral}) /] - -[query public canGenerateSchema(genEnumLiteral : GenEnumLiteral) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'canGenerateSchema()', Sequence{genEnumLiteral}) /] - -[query public canGenerateTests(genEnumLiteral : GenEnumLiteral) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'canGenerateTests()', Sequence{genEnumLiteral}) /] - -[query public capName(genEnumLiteral : GenEnumLiteral, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'capName(java.lang.String)', Sequence{genEnumLiteral, name}) /] - -[query public getCopyright(genEnumLiteral : GenEnumLiteral, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getCopyright(java.lang.String)', Sequence{genEnumLiteral, indentation}) /] - -[query public getDocumentation(genEnumLiteral : GenEnumLiteral, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getDocumentation(java.lang.String)', Sequence{genEnumLiteral, indentation}) /] - -[query public getEcoreModelElement(genEnumLiteral : GenEnumLiteral) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getEcoreModelElement()', Sequence{genEnumLiteral}) /] - -[query public getGenAnnotation(genEnumLiteral : GenEnumLiteral, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'getGenAnnotation(java.lang.String)', Sequence{genEnumLiteral, source}) /] - -[query public hasCopyright(genEnumLiteral : GenEnumLiteral) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'hasCopyright()', Sequence{genEnumLiteral}) /] - -[query public hasDocumentation(genEnumLiteral : GenEnumLiteral) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'hasDocumentation()', Sequence{genEnumLiteral}) /] - -[query public reconcile(genEnumLiteral : GenEnumLiteral) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'reconcile()', Sequence{genEnumLiteral}) /] - -[query public safeName(genEnumLiteral : GenEnumLiteral, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'safeName(java.lang.String)', Sequence{genEnumLiteral, name}) /] - -[query public uncapName(genEnumLiteral : GenEnumLiteral, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'uncapName(java.lang.String)', Sequence{genEnumLiteral, name}) /] - -[query public uncapPrefixedName(genEnumLiteral : GenEnumLiteral, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenEnumLiteral', 'uncapPrefixedName(java.lang.String)', Sequence{genEnumLiteral, input}) /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenFeature.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenFeature.mtl deleted file mode 100644 index 822322ec5..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenFeature.mtl +++ /dev/null @@ -1,487 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenFeature('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] - -[query public getAccessorName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getAccessorName()', Sequence{genFeature}) /] - -[query public getCapName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getCapName()', Sequence{genFeature}) /] - -[query public getChangeableFlag(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getChangeableFlag()', Sequence{genFeature}) /] - -[query public getContainerClass(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getContainerClass()', Sequence{genFeature}) /] - -[query public getContainmentFlag(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getContainmentFlag()', Sequence{genFeature}) /] - -[query public getCreateChildValueLiteral(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getCreateChildValueLiteral()', Sequence{genFeature}) /] - -[query public getDefaultValue(genFeature : GenFeature) : String - = let result : String = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getDefaultValue()', Sequence{genFeature}).oclAsType(String) in - if (result.oclIsInvalid() or result.oclIsUndefined()) then - 'null' - else - result - endif/] - -[query public getDelegateFeature(genFeature : GenFeature) : GenFeature - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getDelegateFeature()', Sequence{genFeature}) /] - -[query public getDelegatedFeatures(genFeature : GenFeature) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getDelegatedFeatures()', Sequence{genFeature}) /] - -[query public getDelegatedFeatures(genFeature : GenFeature, genModel : GenModel) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getDelegatedFeatures(org.eclipse.emf.codegen.ecore.genmodel.GenModel)', Sequence{genFeature, genModel}) /] - -[query public getDerivedFlag(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getDerivedFlag()', Sequence{genFeature}) /] - -[query public getEDefault(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getEDefault()', Sequence{genFeature}) /] - -[query public getFeatureAccessorName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getFeatureAccessorName()', Sequence{genFeature}) /] - -[query public getFeatureKind(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getFeatureKind()', Sequence{genFeature}) /] - -[query public getFormattedName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getFormattedName()', Sequence{genFeature}) /] - -[query public getGenPackage(genFeature : GenFeature) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getGenPackage()', Sequence{genFeature}) /] - -[query public getGetAccessor(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getGetAccessor()', Sequence{genFeature}) /] - -[query public getGetArrayAccessor(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getGetArrayAccessor()', Sequence{genFeature}) /] - -[query public getIDFlag(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getIDFlag()', Sequence{genFeature}) /] - -[query public getImportedMetaType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedMetaType()', Sequence{genFeature}) /] - -[query public getIsName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getIsName()', Sequence{genFeature}) /] - -[query public getKeys(genFeature : GenFeature) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getKeys()', Sequence{genFeature}) /] - -[query public getMetaType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getMetaType()', Sequence{genFeature}) /] - -[query public getModelInfo(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getModelInfo()', Sequence{genFeature}) /] - -[query public getName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getName()', Sequence{genFeature}) /] - -[query public getPropertyImageName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getPropertyImageName()', Sequence{genFeature}) /] - -[comment][query public getQualifiedFeatureAccessor(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getQualifiedFeatureAccessor()', Sequence{genFeature}) /][/comment] - -[query public getQualifiedFeatureAccessorName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getQualifiedFeatureAccessorName()', Sequence{genFeature}) /] - -[query public getQualifiedModelInfo(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getQualifiedModelInfo()', Sequence{genFeature}) /] - -[query public getResolveProxiesFlag(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getResolveProxiesFlag()', Sequence{genFeature}) /] - -[query public getReverse(genFeature : GenFeature) : GenFeature - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getReverse()', Sequence{genFeature}) /] - -[query public getSafeName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getSafeName()', Sequence{genFeature}) /] - -[query public getSafeNameAsEObject(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getSafeNameAsEObject()', Sequence{genFeature}) /] - -[query public getStaticDefaultValue(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getStaticDefaultValue()', Sequence{genFeature}) /] - -[query public getTransientFlag(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getTransientFlag()', Sequence{genFeature}) /] - -[query public getUncapName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getUncapName()', Sequence{genFeature}) /] - -[query public getUnsettableFlag(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getUnsettableFlag()', Sequence{genFeature}) /] - -[query public getUpperName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getUpperName()', Sequence{genFeature}) /] - -[query public getVolatileFlag(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getVolatileFlag()', Sequence{genFeature}) /] - -[query public hasDelegateFeature(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'hasDelegateFeature()', Sequence{genFeature}) /] - -[query public hasEDefault(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'hasEDefault()', Sequence{genFeature}) /] - -[query public hasSettingDelegate(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'hasSettingDelegate()', Sequence{genFeature}) /] - -[query public isBasicGet(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isBasicGet()', Sequence{genFeature}) /] - -[query public isBasicSet(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isBasicSet()', Sequence{genFeature}) /] - -[query public isBasicUnset(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isBasicUnset()', Sequence{genFeature}) /] - -[query public isBidirectional(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isBidirectional()', Sequence{genFeature}) /] - -[query public isChangeable(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isChangeable()', Sequence{genFeature}) /] - -[query public isContainer(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isContainer()', Sequence{genFeature}) /] - -[query public isContains(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isContains()', Sequence{genFeature}) /] - -[query public isDerived(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isDerived()', Sequence{genFeature}) /] - -[query public isESetField(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isESetField()', Sequence{genFeature}) /] - -[query public isESetFlag(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isESetFlag()', Sequence{genFeature}) /] - -[query public isEffectiveContains(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isEffectiveContains()', Sequence{genFeature}) /] - -[query public isField(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isField()', Sequence{genFeature}) /] - -[query public isFlag(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isFlag()', Sequence{genFeature}) /] - -[query public isGet(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isGet()', Sequence{genFeature}) /] - -[query public isID(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isID()', Sequence{genFeature}) /] - -[query public isIsSet(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isIsSet()', Sequence{genFeature}) /] - -[query public isProperty(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isProperty()', Sequence{genFeature}) /] - -[query public isReferenceType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isReferenceType()', Sequence{genFeature}) /] - -[query public isResolveProxies(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isResolveProxies()', Sequence{genFeature}) /] - -[query public isSet(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isSet()', Sequence{genFeature}) /] - -[query public isSetCreateChild(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isSetCreateChild()', Sequence{genFeature}) /] - -[query public isSetDefaultValue(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isSetDefaultValue()', Sequence{genFeature}) /] - -[query public isSuppressedGetVisibility(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isSuppressedGetVisibility()', Sequence{genFeature}) /] - -[query public isSuppressedIsSetVisibility(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isSuppressedIsSetVisibility()', Sequence{genFeature}) /] - -[query public isSuppressedSetVisibility(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isSuppressedSetVisibility()', Sequence{genFeature}) /] - -[query public isSuppressedUnsetVisibility(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isSuppressedUnsetVisibility()', Sequence{genFeature}) /] - -[query public isTested(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isTested()', Sequence{genFeature}) /] - -[query public isUnset(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isUnset()', Sequence{genFeature}) /] - -[query public isUnsettable(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isUnsettable()', Sequence{genFeature}) /] - -[query public isVolatile(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isVolatile()', Sequence{genFeature}) /] - -[query public reconcile(genFeature : GenFeature, oldGenFeatureVersion : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenFeature)', Sequence{genFeature, oldGenFeatureVersion}) /] - -[comment - Override of services for super interface GenTypedElement -/] -[query public getEObjectCast(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getEObjectCast()', Sequence{genFeature}) /] - -[query public getEcoreModelElement(genFeature : GenFeature) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getEcoreModelElement()', Sequence{genFeature}) /] - -[query public getEffectiveComplianceLevel(genFeature : GenFeature) : GenJDKLevel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getEffectiveComplianceLevel()', Sequence{genFeature}) /] - -[query public getGenClassType(genFeature : GenFeature) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getGenClassType()', Sequence{genFeature}) /] - -[query public getGenDataTypeType(genFeature : GenFeature) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getGenDataTypeType()', Sequence{genFeature}) /] - -[query public getGenEnumType(genFeature : GenFeature) : GenEnum - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getGenEnumType()', Sequence{genFeature}) /] - -[query public getImportedEffectiveFeatureMapWrapperClass(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedEffectiveFeatureMapWrapperClass()', Sequence{genFeature}) /] - -[query public getImportedEffectiveFeatureMapWrapperInternalInterface(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedEffectiveFeatureMapWrapperInternalInterface()', Sequence{genFeature}) /] - -[query public getImportedInternalType(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedInternalType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getImportedInternalType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedInternalType()', Sequence{genFeature}) /] - -[query public getImportedMapEntryType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedMapEntryType()', Sequence{genFeature}) /] - -[query public getImportedMapKeyType(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedMapKeyType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getImportedMapTemplateArguments(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedMapTemplateArguments(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getImportedMapValueType(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedMapValueType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getImportedType(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getImportedType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getImportedType()', Sequence{genFeature}) /] - -[query public getInternalTypeCast(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getInternalTypeCast()', Sequence{genFeature}) /] - -[query public getListItemType(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getListItemType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getListItemType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getListItemType()', Sequence{genFeature}) /] - -[query public getListTemplateArguments(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getListTemplateArguments(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getLowerBound(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getLowerBound()', Sequence{genFeature}) /] - -[query public getMapEntryTypeGenClass(genFeature : GenFeature) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getMapEntryTypeGenClass()', Sequence{genFeature}) /] - -[query public getMapGenClass(genFeature : GenFeature) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getMapGenClass()', Sequence{genFeature}) /] - -[query public getMapItemType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getMapItemType()', Sequence{genFeature}) /] - -[query public getNonEObjectInternalTypeCast(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getNonEObjectInternalTypeCast(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getNonEObjectInternalTypeCast(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getNonEObjectInternalTypeCast()', Sequence{genFeature}) /] - -[query public getObjectType(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getObjectType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getObjectType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getObjectType()', Sequence{genFeature}) /] - -[query public getOrderedFlag(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getOrderedFlag()', Sequence{genFeature}) /] - -[query public getPrimitiveValueFunction(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getPrimitiveValueFunction()', Sequence{genFeature}) /] - -[query public getQualifiedListItemType(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getQualifiedListItemType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getQualifiedListItemType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getQualifiedListItemType()', Sequence{genFeature}) /] - -[query public getRawBoundType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getRawBoundType()', Sequence{genFeature}) /] - -[query public getRawImportedBoundType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getRawImportedBoundType()', Sequence{genFeature}) /] - -[query public getRawImportedType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getRawImportedType()', Sequence{genFeature}) /] - -[query public getRawListItemType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getRawListItemType()', Sequence{genFeature}) /] - -[query public getRawType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getRawType()', Sequence{genFeature}) /] - -[query public getRawTypeCast(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getRawTypeCast()', Sequence{genFeature}) /] - -[query public getType(genFeature : GenFeature, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public getType(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getType()', Sequence{genFeature}) /] - -[query public getTypeClassifier(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getTypeClassifier()', Sequence{genFeature}) /] - -[query public getTypeClassifierAccessorName(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getTypeClassifierAccessorName()', Sequence{genFeature}) /] - -[query public getTypeGenClass(genFeature : GenFeature) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getTypeGenClass()', Sequence{genFeature}) /] - -[query public getTypeGenClassifier(genFeature : GenFeature) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getTypeGenClassifier()', Sequence{genFeature}) /] - -[query public getTypeGenDataType(genFeature : GenFeature) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getTypeGenDataType()', Sequence{genFeature}) /] - -[query public getTypeGenEnum(genFeature : GenFeature) : GenEnum - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getTypeGenEnum()', Sequence{genFeature}) /] - -[query public getTypeGenPackage(genFeature : GenFeature) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getTypeGenPackage()', Sequence{genFeature}) /] - -[query public getUniqueFlag(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getUniqueFlag()', Sequence{genFeature}) /] - -[query public getUpperBound(genFeature : GenFeature) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getUpperBound()', Sequence{genFeature}) /] - -[query public hasGenericType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'hasGenericType()', Sequence{genFeature}) /] - -[query public isBooleanType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isBooleanType()', Sequence{genFeature}) /] - -[query public isEffectiveSuppressEMFTypes(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isEffectiveSuppressEMFTypes()', Sequence{genFeature}) /] - -[query public isEnumBasedType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isEnumBasedType()', Sequence{genFeature}) /] - -[query public isEnumType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isEnumType()', Sequence{genFeature}) /] - -[query public isFeatureMapType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isFeatureMapType()', Sequence{genFeature}) /] - -[query public isFeatureMapWrapped(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isFeatureMapWrapped()', Sequence{genFeature}) /] - -[query public isListDataType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isListDataType()', Sequence{genFeature}) /] - -[query public isListType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isListType()', Sequence{genFeature}) /] - -[query public isMapType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isMapType()', Sequence{genFeature}) /] - -[query public isPrimitiveType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isPrimitiveType()', Sequence{genFeature}) /] - -[query public isStringBasedType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isStringBasedType()', Sequence{genFeature}) /] - -[query public isStringType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isStringType()', Sequence{genFeature}) /] - -[query public isUncheckedCast(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isUncheckedCast()', Sequence{genFeature}) /] - -[query public isUncheckedCast(genFeature : GenFeature, ctx : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isUncheckedCast(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genFeature, ctx}) /] - -[query public isUnique(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isUnique()', Sequence{genFeature}) /] - -[query public isWrappedFeatureMapType(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'isWrappedFeatureMapType()', Sequence{genFeature}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'canGenerate()', Sequence{genFeature}) /] - -[query public canGenerateEdit(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'canGenerateEdit()', Sequence{genFeature}) /] - -[query public canGenerateEditor(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'canGenerateEditor()', Sequence{genFeature}) /] - -[query public canGenerateSchema(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'canGenerateSchema()', Sequence{genFeature}) /] - -[query public canGenerateTests(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'canGenerateTests()', Sequence{genFeature}) /] - -[query public capName(genFeature : GenFeature, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'capName(java.lang.String)', Sequence{genFeature, name}) /] - -[query public getCopyright(genFeature : GenFeature, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getCopyright(java.lang.String)', Sequence{genFeature, indentation}) /] - -[query public getDocumentation(genFeature : GenFeature, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getDocumentation(java.lang.String)', Sequence{genFeature, indentation}) /] - -[query public getGenAnnotation(genFeature : GenFeature, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getGenAnnotation(java.lang.String)', Sequence{genFeature, source}) /] - -[query public getGenModel(genFeature : GenFeature) : GenModel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getGenModel()', Sequence{genFeature}) /] - -[query public hasDocumentation(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'hasDocumentation()', Sequence{genFeature}) /] - -[query public reconcile(genFeature : GenFeature) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'reconcile()', Sequence{genFeature}) /] - -[query public safeName(genFeature : GenFeature, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'safeName(java.lang.String)', Sequence{genFeature, name}) /] - -[query public uncapName(genFeature : GenFeature, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'uncapName(java.lang.String)', Sequence{genFeature, name}) /] - -[query public uncapPrefixedName(genFeature : GenFeature, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'uncapPrefixedName(java.lang.String)', Sequence{genFeature, input}) /] - - - - - - -[comment special handling for avoiding NPE due to importManager /] -[query public getQualifiedFeatureAccessor(genFeature : GenFeature) : String = - invoke('org.eclipse.emf.codegen.ecore.genmodel.GenFeature', 'getQualifiedFeatureAccessor()', Sequence{genFeature})/] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenModel.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenModel.mtl deleted file mode 100644 index 1b0b3cc40..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenModel.mtl +++ /dev/null @@ -1,464 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenModel('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public computeMissingUsedGenPackages(genModel : GenModel) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'computeMissingUsedGenPackages()', Sequence{genModel}) /] - -[query public findGenClassifier(genModel : GenModel, eClassifier : EClassifier) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'findGenClassifier(org.eclipse.emf.ecore.EClassifier)', Sequence{genModel, eClassifier}) /] - -[query public findGenPackage(genModel : GenModel, ePackage : EPackage) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'findGenPackage(org.eclipse.emf.ecore.EPackage)', Sequence{genModel, ePackage}) /] - -[query public getAllGenAndUsedGenPackagesWithClassifiers(genModel : GenModel) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getAllGenAndUsedGenPackagesWithClassifiers()', Sequence{genModel}) /] - -[query public getAllGenFeatures(genModel : GenModel) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getAllGenFeatures()', Sequence{genModel}) /] - -[query public getAllGenPackagesWithClassifiers(genModel : GenModel) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getAllGenPackagesWithClassifiers()', Sequence{genModel}) /] - -[query public getAllGenPackagesWithConcreteClasses(genModel : GenModel) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getAllGenPackagesWithConcreteClasses()', Sequence{genModel}) /] - -[query public getAllGenUsedAndStaticGenPackagesWithClassifiers(genModel : GenModel) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getAllGenUsedAndStaticGenPackagesWithClassifiers()', Sequence{genModel}) /] - -[query public getAllUsedGenPackagesWithClassifiers(genModel : GenModel) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getAllUsedGenPackagesWithClassifiers()', Sequence{genModel}) /] - -[query public getCopyrightFieldLiteral(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getCopyrightFieldLiteral()', Sequence{genModel}) /] - -[query public getDate(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getDate()', Sequence{genModel}) /] - -[query public getDriverNumber(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getDriverNumber()', Sequence{genModel}) /] - -[query public getEcoreGenPackage(genModel : GenModel) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEcoreGenPackage()', Sequence{genModel}) /] - -[query public getEditIconsDirectory(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditIconsDirectory()', Sequence{genModel}) /] - -[query public getEditModuleInherits(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditModuleInherits()', Sequence{genModel}) /] - -[query public getEditModuleSources(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditModuleSources()', Sequence{genModel}) /] - -[query public getEditPluginClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditPluginClassName()', Sequence{genModel}) /] - -[query public getEditPluginDirectory(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditPluginDirectory()', Sequence{genModel}) /] - -[query public getEditPluginPackageName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditPluginPackageName()', Sequence{genModel}) /] - -[query public getEditProjectDirectory(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditProjectDirectory()', Sequence{genModel}) /] - -[query public getEditQualifiedPackageNames(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditQualifiedPackageNames()', Sequence{genModel}) /] - -[query public getEditRequiredPlugins(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditRequiredPlugins()', Sequence{genModel}) /] - -[query public getEditResourceDelegateImportedPluginClassNames(genModel : GenModel, packageName : String, className : String) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditResourceDelegateImportedPluginClassNames()', Sequence{genModel}) /] - -[query public getEditSourceFolders(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditSourceFolders()', Sequence{genModel}) /] - -[query public getEditorAdvisorClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorAdvisorClassName()', Sequence{genModel}) /] - -[query public getEditorEntryPointClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorEntryPointClassName()', Sequence{genModel}) /] - -[query public getEditorHomePageName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorHomePageName()', Sequence{genModel}) /] - -[query public getEditorIconsDirectory(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorIconsDirectory()', Sequence{genModel}) /] - -[query public getEditorModuleInherits(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorModuleInherits()', Sequence{genModel}) /] - -[query public getEditorModuleSources(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorModuleSources()', Sequence{genModel}) /] - -[query public getEditorPluginClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorPluginClassName()', Sequence{genModel}) /] - -[query public getEditorPluginDirectory(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorPluginDirectory()', Sequence{genModel}) /] - -[query public getEditorPluginPackageName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorPluginPackageName()', Sequence{genModel}) /] - -[query public getEditorProjectDirectory(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorProjectDirectory()', Sequence{genModel}) /] - -[query public getEditorQualifiedPackageNames(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorQualifiedPackageNames()', Sequence{genModel}) /] - -[query public getEditorRequiredPlugins(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorRequiredPlugins()', Sequence{genModel}) /] - -[query public getEditorSourceFolders(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEditorSourceFolders()', Sequence{genModel}) /] - -[query public getEffectiveModelPluginVariables(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEffectiveModelPluginVariables()', Sequence{genModel}) /] - -[query public getFilteredAllGenFeatures(genModel : GenModel) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getFilteredAllGenFeatures()', Sequence{genModel}) /] - -[query public getImportedName(genModel : GenModel, qualifiedName : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getImportedName(java.lang.String)', Sequence{genModel, qualifiedName}) /] - -[query public getLineDelimiter(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getLineDelimiter()', Sequence{genModel}) /] - -[query public getMainGenModel(genModel : GenModel) : GenModel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getMainGenModel()', Sequence{genModel}) /] - -[query public getMergeRulesLocation(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getMergeRulesLocation()', Sequence{genModel}) /] - -[query public getMissingPackages(genModel : GenModel) : Sequence(EPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getMissingPackages()', Sequence{genModel}) /] - -[query public getModelModuleInherits(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getModelModuleInherits()', Sequence{genModel}) /] - -[query public getModelModuleSources(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getModelModuleSources()', Sequence{genModel}) /] - -[query public getModelPluginClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getModelPluginClassName()', Sequence{genModel}) /] - -[query public getModelPluginPackageName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getModelPluginPackageName()', Sequence{genModel}) /] - -[query public getModelProjectDirectory(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getModelProjectDirectory()', Sequence{genModel}) /] - -[query public getModelQualifiedPackageNames(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getModelQualifiedPackageNames()', Sequence{genModel}) /] - -[query public getModelRequiredPlugins(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getModelRequiredPlugins()', Sequence{genModel}) /] - -[query public getModelSourceFolders(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getModelSourceFolders()', Sequence{genModel}) /] - -[query public getNonNLS(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getNonNLS()', Sequence{genModel}) /] - -[query public getNonNLS(genModel : GenModel, i : Integer) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getNonNLS(int)', Sequence{genModel, i}) /] - -[query public getNonNLS(genModel : GenModel, s : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getNonNLS(java.lang.String)', Sequence{genModel, s}) /] - -[query public getNonNLS(genModel : GenModel, s : String, i : Integer) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getNonNLS(java.lang.String, int)', Sequence{genModel, s, i}) /] - -[query public getPropertyCategoryKey(genModel : GenModel, category : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getPropertyCategoryKey(java.lang.String)', Sequence{genModel, category}) /] - -[query public getPropertyCategories(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getPropertyCategories()', Sequence{genModel}) /] - -[query public getQualifiedEditModuleName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getQualifiedEditModuleName()', Sequence{genModel}) /] - -[query public getQualifiedEditPluginClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getQualifiedEditPluginClassName()', Sequence{genModel}) /] - -[query public getQualifiedEditorAdvisorClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getQualifiedEditorAdvisorClassName()', Sequence{genModel}) /] - -[query public getQualifiedEditorEntryPointClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getQualifiedEditorEntryPointClassName()', Sequence{genModel}) /] - -[query public getQualifiedEditorModuleName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getQualifiedEditorModuleName()', Sequence{genModel}) /] - -[query public getQualifiedEditorPluginClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getQualifiedEditorPluginClassName()', Sequence{genModel}) /] - -[query public getQualifiedModelModuleName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getQualifiedModelModuleName()', Sequence{genModel}) /] - -[query public getQualifiedModelPluginClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getQualifiedModelPluginClassName()', Sequence{genModel}) /] - -[query public getQualifiedTestSuiteClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getQualifiedTestSuiteClassName()', Sequence{genModel}) /] - -[query public getRelativeGenModelLocation(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getRelativeGenModelLocation()', Sequence{genModel}) /] - -[query public getRootImplementsInterfaceGenClass(genModel : GenModel) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getRootImplementsInterfaceGenClass()', Sequence{genModel}) /] - -[query public getStaticGenPackages(genModel : GenModel) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getStaticGenPackages()', Sequence{genModel}) /] - -[query public getTestSuiteClassName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getTestSuiteClassName()', Sequence{genModel}) /] - -[query public getTestSuitePackageName(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getTestSuitePackageName()', Sequence{genModel}) /] - -[query public getTestsProjectDirectory(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getTestsProjectDirectory()', Sequence{genModel}) /] - -[query public getTestsQualifiedPackageNames(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getTestsQualifiedPackageNames()', Sequence{genModel}) /] - -[query public getTestsRequiredPlugins(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getTestsRequiredPlugins()', Sequence{genModel}) /] - -[query public getTestsSourceFolders(genModel : GenModel) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getTestsSourceFolders()', Sequence{genModel}) /] - -[query public getXMLEncodingChoices(genModel : GenModel) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getXMLEncodingChoices()', Sequence{genModel}) /] - -[query public getXMLNamespaceGenPackage(genModel : GenModel) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getXMLNamespaceGenPackage()', Sequence{genModel}) /] - -[query public getXMLTypeGenPackage(genModel : GenModel) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getXMLTypeGenPackage()', Sequence{genModel}) /] - -[query public hasCopyrightField(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasCopyrightField()', Sequence{genModel}) /] - -[query public hasEditSupport(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasEditSupport()', Sequence{genModel}) /] - -[query public hasEditorSupport(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasEditorSupport()', Sequence{genModel}) /] - -[query public hasLocalGenModel(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasLocalGenModel()', Sequence{genModel}) /] - -[query public hasModelPluginClass(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasModelPluginClass()', Sequence{genModel}) /] - -[query public hasPluginSupport(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasPluginSupport()', Sequence{genModel}) /] - -[query public hasTestSuiteClass(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasTestSuiteClass()', Sequence{genModel}) /] - -[query public hasTestSupport(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasTestSupport()', Sequence{genModel}) /] - -[query public hasXMLDependency(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasXMLDependency()', Sequence{genModel}) /] - -[query public isBooleanFlagsEnabled(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isBooleanFlagsEnabled()', Sequence{genModel}) /] - -[query public isDynamicDelegation(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isDynamicDelegation()', Sequence{genModel}) /] - -[query public isSetEditDirectory(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isSetEditDirectory()', Sequence{genModel}) /] - -[query public isSetEditPluginClass(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isSetEditPluginClass()', Sequence{genModel}) /] - -[query public isSetEditorDirectory(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isSetEditorDirectory()', Sequence{genModel}) /] - -[query public isSetEditorPluginClass(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isSetEditorPluginClass()', Sequence{genModel}) /] - -[query public isSetRuntimeVersion(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isSetRuntimeVersion()', Sequence{genModel}) /] - -[query public isSetTestSuiteClass(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isSetTestSuiteClass()', Sequence{genModel}) /] - -[query public isSetTestsDirectory(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isSetTestsDirectory()', Sequence{genModel}) /] - -[query public isSuppressedAnnotation(genModel : GenModel, source : String) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isSuppressedAnnotation(java.lang.String)', Sequence{genModel, source}) /] - -[query public isValidateModel(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isValidateModel()', Sequence{genModel}) /] - -[query public isVirtualDelegation(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'isVirtualDelegation()', Sequence{genModel}) /] - -[query public needsRuntimeCompatibility(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'needsRuntimeCompatibility()', Sequence{genModel}) /] - -[query public reconcile(genModel : GenModel, oldGenModelVersion : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenModel)', Sequence{genModel, oldGenModelVersion}) /] - -[query public sameEditEditorProject(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'sameEditEditorProject()', Sequence{genModel}) /] - -[query public sameModelEditProject(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'sameModelEditProject()', Sequence{genModel}) /] - -[query public sameModelEditorProject(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'sameModelEditorProject()', Sequence{genModel}) /] - -[query public sameModelTestsProject(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'sameModelTestsProject()', Sequence{genModel}) /] - -[query public useClassOverrideAnnotation(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'useClassOverrideAnnotation()', Sequence{genModel}) /] - -[query public useGenerics(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'useGenerics()', Sequence{genModel}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'canGenerate()', Sequence{genModel}) /] - -[query public canGenerateEdit(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'canGenerateEdit()', Sequence{genModel}) /] - -[query public canGenerateEditor(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'canGenerateEditor()', Sequence{genModel}) /] - -[query public canGenerateSchema(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'canGenerateSchema()', Sequence{genModel}) /] - -[query public canGenerateTests(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'canGenerateTests()', Sequence{genModel}) /] - -[query public capName(genModel : GenModel, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'capName(String)', Sequence{genModel, name}) /] - -[query public getCopyright(genModel : GenModel, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getCopyright(java.lang.String)', Sequence{genModel, indentation}) /] - -[query public getDocumentation(genModel : GenModel, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getDocumentation(java.lang.String)', Sequence{genModel, indentation}) /] - -[query public getEcoreModelElement(genModel : GenModel) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getEcoreModelElement()', Sequence{genModel}) /] - -[query public getGenAnnotation(genModel : GenModel, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'getGenAnnotation(java.lang.String)', Sequence{genModel, source}) /] - -[query public hasCopyright(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasCopyright()', Sequence{genModel}) /] - -[query public hasDocumentation(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'hasDocumentation()', Sequence{genModel}) /] - -[query public reconcile(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'reconcile()', Sequence{genModel}) /] - -[query public safeName(genModel : GenModel, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'safeName(java.lang.String)', Sequence{genModel, name}) /] - -[query public uncapName(genModel : GenModel, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'uncapName(java.lang.String)', Sequence{genModel, name}) /] - -[query public uncapPrefixedName(genModel : GenModel, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'uncapPrefixedName(java.lang.String)', Sequence{genModel, input}) /] - - - - -[query public getLocale(genModel : GenModel) : OclAny - = invoke('org.eclipse.emf.codegen.ecore.genmodel.impl.GenModelImpl', 'getLocale()', Sequence{genModel}) /] - -[query public addImport(genModel : GenModel, qualifiedName : String) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'addImport(org.eclipse.emf.codegen.ecore.genmodel.GenModel, java.lang.String)', Sequence{genModel, qualifiedName}) /] - -[query public addPseudoImport(genModel : GenModel, qualifiedName : String) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'addPseudoImport(org.eclipse.emf.codegen.ecore.genmodel.GenModel, java.lang.String)', Sequence{genModel, qualifiedName}) /] - -[query public isJDK50(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'isJDK50(org.eclipse.emf.codegen.ecore.genmodel.GenModel)', Sequence{genModel}) /] - -[query public isEMF26(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'isEMF26(org.eclipse.emf.codegen.ecore.genmodel.GenModel)', Sequence{genModel}) /] - -[query public isEMF25(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'isEMF25(org.eclipse.emf.codegen.ecore.genmodel.GenModel)', Sequence{genModel}) /] - -[query public isEMF24(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'isEMF24(org.eclipse.emf.codegen.ecore.genmodel.GenModel)', Sequence{genModel}) /] - -[query public getIndentation(genModel : GenModel) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'getIndentation(org.eclipse.emf.codegen.ecore.genmodel.GenModel)', Sequence{genModel}) /] - -[comment ************ IMPORT MANAGER ****************************************** /] - -[** - * Returns the imports to insert at the relevant position in the output file. - * @param genModel The current GenModel. -*] -[query public genSortedImports(genModel : GenModel) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'genSortedImports(org.eclipse.emf.codegen.ecore.genmodel.GenModel)', Sequence{genModel}) /] - -[** - * Creates a new importManager and sets it on the current GenModel, to manage the imports - * of the class currently being generated. - * @param genModel The current GenModel. - * @param packageName Qualified package name of the class being generated. - * @param className Name of the class being generated. -*] -[query public initializeImportManager(genModel : GenModel, packageName : String, className : String) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'initializeImportManager(org.eclipse.emf.codegen.ecore.genmodel.GenModel, java.lang.String, java.lang.String)', Sequence{genModel, packageName, className}) /] - -[** - * Creates a new importManager and sets it on the current GenModel, to manage the imports - * of the class currently being generated. - * @param genModel The current GenModel. - * @param genPackage The current GenPackage. - * @param packageName Qualified package name of the class being generated. - * @param className Name of the class being generated. -*] -[query public initializeImportManager(genModel : GenModel, genPackage : GenPackage, packageName : String, className : String) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'initializeImportManager(org.eclipse.emf.codegen.ecore.genmodel.GenModel, org.eclipse.emf.codegen.ecore.genmodel.GenPackage, java.lang.String, java.lang.String)', Sequence{genModel, genPackage, packageName, className}) /] - -[query public toStringLiteral(genModel : GenModel, literal : String) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'toStringLiteral(org.eclipse.emf.codegen.ecore.genmodel.GenModel, java.lang.String)', Sequence{genModel, literal}) /] - -[query public getAllExtendedMetaDataAttributes(genModel : GenModel, eClass : EClass) : Sequence(EStructuralFeature) - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'getAllExtendedMetaDataAttributes(org.eclipse.emf.codegen.ecore.genmodel.GenModel, org.eclipse.emf.ecore.EClass)', Sequence{genModel, eClass}) /] - -[query public getAllExtendedMetaDataElements(genModel : GenModel, eClass : EClass) : Sequence(EStructuralFeature) - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'getAllExtendedMetaDataElements(org.eclipse.emf.codegen.ecore.genmodel.GenModel, org.eclipse.emf.ecore.EClass)', Sequence{genModel, eClass}) /] - -[query public getExtendedMetaDataName(genModel : GenModel, eFeature : EStructuralFeature) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'getExtendedMetaDataName(org.eclipse.emf.codegen.ecore.genmodel.GenModel, org.eclipse.emf.ecore.EStructuralFeature)', Sequence{genModel, eFeature}) /] - -[query public getExtendedMetaDataNamespace(genModel : GenModel, eFeature : EStructuralFeature) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'getExtendedMetaDataNamespace(org.eclipse.emf.codegen.ecore.genmodel.GenModel, org.eclipse.emf.ecore.EStructuralFeature)', Sequence{genModel, eFeature}) /] - -[query public getExtendedMetaDataNamespaceAsLiteral(genModel : GenModel, eFeature : EStructuralFeature) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'getExtendedMetaDataNamespaceAsLiteral(org.eclipse.emf.codegen.ecore.genmodel.GenModel, org.eclipse.emf.ecore.EStructuralFeature)', Sequence{genModel, eFeature}) /] - -[query public supportsComposition(genModel : GenModel) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'supportsComposition(org.eclipse.emf.codegen.ecore.genmodel.GenModel)', Sequence{genModel}) /] - -[query public formatConstraint(genModel : GenModel, constraint : String) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'formatConstraint(org.eclipse.emf.codegen.ecore.genmodel.GenModel, java.lang.String)', Sequence{genModel, constraint}) /] - -[query public upperNameConstraint(constraint : String) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenModelWrapper', 'upperNameConstraint(java.lang.String)', Sequence{constraint}) /] - -[template public addImportHere(genModel : GenModel, qualifiedName : String)] -[invoke('org.eclipse.emf.codegen.ecore.genmodel.GenModel', 'addPseudoImport(java.lang.String)', Sequence{genModel, qualifiedName}) /]import [qualifiedName/];[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenModelWrapper.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenModelWrapper.java deleted file mode 100644 index a637ffa6f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenModelWrapper.java +++ /dev/null @@ -1,220 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services.wrappers; - -import java.util.List; - -import org.eclipse.emf.codegen.ecore.genmodel.GenClass; -import org.eclipse.emf.codegen.ecore.genmodel.GenJDKLevel; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.codegen.ecore.genmodel.GenRuntimeVersion; -import org.eclipse.emf.codegen.ecore.genmodel.impl.Literals; -import org.eclipse.emf.codegen.util.CodeGenUtil; -import org.eclipse.emf.codegen.util.ImportManager; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; - -/** - * This class is used to implement some behaviors regarding GenModels that cannot be properly implemented with - * acceleo alone. - * - * @author Stephane Bouchet - */ -public class GenModelWrapper { - - /** - * Indicates whether the compliance level of a given GenModel is greater than or equal to JDK 1.5. - * - * @param genModel - * @return Returns true if and only if the compliance level set on the given GenModel is - * >= GenJDKLevel.JDK50. - */ - public boolean isJDK50(GenModel genModel) { - if (genModel != null && genModel.getComplianceLevel() != null) - return genModel.getComplianceLevel().getValue() >= GenJDKLevel.JDK50; - return false; - } - - /** - * Indicates whether the runtime version of a given GenModel is greater than or equal to EMF 2.6. - * - * @param genModel - * @return Returns true if and only if the runtime version set on the given GenModel is - * >= GenRuntimeVersion.EMF26_VALUE. - */ - public boolean isEMF26(GenModel genModel) { - if (genModel != null && genModel.getRuntimeVersion() != null) - return genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF26_VALUE; - return false; - } - - /** - * Indicates whether the runtime version of a given GenModel is greater than or equal to EMF 2.5. - * - * @param genModel - * @return Returns true if and only if the runtime version set on the given GenModel is - * >= GenRuntimeVersion.EMF26_VALUE. - * @since 1.1 - */ - public boolean isEMF25(GenModel genModel) { - if (genModel != null && genModel.getRuntimeVersion() != null) - return genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF25_VALUE; - return false; - } - - /** - * Indicates whether the runtime version of a given GenModel is greater than or equal to EMF 2.4. - * - * @param genModel - * @return Returns true if and only if the runtime version set on the given GenModel is - * >= GenRuntimeVersion.EMF26_VALUE. - * @since 1.1 - */ - public boolean isEMF24(GenModel genModel) { - if (genModel != null && genModel.getRuntimeVersion() != null) - return genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF24_VALUE; - return false; - } - - public String getIndentation(GenModel genModel) { - return genModel.getIndentation(new StringBuffer()); - } - - public String genSortedImports(GenModel genModel) { - return genModel.getImportManager().computeSortedImports(); - } - - public String genSortedImports(GenClass genClass) { - return genClass.getGenModel().getImportManager().computeSortedImports(); - } - - /** - * Initializing EMF importManager. - */ - public void initializeImportManager(GenModel genModel, String packageName, String className) { - createImportManagerAndSetItTo(genModel, packageName, className); - } - - private ImportManager createImportManagerAndSetItTo(GenModel genModel, String packageName, - String className) { - ImportManager importManager = new ImportManager(packageName, className); - genModel.setImportManager(importManager); - return importManager; - } - - /** - * Initializing EMF importManager for a given package, managing java.lang conflicts. Classes whose names - * conflict with java.lang classes will be qualified explicitly and not imported. - * - * @since 1.1 - */ - public void initializeImportManager(GenModel genModel, GenPackage genPackage, String packageName, - String className) { - ImportManager importManager = createImportManagerAndSetItTo(genModel, packageName, className); - importManager.addJavaLangImports(genPackage.getJavaLangConflicts()); - } - - public void addImport(GenModel genModel, String qualifiedName) { - genModel.addImport(qualifiedName); - } - - public void addPseudoImport(GenModel genModel, String qualifiedName) { - genModel.addPseudoImport(qualifiedName); - } - - /** - * Wraps method "toStringLiteral" of utility class "Literals". - * - * @param genModel - * @param literal - */ - public String toStringLiteral(GenModel genModel, String literal) { - return Literals.toStringLiteral(literal, genModel); - } - - /** - * @since 1.1 - */ - public List getAllExtendedMetaDataAttributes(GenModel genModel, EClass eClass) { - return genModel.getExtendedMetaData().getAllAttributes(eClass); - } - - /** - * @since 1.1 - */ - public List getAllExtendedMetaDataElements(GenModel genModel, EClass eClass) { - return genModel.getExtendedMetaData().getAllElements(eClass); - } - - /** - * @since 1.1 - */ - public String getExtendedMetaDataName(GenModel genModel, EStructuralFeature eFeature) { - return genModel.getExtendedMetaData().getName(eFeature); - } - - /** - * @since 1.1 - */ - public String getExtendedMetaDataNamespace(GenModel genModel, EStructuralFeature eFeature) { - return genModel.getExtendedMetaData().getNamespace(eFeature); - } - - /** - * @since 1.1 - */ - public String getExtendedMetaDataNamespaceAsLiteral(GenModel genModel, EStructuralFeature eFeature) { - String result = Literals.toStringLiteral(genModel.getExtendedMetaData().getNamespace(eFeature), - genModel); - if ("null".equals(result)) { - result = "\"\""; - } - return result; - } - - /** - * @since 1.1 - */ - public boolean supportsComposition(GenModel genModel) { - return genModel.getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF27_VALUE; - } - - /** - * Replaces the invocation of - * CodeGenUtil.format(constraint, '_', null, false, false).toUpperCase(genClassifier.getGenModel().getLocale()) - * - * @param genModel - * The current GenModel, the Locale of which will be used. - * @param constraint - * The constraint to format. - * @return Returns the formatted constraint suitable for output in EMF code. - * @since 1.1 - */ - public String formatConstraint(GenModel genModel, String constraint) { - if (constraint != null) { - return CodeGenUtil.format(constraint, '_', null, false, false).toUpperCase(genModel.getLocale()); - } - return ""; - } - - /** - * Replaces the invocation of CodeGenUtil.upperName(constraint) - * - * @param constraint - * The constraint to format. - * @return Returns the formatted constraint suitable for output in EMF code. - * @since 1.1 - */ - public String upperNameConstraint(String constraint) { - return CodeGenUtil.upperName(constraint); - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenOperation.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenOperation.mtl deleted file mode 100644 index 1c8c9b538..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenOperation.mtl +++ /dev/null @@ -1,373 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenOperation('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public getBody(genOperation : GenOperation, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getBody(java.lang.String)', Sequence{genOperation, indentation}) /] - -[query public getCapName(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getCapName()', Sequence{genOperation}) /] - -[query public getFormattedName(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getFormattedName()', Sequence{genOperation}) /] - -[query public getGenExceptions(genOperation : GenOperation) : Sequence(GenClassifier) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getGenExceptions()', Sequence{genOperation}) /] - -[query public getGenPackage(genOperation : GenOperation) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getGenPackage()', Sequence{genOperation}) /] - -[query public getImportedMetaType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedMetaType()', Sequence{genOperation}) /] - -[query public getImportedReturnType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedReturnType()', Sequence{genOperation}) /] - -[query public getInvariantExpression(genOperation : GenOperation, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getInvariantExpression(java.lang.String)', Sequence{genOperation, indentation}) /] - -[query public getModelInfo(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getModelInfo()', Sequence{genOperation}) /] - -[query public getName(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getName()', Sequence{genOperation}) /] - -[query public getObjectReturnType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getObjectReturnType()', Sequence{genOperation}) /] - -[query public getOperationAccessorName(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getOperationAccessorName()', Sequence{genOperation}) /] - -[query public getParameterNames(genOperation : GenOperation, separator : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getParameterNames(java.lang.String)', Sequence{genOperation, separator}) /] - -[query public getParameterTypes(genOperation : GenOperation, separator : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getParameterTypes(java.lang.String)', Sequence{genOperation, separator}) /] - -[query public getParameterTypes(genOperation : GenOperation, separator : String, qualified : Boolean) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getParameterTypes(java.lang.String, boolean)', Sequence{genOperation, separator, qualified}) /] - -[query public getParameters(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getParameters(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getParameters(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getParameters()', Sequence{genOperation}) /] - -[query public getParametersArray(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getParametersArray(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getQualifiedOperationAccessor(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getQualifiedOperationAccessor()', Sequence{genOperation}) /] - -[query public getQualifiedOperationAccessorName(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getQualifiedOperationAccessorName()', Sequence{genOperation}) /] - -[query public getReturnType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getReturnType()', Sequence{genOperation}) /] - -[query public getReturnTypeClassifier(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getReturnTypeClassifier()', Sequence{genOperation}) /] - -[query public getReturnTypeGenPackage(genOperation : GenOperation) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getReturnTypeGenPackage()', Sequence{genOperation}) /] - -[query public getThrows(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getThrows(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getThrows(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getThrows()', Sequence{genOperation}) /] - -[query public getTypeParameters(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getTypeParameters(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getValidationDelegate(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getValidationDelegate()', Sequence{genOperation}) /] - -[query public hasBody(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'hasBody()', Sequence{genOperation}) /] - -[query public hasGenericExceptions(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'hasGenericExceptions()', Sequence{genOperation}) /] - -[query public hasInvariantExpression(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'hasInvariantExpression()', Sequence{genOperation}) /] - -[query public hasInvocationDelegate(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'hasInvocationDelegate()', Sequence{genOperation}) /] - -[query public hasParameterDocumentation(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'hasParameterDocumentation()', Sequence{genOperation}) /] - -[query public isInvariant(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isInvariant()', Sequence{genOperation}) /] - -[query public isOverrideOf(genOperation : GenOperation, ctx : GenClass, genOperation2 : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isOverrideOf(org.eclipse.emf.codegen.ecore.genmodel.GenClass, org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genOperation, ctx, genOperation2}) /] - -[query public isOverrideOf(genOperation : GenOperation, genOperation2 : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isOverrideOf(org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genOperation, genOperation2}) /] - -[query public isPrimitiveReturnType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isPrimitiveReturnType()', Sequence{genOperation}) /] - -[query public isSuppressedVisibility(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isSuppressedVisibility()', Sequence{genOperation}) /] - -[query public isVoid(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isVoid()', Sequence{genOperation}) /] - -[query public reconcile(genOperation : GenOperation, oldGenOperationVersion : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genOperation, oldGenOperationVersion}) /] - -[comment - Override of services for super interface GenTypedElement -/] -[query public getEObjectCast(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getEObjectCast()', Sequence{genOperation}) /] - -[query public getEcoreModelElement(genOperation : GenOperation) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getEcoreModelElement()', Sequence{genOperation}) /] - -[query public getEffectiveComplianceLevel(genOperation : GenOperation) : GenJDKLevel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getEffectiveComplianceLevel()', Sequence{genOperation}) /] - -[query public getGenClassType(genOperation : GenOperation) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getGenClassType()', Sequence{genOperation}) /] - -[query public getGenDataTypeType(genOperation : GenOperation) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getGenDataTypeType()', Sequence{genOperation}) /] - -[query public getGenEnumType(genOperation : GenOperation) : GenEnum - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getGenEnumType()', Sequence{genOperation}) /] - -[query public getImportedEffectiveFeatureMapWrapperClass(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedEffectiveFeatureMapWrapperClass()', Sequence{genOperation}) /] - -[query public getImportedEffectiveFeatureMapWrapperInternalInterface(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedEffectiveFeatureMapWrapperInternalInterface()', Sequence{genOperation}) /] - -[query public getImportedInternalType(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedInternalType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getImportedInternalType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedInternalType()', Sequence{genOperation}) /] - -[query public getImportedMapEntryType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedMapEntryType()', Sequence{genOperation}) /] - -[query public getImportedMapKeyType(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedMapKeyType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getImportedMapTemplateArguments(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedMapTemplateArguments(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getImportedMapValueType(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedMapValueType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getImportedType(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getImportedType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getImportedType()', Sequence{genOperation}) /] - -[query public getInternalTypeCast(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getInternalTypeCast()', Sequence{genOperation}) /] - -[query public getListItemType(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getListItemType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getListItemType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getListItemType()', Sequence{genOperation}) /] - -[query public getListTemplateArguments(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getListTemplateArguments(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getLowerBound(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getLowerBound()', Sequence{genOperation}) /] - -[query public getMapEntryTypeGenClass(genOperation : GenOperation) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getMapEntryTypeGenClass()', Sequence{genOperation}) /] - -[query public getMapGenClass(genOperation : GenOperation) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getMapGenClass()', Sequence{genOperation}) /] - -[query public getMapItemType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getMapItemType()', Sequence{genOperation}) /] - -[query public getNonEObjectInternalTypeCast(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getNonEObjectInternalTypeCast(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getNonEObjectInternalTypeCast(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getNonEObjectInternalTypeCast()', Sequence{genOperation}) /] - -[query public getObjectType(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getObjectType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getObjectType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getObjectType()', Sequence{genOperation}) /] - -[query public getOrderedFlag(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getOrderedFlag()', Sequence{genOperation}) /] - -[query public getPrimitiveValueFunction(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getPrimitiveValueFunction()', Sequence{genOperation}) /] - -[query public getQualifiedListItemType(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getQualifiedListItemType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getQualifiedListItemType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getQualifiedListItemType()', Sequence{genOperation}) /] - -[query public getRawBoundType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getRawBoundType()', Sequence{genOperation}) /] - -[query public getRawImportedBoundType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getRawImportedBoundType()', Sequence{genOperation}) /] - -[query public getRawImportedType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getRawImportedType()', Sequence{genOperation}) /] - -[query public getRawListItemType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getRawListItemType()', Sequence{genOperation}) /] - -[query public getRawType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getRawType()', Sequence{genOperation}) /] - -[query public getRawTypeCast(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getRawTypeCast()', Sequence{genOperation}) /] - -[query public getType(genOperation : GenOperation, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public getType(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getType()', Sequence{genOperation}) /] - -[query public getTypeClassifier(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getTypeClassifier()', Sequence{genOperation}) /] - -[query public getTypeClassifierAccessorName(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getTypeClassifierAccessorName()', Sequence{genOperation}) /] - -[query public getTypeGenClass(genOperation : GenOperation) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getTypeGenClass()', Sequence{genOperation}) /] - -[query public getTypeGenClassifier(genOperation : GenOperation) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getTypeGenClassifier()', Sequence{genOperation}) /] - -[query public getTypeGenDataType(genOperation : GenOperation) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getTypeGenDataType()', Sequence{genOperation}) /] - -[query public getTypeGenEnum(genOperation : GenOperation) : GenEnum - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getTypeGenEnum()', Sequence{genOperation}) /] - -[query public getTypeGenPackage(genOperation : GenOperation) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getTypeGenPackage()', Sequence{genOperation}) /] - -[query public getUniqueFlag(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getUniqueFlag()', Sequence{genOperation}) /] - -[query public getUpperBound(genOperation : GenOperation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getUpperBound()', Sequence{genOperation}) /] - -[query public hasGenericType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'hasGenericType()', Sequence{genOperation}) /] - -[query public isBooleanType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isBooleanType()', Sequence{genOperation}) /] - -[query public isEffectiveSuppressEMFTypes(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isEffectiveSuppressEMFTypes()', Sequence{genOperation}) /] - -[query public isEnumBasedType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isEnumBasedType()', Sequence{genOperation}) /] - -[query public isEnumType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isEnumType()', Sequence{genOperation}) /] - -[query public isFeatureMapType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isFeatureMapType()', Sequence{genOperation}) /] - -[query public isFeatureMapWrapped(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isFeatureMapWrapped()', Sequence{genOperation}) /] - -[query public isListDataType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isListDataType()', Sequence{genOperation}) /] - -[query public isListType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isListType()', Sequence{genOperation}) /] - -[query public isMapType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isMapType()', Sequence{genOperation}) /] - -[query public isPrimitiveType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isPrimitiveType()', Sequence{genOperation}) /] - -[query public isStringBasedType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isStringBasedType()', Sequence{genOperation}) /] - -[query public isStringType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isStringType()', Sequence{genOperation}) /] - -[query public isUncheckedCast(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isUncheckedCast()', Sequence{genOperation}) /] - -[query public isUncheckedCast(genOperation : GenOperation, ctx : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isUncheckedCast(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genOperation, ctx}) /] - -[query public isUnique(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isUnique()', Sequence{genOperation}) /] - -[query public isWrappedFeatureMapType(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'isWrappedFeatureMapType()', Sequence{genOperation}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'canGenerate()', Sequence{genOperation}) /] - -[query public canGenerateEdit(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'canGenerateEdit()', Sequence{genOperation}) /] - -[query public canGenerateEditor(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'canGenerateEditor()', Sequence{genOperation}) /] - -[query public canGenerateSchema(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'canGenerateSchema()', Sequence{genOperation}) /] - -[query public canGenerateTests(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'canGenerateTests()', Sequence{genOperation}) /] - -[query public capName(genOperation : GenOperation, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'capName(java.lang.String)', Sequence{genOperation, name}) /] - -[query public getCopyright(genOperation : GenOperation, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getCopyright(java.lang.String)', Sequence{genOperation, indentation}) /] - -[query public getDocumentation(genOperation : GenOperation, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getDocumentation(java.lang.String)', Sequence{genOperation, indentation}) /] - -[query public getGenAnnotation(genOperation : GenOperation, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'getGenAnnotation(java.lang.String)', Sequence{genOperation, source}) /] - -[query public hasCopyright(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'hasCopyright()', Sequence{genOperation}) /] - -[query public hasDocumentation(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'hasDocumentation()', Sequence{genOperation}) /] - -[query public reconcile(genOperation : GenOperation) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'reconcile()', Sequence{genOperation}) /] - -[query public safeName(genOperation : GenOperation, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'safeName(java.lang.String)', Sequence{genOperation, name}) /] - -[query public uncapName(genOperation : GenOperation, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'uncapName(java.lang.String)', Sequence{genOperation, name}) /] - -[query public uncapPrefixedName(genOperation : GenOperation, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenOperation', 'uncapPrefixedName(java.lang.String)', Sequence{genOperation, input}) /] - -[comment We use a template in order to prevent acceleo cache from calling the java method each time /] -[template public prefix(genOperation : GenOperation)] -[if (genOperation.hasGenericType() or genOperation.genParameters->notEmpty() or genOperation.getGenExceptions()->notEmpty() or genOperation.genTypeParameters->notEmpty())] -[invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'prefix(org.eclipse.emf.codegen.ecore.genmodel.GenOperation)', Sequence{genOperation})/][/if][/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenOperationWrapper.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenOperationWrapper.java deleted file mode 100644 index 36bab08d0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenOperationWrapper.java +++ /dev/null @@ -1,34 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services.wrappers; - -import org.eclipse.emf.codegen.ecore.genmodel.GenOperation; - -/** - * @author Stephane Bouchet - * @since 1.1 - */ -public class GenOperationWrapper { - - private boolean firstPrefix = true; - - public String prefix(GenOperation genOperation) { - if (firstPrefix) { - firstPrefix = false; - return genOperation.getGenModel().getImportedName("org.eclipse.emf.ecore.EOperation") + " op = "; - } - return "op = "; - } - - public void resetGenOperationPrefix() { - firstPrefix = true; - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenPackage.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenPackage.mtl deleted file mode 100644 index 9b92d6980..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenPackage.mtl +++ /dev/null @@ -1,575 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenPackage('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] - -[query public getActionBarContributorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getActionBarContributorClassName()', Sequence{genPackage}) /] - -[query public getAdapterDelegatePackages(genPackage : GenPackage) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAdapterDelegatePackages()', Sequence{genPackage}) /] - -[query public getAdapterDelegateSuperClasses(genPackage : GenPackage) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAdapterDelegateSuperClasses()', Sequence{genPackage}) /] - -[query public getAdapterFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAdapterFactoryClassName()', Sequence{genPackage}) /] - -[query public getAdapterFactoryDelegateName(genPackage : GenPackage, genDelegate : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAdapterFactoryDelegateName(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage, genDelegate}) /] - -[query public getAllAnnotations(genPackage : GenPackage) : Sequence(EAnnotation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAllAnnotations()', Sequence{genPackage}) /] - -[query public getAllGenDataTypes(genPackage : GenPackage) : Sequence(GenDataType) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAllGenDataTypes()', Sequence{genPackage}) /] - -[query public getAllGenFeatures(genPackage : GenPackage) : Sequence(GenFeature) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAllGenFeatures()', Sequence{genPackage}) /] - -[query public getAllNestedAnnotations(genPackage : GenPackage, eAnnotation : EAnnotation) : Sequence(EAnnotation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAllNestedAnnotations(org.eclipse.emf.ecore.EAnnotation)', Sequence{genPackage, eAnnotation}) /] - -[query public getAllSwitchGenClasses(genPackage : GenPackage) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAllSwitchGenClasses()', Sequence{genPackage}) /] - -[query public getAllValidatorBaseGenPackages(genPackage : GenPackage) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAllValidatorBaseGenPackages()', Sequence{genPackage}) /] - -[query public getAnnotatedModelElementAccessor(genPackage : GenPackage, eAnnotation : EAnnotation) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAnnotatedModelElementAccessor(org.eclipse.emf.ecore.EAnnotation)', Sequence{genPackage, eAnnotation}) /] - -[query public getAnnotationSourceIdentifier(genPackage : GenPackage, annotationSource : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAnnotationSourceIdentifier(java.lang.String)', Sequence{genPackage, annotationSource}) /] - -[query public getAnnotationSources(genPackage : GenPackage) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getAnnotationSources()', Sequence{genPackage}) /] - -[query public getBasicPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getBasicPackageName()', Sequence{genPackage}) /] - -[query public getChildCreationExtenderName(genPackage : GenPackage, genPackage2 : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getChildCreationExtenderName(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage, genPackage2}) /] - -[query public getClassPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getClassPackageName()', Sequence{genPackage}) /] - -[query public getClassUniqueName(genPackage : GenPackage, genClass : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getClassUniqueName(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genPackage, genClass}) /] - -[query public getClassifierID(genPackage : GenPackage, genClassifier : GenClassifier) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getClassifierID(org.eclipse.emf.codegen.ecore.genmodel.GenClassifier)', Sequence{genPackage, genClassifier}) /] - -[query public getClassifierValue(genPackage : GenPackage, genClassifier : GenClassifier) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getClassifierValue(org.eclipse.emf.codegen.ecore.genmodel.GenClassifier)', Sequence{genPackage, genClassifier}) /] - -[query public getDocumentRoot(genPackage : GenPackage) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getDocumentRoot()', Sequence{genPackage}) /] - -[query public getEditPluginClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getEditPluginClassName()', Sequence{genPackage}) /] - -[query public getEditorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getEditorClassName()', Sequence{genPackage}) /] - -[query public getEditorPluginClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getEditorPluginClassName()', Sequence{genPackage}) /] - -[query public getExampleClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getExampleClassName()', Sequence{genPackage}) /] - -[comment][query public getExtendedChildCreationData(genPackage : GenPackage) : Map - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getExtendedChildCreationData()', Sequence{genPackage}) /][/comment] - -[query public getFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getFactoryClassName()', Sequence{genPackage}) /] - -[query public getFactoryInstanceName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getFactoryInstanceName()', Sequence{genPackage}) /] - -[query public getFactoryInterfaceName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getFactoryInterfaceName()', Sequence{genPackage}) /] - -[query public getFactoryName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getFactoryName()', Sequence{genPackage}) /] - -[query public getFileExtension(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getFileExtension()', Sequence{genPackage}) /] - -[query public getImportedActionBarContributorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedActionBarContributorClassName()', Sequence{genPackage}) /] - -[query public getImportedAdapterFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedAdapterFactoryClassName()', Sequence{genPackage}) /] - -[query public getImportedEditPluginClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedEditPluginClassName()', Sequence{genPackage}) /] - -[query public getImportedEditorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedEditorClassName()', Sequence{genPackage}) /] - -[query public getImportedEditorPluginClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedEditorPluginClassName()', Sequence{genPackage}) /] - -[query public getImportedFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedFactoryClassName()', Sequence{genPackage}) /] - -[query public getImportedFactoryInterfaceName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedFactoryInterfaceName()', Sequence{genPackage}) /] - -[query public getImportedItemProviderAdapterFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedItemProviderAdapterFactoryClassName()', Sequence{genPackage}) /] - -[query public getImportedModelWizardClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedModelWizardClassName()', Sequence{genPackage}) /] - -[query public getImportedPackageClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedPackageClassName()', Sequence{genPackage}) /] - -[query public getImportedPackageInterfaceName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedPackageInterfaceName()', Sequence{genPackage}) /] - -[query public getImportedResourceBaseClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedResourceBaseClassName()', Sequence{genPackage}) /] - -[query public getImportedResourceClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedResourceClassName()', Sequence{genPackage}) /] - -[query public getImportedResourceFactoryBaseClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedResourceFactoryBaseClassName()', Sequence{genPackage}) /] - -[query public getImportedResourceFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedResourceFactoryClassName()', Sequence{genPackage}) /] - -[query public getImportedTestSuiteClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedTestSuiteClassName()', Sequence{genPackage}) /] - -[query public getImportedValidatorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedValidatorClassName()', Sequence{genPackage}) /] - -[query public getImportedXMLProcessorBaseClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getImportedXMLProcessorBaseClassName()', Sequence{genPackage}) /] - -[query public getInterfacePackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getInterfacePackageName()', Sequence{genPackage}) /] - -[query public getItemProviderAdapterFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getItemProviderAdapterFactoryClassName()', Sequence{genPackage}) /] - -[query public getJavaLangConflicts(genPackage : GenPackage) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getJavaLangConflicts()', Sequence{genPackage}) /] - -[query public getLocalClassifierIndex(genPackage : GenPackage, genClassifier : GenClassifier) : Integer - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getLocalClassifierIndex(org.eclipse.emf.codegen.ecore.genmodel.GenClassifier)', Sequence{genPackage, genClassifier}) /] - -[query public getModelIconFileName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getModelIconFileName()', Sequence{genPackage}) /] - -[query public getModelInfo(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getModelInfo()', Sequence{genPackage}) /] - -[query public getModelWizardClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getModelWizardClassName()', Sequence{genPackage}) /] - -[query public getModelWizardIconFileName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getModelWizardIconFileName()', Sequence{genPackage}) /] - -[query public getNSName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getNSName()', Sequence{genPackage}) /] - -[query public getNSURI(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getNSURI()', Sequence{genPackage}) /] - -[query public getOrderedGenClasses(genPackage : GenPackage) : Sequence(GenClass) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getOrderedGenClasses()', Sequence{genPackage}) /] - -[query public getOrderedGenClassifiers(genPackage : GenPackage) : Sequence(GenClassifier) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getOrderedGenClassifiers()', Sequence{genPackage}) /] - -[query public getPackageBuildInterDependencies(genPackage : GenPackage) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getPackageBuildInterDependencies()', Sequence{genPackage}) /] - -[query public getPackageClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getPackageClassName()', Sequence{genPackage}) /] - -[query public getPackageInitializationDependencies(genPackage : GenPackage) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getPackageInitializationDependencies()', Sequence{genPackage}) /] - -[query public getPackageInstanceVariable(genPackage : GenPackage, genPackage2 : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getPackageInstanceVariable(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage, genPackage2}) /] - -[query public getPackageInterDependencies(genPackage : GenPackage) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getPackageInterDependencies()', Sequence{genPackage}) /] - -[query public getPackageInterfaceName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getPackageInterfaceName()', Sequence{genPackage}) /] - -[query public getPackageLoadInterDependencies(genPackage : GenPackage) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getPackageLoadInterDependencies()', Sequence{genPackage}) /] - -[query public getPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getPackageName()', Sequence{genPackage}) /] - -[query public getPackageSimpleDependencies(genPackage : GenPackage) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getPackageSimpleDependencies()', Sequence{genPackage}) /] - -[query public getPresentationPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getPresentationPackageName()', Sequence{genPackage}) /] - -[query public getProviderPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getProviderPackageName()', Sequence{genPackage}) /] - -[query public getProviderSupportedTypes(genPackage : GenPackage) : Sequence(String) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getProviderSupportedTypes()', Sequence{genPackage}) /] - -[query public getQualifiedActionBarContributorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedActionBarContributorClassName()', Sequence{genPackage}) /] - -[query public getQualifiedAdapterFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedAdapterFactoryClassName()', Sequence{genPackage}) /] - -[query public getQualifiedContentTypeIdentifier(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedContentTypeIdentifier()', Sequence{genPackage}) /] - -[query public getQualifiedEFactoryInstanceAccessor(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedEFactoryInstanceAccessor()', Sequence{genPackage}) /] - -[query public getQualifiedEFactoryInternalInstanceAccessor(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedEFactoryInternalInstanceAccessor()', Sequence{genPackage}) /] - -[query public getQualifiedEditPluginClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedEditPluginClassName()', Sequence{genPackage}) /] - -[query public getQualifiedEditorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedEditorClassName()', Sequence{genPackage}) /] - -[query public getQualifiedEditorPluginClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedEditorPluginClassName()', Sequence{genPackage}) /] - -[query public getQualifiedEffectiveResourceFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedEffectiveResourceFactoryClassName()', Sequence{genPackage}) /] - -[query public getQualifiedExampleClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedExampleClassName()', Sequence{genPackage}) /] - -[query public getQualifiedFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedFactoryClassName()', Sequence{genPackage}) /] - -[query public getQualifiedFactoryInstanceAccessor(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedFactoryInstanceAccessor()', Sequence{genPackage}) /] - -[query public getQualifiedFactoryInterfaceName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedFactoryInterfaceName()', Sequence{genPackage}) /] - -[query public getQualifiedItemProviderAdapterFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedItemProviderAdapterFactoryClassName()', Sequence{genPackage}) /] - -[query public getQualifiedModelWizardClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedModelWizardClassName()', Sequence{genPackage}) /] - -[query public getQualifiedPackageClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedPackageClassName()', Sequence{genPackage}) /] - -[query public getQualifiedPackageInterfaceName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedPackageInterfaceName()', Sequence{genPackage}) /] - -[query public getQualifiedPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedPackageName()', Sequence{genPackage}) /] - -[query public getQualifiedResourceClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedResourceClassName()', Sequence{genPackage}) /] - -[query public getQualifiedResourceFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedResourceFactoryClassName()', Sequence{genPackage}) /] - -[query public getQualifiedSwitchClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedSwitchClassName()', Sequence{genPackage}) /] - -[query public getQualifiedTestSuiteClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedTestSuiteClassName()', Sequence{genPackage}) /] - -[query public getQualifiedValidatorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedValidatorClassName()', Sequence{genPackage}) /] - -[query public getQualifiedXMLProcessorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getQualifiedXMLProcessorClassName()', Sequence{genPackage}) /] - -[comment][query public getReferenceData(genPackage : GenPackage, eAnnotation : EAnnotation) : Sequence(AnnotationReferenceData) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getReferenceData(org.eclipse.emf.ecore.EAnnotation)', Sequence{genPackage, eAnnotation}) /][/comment] - -[query public getReflectionClassPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getReflectionClassPackageName()', Sequence{genPackage}) /] - -[query public getReflectionPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getReflectionPackageName()', Sequence{genPackage}) /] - -[query public getResource(genPackage : GenPackage) : GenResourceKind - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getResource()', Sequence{genPackage}) /] - -[query public getResourceClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getResourceClassName()', Sequence{genPackage}) /] - -[query public getResourceFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getResourceFactoryClassName()', Sequence{genPackage}) /] - -[query public getRootClass(genPackage : GenPackage) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getRootClass()', Sequence{genPackage}) /] - -[query public getRootFeature(genPackage : GenPackage) : GenFeature - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getRootFeature()', Sequence{genPackage}) /] - -[query public getRootGenPackage(genPackage : GenPackage) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getRootGenPackage()', Sequence{genPackage}) /] - -[query public getSerializedPackageFilename(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getSerializedPackageFilename()', Sequence{genPackage}) /] - -[query public getSubGenPackages(genPackage : GenPackage) : Sequence(GenPackage) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getSubGenPackages()', Sequence{genPackage}) /] - -[query public getSuperGenPackage(genPackage : GenPackage) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getSuperGenPackage()', Sequence{genPackage}) /] - -[query public getSwitchClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getSwitchClassName()', Sequence{genPackage}) /] - -[query public getTestSuiteClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getTestSuiteClassName()', Sequence{genPackage}) /] - -[query public getTestsPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getTestsPackageName()', Sequence{genPackage}) /] - -[query public getUncapAdapterFactoryClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getUncapAdapterFactoryClassName()', Sequence{genPackage}) /] - -[query public getUncapAdapterFactoryDelegateName(genPackage : GenPackage, genDelegate : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getUncapAdapterFactoryDelegateName(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage, genDelegate}) /] - -[query public getUncapFactoryInterfaceName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getUncapFactoryInterfaceName()', Sequence{genPackage}) /] - -[query public getUncapFactoryName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getUncapFactoryName()', Sequence{genPackage}) /] - -[query public getUncapPackageInterfaceName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getUncapPackageInterfaceName()', Sequence{genPackage}) /] - -[query public getUncapPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getUncapPackageName()', Sequence{genPackage}) /] - -[query public getUtilitiesPackageName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getUtilitiesPackageName()', Sequence{genPackage}) /] - -[query public getValidatorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getValidatorClassName()', Sequence{genPackage}) /] - -[query public getValidatorPackageUniqueSafeName(genPackage : GenPackage, genPackage2 : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getValidatorPackageUniqueSafeName(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage, genPackage2}) /] - -[query public getXMLProcessorClassName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getXMLProcessorClassName()', Sequence{genPackage}) /] - -[query public hasClassifiers(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasClassifiers()', Sequence{genPackage}) /] - -[query public hasClassifiers(genPackage : GenPackage, traverseNestedPackages : Boolean) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasClassifiers(boolean)', Sequence{genPackage, traverseNestedPackages}) /] - -[query public hasConcreteClasses(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasConcreteClasses()', Sequence{genPackage}) /] - -[query public hasConstraints(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasConstraints()', Sequence{genPackage}) /] - -[query public hasDocumentRoot(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasDocumentRoot()', Sequence{genPackage}) /] - -[query public hasExtendedMetaData(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasExtendedMetaData()', Sequence{genPackage}) /] - -[query public hasInterfaceImplConflict(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasInterfaceImplConflict()', Sequence{genPackage}) /] - -[query public hasInvariantExpressions(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasInvariantExpressions()', Sequence{genPackage}) /] - -[query public hasJavaLangConflict(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasJavaLangConflict()', Sequence{genPackage}) /] - -[query public hasStatefulProvider(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasStatefulProvider()', Sequence{genPackage}) /] - -[query public hasTargetNamespace(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasTargetNamespace()', Sequence{genPackage}) /] - -[query public hasTests(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasTests()', Sequence{genPackage}) /] - -[query public hasXMLMap(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasXMLMap()', Sequence{genPackage}) /] - -[query public isContentType(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'isContentType()', Sequence{genPackage}) /] - -[query public isEcorePackage(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'isEcorePackage()', Sequence{genPackage}) /] - -[query public isLoadedInitialization(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'isLoadedInitialization()', Sequence{genPackage}) /] - -[query public isLoadingInitialization(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'isLoadingInitialization()', Sequence{genPackage}) /] - -[query public isMultipleFileExtensions(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'isMultipleFileExtensions()', Sequence{genPackage}) /] - -[query public isXMIResource(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'isXMIResource()', Sequence{genPackage}) /] - -[query public reconcile(genPackage : GenPackage, oldGenPackageVersion : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage, oldGenPackageVersion}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'canGenerate()', Sequence{genPackage}) /] - -[query public canGenerateEdit(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'canGenerateEdit()', Sequence{genPackage}) /] - -[query public canGenerateEditor(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'canGenerateEditor()', Sequence{genPackage}) /] - -[query public canGenerateSchema(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'canGenerateSchema()', Sequence{genPackage}) /] - -[query public canGenerateTests(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'canGenerateTests()', Sequence{genPackage}) /] - -[query public capName(genPackage : GenPackage, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'capName(java.lang.String)', Sequence{genPackage, name}) /] - -[query public getCopyright(genPackage : GenPackage, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getCopyright(java.lang.String)', Sequence{genPackage, indentation}) /] - -[query public getDocumentation(genPackage : GenPackage, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getDocumentation(java.lang.String)', Sequence{genPackage, indentation}) /] - -[query public getEcoreModelElement(genPackage : GenPackage) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getEcoreModelElement()', Sequence{genPackage}) /] - -[query public getGenAnnotation(genPackage : GenPackage, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'getGenAnnotation(java.lang.String)', Sequence{genPackage, source}) /] - -[query public hasCopyright(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasCopyright()', Sequence{genPackage}) /] - -[query public hasDocumentation(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'hasDocumentation()', Sequence{genPackage}) /] - -[query public reconcile(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'reconcile()', Sequence{genPackage}) /] - -[query public safeName(genPackage : GenPackage, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'safeName(java.lang.String)', Sequence{genPackage, name}) /] - -[query public uncapName(genPackage : GenPackage, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'uncapName(java.lang.String)', Sequence{genPackage, name}) /] - -[query public uncapPrefixedName(genPackage : GenPackage, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'uncapPrefixedName(java.lang.String)', Sequence{genPackage, input}) /] - - - - - - - - -[comment special handling for avoiding NPE due to importManager /] -[query public isLiteralsInterface(genPackage : GenPackage) : Boolean = genPackage.literalsInterface/] - - - - - - - - - -[query public getExtendedChildCreationDataEntrySet(genPackage : GenPackage) : Set(OclAny) - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'getExtendedChildCreationDataEntrySet(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage}) /] - -[query public getPackageEntryKey(oclAny : OclAny) : GenPackage - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'getPackageEntryKey(java.lang.Object)', Sequence{oclAny}) /] - -[query public getPackageEntryValueEntrySet(oclAny : OclAny) : Set(OclAny) - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'getPackageEntryValueEntrySet(java.lang.Object)', Sequence{oclAny}) /] - -[query public getClassEntryChildCreationData(oclAny : OclAny) : Set(OclAny) - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'getClassEntryChildCreationData(java.lang.Object)', Sequence{oclAny}) /] - -[query public getClassEntryKey(oclAny : OclAny) : GenClass - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'getClassEntryKey(java.lang.Object)', Sequence{oclAny}) /] - -[comment - This query is used to reproduce getClassUniqueName(null), used in EMF, - but which cannot be translated "as is" with Acceleo - because of a bug in OCL when handling 'null' in sequences. -/] -[query public getDefaultClassUniqueName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'getDefaultClassUniqueName(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage}) /] - -[comment For Icons generation /] -[query public generateCreateChildIcons(genPackage : GenPackage) : OclVoid - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'generateCreateChildIcons(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage}) /] - -[query public generateModelIcon(genPackage : GenPackage) : OclVoid - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'generateModelIcon(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage}) /] - -[query public generateModelWizardIcon(genPackage : GenPackage) : OclVoid - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'generateModelWizardIcon(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage}) /] - -[comment - Flags this genPackage as needing an addEOperation method - /] -[query public requireAddEOperation(genPackage : GenPackage) : OclVoid - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'requireAddEOperation(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage})/] - -[comment - Flags this genPackage as needing an addEParameter method - /] -[query public requireAddEParameter(genPackage : GenPackage) : OclVoid - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'requireAddEParameter(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage})/] - -[query public needsAddEOperation(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'needsAddEOperation(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage})/] - -[query public needsAddEParameter(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'needsAddEParameter(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage})/] - -[query public prepareCache(genPackage : GenPackage) : OclVoid - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'prepareCache()', Sequence{genPackage})/] - -[query public clearCache(genPackage : GenPackage) : OclVoid - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenPackage', 'clearCache()', Sequence{genPackage})/] - -[query public isXMLTypePackage(genPackage : GenPackage) : Boolean - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'isXMLTypePackage(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage})/] - -[comment We use a template in order to prevent acceleo cache from calling the java method each time /] -[template public prefix(genPackage : GenPackage, depth : Integer)] -[invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'prefix(org.eclipse.emf.codegen.ecore.genmodel.GenPackage, int)', Sequence{genPackage, depth})/][/template] - -[comment We use a template in order to prevent acceleo cache from calling the java method each time /] -[template public typePrefix(genPackage : GenPackage, depth : Integer)] -[invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'typePrefix(org.eclipse.emf.codegen.ecore.genmodel.GenPackage, int)', Sequence{genPackage, depth})/][/template] - -[query public resetMaxGenericTypeAssignment(genPackage : GenPackage) : OclVoid - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'resetMaxGenericTypeAssignment()', Sequence{}) /] - -[query public resetGenOperationPrefix(genPackage : GenPackage) : OclVoid - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenOperationWrapper', 'resetGenOperationPrefix()', Sequence{genPackage}) /] - -[query public computeSwitchGenericTypeName(genPackage : GenPackage) : String - = invoke('org.eclipse.emf.eef.codegen.ecore.services.wrappers.GenPackageWrapper', 'computeSwitchGenericTypeName(org.eclipse.emf.codegen.ecore.genmodel.GenPackage)', Sequence{genPackage}) /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenPackageWrapper.java b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenPackageWrapper.java deleted file mode 100644 index 2b660d7b5..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenPackageWrapper.java +++ /dev/null @@ -1,264 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ecore.services.wrappers; - -import java.util.HashSet; -import java.util.List; -import java.util.Map; -import java.util.Set; - -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.codegen.ecore.genmodel.GenClass; -import org.eclipse.emf.codegen.ecore.genmodel.GenClass.ChildCreationData; -import org.eclipse.emf.codegen.ecore.genmodel.GenEnum; -import org.eclipse.emf.codegen.ecore.genmodel.GenFeature; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.GenOperation; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter; -import org.eclipse.emf.codegen.ecore.genmodel.generator.GenPackageGeneratorAdapter; -import org.eclipse.emf.codegen.util.GIFEmitter; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.eef.codegen.ecore.EMFCodegenPlugin; - -/** - * @author Stephane Bouchet - */ -public class GenPackageWrapper { - - public Set getExtendedChildCreationDataEntrySet(GenPackage genPackage) { - return genPackage.getExtendedChildCreationData().entrySet(); - } - - public Set getPackageEntryValueEntrySet(Object packageEntry) { - Map>> map = (Map>>)((Map.Entry)packageEntry) - .getValue(); - return map.entrySet(); - } - - /** - * @since 1.1 - */ - public String getDefaultClassUniqueName(GenPackage genPackage) { - return genPackage.getClassUniqueName(null); - } - - public List getClassEntryChildCreationData(Object classEntry) { - if (classEntry instanceof Map.Entry) { - return (List)((Map.Entry)classEntry).getValue(); - } - return null; - } - - public GenPackage getPackageEntryKey(Object packageEntry) { - if (packageEntry instanceof Map.Entry) { - return (GenPackage)((Map.Entry)packageEntry).getKey(); - } - return null; - } - - public GenClass getClassEntryKey(Object classEntry) { - if (classEntry instanceof Map.Entry) { - return (GenClass)((Map.Entry)classEntry).getKey(); - } - return null; - } - - /** - * used to wrap icon creation. - * - * @see GenPackageGeneratorAdapter#generateCreateChildIcons(GenPackage, Monitor) - * @param genPackage - */ - public void generateCreateChildIcons(GenPackage genPackage) { - GenModel genModel = genPackage.getGenModel(); - if (genModel.isCreationCommands() && genModel.isCreationIcons() - && genPackage.isChildCreationExtenders()) { - for (Map.Entry>> packageEntry : genPackage - .getExtendedChildCreationData().entrySet()) { - for (Map.Entry> classEntry : packageEntry - .getValue().entrySet()) { - GenClass genClass = classEntry.getKey(); - for (GenClass.ChildCreationData childCreationData : classEntry.getValue()) { - if (childCreationData.createClassifier instanceof GenClass - && (childCreationData.delegatedFeature == null || classEntry.getKey() - .getAllGenFeatures().contains(childCreationData.delegatedFeature))) { - GenClass childClass = (GenClass)childCreationData.createClassifier; - GenFeature feature = childCreationData.createFeature; - String inputFile = getClass().getResource("/templates/edit/CreateChild.gif") - .toString(); - GIFEmitter gifEmitter = new GIFEmitter(inputFile); - byte[] contents = gifEmitter - .generateGIF(genClass.getName(), childClass.getName()); - Path targetPath = new Path(genClass.getCreateChildIconFileName(genModel, feature, - childClass)); - EMFCodegenPlugin.getDefault().createGIF(contents, targetPath); - } - } - } - } - } - } - - /** - * used to wrap icon creation. - * - * @see GenPackageGeneratorAdapter#generateModelIcon(GenPackage, Monitor) - * @param genPackage - */ - public void generateModelIcon(GenPackage genPackage) { - if (genPackage.hasConcreteClasses()) { - String inputFile = getClass().getResource("/templates/editor/ModelFile.gif").toString(); - GIFEmitter gifEmitter = new GIFEmitter(inputFile); - byte[] contents = gifEmitter.generateGIF(genPackage.getPrefix(), null); - Path targetPath = new Path(genPackage.getModelIconFileName()); - EMFCodegenPlugin.getDefault().createGIF(contents, targetPath); - } - } - - /** - * used to wrap icon creation. - * - * @see GenPackageGeneratorAdapter#generateModelWizardIcon(GenPackage, Monitor) - * @param genPackage - */ - public void generateModelWizardIcon(GenPackage genPackage) { - if (genPackage.hasConcreteClasses() && genPackage.isGenerateModelWizard()) { - String inputFile = getClass().getResource("/templates/editor/NewModel.gif").toString(); - GIFEmitter gifEmitter = new GIFEmitter(inputFile); - byte[] contents = gifEmitter.generateGIF(genPackage.getPrefix(), null); - Path targetPath = new Path(genPackage.getModelWizardIconFileName()); - EMFCodegenPlugin.getDefault().createGIF(contents, targetPath); - } - } - - /** - * Indicates whether the given GenPackage represents the XMLTypePackage. - * - * @param genPackage - * @return - * @since 1.1 - */ - public boolean isXMLTypePackage(GenPackage genPackage) { - return org.eclipse.emf.ecore.xml.type.XMLTypePackage.eNS_URI.equals(genPackage.getNSURI()); - } - - private boolean needsAddEOperation = false; - - private boolean needsAddEParameter = false; - - /** - * @since 1.1 - */ - public void requireAddEOperation(GenPackage genPackage) { - needsAddEOperation = true; - } - - /** - * @since 1.1 - */ - public void requireAddEParameter(GenPackage genPackage) { - needsAddEParameter = true; - } - - /** - * @since 1.1 - */ - public boolean needsAddEOperation(GenPackage genPackage) { - return needsAddEOperation; - } - - /** - * @since 1.1 - */ - public boolean needsAddEParameter(GenPackage genPackage) { - return needsAddEParameter; - } - - /** - * Counter to reproduce the way EMF manages generic types. - */ - private int maxGenericTypeAssignment = 0; - - /** - * @since 1.1 - */ - public void resetMaxGenericTypeAssignment() { - maxGenericTypeAssignment = 0; - } - - /** - * @since 1.1 - */ - public String prefix(GenPackage genPackage, int depth) { - String prefix = ""; - if (maxGenericTypeAssignment <= depth) { - ++maxGenericTypeAssignment; - prefix = genPackage.getGenModel().getImportedName("org.eclipse.emf.ecore.EGenericType") + " "; - } - return prefix; - } - - private boolean firstPrefix = true; - - /** - * @since 1.1 - */ - public String prefix(GenOperation genOperation) { - if (firstPrefix) { - firstPrefix = false; - return genOperation.getGenModel().getImportedName("org.eclipse.emf.ecore.EOperation") + " op = "; - } - return "op = "; - } - - /** - * @since 1.1 - */ - public void resetGenOperationPrefix() { - firstPrefix = true; - } - - /** - * @since 1.1 - */ - public String typePrefix(GenPackage genPackage, int depth) { - String typePrefix = ""; - if (maxGenericTypeAssignment <= depth) { - ++maxGenericTypeAssignment; - typePrefix = genPackage.getGenModel().getImportedName("org.eclipse.emf.ecore.EGenericType") + " "; - } - return typePrefix; - } - - /** - * @since 1.1 - */ - public String computeSwitchGenericTypeName(GenPackage genPackage) { - Set usedNames = new HashSet(); - for (GenEnum genEnum : genPackage.getGenEnums()) { - usedNames.add(genEnum.getName()); - } - for (GenClass genClass : genPackage.getAllSwitchGenClasses()) { - if (!genClass.isDynamic() && !genClass.isExternalInterface()) { - usedNames.add(genClass.getName()); - } - for (GenTypeParameter genTypeParameter : genClass.getGenTypeParameters()) { - usedNames.add(genTypeParameter.getName()); - } - } - String templateParameterName = "T"; - for (int i = 1; usedNames.contains(templateParameterName); ++i) { - templateParameterName = "T" + i; - } - return templateParameterName; - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenParameter.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenParameter.mtl deleted file mode 100644 index 1d5197eb9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenParameter.mtl +++ /dev/null @@ -1,266 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenParameter('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public getGenPackage(genParameter : GenParameter) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getGenPackage()', Sequence{genParameter}) /] - -[query public getName(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getName()', Sequence{genParameter}) /] - -[query public getQualifiedModelInfo(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getQualifiedModelInfo()', Sequence{genParameter}) /] - -[query public reconcile(genParameter : GenParameter, oldGenParameterVersion : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenParameter)', Sequence{genParameter, oldGenParameterVersion}) /] - -[comment - Override of services for super interface GenTypedElement -/] -[query public getEObjectCast(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getEObjectCast()', Sequence{genParameter}) /] - -[query public getEcoreModelElement(genParameter : GenParameter) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getEcoreModelElement()', Sequence{genParameter}) /] - -[query public getEffectiveComplianceLevel(genParameter : GenParameter) : GenJDKLevel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getEffectiveComplianceLevel()', Sequence{genParameter}) /] - -[query public getGenClassType(genParameter : GenParameter) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getGenClassType()', Sequence{genParameter}) /] - -[query public getGenDataTypeType(genParameter : GenParameter) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getGenDataTypeType()', Sequence{genParameter}) /] - -[query public getGenEnumType(genParameter : GenParameter) : GenEnum - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getGenEnumType()', Sequence{genParameter}) /] - -[query public getImportedEffectiveFeatureMapWrapperClass(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getImportedEffectiveFeatureMapWrapperClass()', Sequence{genParameter}) /] - -[query public getImportedEffectiveFeatureMapWrapperInternalInterface(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getImportedEffectiveFeatureMapWrapperInternalInterface()', Sequence{genParameter}) /] - -[query public getImportedInternalType(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getImportedInternalType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getImportedInternalType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getImportedInternalType()', Sequence{genParameter}) /] - -[query public getImportedMapEntryType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getImportedMapEntryType()', Sequence{genParameter}) /] - -[query public getImportedMapKeyType(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getImportedMapKeyType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getImportedMapTemplateArguments(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getImportedMapTemplateArguments(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getImportedMapValueType(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getImportedMapValueType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getImportedType(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getImportedType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getImportedType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getImportedType()', Sequence{genParameter}) /] - -[query public getInternalTypeCast(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getInternalTypeCast()', Sequence{genParameter}) /] - -[query public getListItemType(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getListItemType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getListItemType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getListItemType()', Sequence{genParameter}) /] - -[query public getListTemplateArguments(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getListTemplateArguments(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getLowerBound(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getLowerBound()', Sequence{genParameter}) /] - -[query public getMapEntryTypeGenClass(genParameter : GenParameter) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getMapEntryTypeGenClass()', Sequence{genParameter}) /] - -[query public getMapGenClass(genParameter : GenParameter) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getMapGenClass()', Sequence{genParameter}) /] - -[query public getMapItemType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getMapItemType()', Sequence{genParameter}) /] - -[query public getNonEObjectInternalTypeCast(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getNonEObjectInternalTypeCast(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getNonEObjectInternalTypeCast(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getNonEObjectInternalTypeCast()', Sequence{genParameter}) /] - -[query public getObjectType(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getObjectType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getObjectType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getObjectType()', Sequence{genParameter}) /] - -[query public getOrderedFlag(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getOrderedFlag()', Sequence{genParameter}) /] - -[query public getPrimitiveValueFunction(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getPrimitiveValueFunction()', Sequence{genParameter}) /] - -[query public getQualifiedListItemType(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getQualifiedListItemType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getQualifiedListItemType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getQualifiedListItemType()', Sequence{genParameter}) /] - -[query public getRawBoundType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getRawBoundType()', Sequence{genParameter}) /] - -[query public getRawImportedBoundType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getRawImportedBoundType()', Sequence{genParameter}) /] - -[query public getRawImportedType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getRawImportedType()', Sequence{genParameter}) /] - -[query public getRawListItemType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getRawListItemType()', Sequence{genParameter}) /] - -[query public getRawType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getRawType()', Sequence{genParameter}) /] - -[query public getRawTypeCast(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getRawTypeCast()', Sequence{genParameter}) /] - -[query public getType(genParameter : GenParameter, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public getType(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getType()', Sequence{genParameter}) /] - -[query public getTypeClassifier(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getTypeClassifier()', Sequence{genParameter}) /] - -[query public getTypeClassifierAccessorName(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getTypeClassifierAccessorName()', Sequence{genParameter}) /] - -[query public getTypeGenClass(genParameter : GenParameter) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getTypeGenClass()', Sequence{genParameter}) /] - -[query public getTypeGenClassifier(genParameter : GenParameter) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getTypeGenClassifier()', Sequence{genParameter}) /] - -[query public getTypeGenDataType(genParameter : GenParameter) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getTypeGenDataType()', Sequence{genParameter}) /] - -[query public getTypeGenEnum(genParameter : GenParameter) : GenEnum - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getTypeGenEnum()', Sequence{genParameter}) /] - -[query public getTypeGenPackage(genParameter : GenParameter) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getTypeGenPackage()', Sequence{genParameter}) /] - -[query public getUniqueFlag(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getUniqueFlag()', Sequence{genParameter}) /] - -[query public getUpperBound(genParameter : GenParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getUpperBound()', Sequence{genParameter}) /] - -[query public hasGenericType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'hasGenericType()', Sequence{genParameter}) /] - -[query public isBooleanType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isBooleanType()', Sequence{genParameter}) /] - -[query public isEffectiveSuppressEMFTypes(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isEffectiveSuppressEMFTypes()', Sequence{genParameter}) /] - -[query public isEnumBasedType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isEnumBasedType()', Sequence{genParameter}) /] - -[query public isEnumType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isEnumType()', Sequence{genParameter}) /] - -[query public isFeatureMapType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isFeatureMapType()', Sequence{genParameter}) /] - -[query public isFeatureMapWrapped(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isFeatureMapWrapped()', Sequence{genParameter}) /] - -[query public isListDataType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isListDataType()', Sequence{genParameter}) /] - -[query public isListType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isListType()', Sequence{genParameter}) /] - -[query public isMapType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isMapType()', Sequence{genParameter}) /] - -[query public isPrimitiveType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isPrimitiveType()', Sequence{genParameter}) /] - -[query public isStringBasedType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isStringBasedType()', Sequence{genParameter}) /] - -[query public isStringType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isStringType()', Sequence{genParameter}) /] - -[query public isUncheckedCast(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isUncheckedCast()', Sequence{genParameter}) /] - -[query public isUncheckedCast(genParameter : GenParameter, ctx : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isUncheckedCast(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genParameter, ctx}) /] - -[query public isUnique(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isUnique()', Sequence{genParameter}) /] - -[query public isWrappedFeatureMapType(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'isWrappedFeatureMapType()', Sequence{genParameter}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'canGenerate()', Sequence{genParameter}) /] - -[query public canGenerateEdit(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'canGenerateEdit()', Sequence{genParameter}) /] - -[query public canGenerateEditor(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'canGenerateEditor()', Sequence{genParameter}) /] - -[query public canGenerateSchema(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'canGenerateSchema()', Sequence{genParameter}) /] - -[query public canGenerateTests(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'canGenerateTests()', Sequence{genParameter}) /] - -[query public capName(genParameter : GenParameter, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'capName(java.lang.String)', Sequence{genParameter, name}) /] - -[query public getCopyright(genParameter : GenParameter, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getCopyright(java.lang.String)', Sequence{genParameter, indentation}) /] - -[query public getDocumentation(genParameter : GenParameter, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getDocumentation(java.lang.String)', Sequence{genParameter, indentation}) /] - -[query public getGenAnnotation(genParameter : GenParameter, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getGenAnnotation(java.lang.String)', Sequence{genParameter, source}) /] - -[query public getGenModel(genParameter : GenParameter) : GenModel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'getGenModel()', Sequence{genParameter}) /] - -[query public hasCopyright(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'hasCopyright()', Sequence{genParameter}) /] - -[query public hasDocumentation(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'hasDocumentation()', Sequence{genParameter}) /] - -[query public reconcile(genParameter : GenParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'reconcile()', Sequence{genParameter}) /] - -[query public safeName(genParameter : GenParameter, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'safeName(java.lang.String)', Sequence{genParameter, name}) /] - -[query public uncapName(genParameter : GenParameter, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'uncapName(java.lang.String)', Sequence{genParameter, name}) /] - -[query public uncapPrefixedName(genParameter : GenParameter, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenParameter', 'uncapPrefixedName(java.lang.String)', Sequence{genParameter, input}) /] diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenTypeParameter.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenTypeParameter.mtl deleted file mode 100644 index 9435d940a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenTypeParameter.mtl +++ /dev/null @@ -1,76 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenTypeParameter('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public getEcoreTypeParameter(genTypeParameter : GenTypeParameter) : ETypeParameter - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'getEcoreTypeParameter()', Sequence{genTypeParameter}) /] - -[query public getName(genTypeParameter : GenTypeParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'getName()', Sequence{genTypeParameter}) /] - -[query public getQualifiedModelInfo(genTypeParameter : GenTypeParameter) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'getQualifiedModelInfo()', Sequence{genTypeParameter}) /] - -[query public isUsed(genTypeParameter : GenTypeParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'isUsed()', Sequence{genTypeParameter}) /] - -[query public reconcile(genTypeParameter : GenTypeParameter, oldGenTypeParameterVersion : GenTypeParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'reconcile(org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter)', Sequence{genTypeParameter, oldGenTypeParameterVersion}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genTypeParameter : GenTypeParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'canGenerate()', Sequence{genTypeParameter}) /] - -[query public canGenerateEdit(genTypeParameter : GenTypeParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'canGenerateEdit()', Sequence{genTypeParameter}) /] - -[query public canGenerateEditor(genTypeParameter : GenTypeParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'canGenerateEditor()', Sequence{genTypeParameter}) /] - -[query public canGenerateSchema(genTypeParameter : GenTypeParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'canGenerateSchema()', Sequence{genTypeParameter}) /] - -[query public canGenerateTests(genTypeParameter : GenTypeParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'canGenerateTests()', Sequence{genTypeParameter}) /] - -[query public capName(genTypeParameter : GenTypeParameter, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'capName(java.lang.String)', Sequence{genTypeParameter, name}) /] - -[query public getCopyright(genTypeParameter : GenTypeParameter, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'getCopyright(java.lang.String)', Sequence{genTypeParameter, indentation}) /] - -[query public getDocumentation(genTypeParameter : GenTypeParameter, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'getDocumentation(java.lang.String)', Sequence{genTypeParameter, indentation}) /] - -[query public getEcoreModelElement(genTypeParameter : GenTypeParameter) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'getEcoreModelElement()', Sequence{genTypeParameter}) /] - -[query public getGenAnnotation(genTypeParameter : GenTypeParameter, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'getGenAnnotation(java.lang.String)', Sequence{genTypeParameter, source}) /] - -[query public getGenAnnotations(genTypeParameter : GenTypeParameter) : Sequence(GenAnnotation) - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'getGenAnnotations()', Sequence{genTypeParameter}) /] - -[query public getGenModel(genTypeParameter : GenTypeParameter) : GenModel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'getGenModel()', Sequence{genTypeParameter}) /] - -[query public hasCopyright(genTypeParameter : GenTypeParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'hasCopyright()', Sequence{genTypeParameter}) /] - -[query public hasDocumentation(genTypeParameter : GenTypeParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'hasDocumentation()', Sequence{genTypeParameter}) /] - -[query public reconcile(genTypeParameter : GenTypeParameter) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'reconcile()', Sequence{genTypeParameter}) /] - -[query public safeName(genTypeParameter : GenTypeParameter, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'safeName(java.lang.String)', Sequence{genTypeParameter, name}) /] - -[query public uncapName(genTypeParameter : GenTypeParameter, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'uncapName(java.lang.String)', Sequence{genTypeParameter, name}) /] - -[query public uncapPrefixedName(genTypeParameter : GenTypeParameter, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypeParameter', 'uncapPrefixedName(java.lang.String)', Sequence{genTypeParameter, input}) /] - - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenTypedElement.mtl b/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenTypedElement.mtl deleted file mode 100644 index 52cdc8ed1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.ecore/src/org/eclipse/emf/eef/codegen/ecore/services/wrappers/GenTypedElement.mtl +++ /dev/null @@ -1,253 +0,0 @@ -[comment encoding = UTF-8 /] -[module GenTypedElement('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[query public getEObjectCast(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getEObjectCast()', Sequence{genTypedElement}) /] - -[query public getEcoreModelElement(genTypedElement : GenTypedElement) : EModelElement - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getEcoreModelElement()', Sequence{genTypedElement}) /] - -[query public getEffectiveComplianceLevel(genTypedElement : GenTypedElement) : GenJDKLevel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getEffectiveComplianceLevel()', Sequence{genTypedElement}) /] - -[query public getGenClassType(genTypedElement : GenTypedElement) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getGenClassType()', Sequence{genTypedElement}) /] - -[query public getGenDataTypeType(genTypedElement : GenTypedElement) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getGenDataTypeType()', Sequence{genTypedElement}) /] - -[query public getGenEnumType(genTypedElement : GenTypedElement) : GenEnum - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getGenEnumType()', Sequence{genTypedElement}) /] - -[query public getImportedEffectiveFeatureMapWrapperClass(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getImportedEffectiveFeatureMapWrapperClass()', Sequence{genTypedElement}) /] - -[query public getImportedEffectiveFeatureMapWrapperInternalInterface(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getImportedEffectiveFeatureMapWrapperInternalInterface()', Sequence{genTypedElement}) /] - -[query public getImportedInternalType(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getImportedInternalType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getImportedInternalType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getImportedInternalType()', Sequence{genTypedElement}) /] - -[query public getImportedMapEntryType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getImportedMapEntryType()', Sequence{genTypedElement}) /] - -[query public getImportedMapKeyType(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getImportedMapKeyType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getImportedMapTemplateArguments(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getImportedMapTemplateArguments(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getImportedMapValueType(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getImportedMapValueType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getImportedType(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getImportedType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getImportedType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getImportedType()', Sequence{genTypedElement}) /] - -[query public getInternalTypeCast(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getInternalTypeCast()', Sequence{genTypedElement}) /] - -[query public getListItemType(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getListItemType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getListItemType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getListItemType()', Sequence{genTypedElement}) /] - -[query public getListTemplateArguments(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getListTemplateArguments(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getLowerBound(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getLowerBound()', Sequence{genTypedElement}) /] - -[query public getMapEntryTypeGenClass(genTypedElement : GenTypedElement) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getMapEntryTypeGenClass()', Sequence{genTypedElement}) /] - -[query public getMapGenClass(genTypedElement : GenTypedElement) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getMapGenClass()', Sequence{genTypedElement}) /] - -[query public getMapItemType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getMapItemType()', Sequence{genTypedElement}) /] - -[query public getNonEObjectInternalTypeCast(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getNonEObjectInternalTypeCast(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getNonEObjectInternalTypeCast(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getNonEObjectInternalTypeCast()', Sequence{genTypedElement}) /] - -[query public getObjectType(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getObjectType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getObjectType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getObjectType()', Sequence{genTypedElement}) /] - -[query public getOrderedFlag(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getOrderedFlag()', Sequence{genTypedElement}) /] - -[query public getPrimitiveValueFunction(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getPrimitiveValueFunction()', Sequence{genTypedElement}) /] - -[query public getQualifiedListItemType(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getQualifiedListItemType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getQualifiedListItemType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getQualifiedListItemType()', Sequence{genTypedElement}) /] - -[query public getRawBoundType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getRawBoundType()', Sequence{genTypedElement}) /] - -[query public getRawImportedBoundType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getRawImportedBoundType()', Sequence{genTypedElement}) /] - -[query public getRawImportedType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getRawImportedType()', Sequence{genTypedElement}) /] - -[query public getRawListItemType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getRawListItemType()', Sequence{genTypedElement}) /] - -[query public getRawType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getRawType()', Sequence{genTypedElement}) /] - -[query public getRawTypeCast(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getRawTypeCast()', Sequence{genTypedElement}) /] - -[query public getType(genTypedElement : GenTypedElement, ctx : GenClass) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getType(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public getType(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getType()', Sequence{genTypedElement}) /] - -[query public getTypeClassifier(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getTypeClassifier()', Sequence{genTypedElement}) /] - -[query public getTypeClassifierAccessorName(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getTypeClassifierAccessorName()', Sequence{genTypedElement}) /] - -[query public getTypeGenClass(genTypedElement : GenTypedElement) : GenClass - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getTypeGenClass()', Sequence{genTypedElement}) /] - -[query public getTypeGenClassifier(genTypedElement : GenTypedElement) : GenClassifier - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getTypeGenClassifier()', Sequence{genTypedElement}) /] - -[query public getTypeGenDataType(genTypedElement : GenTypedElement) : GenDataType - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getTypeGenDataType()', Sequence{genTypedElement}) /] - -[query public getTypeGenEnum(genTypedElement : GenTypedElement) : GenEnum - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getTypeGenEnum()', Sequence{genTypedElement}) /] - -[query public getTypeGenPackage(genTypedElement : GenTypedElement) : GenPackage - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getTypeGenPackage()', Sequence{genTypedElement}) /] - -[query public getUniqueFlag(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getUniqueFlag()', Sequence{genTypedElement}) /] - -[query public getUpperBound(genTypedElement : GenTypedElement) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getUpperBound()', Sequence{genTypedElement}) /] - -[query public hasGenericType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'hasGenericType()', Sequence{genTypedElement}) /] - -[query public isBooleanType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isBooleanType()', Sequence{genTypedElement}) /] - -[query public isEffectiveSuppressEMFTypes(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isEffectiveSuppressEMFTypes()', Sequence{genTypedElement}) /] - -[query public isEnumBasedType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isEnumBasedType()', Sequence{genTypedElement}) /] - -[query public isEnumType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isEnumType()', Sequence{genTypedElement}) /] - -[query public isFeatureMapType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isFeatureMapType()', Sequence{genTypedElement}) /] - -[query public isFeatureMapWrapped(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isFeatureMapWrapped()', Sequence{genTypedElement}) /] - -[query public isListDataType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isListDataType()', Sequence{genTypedElement}) /] - -[query public isListType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isListType()', Sequence{genTypedElement}) /] - -[query public isMapType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isMapType()', Sequence{genTypedElement}) /] - -[query public isPrimitiveType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isPrimitiveType()', Sequence{genTypedElement}) /] - -[query public isStringBasedType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isStringBasedType()', Sequence{genTypedElement}) /] - -[query public isStringType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isStringType()', Sequence{genTypedElement}) /] - -[query public isUncheckedCast(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isUncheckedCast()', Sequence{genTypedElement}) /] - -[query public isUncheckedCast(genTypedElement : GenTypedElement, ctx : GenClass) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isUncheckedCast(org.eclipse.emf.codegen.ecore.genmodel.GenClass)', Sequence{genTypedElement, ctx}) /] - -[query public isUnique(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isUnique()', Sequence{genTypedElement}) /] - -[query public isWrappedFeatureMapType(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'isWrappedFeatureMapType()', Sequence{genTypedElement}) /] - -[comment - Override of services for super interface GenBase -/] -[query public canGenerate(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'canGenerate()', Sequence{genTypedElement}) /] - -[query public canGenerateEdit(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'canGenerateEdit()', Sequence{genTypedElement}) /] - -[query public canGenerateEditor(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'canGenerateEditor()', Sequence{genTypedElement}) /] - -[query public canGenerateSchema(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'canGenerateSchema()', Sequence{genTypedElement}) /] - -[query public canGenerateTests(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'canGenerateTests()', Sequence{genTypedElement}) /] - -[query public capName(genTypedElement : GenTypedElement, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'capName(java.lang.String)', Sequence{genTypedElement, name}) /] - -[query public getCopyright(genTypedElement : GenTypedElement, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getCopyright(java.lang.String)', Sequence{genTypedElement, indentation}) /] - -[query public getDocumentation(genTypedElement : GenTypedElement, indentation : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getDocumentation(java.lang.String)', Sequence{genTypedElement, indentation}) /] - -[query public getGenAnnotation(genTypedElement : GenTypedElement, source : String) : GenAnnotation - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getGenAnnotation(java.lang.String)', Sequence{genTypedElement, source}) /] - -[query public getGenModel(genTypedElement : GenTypedElement) : GenModel - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'getGenModel()', Sequence{genTypedElement}) /] - -[query public hasCopyright(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'hasCopyright()', Sequence{genTypedElement}) /] - -[query public hasDocumentation(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'hasDocumentation()', Sequence{genTypedElement}) /] - -[query public reconcile(genTypedElement : GenTypedElement) : Boolean - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'reconcile()', Sequence{genTypedElement}) /] - -[query public safeName(genTypedElement : GenTypedElement, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'safeName(java.lang.String)', Sequence{genTypedElement, name}) /] - -[query public uncapName(genTypedElement : GenTypedElement, name : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'uncapName(java.lang.String)', Sequence{genTypedElement, name}) /] - -[query public uncapPrefixedName(genTypedElement : GenTypedElement, input : String) : String - = invoke('org.eclipse.emf.codegen.ecore.genmodel.GenTypedElement', 'uncapPrefixedName(java.lang.String)', Sequence{genTypedElement, input}) /] - - diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/templates/edit/CreateChild.gif b/plugins/org.eclipse.emf.eef.codegen.ecore/templates/edit/CreateChild.gif deleted file mode 100644 index add9741886f270d1e51f5d348d49c29a3e760083..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?74Gj(s4*&nh&yTnNf8QR+ zMHb&RT@8q~PEuaiCBL*uYF?$-%o5>$f8PVq-_PfP=+E=Tzwb5!O@jc%pDc_ZmJWyj z*~!2fqoB~25^1N#F!Su;DHpa*>Tm9wRN`s;*`()M_9RU)^?s@3Oy@w2*~?F`i}Y#D zId#&_ia|&1zPF2oKv2W%7YQF0oor`XnBXRVqow9{uGZ<7>G=#fHBG6FP1&l74Auaf Cd0-|0 diff --git a/plugins/org.eclipse.emf.eef.codegen.ecore/templates/edit/Item.gif b/plugins/org.eclipse.emf.eef.codegen.ecore/templates/edit/Item.gif deleted file mode 100644 index ec4ff4551b0ff631244dd4bf50a02338fb027b4a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 129 zcmZ?wbhEHb6krfw*vtS14M4Jip`qcxfddT<4GjN*-2XuK|Nmgte-L}loH;-#2L}hm zpDc_F44e!)Ae|sH7+CZSPI|81Yw`NaHx>Seg|6F8S#PBzcr94?)kg2*G_|W{vzrGC}L0arF<-r8I9;6(q=Uw^*; z{QdRE?@wQUfB5?Q?WbR_KK#7@^2eR$-+>lT3n>0%VPs%nW6%K^2=WsHTe(AXfrpNe z;t7>Y8Z8y`F7UQ!{)|{Jv$BxsRh9Kk&xt}>?Q+iqmPQEfkEI*qVxxL>L++Dp4Xu1dXMO(HS%DUvb~_ocG7?Jl{FrXXjvRX71+%xDNOX*vszj z?%Mj7we`<**2EBBJj9=qNH%?R6N*mHj)gX|TG3N9i7=^-uJ2-}e78!+t%>9iQV1mqw@Fk4(-_%t$568{#GT@`q1L zt6PJwXNM=}`NG9FGg86q^1Fo(BFXBsSSFKyTK@2HX?63%=9jgN&kHM?lI8WKwXM~S z&s$WVt?8D{xq-?4s`l2>Vp4Giz9_j68;8k*r=}B|TWV=--F=LI85r#7W;9gdu|2H8 zce69Rfj>srV`IFDDZ%{zZtefBAbUo8zW`9$1t=(K+c%ZJOj9~+crVE0*nU@#o+H6* zOt&se-5^AG=6n$%Q^Pn~+X3qf$<(n9gm7Bs9SRK3cM$62{s6QAoJ!_w213e|qL){u z_zRr!>+nOR!COJMTpg^9&P`naxRP(hp$MJpHIsPv3fn@IN%2%`5Wn7eCx6bp(VZ0{ zN>q1;268r*MMJa*s#j;^x#S(_8mlJeusCFb7De_)+v$_q6-jbTz;J^U1P!uWf~tJ#`+ zDX3j27o+A?J;1Tv1{`9lpMDkc(6?rFq~9#K3rvMG4{%jr&2V!>@p$U?%nkpOkxav+ zA_uMC4_0#kc(t$eO7PRZCpe={&|#QDk9Iz&)F;E%k(flSlvV?&9ok{)RD*id)1pfN zBL)P+gMyUwvdINTyW2;qapCn+B2d#*8JsWuX}bJ?qSw+{EYr0fGH?K~av!A8Iz%q$ zu;cD)+X!B5PdQ0ei3zUf1S(Ya8vG8Cj3i(o@w%H~4LTSD)S1MAP+2$7Qsv~swp*GI zdgzZjLv#sO{63G@APeY%=K>pv6BC`m9p7l`;gQTsqs&)*P<0cAgXqYs zly|LvGB>VKT76=S4)aVtKM)$ii~8j%2kOYygS%~1ovvAFqNpF2Kzon=!DI3?RfM{k zSozoKDl+du%NfUVUK3Y9bv5q&lPd%$_?wCv`7-Gpn5oD1z4kZ2(4LRn#jmsJ@mGEl0adM4=5u`-c3xvYt3C#>e2MuBO()8rqVn&_e~Cos9*Y-Z_n${i zUUqr^)ur;BAl>!0X75xVdBGlQ+$Y72n1B!^=UtqFWHBXr7cO3N4v2v7IzIdSrK7VE zEI<8TK}&IxrfgTzggkPgLiu!wx_5!Hi)MD2pow)`$1mLqB-YzS z2>Ooas<>#8zgM+9qfP=@Yf`U0IZ|VP!{E{>Ao_9t!4CQ>+n{wM=fqPLpD&G3>8pqn zA(c1B%|QM(r+|^!^9Qjec1F=-O7Rjg@Z8fpZ{J9Gv-(lGV7$nv?tE&W)i>JsX13l1 z7A7yu)->CMcEA>lmMY@FN{6sf90M=H9 z)~@ZQZZ{#nUN5F==h^RDtPc=uRm+mWhiY$ArYO9sLOqaWfG2w-&rQ?*c80@H0lQ^wJ6tlUXRSAc4xzkbkVyhheO5a3uL zX9%uCDjr_Y2PXQ#pf-5Lfs#)JRXIqau;|KEb6b_Rf#HZiPtPeW-3E9(^}AgoZf`Ea zwD|tUp%NPscK8+Lzlnt**8|_)+5bxUv>yr>9w&R-zrNnUFqgc00KPZfIZU6}tc(6B zhP|#YWjuQ3`9?YOB18W;B5k`mjO9=>ryS5p(U*n#NsIiKHyA4wn7?C_=q-O2biW&4 W(@OL5k=6ExZ0F1_9#B^YSo{MpAjRzf diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.classpath b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.classpath deleted file mode 100644 index 2d1a4302f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.gitignore b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.gitignore deleted file mode 100644 index d567ba01e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -bin -target diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.project b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.project deleted file mode 100644 index 97e8ea58f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.project +++ /dev/null @@ -1,48 +0,0 @@ - - - org.eclipse.emf.eef.codegen.extended.widgets.richtext - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - org.eclipse.acceleo.ide.ui.acceleoBuilder - - - compliance - pragmatic - - - resource.kind - binary - - - - - org.eclipse.pde.api.tools.apiAnalysisBuilder - - - - - - org.eclipse.acceleo.ide.ui.acceleoNature - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - org.eclipse.pde.api.tools.apiAnalysisNature - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index d1c0bf949..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,6 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/META-INF/MANIFEST.MF deleted file mode 100644 index 43bc002f4..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/META-INF/MANIFEST.MF +++ /dev/null @@ -1,24 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: Acceleo Extended Module Runtime Plug-in -Bundle-SymbolicName: org.eclipse.emf.eef.codegen.extended.widgets.richtext;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Activator: org.eclipse.emf.eef.codegen.extended.widgets.richtext.Activator -Bundle-Vendor: Eclipse Modeling Project -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.emf.eef.eefgen;bundle-version="1.0.0", - org.eclipse.emf.ecore;bundle-version="2.4.0", - org.eclipse.emf.ecore.xmi;bundle-version="2.4.0", - org.eclipse.ocl;bundle-version="1.2.0", - org.eclipse.ocl.ecore;bundle-version="1.2.0", - org.eclipse.acceleo.model;bundle-version="3.1.0", - org.eclipse.acceleo.engine;bundle-version="3.1.0", - org.eclipse.emf.eef.codegen;bundle-version="1.0.0", - org.eclipse.core.resources;bundle-version="3.4.0", - org.eclipse.emf.eef.runtime;bundle-version="1.0.0", - org.eclipse.ui;bundle-version="3.4.0", - org.eclipse.acceleo.parser;bundle-version="3.1.0";resolution:=optional -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Bundle-ActivationPolicy: lazy -Eclipse-LazyStart: true -Export-Package: org.eclipse.emf.eef.codegen.extended.widgets.richtext diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/about.html b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/build.acceleo b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/build.acceleo deleted file mode 100644 index ebb8cd827..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/build.acceleo +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/build.properties b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/build.properties deleted file mode 100644 index 3b7c29542..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/build.properties +++ /dev/null @@ -1,19 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2011 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ - about.html,\ - std/ -customBuildCallbacks = build.acceleo -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/plugin.xml b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/plugin.xml deleted file mode 100644 index 8aa22ac76..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/plugin.xml +++ /dev/null @@ -1,15 +0,0 @@ - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/pom.xml b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/pom.xml deleted file mode 100644 index 0734f3e03..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/pom.xml +++ /dev/null @@ -1,75 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf - org.eclipse.emf.eef.codegen.extended.widgets.richtext - 1.5.2-SNAPSHOT - eclipse-plugin - - EEF RichText Codegen Plug-in - - - - - org.eclipse.acceleo - org.eclipse.acceleo.maven - 3.5.0-SNAPSHOT - - - compile - - acceleo-compile - - - - - false - true - - ${project.basedir} - - - src - target/classes - - - - org.eclipse.emf:org.eclipse.emf.eef.codegen - - - - org.eclipse.emf.ecore.EcorePackage - org.eclipse.emf.eef.components.ComponentsPackage - org.eclipse.emf.eef.mapping.MappingPackage - org.eclipse.emf.eef.views.ViewsPackage - org.eclipse.emf.eef.EEFGen.EEFGenPackage - org.eclipse.emf.eef.mapping.filters.FiltersPackage - org.eclipse.emf.eef.mapping.navigation.NavigationPackage - org.eclipse.emf.eef.extended.editor.EditorPackage - org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage - - org.eclipse.acceleo.maven.AcceleoURIHandler - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/extended/widgets/richtext/Activator.java b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/extended/widgets/richtext/Activator.java deleted file mode 100644 index 9317d8f48..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/extended/widgets/richtext/Activator.java +++ /dev/null @@ -1,64 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2013 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.widgets.richtext; - -import org.eclipse.core.runtime.Plugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle. - */ -public class Activator extends Plugin { - - /** - * The plug-in ID. - */ - public static final String PLUGIN_ID = "org.eclipse.emf.eef.codegen.extended.widgets.richtext"; - - /** - * The shared instance. - */ - private static Activator plugin; - - /** - * The constructor. - */ - public Activator() { - } - - /**{@inheritDoc} - * - * @see org.eclipse.core.runtime.Plugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - /**{@inheritDoc} - * - * @see org.eclipse.core.runtime.Plugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance. - * - * @return the shared instance - */ - public static Activator getDefault() { - return plugin; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/extended/widgets/richtext/compiler/EEFRichTextCodegenCompiler.java b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/extended/widgets/richtext/compiler/EEFRichTextCodegenCompiler.java deleted file mode 100644 index 8e2269186..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/extended/widgets/richtext/compiler/EEFRichTextCodegenCompiler.java +++ /dev/null @@ -1,169 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.widgets.richtext.compiler; - -import java.io.File; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.Map; - -import org.eclipse.acceleo.common.IAcceleoConstants; -import org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; - -/** - * The Acceleo Standalone compiler. - * - * @author Goulwen Le Fur - * @since 1.2.2 - */ -public class EEFRichTextCodegenCompiler extends AbstractAcceleoCompiler { - - /** - * The entry point of the compilation. - * - * @param args - * The arguments used in the compilation: the source folder, the output folder, a boolean - * indicating if we should use binary resource serialization and finally the dependencies of - * the project. - */ - public static void main(String[] args) { - if (args.length < 3) { - throw new IllegalArgumentException("Missing parameters"); //$NON-NLS-1$ - } - EEFRichTextCodegenCompiler acceleoCompiler = new EEFRichTextCodegenCompiler(); - acceleoCompiler.setSourceFolder(args[0]); - acceleoCompiler.setOutputFolder(args[1]); - acceleoCompiler.setBinaryResource(Boolean.valueOf(args[2]).booleanValue()); - if (args.length == 4 && args[3] != null && !"".equals(args[3])) { //$NON-NLS-1$ - acceleoCompiler.setDependencies(args[3]); - } - acceleoCompiler.doCompile(new BasicMonitor()); - } - - /** - * Launches the compilation of the mtl files in the generator. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#doCompile(org.eclipse.emf.common.util.Monitor) - */ - @Override - public void doCompile(Monitor monitor) { - super.doCompile(monitor); - } - - /** - * Registers the packages of the metamodels used in the generator. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#registerPackages() - */ - @Override - protected void registerPackages() { - super.registerPackages(); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.components.ComponentsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.components.ComponentsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.MappingPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.MappingPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.navigation.NavigationPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.navigation.NavigationPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.filters.FiltersPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.filters.FiltersPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), - org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.views.ViewsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.views.ViewsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.toolkits.ToolkitsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.toolkits.ToolkitsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.EEFGen.EEFGenPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.EEFGen.EEFGenPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE); - - } - - /** - * Registers the resource factories. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#registerResourceFactories() - */ - @Override - protected void registerResourceFactories() { - super.registerResourceFactories(); - /* - * If you want to add other resource factories, for example if your metamodel uses a specific - * serialization: - * org.eclipse.emf.ecore.resource.Resource.Factory.Registry.getExtensionToFactoryMap().put - * (UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - */ - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#computeDependencies(java.util.List, - * java.util.Map) - */ - protected void computeDependencies(List dependenciesURIs, Map mapURIs) { - // USED TO FIX COMPILER WITH TYCHO - Iterator identifiersIt = dependenciesIDs.iterator(); - for (Iterator dependenciesIt = dependencies.iterator(); dependenciesIt.hasNext() - && identifiersIt.hasNext();) { - File requiredFolder = dependenciesIt.next(); - String identifier = identifiersIt.next(); - if (requiredFolder != null && requiredFolder.exists() && requiredFolder.isDirectory()) { - List emtlFiles = new ArrayList(); - members(emtlFiles, requiredFolder, IAcceleoConstants.EMTL_FILE_EXTENSION); - for (File emtlFile : emtlFiles) { - String requiredFolderAbsolutePath = requiredFolder.getAbsolutePath(); - if (requiredFolderAbsolutePath.endsWith("target/classes")) { - // using tycho - String[] splited = requiredFolderAbsolutePath.split("\\/"); - StringBuffer buf = new StringBuffer(requiredFolderAbsolutePath.length()); - for (int i = 0; i < splited.length - 3; i++) { - buf.append(splited[i]); - buf.append("/"); - } - requiredFolderAbsolutePath = buf.toString(); - String emtlAbsolutePath = emtlFile.getAbsolutePath(); - URI emtlFileURI = URI.createFileURI(emtlAbsolutePath); - dependenciesURIs.add(emtlFileURI); - String emtlModifiedPath = emtlAbsolutePath.replaceAll("target\\/|classes\\/", ""); - IPath relativePath = new Path(emtlModifiedPath.substring(requiredFolderAbsolutePath - .length())); - URI relativeURI = URI.createPlatformPluginURI(relativePath.toString(), false); - mapURIs.put(emtlFileURI, relativeURI); - } else { - // normal behavior - String emtlAbsolutePath = emtlFile.getAbsolutePath(); - URI emtlFileURI = URI.createFileURI(emtlAbsolutePath); - dependenciesURIs.add(emtlFileURI); - IPath relativePath = new Path(identifier).append(emtlAbsolutePath - .substring(requiredFolderAbsolutePath.length())); - mapURIs.put(emtlFileURI, URI.createPlatformPluginURI(relativePath.toString(), false)); - } - } - } - } - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextControl.mtl b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextControl.mtl deleted file mode 100644 index 417b76f47..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextControl.mtl +++ /dev/null @@ -1,60 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module richtextControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case : model = Attribute(1) - view = RichText ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('RichText') and not editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.isPrimitiveType())] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].create[editionElement.model.eType.instanceClassName.toUpperFirst()/]FromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue())));[else] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([editionElement.model.eType.instanceClassName/])[include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].createFromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue()));[/if] -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('RichText'))] -if ([editionElement.liveUpdaterNavigationConditionForText(pec)/] && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])){ - if (msg.getNewValue() != null) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EcoreUtil.convertToString([editionElement.metamodelTypeGetter()/], msg.getNewValue())); - } else { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](""); - } -} -[/template] - - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('RichText') and not editionElement.canGeneratemodelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EcoreUtil.convertToString([editionElement.metamodelTypeGetter()/], [pec.pecModelClass().toJavaIdentifier()/].[if isBoolean(editionElement.model.oclAsType(EAttribute))]is[else]get[/if][editionElement.model.name.toUpperFirst()/]())); -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('RichText'))] -[comment no filters for RichText /] -[/template] - - -[comment ===== Case : model = Attribute(1) - view = RichText - ModelNavigation ===== /] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('RichText') and editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.isPrimitiveType())] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].create[editionElement.model.eType.instanceClassName.toUpperFirst()/]FromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue())));[else] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([editionElement.model.eType.instanceClassName/])[include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].createFromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue()));[/if] -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('RichText') and editionElement.canGeneratemodelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EcoreUtil.convertToString([editionElement.metamodelTypeGetter()/], [editionElement.name.toJavaIdentifier()/]Settings.getValue())); -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextFormImpl.mtl deleted file mode 100644 index b1dfbdd73..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextFormImpl.mtl +++ /dev/null @@ -1,156 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module richtextFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'RichText')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.widgets.Label', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.emf.eef.runtime.ui.widgets.richtext.actions.EEFFontNameAction', - 'org.eclipse.emf.eef.runtime.ui.widgets.richtext.actions.EEFFontSizeAction', - 'org.eclipse.emf.eef.runtime.ui.widgets.richtext.actions.EEFFontStyleAction', - 'org.eclipse.epf.richtext.actions.IndentAction', - 'org.eclipse.epf.richtext.actions.ItalicAction', - 'org.eclipse.epf.richtext.actions.JustifyCenterAction', - 'org.eclipse.epf.richtext.actions.JustifyLeftAction', - 'org.eclipse.epf.richtext.actions.JustifyRightAction', - 'org.eclipse.epf.richtext.actions.OutdentAction', - 'org.eclipse.epf.richtext.actions.PasteAction', - 'org.eclipse.epf.richtext.actions.SubscriptAction', - 'org.eclipse.epf.richtext.actions.SuperscriptAction', - 'org.eclipse.epf.richtext.actions.TidyActionGroup', - 'org.eclipse.epf.richtext.actions.UnderlineAction', - 'org.eclipse.epf.richtext.IRichText', - 'org.eclipse.epf.richtext.IRichTextToolBar', - 'org.eclipse.epf.richtext.RichTextToolBar', - 'org.eclipse.epf.richtext.actions.AddImageAction', - 'org.eclipse.epf.richtext.actions.AddLinkAction', - 'org.eclipse.epf.richtext.actions.AddOrderedListAction', - 'org.eclipse.epf.richtext.actions.AddTableAction', - 'org.eclipse.epf.richtext.actions.AddUnorderedListAction', - 'org.eclipse.epf.richtext.actions.BoldAction', - 'org.eclipse.epf.richtext.actions.ClearContentAction', - 'org.eclipse.epf.richtext.actions.CopyAction', - 'org.eclipse.epf.richtext.actions.CutAction', - 'org.eclipse.epf.richtext.actions.FindReplaceAction', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'RichText')] - protected [include('org.eclipse.epf.richtext.RichText')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'RichText')] -return create[editor.name.toJavaClassifier()/]RichText(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'RichText')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]RichText(FormToolkit widgetFactory, Composite parent) { - [if (editor.nameAsLabel)] - Label [editor.elementEditorName()/]Label = FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - Label [editor.elementEditorName()/]Label = createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - GridData [editor.elementEditorName()/]LabelData = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]LabelData.horizontalSpan = 2; - [editor.elementEditorName()/]Label.setLayoutData([editor.elementEditorName()/]LabelData); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - Composite toolbarContainer = widgetFactory.createComposite(parent); - toolbarContainer.setLayout(new GridLayout(2, false)); - GridData toolbarData = new GridData(GridData.FILL_HORIZONTAL); - toolbarData.horizontalSpan = 3; - toolbarContainer.setLayoutData(toolbarData); - RichTextToolBar toolBar = new RichTextToolBar(toolbarContainer, SWT.NONE, [editor.elementEditorName()/]); - [editor.elementEditorName()/] = new RichText(parent, SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); //$NON-NLS-1$ - [editor.elementEditorName()/].setEditable(true); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 3; - [editor.elementEditorName()/]Data.heightHint = 200; - [editor.elementEditorName()/]Data.widthHint = 200; - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - - [editor.elementEditorName()/].addModifyListener(new ModifyListener() { - public void modifyText(ModifyEvent e) { - propertiesEditionComponent.delayedFirePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editorID(editor)/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - }); - - fillToolBar(toolBar, [editor.elementEditorName()/]); - return parent; - } - - /** - * Populate actions in the Toolbar to link with the RichText - * - * @param toolBar The IRichTextToolBar - * @param richText The IRichText - */ - private void fillToolBar(IRichTextToolBar toolBar, IRichText richText) { - [editor.fillToolbar()/] - } -[/template] - -[template public fillToolbar (editor : ElementEditor) ] - toolBar.addAction(new EEFFontStyleAction(richText)); - toolBar.addAction(new EEFFontNameAction(richText)); - toolBar.addAction(new EEFFontSizeAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new CutAction(richText)); - toolBar.addAction(new CopyAction(richText)); - toolBar.addAction(new PasteAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new ClearContentAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new BoldAction(richText)); - toolBar.addAction(new ItalicAction(richText)); - toolBar.addAction(new UnderlineAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new SubscriptAction(richText)); - toolBar.addAction(new SuperscriptAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new TidyActionGroup(richText)); - toolBar.addSeparator(); - toolBar.addAction(new AddOrderedListAction(richText)); - toolBar.addAction(new AddUnorderedListAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new OutdentAction(richText)); - toolBar.addAction(new IndentAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new JustifyLeftAction(richText)); - toolBar.addAction(new JustifyCenterAction(richText)); - toolBar.addAction(new JustifyRightAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new FindReplaceAction(richText) { - /** - * @see org.eclipse.epf.richtext.actions.FindReplaceAction#execute(org.eclipse.epf.richtext.IRichText) - */ - public void execute(IRichText rText) { - rText.getFindReplaceAction().execute(rText); - } - }); - toolBar.addSeparator(); - toolBar.addAction(new AddLinkAction(richText)); - toolBar.addAction(new AddImageAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new AddTableAction(richText)); - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextGettersSetters.mtl deleted file mode 100644 index dcc83cdd7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextGettersSetters.mtl +++ /dev/null @@ -1,55 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module richtextGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('RichText'))] -[elementEditor.getterSignature()/] { - return [elementEditor.elementEditorName()/].getText(); - } -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('RichText'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].setText(newValue); - } else { - [elementEditor.elementEditorName()/].setText(""); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] - -[template public readOnly (editor : ElementEditor)] -[if (editor.readOnly)] -[editor.setReadOnly()/] -[else] -boolean eefElementEditorReadOnlyState = isReadOnly([editor.editorID()/][navigationReadOnly()/]); -if (eefElementEditorReadOnlyState && [editor.elementEditorName()/].getEditable()==true) { - [editor.setReadOnly()/] -} else if (!eefElementEditorReadOnlyState && [editor.elementEditorName()/].getEditable()==false) { - [editor.unsetReadOnly()/] -} -[/if] -[/template] - -[template public setReadOnly (editor : ElementEditor)] -[editor.elementEditorName()/].setEditable(false); -[/template] - -[template public unsetReadOnly (editor : ElementEditor)] -[editor.elementEditorName()/].setEditable(true); -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextSWTImpl.mtl deleted file mode 100644 index 1f532f137..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/src/org/eclipse/emf/eef/codegen/widgets/impl/richtext/richtextSWTImpl.mtl +++ /dev/null @@ -1,156 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module richtextSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'RichText')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.widgets.Label', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.emf.eef.runtime.ui.widgets.richtext.actions.EEFFontNameAction', - 'org.eclipse.emf.eef.runtime.ui.widgets.richtext.actions.EEFFontSizeAction', - 'org.eclipse.emf.eef.runtime.ui.widgets.richtext.actions.EEFFontStyleAction', - 'org.eclipse.epf.richtext.actions.IndentAction', - 'org.eclipse.epf.richtext.actions.ItalicAction', - 'org.eclipse.epf.richtext.actions.JustifyCenterAction', - 'org.eclipse.epf.richtext.actions.JustifyLeftAction', - 'org.eclipse.epf.richtext.actions.JustifyRightAction', - 'org.eclipse.epf.richtext.actions.OutdentAction', - 'org.eclipse.epf.richtext.actions.PasteAction', - 'org.eclipse.epf.richtext.actions.SubscriptAction', - 'org.eclipse.epf.richtext.actions.SuperscriptAction', - 'org.eclipse.epf.richtext.actions.TidyActionGroup', - 'org.eclipse.epf.richtext.actions.UnderlineAction', - 'org.eclipse.epf.richtext.IRichText', - 'org.eclipse.epf.richtext.IRichTextToolBar', - 'org.eclipse.epf.richtext.RichTextToolBar', - 'org.eclipse.epf.richtext.actions.AddImageAction', - 'org.eclipse.epf.richtext.actions.AddLinkAction', - 'org.eclipse.epf.richtext.actions.AddOrderedListAction', - 'org.eclipse.epf.richtext.actions.AddTableAction', - 'org.eclipse.epf.richtext.actions.AddUnorderedListAction', - 'org.eclipse.epf.richtext.actions.BoldAction', - 'org.eclipse.epf.richtext.actions.ClearContentAction', - 'org.eclipse.epf.richtext.actions.CopyAction', - 'org.eclipse.epf.richtext.actions.CutAction', - 'org.eclipse.epf.richtext.actions.FindReplaceAction', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'RichText')] - protected [include('org.eclipse.epf.richtext.RichText')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'RichText')] -return create[editor.name.toJavaClassifier()/]RichText(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'RichText')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]RichText(Composite parent) { - [if (editor.nameAsLabel)] - Label [editor.elementEditorName()/]Label = SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - Label [editor.elementEditorName()/]Label = createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - GridData [editor.elementEditorName()/]LabelData = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]LabelData.horizontalSpan = 2; - [editor.elementEditorName()/]Label.setLayoutData([editor.elementEditorName()/]LabelData); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - Composite toolbarContainer = new Composite(parent, SWT.NONE); - toolbarContainer.setLayout(new GridLayout(2, false)); - GridData toolbarData = new GridData(GridData.FILL_HORIZONTAL); - toolbarData.horizontalSpan = 3; - toolbarContainer.setLayoutData(toolbarData); - RichTextToolBar toolBar = new RichTextToolBar(toolbarContainer, SWT.NONE, [editor.elementEditorName()/]); - [editor.elementEditorName()/] = new RichText(parent, SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); //$NON-NLS-1$ - [editor.elementEditorName()/].setEditable(true); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 3; - [editor.elementEditorName()/]Data.heightHint = 200; - [editor.elementEditorName()/]Data.widthHint = 200; - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - - [editor.elementEditorName()/].addModifyListener(new ModifyListener() { - public void modifyText(ModifyEvent e) { - propertiesEditionComponent.delayedFirePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editorID(editor)/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - }); - - fillToolBar(toolBar, [editor.elementEditorName()/]); - return parent; - } - - /** - * Populate actions in the Toolbar to link with the RichText - * - * @param toolBar The IRichTextToolBar - * @param richText The IRichText - */ - private void fillToolBar(IRichTextToolBar toolBar, IRichText richText) { - [editor.fillToolBar()/] - } -[/template] - -[template public fillToolBar (editor : ElementEditor) ] - toolBar.addAction(new EEFFontStyleAction(richText)); - toolBar.addAction(new EEFFontNameAction(richText)); - toolBar.addAction(new EEFFontSizeAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new CutAction(richText)); - toolBar.addAction(new CopyAction(richText)); - toolBar.addAction(new PasteAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new ClearContentAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new BoldAction(richText)); - toolBar.addAction(new ItalicAction(richText)); - toolBar.addAction(new UnderlineAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new SubscriptAction(richText)); - toolBar.addAction(new SuperscriptAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new TidyActionGroup(richText)); - toolBar.addSeparator(); - toolBar.addAction(new AddOrderedListAction(richText)); - toolBar.addAction(new AddUnorderedListAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new OutdentAction(richText)); - toolBar.addAction(new IndentAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new JustifyLeftAction(richText)); - toolBar.addAction(new JustifyCenterAction(richText)); - toolBar.addAction(new JustifyRightAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new FindReplaceAction(richText) { - /** - * @see org.eclipse.epf.richtext.actions.FindReplaceAction#execute(org.eclipse.epf.richtext.IRichText) - */ - public void execute(IRichText rText) { - rText.getFindReplaceAction().execute(rText); - } - }); - toolBar.addSeparator(); - toolBar.addAction(new AddLinkAction(richText)); - toolBar.addAction(new AddImageAction(richText)); - toolBar.addSeparator(); - toolBar.addAction(new AddTableAction(richText)); - -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/std/Extended.toolkits b/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/std/Extended.toolkits deleted file mode 100644 index b668f3bfb..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended.widgets.richtext/std/Extended.toolkits +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/.classpath b/plugins/org.eclipse.emf.eef.codegen.extended/.classpath deleted file mode 100644 index ed5ee00d9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/.classpath +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/.gitignore b/plugins/org.eclipse.emf.eef.codegen.extended/.gitignore deleted file mode 100644 index d567ba01e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -bin -target diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/.project b/plugins/org.eclipse.emf.eef.codegen.extended/.project deleted file mode 100644 index d4aae1c62..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/.project +++ /dev/null @@ -1,48 +0,0 @@ - - - org.eclipse.emf.eef.codegen.extended - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - org.eclipse.acceleo.ide.ui.acceleoBuilder - - - compliance - pragmatic - - - resource.kind - binary - - - - - org.eclipse.pde.api.tools.apiAnalysisBuilder - - - - - - org.eclipse.acceleo.ide.ui.acceleoNature - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - org.eclipse.pde.api.tools.apiAnalysisNature - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.codegen.extended/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index d1c0bf949..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,6 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.codegen.extended/META-INF/MANIFEST.MF deleted file mode 100644 index 3353b1f1e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/META-INF/MANIFEST.MF +++ /dev/null @@ -1,33 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: Acceleo Extended Module Runtime Plug-in -Bundle-SymbolicName: org.eclipse.emf.eef.codegen.extended;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Activator: org.eclipse.emf.eef.codegen.extended.Activator -Bundle-Vendor: Eclipse Modeling Project -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.emf.eef.eefgen;bundle-version="1.0.0", - org.eclipse.emf.ecore;bundle-version="2.4.0", - org.eclipse.emf.ecore.xmi;bundle-version="2.4.0", - org.eclipse.ocl;bundle-version="1.2.0", - org.eclipse.ocl.ecore;bundle-version="1.2.0", - org.eclipse.acceleo.model;bundle-version="3.1.0", - org.eclipse.acceleo.engine;bundle-version="3.1.0", - org.eclipse.emf.eef.codegen;bundle-version="1.0.0", - org.eclipse.core.resources;bundle-version="3.4.0", - org.eclipse.emf.eef.runtime;bundle-version="1.0.0", - org.eclipse.emf.eef.editor.model;bundle-version="1.0.0", - org.eclipse.emf.eef.runtime.extended;bundle-version="1.0.0", - org.eclipse.ui;bundle-version="3.4.0", - org.eclipse.acceleo.parser;bundle-version="3.1.0";resolution:=optional, - org.eclipse.emf.eef.codegen.ecore;bundle-version="1.1.0" -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Bundle-ActivationPolicy: lazy -Eclipse-LazyStart: true -Export-Package: org.eclipse.emf.eef.codegen.extended, - org.eclipse.emf.eef.codegen.extended.files, - org.eclipse.emf.eef.codegen.extended.flow, - org.eclipse.emf.eef.codegen.extended.initializer, - org.eclipse.emf.eef.codegen.extended.launcher, - org.eclipse.emf.eef.codegen.extended.ui.initializer, - org.eclipse.emf.eef.codegen.extended.ui.launcher diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/about.html b/plugins/org.eclipse.emf.eef.codegen.extended/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/build.acceleo b/plugins/org.eclipse.emf.eef.codegen.extended/build.acceleo deleted file mode 100644 index ab52fd3dc..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/build.acceleo +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/build.properties b/plugins/org.eclipse.emf.eef.codegen.extended/build.properties deleted file mode 100644 index cd7d70856..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/build.properties +++ /dev/null @@ -1,21 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2011 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/,\ - src-custom/,\ - src-build/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ - icons/,\ - about.html -customBuildCallbacks = build.acceleo -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/icons/full/obj16/initialize_eef_editor.gif b/plugins/org.eclipse.emf.eef.codegen.extended/icons/full/obj16/initialize_eef_editor.gif deleted file mode 100644 index 3a63a22343ca9f808bba6b07563b2b9894ade73b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1057 zcmeH`+fR~l0ER!DF6I$3E?Oj@CCCMTq_p>nzK#u69eS*i~fnOdiGvC@9n$2@d4dv|B2|g z%)fT5-w^Qq0Q|6kU9)}H>@Zq@!3vC4U^;MYSiz@Hw+1E)vaz~K=$aCrm(H~7y# zU4Z1q#9z4NNu5|lYmOVb-^)Oqy!VFIX77H=J>uI=L~&HUxbwHQDdVqT4L3X}gIaOXdrlNe ztwmG3Vj=#i8!|FxI6twG@^Ebw2@Z?#I&rCJxetNr8zLE6PCslQc;U|7inNi!{esBF z%YCRjhAbE#7)@JY#w`R;*oJp!BMk)DhaQ-@Jk#w%iq!-NYRj2gp+Am%W^0*yEe5*s E2bYNIuK)l5 diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/plugin.xml b/plugins/org.eclipse.emf.eef.codegen.extended/plugin.xml deleted file mode 100644 index 8a4cd5d41..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/plugin.xml +++ /dev/null @@ -1,68 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/pom.xml b/plugins/org.eclipse.emf.eef.codegen.extended/pom.xml deleted file mode 100644 index 8350d8116..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/pom.xml +++ /dev/null @@ -1,76 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf - org.eclipse.emf.eef.codegen.extended - 1.5.2-SNAPSHOT - eclipse-plugin - - EEF Extended Codegen Plug-in - - - - - org.eclipse.acceleo - org.eclipse.acceleo.maven - 3.5.0-SNAPSHOT - - - compile - - acceleo-compile - - - - - false - true - - ${project.basedir} - - - src - target/classes - - - - org.eclipse.emf:org.eclipse.emf.eef.codegen - org.eclipse.emf:org.eclipse.emf.eef.codegen.ecore - - - - org.eclipse.emf.ecore.EcorePackage - org.eclipse.emf.eef.components.ComponentsPackage - org.eclipse.emf.eef.mapping.MappingPackage - org.eclipse.emf.eef.views.ViewsPackage - org.eclipse.emf.eef.EEFGen.EEFGenPackage - org.eclipse.emf.eef.mapping.filters.FiltersPackage - org.eclipse.emf.eef.mapping.navigation.NavigationPackage - org.eclipse.emf.eef.extended.editor.EditorPackage - org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage - - org.eclipse.acceleo.maven.AcceleoURIHandler - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-build/org/eclipse/emf/eef/codegen/extended/EEFCodegenExtendedCompiler.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-build/org/eclipse/emf/eef/codegen/extended/EEFCodegenExtendedCompiler.java deleted file mode 100644 index f0c48b9dc..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-build/org/eclipse/emf/eef/codegen/extended/EEFCodegenExtendedCompiler.java +++ /dev/null @@ -1,172 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended; - -import java.io.File; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.Map; - -import org.eclipse.acceleo.common.IAcceleoConstants; -import org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; - -/** - * The Acceleo Standalone compiler. - * - * @author Stephane Bouchet - * @since 1.1 - */ -public class EEFCodegenExtendedCompiler extends AbstractAcceleoCompiler { - - /** - * The entry point of the compilation. - * - * @param args - * The arguments used in the compilation: the source folder, the output folder, a boolean - * indicating if we should use binary resource serialization and finally the dependencies of - * the project. - */ - public static void main(String[] args) { - if (args.length < 3) { - throw new IllegalArgumentException("Missing parameters"); //$NON-NLS-1$ - } - EEFCodegenExtendedCompiler acceleoCompiler = new EEFCodegenExtendedCompiler(); - acceleoCompiler.setSourceFolder(args[0]); - acceleoCompiler.setOutputFolder(args[1]); - acceleoCompiler.setBinaryResource(Boolean.valueOf(args[2]).booleanValue()); - if (args.length == 4 && args[3] != null && !"".equals(args[3])) { //$NON-NLS-1$ - acceleoCompiler.setDependencies(args[3]); - } - acceleoCompiler.doCompile(new BasicMonitor()); - } - - /** - * Launches the compilation of the mtl files in the generator. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#doCompile(org.eclipse.emf.common.util.Monitor) - */ - @Override - public void doCompile(Monitor monitor) { - super.doCompile(monitor); - } - - /** - * Registers the packages of the metamodels used in the generator. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#registerPackages() - */ - @Override - protected void registerPackages() { - super.registerPackages(); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.components.ComponentsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.components.ComponentsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.MappingPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.MappingPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.navigation.NavigationPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.navigation.NavigationPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.filters.FiltersPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.filters.FiltersPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), - org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.views.ViewsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.views.ViewsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.toolkits.ToolkitsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.toolkits.ToolkitsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.EEFGen.EEFGenPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.EEFGen.EEFGenPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.extended.editor.EditorPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.extended.editor.EditorPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE); - - } - - /** - * Registers the resource factories. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#registerResourceFactories() - */ - @Override - protected void registerResourceFactories() { - super.registerResourceFactories(); - /* - * If you want to add other resource factories, for example if your metamodel uses a specific - * serialization: - * org.eclipse.emf.ecore.resource.Resource.Factory.Registry.getExtensionToFactoryMap().put - * (UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - */ - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#computeDependencies(java.util.List, - * java.util.Map) - */ - protected void computeDependencies(List dependenciesURIs, Map mapURIs) { - // USED TO FIX COMPILER WITH TYCHO - Iterator identifiersIt = dependenciesIDs.iterator(); - for (Iterator dependenciesIt = dependencies.iterator(); dependenciesIt.hasNext() - && identifiersIt.hasNext();) { - File requiredFolder = dependenciesIt.next(); - String identifier = identifiersIt.next(); - if (requiredFolder != null && requiredFolder.exists() && requiredFolder.isDirectory()) { - List emtlFiles = new ArrayList(); - members(emtlFiles, requiredFolder, IAcceleoConstants.EMTL_FILE_EXTENSION); - for (File emtlFile : emtlFiles) { - String requiredFolderAbsolutePath = requiredFolder.getAbsolutePath(); - if (requiredFolderAbsolutePath.endsWith("target/classes")) { - // using tycho - String[] splited = requiredFolderAbsolutePath.split("\\/"); - StringBuffer buf = new StringBuffer(requiredFolderAbsolutePath.length()); - for (int i = 0; i < splited.length - 3; i++) { - buf.append(splited[i]); - buf.append("/"); - } - requiredFolderAbsolutePath = buf.toString(); - String emtlAbsolutePath = emtlFile.getAbsolutePath(); - URI emtlFileURI = URI.createFileURI(emtlAbsolutePath); - dependenciesURIs.add(emtlFileURI); - String emtlModifiedPath = emtlAbsolutePath.replaceAll("target\\/|classes\\/", ""); - IPath relativePath = new Path(emtlModifiedPath.substring(requiredFolderAbsolutePath - .length())); - URI relativeURI = URI.createPlatformPluginURI(relativePath.toString(), false); - mapURIs.put(emtlFileURI, relativeURI); - } else { - // normal behavior - String emtlAbsolutePath = emtlFile.getAbsolutePath(); - URI emtlFileURI = URI.createFileURI(emtlAbsolutePath); - dependenciesURIs.add(emtlFileURI); - IPath relativePath = new Path(identifier).append(emtlAbsolutePath - .substring(requiredFolderAbsolutePath.length())); - mapURIs.put(emtlFileURI, URI.createPlatformPluginURI(relativePath.toString(), false)); - } - } - } - } - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/CleanEEFEditorSources.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/CleanEEFEditorSources.java deleted file mode 100644 index 85c193db2..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/CleanEEFEditorSources.java +++ /dev/null @@ -1,344 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.flow; - - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.eef.codegen.flow.StepWithInput; -import org.eclipse.emf.eef.codegen.flow.util.GenmodelHelper; -import org.eclipse.emf.eef.runtime.ui.EEFExtendedRuntime; -import org.eclipse.jface.wizard.WizardPage; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; - -/** - * @author Goulwen Le Fur - * - */ -public class CleanEEFEditorSources extends StepWithInput { - - private static final String PLUGIN_XML = "plugin.xml"; - private static final String PLUGIN_PROPERTIES = "plugin.properties"; - private static final String BUILD_PROPERTIES = "build.properties"; - - private GenmodelHelper helper; - private IFile ecoreModel; - private IContainer targetFolder; - - private boolean genmodel; - private boolean emfModelCode; - private boolean emfEditCode; - private boolean emfEditorCode; - private boolean eefPropertiesModels; - private boolean eefEditorModels; - - /** - * @param name task name - * @param activeShell the active shell - */ - public CleanEEFEditorSources(String name, IFile ecoreModel, IContainer targetFolder) { - super(name); - this.ecoreModel = ecoreModel; - this.targetFolder = targetFolder; - genmodel = true; - emfModelCode = true; - emfEditCode = true; - emfEditorCode = true; - eefPropertiesModels = true; - eefEditorModels = false; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - public IStatus execute(IProgressMonitor monitor) { - try { - GenModel genModel = helper.getGenModel(); - if (genModel != null) { - String modelDirectory = genModel.getModelDirectory(); - String editDirectory = genModel.getEditDirectory(); - String editorDirectory = genModel.getEditorDirectory(); - if (genmodel) { - deleteGenmodel(monitor); - } - if (emfModelCode) { - deleteProject(modelDirectory, monitor); - } - if (emfEditCode) { - deleteProject(editDirectory, monitor); - } - if (emfEditorCode) { - deleteProject(editorDirectory, monitor); - } - if (eefPropertiesModels) { - deleteEEFPropertiesModels(monitor); - } - if (eefEditorModels) { - deleteEEFEditorModels(monitor); - } - } - } catch (CoreException e) { - return new Status(IStatus.ERROR, EEFExtendedRuntime.PLUGIN_ID, "Unable to delete genmodel file.", e); - } - return Status.OK_STATUS; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.StepWithInput#getInputPages() - */ - public List getInputPages() { - helper = new GenmodelHelper(resourceSet, ecoreModel, targetFolder); - CleanEEFEditorSourcesWizardPage cleanEEFEditorSourcesWizardPage = new CleanEEFEditorSourcesWizardPage("Clean EEF Editor sources page"); - List pages = new ArrayList(); - pages.add(cleanEEFEditorSourcesWizardPage); - return pages; - } - - /** - * @param monitor - * @throws CoreException - */ - protected void deleteGenmodel(IProgressMonitor monitor) throws CoreException { - IFile genModelFile = helper.getGenModelFile(); - if (genModelFile.isAccessible()) { - genModelFile.delete(true, monitor); - helper.getTargetFolder().refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - } - - /** - * @param srcFolderDirectory - * @param monitor - * @throws CoreException - */ - protected void deleteProject(String srcFolderDirectory, IProgressMonitor monitor) throws CoreException { - IFolder srcFolder = ecoreModel.getWorkspace().getRoot().getFolder(new Path(srcFolderDirectory)); - IProject project = srcFolder.getProject(); - IFile pluginXML = project.getFile(new Path(PLUGIN_XML)); - IFile pluginProperties = project.getFile(new Path(PLUGIN_PROPERTIES)); - IFile buildProperties = project.getFile(new Path(BUILD_PROPERTIES)); - if (srcFolder.isAccessible()) { - srcFolder.delete(true, monitor); - } - if (pluginXML.isAccessible()) { - pluginXML.delete(true, monitor); - } - if (pluginProperties.isAccessible()) { - pluginProperties.delete(true, monitor); - } - if (buildProperties.isAccessible()) { - buildProperties.delete(true, monitor); - } - project.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - - /** - * @param monitor - * @throws CoreException - */ - protected void deleteEEFPropertiesModels(IProgressMonitor monitor) throws CoreException { - IFile eefPropertiesComponentsModel = helper.getEEFPropertiesComponentsModel(); - if (eefPropertiesComponentsModel.isAccessible()) { - eefPropertiesComponentsModel.delete(true, monitor); - } - IFile eefPropertiesEEFGenModel = helper.getEEFPropertiesEEFGenModel(); - if (eefPropertiesEEFGenModel.isAccessible()) { - eefPropertiesEEFGenModel.delete(true, monitor); - } - helper.getEEFModelsFolder().refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - - /** - * @param monitor - * @throws CoreException - */ - protected void deleteEEFEditorModels(IProgressMonitor monitor) throws CoreException { - IFile eefEditorComponentsModel = helper.getEEFEditorComponentsModel(); - if (eefEditorComponentsModel.isAccessible()) { - eefEditorComponentsModel.delete(true, monitor); - } - IFile eefEditorEEFGenModel = helper.getEEFEditorEEFGenModel(); - if (eefEditorEEFGenModel.isAccessible()) { - eefEditorEEFGenModel.delete(true, monitor); - } - helper.getEEFModelsFolder().refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - - private class CleanEEFEditorSourcesWizardPage extends WizardPage { - - private Button genmodelButton; - private Button emfModelCodeButton; - private Button emfEditCodeButton; - private Button emfEditorCodeButton; - private Button eefPropertiesModelsButton; - private Button eefEditorModelsButton; - - /** - * @param pageName - */ - public CleanEEFEditorSourcesWizardPage(String pageName) { - super(pageName); - setTitle("EEF editor sources cleaning"); - setDescription("Choose actions you want to perform"); - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.dialogs.IDialogPage#createControl(org.eclipse.swt.widgets.Composite) - */ - public void createControl(Composite parent) { - Composite container = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - container.setLayout(layout); - genmodelButton = new Button(container, SWT.CHECK); - genmodelButton.setText("Delete generated 'genmodel' file"); - genmodelButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - genmodel = !genmodel; - } - - }); - if (helper.getGenModelFile().exists()) { - genmodelButton.setSelection(genmodel); - } else { - genmodelButton.setEnabled(false); - genmodel = false; - } - emfModelCodeButton = new Button(container, SWT.CHECK); - emfModelCodeButton.setText("Delete generated EMF model code"); - emfModelCodeButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - emfModelCode = !emfModelCode; - } - - }); - IFolder emfModelSrcFolder = helper.getEMFModelSrcFolder(); - if (emfModelSrcFolder != null && emfModelSrcFolder.isAccessible()) { - emfModelCodeButton.setSelection(emfModelCode); - } else { - emfModelCodeButton.setEnabled(false); - emfModelCode = false; - } - emfEditCodeButton = new Button(container, SWT.CHECK); - emfEditCodeButton.setText("Delete generated EMF edit code"); - emfEditCodeButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - emfEditCode = !emfEditCode; - } - - }); - IFolder emfEditSrcFolder = helper.getEMFEditSrcFolder(); - if (emfEditSrcFolder != null && emfEditSrcFolder.isAccessible()) { - emfEditCodeButton.setSelection(emfEditCode); - } else { - emfEditCodeButton.setEnabled(false); - emfEditCode = false; - } - emfEditorCodeButton = new Button(container, SWT.CHECK); - emfEditorCodeButton.setText("Delete generated EMF editor code"); - emfEditorCodeButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - emfEditorCode = !emfEditorCode; - } - - }); - IFolder emfEditorSrcFolder = helper.getEMFEditorSrcFolder(); - if (emfEditorSrcFolder != null && emfEditorSrcFolder.isAccessible()) { - emfEditorCodeButton.setSelection(emfEditorCode); - } else { - emfEditorCodeButton.setEnabled(false); - emfEditorCode = false; - } - eefPropertiesModelsButton = new Button(container, SWT.CHECK); - eefPropertiesModelsButton.setText("Delete generated EEF models for properties views"); - eefPropertiesModelsButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - eefPropertiesModels = !eefPropertiesModels; - } - - }); - if (helper.getEEFPropertiesComponentsModel().exists() || helper.getEEFPropertiesEEFGenModel().exists()) { - eefPropertiesModelsButton.setSelection(eefPropertiesModels); - } else { - eefPropertiesModelsButton.setEnabled(false); - eefPropertiesModels = false; - } - eefEditorModelsButton = new Button(container, SWT.CHECK); - eefEditorModelsButton.setText("Delete generated EEF models for EEF editor"); - eefEditorModelsButton.setSelection(true); - eefEditorModelsButton.addSelectionListener(new SelectionAdapter() { - - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - eefEditorModels = !eefEditorModels; - } - - }); - if (helper.getEEFEditorComponentsModel().exists() || helper.getEEFEditorEEFGenModel().exists()) { - eefEditorModelsButton.setSelection(eefEditorModels); - } else { - eefEditorModelsButton.setEnabled(false); - eefEditorModels = false; - } - setControl(container); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/GenerateEEFEditorModels.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/GenerateEEFEditorModels.java deleted file mode 100644 index f913bde11..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/GenerateEEFEditorModels.java +++ /dev/null @@ -1,147 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.flow; - -import java.io.IOException; - -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.util.EMFHelper; -import org.eclipse.emf.eef.codegen.extended.initializer.EEFEditorModelInitializer; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.util.GenmodelHelper; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; - -/** - * @author Goulwen Le Fur - * - */ -public class GenerateEEFEditorModels extends Step { - - private EEFEditorModelInitializer eefeditorModelInitializer; - private Object modelURI; - private Object editGenProject; - private Object genmodelURI; - private WorkflowVariable eefgenModelVar; - private Object modelsFolder; - - /** - * @param name of the step - */ - public GenerateEEFEditorModels(String name, Object modelURI, Object editGenProject, Object genmodelURI, Object modelsFolder) { - super(name); - this.modelURI = modelURI; - this.editGenProject = editGenProject; - this.genmodelURI = genmodelURI; - this.modelsFolder = modelsFolder; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - public IStatus execute(IProgressMonitor monitor) { - try { - IProject editProject = getEditProject(); - if (editProject != null) { - eefeditorModelInitializer = new EEFEditorModelInitializer(); - initializeEEFModels(getModelsFolder(), getGenModelURI()); - EEFGenModel eefgenModel = generatedEEFGen(getModelURI(), getModelsFolder()); - ((WorkflowVariable)getEEFGenModel()).setValue(eefgenModel); - return Status.OK_STATUS; - } - else { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "Unable to find edit project"); - } - } catch (IOException e) { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "An error occured during EEF models initialization.", e); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "An error occured during EEF models initialization.", e); - } - } - - public Object getEEFGenModel() { - if (eefgenModelVar == null) { - eefgenModelVar = new WorkflowVariable(eefgenmodelVarName()); - } - return eefgenModelVar; - } - - private final String eefgenmodelVarName() { - return "GEN_EEF_EDITOR_MODEL_" + name + "_EEFGENMODEL"; - } - - private URI getModelURI() { - if (modelURI instanceof URI) { - return (URI) modelURI; - } else if (modelURI instanceof WorkflowVariable) { - return (URI) ((WorkflowVariable)modelURI).getValue(); - } - return null; - } - - private URI getGenModelURI() { - if (genmodelURI instanceof URI) { - return (URI) genmodelURI; - } else if (genmodelURI instanceof WorkflowVariable) { - return (URI) ((WorkflowVariable)genmodelURI).getValue(); - } - return null; - } - - private IProject getEditProject() { - if (editGenProject instanceof IProject) { - return (IProject) editGenProject; - } else if (editGenProject instanceof WorkflowVariable) { - return (IProject) ((WorkflowVariable)editGenProject).getValue(); - } - else { - return null; - } - } - - private IFolder getModelsFolder() { - if (modelsFolder instanceof IFolder) { - return (IFolder) modelsFolder; - } else if (modelsFolder instanceof WorkflowVariable) { - return (IFolder) ((WorkflowVariable)modelsFolder).getValue(); - } else { - return null; - } - } - - private void initializeEEFModels(IFolder modelsFolder, URI genmodelURI) throws IOException, CoreException { - NullProgressMonitor monitor = new NullProgressMonitor(); - eefeditorModelInitializer.initialize(genmodelURI, modelsFolder); - modelsFolder.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - - private EEFGenModel generatedEEFGen(URI modelURI, IFolder modelsFolder) throws IOException { - EEFGenModel eefgenModel = null; - URI eefgenURI = GenmodelHelper.computeEditorEEFGenModelURI(modelsFolder, modelURI); - EObject extractedEEFGenModel = EMFHelper.load(eefgenURI, resourceSet); - if (extractedEEFGenModel instanceof EEFGenModel) { - eefgenModel = (EEFGenModel)extractedEEFGenModel; - } - return eefgenModel; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/OverrideEMFEditorCode.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/OverrideEMFEditorCode.java deleted file mode 100644 index 5403f1a92..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/flow/OverrideEMFEditorCode.java +++ /dev/null @@ -1,149 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.flow; - -import java.io.ByteArrayInputStream; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Set; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.codegen.core.launcher.AbstractPropertiesGeneratorLauncher; -import org.eclipse.emf.eef.codegen.core.services.PropertiesGeneratorLaunchersServices; -import org.eclipse.emf.eef.codegen.extended.Activator; -import org.eclipse.emf.eef.codegen.extended.launcher.EEFEditorLauncher; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; - -/** - * @author Goulwen Le Fur - * - */ -public class OverrideEMFEditorCode extends Step { - - private Object eefEditorGenModel; - - /** - * @param name - */ - public OverrideEMFEditorCode(String name, Object eefEditorGenModel) { - super(name); - this.eefEditorGenModel = eefEditorGenModel; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - @Override - public IStatus execute(IProgressMonitor monitor) { - try { - EEFGenModel eefEditorGenModel = getEEFEditorGenModel(); - IContainer target = getGenContainer(eefEditorGenModel); - if (target != null) { - monitor.beginTask("Generating EEF Editor", 1); - clearExistingEditorCode(monitor); - Set generationTargets = new LinkedHashSet(); - generationTargets.add(target); - final EEFEditorLauncher generator = new EEFEditorLauncher(eefEditorGenModel, target.getLocation().toFile(), new ArrayList()); - generator.doGenerate(BasicMonitor.toMonitor(monitor)); - - List launchers = PropertiesGeneratorLaunchersServices.getInstance().getlaunchers(); - for (AbstractPropertiesGeneratorLauncher abstractPropertiesGeneratorLauncher : launchers) { - EObject inputModel = generator.getModel(); - if (inputModel instanceof EEFGenModel) { - abstractPropertiesGeneratorLauncher.doGenerate(eefEditorGenModel, generator.getTargetFolder(), monitor); - if (!abstractPropertiesGeneratorLauncher.getTargetContainer().isEmpty()) - generationTargets.addAll(abstractPropertiesGeneratorLauncher.getTargetContainer()); - } - } - for (Iterator iterator = generationTargets - .iterator(); iterator.hasNext();) { - IContainer nextContainer = iterator.next(); - nextContainer.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - - } - return Status.OK_STATUS; - } catch (IOException e) { - return new Status(IStatus.ERROR, Activator.PLUGIN_ID, "An error occured during generation.", e); - } catch (CoreException e) { - return new Status(IStatus.ERROR, Activator.PLUGIN_ID, "An error occured during generation.", e); - } - } - - public EEFGenModel getEEFEditorGenModel() { - if (eefEditorGenModel instanceof EEFGenModel) { - return (EEFGenModel) eefEditorGenModel; - } else if (eefEditorGenModel instanceof WorkflowVariable) { - return (EEFGenModel) ((WorkflowVariable) eefEditorGenModel).getValue(); - } else { - return null; - } - } - - /** - * Returns the container that the EEFGenModel use as generation directory - * - * @param eefGenModel - * the eefGenModel - * @return the generation directory - * @throws IOException - * an error occurred during container creation - */ - public IContainer getGenContainer(EEFGenModel eefGenModel) throws IOException { - if (eefGenModel != null) { - if (eefGenModel.getGenDirectory() != null) { - final IContainer target = (IContainer) ResourcesPlugin.getWorkspace().getRoot().getFolder(new Path(eefGenModel.getGenDirectory())); - return target; - } - } - return null; - } - - private void clearExistingEditorCode(IProgressMonitor monitor) throws CoreException { - for (GenEditionContext genEditionContext : getEEFEditorGenModel().getEditionContexts()) { - if (genEditionContext.getPropertiesEditionContext() != null && genEditionContext.getPropertiesEditionContext().getModel() != null) { - GenPackage genPackage = (GenPackage)genEditionContext.getPropertiesEditionContext().getModel(); - StringBuilder builder = new StringBuilder(); - builder.append(genPackage.getGenModel().getEditorPluginDirectory()); - builder.append('/'); - builder.append(genPackage.getPresentationPackageName().replaceAll("\\.", "/")); - builder.append('/'); - builder.append(genPackage.getEditorClassName()); - builder.append(".java"); - String qualifiedEditorClass = builder.toString(); - IFile editorClass = ResourcesPlugin.getWorkspace().getRoot().getFile(new Path(qualifiedEditorClass)); - if (editorClass.isAccessible()) { - editorClass.setContents(new ByteArrayInputStream("".getBytes()), true, false, monitor); - } - } - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorContributionTransformer.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorContributionTransformer.java deleted file mode 100644 index 8ab3a2cb0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorContributionTransformer.java +++ /dev/null @@ -1,78 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - - -package org.eclipse.emf.eef.codegen.extended.initializer; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.util.Map; - -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.codegen.core.initializer.AbstractTransformer; -import org.eclipse.emf.eef.components.ComponentsFactory; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput; -import org.eclipse.emf.eef.extended.editor.EEFEditorContributions; -import org.eclipse.emf.eef.extended.editor.EEFPage; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution; -import org.eclipse.emf.eef.views.ViewElement; - -/** - * @author Goulwen Le Fur - * - */ -public class EEFEditorContributionTransformer extends AbstractTransformer { - - - /* ===== Constructor ===== */ - - private Map> workingResolvTemp; - - public EEFEditorContributionTransformer(Map> workingResolvTemp) { - this.workingResolvTemp = workingResolvTemp; - } - - public PropertiesEditionContext genPackage2Context(GenPackage genPackage) { - PropertiesEditionContext context = ComponentsFactory.eINSTANCE.createPropertiesEditionContext(); - context.setModel(genPackage); - context.setDocumentation("Editor contribution for " + genPackage.getEcorePackage().getName() + " GenPackage"); - EEFEditorContributions contributions = EditorFactory.eINSTANCE.createEEFEditorContributions(); - contributions.setName(genPackage.getEcorePackage().getName() + " contributions"); - context.getCategories().add(contributions); - contributions.getBindings().addAll(genPackage2Contributions(genPackage)); - return context; - } - - private Collection genPackage2Contributions(GenPackage genPackage) { - Collection result = new ArrayList(); - StaticEEFEditorContribution eefEditorContribution = EditorFactory.eINSTANCE.createStaticEEFEditorContribution(); - eefEditorContribution.setName("Main contribution"); - workingResolvTemp.get(genPackage.getEcorePackage()); - Collection pages = new ArrayList(); - for (ViewElement viewElement : workingResolvTemp.get(genPackage.getEcorePackage())) { - if (viewElement instanceof EEFPage) { - pages.add((EEFPage) viewElement); - } - } - eefEditorContribution.getViews().addAll(pages); - AllResourcesRootsRelativeInput input = EditorFactory.eINSTANCE.createAllResourcesRootsRelativeInput(); - eefEditorContribution.setInput(input); - result.add(eefEditorContribution); - return result ; - } - - - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorInitializer.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorInitializer.java deleted file mode 100644 index 1fe7b1a3a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorInitializer.java +++ /dev/null @@ -1,252 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.initializer; - -import java.io.IOException; -import java.lang.reflect.InvocationTargetException; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.eef.codegen.core.initializer.AbstractPropertiesInitializer; -import org.eclipse.emf.eef.codegen.core.util.EMFHelper; -import org.eclipse.emf.eef.codegen.extended.flow.CleanEEFEditorSources; -import org.eclipse.emf.eef.codegen.extended.flow.GenerateEEFEditorModels; -import org.eclipse.emf.eef.codegen.extended.flow.OverrideEMFEditorCode; -import org.eclipse.emf.eef.codegen.flow.ConditionalStep; -import org.eclipse.emf.eef.codegen.flow.Workflow; -import org.eclipse.emf.eef.codegen.flow.impl.AddDependency; -import org.eclipse.emf.eef.codegen.flow.impl.GenerateEEFCode; -import org.eclipse.emf.eef.codegen.flow.impl.GenerateEEFModels; -import org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFEditCode; -import org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFEditorCode; -import org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFModelCode; -import org.eclipse.emf.eef.codegen.flow.impl.InitializeGenModel; -import org.eclipse.emf.eef.codegen.flow.impl.MergePluginXML; -import org.eclipse.emf.eef.codegen.flow.util.GenmodelHelper; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.ui.EEFExtendedRuntime; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.jface.dialogs.ProgressMonitorDialog; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.IWorkbenchPartSite; -import org.eclipse.ui.actions.WorkspaceModifyOperation; - -/** - * @author Goulwen Le Fur - */ -public class EEFEditorInitializer extends AbstractPropertiesInitializer { - - private static final String CLEAN_EEF_EDITOR_SOURCE = "Clean EEF editor source"; - - private static final String WORKFLOW_NAME = "Generate EEF Editor"; - - private static final String GENERATING_THE_GENMODEL = "Generating the GenModel"; - - private static final String GENERATE_EMF_MODEL_CODE = "Generate EMF Model Code"; - - private static final String GENERATE_EMF_EDIT_CODE = "Generate EMF Edit Code"; - - private static final String GENERATE_EMF_EDITOR_CODE = "Generate EMF Editor Code"; - - private static final String GENERATE_EEF_MODELS = "Generate EEF models"; - - private static final String ADDING_EEF_RUNTIME_DEPENDENCY = "Adding EEF Runtime dependency"; - - private static final String GENERATE_EEF_CODE = "Generate EEF code"; - - private static final String MERGING_GENERATED_PLUGIN_XML_FILES = "Merging generated plugin.xml files"; - - private static final String GENERATE_EEF_EDITOR_MODELS = "Generate EEF Editor models"; - - private static final String ADDING_EEF_EXTENDED_RUNTIME_DEPENDENCY = "Adding EEF Extended Runtime dependency"; - - private static final String GENERATE_EEF_EDITOR_CODE = "Generate EEF Editor code"; - - private ResourceSet resourceSet; - - private IFile modelFile; - - private IWorkbenchPartSite activeSite; - - public EEFEditorInitializer(IFile selectedFile, IWorkbenchPartSite activeSite) { - this.modelFile = selectedFile; - this.activeSite = activeSite; - } - -/** - * {@inheritDoc] - * @throws Exception - * @see org.eclipse.emf.eef.codegen.core.initializer.IPropertiesInitializer#initialize(org.eclipse.emf.common.util.URI, org.eclipse.core.resources.IContainer) - */ - public void initialize(URI modelURI, IContainer targetFolder) throws Exception { - resourceSet = new ResourceSetImpl(); - registerResourceFactories(resourceSet); - registerPackages(resourceSet); - EObject model = EMFHelper.load(modelURI, resourceSet); - if (model instanceof EPackage) { - final Workflow workflow = new Workflow(WORKFLOW_NAME, activeSite.getShell()); - workflow.setResourceSet(resourceSet); - final GenmodelHelper helper = new GenmodelHelper(resourceSet, modelFile, targetFolder); - CleanEEFEditorSources cleanEEFEditorSources = new CleanEEFEditorSources(CLEAN_EEF_EDITOR_SOURCE, - modelFile, targetFolder); - ConditionalStep conditon = new ConditionalStep(cleanEEFEditorSources) { - - @Override - public boolean condition() { - return helper.getGenModelFile().isAccessible(); - } - }; - workflow.addStep(CLEAN_EEF_EDITOR_SOURCE, conditon); - // Step 1 : Generate GenModel - InitializeGenModel initializeGenModelStep = new InitializeGenModel(GENERATING_THE_GENMODEL, - modelFile, targetFolder, helper.genmodelFileName()) { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.flow.Step#validateExecution() - */ - public boolean validateExecution() { - boolean genmodelExists = helper.getGenModelFile().exists(); - if (genmodelExists) { - try { - ((WorkflowVariable)getGenModelURI()).setValue(helper.genmodelURI()); - ((WorkflowVariable)genmodel()).setValue(EMFHelper.load(helper.genmodelURI(), - resourceSet)); - } catch (IOException e) { - EEFExtendedRuntime.INSTANCE.log(e); - return true; - } - } - return !genmodelExists; - } - - /** - * {@inheritDoc] - * @see org.eclipse.emf.eef.codegen.flow.impl.InitializeGenModel#configureGenModel(org.eclipse.emf.codegen.ecore.genmodel.GenModel) - */ - public void configureGenModel(GenModel genModel) { - genModel.setModelDirectory(genModel.getModelDirectory() + "-gen"); - genModel.setEditDirectory(genModel.getEditDirectory() + "-gen"); - genModel.setEditorDirectory(genModel.getEditorDirectory() + "-gen"); - } - - }; - workflow.addStep(GENERATING_THE_GENMODEL, initializeGenModelStep); - // Step 2 : Generate EMF Code - GenerateEMFModelCode generateEMFModelCode = new GenerateEMFModelCode(GENERATE_EMF_MODEL_CODE, - initializeGenModelStep.genmodel()); - workflow.addStep(GENERATE_EMF_MODEL_CODE, generateEMFModelCode); - GenerateEMFEditCode generateEMFEditCode = new GenerateEMFEditCode(GENERATE_EMF_EDIT_CODE, - initializeGenModelStep.genmodel()); - workflow.addStep(GENERATE_EMF_EDIT_CODE, generateEMFEditCode); - GenerateEMFEditorCode generateEMFEditorCode = new GenerateEMFEditorCode(GENERATE_EMF_EDITOR_CODE, - initializeGenModelStep.genmodel()); - workflow.addStep(GENERATE_EMF_EDITOR_CODE, generateEMFEditorCode); - // Step 3 : Generate EEF model - GenerateEEFModels generateEEFModels = new GenerateEEFModels(GENERATE_EEF_MODELS, modelURI, - generateEMFEditCode.genProject(), initializeGenModelStep.getGenModelURI(), - helper.eefmodelsFolderPath()) { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.flow.Step#validateExecution() - */ - public boolean validateExecution() { - boolean modelsExist = helper.getEEFPropertiesComponentsModel().exists() - && helper.getEEFPropertiesEEFGenModel().exists(); - if (modelsExist) { - try { - ((WorkflowVariable)getEEFModelsFolder()).setValue(helper.getEEFModelsFolder()); - ((WorkflowVariable)getEEFGenModel()).setValue(EMFHelper.load( - GenmodelHelper.computePropertiesEEFGenModelURI( - helper.getEEFModelsFolder(), helper.genmodelURI()), resourceSet)); - } catch (IOException e) { - EEFExtendedRuntime.INSTANCE.log(e); - return true; - } - } - return !modelsExist; - } - - }; - workflow.addStep(GENERATE_EEF_MODELS, generateEEFModels); - // Step 4 : Add EEF Runtime dependency - AddDependency addDependency = new AddDependency(ADDING_EEF_RUNTIME_DEPENDENCY, - generateEMFEditCode.genProject(), EEFRuntimePlugin.PLUGIN_ID); - workflow.addStep(ADDING_EEF_RUNTIME_DEPENDENCY, addDependency); - GenerateEEFCode generateEEFCode = new GenerateEEFCode(GENERATE_EEF_CODE, - generateEEFModels.getEEFGenModel()); - // JDTImportsOrganisationCallback callback = new JDTImportsOrganisationCallback(activeSite); - // generateEEFCode.addGenerationCallback(callback); - workflow.addStep(GENERATE_EEF_CODE, generateEEFCode); - // Step 6 : Adding Extension Point - MergePluginXML mergePluginXML = new MergePluginXML(MERGING_GENERATED_PLUGIN_XML_FILES, - generateEMFEditCode.genProject()); - workflow.addStep(MERGING_GENERATED_PLUGIN_XML_FILES, mergePluginXML); - final GenerateEEFEditorModels generateEEFEditorModels = new GenerateEEFEditorModels( - GENERATE_EEF_EDITOR_MODELS, modelURI, generateEMFEditCode.genProject(), - initializeGenModelStep.getGenModelURI(), generateEEFModels.getEEFModelsFolder()) { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.flow.Step#validateExecution() - */ - public boolean validateExecution() { - boolean modelsExist = helper.getEEFEditorComponentsModel().exists() - && helper.getEEFEditorEEFGenModel().exists(); - if (modelsExist) { - try { - ((WorkflowVariable)getEEFGenModel()).setValue(EMFHelper.load(GenmodelHelper - .computeEditorEEFGenModelURI(helper.getEEFModelsFolder(), - helper.genmodelURI()), resourceSet)); - } catch (IOException e) { - EEFExtendedRuntime.INSTANCE.log(e); - return true; - } - } - return !modelsExist; - } - - }; - workflow.addStep(GENERATE_EEF_EDITOR_MODELS, generateEEFEditorModels); - AddDependency addExtendedRuntimeDependency = new AddDependency( - ADDING_EEF_EXTENDED_RUNTIME_DEPENDENCY, generateEMFEditorCode.genProject(), - EEFExtendedRuntime.PLUGIN_ID); - workflow.addStep(ADDING_EEF_EXTENDED_RUNTIME_DEPENDENCY, addExtendedRuntimeDependency); - OverrideEMFEditorCode generateEEFEditorCode = new OverrideEMFEditorCode(GENERATE_EEF_EDITOR_CODE, - generateEEFEditorModels.getEEFGenModel()); - workflow.addStep(GENERATE_EEF_EDITOR_CODE, generateEEFEditorCode); - if (workflow.prepare()) { - WorkspaceModifyOperation runnable = new WorkspaceModifyOperation() { - - public void execute(IProgressMonitor monitor) throws InvocationTargetException, - InterruptedException { - workflow.execute(monitor); - } - }; - new ProgressMonitorDialog(EditingUtils.getShell()).run(true, true, runnable); - } - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorModelInitializer.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorModelInitializer.java deleted file mode 100644 index 4eff75ca7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFEditorModelInitializer.java +++ /dev/null @@ -1,173 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.initializer; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.eef.EEFGen.EEFGenFactory; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; -import org.eclipse.emf.eef.codegen.core.initializer.AbstractPropertiesInitializer; -import org.eclipse.emf.eef.codegen.core.util.EMFHelper; -import org.eclipse.emf.eef.codegen.flow.util.GenmodelHelper; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.views.ViewsRepository; - -/** - * @author Goulwen Le Fur - * - */ -public class EEFEditorModelInitializer extends AbstractPropertiesInitializer { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.core.initializer.IPropertiesInitializer#initialize(org.eclipse.emf.common.util.URI, org.eclipse.core.resources.IContainer) - */ - public void initialize(URI modelURI, IContainer targetFolder) throws IOException, CoreException { - ResourceSet resourceSet = new ResourceSetImpl(); - registerResourceFactories(resourceSet); - registerPackages(resourceSet); - EObject model = EMFHelper.load(modelURI, resourceSet); - - if (!targetFolder.exists()) { - if (targetFolder instanceof IFolder) - ((IFolder)targetFolder).create(true, true, new NullProgressMonitor()); - else - return; - } - EEFPagesTransformer pagesTransformer = new EEFPagesTransformer(); - TreeIterator allContents = model.eAllContents(); - Map repositories = new HashMap(); - List contexts = new ArrayList(); - while (allContents.hasNext()) { - EObject next = allContents.next(); - if (next instanceof GenPackage) { - GenPackage genPack = (GenPackage)next; - if (genPack.eContents().size() >= 1) { - ViewsRepository repository = pagesTransformer.genPackage2ViewsRepository(genPack); - String completePackage = genPack.getBasePackage(); - if (completePackage != null && completePackage.length() > 0) { - completePackage += "." + ecoreStringHierarchy(genPack); - } else { - completePackage = ecoreStringHierarchy(genPack); - } - repositories.put(repository, completePackage); - EEFEditorContributionTransformer contributionTransformer = new EEFEditorContributionTransformer(pagesTransformer.getWorkingResolvTemp()); - PropertiesEditionContext context = contributionTransformer.genPackage2Context(genPack); - contexts.add(context); - } - } - } - - URI contributionsModelUri = GenmodelHelper.computeEditorComponentsModelURI(targetFolder, model.eResource().getURI()); - Resource contributionsResource = model.eResource().getResourceSet().createResource(contributionsModelUri); - for (PropertiesEditionContext context : contexts) - contributionsResource.getContents().add(context); - for (ViewsRepository repository : repositories.keySet()) - contributionsResource.getContents().add(repository); - EEFGenModel eefGenModel = createEEFGenModel((GenModel) model, repositories, contexts, targetFolder); - contributionsResource.save(Collections.EMPTY_MAP); - URI eefgenModelUri = GenmodelHelper.computeEditorEEFGenModelURI(targetFolder, model.eResource().getURI()); - Resource eefgenResource = model.eResource().getResourceSet().createResource(eefgenModelUri); - eefgenResource.getContents().add(eefGenModel); - eefgenResource.save(Collections.EMPTY_MAP); - return; - - } - - public String ecoreStringHierarchy(GenPackage genPack) { - String result = ""; - List ecorePackageHierarchy = ecorePackageHierarchy(genPack); - for (int i = ecorePackageHierarchy.size() - 1; i >= 0; i--) { - EPackage next = ecorePackageHierarchy.get(i); - result += next.getName(); - if (i > 0) - result += "."; - } - return genPack.getEcorePackage().getName(); - } - - public List ecorePackageHierarchy(GenPackage genPack) { - List hierarchy = new ArrayList(); - EObject current = genPack.getEcorePackage(); - while (current instanceof EPackage) { - hierarchy.add((EPackage) current); - current = current.eContainer(); - } - return hierarchy; - } - - private EEFGenModel createEEFGenModel(GenModel inputGenmodel, Map repositories, List contexts, IContainer targetFolder) { - EEFGenModel eefGenModel = EEFGenFactory.eINSTANCE.createEEFGenModel(); - eefGenModel.setGenDirectory(findGenDirectory(inputGenmodel)); - for (PropertiesEditionContext context : contexts) - eefGenModel.getEditionContexts().add(createGenEditionContext(context)); - String contextPackage = ""; - if (contexts.size() > 0) { - String findBasePackage = findBasePackage(contexts.get(0).getModel()); - if (findBasePackage != null && !findBasePackage.equals("")) { - contextPackage = findBasePackage + "."; - } - contextPackage = contextPackage + contexts.get(0).getModel().getEcorePackage().getName().toLowerCase(); - } - for (ViewsRepository repository : repositories.keySet()) - eefGenModel.getViewsRepositories().add(createGenViewsRepository(repository, repositories.get(repository))); - return eefGenModel; - } - - private GenEditionContext createGenEditionContext(PropertiesEditionContext context) { - GenEditionContext genEditionContext = EEFGenFactory.eINSTANCE.createGenEditionContext(); - genEditionContext.setPropertiesEditionContext(context); - if (context.getModel() != null) - genEditionContext.setBasePackage(findBasePackage(context.getModel())); - genEditionContext.setDescriptorsGenericPropertiesViews(true); - return genEditionContext; - } - - private GenViewsRepository createGenViewsRepository(ViewsRepository repository, String contextPackage) { - GenViewsRepository genViewsRepository = EEFGenFactory.eINSTANCE.createGenViewsRepository(); - genViewsRepository.setViewsRepository(repository); - genViewsRepository.setBasePackage(contextPackage); - genViewsRepository.setSwtViews(true); - genViewsRepository.setFormViews(true); - return genViewsRepository; - } - - private String findBasePackage(GenPackage genPackage) { - if (genPackage.getBasePackage() != null) - return genPackage.getBasePackage(); - return ""; - } - - private String findGenDirectory(GenModel genmodel) { - return genmodel.getEditorDirectory(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFPagesTransformer.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFPagesTransformer.java deleted file mode 100644 index 8456ffec3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/initializer/EEFPagesTransformer.java +++ /dev/null @@ -1,86 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.initializer; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.common.util.UniqueEList; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.codegen.core.initializer.AbstractTransformer; -import org.eclipse.emf.eef.extended.editor.EEFEditorPages; -import org.eclipse.emf.eef.extended.editor.EEFPage; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.extended.editor.TreeMasterPage; -import org.eclipse.emf.eef.views.ViewElement; -import org.eclipse.emf.eef.views.ViewsFactory; -import org.eclipse.emf.eef.views.ViewsRepository; - -/** - * @author Goulwen Le Fur - * - */ -public class EEFPagesTransformer extends AbstractTransformer { - - private Map> workingResolvTemp; - private ViewsRepository repository; - - public EEFPagesTransformer() { - workingResolvTemp = new HashMap>(); - } - - public Map> getWorkingResolvTemp() { - return workingResolvTemp; - } - - public void addElementToEObject(EObject source, ViewElement element) { - if (workingResolvTemp.get(source) != null) - workingResolvTemp.get(source).add(element); - else { - List list = new UniqueEList(); - list.add(element); - workingResolvTemp.put(source, list); - } - } - - public ViewsRepository genPackage2ViewsRepository(GenPackage genPackage) { - repository = ViewsFactory.eINSTANCE.createViewsRepository(); - repository.getRepositoryKind().add("Editor"); - repository.setName(genPackage.getEcorePackage().getName() + " editor"); - repository.setDocumentation("Editor pages for " + genPackage.getEcorePackage().getName() + " GenPackage"); - EEFEditorPages editorPages = EditorFactory.eINSTANCE.createEEFEditorPages(); - editorPages.setName(genPackage.getEcorePackage().getName() + " editor pages"); - repository.getCategories().add(editorPages); - editorPages.getViews().addAll(genPackage2EditorPages(genPackage)); - - return repository; - - } - - /** - * @param genPackage - * @return - */ - private Collection genPackage2EditorPages(GenPackage genPackage) { - Collection result = new ArrayList(); - TreeMasterPage mainPage = EditorFactory.eINSTANCE.createTreeMasterPage(); - mainPage.setName("main"); - mainPage.setTitle(genPackage.getEcorePackage().getName()); - addElementToEObject(genPackage.getEcorePackage(), mainPage); - result.add(mainPage); - return result; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/launcher/GenerateAll.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/launcher/GenerateAll.java deleted file mode 100644 index 6966a4a3e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/launcher/GenerateAll.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.launcher; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Set; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.launcher.AbstractPropertiesGeneratorLauncher; -import org.eclipse.emf.eef.codegen.core.services.PropertiesGeneratorLaunchersServices; - -/** - * @author Goulwen Le Fur - * - */ -public class GenerateAll { - - - public GenerateAll() { - } - - - public void doGenerate(EEFGenModel eefGenModel, IContainer target, IProgressMonitor monitor) throws IOException { - Set generationTargets = new LinkedHashSet(); - generationTargets.add(target); - try { - final EEFEditorLauncher generator = new EEFEditorLauncher(eefGenModel, target.getLocation().toFile(), new ArrayList()); - generator.doGenerate(BasicMonitor.toMonitor(monitor)); - List launchers = PropertiesGeneratorLaunchersServices.getInstance().getlaunchers(); - for (AbstractPropertiesGeneratorLauncher abstractPropertiesGeneratorLauncher : launchers) { - EObject inputModel = generator.getModel(); - if (inputModel instanceof EEFGenModel) { - abstractPropertiesGeneratorLauncher.doGenerate(eefGenModel,generator.getTargetFolder(),monitor); - if (!abstractPropertiesGeneratorLauncher.getTargetContainer().isEmpty()) - generationTargets.addAll(abstractPropertiesGeneratorLauncher.getTargetContainer()); - } - } - } catch (IOException e) { - EEFCodegenPlugin.getDefault().logError(e); - } - - // Desactivation of Acceleo Traceability - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/initializer/InitializeEEFEditorAction.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/initializer/InitializeEEFEditorAction.java deleted file mode 100644 index a7c907b80..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/initializer/InitializeEEFEditorAction.java +++ /dev/null @@ -1,115 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.ui.initializer; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.IAdaptable; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.initializer.AbstractPropertiesInitializer; -import org.eclipse.emf.eef.codegen.core.util.EMFHelper; -import org.eclipse.emf.eef.codegen.extended.initializer.EEFEditorInitializer; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.ui.IEditorActionDelegate; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IObjectActionDelegate; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.IWorkbenchPartSite; - -/** - * @author Goulwen Le Fur - * - */ -public class InitializeEEFEditorAction implements IObjectActionDelegate, IEditorActionDelegate { - - private URI modelURI; - - private IFile selectedFile = null; - - private IWorkbenchPartSite activeSite; - - /** - * - */ - public InitializeEEFEditorAction() { - super(); - } - - /** - * {@inheritDoc] - * @see org.eclipse.ui.IActionDelegate#run(org.eclipse.jface.action.IAction) - */ - public void run(IAction action) { - if (selectedFile != null) { - try { - modelURI = URI.createURI("platform:/resource" + selectedFile.getFullPath()); - IContainer container = selectedFile.getParent(); - AbstractPropertiesInitializer initializer = new EEFEditorInitializer(selectedFile, activeSite); - initializer.initialize(modelURI, container); - container.refreshLocal(IResource.DEPTH_INFINITE, new NullProgressMonitor()); - } catch (Exception e) { - EEFCodegenPlugin.getDefault().logError(e); - } - - } - - } - - /** - * {@inheritDoc] - * @see org.eclipse.ui.IActionDelegate#selectionChanged(org.eclipse.jface.action.IAction, org.eclipse.jface.viewers.ISelection) - */ - public void selectionChanged(IAction action, ISelection selection) { - if (selection instanceof StructuredSelection) { - StructuredSelection sSelection = (StructuredSelection)selection; - Object selectedElement = sSelection.getFirstElement(); - if (selectedElement instanceof IFile) { - this.selectedFile = (IFile)selectedElement; - } else if (selectedElement instanceof IAdaptable) { - EObject eObject = (EObject) ((IAdaptable)selectedElement).getAdapter(EObject.class); - if (eObject != null) { - // We use the ability of a GMF EditPart to be adapted into the semantic EObject - if (eObject.eResource().getURI().fileExtension().equals("ecore")) { - IFile associatedFile = EMFHelper.associatedFile(eObject); - if (associatedFile.isAccessible()) { - this.selectedFile = associatedFile; - } - } - } - } - } - } - - /** - * {@inheritDoc] - * @see org.eclipse.ui.IObjectActionDelegate#setActivePart(org.eclipse.jface.action.IAction, org.eclipse.ui.IWorkbenchPart) - */ - public void setActivePart(IAction action, IWorkbenchPart targetPart) { - this.activeSite = targetPart.getSite(); - } - - /** - * {@inheritDoc} - * @see org.eclipse.ui.IEditorActionDelegate#setActiveEditor(org.eclipse.jface.action.IAction, org.eclipse.ui.IEditorPart) - */ - public void setActiveEditor(IAction action, IEditorPart targetEditor) { - if (targetEditor != null) { - this.activeSite = targetEditor.getSite(); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/initializer/InitializeEEFEditorModelsAction.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/initializer/InitializeEEFEditorModelsAction.java deleted file mode 100755 index ed80271b5..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/initializer/InitializeEEFEditorModelsAction.java +++ /dev/null @@ -1,99 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.ui.initializer; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.initializer.AbstractPropertiesInitializer; -import org.eclipse.emf.eef.codegen.extended.initializer.EEFEditorModelInitializer; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.IActionDelegate; -import org.eclipse.ui.IObjectActionDelegate; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.dialogs.ContainerSelectionDialog; - -/** - * @author Goulwen Le Fur - */ -public class InitializeEEFEditorModelsAction implements IObjectActionDelegate { - - private Shell shell; - - private URI modelURI; - - private IFile selectedFile = null; - - /** - * Constructor for Action1. - */ - public InitializeEEFEditorModelsAction() { - super(); - } - - /** - * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart) - */ - public void setActivePart(IAction action, IWorkbenchPart targetPart) { - shell = targetPart.getSite().getShell(); - } - - /** - * @see IActionDelegate#run(IAction) - */ - public void run(IAction action) { - if (selectedFile != null) { - ContainerSelectionDialog dialog = new ContainerSelectionDialog(shell, selectedFile.getParent(),false, "Select a destination container for models :"); - dialog.setTitle("Container Selection"); - dialog.open(); - Object[] result = dialog.getResult(); - if (result != null && result.length >= 1) { - try { - IContainer container; - IPath path = (IPath)result[0]; - if (path.segmentCount() == 1) { - container = (IContainer)ResourcesPlugin.getWorkspace().getRoot().getProject(path.toString()); - } else { - container = (IContainer)ResourcesPlugin.getWorkspace().getRoot().getFolder(path); - } - modelURI = URI.createPlatformResourceURI(selectedFile.getFullPath().toString(), false); - AbstractPropertiesInitializer initializer = new EEFEditorModelInitializer(); - initializer.initialize(modelURI, container); - container.refreshLocal(IResource.DEPTH_INFINITE, new NullProgressMonitor()); - } catch (Exception e) { - EEFCodegenPlugin.getDefault().logError(e); - } - } - } - } - - /** - * @see IActionDelegate#selectionChanged(IAction, ISelection) - */ - public void selectionChanged(IAction action, ISelection selection) { - if (selection instanceof StructuredSelection) { - StructuredSelection sSelection = (StructuredSelection)selection; - if (sSelection.getFirstElement() instanceof IFile) { - this.selectedFile = (IFile)sSelection.getFirstElement(); - } - - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/launcher/GenerateEEFEditorAction.java b/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/launcher/GenerateEEFEditorAction.java deleted file mode 100755 index f53fb1d81..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src-custom/org/eclipse/emf/eef/codegen/extended/ui/launcher/GenerateEEFEditorAction.java +++ /dev/null @@ -1,248 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.ui.launcher; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collections; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Set; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.core.runtime.jobs.Job; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenModelReference; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.extended.flow.OverrideEMFEditorCode; -import org.eclipse.emf.eef.codegen.flow.Workflow; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.IActionDelegate; -import org.eclipse.ui.IObjectActionDelegate; -import org.eclipse.ui.IWorkbenchPart; - -/** - * @author Stephane Bouchet - */ -public class GenerateEEFEditorAction implements IObjectActionDelegate { - - private static final String GENERATE_EEF_EDITOR = "Generate EEF Editor for "; - - /** - * @deprecated see bug #370409 - */ - private Shell shell; - - protected Set selectedFiles; - - /** - * the list of eefgenmodels - * - * @deprecated since a job is used to generates files - */ - protected List eefGenModels; - - /** - * Constructor. - */ - public GenerateEEFEditorAction() { - selectedFiles = new LinkedHashSet(); - } - - /** - * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart) - * @deprecated see bug #370409 - */ - public void setActivePart(IAction action, IWorkbenchPart targetPart) { - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.IActionDelegate#run(org.eclipse.jface.action.IAction) - */ - public void run(IAction action) { - if (selectedFiles != null) { - try { - List eefgenmodels = initEEFGenModel(); - - final Workflow flow = new Workflow("Generate EEF Editors", shell); - for (final EEFGenModel eefGenModel : eefgenmodels) { - String key = GENERATE_EEF_EDITOR + eefGenModel.eResource().getURI().toString(); - OverrideEMFEditorCode eefEditorCode = new OverrideEMFEditorCode(key, eefGenModel); - flow.addStep(key, eefEditorCode); - } - flow.prepare(); - Job job = new Job("EEF editors generation") { - - @Override - protected IStatus run(IProgressMonitor monitor) { - flow.execute(monitor); - monitor.done(); - selectedFiles.clear(); - return Status.OK_STATUS; - } - - }; - job.setUser(true); - // lock the workspace to avoid concurrent modification - job.setRule(ResourcesPlugin.getWorkspace().getRoot()); - job.schedule(); - } catch (IOException e) { - EEFCodegenPlugin.getDefault().logError(e); - } - } - } - - /** - * @see IActionDelegate#selectionChanged(IAction, ISelection) - */ - public void selectionChanged(IAction action, ISelection selection) { - selectedFiles.clear(); - if (selection instanceof StructuredSelection) { - StructuredSelection sSelection = (StructuredSelection)selection; - for (Object selectedElement : sSelection.toList()) { - if (selectedElement instanceof IFile) { - this.selectedFiles.add((IFile)selectedElement); - } - } - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.ui.generators.actions.AbstractGenerateEEFAction#inutEEFGenModel() - */ - protected List initEEFGenModel() throws IOException { - List eefgenmodels = new ArrayList(selectedFiles.size()); - if (!selectedFiles.isEmpty()) { - ResourceSet resourceSet = new ResourceSetImpl(); - for (IFile selectedFile : selectedFiles) { - URI modelURI = URI.createPlatformResourceURI(selectedFile.getFullPath().toString(), true); - String fileExtension = modelURI.fileExtension(); - if (fileExtension == null || fileExtension.length() == 0) { - fileExtension = Resource.Factory.Registry.DEFAULT_EXTENSION; - } - final Resource.Factory.Registry registry = Resource.Factory.Registry.INSTANCE; - final Object resourceFactory = registry.getExtensionToFactoryMap().get(fileExtension); - if (resourceFactory != null) { - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap() - .put(fileExtension, resourceFactory); - } else { - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap() - .put(fileExtension, new XMIResourceFactoryImpl()); - } - Resource res = resourceSet.createResource(modelURI); - res.load(Collections.EMPTY_MAP); - EcoreUtil.resolveAll(resourceSet); - if (res.getContents().size() > 0) { - EObject object = res.getContents().get(0); - if (object instanceof EEFGenModel) { - eefgenmodels.add((EEFGenModel)object); - } - } - } - } - // validate eefgenmodels and components recursively - return validateEEFGenmodels(eefgenmodels); - } - - /** - * @param eefgenmodels - * @return - * @since 2.0 - */ - private List validateEEFGenmodels(List eefgenmodels) { - List eefModels = new ArrayList(eefgenmodels.size()); - eefModels.addAll(eefgenmodels); - for (EEFGenModel eefGenModel : eefgenmodels) { - if (!validateOneEEFGenModel(eefGenModel)) - eefModels.remove(eefGenModel); - // validate also referenced EEFGenModels - if (!validateReferencedEEFGenModels(eefGenModel)) - eefModels.remove(eefGenModel); - } - return eefModels; - } - - /** - * @param eefGenModel - */ - private boolean validateReferencedEEFGenModels(EEFGenModel eefGenModel) { - for (EEFGenModelReference eefGenModelReference : eefGenModel.getReferences()) { - EEFGenModel referencedEEFGenModel = eefGenModelReference.getReferencedContext(); - if (!validateOneEEFGenModel(referencedEEFGenModel)) - return false; - return validateReferencedEEFGenModels(referencedEEFGenModel); - } - return true; - } - - /** - * @param eefGenModel - * @return - * @since 2.0 - */ - private boolean validateOneEEFGenModel(EEFGenModel eefGenModel) { - // validate eefgenmodels - final Diagnostic diag = Diagnostician.INSTANCE.validate(eefGenModel); - if (diag.getSeverity() != Diagnostic.OK) { - Status status = new Status(diag.getSeverity(), EEFCodegenPlugin.PLUGIN_ID, "EEFGenmodel '" - + eefGenModel.eResource().getURI() + "' contains errors."); - EEFCodegenPlugin.getDefault().getLog().log(status); - return false; - } - // validate PropertiesEditionContext - for (GenEditionContext genEditionContext : eefGenModel.getEditionContexts()) { - final Diagnostic diag2 = Diagnostician.INSTANCE.validate(genEditionContext - .getPropertiesEditionContext()); - if (diag2.getSeverity() != Diagnostic.OK) { - Status status = new Status(diag2.getSeverity(), EEFCodegenPlugin.PLUGIN_ID, - "PropertiesEditionContext '" - + genEditionContext.getPropertiesEditionContext().eResource().getURI() - + "' contains errors."); - EEFCodegenPlugin.getDefault().getLog().log(status); - return false; - } - } - // validate ViewsRepository - for (GenViewsRepository genViewsRepository : eefGenModel.getViewsRepositories()) { - final Diagnostic diag2 = Diagnostician.INSTANCE.validate(genViewsRepository.getViewsRepository()); - if (diag2.getSeverity() != Diagnostic.OK) { - Status status = new Status(diag2.getSeverity(), EEFCodegenPlugin.PLUGIN_ID, - "ViewsRepository '" + genViewsRepository.getViewsRepository().eResource().getURI() - + "' contains errors."); - EEFCodegenPlugin.getDefault().getLog().log(status); - return false; - } - } - return true; - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/Activator.java b/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/Activator.java deleted file mode 100644 index c4ba5f593..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/Activator.java +++ /dev/null @@ -1,64 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended; - -import org.eclipse.core.runtime.Plugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle. - */ -public class Activator extends Plugin { - - /** - * The plug-in ID. - */ - public static final String PLUGIN_ID = "org.eclipse.emf.eef.codegen.extended"; - - /** - * The shared instance. - */ - private static Activator plugin; - - /** - * The constructor. - */ - public Activator() { - } - - /**{@inheritDoc} - * - * @see org.eclipse.core.runtime.Plugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - /**{@inheritDoc} - * - * @see org.eclipse.core.runtime.Plugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance. - * - * @return the shared instance - */ - public static Activator getDefault() { - return plugin; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/editor/api/EditorContribution.mtl b/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/editor/api/EditorContribution.mtl deleted file mode 100644 index 1103bf105..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/editor/api/EditorContribution.mtl +++ /dev/null @@ -1,145 +0,0 @@ -[comment encoding = UTF-8 /] -[module EditorContribution('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/extended/editor/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/eef/extended/query/1.0.0','http://www.eclipse.org/emf/eef/mapping/filters/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::extended::query::oclquery /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment =================== API ===================== /] - -[template public editorInput(input : EEFPageInput)] -//FIXME: Input of type [input.eClass().name/] not managed. Override 'editorInput' template into EditorContribution to fix this. -[/template] - -[template public filterDeclaration(filter : BindingFilter)] -//FIXME: Input of type [filter.eClass().name/] not managed. Override 'filterDeclaration' template into EditorContribution to fix this. -[/template] - -[template public editorPage(page : EEFPage, editorName : String)] -//FIXME: Input of type [page.eClass().name/] not managed. Override 'editorPage' template into EditorContribution to fix this. -[/template] - -[comment =================== Editor Input implementations ===================== /] -[template public editorInput(input : AllResourcesRootsRelativeInput)] - [if (input.query.oclIsUndefined())] -Object input = getEditingDomain().getResourceSet(); - [else] -//FIXME: input not processed - [/if] -[/template] - -[template public editorInput(input : FirstResourceRootRelativeInput)] -Object input = null; - [if (input.query.oclIsUndefined())] -if (getEditingDomain().getResourceSet() != null && getEditingDomain().getResourceSet().getResources().size() > 0) { - input = getEditingDomain().getResourceSet().getResources().get(0); -} - [else] -if (getEditingDomain().getResourceSet() != null && getEditingDomain().getResourceSet().getResources().size() > 0) { - Resource resource = getEditingDomain().getResourceSet().getResources().get(0); - if (resource.getContents() != null && resource.getContents().size() > 0) { - EObject element = resource.getContents().get(0); - [input.query.content()/] - } -} - [/if] -[/template] - -[comment =================== Filters implementations ===================== /] -[template public filterImports(peContext : PropertiesEditionContext, filterType : EClass) ? (filterType.name = 'PartFilter')] -[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.ui.viewers.filters.PropertiesEditionPartFilter'})/] -[/template] - -[template public filterDeclaration(filter : PartFilter)] -filters.add(new PropertiesEditionPartFilter("[filter.filteredPart.viewKey(filter.contextualComponent)/]")); -[/template] - -[template public filterImports(peContext : PropertiesEditionContext, filterType : EClass) ? (filterType.name = 'OCLFilter')] -[addImports(Sequence{ - 'org.eclipse.emf.ecore.EcorePackage', - 'org.eclipse.jface.viewers.Viewer', - 'org.eclipse.emf.eef.runtime.query.QueryWrapper'})/] -[/template] - -[template public filterDeclaration(filter : OCLFilter)] -filters.add(new ViewerFilter() { - public boolean select(Viewer viewer, Object parentElement, Object element) { - if (element instanceof EObject) { - final QueryWrapper query = new OCLQuery(EcorePackage.eINSTANCE.getEObject(), "[filter.OCLBody/]"); - if (EEFExtendedRuntime.INSTANCE.getProcessor().canEvaluate(query)) { - final QueryResult evaluate = EEFExtendedRuntime.INSTANCE.getProcessor().evaluate((EObject) element, query); - if (evaluate.evaluationStatus.isOK()) { - return (Boolean)evaluate.evaluationResult; - } - } - } - return true; - } - }); -[/template] - -[comment =================== Editor page implementations ===================== /] -[template public pageImports(peContext : PropertiesEditionContext, pageType : EClass) ? (pageType.name = 'TreeMasterPage')] -[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.ui.editors.pages.tree.EEFTreeMDFormPage', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.swt.widgets.Composite'})/] -[/template] - -[template public editorPage(page : TreeMasterPage, editorName : String)] -final EEFTreeMDFormPage page = new EEFTreeMDFormPage([editorName/].this, "[page.name/]") { - - /** - * {@inheritDoc} - * @see org.eclipse.ui.forms.editor.FormPage#createPartControl(org.eclipse.swt.widgets.Composite) - */ - public void createPartControl(Composite parent) { - super.createPartControl(parent); - getModelViewer().addSelectionChangedListener(new ISelectionChangedListener() { - // This just notifies those things that are affected by the section. - // - public void selectionChanged(SelectionChangedEvent selectionChangedEvent) { - [editorName/].this.setSelection(selectionChangedEvent.getSelection()); - } - } - - ); - } - -}; -page.setInitialMasterPartToolBarVisibility([page.toolbarVisible/]); -page.setAdapterFactory(adapterFactory); -page.setEditingDomain(editingDomain); -[/template] - -[template public pageImports(peContext : PropertiesEditionContext, pageType : EClass) ? (pageType.name = 'StandardFormPage')] -[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.ui.editors.pages.EEFStandardFormPage'})/] -[/template] - -[template public editorPage(page : StandardFormPage, editorName : String)] -final EEFStandardFormPage page = new EEFStandardFormPage([editorName/].this, "[page.name/]"); -[if ((not page.title.oclIsUndefined()) and (page.title.size() > 0))] -page.setPageTitle("[page.title/]"); -[/if] -page.setAdapterFactory(adapterFactory); -page.setEditingDomain(editingDomain); -[/template] - -[template public pageImports(peContext : PropertiesEditionContext, pageType : EClass) ? (pageType.name = 'EEFMasterPage')] -[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.ui.editors.pages.eefviewer.EEFPropertiesViewerMDFormPage'})/] -[/template] - -[template public editorPage(page : EEFMasterPage, editorName : String)] -final EEFPropertiesViewerMDFormPage page = new EEFPropertiesViewerMDFormPage([editorName/].this, "[page.name/]", true, true); -page.setAdapterFactory(adapterFactory); -page.setEditingDomain(editingDomain); -[if ((not page.title.oclIsUndefined()) and (page.title.size() > 0))] -page.setPageTitle("[page.title/]"); -[/if] -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/files/EEFEditor.mtl b/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/files/EEFEditor.mtl deleted file mode 100644 index 15d8bbc0c..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/files/EEFEditor.mtl +++ /dev/null @@ -1,136 +0,0 @@ -[comment encoding = UTF-8 /] -[module EEFEditor('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/extended/editor/1.0.0', 'http://www.eclipse.org/emf/eef/extended/query/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel','http://www.eclipse.org/emf/eef/mapping/filters/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::extended::query::oclquery /] -[import org::eclipse::emf::eef::codegen::extended::services::editor-common /] -[import org::eclipse::emf::eef::codegen::extended::editor::api::EditorContribution /] -[import org::eclipse::emf::eef::codegen::services::imports /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenModel /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::editor::Editor /] - -[template public generateEditor(peContext : PropertiesEditionContext)] -[peContext.initializeImportManager(peContext.model.presentationPackage(), model.editorClassName())/] - -[for (pageType : EClass | peContext.categories.bindings.views.eClass()->asOrderedSet())] -[peContext.pageImports(pageType)/] -[/for] - -[for (filterType : EClass | peContext.categories.bindings.bindingFilters.eClass()->asOrderedSet())] -[peContext.filterImports(filterType)/] -[/for] - -[for (queryType : EClass | peContext.eAllContents(EEFUnderstandableQuery).eClass()->asOrderedSet())] -[peContext.queryImports(queryType)/] -[/for] - - [file (peContext.fullFilePath(), false, 'UTF-8')] -/** - * - * - * - */ -package [peContext.model.presentationPackage()/];[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.ui.EEFExtendedRuntime', - 'org.eclipse.emf.eef.runtime.ui.editor.InteractiveEEFEditor', - 'org.eclipse.ui.PartInitException', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.ecore.resource.Resource' - })/] - -[let content : String = peContext.fileContent()] -[peContext.genSortedImports()/] -[content/] -[/let] -[/file] -[/template] - -[template public fileContent(peContext : PropertiesEditionContext) { genModel : GenModel = peContext.model.genModel ; genPackage : GenPackage = peContext.model ;} ] -/** - * This is an example of a [model.ecorePackage.name/] model editor. - * - */ -public class [model.editorClassName()/] extends InteractiveEEFEditor { - -[if (genModel.richClientPlatform)][addImports(Sequence{'java.util.List', 'java.util.ArrayList', 'java.util.Collections'})/] - /** - * The filters for file extensions supported by the editor. - * - * - * @generated - */[if (genPackage.generateModelWizard)] - public static final [genModel._ListOfString()/] FILE_EXTENSION_FILTERS = prefixExtensions([genPackage.getImportedModelWizardClassName()/].FILE_EXTENSIONS, "*.");[genModel.getNonNLS()/] - [else] - public static final [genModel._ListOfString()/] FILE_EXTENSION_FILTERS = prefixExtensions([genModel.getImportedName('java.util.Arrays')/].asList([genPackage.getImportedEditorPluginClassName()/].INSTANCE.getString("_UI_[genPackage.getEditorClassName()/]FilenameExtensions").split("\\s*,\\s*")), "*.");[genModel.getNonNLS()/][genModel.getNonNLS(2)/][genModel.getNonNLS(3)/] - [/if] - /** - * Returns a new unmodifiable list containing prefixed versions of the extensions in the given list. - * - * - * @generated - */ - private static [genModel._ListOfString()/] prefixExtensions([genModel._ListOfString()/] extensions, String prefix) - { - [genModel._ListOfString()/] result = new [genModel._ArrayListOfString()/](); - [if (genModel.useGenerics())] - for (String extension : extensions) - { - result.add(prefix + extension); - [ else ] - for (Iterator iterator = extensions.iterator() ; iterator.hasNext(); ) - { - result.add(prefix + (String)iterator.next()); - [/if] - } - return Collections.unmodifiableList(result); - } - -[/if] - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.editor.InteractiveEEFEditor#contributePages() - */ - protected void contributePages() { - try { - [for (contribution : StaticEEFEditorContribution | peContext.categories.bindings->filter(StaticEEFEditorContribution))] - { - [contribution.input.editorInput()/] - [if (contribution.bindingFilters->size() > 0)] - [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> filters = new [include('java.util.ArrayList')/]([contribution.bindingFilters->size()/]); - [for (contribution.bindingFilters)] - [filterDeclaration()/] - [/for] - [/if] - [for (page : EEFPage | contribution.views->filter(EEFPage))] - { - [page.editorPage(peContext.model.editorClassName())/] - [if (contribution.bindingFilters->size() > 0)] - for (ViewerFilter viewerFilter : filters) { - page.addFilter(viewerFilter); - } - [/if] - page.setInput(input); - addPage(page); - } - [/for] - } - [/for] - } catch (PartInitException e) { - EEFExtendedRuntime.getPlugin().log(e); - } - } - - [additionalMethods()/] - -} - -[/template] - -[template public additionalMethods (peContext : PropertiesEditionContext) /] - -[template public fullFilePath(peContext : PropertiesEditionContext)] -[peContext.model.qualifiedEditorClassName().toPath()/].java -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/launcher/EEFEditorLauncher.java b/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/launcher/EEFEditorLauncher.java deleted file mode 100644 index a17d5ad9c..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/launcher/EEFEditorLauncher.java +++ /dev/null @@ -1,442 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.extended.launcher; - -import java.io.File; -import java.io.IOException; -import java.net.URL; -import java.util.ArrayList; -import java.util.Enumeration; -import java.util.List; - -import org.eclipse.acceleo.engine.event.IAcceleoTextGenerationListener; -import org.eclipse.acceleo.engine.generation.strategy.IAcceleoGenerationStrategy; -import org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.osgi.framework.Bundle; - -/** - * Entry point of the 'EEFEditorLauncher' generation module. - * - * @generated - */ -public class EEFEditorLauncher extends AbstractAcceleoGenerator { - /** - * The name of the module. - * - * @generated - */ - public static final String MODULE_FILE_NAME = "/org/eclipse/emf/eef/codegen/extended/launcher/EEFEditorLauncher"; - - /** - * The name of the templates that are to be generated. - * - * @generated - */ - public static final String[] TEMPLATE_NAMES = { "EEFEditorLauncher" }; - - /** - * The list of properties files from the launch parameters (Launch configuration). - * - * @generated - */ - private List propertiesFiles = new ArrayList(); - - /** - * Allows the public constructor to be used. Note that a generator created - * this way cannot be used to launch generations before one of - * {@link #initialize(EObject, File, List)} or - * {@link #initialize(URI, File, List)} is called. - *

- * The main reason for this constructor is to allow clients of this - * generation to call it from another Java file, as it allows for the - * retrieval of {@link #getProperties()} and - * {@link #getGenerationListeners()}. - *

- * - * @generated - */ - public EEFEditorLauncher() { - // Empty implementation - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param modelURI - * URI where the model on which this generator will be used is located. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in three scenarios : the module cannot be found, it cannot be loaded, or - * the model cannot be loaded. - * @generated - */ - public EEFEditorLauncher(URI modelURI, File targetFolder, - List arguments) throws IOException { - initialize(modelURI, targetFolder, arguments); - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param model - * We'll iterate over the content of this element to find Objects matching the first parameter - * of the template we need to call. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in two scenarios : the module cannot be found, or it cannot be loaded. - * @generated - */ - public EEFEditorLauncher(EObject model, File targetFolder, - List arguments) throws IOException { - initialize(model, targetFolder, arguments); - } - - /** - * FIX the build for Acceleo 3.1.3 - * @see org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator#createTemplateURI(java.lang.String) - */ - @Override - protected URI createTemplateURI(String entry) { - if (EMFPlugin.IS_ECLIPSE_RUNNING) { - Bundle bundle = Platform.getBundle("org.eclipse.emf.eef.codegen.extended"); - Enumeration e = bundle.findEntries("/", "*.emtl", true); - while (e.hasMoreElements()) { - URL anUrl = e.nextElement(); - if (anUrl.toString().endsWith("org/eclipse/emf/eef/codegen/extended/launcher/EEFEditorLauncher.emtl")) { - return URI.createURI("platform:/plugin/org.eclipse.emf.eef.codegen.extended" + anUrl.getPath()); - } - } - } - return super.createTemplateURI(entry); - } - - /** - * This can be used to launch the generation from a standalone application. - * - * @param args - * Arguments of the generation. - * @generated - */ - public static void main(String[] args) { - try { - if (args.length < 2) { - System.out.println("Arguments not valid : {model, folder}."); - } else { - URI modelURI = URI.createFileURI(args[0]); - File folder = new File(args[1]); - - List arguments = new ArrayList(); - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * Add in this list all the arguments used by the starting point of the generation - * If your main template is called on an element of your model and a String, you can - * add in "arguments" this "String" attribute. - */ - - EEFEditorLauncher generator = new EEFEditorLauncher(modelURI, folder, arguments); - - /* - * Add the properties from the launch arguments. - * If you want to programmatically add new properties, add them in "propertiesFiles" - * You can add the absolute path of a properties files, or even a project relative path. - * If you want to add another "protocol" for your properties files, please override - * "getPropertiesLoaderService(AcceleoService)" in order to return a new property loader. - * The behavior of the properties loader service is explained in the Acceleo documentation - * (Help -> Help Contents). - */ - - for (int i = 2; i < args.length; i++) { - generator.addPropertiesFile(args[i]); - } - - generator.doGenerate(new BasicMonitor()); - } - } catch (IOException e) { - e.printStackTrace(); - } - } - - /** - * Launches the generation described by this instance. - * - * @param monitor - * This will be used to display progress information to the user. - * @throws IOException - * This will be thrown if any of the output files cannot be saved to disk. - * @generated - */ - @Override - public void doGenerate(Monitor monitor) throws IOException { - /* - * TODO if you wish to change the generation as a whole, override this. The default behavior should - * be sufficient in most cases. If you want to change the content of this method, do NOT forget to - * change the "@generated" tag in the Javadoc of this method to "@generated NOT". Without this new tag, - * any compilation of the Acceleo module with the main template that has caused the creation of this - * class will revert your modifications. If you encounter a problem with an unresolved proxy during the - * generation, you can remove the comments in the following instructions to check for problems. Please - * note that those instructions may have a significant impact on the performances. - */ - - //org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(model); - - /* - * If you want to check for potential errors in your models before the launch of the generation, you - * use the code below. - */ - - //if (model != null && model.eResource() != null) { - // List errors = model.eResource().getErrors(); - // for (org.eclipse.emf.ecore.resource.Resource.Diagnostic diagnostic : errors) { - // System.err.println(diagnostic.toString()); - // } - //} - - super.doGenerate(monitor); - } - - /** - * If this generator needs to listen to text generation events, listeners can be returned from here. - * - * @return List of listeners that are to be notified when text is generated through this launch. - * @generated - */ - @Override - public List getGenerationListeners() { - List listeners = super.getGenerationListeners(); - /* - * TODO if you need to listen to generation event, add listeners to the list here. If you want to change - * the content of this method, do NOT forget to change the "@generated" tag in the Javadoc of this method - * to "@generated NOT". Without this new tag, any compilation of the Acceleo module with the main template - * that has caused the creation of this class will revert your modifications. - */ - return listeners; - } - - /** - * If you need to change the way files are generated, this is your entry point. - *

- * The default is {@link org.eclipse.acceleo.engine.generation.strategy.DefaultStrategy}; it generates - * files on the fly. If you only need to preview the results, return a new - * {@link org.eclipse.acceleo.engine.generation.strategy.PreviewStrategy}. Both of these aren't aware of - * the running Eclipse and can be used standalone. - *

- *

- * If you need the file generation to be aware of the workspace (A typical example is when you wanna - * override files that are under clear case or any other VCS that could forbid the overriding), then - * return a new {@link org.eclipse.acceleo.engine.generation.strategy.WorkspaceAwareStrategy}. - * Note, however, that this cannot be used standalone. - *

- *

- * All three of these default strategies support merging through JMerge. - *

- * - * @return The generation strategy that is to be used for generations launched through this launcher. - * @generated - */ - @Override - public IAcceleoGenerationStrategy getGenerationStrategy() { - return super.getGenerationStrategy(); - } - - /** - * This will be called in order to find and load the module that will be launched through this launcher. - * We expect this name not to contain file extension, and the module to be located beside the launcher. - * - * @return The name of the module that is to be launched. - * @generated - */ - @Override - public String getModuleName() { - return MODULE_FILE_NAME; - } - - /** - * If the module(s) called by this launcher require properties files, return their qualified path from - * here.Take note that the first added properties files will take precedence over subsequent ones if they - * contain conflicting keys. - *

- * Properties need to be in source folders, the path that we expect to get as a result of this call are of - * the form <package>.<properties file name without extension>. For example, if you have a file - * named "messages.properties" in package "org.eclipse.acceleo.sample", the path that needs be returned by - * a call to {@link #getProperties()} is "org.eclipse.acceleo.sample.messages". - *

- * - * @return The list of properties file we need to add to the generation context. - * @see java.util.ResourceBundle#getBundle(String) - * @generated - */ - @Override - public List getProperties() { - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO if your generation module requires access to properties files, add their qualified path to the list here. - * - * Properties files can be located in an Eclipse plug-in or in the file system (all Acceleo projects are Eclipse - * plug-in). In order to use properties files located in an Eclipse plugin, you need to add the path of the properties - * files to the "propertiesFiles" list: - * - * final String prefix = "platform:/plugin/"; - * final String pluginName = "org.eclipse.acceleo.module.sample"; - * final String packagePath = "/org/eclipse/acceleo/module/sample/properties/"; - * final String fileName = "default.properties"; - * propertiesFiles.add(prefix + pluginName + packagePath + fileName); - * - * With this mechanism, you can load properties files from your plugin or from another plugin. - * - * You may want to load properties files from the file system, for that you need to add the absolute path of the file: - * - * propertiesFiles.add("C:\Users\MyName\MyFile.properties"); - * - * If you want to let your users add properties files located in the same folder as the model: - * - * if (EMFPlugin.IS_ECLIPSE_RUNNING && model != null && model.eResource() != null) { - * propertiesFiles.addAll(AcceleoEngineUtils.getPropertiesFilesNearModel(model.eResource())); - * } - * - * To learn more about Properties Files, have a look at the Acceleo documentation (Help -> Help Contents). - */ - return propertiesFiles; - } - - /** - * Adds a properties file in the list of properties files. - * - * @param propertiesFile - * The properties file to add. - * @generated - * @since 3.1 - */ - @Override - public void addPropertiesFile(String propertiesFile) { - this.propertiesFiles.add(propertiesFile); - } - - /** - * This will be used to get the list of templates that are to be launched by this launcher. - * - * @return The list of templates to call on the module {@link #getModuleName()}. - * @generated - */ - @Override - public String[] getTemplateNames() { - return TEMPLATE_NAMES; - } - - /** - * This can be used to update the resource set's package registry with all needed EPackages. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerPackages(ResourceSet resourceSet) { - super.registerPackages(resourceSet); - if (!isInWorkspace(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE.getNsURI(), org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE); - } - if (!isInWorkspace(org.eclipse.emf.ecore.EcorePackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - } - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * If you need additional package registrations, you can register them here. The following line - * (in comment) is an example of the package registration for UML. - * - * You can use the method "isInWorkspace(Class c)" to check if the package that you are about to - * register is in the workspace. - * - * To register a package properly, please follow the following conventions: - * - * If the package is located in another plug-in, already installed in Eclipse. The following content should - * have been generated at the beginning of this method. Do not register the package using this mechanism if - * the metamodel is located in the workspace. - * - * if (!isInWorkspace(UMLPackage.class)) { - * // The normal package registration if your metamodel is in a plugin. - * resourceSet.getPackageRegistry().put(UMLPackage.eNS_URI, UMLPackage.eINSTANCE); - * } - * - * If the package is located in another project in your workspace, the plugin containing the package has not - * been register by EMF and Acceleo should register it automatically. If you want to use the generator in - * stand alone, the regular registration (seen a couple lines before) is needed. - * - * To learn more about Package Registration, have a look at the Acceleo documentation (Help -> Help Contents). - */ - } - - /** - * This can be used to update the resource set's resource factory registry with all needed factories. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerResourceFactories(ResourceSet resourceSet) { - super.registerResourceFactories(resourceSet); - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO If you need additional resource factories registrations, you can register them here. the following line - * (in comment) is an example of the resource factory registration for UML. - * - * If you want to use the generator in stand alone, the resource factory registration will be required. - * - * To learn more about the registration of Resource Factories, have a look at the Acceleo documentation (Help -> Help Contents). - */ - - // resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/launcher/EEFEditorLauncher.mtl b/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/launcher/EEFEditorLauncher.mtl deleted file mode 100644 index ecec6d48d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/launcher/EEFEditorLauncher.mtl +++ /dev/null @@ -1,14 +0,0 @@ -[comment encoding = UTF-8 /] -[module EEFEditorLauncher('http://www.eclipse.org/emf/eef/generation/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/extended/editor/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::extended::files::EEFEditor /] - -[template public EEFEditorLauncher(genModel : EEFGenModel)] - [comment @main /] -[for (editionContext : GenEditionContext | genModel.editionContexts)] - [let peContext : PropertiesEditionContext = editionContext.PropertiesEditionContext] - [peContext.generateEditor()/] - [/let] -[/for] -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/query/oclquery.mtl b/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/query/oclquery.mtl deleted file mode 100644 index 4c54b2c5b..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/query/oclquery.mtl +++ /dev/null @@ -1,24 +0,0 @@ -[comment encoding = UTF-8 /] -[module oclquery('http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/eef/extended/query/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::emfCodeGen /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public content(eefUnderstandableQuery : EEFUnderstandableQuery)] -[/template] - -[template public queryImports(peContext : PropertiesEditionContext, queryType : EClass) ? (queryType.name = 'OCLQuery')] -[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.query.QueryResult', - 'org.eclipse.emf.eef.runtime.query.ocl.OCLQuery'})/] -[/template] - -[template public content(oclQuery : OCLQuery)] -OCLQuery query = new OCLQuery([oclQuery._context.metamodelGetter()/][addImport(oclQuery._context.ePackage.qualifiedMetamodelPackage())/], "[oclQuery._query/]"); -if (EEFExtendedRuntime.INSTANCE.getProcessor().canEvaluate(query)) { - QueryResult result = EEFExtendedRuntime.INSTANCE.getProcessor().evaluate(element, query); - if (result.evaluationStatus.isOK()) { - input = result.evaluationResult; - } -} -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/services/editor-common.mtl b/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/services/editor-common.mtl deleted file mode 100644 index 744579b59..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.extended/src/org/eclipse/emf/eef/codegen/extended/services/editor-common.mtl +++ /dev/null @@ -1,14 +0,0 @@ -[comment encoding = UTF-8 /] -[module editor-common('http://www.eclipse.org/emf/2002/GenModel')/] - -[template public editorClassName(genPackage : GenPackage)] -[genPackage.prefix/]Editor -[/template] - -[template public qualifiedEditorClassName(genPackage : GenPackage)] -[genPackage.presentationPackage()/].[genPackage.editorClassName()/] -[/template] - -[template public presentationPackage(genPackage : GenPackage)] -[if ((not genPackage.basePackage.oclIsUndefined()) and genPackage.basePackage.size() > 0)][genPackage.basePackage/].[/if][genPackage.ecorePackage.name/].presentation -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/.classpath b/plugins/org.eclipse.emf.eef.codegen.launcher/.classpath deleted file mode 100644 index 64c5e31b7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/.gitignore b/plugins/org.eclipse.emf.eef.codegen.launcher/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/.project b/plugins/org.eclipse.emf.eef.codegen.launcher/.project deleted file mode 100644 index 6354735a8..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.codegen.launcher - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.codegen.launcher/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index 5d3649898..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,8 +0,0 @@ -#Mon Dec 12 14:57:03 CET 2011 -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.codegen.launcher/META-INF/MANIFEST.MF deleted file mode 100644 index 154322386..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/META-INF/MANIFEST.MF +++ /dev/null @@ -1,14 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Codegen Launcher -Bundle-SymbolicName: org.eclipse.emf.eef.codegen.launcher -Bundle-Version: 1.5.2.qualifier -Bundle-Activator: org.eclipse.emf.eef.codegen.launcher.EEFCodegenLauncher -Bundle-Vendor: Eclipse Modeling Project -Require-Bundle: org.eclipse.ui, - org.eclipse.core.runtime, - org.eclipse.emf.ecore -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Bundle-ActivationPolicy: lazy -Export-Package: org.eclipse.emf.eef.codegen.flow, - org.eclipse.emf.eef.codegen.flow.var diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/about.html b/plugins/org.eclipse.emf.eef.codegen.launcher/about.html deleted file mode 100755 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/build.properties b/plugins/org.eclipse.emf.eef.codegen.launcher/build.properties deleted file mode 100644 index e95ac0c3a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/build.properties +++ /dev/null @@ -1,16 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - about.html -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/pom.xml b/plugins/org.eclipse.emf.eef.codegen.launcher/pom.xml deleted file mode 100644 index f90fc5b2b..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/pom.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.codegen.launcher - eclipse-plugin - - EEF Launcher Codegen Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/ConditionalStep.java b/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/ConditionalStep.java deleted file mode 100755 index 20478db4f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/ConditionalStep.java +++ /dev/null @@ -1,132 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.codegen.flow; - -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowContext; - -/** - * @author Goulwen Le Fur - * - */ -public abstract class ConditionalStep extends Step { - - private Step thenStep; - private Step elseStep; - - /** - * @param thenStep execution if condition is valid - */ - public ConditionalStep(Step thenStep) { - super("Conditional step"); - this.thenStep = thenStep; - this.elseStep = new IdentityStep(); - } - - /** - * @param thenStep execution if condition is valid - * @param elseStep execution if condition is invalid - */ - public ConditionalStep(Step thenStep, Step elseStep) { - super("Conditional step"); - this.thenStep = thenStep; - this.elseStep = elseStep; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - public IStatus execute(IProgressMonitor monitor) { - if (condition()) { - return thenStep.execute(monitor); - } else { - if (elseStep != null) { - return elseStep.execute(monitor); - } - } - return Status.OK_STATUS; - } - - /** - * Defines if the thenStep or the elseStep must be executed. - * @return result - */ - public abstract boolean condition(); - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#getName() - */ - public String getName() { - return super.getName(); - } - - /** - * @return the thenStep - */ - public Step getThenStep() { - return thenStep; - } - - /** - * @return the elseStep - */ - public Step getElseStep() { - return elseStep; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#setContext(org.eclipse.emf.eef.codegen.flow.var.WorkflowContext) - */ - public void setContext(WorkflowContext context) { - super.setContext(context); - thenStep.setContext(context); - if (elseStep != null) { - elseStep.setContext(context); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#setResourceSet(org.eclipse.emf.ecore.resource.ResourceSet) - */ - public void setResourceSet(ResourceSet resourceSet) { - super.setResourceSet(resourceSet); - thenStep.setResourceSet(resourceSet); - if (elseStep != null) { - elseStep.setResourceSet(resourceSet); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#validateExecution() - */ - public boolean validateExecution() { - if (condition()) { - return thenStep.validateExecution(); - } else { - if (elseStep != null) { - return elseStep.validateExecution(); - } - else { - return super.validateExecution(); - } - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/IdentityStep.java b/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/IdentityStep.java deleted file mode 100755 index 37bb8917e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/IdentityStep.java +++ /dev/null @@ -1,42 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow; - -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; - -/** - * @author Goulwen Le Fur - * - */ -public class IdentityStep extends Step { - - private static final String IDENTITY_STEP_NAME = "Identity"; - - /** - * @param name - */ - public IdentityStep() { - super(IDENTITY_STEP_NAME); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - @Override - public IStatus execute(IProgressMonitor monitor) { - // TO Nothing - return Status.OK_STATUS; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/Step.java b/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/Step.java deleted file mode 100755 index 918259bb6..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/Step.java +++ /dev/null @@ -1,102 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow; - -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowContext; - -/** - * @author Goulwen Le Fur - * - */ -public abstract class Step { - - /** - * ResourceSet where to work - */ - protected ResourceSet resourceSet; - - /** - * Workflow context - */ - protected WorkflowContext context; - - /** - * Step name - */ - protected final String name; - - - /** - * @param name StepName - */ - public Step(String name) { - this.name = name; - } - - /** - * @return the name - */ - public String getName() { - return name; - } - - /** - * @return the context - */ - public WorkflowContext getContext() { - if (context == null) { - context = new WorkflowContext(); - } - return context; - } - - /** - * @param context to set - */ - public void setContext(WorkflowContext context) { - this.context = context; - } - - /** - * @return the resourceSet - */ - public ResourceSet getResourceSet() { - if (resourceSet == null) { - resourceSet = new ResourceSetImpl(); - } - return resourceSet; - } - - /** - * @param resourceSet the resourceSet to set - */ - public void setResourceSet(ResourceSet resourceSet) { - this.resourceSet = resourceSet; - } - - /** - * @return true if the step must be executed - */ - public boolean validateExecution() { - return true; - } - - /** - * @param monitor monitor to use - * @return the execution result - */ - public abstract IStatus execute(IProgressMonitor monitor); - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/StepWithInput.java b/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/StepWithInput.java deleted file mode 100755 index c72f76f4c..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/StepWithInput.java +++ /dev/null @@ -1,36 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow; - -import java.util.List; - -import org.eclipse.jface.wizard.WizardPage; - - -/** - * @author Goulwen Le Fur - * - */ -public abstract class StepWithInput extends Step { - - /** - * @param name of the task - */ - public StepWithInput(String name) { - super(name); - } - - /** - * @return a wizard page to get the step inputs - */ - public abstract List getInputPages(); - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/Workflow.java b/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/Workflow.java deleted file mode 100755 index b578811fa..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/Workflow.java +++ /dev/null @@ -1,214 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowContext; -import org.eclipse.emf.eef.codegen.launcher.EEFCodegenLauncher; -import org.eclipse.jface.wizard.Wizard; -import org.eclipse.jface.wizard.WizardDialog; -import org.eclipse.jface.wizard.WizardPage; -import org.eclipse.swt.widgets.Shell; - -/** - * @author Goulwen Le Fur - * - */ -public class Workflow extends StepWithInput { - - private Map steps; - private Shell shell; - private boolean prepared; - private boolean canExecute; - - /** - * Create an empty flow - */ - public Workflow(String name, Shell shell) { - super(name); - steps = new LinkedHashMap(); - this.shell = shell; - prepared = false; - } - - /** - * Create a flow with the given steps - * @param name flow name - * @param shell current shell - * @param steps the workflow's steps - */ - public Workflow(String name, Shell shell, Map steps) { - super(name); - this.steps = steps; - this.shell = shell; - prepared = false; - } - - /** - * @param context - */ - public void setContext(WorkflowContext context) { - super.setContext(context); - for (Step step : steps.values()) { - step.setContext(context); - } - } - - /** - * Add a new step to the workflow. - * @param key title of the step (must be unique) - * @param step the step to add - */ - public void addStep(String key, Step step) { - if (context == null) { - context = new WorkflowContext(); - } - step.setContext(context); - if (resourceSet == null) { - resourceSet = new ResourceSetImpl(); - } - step.setResourceSet(resourceSet); - steps.put(key, step); - } - - - /** - * {@inheritDoc] - * @see org.eclipse.emf.eef.codegen.flow.Step#getResourceSet() - */ - public ResourceSet getResourceSet() { - if (resourceSet == null) { - resourceSet = new ResourceSetImpl(); - for (Step step : steps.values()) { - step.setResourceSet(resourceSet); - } - } - return resourceSet; - } - - /** - * {@inheritDoc] - * @see org.eclipse.emf.eef.codegen.flow.Step#setResourceSet(org.eclipse.emf.ecore.resource.ResourceSet) - */ - public void setResourceSet(ResourceSet resourceSet) { - super.setResourceSet(resourceSet); - for (Step step : steps.values()) { - step.setResourceSet(resourceSet); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.StepWithInput#getInputPages() - */ - public List getInputPages() { - List flowPages = new ArrayList(); - for (Step step : steps.values()) { - if (step instanceof ConditionalStep) { - if (((ConditionalStep) step).condition()) { - step = ((ConditionalStep) step).getThenStep(); - } else { - step = ((ConditionalStep) step).getElseStep(); - } - } - if (step instanceof StepWithInput) { - flowPages.addAll(((StepWithInput) step).getInputPages()); - } - } - return flowPages; - } - - /** - * Prepare the flow execution. - */ - public boolean prepare() { - canExecute = true; - if (getInputPages().size() > 0) { - Wizard prepareWizard = new Wizard() { - - /** - * {@inheritDoc} - * @see org.eclipse.jface.wizard.Wizard#addPages() - */ - public void addPages() { - for (WizardPage page : getInputPages()) { - addPage(page); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.wizard.Wizard#performFinish() - */ - public boolean performFinish() { - canExecute = true; - return true; - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.wizard.Wizard#performCancel() - */ - public boolean performCancel() { - canExecute = false; - return true; - } - - - }; - WizardDialog wDialog = new WizardDialog(shell, prepareWizard); - wDialog.open(); - } - prepared = true; - return canExecute; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - public IStatus execute(IProgressMonitor monitor) { - assert prepared == true:"Workflow must be prepared before execution"; - monitor.beginTask(name, steps.size()); - for (Iterator iterator = steps.keySet().iterator(); iterator.hasNext();) { - String key = (String) iterator.next(); - monitor.subTask(key); - Step step = steps.get(key); - if (step instanceof ConditionalStep) { - if (((ConditionalStep) step).condition()) { - step = ((ConditionalStep) step).getThenStep(); - } else { - step = ((ConditionalStep) step).getElseStep(); - } - } - if (step.validateExecution()) { - IStatus execute = step.execute(monitor); - if (!execute.isOK()) { - EEFCodegenLauncher.getDefault().logError((Exception) execute.getException()); - return execute; - } - } - monitor.worked(1); - } - return Status.OK_STATUS; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/var/WorkflowContext.java b/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/var/WorkflowContext.java deleted file mode 100755 index 03a9bc2ca..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/var/WorkflowContext.java +++ /dev/null @@ -1,75 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.var; - -import java.util.HashMap; -import java.util.Map; - -/** - * @author Goulwen Le Fur - * - */ -public class WorkflowContext { - - private Map variables; - - /** - * Default constructor. - */ - public WorkflowContext() { - variables = new HashMap(); - } - - /** - * Returns the value of a variable. - * @param name of the variable - * @return value of the variable - */ - public Object get(String name) { - if (variables.get(name) != null) { - return variables.get(name).getValue(); - } - return null; - } - - /** - * Add a variable to the context. - * @param var to add - */ - public void add(WorkflowVariable var) { - variables.put(var.getName(), var); - } - - /** - * Add a variable to the context. - * @param name of the variable - * @param value of the variable - */ - public void add(String name, Object value) { - WorkflowVariable var = new WorkflowVariable(name, value); - variables.put(name, var); - } - - /** - * Set a value to a variable of context. - * @param name of the variable - * @param value of the variable - */ - public void set(String name, Object value) { - WorkflowVariable var = variables.get(name); - if (var != null) { - var.setValue(value); - } else { - var = new WorkflowVariable(name, value); - variables.put(name, var); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/var/WorkflowVariable.java b/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/var/WorkflowVariable.java deleted file mode 100755 index b33a09787..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/flow/var/WorkflowVariable.java +++ /dev/null @@ -1,64 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.var; - -/** - * @author Goulwen Le Fur - * - */ -public class WorkflowVariable { - - private final String name; - private Object value; - - /** - * @param name of the variable - */ - public WorkflowVariable(String name) { - super(); - this.name = name; - this.value = null; - } - - /** - * @param name of the variable - * @param value of the variable - */ - public WorkflowVariable(String name, Object value) { - super(); - this.name = name; - this.value = value; - } - - /** - * @return the name - */ - public String getName() { - return name; - } - - /** - * @return the value - */ - public Object getValue() { - return value; - } - - /** - * @param value the value to set - */ - public void setValue(Object value) { - this.value = value; - } - - - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/launcher/EEFCodegenLauncher.java b/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/launcher/EEFCodegenLauncher.java deleted file mode 100644 index cd0f1b36e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.launcher/src/org/eclipse/emf/eef/codegen/launcher/EEFCodegenLauncher.java +++ /dev/null @@ -1,72 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.launcher; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.ui.plugin.AbstractUIPlugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle - */ -public class EEFCodegenLauncher extends AbstractUIPlugin { - - // The plug-in ID - public static final String PLUGIN_ID = "org.eclipse.emf.eef.codegen.launcher"; //$NON-NLS-1$ - - // The shared instance - private static EEFCodegenLauncher plugin; - - /** - * The constructor - */ - public EEFCodegenLauncher() { - } - - public void logError(Exception e) { - IStatus status = new Status(IStatus.ERROR, PLUGIN_ID, e.getMessage(), e); - getLog().log(status); - } - - public void logWarning(Exception e) { - IStatus status = new Status(IStatus.WARNING, PLUGIN_ID, e.getMessage(), e); - getLog().log(status); - } - - /* - * (non-Javadoc) - * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - /* - * (non-Javadoc) - * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance - * - * @return the shared instance - */ - public static EEFCodegenLauncher getDefault() { - return plugin; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/.checkstyle b/plugins/org.eclipse.emf.eef.codegen.tests/.checkstyle deleted file mode 100644 index 48589e9cb..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/.classpath b/plugins/org.eclipse.emf.eef.codegen.tests/.classpath deleted file mode 100644 index ed5ee00d9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/.classpath +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/.gitignore b/plugins/org.eclipse.emf.eef.codegen.tests/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/.project b/plugins/org.eclipse.emf.eef.codegen.tests/.project deleted file mode 100644 index c4d02fdc3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/.project +++ /dev/null @@ -1,34 +0,0 @@ - - - org.eclipse.emf.eef.codegen.tests - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - org.eclipse.acceleo.ide.ui.acceleoBuilder - - - - - - org.eclipse.acceleo.ide.ui.acceleoNature - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.codegen.tests/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index d1c0bf949..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,6 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.codegen.tests/META-INF/MANIFEST.MF deleted file mode 100644 index 617a37075..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/META-INF/MANIFEST.MF +++ /dev/null @@ -1,22 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: Acceleo Tests Module Runtime Plug-in -Bundle-SymbolicName: org.eclipse.emf.eef.codegen.tests;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Activator: org.eclipse.emf.eef.codegen.tests.Activator -Bundle-Vendor: Eclipse Modeling Project -Require-Bundle: org.eclipse.core.runtime, - org.eclipse.ui, - org.eclipse.core.resources, - org.eclipse.emf.ecore, - org.eclipse.emf.ecore.xmi, - org.eclipse.ocl, - org.eclipse.ocl.ecore, - org.eclipse.acceleo.model, - org.eclipse.acceleo.engine, - org.eclipse.acceleo.parser;bundle-version="3.1.0", - org.eclipse.emf.eef.eefgen, - org.eclipse.emf.eef.codegen -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Bundle-ActivationPolicy: lazy -Export-Package: org.eclipse.emf.eef.codegen.tests.main.cases diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/about.html b/plugins/org.eclipse.emf.eef.codegen.tests/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/build.acceleo b/plugins/org.eclipse.emf.eef.codegen.tests/build.acceleo deleted file mode 100644 index ebb8cd827..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/build.acceleo +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/build.properties b/plugins/org.eclipse.emf.eef.codegen.tests/build.properties deleted file mode 100644 index 7d729a796..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2010 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/,\ - src-custom/,\ - src-build/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ - about.html -customBuildCallbacks = build.acceleo -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/plugin.xml b/plugins/org.eclipse.emf.eef.codegen.tests/plugin.xml deleted file mode 100644 index 2ded4a99e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/plugin.xml +++ /dev/null @@ -1,25 +0,0 @@ - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/pom.xml b/plugins/org.eclipse.emf.eef.codegen.tests/pom.xml deleted file mode 100644 index dd685092e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/pom.xml +++ /dev/null @@ -1,60 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.1.0-SNAPSHOT - - - org.eclipse.emf - org.eclipse.emf.eef.codegen.tests - 1.1.0.qualifier - eclipse-plugin - - EEF Tests Codegen Plug-in - - - - - org.codehaus.mojo - exec-maven-plugin - 1.1.1 - - - compile - - java - - - org.eclipse.emf.eef.codegen.tests.EEFCodegenTestsCompiler - - ${basedir}/src/ - ${basedir}/target/classes - true - ${basedir}/../org.eclipse.emf.eef.codegen/target/classes - - - - - - - org.eclipse.tycho - tycho-source-plugin - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src-build/org/eclipse/emf/eef/codegen/tests/EEFCodegenTestsCompiler.java b/plugins/org.eclipse.emf.eef.codegen.tests/src-build/org/eclipse/emf/eef/codegen/tests/EEFCodegenTestsCompiler.java deleted file mode 100644 index 746195db1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src-build/org/eclipse/emf/eef/codegen/tests/EEFCodegenTestsCompiler.java +++ /dev/null @@ -1,166 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.tests; - -import java.io.File; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.Map; - -import org.eclipse.acceleo.common.IAcceleoConstants; -import org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; - -/** - * The Acceleo Standalone compiler. - * - * @author Stephane Bouchet - * @since 1.1 - */ -public class EEFCodegenTestsCompiler extends AbstractAcceleoCompiler { - - /** - * The entry point of the compilation. - * - * @param args - * The arguments used in the compilation: the source folder, the output folder, a boolean - * indicating if we should use binary resource serialization and finally the dependencies of - * the project. - */ - public static void main(String[] args) { - if (args.length < 3) { - throw new IllegalArgumentException("Missing parameters"); //$NON-NLS-1$ - } - EEFCodegenTestsCompiler acceleoCompiler = new EEFCodegenTestsCompiler(); - acceleoCompiler.setSourceFolder(args[0]); - acceleoCompiler.setOutputFolder(args[1]); - acceleoCompiler.setBinaryResource(Boolean.valueOf(args[2]).booleanValue()); - if (args.length == 4 && args[3] != null && !"".equals(args[3])) { //$NON-NLS-1$ - acceleoCompiler.setDependencies(args[3]); - } - acceleoCompiler.doCompile(new BasicMonitor()); - } - - /** - * Launches the compilation of the mtl files in the generator. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#doCompile(org.eclipse.emf.common.util.Monitor) - */ - @Override - public void doCompile(Monitor monitor) { - super.doCompile(monitor); - } - - /** - * Registers the packages of the metamodels used in the generator. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#registerPackages() - */ - @Override - protected void registerPackages() { - super.registerPackages(); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.components.ComponentsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.components.ComponentsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.MappingPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.MappingPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.navigation.NavigationPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.navigation.NavigationPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.filters.FiltersPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.filters.FiltersPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), - org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.views.ViewsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.views.ViewsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.toolkits.ToolkitsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.toolkits.ToolkitsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.EEFGen.EEFGenPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.EEFGen.EEFGenPackage.eINSTANCE); - } - - /** - * Registers the resource factories. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#registerResourceFactories() - */ - @Override - protected void registerResourceFactories() { - super.registerResourceFactories(); - /* - * If you want to add other resource factories, for example if your metamodel uses a specific - * serialization: - * org.eclipse.emf.ecore.resource.Resource.Factory.Registry.getExtensionToFactoryMap().put - * (UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - */ - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#computeDependencies(java.util.List, - * java.util.Map) - */ - protected void computeDependencies(List dependenciesURIs, Map mapURIs) { - // USED TO FIX COMPILER WITH TYCHO - Iterator identifiersIt = dependenciesIDs.iterator(); - for (Iterator dependenciesIt = dependencies.iterator(); dependenciesIt.hasNext() - && identifiersIt.hasNext();) { - File requiredFolder = dependenciesIt.next(); - String identifier = identifiersIt.next(); - if (requiredFolder != null && requiredFolder.exists() && requiredFolder.isDirectory()) { - List emtlFiles = new ArrayList(); - members(emtlFiles, requiredFolder, IAcceleoConstants.EMTL_FILE_EXTENSION); - for (File emtlFile : emtlFiles) { - String requiredFolderAbsolutePath = requiredFolder.getAbsolutePath(); - if (requiredFolderAbsolutePath.endsWith("target/classes")) { - // using tycho - String[] splited = requiredFolderAbsolutePath.split("\\/"); - StringBuffer buf = new StringBuffer(requiredFolderAbsolutePath.length()); - for (int i = 0; i < splited.length - 3; i++) { - buf.append(splited[i]); - buf.append("/"); - } - requiredFolderAbsolutePath = buf.toString(); - String emtlAbsolutePath = emtlFile.getAbsolutePath(); - URI emtlFileURI = URI.createFileURI(emtlAbsolutePath); - dependenciesURIs.add(emtlFileURI); - String emtlModifiedPath = emtlAbsolutePath.replaceAll("target\\/|classes\\/", ""); - IPath relativePath = new Path(emtlModifiedPath.substring(requiredFolderAbsolutePath - .length())); - URI relativeURI = URI.createPlatformPluginURI(relativePath.toString(), false); - mapURIs.put(emtlFileURI, relativeURI); - } else { - // normal behavior - String emtlAbsolutePath = emtlFile.getAbsolutePath(); - URI emtlFileURI = URI.createFileURI(emtlAbsolutePath); - dependenciesURIs.add(emtlFileURI); - IPath relativePath = new Path(identifier).append(emtlAbsolutePath - .substring(requiredFolderAbsolutePath.length())); - mapURIs.put(emtlFileURI, URI.createPlatformPluginURI(relativePath.toString(), false)); - } - } - } - } - } -} - diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src-custom/org/eclipse/emf/eef/tests/codegen/core/launcher/ComponentPropertiesTestsGeneratorLauncher.java b/plugins/org.eclipse.emf.eef.codegen.tests/src-custom/org/eclipse/emf/eef/tests/codegen/core/launcher/ComponentPropertiesTestsGeneratorLauncher.java deleted file mode 100644 index dc1dcface..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src-custom/org/eclipse/emf/eef/tests/codegen/core/launcher/ComponentPropertiesTestsGeneratorLauncher.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008-2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.tests.codegen.core.launcher; - -import java.io.File; -import java.io.FileNotFoundException; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.launcher.AbstractPropertiesGeneratorLauncher; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.tests.codegen.main.cases.ComponentPropertiesTests; - -/** - * Extension for generating PropertiesSection set up for GMF1 modelers - * - * @author Goulwen Le Fur - */ -public class ComponentPropertiesTestsGeneratorLauncher extends AbstractPropertiesGeneratorLauncher { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.core.launcher.IPropertiesGeneratorLauncher#doGenerate(org.eclipse.emf.eef.EEFGen.EEFGenModel, - * java.io.File, org.eclipse.core.runtime.IProgressMonitor) - */ - public void doGenerate(EEFGenModel eefGenModel, File targetFolder, IProgressMonitor monitor) { - List arguments = new ArrayList(); - for (GenEditionContext genEditionContext : eefGenModel.getEditionContexts()) { - if (genEditionContext.isGenerateJunitTestCases()) { - try { - PropertiesEditionContext propertiesEditionContext = genEditionContext.getPropertiesEditionContext(); - monitor.subTask("Generating JUnits TestCases"); - IContainer testGenContainer = getTestGenContainer(eefGenModel); - if (testGenContainer != null && !testGenContainer.exists()) { - EEFCodegenPlugin.getDefault().logWarning(new FileNotFoundException("Cannot find junit test project named \"" + testGenContainer.getProject().getName() + "\"")); - return; - } - ComponentPropertiesTests gen = new ComponentPropertiesTests(propertiesEditionContext, testGenContainer.getLocation().toFile(), arguments); - gen.doGenerate(BasicMonitor.toMonitor(monitor)); - targetContainer.add(testGenContainer); - monitor.worked(1); - } catch (IOException e) { - EEFCodegenPlugin.getDefault().logError(e); - } - } - } - } - - /** - * Returns the container that the EEFGenModel use as generation directory - * - * @param eefGenModel - * the eefGenModel - * @return the generation directory - * @throws IOException - * an error occurred during container creation - */ - public IContainer getTestGenContainer(EEFGenModel eefGenModel) throws IOException { - if (eefGenModel != null) { - if (eefGenModel.getGenDirectory() != null) { - final IContainer target = ResourcesPlugin.getWorkspace().getRoot() - .getFolder(new Path(eefGenModel.getTestsGenDirectory())); - return target; - } - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src-custom/org/eclipse/emf/eef/tests/codegen/core/launcher/ComponentTestsGeneratorLauncher.java b/plugins/org.eclipse.emf.eef.codegen.tests/src-custom/org/eclipse/emf/eef/tests/codegen/core/launcher/ComponentTestsGeneratorLauncher.java deleted file mode 100644 index 0e72ddc5b..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src-custom/org/eclipse/emf/eef/tests/codegen/core/launcher/ComponentTestsGeneratorLauncher.java +++ /dev/null @@ -1,91 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008-2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.tests.codegen.core.launcher; - -import java.io.File; -import java.io.FileNotFoundException; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.launcher.AbstractPropertiesGeneratorLauncher; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.tests.codegen.main.cases.ComponentTests; - -/** - * Extension for generating PropertiesSection set up for GMF1 modelers - * - * @author Goulwen Le Fur - */ -public class ComponentTestsGeneratorLauncher extends AbstractPropertiesGeneratorLauncher { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.core.launcher.IPropertiesGeneratorLauncher#doGenerate(org.eclipse.emf.eef.EEFGen.EEFGenModel, - * java.io.File, org.eclipse.core.runtime.IProgressMonitor) - */ - public void doGenerate(EEFGenModel eefGenModel, File targetFolder, IProgressMonitor monitor) { - List arguments = new ArrayList(); - for (GenEditionContext genEditionContext : eefGenModel.getEditionContexts()) { - if (genEditionContext.isGenerateJunitTestCases()) { - try { - PropertiesEditionContext propertiesEditionContext = genEditionContext - .getPropertiesEditionContext(); - monitor.subTask("Generating JUnits TestCases"); - IContainer testGenContainer = getTestGenContainer(eefGenModel); - if (testGenContainer != null && !testGenContainer.exists()) { - EEFCodegenPlugin.getDefault().logWarning( - new FileNotFoundException("Cannot find junit test project named \"" - + testGenContainer.getProject().getName() + "\"")); - return; - } - ComponentTests gen = new ComponentTests(propertiesEditionContext, testGenContainer - .getLocation().toFile(), arguments); - gen.doGenerate(BasicMonitor.toMonitor(monitor)); - targetContainer.add(testGenContainer); - monitor.worked(1); - } catch (IOException e) { - EEFCodegenPlugin.getDefault().logError(e); - } - } - } - } - - /** - * Returns the container that the EEFGenModel use as generation directory - * - * @param eefGenModel - * the eefGenModel - * @return the generation directory - * @throws IOException - * an error occurred during container creation - */ - public IContainer getTestGenContainer(EEFGenModel eefGenModel) throws IOException { - if (eefGenModel != null) { - if (eefGenModel.getGenDirectory() != null) { - final IContainer target = ResourcesPlugin.getWorkspace().getRoot() - .getFolder(new Path(eefGenModel.getTestsGenDirectory())); - return target; - } - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/Activator.java b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/Activator.java deleted file mode 100644 index b2470ddc3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/Activator.java +++ /dev/null @@ -1,66 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.tests.codegen; - -import org.eclipse.core.runtime.Plugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle. - * - * @author Jonathan Musset - */ -public class Activator extends Plugin { - - /** - * The plug-in ID. - */ - public static final String PLUGIN_ID = "org.eclipse.emf.eef.tests.codegen"; - - /** - * The shared instance. - */ - private static Activator plugin; - - /** - * The constructor. - */ - public Activator() { - } - - /**{@inheritDoc} - * - * @see org.eclipse.core.runtime.Plugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - /**{@inheritDoc} - * - * @see org.eclipse.core.runtime.Plugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance. - * - * @return the shared instance - */ - public static Activator getDefault() { - return plugin; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentPropertiesTests.java b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentPropertiesTests.java deleted file mode 100644 index c33db23ad..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentPropertiesTests.java +++ /dev/null @@ -1,420 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.tests.codegen.main.cases; - -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.acceleo.engine.event.IAcceleoTextGenerationListener; -import org.eclipse.acceleo.engine.generation.strategy.IAcceleoGenerationStrategy; -import org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; - -/** - * Entry point of the 'ComponentPropertiesTests' generation module. - * - * @author Nathalie Lepine - * @generated - */ -public class ComponentPropertiesTests extends AbstractAcceleoGenerator { - /** - * The name of the module. - * - * @generated - */ - public static final String MODULE_FILE_NAME = "/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentPropertiesTests"; - - /** - * The name of the templates that are to be generated. - * - * @generated - */ - public static final String[] TEMPLATE_NAMES = { "PropertySection" }; - - /** - * The list of properties files from the launch parameters (Launch configuration). - * - * @generated - */ - private List propertiesFiles = new ArrayList(); - - /** - * Allows the public constructor to be used. Note that a generator created - * this way cannot be used to launch generations before one of - * {@link #initialize(EObject, File, List)} or - * {@link #initialize(URI, File, List)} is called. - *

- * The main reason for this constructor is to allow clients of this - * generation to call it from another Java file, as it allows for the - * retrieval of {@link #getProperties()} and - * {@link #getGenerationListeners()}. - *

- * - * @generated - */ - public ComponentPropertiesTests() { - // Empty implementation - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param modelURI - * URI where the model on which this generator will be used is located. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in three scenarios : the module cannot be found, it cannot be loaded, or - * the model cannot be loaded. - * @generated - */ - public ComponentPropertiesTests(URI modelURI, File targetFolder, - List arguments) throws IOException { - initialize(modelURI, targetFolder, arguments); - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param model - * We'll iterate over the content of this element to find Objects matching the first parameter - * of the template we need to call. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in two scenarios : the module cannot be found, or it cannot be loaded. - * @generated - */ - public ComponentPropertiesTests(EObject model, File targetFolder, - List arguments) throws IOException { - initialize(model, targetFolder, arguments); - } - - /** - * This can be used to launch the generation from a standalone application. - * - * @param args - * Arguments of the generation. - * @generated - */ - public static void main(String[] args) { - try { - if (args.length < 2) { - System.out.println("Arguments not valid : {model, folder}."); - } else { - URI modelURI = URI.createFileURI(args[0]); - File folder = new File(args[1]); - - List arguments = new ArrayList(); - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * Add in this list all the arguments used by the starting point of the generation - * If your main template is called on an element of your model and a String, you can - * add in "arguments" this "String" attribute. - */ - - ComponentPropertiesTests generator = new ComponentPropertiesTests(modelURI, folder, arguments); - - /* - * Add the properties from the launch arguments. - * If you want to programmatically add new properties, add them in "propertiesFiles" - * You can add the absolute path of a properties files, or even a project relative path. - * If you want to add another "protocol" for your properties files, please override - * "getPropertiesLoaderService(AcceleoService)" in order to return a new property loader. - * The behavior of the properties loader service is explained in the Acceleo documentation - * (Help -> Help Contents). - */ - - for (int i = 2; i < args.length; i++) { - generator.addPropertiesFile(args[i]); - } - - generator.doGenerate(new BasicMonitor()); - } - } catch (IOException e) { - e.printStackTrace(); - } - } - - /** - * Launches the generation described by this instance. - * - * @param monitor - * This will be used to display progress information to the user. - * @throws IOException - * This will be thrown if any of the output files cannot be saved to disk. - * @generated - */ - @Override - public void doGenerate(Monitor monitor) throws IOException { - /* - * TODO if you wish to change the generation as a whole, override this. The default behavior should - * be sufficient in most cases. If you want to change the content of this method, do NOT forget to - * change the "@generated" tag in the Javadoc of this method to "@generated NOT". Without this new tag, - * any compilation of the Acceleo module with the main template that has caused the creation of this - * class will revert your modifications. If you encounter a problem with an unresolved proxy during the - * generation, you can remove the comments in the following instructions to check for problems. Please - * note that those instructions may have a significant impact on the performances. - */ - - //org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(model); - - /* - * If you want to check for potential errors in your models before the launch of the generation, you - * use the code below. - */ - - //if (model != null && model.eResource() != null) { - // List errors = model.eResource().getErrors(); - // for (org.eclipse.emf.ecore.resource.Resource.Diagnostic diagnostic : errors) { - // System.err.println(diagnostic.toString()); - // } - //} - - super.doGenerate(monitor); - } - - /** - * If this generator needs to listen to text generation events, listeners can be returned from here. - * - * @return List of listeners that are to be notified when text is generated through this launch. - * @generated - */ - @Override - public List getGenerationListeners() { - List listeners = super.getGenerationListeners(); - /* - * TODO if you need to listen to generation event, add listeners to the list here. If you want to change - * the content of this method, do NOT forget to change the "@generated" tag in the Javadoc of this method - * to "@generated NOT". Without this new tag, any compilation of the Acceleo module with the main template - * that has caused the creation of this class will revert your modifications. - */ - return listeners; - } - - /** - * If you need to change the way files are generated, this is your entry point. - *

- * The default is {@link org.eclipse.acceleo.engine.generation.strategy.DefaultStrategy}; it generates - * files on the fly. If you only need to preview the results, return a new - * {@link org.eclipse.acceleo.engine.generation.strategy.PreviewStrategy}. Both of these aren't aware of - * the running Eclipse and can be used standalone. - *

- *

- * If you need the file generation to be aware of the workspace (A typical example is when you wanna - * override files that are under clear case or any other VCS that could forbid the overriding), then - * return a new {@link org.eclipse.acceleo.engine.generation.strategy.WorkspaceAwareStrategy}. - * Note, however, that this cannot be used standalone. - *

- *

- * All three of these default strategies support merging through JMerge. - *

- * - * @return The generation strategy that is to be used for generations launched through this launcher. - * @generated - */ - @Override - public IAcceleoGenerationStrategy getGenerationStrategy() { - return super.getGenerationStrategy(); - } - - /** - * This will be called in order to find and load the module that will be launched through this launcher. - * We expect this name not to contain file extension, and the module to be located beside the launcher. - * - * @return The name of the module that is to be launched. - * @generated - */ - @Override - public String getModuleName() { - return MODULE_FILE_NAME; - } - - /** - * If the module(s) called by this launcher require properties files, return their qualified path from - * here.Take note that the first added properties files will take precedence over subsequent ones if they - * contain conflicting keys. - *

- * Properties need to be in source folders, the path that we expect to get as a result of this call are of - * the form <package>.<properties file name without extension>. For example, if you have a file - * named "messages.properties" in package "org.eclipse.acceleo.sample", the path that needs be returned by - * a call to {@link #getProperties()} is "org.eclipse.acceleo.sample.messages". - *

- * - * @return The list of properties file we need to add to the generation context. - * @see java.util.ResourceBundle#getBundle(String) - * @generated - */ - @Override - public List getProperties() { - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO if your generation module requires access to properties files, add their qualified path to the list here. - * - * Properties files can be located in an Eclipse plug-in or in the file system (all Acceleo projects are Eclipse - * plug-in). In order to use properties files located in an Eclipse plugin, you need to add the path of the properties - * files to the "propertiesFiles" list: - * - * final String prefix = "platform:/plugin/"; - * final String pluginName = "org.eclipse.acceleo.module.sample"; - * final String packagePath = "/org/eclipse/acceleo/module/sample/properties/"; - * final String fileName = "default.properties"; - * propertiesFiles.add(prefix + pluginName + packagePath + fileName); - * - * With this mechanism, you can load properties files from your plugin or from another plugin. - * - * You may want to load properties files from the file system, for that you need to add the absolute path of the file: - * - * propertiesFiles.add("C:\Users\MyName\MyFile.properties"); - * - * If you want to let your users add properties files located in the same folder as the model: - * - * if (EMFPlugin.IS_ECLIPSE_RUNNING && model != null && model.eResource() != null) { - * propertiesFiles.addAll(AcceleoEngineUtils.getPropertiesFilesNearModel(model.eResource())); - * } - * - * To learn more about Properties Files, have a look at the Acceleo documentation (Help -> Help Contents). - */ - return propertiesFiles; - } - - /** - * Adds a properties file in the list of properties files. - * - * @param propertiesFile - * The properties file to add. - * @generated - * @since 3.1 - */ - @Override - public void addPropertiesFile(String propertiesFile) { - this.propertiesFiles.add(propertiesFile); - } - - /** - * This will be used to get the list of templates that are to be launched by this launcher. - * - * @return The list of templates to call on the module {@link #getModuleName()}. - * @generated - */ - @Override - public String[] getTemplateNames() { - return TEMPLATE_NAMES; - } - - /** - * This can be used to update the resource set's package registry with all needed EPackages. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerPackages(ResourceSet resourceSet) { - super.registerPackages(resourceSet); - if (!isInWorkspace(org.eclipse.emf.ecore.EcorePackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - } - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * If you need additional package registrations, you can register them here. The following line - * (in comment) is an example of the package registration for UML. - * - * You can use the method "isInWorkspace(Class c)" to check if the package that you are about to - * register is in the workspace. - * - * To register a package properly, please follow the following conventions: - * - * If the package is located in another plug-in, already installed in Eclipse. The following content should - * have been generated at the beginning of this method. Do not register the package using this mechanism if - * the metamodel is located in the workspace. - * - * if (!isInWorkspace(UMLPackage.class)) { - * // The normal package registration if your metamodel is in a plugin. - * resourceSet.getPackageRegistry().put(UMLPackage.eNS_URI, UMLPackage.eINSTANCE); - * } - * - * If the package is located in another project in your workspace, the plugin containing the package has not - * been register by EMF and Acceleo should register it automatically. If you want to use the generator in - * stand alone, the regular registration (seen a couple lines before) is needed. - * - * To learn more about Package Registration, have a look at the Acceleo documentation (Help -> Help Contents). - */ - } - - /** - * This can be used to update the resource set's resource factory registry with all needed factories. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerResourceFactories(ResourceSet resourceSet) { - super.registerResourceFactories(resourceSet); - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO If you need additional resource factories registrations, you can register them here. the following line - * (in comment) is an example of the resource factory registration for UML. - * - * If you want to use the generator in stand alone, the resource factory registration will be required. - * - * To learn more about the registration of Resource Factories, have a look at the Acceleo documentation (Help -> Help Contents). - */ - - // resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - } - - @Override - protected void postGenerate(ResourceSet rs) { - // Don't unload resources - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentPropertiesTests.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentPropertiesTests.mtl deleted file mode 100644 index 12c6b6b2f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentPropertiesTests.mtl +++ /dev/null @@ -1,112 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] - -[module ComponentPropertiesTests('http://www.eclipse.org/emf/eef/components/1.0.0','http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends ComponentCommonTests/] - -[import common /] -[import naming /] -[import testsNaming /] -[import widgetTest /] - -[template public PropertySection(peContext : PropertiesEditionContext)] -[comment @main /] -[for (pec : PropertiesEditionComponent | peContext.eAllContents(PropertiesEditionComponent)) ? (pec.mustBeGenerated() and pec.testMustBeGenerated())] - [for (view : View | pec.views) ? (view.explicit)] -[file (pec.fullFilePath(), false)] -[peContext.associatedGenModel().licenceText().trim()/] -[packagePropertySection(pec)/] - -[headPropertySection(peContext, pec)/] -[peContext.additionalImports()/] -/** - * TestCase for [pec.name/] - * [peContext.associatedGenModel().authorText().trim()/] - */ -public class [pec.propertyTestCase()/] extends SWTBotEEFTestCase { - -[testCasePropertySection(peContext, pec)/] -[for (peElement : PropertiesEditionElement | pec.properties->select(oclIsKindOf(components::PropertiesEditionElement)).oclAsType(components::PropertiesEditionElement)) ? (pec.canGenerateTest(peElement) <> 'false')] -[if (not peElement.isAbstractType())] -[testAddPropertySection(pec, peElement)/] -[if (peElement.canRemove())] -[testRemovePropertySection(pec, peElement)/] -[/if] -[/if] -[/for] -[for (peElement : PropertiesEditionElement | pec.properties->select(oclIsKindOf(components::PropertiesEditionElement)).oclAsType(components::PropertiesEditionElement)) ? (pec.canGenerateTest(peElement) <> 'false')] -[if (not peElement.isAbstractType())] -[additionnalMethodsForWidgets(pec, peElement)/] -[additionalMethodsPropertiesForTableComposition(pec, peElement)/] -[/if] -[/for] -[additionalMethods()/] - -} - [/file] - [/for] - [/for] -[/template] - -[template public testAddPropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[initializeExpectedModelPropertySection(pec, peElement)/] -[commentTestPropertySection()/] -[testEditPropertySection(pec, peElement)/] -[editFeaturePropertySection(pec, peElement)/] -[comparePropertySection(pec, peElement)/] -[/template] - -[template public testRemovePropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[initializeRemoveExpectedModelPropertySection(pec, peElement)/] -[commentTestPropertySection()/] -[testRemoveEditPropertySection(pec, peElement)/] -[removeFeaturePropertySection(pec, peElement)/] -[comparePropertySection(pec, peElement)/] -[/template] - -[template public fullFilePath(pec : PropertiesEditionComponent)] -[pec.model.completePackage().toPath()/]/tests/junit/properties/[pec.propertyTestCase()/].java -[/template] - -[comment overrides this template if additional imports is needed/] -[template public additionalImports(peContext : PropertiesEditionContext) overrides additionalImports] -import org.eclipse.swtbot.swt.finder.widgets.SWTBotShell; -[/template] - -[comment overrides this template if additional methods are needed/] -[template public additionalMethods()] -[/template] - -[template public packagePropertySection(pec : PropertiesEditionComponent)] -package [pec.model.completePackage()/].tests.junit.properties; -[/template] - -[template public editFeaturePropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - // Open the EEF properties view to edit the [pec.model.name/] element - EObject firstInstanceOf = EEFTestsModelsUtils.getFirstInstanceOf(bot.getActiveResource(), [pec.model.name.toLowerFirst()/]MetaClass); - if (firstInstanceOf == null) - throw new InputModelInvalidException([pec.model.name.toLowerFirst()/]MetaClass.getName()); - SWTBotView propertiesView = bot.prepareLiveEditing(modelEditor, firstInstanceOf, [if (pec.involvedViews()->size() > 1)]"[peElement.views->first().owningView().viewKey(pec).toASCII().substituteAll(' ', '_')/]"[else]null[/if]); - - [pec.editPropertyFeature(peElement)/] -[/template] - -[template public removeFeaturePropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - // Open the EEF properties view to edit the [pec.model.name/] element - EObject firstInstanceOf = EEFTestsModelsUtils.getFirstInstanceOf(bot.getActiveResource(), [pec.model.name.toLowerFirst()/]MetaClass); - if (firstInstanceOf == null) - throw new InputModelInvalidException([pec.model.name.toLowerFirst()/]MetaClass.getName()); - - SWTBotView propertiesView = bot.prepareLiveEditing(modelEditor, firstInstanceOf, [if (pec.involvedViews()->size() > 1)]"[peElement.views->first().owningView().viewKey(pec).toASCII().substituteAll(' ', '_')/]"[else]null[/if]); - - [pec.removePropertyFeature(peElement)/] -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentTests.java b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentTests.java deleted file mode 100644 index b302be241..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentTests.java +++ /dev/null @@ -1,420 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.tests.codegen.main.cases; - -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.acceleo.engine.event.IAcceleoTextGenerationListener; -import org.eclipse.acceleo.engine.generation.strategy.IAcceleoGenerationStrategy; -import org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; - -/** - * Entry point of the 'ComponentTests' generation module. - * - * @author Nathalie Lepine - * @generated - */ -public class ComponentTests extends AbstractAcceleoGenerator { - /** - * The name of the module. - * - * @generated - */ - public static final String MODULE_FILE_NAME = "/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentTests"; - - /** - * The name of the templates that are to be generated. - * - * @generated - */ - public static final String[] TEMPLATE_NAMES = { "PropertySection" }; - - /** - * The list of properties files from the launch parameters (Launch configuration). - * - * @generated - */ - private List propertiesFiles = new ArrayList(); - - /** - * Allows the public constructor to be used. Note that a generator created - * this way cannot be used to launch generations before one of - * {@link #initialize(EObject, File, List)} or - * {@link #initialize(URI, File, List)} is called. - *

- * The main reason for this constructor is to allow clients of this - * generation to call it from another Java file, as it allows for the - * retrieval of {@link #getProperties()} and - * {@link #getGenerationListeners()}. - *

- * - * @generated - */ - public ComponentTests() { - // Empty implementation - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param modelURI - * URI where the model on which this generator will be used is located. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in three scenarios : the module cannot be found, it cannot be loaded, or - * the model cannot be loaded. - * @generated - */ - public ComponentTests(URI modelURI, File targetFolder, - List arguments) throws IOException { - initialize(modelURI, targetFolder, arguments); - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param model - * We'll iterate over the content of this element to find Objects matching the first parameter - * of the template we need to call. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in two scenarios : the module cannot be found, or it cannot be loaded. - * @generated - */ - public ComponentTests(EObject model, File targetFolder, - List arguments) throws IOException { - initialize(model, targetFolder, arguments); - } - - /** - * This can be used to launch the generation from a standalone application. - * - * @param args - * Arguments of the generation. - * @generated - */ - public static void main(String[] args) { - try { - if (args.length < 2) { - System.out.println("Arguments not valid : {model, folder}."); - } else { - URI modelURI = URI.createFileURI(args[0]); - File folder = new File(args[1]); - - List arguments = new ArrayList(); - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * Add in this list all the arguments used by the starting point of the generation - * If your main template is called on an element of your model and a String, you can - * add in "arguments" this "String" attribute. - */ - - ComponentTests generator = new ComponentTests(modelURI, folder, arguments); - - /* - * Add the properties from the launch arguments. - * If you want to programmatically add new properties, add them in "propertiesFiles" - * You can add the absolute path of a properties files, or even a project relative path. - * If you want to add another "protocol" for your properties files, please override - * "getPropertiesLoaderService(AcceleoService)" in order to return a new property loader. - * The behavior of the properties loader service is explained in the Acceleo documentation - * (Help -> Help Contents). - */ - - for (int i = 2; i < args.length; i++) { - generator.addPropertiesFile(args[i]); - } - - generator.doGenerate(new BasicMonitor()); - } - } catch (IOException e) { - e.printStackTrace(); - } - } - - /** - * Launches the generation described by this instance. - * - * @param monitor - * This will be used to display progress information to the user. - * @throws IOException - * This will be thrown if any of the output files cannot be saved to disk. - * @generated - */ - @Override - public void doGenerate(Monitor monitor) throws IOException { - /* - * TODO if you wish to change the generation as a whole, override this. The default behavior should - * be sufficient in most cases. If you want to change the content of this method, do NOT forget to - * change the "@generated" tag in the Javadoc of this method to "@generated NOT". Without this new tag, - * any compilation of the Acceleo module with the main template that has caused the creation of this - * class will revert your modifications. If you encounter a problem with an unresolved proxy during the - * generation, you can remove the comments in the following instructions to check for problems. Please - * note that those instructions may have a significant impact on the performances. - */ - - //org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(model); - - /* - * If you want to check for potential errors in your models before the launch of the generation, you - * use the code below. - */ - - //if (model != null && model.eResource() != null) { - // List errors = model.eResource().getErrors(); - // for (org.eclipse.emf.ecore.resource.Resource.Diagnostic diagnostic : errors) { - // System.err.println(diagnostic.toString()); - // } - //} - - super.doGenerate(monitor); - } - - /** - * If this generator needs to listen to text generation events, listeners can be returned from here. - * - * @return List of listeners that are to be notified when text is generated through this launch. - * @generated - */ - @Override - public List getGenerationListeners() { - List listeners = super.getGenerationListeners(); - /* - * TODO if you need to listen to generation event, add listeners to the list here. If you want to change - * the content of this method, do NOT forget to change the "@generated" tag in the Javadoc of this method - * to "@generated NOT". Without this new tag, any compilation of the Acceleo module with the main template - * that has caused the creation of this class will revert your modifications. - */ - return listeners; - } - - /** - * If you need to change the way files are generated, this is your entry point. - *

- * The default is {@link org.eclipse.acceleo.engine.generation.strategy.DefaultStrategy}; it generates - * files on the fly. If you only need to preview the results, return a new - * {@link org.eclipse.acceleo.engine.generation.strategy.PreviewStrategy}. Both of these aren't aware of - * the running Eclipse and can be used standalone. - *

- *

- * If you need the file generation to be aware of the workspace (A typical example is when you wanna - * override files that are under clear case or any other VCS that could forbid the overriding), then - * return a new {@link org.eclipse.acceleo.engine.generation.strategy.WorkspaceAwareStrategy}. - * Note, however, that this cannot be used standalone. - *

- *

- * All three of these default strategies support merging through JMerge. - *

- * - * @return The generation strategy that is to be used for generations launched through this launcher. - * @generated - */ - @Override - public IAcceleoGenerationStrategy getGenerationStrategy() { - return super.getGenerationStrategy(); - } - - /** - * This will be called in order to find and load the module that will be launched through this launcher. - * We expect this name not to contain file extension, and the module to be located beside the launcher. - * - * @return The name of the module that is to be launched. - * @generated - */ - @Override - public String getModuleName() { - return MODULE_FILE_NAME; - } - - /** - * If the module(s) called by this launcher require properties files, return their qualified path from - * here.Take note that the first added properties files will take precedence over subsequent ones if they - * contain conflicting keys. - *

- * Properties need to be in source folders, the path that we expect to get as a result of this call are of - * the form <package>.<properties file name without extension>. For example, if you have a file - * named "messages.properties" in package "org.eclipse.acceleo.sample", the path that needs be returned by - * a call to {@link #getProperties()} is "org.eclipse.acceleo.sample.messages". - *

- * - * @return The list of properties file we need to add to the generation context. - * @see java.util.ResourceBundle#getBundle(String) - * @generated - */ - @Override - public List getProperties() { - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO if your generation module requires access to properties files, add their qualified path to the list here. - * - * Properties files can be located in an Eclipse plug-in or in the file system (all Acceleo projects are Eclipse - * plug-in). In order to use properties files located in an Eclipse plugin, you need to add the path of the properties - * files to the "propertiesFiles" list: - * - * final String prefix = "platform:/plugin/"; - * final String pluginName = "org.eclipse.acceleo.module.sample"; - * final String packagePath = "/org/eclipse/acceleo/module/sample/properties/"; - * final String fileName = "default.properties"; - * propertiesFiles.add(prefix + pluginName + packagePath + fileName); - * - * With this mechanism, you can load properties files from your plugin or from another plugin. - * - * You may want to load properties files from the file system, for that you need to add the absolute path of the file: - * - * propertiesFiles.add("C:\Users\MyName\MyFile.properties"); - * - * If you want to let your users add properties files located in the same folder as the model: - * - * if (EMFPlugin.IS_ECLIPSE_RUNNING && model != null && model.eResource() != null) { - * propertiesFiles.addAll(AcceleoEngineUtils.getPropertiesFilesNearModel(model.eResource())); - * } - * - * To learn more about Properties Files, have a look at the Acceleo documentation (Help -> Help Contents). - */ - return propertiesFiles; - } - - /** - * Adds a properties file in the list of properties files. - * - * @param propertiesFile - * The properties file to add. - * @generated - * @since 3.1 - */ - @Override - public void addPropertiesFile(String propertiesFile) { - this.propertiesFiles.add(propertiesFile); - } - - /** - * This will be used to get the list of templates that are to be launched by this launcher. - * - * @return The list of templates to call on the module {@link #getModuleName()}. - * @generated - */ - @Override - public String[] getTemplateNames() { - return TEMPLATE_NAMES; - } - - /** - * This can be used to update the resource set's package registry with all needed EPackages. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerPackages(ResourceSet resourceSet) { - super.registerPackages(resourceSet); - if (!isInWorkspace(org.eclipse.emf.ecore.EcorePackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - } - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * If you need additional package registrations, you can register them here. The following line - * (in comment) is an example of the package registration for UML. - * - * You can use the method "isInWorkspace(Class c)" to check if the package that you are about to - * register is in the workspace. - * - * To register a package properly, please follow the following conventions: - * - * If the package is located in another plug-in, already installed in Eclipse. The following content should - * have been generated at the beginning of this method. Do not register the package using this mechanism if - * the metamodel is located in the workspace. - * - * if (!isInWorkspace(UMLPackage.class)) { - * // The normal package registration if your metamodel is in a plugin. - * resourceSet.getPackageRegistry().put(UMLPackage.eNS_URI, UMLPackage.eINSTANCE); - * } - * - * If the package is located in another project in your workspace, the plugin containing the package has not - * been register by EMF and Acceleo should register it automatically. If you want to use the generator in - * stand alone, the regular registration (seen a couple lines before) is needed. - * - * To learn more about Package Registration, have a look at the Acceleo documentation (Help -> Help Contents). - */ - } - - /** - * This can be used to update the resource set's resource factory registry with all needed factories. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerResourceFactories(ResourceSet resourceSet) { - super.registerResourceFactories(resourceSet); - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO If you need additional resource factories registrations, you can register them here. the following line - * (in comment) is an example of the resource factory registration for UML. - * - * If you want to use the generator in stand alone, the resource factory registration will be required. - * - * To learn more about the registration of Resource Factories, have a look at the Acceleo documentation (Help -> Help Contents). - */ - - // resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - } - - @Override - protected void postGenerate(ResourceSet rs) { - // Don't unload resources - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentTests.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentTests.mtl deleted file mode 100644 index a4a7d3d41..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/ComponentTests.mtl +++ /dev/null @@ -1,112 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module ComponentTests('http://www.eclipse.org/emf/eef/components/1.0.0','http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends ComponentCommonTests/] - -[import common /] -[import naming /] -[import testsNaming /] -[import widgetTest /] - -[template public PropertySection(peContext : PropertiesEditionContext)] -[comment @main /] -[for (pec : PropertiesEditionComponent | peContext.eAllContents(PropertiesEditionComponent)) ? (pec.mustBeGenerated() and pec.testMustBeGenerated())] - [for (view : View | pec.views) ? (view.explicit)] -[file (pec.fullFilePath(), false)] -[peContext.associatedGenModel().licenceText().trim()/] -[packagePropertySection(pec)/] - -[headPropertySection(peContext, pec)/] -[peContext.additionalImports()/] -/** - * TestCase for [pec.name/] - * [peContext.associatedGenModel().authorText().trim()/] - */ -public class [pec.testCase()/] extends SWTBotEEFTestCase { - -[testCasePropertySection(peContext, pec)/] -[for (peElement : PropertiesEditionElement | pec.properties->select(oclIsKindOf(components::PropertiesEditionElement)).oclAsType(components::PropertiesEditionElement)) ? (pec.canGenerateTest(peElement) <> 'false')] -[if (not peElement.isAbstractType())] -[testAddPropertySection(pec, peElement)/] -[if (peElement.canRemove())] -[testRemovePropertySection(pec, peElement)/] -[/if] -[/if] -[/for] -[for (peElement : PropertiesEditionElement | pec.properties->select(oclIsKindOf(components::PropertiesEditionElement)).oclAsType(components::PropertiesEditionElement)) ? (pec.canGenerateTest(peElement) <> 'false')] -[if (not peElement.isAbstractType())] -[additionnalMethodsForWidgets(pec, peElement)/] -[additionalMethodsForTableComposition(pec, peElement)/] -[/if] -[/for] -[additionalMethods()/] - -} - [/file] - [/for] - [/for] -[/template] - -[template public testAddPropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[initializeExpectedModelPropertySection(pec, peElement)/] -[commentTestPropertySection()/] -[testEditPropertySection(pec, peElement)/] -[editFeaturePropertySection(pec, peElement)/] -[comparePropertySection(pec, peElement)/] -[/template] - -[template public testRemovePropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[initializeRemoveExpectedModelPropertySection(pec, peElement)/] -[commentTestPropertySection()/] -[testRemoveEditPropertySection(pec, peElement)/] -[removeFeaturePropertySection(pec, peElement)/] -[comparePropertySection(pec, peElement)/] -[/template] - -[template public fullFilePath(pec : PropertiesEditionComponent)] -[pec.model.completePackage().toPath()/]/tests/junit/[pec.testCase()/].java -[/template] - -[comment overrides this template if additional imports is needed/] -[template public additionalImports(peContext : PropertiesEditionContext) overrides additionalImports] -import org.eclipse.swtbot.swt.finder.widgets.SWTBotShell; -[/template] - -[comment overrides this template if additional methods are needed/] -[template public additionalMethods()] -[/template] - -[template public packagePropertySection(pec : PropertiesEditionComponent)] -package [pec.model.completePackage()/].tests.junit; -[/template] - -[template public editFeaturePropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - // Open the EEF wizard (by double click) to edit the [pec.model.name/] element - EObject firstInstanceOf = EEFTestsModelsUtils.getFirstInstanceOf(bot.getActiveResource(), [pec.model.name.toLowerFirst()/]MetaClass); - if (firstInstanceOf == null) - throw new InputModelInvalidException([pec.model.name.toLowerFirst()/]MetaClass.getName()); - - SWTBotShell wizardShell = bot.prepareBatchEditing(modelEditor, [pec.model.name.toLowerFirst()/]MetaClass, firstInstanceOf, [if (pec.involvedViews()->size() > 1)]"[peElement.views->first().owningView().viewKey(pec).toASCII().substituteAll(' ', '_')/]"[else]null[/if]); - - [pec.editFeature(peElement)/] -[/template] - -[template public removeFeaturePropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - // Open the EEF wizard (by double click) to edit the [pec.model.name/] element - EObject firstInstanceOf = EEFTestsModelsUtils.getFirstInstanceOf(bot.getActiveResource(), [pec.model.name.toLowerFirst()/]MetaClass); - if (firstInstanceOf == null) - throw new InputModelInvalidException([pec.model.name.toLowerFirst()/]MetaClass.getName()); - - SWTBotShell wizardShell = bot.prepareBatchEditing(modelEditor, [pec.model.name.toLowerFirst()/]MetaClass, firstInstanceOf, [if (pec.involvedViews()->size() > 1)]"[peElement.views->first().owningView().viewKey(pec).toASCII().substituteAll(' ', '_')/]"[else]null[/if]); - - [pec.removeFeature(peElement)/] -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/common/ComponentCommonTests.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/common/ComponentCommonTests.mtl deleted file mode 100644 index 7f06a8924..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/main/cases/common/ComponentCommonTests.mtl +++ /dev/null @@ -1,283 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module ComponentCommonTests('http://www.eclipse.org/emf/eef/components/1.0.0','http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import common /] -[import naming /] -[import testsNaming /] -[import typeUtils /] -[import widgetTest /] - -[template public headPropertySection(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent)] -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.command.CompoundCommand; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.command.AddCommand; -import org.eclipse.emf.edit.command.SetCommand; -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import [pec.model.qualifiedName()/]; -import [pec.model.qualifiedMetamodelPackage()/]; -[for (viewRepository : ViewsRepository | pec.views.owningViewsRepository()->asSet())] -import [viewRepository.qualifiedMessagesProvider()/]; -[/for] -[for (peElement : components::PropertiesEditionElement | pec.properties->select(oclIsTypeOf(components::PropertiesEditionElement)).oclAsType(components::PropertiesEditionElement))] -[if (peElement.model.eType.oclIsKindOf(ecore::EClass))]import [peElement.model.eType.qualifiedName()/]; -[/if] -[/for] -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.tests.SWTBotEEFTestCase; -import org.eclipse.emf.eef.runtime.tests.exceptions.InputModelInvalidException; -import org.eclipse.emf.eef.runtime.tests.exceptions.WidgetInvalidException; -import org.eclipse.emf.eef.runtime.tests.utils.EEFTestsModelsUtils; -import org.eclipse.emf.eef.runtime.tests.utils.EEFTestsResourceUtils; -import org.eclipse.emf.eef.runtime.tests.utils.UIConstants; -import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotEditor; -[additionalImports()/] -[/template] - -[template public additionalImports (peContext : PropertiesEditionContext) /] - - -[template public testCasePropertySection(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent)] - /** - * The EClass of the type to edit - */ - private EClass [pec.model.name.toLowerFirst()/]MetaClass = [pec.model.ePackage.metamodelPackage()/].eINSTANCE.get[pec.model.name/](); - - /** - * The type to edit - */ - private EObject [pec.model.name.toLowerFirst()/]; - - [for (peElement : PropertiesEditionElement | pec.properties->select(oclIsTypeOf(components::PropertiesEditionElement)).oclAsType(components::PropertiesEditionElement)->select(model.oclIsTypeOf(ecore::EAttribute) and model.oclAsType(ecore::EAttribute).isEnum())) separator ('\n')] - /** - * The enum value for the enum class [peElement.model.name.toLowerFirst()/] - */ - private Object enumValueFor[peElement.model.name.toUpperFirst()/]; - [/for] - [for (peElement : PropertiesEditionElement | pec.properties->select(oclIsTypeOf(components::PropertiesEditionElement)).oclAsType(components::PropertiesEditionElement)->select(pee : PropertiesEditionElement | pee.model.oclIsTypeOf(ecore::EReference) and pee.isEOFCVorReferencesTable())->asSet()) separator ('\n')] - /** - * The reference value for the reference class [peElement.model.name.toLowerFirst()/] - */ - private Object referenceValueFor[peElement.model.name.toUpperFirst()/]; - [/for] - [for (name : String | pec.properties->select(oclIsTypeOf(components::PropertiesEditionElement)).oclAsType(components::PropertiesEditionElement)->select(model.oclIsTypeOf(ecore::EReference)).model.eType->select(name<>pec.model.name).name->asSet()) separator ('\n')] - /** - * The EClass of the reference to edit - */ - private EClass [name.toLowerFirst()/]MetaClass = [pec.model.ePackage.metamodelPackage()/].eINSTANCE.get[name/](); - [/for] -[if (pec.properties->select(oclIsTypeOf(components::PropertiesEditionElement)).oclAsType(components::PropertiesEditionElement)->select(model.oclIsTypeOf(ecore::EReference) and canRemove())->asSet()->notEmpty())] - /** - * The eObjects list contained in widgets - */ - private List allInstancesOf; -[/if] - /** - * Updated value of the feature - */ - private static final String UPDATED_VALUE = "value2"; - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.tests.SWTBotEEFTestCase#getExpectedModelName() - */ - protected String getExpectedModelName() { - return "expected.[pec.model.ePackage.metamodelPrefix().toLowerFirst()/]"; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.tests.SWTBotEEFTestCase#getInputModelFolder() - */ - protected String getInputModelFolder() { - return "input"; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.tests.SWTBotEEFTestCase#getInputModelName() - */ - protected String getInputModelName() { - return "input.[pec.model.ePackage.metamodelPrefix().toLowerFirst()/]"; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.tests.SWTBotEEFTestCase#getTestsProjectName() - */ - protected String getTestsProjectName() { - return "[peContext.associatedGenModel().testsGenDirectory.tokenize('/')->at(1)/]"; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.tests.SWTBotEEFTestCase#getExpectedModelFolder() - */ - protected String getExpectedModelFolder() { - // The project that contains models for tests - return "expected"; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.tests.SWTBotEEFTestCase#getImportModelsFolder() - */ - protected String getImportModelsFolder() { - return "models"; - } - [/template] - -[template public initializeExpectedModelPropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - /** - * Create the expected model from the input model - * @throws InputModelInvalidException error during expected model initialization - * @throws IOException error during expected model serialization - */ - protected void initializeExpectedModelFor[pec.model.name.toUpperFirst()/][peElement.name.toUpperFirst()/]() throws InputModelInvalidException, IOException { - // Create the expected model content by applying the attempted command on a copy of the input model content - createExpectedModel(); - EObject [pec.model.name.toLowerFirst()/] = EEFTestsModelsUtils.getFirstInstanceOf(expectedModel, [pec.model.name.toLowerFirst()/]MetaClass); - if ([pec.model.name.toLowerFirst()/] == null) - throw new InputModelInvalidException([pec.model.name.toLowerFirst()/]MetaClass.getName()); - [pec.updateExpectedModel(peElement)/] - editingDomain.getCommandStack().execute(cc); - expectedModel.save(Collections.EMPTY_MAP); - } -[/template] - -[template public initializeRemoveExpectedModelPropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) ? (peElement.canRemove())] - /** - * Create the expected model from the input model - * @throws InputModelInvalidException error during expected model initialization - * @throws IOException error during expected model serialization - */ - protected void initializeRemoveExpectedModelFor[pec.model.name.toUpperFirst()/][peElement.name.toUpperFirst()/]() throws InputModelInvalidException, IOException { - // Create the expected model content by applying the attempted command on a copy of the input model content - createExpectedModel(); - EObject [pec.model.name.toLowerFirst()/] = EEFTestsModelsUtils.getFirstInstanceOf(expectedModel, [pec.model.name.toLowerFirst()/]MetaClass); - if ([pec.model.name.toLowerFirst()/] == null) - throw new InputModelInvalidException([pec.model.name.toLowerFirst()/]MetaClass.getName()); - [pec.removeExpectedModel(peElement)/] - editingDomain.getCommandStack().execute(cc); - expectedModel.save(Collections.EMPTY_MAP); - } -[/template] - -[template public testEditPropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - public void testEdit[pec.name.toUpperFirst()/][peElement.name.toUpperFirst()/]() throws Exception { - - // Import the input model - initializeInputModel(); - - [pec.model.name.toLowerFirst()/] = EEFTestsModelsUtils.getFirstInstanceOf(bot.getActiveResource(), [pec.model.name.toLowerFirst()/]MetaClass); - if ([pec.model.name.toLowerFirst()/] == null) - throw new InputModelInvalidException([pec.model.name.toLowerFirst()/]MetaClass.getName()); - - [if (peElement.model.oclIsTypeOf(ecore::EAttribute) and peElement.model.oclAsType(ecore::EAttribute).isEnum())] - enumValueFor[peElement.model.name.toUpperFirst()/] = bot.changeEnumLiteralValue([peElement.model.eContainingClass.metamodelPackage()/].eINSTANCE.get[peElement.model.eType.name/](), (([pec.model.name/])[pec.model.name.toLowerFirst()/]).get[peElement.model.name.toUpperFirst()/]().getLiteral()); - [/if] - // Create the expected model - initializeExpectedModelFor[pec.model.name.toUpperFirst()/][peElement.name.toUpperFirst()/](); - - // Open the input model with the treeview editor - SWTBotEditor modelEditor = bot.openActiveModel(); - -[/template] - -[template public testRemoveEditPropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) ? (peElement.canRemove())] - public void testRemove[pec.name.toUpperFirst()/][peElement.name.toUpperFirst()/]() throws Exception { - - // Import the input model - initializeInputModel(); - - [pec.model.name.toLowerFirst()/] = EEFTestsModelsUtils.getFirstInstanceOf(bot.getActiveResource(), [pec.model.name.toLowerFirst()/]MetaClass); - if ([pec.model.name.toLowerFirst()/] == null) - throw new InputModelInvalidException([pec.model.name.toLowerFirst()/]MetaClass.getName()); - - [if (peElement.model.oclIsTypeOf(ecore::EAttribute) and peElement.model.oclAsType(ecore::EAttribute).isEnum())] - enumValueFor[peElement.model.name.toUpperFirst()/] = bot.changeEnumLiteralValue([peElement.model.eContainingClass.metamodelPackage()/].eINSTANCE.get[peElement.model.eType.name/](), (([pec.model.name/])[pec.model.name.toLowerFirst()/]).get[peElement.model.name.toUpperFirst()/]().getLiteral()); - [/if] - // Create the expected model - initializeRemoveExpectedModelFor[pec.model.name.toUpperFirst()/][peElement.name.toUpperFirst()/](); - - // Open the input model with the treeview editor - SWTBotEditor modelEditor = bot.openActiveModel(); - -[/template] - -[template public comparePropertySection(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - - // Save the modification - bot.finalizeEdition(modelEditor); - - // Compare real model with expected model - assertExpectedModelReached(expectedModel); - - // Delete the input model - deleteModels(); - - } -[/template] - -[query public testMustBeGenerated(pec : PropertiesEditionComponent) : Boolean = - not pec.model.oclAsType(EClass).abstract - and pec.properties->select(pee : mapping::AbstractPropertyBinding | - pee.oclIsKindOf(components::PropertiesEditionElement) - and pec.canGenerateTest(pee.oclAsType(components::PropertiesEditionElement)) <> 'false')->notEmpty()/] - -[template public commentTestPropertySection()] - /** - * Test the editor properties : - * - init the input model - * - calculate the expected model - * - initialize the model editor - * - change the properties in the editor properties - * - compare the expected and the real model : if they are equals the test pass - * - delete the models - */ -[/template] - -[query public isAbstractType(peElement : PropertiesEditionElement) : Boolean = - if (peElement.model.eType->select(oclIsKindOf(ecore::EClass))->notEmpty()) then - peElement.model.eType.oclAsType(ecore::EClass).abstract - else - false - endif/] - -[query public isCompositionType(peElement : PropertiesEditionElement) : Boolean = - peElement.representationName('AdvancedTableComposition') or peElement.representationName('TableComposition')/] - -[comment][query public isCompositionType(peElement : PropertiesEditionElement) : Boolean = - peElement.model->select(oclIsTypeOf(ecore::EReference)).oclAsType(ecore::EReference).isContainment()/][/comment] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/common/testsNaming.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/common/testsNaming.mtl deleted file mode 100644 index 0e7abe22d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/common/testsNaming.mtl +++ /dev/null @@ -1,23 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module testsNaming('http://www.eclipse.org/emf/eef/components/1.0.0')/] - -[import common /] - -[template public testCase(pec : PropertiesEditionComponent)] -[pec.name.toJavaClassifier()/]TestCase -[/template] - -[template public propertyTestCase(pec : PropertiesEditionComponent)] -[pec.name.toJavaClassifier()/]PropertiesTestCase -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/api/widgetTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/api/widgetTest.mtl deleted file mode 100644 index 530bdfd68..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/api/widgetTest.mtl +++ /dev/null @@ -1,77 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module widgetTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import common /] -[import naming /] - -[comment defines if a test can be generated for this case /] -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)]false[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - // FIXME : define 'updateExpectedModel' (from widgetTest.mtl) for case ([peElement.views->first().representation.name/] - [peElement.model.eType.name/]) -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - // FIXME : define 'editFeature' (from widgetTest.mtl) for case ([peElement.views->first().representation.name/] - [peElement.model.eType.name/]) -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - // FIXME : define 'editPropertyFeature' (from widgetTest.mtl) for case ([peElement.views->first().representation.name/] - [peElement.model.eType.name/]) -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - // FIXME : define 'removeExpectedModel' (from widgetTest.mtl) for case ([peElement.views->first().representation.name/] - [peElement.model.eType.name/]) -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - // FIXME : define 'removeFeature' (from widgetTest.mtl) for case ([peElement.views->first().representation.name/] - [peElement.model.eType.name/]) -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] - // FIXME : define 'removePropertyFeature' (from widgetTest.mtl) for case ([peElement.views->first().representation.name/] - [peElement.model.eType.name/]) -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[template public additionalMethodsPropertiesForTableComposition(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[template public additionalMethodsForTableComposition(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement)] - // FIXME : define 'editFeature' for structural feature (from widgetTest.mtl) for case ([peElement.views->first().representation.name/] - [peElement.model.eType.name/]) -[/template] - -[template public removeFeature(f : EStructuralFeature, peElement : PropertiesEditionElement)] - // FIXME : define 'removeFeature' (from widgetTest.mtl) for case ([peElement.views->first().representation.name/] - [peElement.model.eType.name/]) -[/template] - -[query public isEOFCVorReferencesTable(peElement : PropertiesEditionElement) : Boolean = - peElement.representationName('EObjectFlatComboViewer')or peElement.representationName('AdvancedEObjectFlatComboViewer') - or peElement.representationName('ReferencesTable') or peElement.representationName('AdvancedReferencesTable') - or peElement.representationName('FlatReferencesTable')/] - -[query public canRemoveEOFCVorReferencesTable(peElement : PropertiesEditionElement) : Boolean = - (peElement.representationName('EObjectFlatComboViewer') and not peElement.model.required) or peElement.representationName('AdvancedEObjectFlatComboViewer') - or peElement.representationName('ReferencesTable') or peElement.representationName('AdvancedReferencesTable') or peElement.representationName('FlatReferencesTable')/] - -[query public canRemove(peElement : PropertiesEditionElement) : Boolean = - peElement.canRemoveEOFCVorReferencesTable() or - peElement.representationName('TableComposition')or peElement.representationName('AdvancedTableComposition')/] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/EMFComboViewerTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/EMFComboViewerTest.mtl deleted file mode 100644 index 63fbcc62b..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/EMFComboViewerTest.mtl +++ /dev/null @@ -1,60 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module EMFComboViewerTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isEMFComboViewerEnum())]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isEMFComboViewerEnum())] -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -cc.append(SetCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], [peElement.model.eContainingClass.metamodelPackage()/].eINSTANCE.get[peElement.model.eType.name/]().getEEnumLiteralByLiteral(enumValueFor[peElement.model.name.toUpperFirst()/].toString()).getInstance())); -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isEMFComboViewerEnum())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editEMFComboViewerFeature(wizardShell, [peElement.views->first().editorID()/], enumValueFor[peElement.model.name.toUpperFirst()/]); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isEMFComboViewerEnum())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element - bot.editEMFComboViewer([peElement.views->first().editorID()/], [peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]()); -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isEMFComboViewerEnum())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editPropertyEMFComboViewerFeature(propertiesView, [peElement.views->first().editorID()/], enumValueFor[peElement.model.name.toUpperFirst()/], bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[query public isEMFComboViewerEnum(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EAttribute)) - then false - else peElement.representationName('EMFComboViewer') and peElement.model.oclAsType(ecore::EAttribute).isEnum() - endif/] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedEobjectFlatComboViewerTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedEobjectFlatComboViewerTest.mtl deleted file mode 100644 index 55d7df391..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedEobjectFlatComboViewerTest.mtl +++ /dev/null @@ -1,70 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module advancedEobjectFlatComboViewerTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isAEOFCVReference())]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isAEOFCVReference())] -CompoundCommand cc = new CompoundCommand(); - [comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] - allInstancesOf = EEFTestsModelsUtils.getAllInstancesOf(expectedModel, [peElement.model.eType.name.toLowerFirst()/]MetaClass); - referenceValueFor[peElement.model.name.toUpperFirst()/] = bot.changeReferenceValue(allInstancesOf, (([pec.model.name.toUpperFirst()/])[pec.model.name.toLowerFirst()/]).get[peElement.model.name.toUpperFirst()/]()); - cc.append(SetCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], referenceValueFor[peElement.model.name.toUpperFirst()/])); -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isAEOFCVReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editAdvancedEObjectFlatComboViewerFeature(wizardShell, [peElement.views->first().editorID()/], referenceValueFor[peElement.model.name.toUpperFirst()/]); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isAEOFCVReference())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element - bot.editAdvancedEObjectFlatComboViewer([peElement.views->first().editorID()/], [peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]()); -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isAEOFCVReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editPropertyAdvancedEObjectFlatComboViewerFeature(propertiesView, [peElement.views->first().editorID()/], referenceValueFor[peElement.model.name.toUpperFirst()/], bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeExpectedModel ? (peElement.isAEOFCVReference())] -CompoundCommand cc = new CompoundCommand(); - [comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] - allInstancesOf = EEFTestsModelsUtils.getAllInstancesOf(expectedModel, [peElement.model.eType.name.toLowerFirst()/]MetaClass); - cc.append(SetCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], null)); -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeFeature ? (peElement.isAEOFCVReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.removeAdvancedEObjectFlatComboViewerFeature(wizardShell, [peElement.views->first().editorID()/]); -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removePropertyFeature ? (peElement.isAEOFCVReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.removePropertyAdvancedEObjectFlatComboViewerFeature(propertiesView, [peElement.views->first().editorID()/], bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[query public isAEOFCVReference(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EReference)) - then false - else peElement.representationName('AdvancedEObjectFlatComboViewer') and peElement.model.oclAsType(ecore::EReference).isReferenceSingle() - endif/] diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedReferencesTableTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedReferencesTableTest.mtl deleted file mode 100644 index da53828b6..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedReferencesTableTest.mtl +++ /dev/null @@ -1,88 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module advancedReferencesTableTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isAdvancedReferencesTableReference())]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isAdvancedReferencesTableReference())] -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -allInstancesOf = EEFTestsModelsUtils.getAllInstancesOf(expectedModel, [peElement.model.eType.name.toLowerFirst()/]MetaClass); -referenceValueFor[peElement.model.name.toUpperFirst()/] = bot.changeReferenceValue(allInstancesOf, (([pec.model.name.toUpperFirst()/])[pec.model.name.toLowerFirst()/]).get[peElement.model.name.toUpperFirst()/]()); -cc.append(AddCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], referenceValueFor[peElement.model.name.toUpperFirst()/])); -[/template] - -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeExpectedModel ? (peElement.isAdvancedReferencesTableReference())] -CompoundCommand cc = new CompoundCommand(); -List allReferencedInstances = (List)[pec.model.name.toLowerFirst()/].eGet([peElement.metamodelGetter()/]); -if (allReferencedInstances.size() > 0) { - cc.append(RemoveCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], allReferencedInstances.get(0))); -} -else { - throw new InputModelInvalidException(); -} -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isAdvancedReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.editAdvancedReferencesTableFeature(wizardShell, [peElement.views->first().editorID()/], referenceValueFor[peElement.model.name.toUpperFirst()/]); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isAdvancedReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element -bot.editAdvancedReferencesTableValues([peElement.views->first().editorID()/], [peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]()); -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isAdvancedReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.editPropertyAdvancedReferencesTableFeature(propertiesView, [peElement.views->first().editorID()/], referenceValueFor[peElement.model.name.toUpperFirst()/], bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeFeature ? (peElement.isAdvancedReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.removeAdvancedReferencesTableFeature(wizardShell, [peElement.views->first().editorID()/], [peElement.views->first().owningViewsRepository().messagesProvider()/].PropertiesEditionPart_RemoveListViewerLabel); -[/template] - -[template public removeFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides removeFeature ? (peElement.isAdvancedReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element -bot.removeAdvancedReferencesTable([peElement.views->first().owningViewsRepository().messagesProvider()/].[peElement.views->first().editorKey(peElement.views->first().owningView())/], [peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]()); -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removePropertyFeature ? (peElement.isAdvancedReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.removePropertyAdvancedReferencesTableFeature(propertiesView, [peElement.views->first().editorID()/], [peElement.views->first().owningViewsRepository().messagesProvider()/].PropertiesEditionPart_RemoveListViewerLabel, bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[query public isAdvancedReferencesTableReference(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EReference)) - then false - else peElement.representationName('AdvancedReferencesTable') and peElement.model.oclAsType(ecore::EReference).isReferenceMany() - endif/] diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedTableCompositionTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedTableCompositionTest.mtl deleted file mode 100644 index 5e98324c7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/advancedTableCompositionTest.mtl +++ /dev/null @@ -1,116 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module advancedTableCompositionTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isAdvancedTableComposition() and pec.model<>peElement.model.eType)]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isAdvancedTableComposition())] -EClass [peElement.model.eType.name.toLowerFirst()/]MetaClass = [peElement.model.eType.ePackage.metamodelPackage()/].eINSTANCE.get[peElement.model.eType.name/](); -EObject [peElement.model.eType.name.toLowerFirst()/] = EEFTestsModelsUtils.getFirstInstanceOf(expectedModel, [peElement.model.eType.name.toLowerFirst()/]MetaClass); -if ([peElement.model.eType.name.toLowerFirst()/] == null) - throw new InputModelInvalidException([peElement.model.eType.name.toLowerFirst()/]MetaClass.getName()); -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -cc.append(AddCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], EcoreUtil.copy([peElement.model.eType.name.toLowerFirst()/]))); -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isAdvancedTableComposition())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -editAdvancedTableComposition[peElement.name/]Feature(wizardShell); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isAdvancedTableComposition())] -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isAdvancedTableComposition())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - editAdvancedTableComposition[peElement.name/]Feature(propertiesView, bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides additionnalMethodsForWidgets ? (peElement.isAdvancedTableComposition())] - /** - * Edit the feature in the table composition - */ - protected void editAdvancedTableCompositionFor[peElement.name/]Feature() throws WidgetInvalidException { - EClass [peElement.model.eType.name.toLowerFirst()/]MetaClass = [peElement.model.eType.ePackage.metamodelPackage()/].eINSTANCE.get[peElement.model.eType.name/](); - SWTBotShell shellTable = bot.shell([peElement.model.eType.name.toLowerFirst()/]MetaClass.getName()); - bot.activateShell(shellTable); - [peElement.model.eType.name/] [peElement.model.eType.name.toLowerFirst()/] = ([peElement.model.eType.name/]) EEFTestsModelsUtils.getFirstInstanceOf(bot.getActiveResource(), [peElement.model.eType.name.toLowerFirst()/]MetaClass); - [for (f : ecore::EStructuralFeature | peElement.model.eType.eContents()->select(oclIsKindOf(ecore::EStructuralFeature)).oclAsType(ecore::EStructuralFeature)->select(feature : ecore::EStructuralFeature |not feature.isContainment()))] - bot.sleep(500); - [editFeature(f, involvedPropertiesEditionElement(peElement, f))/] - [/for] - bot.closeShellWithFinishButton(shellTable); - } -[/template] - -[comment overrides this template if additional methods are needed/] -[template public additionalMethodsForTableComposition(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides additionalMethodsForTableComposition ? (peElement.isAdvancedTableComposition())] - /** - * Edit the table composition - * @param wizardShell - */ - protected void editAdvancedTableComposition[peElement.name/]Feature(SWTBotShell wizardShell) throws WidgetInvalidException { - bot.activateShell(wizardShell); - bot.sleep(500); - bot.addButtonAdvancedTableComposition([peElement.views->first().editorID()/]).click(); - editAdvancedTableCompositionFor[peElement.name/]Feature(); - bot.closeShellWithFinishButton(wizardShell); - } -[/template] - -[comment overrides this template if additional methods are needed/] -[template public additionalMethodsPropertiesForTableComposition(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides additionalMethodsPropertiesForTableComposition ? (peElement.isAdvancedTableComposition())] - /** - * Edit the table composition - * @param wizardShell - */ - protected void editAdvancedTableComposition[peElement.name/]Feature(SWTBotView propertyView, SWTBotTreeItem selectNode) throws WidgetInvalidException { - SWTEEFBotHelper helper = new SWTEEFBotHelper(propertyView.bot()); - helper.addButtonAdvancedTableComposition([peElement.views->first().editorID()/]).click(); - editAdvancedTableCompositionFor[peElement.name/]Feature(); - selectNode.select(); - } -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeExpectedModel ? (peElement.isAdvancedTableComposition())] -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -List eGet = (List)[pec.model.name.toLowerFirst()/].eGet([peElement.metamodelGetter()/]); -if (eGet.size() == 0) - throw new InputModelInvalidException("Model is invalid"); -EObject firstInstanceOf = (EObject) eGet.get(0); -cc.append(RemoveCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], firstInstanceOf)); -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeFeature ? (peElement.isAdvancedTableComposition())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.removeAdvancedTableCompositionFeature(wizardShell, [peElement.views->first().editorID()/]); -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removePropertyFeature ? (peElement.isAdvancedTableComposition())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.removePropertyAdvancedTableCompositionFeature(propertiesView, [peElement.views->first().editorID()/], [peElement.views->first().owningViewsRepository().messagesProvider()/].PropertiesEditionPart_RemoveListViewerLabel, bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[query public isAdvancedTableComposition(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EReference)) - then false - else (peElement.representationName('AdvancedTableComposition')) and (peElement.model.oclAsType(ecore::EReference).isContainmentMany() or peElement.model.oclAsType(ecore::EReference).isContainmentSingle()) - endif/] diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/checkboxTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/checkboxTest.mtl deleted file mode 100644 index cc5a529a0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/checkboxTest.mtl +++ /dev/null @@ -1,61 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module checkboxTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isCheckboxBoolean())]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isCheckboxBoolean())] -CompoundCommand cc = new CompoundCommand(); - [comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] - Boolean oldValue = (Boolean)[pec.model.name.toLowerFirst()/].eGet([peElement.metamodelGetter()/]); - cc.append(SetCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], !oldValue)); -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isCheckboxBoolean())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editCheckboxFeature(wizardShell, [peElement.views->first().editorID()/]); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isCheckboxBoolean())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element - bot.editCheckBox([peElement.views->first().editorID()/], [peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].is[peElement.model.name.toUpperFirst()/]()); -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isCheckboxBoolean())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editPropertyEEFCheckbox(propertiesView, [peElement.views->first().editorID()/], bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[query public isCheckboxBoolean(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EAttribute)) - then false - else peElement.representationName('Checkbox') and peElement.model.oclAsType(ecore::EAttribute).isBoolean() - endif/] diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/eobjectFlatComboViewerTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/eobjectFlatComboViewerTest.mtl deleted file mode 100644 index 310d316db..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/eobjectFlatComboViewerTest.mtl +++ /dev/null @@ -1,75 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module eobjectFlatComboViewerTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isEOFCVReference())]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isEOFCVReference())] -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -allInstancesOf = EEFTestsModelsUtils.getAllInstancesOf(expectedModel, [peElement.model.eType.name.toLowerFirst()/]MetaClass); -referenceValueFor[peElement.model.name.toUpperFirst()/] = bot.changeReferenceValue(allInstancesOf, (([pec.model.name.toUpperFirst()/])[pec.model.name.toLowerFirst()/]).get[peElement.model.name.toUpperFirst()/]()); -cc.append(SetCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], referenceValueFor[peElement.model.name.toUpperFirst()/])); -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isEOFCVReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.editEObjectFlatComboViewerFeature(wizardShell, [peElement.views->first().editorID()/], allInstancesOf.indexOf(referenceValueFor[peElement.model.name.toUpperFirst()/])[if (not peElement.model.required)]+1[/if]); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isEOFCVReference())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element -if ([peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]() != null) { - allInstancesOf = EEFTestsModelsUtils.getAllInstancesOf(expectedModel, [peElement.model.eType.name.toLowerFirst()/]MetaClass); - bot.editEObjectFlatComboViewer([peElement.views->first().editorID()/], allInstancesOf.indexOf([peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]())); -} -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isEOFCVReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.editPropertyEObjectFlatComboViewerFeature(propertiesView, [peElement.views->first().editorID()/], allInstancesOf.indexOf(referenceValueFor[peElement.model.name.toUpperFirst()/])[if (not peElement.model.required)]+1[/if], bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeExpectedModel ? (peElement.isEOFCVReference())] -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -allInstancesOf = EEFTestsModelsUtils.getAllInstancesOf(expectedModel, [peElement.model.eType.name.toLowerFirst()/]MetaClass); -cc.append(SetCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], null)); -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeFeature ? (peElement.isEOFCVReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.removeEObjectFlatComboViewerFeature(wizardShell, [peElement.views->first().editorID()/]); - -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removePropertyFeature ? (peElement.isEOFCVReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.removePropertyEObjectFlatComboViewerFeature(propertiesView, [peElement.views->first().editorID()/], bot.selectNode(modelEditor, firstInstanceOf)); - -[/template] - -[query public isEOFCVReference(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EReference)) - then false - else peElement.representationName('EObjectFlatComboViewer') and peElement.model.oclAsType(ecore::EReference).isReferenceSingle() - endif/] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/flatReferencesTableTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/flatReferencesTableTest.mtl deleted file mode 100644 index 8ace60a89..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/flatReferencesTableTest.mtl +++ /dev/null @@ -1,74 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module flatReferencesTableTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isFlatReferencesTableReference())]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isFlatReferencesTableReference())] -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -allInstancesOf = EEFTestsModelsUtils.getAllInstancesOf(expectedModel, [peElement.model.eType.name.toLowerFirst()/]MetaClass); -referenceValueFor[peElement.model.name.toUpperFirst()/] = bot.changeReferenceValue(allInstancesOf, (([pec.model.name.toUpperFirst()/])[pec.model.name.toLowerFirst()/]).get[peElement.model.name.toUpperFirst()/]()); -cc.append(AddCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], referenceValueFor[peElement.model.name.toUpperFirst()/])); -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isFlatReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.editFlatReferencesTableFeature(wizardShell, [peElement.views->first().editorID()/], 0); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isFlatReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element -bot.editFlatReferencesTable([peElement.views->first().editorID()/], 0); -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isFlatReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.editPropertyFlatReferencesTableFeature(propertiesView, [peElement.views->first().editorID()/], 0, bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeExpectedModel ? (peElement.isFlatReferencesTableReference())] -CompoundCommand cc = new CompoundCommand(); -List allReferencedInstances = (List)[pec.model.name.toLowerFirst()/].eGet([peElement.metamodelGetter()/]); -if (allReferencedInstances.size() > 0) { - cc.append(RemoveCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], allReferencedInstances.get(0))); -} -else { - throw new InputModelInvalidException(); -} -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeFeature ? (peElement.isFlatReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.removeFlatReferencesTableFeature(wizardShell, [peElement.views->first().editorID()/]); -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removePropertyFeature ? (peElement.isFlatReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.removePropertyFlatReferencesTableFeature(propertiesView, [peElement.views->first().editorID()/], bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[query public isFlatReferencesTableReference(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EReference)) - then false - else peElement.representationName('FlatReferencesTable') and peElement.model.oclAsType(ecore::EReference).isReferenceMany() - endif/] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/multiValuedEditorTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/multiValuedEditorTest.mtl deleted file mode 100644 index df60f9b65..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/multiValuedEditorTest.mtl +++ /dev/null @@ -1,62 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module multiValuedEditorTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isMultiValuedEditorString())]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isMultiValuedEditorString())] -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -List expectedValue = new ArrayList((List)[pec.model.name.toLowerFirst()/].eGet([peElement.metamodelGetter()/])); -expectedValue.add(UPDATED_VALUE); -cc.append(SetCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], expectedValue)); -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isMultiValuedEditorString())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editMultiValuedEditorFeature(wizardShell, [peElement.views->first().editorID()/], UPDATED_VALUE); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isMultiValuedEditorString())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element - bot.editMultiValuedEditor([peElement.views->first().editorID()/], [peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]()); -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isMultiValuedEditorString())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editPropertyMultiValuedEditorFeature(propertiesView, [peElement.views->first().editorID()/], UPDATED_VALUE, bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[query public isMultiValuedEditorString(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EAttribute)) - then false - else peElement.representationName('MultiValuedEditor') and peElement.model.oclAsType(ecore::EAttribute).isString() - endif/] diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/radioTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/radioTest.mtl deleted file mode 100644 index e5f22fe82..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/radioTest.mtl +++ /dev/null @@ -1,60 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module radioTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isRadioEnum())]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isRadioEnum())] -CompoundCommand cc = new CompoundCommand(); - [comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] - cc.append(SetCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], [peElement.model.eContainingClass.metamodelPackage()/].eINSTANCE.get[peElement.model.eType.name/]().getEEnumLiteralByLiteral(enumValueFor[peElement.model.name.toUpperFirst()/].toString()).getInstance())); -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isRadioEnum())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editRadioFeature(wizardShell, [peElement.views->first().editorID()/], enumValueFor[peElement.model.name.toUpperFirst()/]); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isRadioEnum())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element - bot.editRadio([peElement.views->first().owningViewsRepository().messagesProvider()/].[peElement.views->first().editorKey(peElement.views->first().owningView())/], [peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]()); -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isRadioEnum())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editPropertyRadioFeature(propertiesView, [peElement.views->first().editorID()/], enumValueFor[peElement.model.name.toUpperFirst()/], bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[query public isRadioEnum(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EAttribute)) - then false - else peElement.representationName('Radio') and peElement.model.oclAsType(ecore::EAttribute).isEnum() - endif/] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/referencesTableTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/referencesTableTest.mtl deleted file mode 100644 index eadda77fb..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/referencesTableTest.mtl +++ /dev/null @@ -1,77 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module referencesTableTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isReferencesTableReference())]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isReferencesTableReference())] -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -allInstancesOf = EEFTestsModelsUtils.getAllInstancesOf(expectedModel, [peElement.model.eType.name.toLowerFirst()/]MetaClass); -referenceValueFor[peElement.model.name.toUpperFirst()/] = bot.changeReferenceValue(allInstancesOf, (([pec.model.name.toUpperFirst()/])[pec.model.name.toLowerFirst()/]).get[peElement.model.name.toUpperFirst()/]()); -cc.append(AddCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], referenceValueFor[peElement.model.name.toUpperFirst()/])); -[/template] - -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeExpectedModel ? (peElement.isReferencesTableReference())] -CompoundCommand cc = new CompoundCommand(); -List allReferencedInstances = (List)[pec.model.name.toLowerFirst()/].eGet([peElement.metamodelGetter()/]); -if (allReferencedInstances.size() > 0) { - cc.append(RemoveCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], allReferencedInstances.get(0))); -} -else { - throw new InputModelInvalidException(); -} -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editReferencesTableFeature(wizardShell, [peElement.views->first().editorID()/], 0); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element - bot.editReferencesTable([peElement.views->first().owningViewsRepository().messagesProvider()/].[peElement.views->first().editorKey(peElement.views->first().owningView())/], [peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]()); -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editPropertyReferencesTableFeature(propertiesView, [peElement.views->first().editorID()/], 0, bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeFeature ? (peElement.isReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.removeReferencesTableFeature(wizardShell, [peElement.views->first().editorID()/], 0); -[/template] - -[template public removeFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides removeFeature ? (peElement.isReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element - bot.removeReferencesTable([peElement.views->first().owningViewsRepository().messagesProvider()/].[peElement.views->first().editorKey(peElement.views->first().owningView())/], [peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]()); -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removePropertyFeature ? (peElement.isReferencesTableReference())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.removePropertyReferencesTableFeature(propertiesView, [peElement.views->first().editorID()/], 0, bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[query public isReferencesTableReference(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EReference)) - then false - else peElement.representationName('ReferencesTable') and peElement.model.oclAsType(ecore::EReference).isReferenceMany() - endif/] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/tableCompositionTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/tableCompositionTest.mtl deleted file mode 100644 index b7e08ddd7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/tableCompositionTest.mtl +++ /dev/null @@ -1,114 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module tableCompositionTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isTableComposition() and pec.model<>peElement.model.eType)]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isTableComposition())] -EClass [peElement.model.eType.name.toLowerFirst()/]MetaClass = [peElement.model.eType.ePackage.metamodelPackage()/].eINSTANCE.get[peElement.model.eType.name/](); -EObject [peElement.model.eType.name.toLowerFirst()/] = EEFTestsModelsUtils.getFirstInstanceOf(expectedModel, [peElement.model.eType.name.toLowerFirst()/]MetaClass); -if ([peElement.model.eType.name.toLowerFirst()/] == null) - throw new InputModelInvalidException([peElement.model.eType.name.toLowerFirst()/]MetaClass.getName()); -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -cc.append(AddCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], EcoreUtil.copy([peElement.model.eType.name.toLowerFirst()/]))); -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isTableComposition())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -editTableComposition[peElement.name/]Feature(wizardShell); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isTableComposition())] -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isTableComposition())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -editTableComposition[peElement.name/]Feature(propertiesView, bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[comment overrides this template if additional methods are needed/] -[template public additionalMethodsForTableComposition(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides additionalMethodsForTableComposition ? (peElement.isTableComposition())] - /** - * Edit the table composition - * @param wizardShell - */ - protected void editTableComposition[peElement.name/]Feature(SWTBotShell wizardShell) throws WidgetInvalidException{ - bot.activateShell(wizardShell); - bot.sleep(500); - bot.addButtonTableComposition([peElement.views->first().editorID()/]).click(); - editTableCompositionFor[peElement.name/]Feature(); - bot.closeShellWithFinishButton(wizardShell); - } -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides additionnalMethodsForWidgets ? (peElement.isTableComposition())] - /** - * Edit the feature in the table composition - */ - protected void editTableCompositionFor[peElement.name/]Feature() throws WidgetInvalidException { - EClass [peElement.model.eType.name.toLowerFirst()/]MetaClass = [peElement.model.eType.ePackage.metamodelPackage()/].eINSTANCE.get[peElement.model.eType.name/](); - SWTBotShell shellTable = bot.shell([peElement.model.eType.name.toLowerFirst()/]MetaClass.getName()); - bot.activateShell(shellTable); - [peElement.model.eType.name/] [peElement.model.eType.name.toLowerFirst()/] = ([peElement.model.eType.name/]) EEFTestsModelsUtils.getFirstInstanceOf(bot.getActiveResource(), [peElement.model.eType.name.toLowerFirst()/]MetaClass); - [for (f : ecore::EStructuralFeature | peElement.model.eType.eContents()->select(oclIsKindOf(ecore::EStructuralFeature)).oclAsType(ecore::EStructuralFeature)->select(feature : ecore::EStructuralFeature | not (feature.isContainmentSingle() or feature.isContainmentMany())))] - bot.sleep(500); - [editFeature(f, involvedPropertiesEditionElement(peElement, f))/] - [/for] - bot.closeShellWithFinishButton(shellTable); - } -[/template] - -[comment overrides this template if additional methods are needed/] -[template public additionalMethodsPropertiesForTableComposition(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides additionalMethodsPropertiesForTableComposition ? (peElement.isTableComposition())] - /** - * Edit the table composition - * @param wizardShell - */ - protected void editTableComposition[peElement.name/]Feature(SWTBotView propertyView, SWTBotTreeItem selectNode) throws WidgetInvalidException { - SWTEEFBotHelper helper = new SWTEEFBotHelper(propertyView.bot()); - helper.addButtonTableComposition([peElement.views->first().editorID()/]).click(); - editTableCompositionFor[peElement.name/]Feature(); - selectNode.select(); - } -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeExpectedModel ? (peElement.isTableComposition())] -CompoundCommand cc = new CompoundCommand(); -[comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] -allInstancesOf = (([pec.model.name.toUpperFirst()/])[pec.model.name.toLowerFirst()/]).get[peElement.model.name.toUpperFirst()/](); -EObject firstInstanceOf = EEFTestsModelsUtils.getFirstInstanceOf(allInstancesOf, [peElement.model.eType.name.toLowerFirst()/]MetaClass); -cc.append(RemoveCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], firstInstanceOf)); -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removeFeature ? (peElement.isTableComposition())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.removeTableCompositionFeature(wizardShell, [peElement.views->first().editorID()/]); -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides removePropertyFeature ? (peElement.isTableComposition())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element -bot.removePropertyTableCompositionFeature(propertiesView, [peElement.views->first().editorID()/], bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[query public isTableComposition(peElement : PropertiesEditionElement) : Boolean = - if (not peElement.model.oclIsTypeOf(ecore::EReference)) - then false - else (peElement.representationName('TableComposition')) and (peElement.model.oclAsType(ecore::EReference).isContainmentMany() or peElement.model.oclAsType(ecore::EReference).isContainmentSingle()) - endif/] diff --git a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/textTest.mtl b/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/textTest.mtl deleted file mode 100644 index a9d0c446f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.tests/src/org/eclipse/emf/eef/tests/codegen/services/widgets/impl/textTest.mtl +++ /dev/null @@ -1,58 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module textTest('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends widgetTest/] - -[import common /] -[import naming /] -[import typeUtils /] - -[template public canGenerateTest(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides canGenerateTest ? (peElement.isTextString())]true[/template] - -[template public updateExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides updateExpectedModel ? (peElement.isTextString())] -CompoundCommand cc = new CompoundCommand(); - [comment TODO: Reuse the commandUpdater template but the last parameter of the command creation method must be ... parameterized /] - cc.append(SetCommand.create(editingDomain, [pec.model.name.toLowerFirst()/], [peElement.metamodelGetter()/], UPDATED_VALUE)); -[/template] - -[template public editFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isTextString())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editTextFeature(wizardShell, [peElement.views->first().editorID()/], UPDATED_VALUE); -[/template] - -[template public editFeature(f : EStructuralFeature, peElement : PropertiesEditionElement) overrides editFeature ? (peElement.isTextString())] -// Change value of the [peElement.name/] feature of the [peElement.model.name/] element - bot.editEEFText([peElement.views->first().editorID()/], [peElement.element->select(oclIsTypeOf(components::PropertiesEditionComponent)).oclAsType(components::PropertiesEditionComponent).model.name.toLowerFirst()/].get[peElement.model.name.toUpperFirst()/]()); -[/template] - -[template public editPropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement) overrides editPropertyFeature ? (peElement.isTextString())] -// Change value of the [peElement.name/] feature of the [pec.model.name/] element - bot.editPropertyEEFText(propertiesView, [peElement.views->first().editorID()/], UPDATED_VALUE, bot.selectNode(modelEditor, firstInstanceOf)); -[/template] - -[template public additionnalMethodsForWidgets(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the command to apply in order to obtain the expected model /] -[template public removeExpectedModel(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[comment defines the bot command to process to edit the expected feature /] -[template public removeFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[template public removePropertyFeature(pec : PropertiesEditionComponent, peElement : PropertiesEditionElement)] -[/template] - -[query public isTextString(peElement : PropertiesEditionElement) : Boolean = - peElement <> null and peElement.model.oclIsTypeOf(ecore::EAttribute) - /] diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/.classpath b/plugins/org.eclipse.emf.eef.codegen.uml/.classpath deleted file mode 100644 index 64c5e31b7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/.gitignore b/plugins/org.eclipse.emf.eef.codegen.uml/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/.project b/plugins/org.eclipse.emf.eef.codegen.uml/.project deleted file mode 100644 index 5ba7c78c1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/.project +++ /dev/null @@ -1,42 +0,0 @@ - - - org.eclipse.emf.eef.codegen.uml - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - org.eclipse.acceleo.ide.ui.acceleoBuilder - - - compliance - pragmatic - - - resource.kind - binary - - - - - - org.eclipse.acceleo.ide.ui.acceleoNature - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.codegen.uml/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index d1c0bf949..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,6 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.codegen.uml/META-INF/MANIFEST.MF deleted file mode 100644 index e2535ac8f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/META-INF/MANIFEST.MF +++ /dev/null @@ -1,16 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: MTL Uml Module Runtime Plug-in -Bundle-SymbolicName: org.eclipse.emf.eef.codegen.uml;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Vendor: Eclipse.org -Require-Bundle: org.eclipse.core.runtime, - org.eclipse.emf.ecore, - org.eclipse.emf.ecore.xmi, - org.eclipse.ocl, - org.eclipse.ocl.ecore, - org.eclipse.acceleo.model, - org.eclipse.acceleo.engine, - org.eclipse.emf.eef.codegen -Bundle-RequiredExecutionEnvironment: J2SE-1.5 - diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/about.html b/plugins/org.eclipse.emf.eef.codegen.uml/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/build.acceleo b/plugins/org.eclipse.emf.eef.codegen.uml/build.acceleo deleted file mode 100644 index 5cc4ffb11..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/build.acceleo +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/build.properties b/plugins/org.eclipse.emf.eef.codegen.uml/build.properties deleted file mode 100644 index 10e9ea302..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/build.properties +++ /dev/null @@ -1,25 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2010 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/,\ - .emtl/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ - build.acceleo,\ - about.html -customBuildCallbacks = build.acceleo -src.includes = META-INF/,\ - build.acceleo,\ - build.properties,\ - plugin.xml,\ - src/,\ - about.html diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/plugin.xml b/plugins/org.eclipse.emf.eef.codegen.uml/plugin.xml deleted file mode 100644 index 17c6e1b2b..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/plugin.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/pom.xml b/plugins/org.eclipse.emf.eef.codegen.uml/pom.xml deleted file mode 100644 index f205c395a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/pom.xml +++ /dev/null @@ -1,74 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf - org.eclipse.emf.eef.codegen.uml - 1.5.2-SNAPSHOT - eclipse-plugin - - EEF Codegen for UML Plug-in - - - - - org.eclipse.acceleo - org.eclipse.acceleo.maven - 3.5.0-SNAPSHOT - - - compile - - acceleo-compile - - - - - false - true - - ${project.basedir} - - - src - target/classes - - - - org.eclipse.emf:org.eclipse.emf.eef.codegen - - - - org.eclipse.emf.ecore.EcorePackage - org.eclipse.emf.eef.components.ComponentsPackage - org.eclipse.emf.eef.mapping.MappingPackage - org.eclipse.emf.eef.views.ViewsPackage - org.eclipse.emf.eef.EEFGen.EEFGenPackage - org.eclipse.emf.eef.mapping.filters.FiltersPackage - org.eclipse.emf.eef.mapping.navigation.NavigationPackage - org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage - - org.eclipse.acceleo.maven.AcceleoURIHandler - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/src/org/eclipse/emf/eef/codegen/services/umlCommon.mtl b/plugins/org.eclipse.emf.eef.codegen.uml/src/org/eclipse/emf/eef/codegen/services/umlCommon.mtl deleted file mode 100644 index 381464b67..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/src/org/eclipse/emf/eef/codegen/services/umlCommon.mtl +++ /dev/null @@ -1,18 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module umlCommon('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::services::common/] - -[comment ==== For multiples model features getters (thanks to the specific UML2 Codegen !) ==== /] -[template public toMany(s: String) overrides toMany] -[if (s.endsWith('y') and not s.endsWith('By'))][s.substring(1, s.size()-1).concat('ies')/][elseif (s.endsWith('ex'))][s.substring(1, s.size()-2).concat('ices')/][elseif (s.endsWith('Data') or s.endsWith('ctual') or s = 'type')][s/][elseif not (s.endsWith('s'))][s.concat('s')/][else][s/][/if] -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen.uml/src/org/eclipse/emf/eef/codegen/services/umlComponentUtils.mtl b/plugins/org.eclipse.emf.eef.codegen.uml/src/org/eclipse/emf/eef/codegen/services/umlComponentUtils.mtl deleted file mode 100644 index e59db009c..000000000 --- a/plugins/org.eclipse.emf.eef.codegen.uml/src/org/eclipse/emf/eef/codegen/services/umlComponentUtils.mtl +++ /dev/null @@ -1,31 +0,0 @@ -[comment - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module umlComponentUtils('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::impl::checkbox::checkboxControl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Checkbox'))] -[if (editionElement.model.oclAsType("EAttribute").eType.instanceClassName = 'boolean')] - [if (editionElement.model.name.startsWith('is'))] -[view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([pec.model.name.toJavaIdentifier()/].[editionElement.model.name.toJavaClassifier().toLowerFirst()/]()); - [else] -[view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([pec.model.name.toJavaIdentifier()/].is[editionElement.model.name.toJavaClassifier()/]()); - [/if] -[elseif (editionElement.model.oclAsType(ecore::EAttribute).isBoolean())] -[view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([pec.model.name.toJavaIdentifier()/].get[editionElement.model.name.toJavaClassifier()/]()); -[else] -//FIXME invalid case in updater(), Case : model = Attribute(1) : [editionElement.model.name/] - view = Checkbox -[/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/.checkstyle b/plugins/org.eclipse.emf.eef.codegen/.checkstyle deleted file mode 100644 index 48589e9cb..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen/.classpath b/plugins/org.eclipse.emf.eef.codegen/.classpath deleted file mode 100644 index ed5ee00d9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/.classpath +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen/.gitignore b/plugins/org.eclipse.emf.eef.codegen/.gitignore deleted file mode 100644 index 7568f78ff..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -tasks -target -bin \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/.project b/plugins/org.eclipse.emf.eef.codegen/.project deleted file mode 100644 index 1b67ceb2a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/.project +++ /dev/null @@ -1,52 +0,0 @@ - - - org.eclipse.emf.eef.codegen - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - org.eclipse.acceleo.ide.ui.acceleoBuilder - - - compilation.kind - compilation.absolute.path - - - compliance - pragmatic - - - resource.kind - binary - - - - - org.eclipse.pde.api.tools.apiAnalysisBuilder - - - - - - org.eclipse.acceleo.ide.ui.acceleoNature - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - org.eclipse.pde.api.tools.apiAnalysisNature - - diff --git a/plugins/org.eclipse.emf.eef.codegen/.settings/org.eclipse.core.resources.prefs b/plugins/org.eclipse.emf.eef.codegen/.settings/org.eclipse.core.resources.prefs deleted file mode 100644 index e45dd9b0e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/.settings/org.eclipse.core.resources.prefs +++ /dev/null @@ -1,3 +0,0 @@ -#Tue Feb 17 11:51:40 CET 2009 -eclipse.preferences.version=1 -encoding/=UTF-8 diff --git a/plugins/org.eclipse.emf.eef.codegen/.settings/org.eclipse.core.runtime.prefs b/plugins/org.eclipse.emf.eef.codegen/.settings/org.eclipse.core.runtime.prefs deleted file mode 100644 index 91c7db9ae..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/.settings/org.eclipse.core.runtime.prefs +++ /dev/null @@ -1,3 +0,0 @@ -#Tue Feb 17 11:51:40 CET 2009 -eclipse.preferences.version=1 -line.separator=\n diff --git a/plugins/org.eclipse.emf.eef.codegen/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.codegen/META-INF/MANIFEST.MF deleted file mode 100644 index 3d31d8eb8..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/META-INF/MANIFEST.MF +++ /dev/null @@ -1,56 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Standard Acceleo generator -Bundle-SymbolicName: org.eclipse.emf.eef.codegen;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Activator: org.eclipse.emf.eef.codegen.EEFCodegenPlugin -Bundle-Vendor: Eclipse Modeling Project -Require-Bundle: org.eclipse.ui;bundle-version="3.4.0", - org.eclipse.ui.ide;bundle-version="3.4.0", - org.eclipse.jface.text;bundle-version="3.4.0";resolution:=optional, - org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.core.resources;bundle-version="3.4.0", - org.eclipse.emf.ecore;bundle-version="2.4.0", - org.eclipse.emf.ecore.xmi;bundle-version="2.4.0", - org.eclipse.emf.codegen.ecore;bundle-version="2.4.0", - org.eclipse.emf.edit;bundle-version="2.4.0", - org.eclipse.ocl;bundle-version="1.2.0", - org.eclipse.ocl.ecore;bundle-version="1.2.0", - org.eclipse.acceleo.model;bundle-version="3.1.0", - org.eclipse.acceleo.engine;bundle-version="3.1.0", - org.eclipse.jdt.core;bundle-version="3.4.0";resolution:=optional, - org.eclipse.jdt.ui;bundle-version="3.4.0";resolution:=optional, - org.eclipse.emf.eef.eefgen;bundle-version="1.0.0", - org.eclipse.emf.eef.views;bundle-version="1.0.0", - org.eclipse.emf.eef.views.edit;bundle-version="1.0.0", - org.eclipse.emf.eef.components;bundle-version="1.0.0", - org.eclipse.emf.eef.components.edit;bundle-version="1.0.0", - org.eclipse.emf.importer.ecore;bundle-version="2.4.0", - org.eclipse.emf.importer;bundle-version="2.4.0", - org.eclipse.pde.core;bundle-version="3.4.0", - org.eclipse.pde.ui;bundle-version="3.4.0", - org.eclipse.acceleo.parser;bundle-version="3.1.0";resolution:=optional, - org.eclipse.emf.eef.codegen.launcher;bundle-version="1.1.0";visibility:=reexport, - org.eclipse.emf.eef.codegen.ecore;bundle-version="1.1.0" -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Bundle-ActivationPolicy: lazy -Export-Package: org.eclipse.emf.eef.codegen, - org.eclipse.emf.eef.codegen.components, - org.eclipse.emf.eef.codegen.core.initializer, - org.eclipse.emf.eef.codegen.core.launcher, - org.eclipse.emf.eef.codegen.core.services, - org.eclipse.emf.eef.codegen.core.util, - org.eclipse.emf.eef.codegen.flow.impl, - org.eclipse.emf.eef.codegen.flow.util, - org.eclipse.emf.eef.codegen.launcher, - org.eclipse.emf.eef.codegen.parts, - org.eclipse.emf.eef.codegen.plugin, - org.eclipse.emf.eef.codegen.providers, - org.eclipse.emf.eef.codegen.services, - org.eclipse.emf.eef.codegen.ui.generators.actions, - org.eclipse.emf.eef.codegen.ui.generators.callback, - org.eclipse.emf.eef.codegen.ui.generators.callback.imports, - org.eclipse.emf.eef.codegen.ui.generators.common, - org.eclipse.emf.eef.codegen.ui.initializer.actions, - org.eclipse.emf.eef.codegen.ui.initializer.ui, - org.eclipse.emf.eef.codegen.ui.validators.actions diff --git a/plugins/org.eclipse.emf.eef.codegen/about.html b/plugins/org.eclipse.emf.eef.codegen/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/build.acceleo b/plugins/org.eclipse.emf.eef.codegen/build.acceleo deleted file mode 100644 index 816061796..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/build.acceleo +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen/build.properties b/plugins/org.eclipse.emf.eef.codegen/build.properties deleted file mode 100644 index 74348b740..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/build.properties +++ /dev/null @@ -1,23 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/,\ - src-custom/,\ - src-build/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ - build.acceleo,\ - about.html -customBuildCallbacks = build.acceleo -src.includes = build.acceleo,\ - schema/,\ - about.html diff --git a/plugins/org.eclipse.emf.eef.codegen/plugin.xml b/plugins/org.eclipse.emf.eef.codegen/plugin.xml deleted file mode 100644 index 70c8b89cd..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/plugin.xml +++ /dev/null @@ -1,111 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen/pom.xml b/plugins/org.eclipse.emf.eef.codegen/pom.xml deleted file mode 100644 index 9d42b89fc..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/pom.xml +++ /dev/null @@ -1,74 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf - org.eclipse.emf.eef.codegen - 1.5.2-SNAPSHOT - eclipse-plugin - - EEF Codegen Plug-in - - - - - org.eclipse.acceleo - org.eclipse.acceleo.maven - 3.5.0-SNAPSHOT - - - compile - - acceleo-compile - - - - - false - true - - ${project.basedir} - - - src - target/classes - - - - org.eclipse.emf:org.eclipse.emf.eef.codegen.ecore - - - - org.eclipse.emf.ecore.EcorePackage - org.eclipse.emf.eef.components.ComponentsPackage - org.eclipse.emf.eef.mapping.MappingPackage - org.eclipse.emf.eef.views.ViewsPackage - org.eclipse.emf.eef.EEFGen.EEFGenPackage - org.eclipse.emf.eef.mapping.filters.FiltersPackage - org.eclipse.emf.eef.mapping.navigation.NavigationPackage - org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage - - org.eclipse.acceleo.maven.AcceleoURIHandler - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen/schema/PropertiesGeneratorLauncher.exsd b/plugins/org.eclipse.emf.eef.codegen/schema/PropertiesGeneratorLauncher.exsd deleted file mode 100644 index 194031636..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/schema/PropertiesGeneratorLauncher.exsd +++ /dev/null @@ -1,109 +0,0 @@ - - - - - - - - - Declares a new generator during the EEF generation phase - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [Enter the first release in which this extension point appears.] - - - - - - - - - [Enter extension point usage example here.] - - - - - - - - - [Enter API information here.] - - - - - - - - - [Enter information about supplied implementation of this extension point.] - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen/schema/PropertiesInitializerStrategy.exsd b/plugins/org.eclipse.emf.eef.codegen/schema/PropertiesInitializerStrategy.exsd deleted file mode 100644 index a51f13e99..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/schema/PropertiesInitializerStrategy.exsd +++ /dev/null @@ -1,116 +0,0 @@ - - - - - - - - - Declare a new strategy to initialize EEF components and EEF Generation models - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [Enter the first release in which this extension point appears.] - - - - - - - - - [Enter extension point usage example here.] - - - - - - - - - [Enter API information here.] - - - - - - - - - [Enter information about supplied implementation of this extension point.] - - - - - diff --git a/plugins/org.eclipse.emf.eef.codegen/src-build/org/eclipse/emf/eef/codegen/EEFCodegenCompiler.java b/plugins/org.eclipse.emf.eef.codegen/src-build/org/eclipse/emf/eef/codegen/EEFCodegenCompiler.java deleted file mode 100644 index 196bb211e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-build/org/eclipse/emf/eef/codegen/EEFCodegenCompiler.java +++ /dev/null @@ -1,166 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen; - -import java.io.File; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.Map; - -import org.eclipse.acceleo.common.IAcceleoConstants; -import org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; - -/** - * The Acceleo Standalone compiler. - * - * @author Stephane Bouchet - * @since 1.1 - */ -public class EEFCodegenCompiler extends AbstractAcceleoCompiler { - - /** - * The entry point of the compilation. - * - * @param args - * The arguments used in the compilation: the source folder, the output folder, a boolean - * indicating if we should use binary resource serialization and finally the dependencies of - * the project. - */ - public static void main(String[] args) { - if (args.length < 3) { - throw new IllegalArgumentException("Missing parameters"); //$NON-NLS-1$ - } - EEFCodegenCompiler acceleoCompiler = new EEFCodegenCompiler(); - acceleoCompiler.setSourceFolder(args[0]); - acceleoCompiler.setOutputFolder(args[1]); - acceleoCompiler.setBinaryResource(Boolean.valueOf(args[2]).booleanValue()); - if (args.length == 4 && args[3] != null && !"".equals(args[3])) { //$NON-NLS-1$ - acceleoCompiler.setDependencies(args[3]); - } - acceleoCompiler.doCompile(new BasicMonitor()); - } - - /** - * Launches the compilation of the mtl files in the generator. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#doCompile(org.eclipse.emf.common.util.Monitor) - */ - @Override - public void doCompile(Monitor monitor) { - super.doCompile(monitor); - } - - /** - * Registers the packages of the metamodels used in the generator. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#registerPackages() - */ - @Override - protected void registerPackages() { - super.registerPackages(); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.components.ComponentsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.components.ComponentsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.MappingPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.MappingPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.navigation.NavigationPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.navigation.NavigationPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.mapping.filters.FiltersPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.mapping.filters.FiltersPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), - org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.views.ViewsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.views.ViewsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.toolkits.ToolkitsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.toolkits.ToolkitsPackage.eINSTANCE); - org.eclipse.emf.ecore.EPackage.Registry.INSTANCE.put( - org.eclipse.emf.eef.EEFGen.EEFGenPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.EEFGen.EEFGenPackage.eINSTANCE); - } - - /** - * Registers the resource factories. - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#registerResourceFactories() - */ - @Override - protected void registerResourceFactories() { - super.registerResourceFactories(); - /* - * If you want to add other resource factories, for example if your metamodel uses a specific - * serialization: - * org.eclipse.emf.ecore.resource.Resource.Factory.Registry.getExtensionToFactoryMap().put - * (UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - */ - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.acceleo.parser.compiler.AbstractAcceleoCompiler#computeDependencies(java.util.List, - * java.util.Map) - */ - protected void computeDependencies(List dependenciesURIs, Map mapURIs) { - // USED TO FIX COMPILER WITH TYCHO - Iterator identifiersIt = dependenciesIDs.iterator(); - for (Iterator dependenciesIt = dependencies.iterator(); dependenciesIt.hasNext() - && identifiersIt.hasNext();) { - File requiredFolder = dependenciesIt.next(); - String identifier = identifiersIt.next(); - if (requiredFolder != null && requiredFolder.exists() && requiredFolder.isDirectory()) { - List emtlFiles = new ArrayList(); - members(emtlFiles, requiredFolder, IAcceleoConstants.EMTL_FILE_EXTENSION); - for (File emtlFile : emtlFiles) { - String requiredFolderAbsolutePath = requiredFolder.getAbsolutePath(); - if (requiredFolderAbsolutePath.endsWith("target/classes")) { - // using tycho - String[] splited = requiredFolderAbsolutePath.split("\\/"); - StringBuffer buf = new StringBuffer(requiredFolderAbsolutePath.length()); - for (int i = 0; i < splited.length - 3; i++) { - buf.append(splited[i]); - buf.append("/"); - } - requiredFolderAbsolutePath = buf.toString(); - String emtlAbsolutePath = emtlFile.getAbsolutePath(); - URI emtlFileURI = URI.createFileURI(emtlAbsolutePath); - dependenciesURIs.add(emtlFileURI); - String emtlModifiedPath = emtlAbsolutePath.replaceAll("target\\/|classes\\/", ""); - IPath relativePath = new Path(emtlModifiedPath.substring(requiredFolderAbsolutePath - .length())); - URI relativeURI = URI.createPlatformPluginURI(relativePath.toString(), false); - mapURIs.put(emtlFileURI, relativeURI); - } else { - // normal behavior - String emtlAbsolutePath = emtlFile.getAbsolutePath(); - URI emtlFileURI = URI.createFileURI(emtlAbsolutePath); - dependenciesURIs.add(emtlFileURI); - IPath relativePath = new Path(identifier).append(emtlAbsolutePath - .substring(requiredFolderAbsolutePath.length())); - mapURIs.put(emtlFileURI, URI.createPlatformPluginURI(relativePath.toString(), false)); - } - } - } - } - } -} - diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/EEFCodegenPlugin.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/EEFCodegenPlugin.java deleted file mode 100644 index 6e4c13426..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/EEFCodegenPlugin.java +++ /dev/null @@ -1,76 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.ui.plugin.AbstractUIPlugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle - * - * @author Goulwen Le Fur - */ -public class EEFCodegenPlugin extends AbstractUIPlugin { - - // The plug-in ID - public static final String PLUGIN_ID = "org.eclipse.emf.eef.codegen"; //$NON-NLS-1$ - - // The shared instance - private static EEFCodegenPlugin plugin; - - /** - * The constructor - */ - public EEFCodegenPlugin() { - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance - * - * @return the shared instance - */ - public static EEFCodegenPlugin getDefault() { - return plugin; - } - - public void logError(Exception e) { - IStatus status = new Status(IStatus.ERROR, PLUGIN_ID, e.getMessage(), e); - getLog().log(status); - } - - public void logWarning(Exception e) { - IStatus status = new Status(IStatus.WARNING, PLUGIN_ID, e.getMessage(), e); - getLog().log(status); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/AbstractPropertiesInitializer.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/AbstractPropertiesInitializer.java deleted file mode 100644 index af8b32fdc..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/AbstractPropertiesInitializer.java +++ /dev/null @@ -1,108 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.initializer; - -import org.eclipse.emf.codegen.ecore.genmodel.GenModelFactory; -import org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.xmi.impl.EcoreResourceFactoryImpl; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; -import org.eclipse.emf.eef.components.resources.ComponentsResourceFactory; -import org.eclipse.emf.eef.views.resources.ViewsResourceFactory; - -/** - * @author Goulwen Le Fur - */ -public abstract class AbstractPropertiesInitializer implements IPropertiesInitializer { - - /** - * The name of the initializer - */ - private String name; - - /** - * The description of the initializer - */ - private String description; - - /** - * @return the name - */ - public String getName() { - return name; - } - - /** - * @param name - * the name to set - */ - public void setName(String name) { - this.name = name; - } - - /** - * @return the description - */ - public String getDescription() { - return description; - } - - /** - * @param description - * the description to set - */ - public void setDescription(String description) { - this.description = description; - } - - /** - * Updates the registry used for looking up a package based namespace, in the resource set. - * - * @param resourceSet - * is the resource set - * @generated - */ - protected void registerPackages(ResourceSet resourceSet) { - resourceSet.getPackageRegistry().put( - org.eclipse.emf.eef.components.ComponentsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.components.ComponentsPackage.eINSTANCE); - resourceSet.getPackageRegistry().put(org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), - org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - resourceSet.getPackageRegistry().put(GenModelPackage.eINSTANCE.getNsURI(), GenModelFactory.eINSTANCE); - resourceSet.getPackageRegistry().put(org.eclipse.emf.eef.views.ViewsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.views.ViewsPackage.eINSTANCE); - resourceSet.getPackageRegistry().put( - org.eclipse.emf.eef.toolkits.ToolkitsPackage.eINSTANCE.getNsURI(), - org.eclipse.emf.eef.toolkits.ToolkitsPackage.eINSTANCE); - - } - - /** - * Updates the registry used for looking up resources factory in the given resource set. - * - * @param resourceSet - * The resource set that is to be updated. - * @generated - */ - protected void registerResourceFactories(ResourceSet resourceSet) { - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put("ecore", - new EcoreResourceFactoryImpl()); - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put("views", - new ViewsResourceFactory()); - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put("components", - new ComponentsResourceFactory()); - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put( - Resource.Factory.Registry.DEFAULT_EXTENSION, new XMIResourceFactoryImpl()); - } - - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/AbstractTransformer.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/AbstractTransformer.java deleted file mode 100644 index ec3d6b21b..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/AbstractTransformer.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.initializer; - -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.ecore.EAnnotation; -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EModelElement; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.util.EcoreUtil; - -/** - * @author Goulwen Le Fur - */ -public abstract class AbstractTransformer { - - protected String genConstraint(EModelElement source, String key) { - if (source != null) { - EAnnotation annotation = source.getEAnnotation("genConstraint"); - if (annotation != null) { - return annotation.getDetails().get(key); - } - } - return null; - } - - protected boolean isSignificant(EStructuralFeature feature) { - if (feature instanceof EAttribute) { - String genConstraint = genConstraint(feature, "significant"); - if (genConstraint != null && genConstraint.equals("false")) - return false; - return true; - } - if (feature instanceof EReference) { - String genConstraint = genConstraint(feature, "significant"); - if (genConstraint != null && genConstraint.equals("false")) - return false; - return true; - } - return true; - } - - protected Object getViewName(EStructuralFeature feature) { - if (genConstraint(feature, "component") != null) - return genConstraint(feature, "component"); - return null; - } - - protected boolean inheritedMember(EStructuralFeature feature, EClass current) { - return !feature.getEContainingClass().equals(current) && getViewName(feature) != null; - } - - protected EStructuralFeature findEStructuralFeature(EPackage metamodel, String name) { - TreeIterator allContents = metamodel.eAllContents(); - while (allContents.hasNext()) { - EObject next = allContents.next(); - if (next instanceof EStructuralFeature && name.equals(((EStructuralFeature)next).getName())) - return (EStructuralFeature)next; - } - return null; - } - - protected EClass findEClass(EPackage metamodel, String name) { - EcoreUtil.resolveAll(metamodel.eResource().getResourceSet()); - TreeIterator allContents = metamodel.eResource().getResourceSet().getAllContents(); - while (allContents.hasNext()) { - Notifier next = allContents.next(); - if (next instanceof EClass && name.equals(((EClass)next).getName())) - return (EClass)next; - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/ComponentTransformer.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/ComponentTransformer.java deleted file mode 100644 index 172b2a566..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/ComponentTransformer.java +++ /dev/null @@ -1,126 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.initializer; - -import java.util.List; -import java.util.Map; - -import org.eclipse.emf.codegen.ecore.genmodel.GenClass; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.components.ComponentsFactory; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.MappingFactory; -import org.eclipse.emf.eef.views.Container; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewElement; - -/** - * @author Goulwen Le Fur - */ -public class ComponentTransformer extends AbstractTransformer { - - private Map> workingResolvTemp; - - /* ===== Constructor ===== */ - - public ComponentTransformer(Map> workingResolvTemp) { - this.workingResolvTemp = workingResolvTemp; - } - - /* ===== Transformation ===== */ - - public PropertiesEditionContext genPackage2Context(GenPackage genPackage) { - PropertiesEditionContext context = ComponentsFactory.eINSTANCE.createPropertiesEditionContext(); - context.setModel(genPackage); - context.setDocumentation("Edition Context for " + genPackage.getEcorePackage().getName() - + " GenPackage"); - Category components = MappingFactory.eINSTANCE.createCategory(); - components.setName(genPackage.getEcorePackage().getName()); - context.getCategories().add(components); - for (GenClass genClass : genPackage.getGenClasses()) { - if (!genClass.getEcoreClass().isAbstract()) { - components.getBindings().add(genClass2Component(genClass, genPackage)); - } - } - return context; - } - - public PropertiesEditionComponent genClass2Component(GenClass genClass, GenPackage genPackage) { - PropertiesEditionComponent component = ComponentsFactory.eINSTANCE.createPropertiesEditionComponent(); - component.setName(genClass.getEcoreClass().getName()); - component.setModel(genClass.getEcoreClass()); - List list = workingResolvTemp.get(genClass.getEcoreClass()); - for (ViewElement viewElement : list) { - component.getViews().add((View)viewElement); - } - for (EStructuralFeature feature : genClass.getEcoreClass().getEAllStructuralFeatures()) { - if (isSignificant(feature) && !feature.isDerived() - && !inheritedMember(feature, genClass.getEcoreClass())) { - PropertiesEditionElement structuralFeature2EditionElement = eStructuralFeature2EditionElement( - list, feature); - if (structuralFeature2EditionElement != null) - component.getProperties().add(structuralFeature2EditionElement); - } - } - return component; - - } - - public PropertiesEditionElement eStructuralFeature2EditionElement(List concerningViews, - EStructuralFeature feature) { - PropertiesEditionElement element = ComponentsFactory.eINSTANCE.createPropertiesEditionElement(); - element.setName(feature.getName()); - element.setModel(feature); - List list = workingResolvTemp.get(feature); - if (list != null) { - for (ViewElement viewElement : list) { - if (inConcerningViews(concerningViews, viewElement)) - element.getViews().add((ElementEditor)viewElement); - } - } else { - System.err.println("No view found for : " + feature.toString()); - return null; - } - return element; - - } - - /* ===== Misc utilities ===== */ - private boolean inConcerningViews(List concerningViews, ViewElement toCheck) { - for (ViewElement viewElement : concerningViews) { - if (viewElement instanceof View) { - if (inConcerningView((View)viewElement, toCheck)) - return true; - } - } - return false; - } - - private boolean inConcerningView(View concerningView, ViewElement toCheck) { - if (toCheck instanceof View && EcoreUtil.equals(concerningView, toCheck)) - return true; - else { - Container next = toCheck.getContainer(); - if (next != null) - return inConcerningView(concerningView, next); - else - return false; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/IPropertiesInitializer.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/IPropertiesInitializer.java deleted file mode 100644 index 8b57fd60f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/IPropertiesInitializer.java +++ /dev/null @@ -1,20 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.initializer; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.emf.common.util.URI; - -public interface IPropertiesInitializer { - - public void initialize(URI modelURI, IContainer targetFolder) throws Exception; - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/PropertiesInitializer.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/PropertiesInitializer.java deleted file mode 100644 index a0bb40179..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/PropertiesInitializer.java +++ /dev/null @@ -1,208 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.initializer; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.eef.EEFGen.EEFGenFactory; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; -import org.eclipse.emf.eef.codegen.core.util.EMFHelper; -import org.eclipse.emf.eef.codegen.flow.util.GenmodelHelper; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewsFactory; -import org.eclipse.emf.eef.views.ViewsRepository; - -/** - * @author Goulwen Le Fur - */ -public class PropertiesInitializer extends AbstractPropertiesInitializer { - - private static final String SWT_TOOLKIT_NAME = "SWT"; - - private static final String EMF_PROPERTIES_TOOLKIT_NAME = "EMFProperties"; - - private static String swt_pathmap = null; - - private static String emfproperties_pathmap = null; - - private static String findToolkitPath(EObject view, String str) { - String res = "platform:/plugin/org.eclipse.emf.eef.views/std/" + str + ".toolkits"; - return res; - } - - public static String getSWTPathmap(EObject view) { - if (swt_pathmap == null) { - swt_pathmap = findToolkitPath(view, SWT_TOOLKIT_NAME); - } - return swt_pathmap; - } - - public static String getEMFPropertiesPathmap(EObject view) { - if (emfproperties_pathmap == null) { - emfproperties_pathmap = findToolkitPath(view, EMF_PROPERTIES_TOOLKIT_NAME); - } - return emfproperties_pathmap; - } - - public void initialize(URI modelURI, IContainer targetFolder) throws IOException, CoreException { - ResourceSet resourceSet = new ResourceSetImpl(); - registerResourceFactories(resourceSet); - registerPackages(resourceSet); - EObject model = EMFHelper.load(modelURI, resourceSet); - - if (!targetFolder.exists()) { - if (targetFolder instanceof IFolder) - ((IFolder)targetFolder).create(true, true, new NullProgressMonitor()); - else - return; - } - - Map toolkits = new HashMap(); - View instanceView = ViewsFactory.eINSTANCE.createView(); - toolkits.put(SWT_TOOLKIT_NAME, EMFHelper.load(URI.createURI(getSWTPathmap(instanceView), false), model.eResource().getResourceSet())); - toolkits.put(EMF_PROPERTIES_TOOLKIT_NAME, EMFHelper.load(URI.createURI(getEMFPropertiesPathmap(instanceView), false), model.eResource().getResourceSet())); - - ViewTransformer viewTransformer = new ViewTransformer(toolkits); - TreeIterator allContents = model.eAllContents(); - Map repositories = new HashMap(); - List contexts = new ArrayList(); - while (allContents.hasNext()) { - EObject next = allContents.next(); - if (next instanceof GenPackage) { - GenPackage genPack = (GenPackage)next; - if (genPack.getGenClassifiers().size() >= 1) { - ViewsRepository repository = viewTransformer.genPackage2ViewsRepository(genPack, SWT_TOOLKIT_NAME); - String completePackage = genPack.getBasePackage(); - if (completePackage != null && completePackage.length() > 0) { - completePackage += "." + ecoreStringHierarchy(genPack); - } else { - completePackage = ecoreStringHierarchy(genPack); - } - repositories.put(repository, completePackage); - ComponentTransformer componentTransformer = new ComponentTransformer(viewTransformer.getWorkingResolvTemp()); - PropertiesEditionContext context = componentTransformer.genPackage2Context(genPack); - contexts.add(context); - } - } - } - URI componentsModelUri = GenmodelHelper.computePropertiesComponentsModelURI(targetFolder, model.eResource().getURI()); - Resource componentsResource = model.eResource().getResourceSet().createResource(componentsModelUri); - for (PropertiesEditionContext context : contexts) - componentsResource.getContents().add(context); - for (ViewsRepository repository : repositories.keySet()) - componentsResource.getContents().add(repository); - componentsResource.save(Collections.EMPTY_MAP); - EEFGenModel eefGenModel = createEEFGenModel(repositories, contexts, targetFolder); - URI eefgenModelUri = GenmodelHelper.computePropertiesEEFGenModelURI(targetFolder, model.eResource().getURI()); - Resource eefgenResource = model.eResource().getResourceSet().createResource(eefgenModelUri); - eefgenResource.getContents().add(eefGenModel); - eefgenResource.save(Collections.EMPTY_MAP); - return; - - } - - public String ecoreStringHierarchy(GenPackage genPack) { - String result = ""; - List ecorePackageHierarchy = ecorePackageHierarchy(genPack); - for (int i = ecorePackageHierarchy.size() - 1; i >= 0; i--) { - EPackage next = ecorePackageHierarchy.get(i); - result += next.getName(); - if (i > 0) - result += "."; - } - return genPack.getEcorePackage().getName(); - } - - public List ecorePackageHierarchy(GenPackage genPack) { - List hierarchy = new ArrayList(); - EObject current = genPack.getEcorePackage(); - while (current instanceof EPackage) { - hierarchy.add((EPackage) current); - current = current.eContainer(); - } - return hierarchy; - } - - private EEFGenModel createEEFGenModel(Map repositories, List contexts, IContainer targetFolder) { - EEFGenModel eefGenModel = EEFGenFactory.eINSTANCE.createEEFGenModel(); - eefGenModel.setGenDirectory(findGenDirectory(targetFolder)); - for (PropertiesEditionContext context : contexts) - eefGenModel.getEditionContexts().add(createGenEditionContext(context)); - String contextPackage = ""; - if (contexts.size() > 0) { - String findBasePackage = findBasePackage(contexts.get(0).getModel()); - if (findBasePackage != null && !findBasePackage.equals("")) { - contextPackage = findBasePackage + "."; - } - contextPackage = contextPackage + contexts.get(0).getModel().getEcorePackage().getName().toLowerCase(); - } - for (ViewsRepository repository : repositories.keySet()) - eefGenModel.getViewsRepositories().add(createGenViewsRepository(repository, repositories.get(repository))); - return eefGenModel; - } - - private GenEditionContext createGenEditionContext(PropertiesEditionContext context) { - GenEditionContext genEditionContext = EEFGenFactory.eINSTANCE.createGenEditionContext(); - genEditionContext.setPropertiesEditionContext(context); - if (context.getModel() != null) - genEditionContext.setBasePackage(findBasePackage(context.getModel())); - genEditionContext.setDescriptorsGenericPropertiesViews(true); - return genEditionContext; - } - - private GenViewsRepository createGenViewsRepository(ViewsRepository repository, String contextPackage) { - GenViewsRepository genViewsRepository = EEFGenFactory.eINSTANCE.createGenViewsRepository(); - genViewsRepository.setViewsRepository(repository); - genViewsRepository.setBasePackage(contextPackage); - genViewsRepository.setSwtViews(true); - genViewsRepository.setFormViews(true); - return genViewsRepository; - } - - private String findBasePackage(GenPackage genPackage) { - if (genPackage.getBasePackage() != null) - return genPackage.getBasePackage(); - return ""; - } - - private String findGenDirectory(IContainer targetFolder) { - IProject project; - if (targetFolder instanceof IFolder) { - project = targetFolder.getProject(); - } else { - project = (IProject) targetFolder; - } - - return project.getFullPath().toString() + "/src-gen"; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/ViewTransformer.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/ViewTransformer.java deleted file mode 100644 index 9007d0a8f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/initializer/ViewTransformer.java +++ /dev/null @@ -1,242 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.initializer; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.emf.codegen.ecore.genmodel.GenAnnotation; -import org.eclipse.emf.codegen.ecore.genmodel.GenClass; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.common.util.UniqueEList; -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.eef.toolkits.Widget; -import org.eclipse.emf.eef.views.Category; -import org.eclipse.emf.eef.views.Container; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewElement; -import org.eclipse.emf.eef.views.ViewsFactory; -import org.eclipse.emf.eef.views.ViewsRepository; - -/** - * @author Goulwen Le Fur - */ -public class ViewTransformer extends AbstractTransformer { - - private Map toolkits; - - private Map> workingResolvTemp; - - private ViewsRepository repository; - - /* ===== Constructor ===== */ - - public ViewTransformer(Map toolkits) { - this.toolkits = toolkits; - workingResolvTemp = new HashMap>(); - } - - /* ===== Getters/Setters ===== */ - public Map> getWorkingResolvTemp() { - return workingResolvTemp; - } - - public void addElementToEObject(EObject source, ViewElement element) { - if (workingResolvTemp.get(source) != null) - workingResolvTemp.get(source).add(element); - else { - List list = new UniqueEList(); - list.add(element); - workingResolvTemp.put(source, list); - } - } - - /* ===== Transformation ===== */ - - public ViewsRepository genPackage2ViewsRepository(GenPackage genPackage, String repositoryKind) { - - repository = ViewsFactory.eINSTANCE.createViewsRepository(); - repository.getRepositoryKind().add("SWT"); - repository.getRepositoryKind().add("Form"); - repository.setName(genPackage.getEcorePackage().getName()); - repository.setDocumentation("Views repository for " + genPackage.getEcorePackage().getName() - + " GenPackage"); - Category views = ViewsFactory.eINSTANCE.createCategory(); - views.setName(genPackage.getEcorePackage().getName()); - repository.getCategories().add(views); - for (GenClass genClass : genPackage.getGenClasses()) { - if (!genClass.getEcoreClass().isAbstract()) { - views.getViews().addAll(genClass2Views(genClass)); - } - } - - return repository; - - } - - public List genClass2Views(GenClass genClass) { - List result = new ArrayList(); - View view = ViewsFactory.eINSTANCE.createView(); - view.setExplicit(true); - View additionalView = genClass2AdditionalView(genClass); - view.setName(genClass.getName()); - Map> groups = genClassGroups(genClass); - for (String name : groups.keySet()) { - if (!name.equals("view")) { - Container container = ViewsFactory.eINSTANCE.createContainer(); - container.setName(name); - container.setRepresentation(getWidget("Group")); - List features = groups.get(name); - for (EStructuralFeature structuralFeature : features) { - if (!structuralFeature.isDerived()) { - ElementEditor editor = eStructuralFeature2ViewElement(structuralFeature); - if (editor != null) - container.getElements().add(editor); - } - } - view.getElements().add(container); - } - } - if (groups.get("view") != null) { - List features = groups.get("view"); - for (EStructuralFeature structuralFeature : features) { - if (!structuralFeature.isDerived()) { - ElementEditor editor = eStructuralFeature2ViewElement(structuralFeature); - if (editor != null) - view.getElements().add(editor); - } - } - } - result.add(view); - addElementToEObject(genClass.getEcoreClass(), view); - if (additionalView != null) { - result.add(additionalView); - addElementToEObject(genClass.getEcoreClass(), additionalView); - } - return result; - } - - public View genClass2AdditionalView(GenClass genClass) { - View newView = null; - GenAnnotation genAnnotation = genClass.getGenAnnotation("component"); - if (genAnnotation != null) { - newView = ViewsFactory.eINSTANCE.createCustomView(); - String name = genAnnotation.getDetails().get("name"); - if (name != null) { - newView.setName(genClass.getName() + name); - } - } - return newView; - - } - - public ElementEditor eStructuralFeature2ViewElement(EStructuralFeature feature) { - ElementEditor result = ViewsFactory.eINSTANCE.createElementEditor(); - result.setName(feature.getName()); - if (feature instanceof EAttribute) { - if (feature.isMany()) { - result.setRepresentation(getWidget("MultiValuedEditor")); - } else { - if (feature.getEType().getName().equals("EBoolean") - || feature.getEType().getName().equals("EBool") - || feature.getEType().getName().equalsIgnoreCase("Boolean")) { - result.setRepresentation(getWidget("Checkbox")); - } else if (EcorePackage.eINSTANCE.getEEnum().isInstance(feature.getEType())) { - result.setRepresentation(getWidget("EMFComboViewer")); - } - // FIXME: HACK - else if ("documentation".equals(feature.getName())) { - result.setRepresentation(getWidget("Textarea")); - } else { - result.setRepresentation(getWidget("Text")); - } - } - } else if (feature instanceof EReference) { - EReference reference = (EReference)feature; - if (reference.isContainment()) { - if (reference.isMany()) - result.setRepresentation(getWidget("AdvancedTableComposition")); - else { - return null; - } - } else { - if (reference.isMany()) - result.setRepresentation(getWidget("AdvancedReferencesTable")); - else - result.setRepresentation(getWidget("EObjectFlatComboViewer")); - } - } - addElementToEObject(feature, result); - return result; - } - - /* ===== Widgets management ===== */ - - protected Widget getWidget(String name) { - if (name != null) { - for (String key : toolkits.keySet()) { - EObject toolkit = toolkits.get(key); - TreeIterator iter = toolkit.eAllContents(); - while (iter.hasNext()) { - EObject next = iter.next(); - if (next instanceof Widget && name.equals(((Widget)next).getName())) - return (Widget)next; - } - } - } - return null; - } - - /* ===== GenConstraint management ===== */ - - private Map> genClassGroups(GenClass genClass) { - Map> result = new HashMap>(); - for (EStructuralFeature feature : genClass.getEcoreClass().getEAllStructuralFeatures()) { - if (isSignificant(feature) && getViewName(feature) == null) { - String groupConstraint = genConstraint(feature, "group"); - if (groupConstraint != null) { - addToGroup(result, feature, groupConstraint); - } else { - // FIXME: HACK - String docConstraint = genConstraint(feature, "documentation"); - if ("true".equals(docConstraint)) - addToGroup(result, feature, "view"); - else - addToGroup(result, feature, "properties"); - } - } - } - - return result; - } - - /* ===== Misc utilities ===== */ - - private void addToGroup(Map> result, EStructuralFeature feature, - String genConstraint) { - if (result.get(genConstraint) != null) - result.get(genConstraint).add(feature); - else { - List list = new ArrayList(); - list.add(feature); - result.put(genConstraint, list); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/AbstractPropertiesGeneratorLauncher.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/AbstractPropertiesGeneratorLauncher.java deleted file mode 100644 index 98246cc39..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/AbstractPropertiesGeneratorLauncher.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.launcher; - -import java.io.IOException; -import java.net.URL; -import java.util.Enumeration; -import java.util.HashSet; -import java.util.Set; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.common.util.URI; -import org.osgi.framework.Bundle; - -/** - * @author Goulwen Le Fur - */ -public abstract class AbstractPropertiesGeneratorLauncher implements IPropertiesGeneratorLauncher { - - /** - * Name of the launcher - */ - private String name; - - /** - * @return the name - */ - public String getName() { - return name; - } - - /** - * @param name - * the name to set - */ - public void setName(String name) { - this.name = name; - } - - /** - * A set containing the generation target - */ - protected Set targetContainer = new HashSet(); - - /** - * @return the targetContainer - */ - public Set getTargetContainer() { - return targetContainer; - } - - /** - * Finds the template in the plug-in. Returns the template plug-in URI. - * - * @param bundleID - * is the plug-in ID - * @param relativePath - * is the relative path of the template in the plug-in - * @return the template URI - * @throws IOException - * @deprecated - */ - protected URI getTemplateURI(String bundleID, IPath relativePath) throws IOException { - Bundle bundle = Platform.getBundle(bundleID); - if (bundle == null) { - // no need to go any further - return URI.createPlatformResourceURI(new Path(bundleID).append(relativePath).toString(), false); - } - URL url = bundle.getEntry(relativePath.toString()); - if (url == null && relativePath.segmentCount() > 1) { - Enumeration entries = bundle.findEntries("/", "*.emtl", true); - if (entries != null) { - String[] segmentsRelativePath = relativePath.segments(); - while (url == null && entries.hasMoreElements()) { - URL entry = entries.nextElement(); - IPath path = new Path(entry.getPath()); - if (path.segmentCount() > relativePath.segmentCount()) { - path = path.removeFirstSegments(path.segmentCount() - relativePath.segmentCount()); - } - String[] segmentsPath = path.segments(); - boolean equals = segmentsPath.length == segmentsRelativePath.length; - for (int i = 0; equals && i < segmentsPath.length; i++) { - equals = segmentsPath[i].equals(segmentsRelativePath[i]); - } - if (equals) { - url = bundle.getEntry(entry.getPath()); - } - } - } - } - URI result; - if (url != null) { - result = URI.createPlatformPluginURI(new Path(bundleID).append(new Path(url.getPath())) - .toString(), false); - } else { - result = URI.createPlatformResourceURI(new Path(bundleID).append(relativePath).toString(), false); - } - return result; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/EEFLauncher.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/EEFLauncher.java deleted file mode 100644 index 1bd70afd5..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/EEFLauncher.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.launcher; - -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.URI; - -/** - * @author Goulwen Le Fur - * @deprecated use {@link org.eclipse.emf.eef.codegen.launcher.EEFLauncher} - */ -public class EEFLauncher { - - /** - * @param args - */ - public static void main(String[] args) { - try { - if (args.length != 3) { - System.out.println("Arguments not valid : {model, folder, basePackage}."); - } else { - URI modelURI = URI.createFileURI(args[0]); - File folder = new File(args[1]); - BasicMonitor monitor = new BasicMonitor(); - List arguments = new ArrayList(); - arguments.add(args[2]); - - monitor.subTask("Loading..."); - org.eclipse.emf.eef.codegen.launcher.EEFLauncher launcher = new org.eclipse.emf.eef.codegen.launcher.EEFLauncher(modelURI, folder, arguments); - monitor.worked(1); - monitor.subTask("Generating using " - + modelURI.lastSegment() + "..."); - launcher.doGenerate(monitor); - monitor.worked(1); - } - } catch (IOException e) { - e.printStackTrace(); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/EMFPropertiesLauncher.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/EMFPropertiesLauncher.java deleted file mode 100644 index f408d3ab3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/EMFPropertiesLauncher.java +++ /dev/null @@ -1,27 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.launcher; - - -/** - * @author Goulwen Le Fur - * @deprecated use {@link org.eclipse.emf.eef.codegen.launcher.EEFLauncher} - */ -public class EMFPropertiesLauncher { - - /** - * @param args - */ - public static void main(String[] args) { - EEFLauncher.main(args); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/IPropertiesGeneratorLauncher.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/IPropertiesGeneratorLauncher.java deleted file mode 100644 index a6340a547..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/launcher/IPropertiesGeneratorLauncher.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.launcher; - -import java.io.File; - -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; - -/** - * @author Goulwen Le Fur - */ -public interface IPropertiesGeneratorLauncher { - - public void doGenerate(EEFGenModel eefGenModel, File targetFolder, IProgressMonitor monitor); - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/services/PropertiesGeneratorLaunchersServices.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/services/PropertiesGeneratorLaunchersServices.java deleted file mode 100644 index 5e358e4fc..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/services/PropertiesGeneratorLaunchersServices.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.services; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IConfigurationElement; -import org.eclipse.core.runtime.IExtension; -import org.eclipse.core.runtime.IExtensionPoint; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.launcher.AbstractPropertiesGeneratorLauncher; - -/** - * @author Goulwen Le Fur - */ -public class PropertiesGeneratorLaunchersServices { - - /** - * The extension name. - */ - public static final String EXTENSION_NAME = "PropertiesGeneratorLauncher"; //$NON-NLS-1$ - - /** - * The extension's element name. - */ - private static final String EXTENSION_ELEMENT_NAME = "PropertiesGeneratorLauncher"; //$NON-NLS-1$ - - /** - * The element's attribute name. - */ - private static final String EXTENSION_ATTRIBUTE_NAME = "name"; //$NON-NLS-1$ - - /** - * The launcher class. - */ - private static final String EXTENSION_ATTRIBUTE_CLASS = "generatorLauncher"; //$NON-NLS-1$ - - /** - * The instance of the service - */ - private static PropertiesGeneratorLaunchersServices instance = new PropertiesGeneratorLaunchersServices(); - - /** - * The discovered strategies - */ - private List launchers; - - /** - * Default constructor - */ - private PropertiesGeneratorLaunchersServices() { - configureService(); - } - - /** - * @return the service instance - */ - public static PropertiesGeneratorLaunchersServices getInstance() { - return instance; - } - - /** - * @return the strategies - */ - public List getlaunchers() { - return launchers; - } - - /** - * Load all the providers registered by extension point. - */ - private void configureService() { - launchers = new ArrayList(); - IExtensionPoint extensionPoint = Platform.getExtensionRegistry().getExtensionPoint( - EEFCodegenPlugin.PLUGIN_ID, EXTENSION_NAME); - - IExtension[] extensions = extensionPoint.getExtensions(); - for (int extensionIndex = 0; extensionIndex < extensions.length; extensionIndex++) { - IExtension extension = extensions[extensionIndex]; - IConfigurationElement[] configurationElements = extension.getConfigurationElements(); - for (int i = 0; i < configurationElements.length; i++) { - IConfigurationElement cfg = configurationElements[i]; - - if (EXTENSION_ELEMENT_NAME.equals(cfg.getName())) { - try { - AbstractPropertiesGeneratorLauncher launcher = (AbstractPropertiesGeneratorLauncher)cfg - .createExecutableExtension(EXTENSION_ATTRIBUTE_CLASS); - String nameAttribute = cfg.getAttribute(EXTENSION_ATTRIBUTE_NAME); - if (nameAttribute != null) - launcher.setName(nameAttribute); - launchers.add(launcher); - } catch (CoreException e) { - e.printStackTrace(); - } - } - } - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/services/PropertiesInitializerStrategyServices.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/services/PropertiesInitializerStrategyServices.java deleted file mode 100644 index 31ebc28b7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/services/PropertiesInitializerStrategyServices.java +++ /dev/null @@ -1,120 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.services; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IConfigurationElement; -import org.eclipse.core.runtime.IExtension; -import org.eclipse.core.runtime.IExtensionPoint; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.initializer.AbstractPropertiesInitializer; - -/** - * @author Goulwen Le Fur - */ -public class PropertiesInitializerStrategyServices { - - /** - * The extension name. - */ - public static final String EXTENSION_NAME = "PropertiesInitializerStrategy"; //$NON-NLS-1$ - - /** - * The extension's element name. - */ - private static final String EXTENSION_ELEMENT_NAME = "PropertiesInitializerStrategy"; //$NON-NLS-1$ - - /** - * The element's attribute name. - */ - private static final String EXTENSION_ATTRIBUTE_NAME = "name"; //$NON-NLS-1$ - - /** - * The element's attribute description. - */ - private static final String EXTENSION_ATTRIBUTE_DESCRIPTION = "description"; //$NON-NLS-1$ - - /** - * The element's attribute class. - */ - private static final String EXTENSION_ATTRIBUTE_CLASS = "strategyClass"; //$NON-NLS-1$ - - /** - * The instance of the service - */ - private static PropertiesInitializerStrategyServices instance = new PropertiesInitializerStrategyServices(); - - /** - * The discovered strategies - */ - private List strategies; - - /** - * Default constructor - */ - private PropertiesInitializerStrategyServices() { - configureService(); - } - - /** - * @return the service instance - */ - public static PropertiesInitializerStrategyServices getInstance() { - return instance; - } - - /** - * @return the strategies - */ - public List getStrategies() { - return strategies; - } - - /** - * Load all the providers registered by extension point. - */ - private void configureService() { - strategies = new ArrayList(); - IExtensionPoint extensionPoint = Platform.getExtensionRegistry().getExtensionPoint( - EEFCodegenPlugin.PLUGIN_ID, EXTENSION_NAME); - - IExtension[] extensions = extensionPoint.getExtensions(); - for (int extensionIndex = 0; extensionIndex < extensions.length; extensionIndex++) { - IExtension extension = extensions[extensionIndex]; - IConfigurationElement[] configurationElements = extension.getConfigurationElements(); - for (int i = 0; i < configurationElements.length; i++) { - IConfigurationElement cfg = configurationElements[i]; - - if (EXTENSION_ELEMENT_NAME.equals(cfg.getName())) { - try { - AbstractPropertiesInitializer initializer = (AbstractPropertiesInitializer)cfg - .createExecutableExtension(EXTENSION_ATTRIBUTE_CLASS); - String nameAttribute = cfg.getAttribute(EXTENSION_ATTRIBUTE_NAME); - if (nameAttribute != null) - initializer.setName(nameAttribute); - String descriptionAttribute = cfg.getAttribute(EXTENSION_ATTRIBUTE_DESCRIPTION); - if (descriptionAttribute != null) - initializer.setDescription(descriptionAttribute); - strategies.add(initializer); - } catch (CoreException e) { - e.printStackTrace(); - } - } - } - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/BundleHelper.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/BundleHelper.java deleted file mode 100644 index 14e7de63d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/BundleHelper.java +++ /dev/null @@ -1,101 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.util; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.Path; -import org.eclipse.pde.core.plugin.IPluginBase; -import org.eclipse.pde.core.plugin.IPluginImport; -import org.eclipse.pde.internal.core.bundle.BundlePluginModel; -import org.eclipse.pde.internal.core.bundle.BundlePluginModelBase; -import org.eclipse.pde.internal.core.bundle.WorkspaceBundleModel; - -/** - * @author Goulwen Le Fur - * - */ -public class BundleHelper { - - private static final String MANIFEST_FILE_PATH = "META-INF/MANIFEST.MF"; - private IProject bundleProject; - private BundlePluginModel pluginModel; - - /** - * @param bundleProject the bundle project to use - */ - public BundleHelper(IProject bundleProject) { - super(); - this.bundleProject = bundleProject; - } - - /** - * Extract the bundle model from the project. - * @return the extracted model - */ - public BundlePluginModel getBundlePluginModel() { - if (pluginModel == null) { - IFile manifest = bundleProject.getFile(new Path(MANIFEST_FILE_PATH)); - WorkspaceBundleModel bModel = new WorkspaceBundleModel(manifest); - bModel.load(); -// WorkspaceExtensionsModel eModel = new WorkspaceExtensionsModel(pluginxml); - pluginModel = new BundlePluginModel(); - pluginModel.setBundleModel(bModel); -// pluginModel.setExtensionsModel(eModel); - } - return pluginModel; - } - - /** - * Add a bundle to the dependencies of the managed plugin - * @param bundleToAdd the bundle to add. - * @throws CoreException an error occured during the process. - */ - public void addDependency(String bundleToAdd) throws CoreException { - IPluginBase pluginBase = getBundlePluginModel().getPluginBase(); - //TODO: Verifier la non existance effective -// IPluginImport[] imports = pluginBase.getImports(); - IPluginImport createImport = ((BundlePluginModelBase)getBundlePluginModel().getPluginFactory()).createImport(bundleToAdd); - createImport.setReexported(true); - pluginBase.add(createImport); - getBundlePluginModel().save(); - } - -// @SuppressWarnings("restriction") -// public void addExtension(String id) throws CoreException { -// getBundlePluginModel().getExtensionsModel().load(); -// IPluginExtension extension = getBundlePluginModel().getFactory().createExtension(); -// extension.setPoint(id); -// ISchemaElement schemaElement = null; -// Object object = extension.getSchema(); -// if ((object != null) && (object instanceof Schema)) { -// Schema schema = (Schema) object; -// if (extension instanceof PluginExtension) { -// PluginExtension pluginExt = (PluginExtension) extension; -// String name = "PropertiesEditionPartProvider"; -// schemaElement = schema.findElement(name); -// } -// if (extension instanceof PluginExtensionNode) { -// // Get the extension's XML element name -// String elementName = ((PluginExtensionNode) extension).getXMLTagName(); -// // Find the extension's corresponding schema element -// schemaElement = schema.findElement(elementName); -// } -// // If there is an associated schema, do the auto-insert -// if (schemaElement != null) { -// XMLInsertionComputer.computeInsertion(schemaElement, extension); -// } -// } -// getBundlePluginModel().save(); -// } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/EMFHelper.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/EMFHelper.java deleted file mode 100644 index d1f3c10dd..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/EMFHelper.java +++ /dev/null @@ -1,120 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.util; - -import java.io.IOException; -import java.util.HashMap; -import java.util.Map; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.xmi.XMLResource; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; - -/** - * @author Goulwen Le Fur - * - */ -public class EMFHelper { - - /** - * @param modelURI - * @param resourceSet - * @return - * @throws IOException - */ - public static EObject load(URI modelURI, ResourceSet resourceSet) throws IOException { - EObject result = null; - Resource modelResource = null; - modelResource = resourceAlreadyLoaded(modelURI, resourceSet, modelResource); - if (modelResource == null) { - modelResource = createResource(modelURI, resourceSet); - final Map options = new HashMap(); - options.put(XMLResource.OPTION_ENCODING, System.getProperty("file.encoding")); - modelResource.load(options); - } - if (modelResource.getContents().size() > 0) { - result = modelResource.getContents().get(0); - } else { - // Maybe the resource was deleted. Try a reload - modelResource.unload(); - final Map options = new HashMap(); - options.put(XMLResource.OPTION_ENCODING, System.getProperty("file.encoding")); - modelResource.load(options); - if (modelResource.getContents().size() > 0) { - result = modelResource.getContents().get(0); - } - } - return result; - } - - /** - * @param modelURI - * @param resourceSet - * @param modelResource - * @return - */ - protected static Resource resourceAlreadyLoaded(URI modelURI, ResourceSet resourceSet, Resource modelResource) { - for (Resource resource : resourceSet.getResources()) { - if (resource.getURI().equals(modelURI)) { - modelResource = resource; - } - } - return modelResource; - } - - /** - * This will create a {@link Resource} given the model extension it is intended for and a ResourceSet. - * - * @param modelURI - * {@link org.eclipse.emf.common.util.URI URI} where the model is stored. - * @param resourceSet - * The {@link ResourceSet} to load the model in. - * @return The {@link Resource} given the model extension it is intended for. - * @generated - */ - public static Resource createResource(URI modelURI, ResourceSet resourceSet) { - String fileExtension = modelURI.fileExtension(); - if (fileExtension == null || fileExtension.length() == 0) { - fileExtension = Resource.Factory.Registry.DEFAULT_EXTENSION; - } - final Resource.Factory.Registry registry = Resource.Factory.Registry.INSTANCE; - final Object resourceFactory = registry.getExtensionToFactoryMap().get(fileExtension); - if (resourceFactory != null) { - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(fileExtension, - resourceFactory); - } else { - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(fileExtension, - new XMIResourceFactoryImpl()); - } - return resourceSet.createResource(modelURI); - } - - - /** - * @param eObject - * @return - */ - public static IFile associatedFile(EObject eObject) { - if (eObject.eResource().getURI().isPlatformResource()) { - URI uri = eObject.eResource().getURI(); - String path = uri.toString().substring("platform:/resource".length()); - return ResourcesPlugin.getWorkspace().getRoot().getFile(new Path(path)); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/ExtensionHelper.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/ExtensionHelper.java deleted file mode 100644 index 1d0ed3432..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/core/util/ExtensionHelper.java +++ /dev/null @@ -1,247 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.core.util; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import javax.xml.parsers.DocumentBuilder; -import javax.xml.parsers.DocumentBuilderFactory; -import javax.xml.parsers.ParserConfigurationException; -import javax.xml.transform.Transformer; -import javax.xml.transform.TransformerConfigurationException; -import javax.xml.transform.TransformerException; -import javax.xml.transform.TransformerFactory; -import javax.xml.transform.TransformerFactoryConfigurationError; -import javax.xml.transform.dom.DOMSource; -import javax.xml.transform.stream.StreamResult; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.runtime.Path; -import org.w3c.dom.Document; -import org.w3c.dom.NamedNodeMap; -import org.w3c.dom.Node; -import org.w3c.dom.NodeList; -import org.xml.sax.SAXException; - -/** - * @author Goulwen Le Fur - * - */ -public class ExtensionHelper { - - private static final String POINT_ATTRIBUTE_NAME = "point"; - - private static final String EXTENSION_TAG = "extension"; - - private static final String PLUGIN_TAG_NAME = "plugin"; - - private static final String PLUGIN_XML_FILE_PATH = "plugin.xml"; - - private IProject bundleProject; - private Document document; - private IFile pluginXML; - - /** - * @param pluginProject - * @throws ParserConfigurationException - * @throws IOException - * @throws SAXException - */ - public ExtensionHelper(IProject pluginProject) throws ParserConfigurationException, SAXException, IOException { - this.bundleProject = pluginProject; - this.pluginXML = pluginXML(); - DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); - factory.setIgnoringElementContentWhitespace(false); - DocumentBuilder builder = factory.newDocumentBuilder(); - document = builder.parse(pluginXML.getLocation().toFile()); - } - - public ExtensionHelper(IFile pluginXML) throws ParserConfigurationException, SAXException, IOException { - this.bundleProject = pluginXML.getProject(); - this.pluginXML = pluginXML; - DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); - DocumentBuilder builder = factory.newDocumentBuilder(); - document = builder.parse(pluginXML.getLocation().toFile()); - } - - - /** - * @return - */ - public List extensions() { - List result = new ArrayList(); - Node pluginTag = pluginTag(); - if (pluginTag != null && pluginTag.hasChildNodes()) { - NodeList elementsByTagName = document.getElementsByTagName(EXTENSION_TAG); - int i = 0; - Node next = elementsByTagName.item(i); - while (next != null) { - result.add(next); - i++; - next = elementsByTagName.item(i); - } - } - return result; - } - - /** - * @param id - * @return - */ - public List extensionsWithID(String id) { - List result = new ArrayList(); - for (Node node : extensions()) { - NamedNodeMap attributes = node.getAttributes(); - Node namedItem = attributes.getNamedItem(POINT_ATTRIBUTE_NAME); - if (namedItem != null && namedItem.getNodeValue().equals(id)) { - result.add(node); - } - } - return result; - } - - /** - * @param n1 - * @return - */ - public boolean hasExtension(Node n1) { - for (Node node : extensions()) { - if (extensionsEqual(n1, node)) { - return true; - } - } - return false; - } - - /** - * @return the "plugin.xml" file of the plugin - */ - public IFile pluginXML() { - if (pluginXML == null) { - return bundleProject.getFile(new Path(PLUGIN_XML_FILE_PATH)); - } else { - return pluginXML; - } - } - - /** - * @param helper - * @return - */ - public List diff(ExtensionHelper helper) { - List extensions = helper.extensions(); - List res = new ArrayList(extensions.size()); - for (Node ext : extensions) { - if (!hasExtension(ext)) { - res.add(ext); - } - } - return res; - } - - - /** - * @param extensions - * @throws TransformerException - * @throws TransformerFactoryConfigurationError - * @throws TransformerConfigurationException - */ - public void append(List extensions) throws TransformerConfigurationException, TransformerFactoryConfigurationError, TransformerException { - for (Node node : extensions) { - Node importNode = document.importNode(node, true); - pluginTag().appendChild(importNode); - } - save(); - } - - public void save() throws TransformerConfigurationException, TransformerFactoryConfigurationError, TransformerException { - Transformer transformer = TransformerFactory.newInstance().newTransformer(); - StreamResult result = new StreamResult(pluginXML.getLocation().toFile()); - DOMSource source = new DOMSource(document); - transformer.transform(source, result); - } - - /** - * @param n1 - * @param n2 - * @return - */ - private boolean extensionsEqual(Node n1, Node n2) { - boolean res = extensionAttributesEquals(n1, n2); - if (res) { - // All attributes are equals, comparing sub-nodes - NodeList childNodes = n1.getChildNodes(); - for (int i = 0; i < childNodes.getLength(); i++) { - Node childNode = childNodes.item(i); - if (!hasAMatchingSubNode(childNode, n2)) { - return false; - } - } - } - return res; - } - - private boolean extensionAttributesEquals(Node n1, Node n2) { - NamedNodeMap n1Attributes = n1.getAttributes(); - NamedNodeMap n2Attributes = n2.getAttributes(); - if (n1Attributes == null) { - if (n2Attributes == null) { - return true; - } - else { - return false; - } - } - else if (n2Attributes == null) { - return false; - } else { - for (int i = 0; i < n1Attributes.getLength(); i++) { - Node item = n1Attributes.item(i); - String nodeName = item.getNodeName(); - Node matchingItem = n2Attributes.getNamedItem(nodeName); - if (!item.getNodeValue().equals(matchingItem.getNodeValue())) { - return false; - } - } - return true; - } - } - - /** - * @param subNode - * @param processingNode - * @return - */ - private boolean hasAMatchingSubNode(Node subNode, Node processingNode) { - NodeList childNodes = processingNode.getChildNodes(); - for (int i = 0; i < childNodes.getLength(); i++) { - Node childNode = childNodes.item(i); - if (extensionsEqual(subNode, childNode)) { - return true; - } - } - return false; - } - - /** - * @return - */ - private Node pluginTag() { - NodeList pluginTags = document.getElementsByTagName(PLUGIN_TAG_NAME); - if (pluginTags.item(0) != null) - return pluginTags.item(0); - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/AddDependency.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/AddDependency.java deleted file mode 100644 index b099a5fb4..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/AddDependency.java +++ /dev/null @@ -1,65 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.impl; - -import org.eclipse.core.resources.IProject; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.util.BundleHelper; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; - -/** - * @author Goulwen Le Fur - * - */ -public class AddDependency extends Step { - - private Object project; - private String dependency; - - /** - * @param name of the step - */ - public AddDependency(String name, Object project, String dependency) { - super(name); - this.project = project; - this.dependency = dependency; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - public IStatus execute(IProgressMonitor monitor) { - try { - BundleHelper bundleHelper = new BundleHelper(getEditProject()); - bundleHelper.addDependency(dependency); - return Status.OK_STATUS; - } catch (CoreException e) { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "An error occured when adding dependency.", e); - } - } - - private IProject getEditProject() { - if (project instanceof IProject) { - return (IProject) project; - } else if (project instanceof WorkflowVariable) { - return (IProject) ((WorkflowVariable)project).getValue(); - } else { - return null; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEEFCode.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEEFCode.java deleted file mode 100644 index 4c28d3314..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEEFCode.java +++ /dev/null @@ -1,69 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.impl; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; -import org.eclipse.emf.eef.codegen.ui.generators.callback.EEFGenerationCallback; -import org.eclipse.emf.eef.codegen.ui.generators.common.GenerationHelper; - -/** - * @author Goulwen Le Fur - * - */ -public class GenerateEEFCode extends Step { - - private Object eefgenModel; - private List callbacks; - - /** - * @param name of the step - */ - public GenerateEEFCode(String name, Object eefgenModel) { - super(name); - this.eefgenModel = eefgenModel; - callbacks = new ArrayList(1); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - public IStatus execute(IProgressMonitor monitor) { - List eefgenModels = new ArrayList(1); - eefgenModels.add(getEEFGenModel()); - GenerationHelper generationHelper = new GenerationHelper(eefgenModels, callbacks); - generationHelper.generate(monitor); - return Status.OK_STATUS; - } - - public void addGenerationCallback(EEFGenerationCallback callback) { - callbacks.add(callback); - } - - public EEFGenModel getEEFGenModel() { - if (eefgenModel instanceof EEFGenModel) { - return (EEFGenModel) eefgenModel; - } else if (eefgenModel instanceof WorkflowVariable) { - return (EEFGenModel) ((WorkflowVariable)eefgenModel).getValue(); - } else { - return null; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEEFModels.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEEFModels.java deleted file mode 100644 index 994ff241f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEEFModels.java +++ /dev/null @@ -1,163 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.impl; - -import java.io.IOException; - -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.initializer.PropertiesInitializer; -import org.eclipse.emf.eef.codegen.core.util.EMFHelper; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; - -/** - * @author Goulwen Le Fur - * - */ -public class GenerateEEFModels extends Step { - - private PropertiesInitializer propertiesInitializer; - private Object modelURI; - private Object editGenProject; - private Object genmodelURI; - private WorkflowVariable eefgenModelVar; - private WorkflowVariable eefModelsFolderVar; - private String modelsFolderPath; - - /** - * @param name of the step - */ - public GenerateEEFModels(String name, Object modelURI, Object editGenProject, Object genmodelURI, String modelsFolderPath) { - super(name); - this.modelURI = modelURI; - this.editGenProject = editGenProject; - this.genmodelURI = genmodelURI; - this.modelsFolderPath = modelsFolderPath; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - public IStatus execute(IProgressMonitor monitor) { - try { - IProject editProject = getEditProject(); - if (editProject != null) { - propertiesInitializer = new PropertiesInitializer(); - IFolder modelsFolder = createEEFModelsFolder(editProject, monitor); - initializeEEFModels(modelsFolder, getGenModelURI()); - EEFGenModel eefgenModel = generatedEEFGen(getModelURI(), modelsFolder); - ((WorkflowVariable)getEEFGenModel()).setValue(eefgenModel); - return Status.OK_STATUS; - } - else { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "Unable to find edit project"); - } - } catch (IOException e) { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "An error occured during EEF models initialization."); - } catch (CoreException e) { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "An error occured during EEF models initialization."); - } - } - - public Object getEEFGenModel() { - if (eefgenModelVar == null) { - eefgenModelVar = new WorkflowVariable(eefgenmodelVarName()); - } - return eefgenModelVar; - } - - private final String eefgenmodelVarName() { - return "GEN_EEF_MODELS_" + name + "_EEFGENMODEL"; - } - - public Object getEEFModelsFolder() { - if (eefModelsFolderVar == null) { - eefModelsFolderVar = new WorkflowVariable(eefModelsFolderVarName()); - } - return eefModelsFolderVar; - } - - private final String eefModelsFolderVarName() { - return "GEN_EEF_MODELS_" + name + "_EEFMODELSFOLDER"; - } - - private URI getModelURI() { - if (modelURI instanceof URI) { - return (URI) modelURI; - } else if (modelURI instanceof WorkflowVariable) { - return (URI) ((WorkflowVariable)modelURI).getValue(); - } - return null; - } - - private URI getGenModelURI() { - if (genmodelURI instanceof URI) { - return (URI) genmodelURI; - } else if (genmodelURI instanceof WorkflowVariable) { - return (URI) ((WorkflowVariable)genmodelURI).getValue(); - } - return null; - } - - private IProject getEditProject() { - if (editGenProject instanceof IProject) { - return (IProject) editGenProject; - } else if (editGenProject instanceof WorkflowVariable) { - return (IProject) ((WorkflowVariable)editGenProject).getValue(); - } - else { - return null; - } - } - - private void initializeEEFModels(IFolder modelsFolder, URI genmodelURI) throws IOException, CoreException { - NullProgressMonitor monitor = new NullProgressMonitor(); - propertiesInitializer.initialize(genmodelURI, modelsFolder); - modelsFolder.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - - private EEFGenModel generatedEEFGen(URI modelURI, IFolder modelsFolder) throws IOException { - String eefgenPath = modelsFolder.getFullPath().toString() + "/" + modelURI.trimFileExtension().appendFileExtension("eefgen").lastSegment(); - EEFGenModel eefgenModel = null; - URI eefgenURI = URI.createPlatformResourceURI(eefgenPath, true); - EObject extractedEEFGenModel = EMFHelper.load(eefgenURI, resourceSet); - if (extractedEEFGenModel instanceof EEFGenModel) { - eefgenModel = (EEFGenModel)extractedEEFGenModel; - } - return eefgenModel; - } - - - private IFolder createEEFModelsFolder(IProject editProject, IProgressMonitor monitor) throws CoreException { - IFolder modelsFolder = editProject.getFolder(new Path(modelsFolderPath)); - if (!modelsFolder.exists()) { - modelsFolder.create(true, true, monitor); - editProject.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - ((WorkflowVariable)getEEFModelsFolder()).setValue(modelsFolder); - return modelsFolder; - } - - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFCode.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFCode.java deleted file mode 100644 index b5b3b7fd5..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFCode.java +++ /dev/null @@ -1,121 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.impl; - -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IWorkspace; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.codegen.ecore.generator.Generator; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.util.GenModelUtil; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; - -/** - * @author Goulwen Le Fur - * - */ -public abstract class GenerateEMFCode extends Step { - - /** - * Genmodel to use - */ - private Object genmodel; - - /** - * - */ - private WorkflowVariable genProjectVar; - - /** - * @param resourceSet - */ - public GenerateEMFCode(String name, Object genmodel) { - super(name); - this.genmodel = genmodel; - } - - protected GenModel getGenModel() { - if (genmodel instanceof GenModel) { - return (GenModel) genmodel; - } else if (genmodel instanceof WorkflowVariable && ((WorkflowVariable)genmodel).getValue() instanceof GenModel) { - return (GenModel) ((WorkflowVariable)genmodel).getValue(); - } else { - return null; - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - public IStatus execute(IProgressMonitor monitor) { - try { - if (getGenModel() != null) { - getGenModel().setCanGenerate(true); - generateModelCode(getGenModel()); - valuateGenerationProject(); - return Status.OK_STATUS; - } else { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "Unable to find the generated GenModel."); - } - } catch (Exception e) { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "An error occured during EMF code generation.", e); - } - } - - /** - * - */ - protected abstract void valuateGenerationProject(); - - /** - * @return - */ - public Object genProject() { - if (genProjectVar == null) { - genProjectVar = new WorkflowVariable(genprojectVarName()); - } - return genProjectVar; - } - - /** - * @param genModel - */ - protected void generateModelCode(GenModel genModel) { - Generator generator = GenModelUtil.createGenerator(genModel); - invokeGeneration(genModel, generator); - } - - /** - * @return - */ - protected abstract String genprojectVarName(); - - protected IProject extractProject(String sPath) { - IPath path = new Path(sPath); - IWorkspace workspace = ResourcesPlugin.getWorkspace(); - return workspace.getRoot().getProject(path.segment(0)); - } - - /** - * @param genModel - * @param generator - */ - protected abstract void invokeGeneration(GenModel genModel, Generator generator); - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFEditCode.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFEditCode.java deleted file mode 100644 index b7f42c1cd..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFEditCode.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.impl; - -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.codegen.ecore.CodeGenEcorePlugin; -import org.eclipse.emf.codegen.ecore.generator.Generator; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.generator.GenBaseGeneratorAdapter; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; - -/** - * @author Goulwen Le Fur - * - */ -public class GenerateEMFEditCode extends GenerateEMFCode { - - /** - * @param name - * @param genmodel - */ - public GenerateEMFEditCode(String name, Object genmodel) { - super(name, genmodel); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFCode#invokeGeneration(org.eclipse.emf.codegen.ecore.genmodel.GenModel, org.eclipse.emf.codegen.ecore.generator.Generator) - */ - protected void invokeGeneration(GenModel genModel, Generator generator) { - generator.generate(genModel, GenBaseGeneratorAdapter.EDIT_PROJECT_TYPE, CodeGenEcorePlugin.INSTANCE.getString("_UI_EditProject_name"), BasicMonitor.toMonitor(new NullProgressMonitor())); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFCode#genprojectVarName() - */ - protected String genprojectVarName() { - return "GENERATE_EMF_EDIT_CODE_" + name + "_GEN_PROJECT"; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFCode#valuateGenerationProject() - */ - protected void valuateGenerationProject() { - ((WorkflowVariable)genProject()).setValue(extractProject(getGenModel().getEditProjectDirectory())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFEditorCode.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFEditorCode.java deleted file mode 100644 index 099aa8311..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFEditorCode.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.impl; - -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.codegen.ecore.CodeGenEcorePlugin; -import org.eclipse.emf.codegen.ecore.generator.Generator; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.generator.GenBaseGeneratorAdapter; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; - -/** - * @author Goulwen Le Fur - * - */ -public class GenerateEMFEditorCode extends GenerateEMFCode { - - /** - * @param name - * @param genmodel - */ - public GenerateEMFEditorCode(String name, Object genmodel) { - super(name, genmodel); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFCode#invokeGeneration(org.eclipse.emf.codegen.ecore.genmodel.GenModel, org.eclipse.emf.codegen.ecore.generator.Generator) - */ - protected void invokeGeneration(GenModel genModel, Generator generator) { - generator.generate(genModel, GenBaseGeneratorAdapter.EDITOR_PROJECT_TYPE, CodeGenEcorePlugin.INSTANCE.getString("_UI_EditorProject_name"), BasicMonitor.toMonitor(new NullProgressMonitor())); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFCode#genprojectVarName() - */ - protected String genprojectVarName() { - return "GENERATE_EMF_EDITOR_CODE_" + name + "_GEN_PROJECT"; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFCode#valuateGenerationProject() - */ - protected void valuateGenerationProject() { - ((WorkflowVariable)genProject()).setValue(extractProject(getGenModel().getEditorProjectDirectory())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFModelCode.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFModelCode.java deleted file mode 100644 index dbd5ef92d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/GenerateEMFModelCode.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.impl; - -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.codegen.ecore.CodeGenEcorePlugin; -import org.eclipse.emf.codegen.ecore.generator.Generator; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.ecore.genmodel.generator.GenBaseGeneratorAdapter; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; - -/** - * @author Goulwen Le Fur - * - */ -public class GenerateEMFModelCode extends GenerateEMFCode { - - /** - * @param name - * @param genmodel - */ - public GenerateEMFModelCode(String name, Object genmodel) { - super(name, genmodel); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFCode#genprojectVarName() - */ - protected String genprojectVarName() { - return "GENERATE_EMF_MODEL_CODE_" + name + "_GEN_PROJECT"; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFCode#invokeGeneration(org.eclipse.emf.codegen.ecore.genmodel.GenModel, org.eclipse.emf.codegen.ecore.generator.Generator) - */ - protected void invokeGeneration(GenModel genModel, Generator generator) { - generator.generate(genModel, GenBaseGeneratorAdapter.MODEL_PROJECT_TYPE, CodeGenEcorePlugin.INSTANCE.getString("_UI_ModelProject_name"), BasicMonitor.toMonitor(new NullProgressMonitor())); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.impl.GenerateEMFCode#valuateGenerationProject() - */ - protected void valuateGenerationProject() { - ((WorkflowVariable)genProject()).setValue(extractProject(getGenModel().getModelProjectDirectory())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/InitializeGenModel.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/InitializeGenModel.java deleted file mode 100644 index d3d0807f3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/InitializeGenModel.java +++ /dev/null @@ -1,134 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.impl; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.util.EMFHelper; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.util.GenmodelHelper; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; -import org.eclipse.emf.importer.ModelImporter; - -/** - * @author Goulwen Le Fur - * - */ -public class InitializeGenModel extends Step { - - /** - * GenModel variable - */ - private WorkflowVariable genmodelVar; - - /** - * GenModel variable - */ - private WorkflowVariable genmodelURIVar; - - /** - * GenModel Helper - */ -// private GenmodelHelper helper; - - private IFile modelFile; - - private IContainer targetFolder; - - private String genmodelFileName; - - /** - * @param name of the step - * @param modelURI Ecore model file - * @param targetFolder Folder where to generate the GenModel - */ - public InitializeGenModel(String name, IFile modelFile, IContainer targetFolder, String genmodelFileName) { - super(name); - this.modelFile = modelFile; - this.targetFolder = targetFolder; - this.genmodelFileName = genmodelFileName; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - public IStatus execute(IProgressMonitor monitor) { - try { - BasicMonitor emfMonitor = new BasicMonitor(); - ModelImporter importer = initializeConverter(genmodelFileName, emfMonitor); - initializeGenModel(importer, emfMonitor); - targetFolder.refreshLocal(IResource.DEPTH_INFINITE, monitor); - URI genmodelURI = GenmodelHelper.computeGenmodelURI(targetFolder, genmodelFileName); - ((WorkflowVariable)getGenModelURI()).setValue(genmodelURI); - ((WorkflowVariable)genmodel()).setValue(EMFHelper.load(genmodelURI, resourceSet)); - return Status.OK_STATUS; - } catch (Exception e) { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "An error occured during genmodel initialization", e); - } - } - - - private final String genmodelVarName() { - return "INIT_GENMODEL_" + name + "_GENMODEL"; - } - - private final String genmodelURIVarName() { - return "INIT_GENMODEL_" + name + "_GENMODEL_URI"; - } - - public Object genmodel() { - if (genmodelVar == null) { - genmodelVar = new WorkflowVariable(genmodelVarName()); - getContext().add(genmodelVar); - } - return genmodelVar; - } - - /** - * @return the generated genmodel URI. - */ - public Object getGenModelURI() { - if (genmodelURIVar == null) { - genmodelURIVar = new WorkflowVariable(genmodelURIVarName()); - } - return genmodelURIVar; - } - - private ModelImporter initializeConverter(String genmodelFileName, Monitor monitor) throws Exception { - ModelImporter converter = new org.eclipse.emf.importer.ecore.EcoreImporter(); - converter.setGenModelContainerPath(targetFolder.getFullPath()); - converter.setGenModelFileName(genmodelFileName); - converter.setModelFile(modelFile); - converter.computeEPackages(monitor); - converter.adjustEPackages(monitor); - return converter; - } - - protected void initializeGenModel(ModelImporter importer, Monitor monitor) throws Exception { - importer.prepareGenModelAndEPackages(monitor); - configureGenModel(importer.getGenModel()); - importer.saveGenModelAndEPackages(monitor); - } - - - protected void configureGenModel(GenModel genModel) { } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/MergePluginXML.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/MergePluginXML.java deleted file mode 100644 index cac5c7a85..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/impl/MergePluginXML.java +++ /dev/null @@ -1,108 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.impl; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.IResourceVisitor; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.util.ExtensionHelper; -import org.eclipse.emf.eef.codegen.flow.Step; -import org.eclipse.emf.eef.codegen.flow.var.WorkflowVariable; -import org.w3c.dom.Node; - -/** - * @author Goulwen Le Fur - * - */ -public class MergePluginXML extends Step { - - private Object editGenProject; - - /** - * @param name of the step - */ - public MergePluginXML(String name, Object editGenProject) { - super(name); - this.editGenProject = editGenProject; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.codegen.flow.Step#execute(org.eclipse.core.runtime.IProgressMonitor) - */ - public IStatus execute(IProgressMonitor monitor) { - try { - IProject editProject = getEditGenProject(); - editProject.refreshLocal(IResource.DEPTH_INFINITE, monitor); - PluginXMLSearcher searcher = new PluginXMLSearcher(); - editProject.accept(searcher); - ExtensionHelper actualHelper = new ExtensionHelper(editProject); - for (IFile next : searcher.filesToMerge) { - ExtensionHelper predictiveHelper = new ExtensionHelper(next); - List diff = actualHelper.diff(predictiveHelper); - actualHelper.append(diff); - } - return Status.OK_STATUS; - } catch (Exception e) { - return new Status(IStatus.ERROR, EEFCodegenPlugin.PLUGIN_ID, "An error occured during workspace analysis.", e); - } - } - - /** - * @return - */ - private IProject getEditGenProject() { - if (editGenProject instanceof IProject) { - return (IProject) editGenProject; - } else if (editGenProject instanceof WorkflowVariable) { - return (IProject) ((WorkflowVariable)editGenProject).getValue(); - } else { - return null; - } - } - - private class PluginXMLSearcher implements IResourceVisitor { - - private List filesToMerge; - - /** - * - */ - public PluginXMLSearcher() { - filesToMerge = new ArrayList(); - } - - /** - * {@inheritDoc} - * @see org.eclipse.core.resources.IResourceVisitor#visit(org.eclipse.core.resources.IResource) - */ - public boolean visit(IResource resource) throws CoreException { - if (resource instanceof IFile) { - IFile file = (IFile) resource; - if (file.getName().matches(".*\\.plugin\\.xml")) { - filesToMerge.add(file); - } - } - return true; - } - - } -} - diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/util/GenmodelHelper.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/util/GenmodelHelper.java deleted file mode 100644 index 3936453a1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/flow/util/GenmodelHelper.java +++ /dev/null @@ -1,238 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.flow.util; - -import java.io.IOException; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.codegen.core.util.EMFHelper; - -/** - * @author Goulwen Le Fur - * - */ -public class GenmodelHelper { - - private static final String EDITOR_SUFFIX = "editor"; - private static final String PLATFORM_RESOURCE_SCHEME = "platform:/resource"; - private static final String GENMODEL_EXTENSION = "genmodel"; - private static final String EEF_MODELS_PATH = "models"; - private static final String COMPONENTS_FILE_EXTENSION = "components"; - private static final String EEFGEN_FILE_EXTENSION = "eefgen"; - - private IFile ecoreModel; - private IContainer targetFolder; - private ResourceSet resourceSet; - private URI ecoreModelURI; - private GenModel genmodel; - private URI genmodelURI; - - /** - * @param ecoreModel - * @param targetFolder - */ - public GenmodelHelper(ResourceSet resourceSet, IFile ecoreModel, IContainer targetFolder) { - this.ecoreModel = ecoreModel; - this.targetFolder = targetFolder; - this.resourceSet = resourceSet; - } - - /** - * @return the targetFolder - */ - public IContainer getTargetFolder() { - return targetFolder; - } - - /** - * @return the ecoreModel - */ - public IFile getEcoreModel() { - return ecoreModel; - } - - /** - * @return the ecoremodelURI - */ - public URI ecoreModelURI() { - return computeEcoreModelURI(); - } - - /** - * @return the IFile containing the GenModel - */ - public IFile getGenModelFile() { - return targetFolder.getFile(new Path(genmodelFileName())); - } - - /** - * @return the generated genmodel URI. - */ - public URI genmodelURI() { - if (genmodelURI == null) { - genmodelURI = GenmodelHelper.computeGenmodelURI(targetFolder, genmodelFileName()); - } - return genmodelURI; - } - - /** - * @return the genmodel - */ - public GenModel getGenModel() { - if (genmodel == null) { - genmodel = loadGenmodel(); - } - return genmodel; - } - - /** - * @return the EEF models {@link IFolder} - */ - public IFolder getEEFModelsFolder() { - IProject editProject = targetFolder.getWorkspace().getRoot().getProject(getGenModel().getEditPluginID()); - IFolder modelsFolder = editProject.getFolder(new Path(eefmodelsFolderPath())); - return modelsFolder; - } - - /** - * @return folder path for the EEF models - */ - public String eefmodelsFolderPath() { - return EEF_MODELS_PATH; - } - - /** - * @return components file for EEF properties - */ - public IFile getEEFPropertiesComponentsModel() { - return getEEFModelsFolder().getFile(new Path(genmodelURI().trimFileExtension().appendFileExtension(COMPONENTS_FILE_EXTENSION).lastSegment())); - } - - /** - * @return components file for EEF properties - */ - public IFile getEEFPropertiesEEFGenModel() { - return getEEFModelsFolder().getFile(new Path(genmodelURI().trimFileExtension().appendFileExtension(EEFGEN_FILE_EXTENSION).lastSegment())); - } - - /** - * @return components file for EEF Editor - */ - public IFile getEEFEditorComponentsModel() { - return getEEFModelsFolder().getFile(new Path(genmodelURI().trimFileExtension().lastSegment() + "-" + EDITOR_SUFFIX + "." + COMPONENTS_FILE_EXTENSION)); - } - - /** - * @return components file for EEF Editor - */ - public IFile getEEFEditorEEFGenModel() { - return getEEFModelsFolder().getFile(new Path(genmodelURI().trimFileExtension().lastSegment() + "-" + EDITOR_SUFFIX + "." + EEFGEN_FILE_EXTENSION)); - } - - /** - * @return the Source folder of the EMF model plugin if genmodel found. null otherwise. - */ - public IFolder getEMFModelSrcFolder() { - if (getGenModel() != null) { - return targetFolder.getWorkspace().getRoot().getFolder(new Path(getGenModel().getModelDirectory())); - } - return null; - } - - /** - * @return the Source folder of the EMF edit plugin if genmodel found. null otherwise. - */ - public IFolder getEMFEditSrcFolder() { - if (getGenModel() != null) { - return targetFolder.getWorkspace().getRoot().getFolder(new Path(getGenModel().getEditDirectory())); - } - return null; - } - - /** - * @return the Source folder of the EMF editor plugin if genmodel found. null otherwise. - */ - public IFolder getEMFEditorSrcFolder() { - if (getGenModel() != null) { - return targetFolder.getWorkspace().getRoot().getFolder(new Path(getGenModel().getEditorDirectory())); - } - return null; - } - - /** - * Compute the Ecore Model URI for the given ecore file - * @param ecoreModel the ecore file - * @return the ecore model URI - */ - private URI computeEcoreModelURI() { - if (ecoreModelURI == null) { - ecoreModelURI = URI.createURI(PLATFORM_RESOURCE_SCHEME + ecoreModel.getFullPath()); - } - return ecoreModelURI; - } - - /** - * Compute the GenModel URI for the given ecore modelURI - * @param ecoreModelURI - * @return - */ - public static URI computeGenmodelURI(IContainer targetFolder, String genmodelFileName) { - return URI.createPlatformResourceURI(targetFolder.getFullPath() + "/" + genmodelFileName, true); - } - - /** - * @param modelURI - * @return - */ - public String genmodelFileName() { - return ecoreModelURI().trimFileExtension().appendFileExtension(GENMODEL_EXTENSION).lastSegment(); - } - - /** - * @return the created genmodel - */ - private GenModel loadGenmodel() { - try { - URI genmodelURI = genmodelURI(); - EObject model = EMFHelper.load(genmodelURI, resourceSet); - if (model instanceof GenModel) { - return (GenModel) model; - } - } catch (IOException e) { - // Silent catch - } - return null; - } - - public static URI computePropertiesComponentsModelURI(IContainer targetFolder, URI genmodelURI) { - return URI.createPlatformResourceURI(targetFolder.getFullPath() + "/" + genmodelURI.trimFileExtension().appendFileExtension(COMPONENTS_FILE_EXTENSION).lastSegment(), false); - } - - public static URI computePropertiesEEFGenModelURI(IContainer targetFolder, URI genmodelURI) { - return URI.createPlatformResourceURI(targetFolder.getFullPath() + "/" + genmodelURI.trimFileExtension().appendFileExtension(EEFGEN_FILE_EXTENSION).lastSegment(), false); - } - - public static URI computeEditorComponentsModelURI(IContainer targetFolder, URI genmodelURI) { - return URI.createPlatformResourceURI(targetFolder.getFullPath() + "/" + genmodelURI.trimFileExtension().lastSegment() + "-" + EDITOR_SUFFIX + "." + COMPONENTS_FILE_EXTENSION, false); - } - - public static URI computeEditorEEFGenModelURI(IContainer targetFolder, URI genmodelURI) { - return URI.createPlatformResourceURI(targetFolder.getFullPath() + "/" + genmodelURI.trimFileExtension().lastSegment() + "-" + EDITOR_SUFFIX + "." + EEFGEN_FILE_EXTENSION, false); - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/actions/AbstractGenerateEEFAction.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/actions/AbstractGenerateEEFAction.java deleted file mode 100644 index dbf85233c..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/actions/AbstractGenerateEEFAction.java +++ /dev/null @@ -1,174 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ui.generators.actions; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.core.runtime.jobs.Job; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.ui.generators.common.GenerateAll; -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.ui.IActionDelegate; -import org.eclipse.ui.IObjectActionDelegate; -import org.eclipse.ui.IWorkbenchPart; - -/** - * @author Goulwen Le Fur - */ -public abstract class AbstractGenerateEEFAction extends Action implements IObjectActionDelegate { - - protected List selectedFiles; - - /** - * the list of eefgenmodels - * @deprecated since a job is used to generates files - */ - protected List eefGenModels; - - /** - * Constructor. - */ - public AbstractGenerateEEFAction() { - selectedFiles = new ArrayList(); - } - - /** - * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart) - * @deprecated see bug #370409 - */ - public void setActivePart(IAction action, IWorkbenchPart targetPart) { - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.IActionDelegate#run(org.eclipse.jface.action.IAction) - */ - public void run(IAction action) { - run(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.action.Action#run() - */ - public void run() { - if (selectedFiles != null) { - - Job generationJob = new Job("EEF architecture generation") { - @Override - protected IStatus run(IProgressMonitor monitor) { - try { - List eefgenmodels = initEEFGenModel(); - if (eefgenmodels != null && !monitor.isCanceled()) { - monitor.beginTask("Generating EEF Architecture", IProgressMonitor.UNKNOWN); - for (final EEFGenModel eefGenModel : eefgenmodels) { - final IContainer target = getGenContainer(eefGenModel); - if (target != null) { - monitor.subTask("Generating " - + eefGenModel.eResource().getURI().lastSegment() - + " Architecture"); - int count = 2; - if (eefGenModel.getEditionContexts() != null) - count += eefGenModel.getEditionContexts().size() * 11; - if (eefGenModel.getViewsRepositories() != null) - count += eefGenModel.getViewsRepositories().size() * 5; - final GenerateAll generator = new GenerateAll(target, eefGenModel); - generator.doGenerate(monitor); - for (Iterator iterator = generator.getGenerationTargets() - .iterator(); iterator.hasNext();) { - IContainer nextContainer = iterator.next(); - nextContainer.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - monitor.worked(count); - } - // check monitor state - if (monitor.isCanceled()) { - break; - } - } - } - } catch (IOException e) { - EEFCodegenPlugin.getDefault().logError(e); - return Status.CANCEL_STATUS; - } catch (CoreException e) { - EEFCodegenPlugin.getDefault().logError(e); - return Status.CANCEL_STATUS; - } finally { - monitor.done(); - selectedFiles.clear(); - } - return Status.OK_STATUS; - } - }; - generationJob.setUser(true); - // lock the workspace to avoid concurrent modification - generationJob.setRule(ResourcesPlugin.getWorkspace().getRoot()); - generationJob.schedule(); - } - } - - /** - * @see IActionDelegate#selectionChanged(IAction, ISelection) - */ - public void selectionChanged(IAction action, ISelection selection) { - selectedFiles.clear(); - if (selection instanceof StructuredSelection) { - StructuredSelection sSelection = (StructuredSelection)selection; - for (Object selectedElement : sSelection.toList()) { - if (selectedElement instanceof IFile) { - this.selectedFiles.add((IFile)selectedElement); - } - } - - } - } - - protected abstract List initEEFGenModel() throws IOException; - - /** - * Returns the container that the EEFGenModel use as generation directory - * - * @param eefGenModel - * the eefGenModel - * @return the generation directory - * @throws IOException - * an error occurred during container creation - */ - public IContainer getGenContainer(EEFGenModel eefGenModel) throws IOException { - if (eefGenModel != null) { - if (eefGenModel.getGenDirectory() != null) { - final IContainer target = (IContainer)ResourcesPlugin.getWorkspace().getRoot() - .getFolder(new Path(eefGenModel.getGenDirectory())); - return target; - } - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/actions/GenerateEEFAction.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/actions/GenerateEEFAction.java deleted file mode 100755 index ca4bfe5ce..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/actions/GenerateEEFAction.java +++ /dev/null @@ -1,157 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ui.generators.actions; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenModelReference; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; - -/** - * @author Goulwen Le Fur - */ -public class GenerateEEFAction extends AbstractGenerateEEFAction { - - /** - * Constructor for Action1. - */ - public GenerateEEFAction() { - super(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.codegen.ui.generators.actions.AbstractGenerateEEFAction#initEEFGenModel() - */ - protected List initEEFGenModel() throws IOException { - List eefgenmodels = new ArrayList(selectedFiles.size()); - if (!selectedFiles.isEmpty()) { - for (IFile selectedFile : selectedFiles) { - ResourceSet resourceSet = new ResourceSetImpl(); - URI modelURI = URI.createPlatformResourceURI(selectedFile.getFullPath().toString(), true); - String fileExtension = modelURI.fileExtension(); - if (fileExtension == null || fileExtension.length() == 0) { - fileExtension = Resource.Factory.Registry.DEFAULT_EXTENSION; - } - final Resource.Factory.Registry registry = Resource.Factory.Registry.INSTANCE; - final Object resourceFactory = registry.getExtensionToFactoryMap().get(fileExtension); - if (resourceFactory != null) { - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap() - .put(fileExtension, resourceFactory); - } else { - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap() - .put(fileExtension, new XMIResourceFactoryImpl()); - } - Resource res = resourceSet.createResource(modelURI); - res.load(Collections.EMPTY_MAP); - EcoreUtil.resolveAll(resourceSet); - if (res.getContents().size() > 0) { - EObject object = res.getContents().get(0); - if (object instanceof EEFGenModel) { - eefgenmodels.add((EEFGenModel)object); - } - } - } - } - // validate eefgenmodels and components recursively - return validateEEFGenmodels(eefgenmodels); - } - - /** - * @param eefgenmodels - * @return - * @since 2.0 - */ - private List validateEEFGenmodels(List eefgenmodels) { - List eefModels = new ArrayList(eefgenmodels.size()); - eefModels.addAll(eefgenmodels); - for (EEFGenModel eefGenModel : eefgenmodels) { - if (!validateOneEEFGenModel(eefGenModel)) - eefModels.remove(eefGenModel); - // validate also referenced EEFGenModels - if (!validateReferencedEEFGenModels(eefGenModel)) - eefModels.remove(eefGenModel); - } - return eefModels; - } - - /** - * @param eefGenModel - */ - private boolean validateReferencedEEFGenModels(EEFGenModel eefGenModel) { - for (EEFGenModelReference eefGenModelReference : eefGenModel.getReferences()) { - EEFGenModel referencedEEFGenModel = eefGenModelReference.getReferencedContext(); - if (!validateOneEEFGenModel(referencedEEFGenModel)) - return false; - return validateReferencedEEFGenModels(referencedEEFGenModel); - } - return true; - } - - /** - * @param eefGenModel - * @return - * @since 2.0 - */ - private boolean validateOneEEFGenModel(EEFGenModel eefGenModel) { - // validate eefgenmodels - final Diagnostic diag = Diagnostician.INSTANCE.validate(eefGenModel); - if (diag.getSeverity() != Diagnostic.OK) { - Status status = new Status(diag.getSeverity(), EEFCodegenPlugin.PLUGIN_ID, "EEFGenmodel '" - + eefGenModel.eResource().getURI() + "' contains errors."); - EEFCodegenPlugin.getDefault().getLog().log(status); - return false; - } - // validate PropertiesEditionContext - for (GenEditionContext genEditionContext : eefGenModel.getEditionContexts()) { - final Diagnostic diag2 = Diagnostician.INSTANCE.validate(genEditionContext - .getPropertiesEditionContext()); - if (diag2.getSeverity() != Diagnostic.OK) { - Status status = new Status(diag2.getSeverity(), EEFCodegenPlugin.PLUGIN_ID, - "PropertiesEditionContext '" - + genEditionContext.getPropertiesEditionContext().eResource().getURI() - + "' contains errors."); - EEFCodegenPlugin.getDefault().getLog().log(status); - return false; - } - } - // validate ViewsRepository - for (GenViewsRepository genViewsRepository : eefGenModel.getViewsRepositories()) { - final Diagnostic diag2 = Diagnostician.INSTANCE.validate(genViewsRepository.getViewsRepository()); - if (diag2.getSeverity() != Diagnostic.OK) { - Status status = new Status(diag2.getSeverity(), EEFCodegenPlugin.PLUGIN_ID, - "ViewsRepository '" + genViewsRepository.getViewsRepository().eResource().getURI() - + "' contains errors."); - EEFCodegenPlugin.getDefault().getLog().log(status); - return false; - } - } - return true; - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/callback/EEFGenerationCallback.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/callback/EEFGenerationCallback.java deleted file mode 100644 index 81f93cda4..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/callback/EEFGenerationCallback.java +++ /dev/null @@ -1,31 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ui.generators.callback; - -import java.util.Set; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.runtime.IProgressMonitor; - -/** - * @author Goulwen Le Fur - * - */ -public interface EEFGenerationCallback { - - /** - * Execute the callback. - * @param target list of directory where EEF generates code. - * @param monitor Eclipse ProgressMonitor - */ - void execute(Set target, IProgressMonitor monitor); - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/callback/imports/JDTImportsOrganisationCallback.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/callback/imports/JDTImportsOrganisationCallback.java deleted file mode 100644 index e2433eee9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/callback/imports/JDTImportsOrganisationCallback.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ui.generators.callback.imports; - -import java.util.Set; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.emf.eef.codegen.ui.generators.callback.EEFGenerationCallback; -import org.eclipse.emf.eef.codegen.ui.generators.common.ImportOrganizer; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.swt.widgets.Display; -import org.eclipse.ui.IWorkbenchSite; - -/** - * @author Goulwen Le Fur - * @deprecated will be removed in next major release. EEF does not organize imports anymore after generation - */ -public class JDTImportsOrganisationCallback implements EEFGenerationCallback { - - private IWorkbenchSite site; - - /** - * @param site - * the current workbench site - */ - public JDTImportsOrganisationCallback(IWorkbenchSite site) { - this.site = site; - } - - /** - * {@inheritDoc] - * @see org.eclipse.emf.eef.codegen.ui.generators.callback.EEFGenerationCallback#execute() - */ - public void execute(final Set target, final IProgressMonitor monitor) { - if (EEFUtils.isBundleLoaded(EEFUtils.JDT_CORE_SYMBOLIC_NAME)) { - monitor.beginTask("Organize imports", 1); - Display.getDefault().asyncExec(new Runnable() { - public void run() { - ImportOrganizer.organizeImports(site, target); - } - }); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/GenerateAll.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/GenerateAll.java deleted file mode 100644 index 5ca5ff1f9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/GenerateAll.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ui.generators.common; - -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.HashSet; -import java.util.List; -import java.util.Set; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.SubProgressMonitor; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.launcher.AbstractPropertiesGeneratorLauncher; -import org.eclipse.emf.eef.codegen.core.services.PropertiesGeneratorLaunchersServices; - -/** - * Main entry point of the 'Codegen' generation module. - * - * @author Goulwen Le Fur - */ -public class GenerateAll { - - /** - * The output folder. - */ - private File targetFolder; - - /** - * The Generation PSM - */ - private EEFGenModel eefGenModel; - - /** - * A set containing the target folder for generation - */ - private Set generationTargets; - - /** - * Constructor. - * - * @param modelURI - * is the URI of the model. - * @param targetFolder - * is the output folder - * @throws IOException - * Thrown when the output cannot be saved. - */ - public GenerateAll(IContainer targetFolder, EEFGenModel eefGenModel) { - if (targetFolder.getLocation() != null) { - this.targetFolder = targetFolder.getLocation().toFile(); - } else { - EEFCodegenPlugin.getDefault().logWarning( - new IllegalArgumentException("TargetFolder must specify a correct location")); - } - this.eefGenModel = eefGenModel; - this.generationTargets = new HashSet(); - this.generationTargets.add(targetFolder); - } - - /** - * @return the generationTargets - */ - public Set getGenerationTargets() { - return generationTargets; - } - - /** - * Launches the generation. - * - * @throws IOException - * Thrown when the output cannot be saved. - */ - public void doGenerate(IProgressMonitor monitor) throws IOException { - if (targetFolder == null) { - return; - } - if (!targetFolder.exists()) { - monitor.subTask("Creating target folder"); - targetFolder.mkdirs(); - monitor.worked(1); - } - - List arguments = new ArrayList(); - monitor.subTask("Loading..."); - org.eclipse.emf.eef.codegen.launcher.EEFLauncher launcher = new org.eclipse.emf.eef.codegen.launcher.EEFLauncher( - eefGenModel, targetFolder, arguments); - monitor.worked(1); - monitor.subTask("Generating EEF code using " + eefGenModel.eResource().getURI().lastSegment() + "..."); - launcher.doGenerate(BasicMonitor.toMonitor(new SubProgressMonitor(monitor, IProgressMonitor.UNKNOWN))); - monitor.worked(1); - for (AbstractPropertiesGeneratorLauncher abstractPropertiesGeneratorLauncher : PropertiesGeneratorLaunchersServices - .getInstance().getlaunchers()) { - abstractPropertiesGeneratorLauncher.doGenerate(eefGenModel, targetFolder, monitor); - if (!abstractPropertiesGeneratorLauncher.getTargetContainer().isEmpty()) - generationTargets.addAll(abstractPropertiesGeneratorLauncher.getTargetContainer()); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/GenerationHelper.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/GenerationHelper.java deleted file mode 100644 index 39dd7db05..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/GenerationHelper.java +++ /dev/null @@ -1,94 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ui.generators.common; - -import java.io.IOException; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.ui.generators.callback.EEFGenerationCallback; - -/** - * @author Goulwen Le Fur - * - */ -public class GenerationHelper { - - private List eefGenModels; - private List callbacks; - - /** - * Defaut constructor - * @param eefgen the eefGen to generate - */ - public GenerationHelper(List eefgen, List callbacks) { - super(); - this.eefGenModels = eefgen; - this.callbacks = callbacks; - } - - public void generate(IProgressMonitor monitor) { - try { - if (eefGenModels != null) { - for (final EEFGenModel eefGenModel : eefGenModels) { - final IContainer target = getGenContainer(eefGenModel); - if (target != null) { - int count = 2; - if (eefGenModel.getEditionContexts() != null) - count += eefGenModel.getEditionContexts().size() * 11; - if (eefGenModel.getViewsRepositories() != null) - count += eefGenModel.getViewsRepositories().size() * 5; - monitor.beginTask("Generating EEF Architecture", count); - final GenerateAll generator = new GenerateAll(target, eefGenModel); - generator.doGenerate(monitor); - for (Iterator iterator = generator.getGenerationTargets() - .iterator(); iterator.hasNext();) { - IContainer nextContainer = iterator.next(); - nextContainer.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - monitor.worked(1); - for (EEFGenerationCallback callback : callbacks) { - callback.execute(generator.getGenerationTargets(), monitor); - } - } - } - } - } catch (IOException e) { - EEFCodegenPlugin.getDefault().logError(e); - } catch (CoreException e) { - EEFCodegenPlugin.getDefault().logError(e); - } finally { - monitor.done(); - } - - } - - public IContainer getGenContainer(EEFGenModel eefGenModel) throws IOException { - if (eefGenModel != null) { - if (eefGenModel.getGenDirectory() != null) { - final IContainer target = (IContainer)ResourcesPlugin.getWorkspace().getRoot().getFolder( - new Path(eefGenModel.getGenDirectory())); - return target; - } - } - return null; - } - - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/ImportOrganizer.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/ImportOrganizer.java deleted file mode 100644 index 19e760899..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/generators/common/ImportOrganizer.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ui.generators.common; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; -import java.util.Set; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.jdt.core.ICompilationUnit; -import org.eclipse.jdt.core.IJavaElement; -import org.eclipse.jdt.core.IPackageFragment; -import org.eclipse.jdt.core.IPackageFragmentRoot; -import org.eclipse.jdt.core.JavaCore; -import org.eclipse.jdt.core.JavaModelException; -import org.eclipse.jdt.ui.actions.OrganizeImportsAction; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.ui.IWorkbenchSite; - -/** - * @author Goulwen Le Fur - */ -public class ImportOrganizer { - - public static void organizeImports(IWorkbenchSite site, Set folders) { - List units = new ArrayList(); - for (IContainer container : folders) { - IJavaElement element = JavaCore.create(container); - try { - if (element instanceof IPackageFragmentRoot) { - IJavaElement[] children = ((IPackageFragmentRoot)element).getChildren(); - for (int i = 0; i < children.length; i++) { - IJavaElement javaElement = children[i]; - if (javaElement instanceof IPackageFragment) { - IPackageFragment fragment = (IPackageFragment)javaElement; - units.addAll(Arrays.asList(fragment.getCompilationUnits())); - } - } - } - } catch (JavaModelException e) { - } - } - OrganizeImportsAction organizeImportsAction = new OrganizeImportsAction(site); - organizeImportsAction.run(new StructuredSelection(units)); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/initializer/actions/InitializeEEFModelsAction.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/initializer/actions/InitializeEEFModelsAction.java deleted file mode 100644 index 5ed1df2ec..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/initializer/actions/InitializeEEFModelsAction.java +++ /dev/null @@ -1,99 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ui.initializer.actions; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.codegen.core.initializer.AbstractPropertiesInitializer; -import org.eclipse.emf.eef.codegen.ui.initializer.ui.InitializeEEFModelsDialog; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.IActionDelegate; -import org.eclipse.ui.IObjectActionDelegate; -import org.eclipse.ui.IWorkbenchPart; - -/** - * @author Goulwen Le Fur - */ -public class InitializeEEFModelsAction implements IObjectActionDelegate { - - private Shell shell; - - private URI modelURI; - - private IFile selectedFile = null; - - /** - * Constructor for Action1. - */ - public InitializeEEFModelsAction() { - super(); - } - - /** - * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart) - */ - public void setActivePart(IAction action, IWorkbenchPart targetPart) { - shell = targetPart.getSite().getShell(); - } - - /** - * @see IActionDelegate#run(IAction) - */ - public void run(IAction action) { - if (selectedFile != null) { - InitializeEEFModelsDialog dialog = new InitializeEEFModelsDialog(shell, selectedFile.getParent(), - false, "Select a destination container for models :"); - dialog.setTitle("Container Selection"); - dialog.open(); - Object[] result = dialog.getResult(); - if (result != null && result.length >= 1) { - try { - IContainer container; - IPath path = (IPath)result[0]; - if (path.segmentCount() == 1) { - container = (IContainer)ResourcesPlugin.getWorkspace().getRoot().getProject(path.toString()); - } else { - container = (IContainer)ResourcesPlugin.getWorkspace().getRoot().getFolder(path); - } - modelURI = URI.createPlatformResourceURI(selectedFile.getFullPath().toString(), false); - AbstractPropertiesInitializer initializer = dialog.getInitializer(); - initializer.initialize(modelURI, container); - container.refreshLocal(IResource.DEPTH_INFINITE, new NullProgressMonitor()); - } catch (Exception e) { - EEFCodegenPlugin.getDefault().logError(e); - } - } - } - } - - /** - * @see IActionDelegate#selectionChanged(IAction, ISelection) - */ - public void selectionChanged(IAction action, ISelection selection) { - if (selection instanceof StructuredSelection) { - StructuredSelection sSelection = (StructuredSelection)selection; - if (sSelection.getFirstElement() instanceof IFile) { - this.selectedFile = (IFile)sSelection.getFirstElement(); - } - - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/initializer/ui/InitializeEEFModelsDialog.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/initializer/ui/InitializeEEFModelsDialog.java deleted file mode 100644 index 01b157450..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/initializer/ui/InitializeEEFModelsDialog.java +++ /dev/null @@ -1,136 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.codegen.ui.initializer.ui; - -import java.util.List; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.emf.eef.codegen.core.initializer.AbstractPropertiesInitializer; -import org.eclipse.emf.eef.codegen.core.services.PropertiesInitializerStrategyServices; -import org.eclipse.jface.viewers.ArrayContentProvider; -import org.eclipse.jface.viewers.ComboViewer; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.LabelProvider; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.dialogs.ContainerSelectionDialog; - -/** - * @author Goulwen Le Fur - */ -public class InitializeEEFModelsDialog extends ContainerSelectionDialog { - - private ComboViewer strategies; - - private Label description; - - private AbstractPropertiesInitializer selectedStrategy; - - public InitializeEEFModelsDialog(Shell parentShell, IContainer initialRoot, - boolean allowNewContainerName, String message) { - super(parentShell, initialRoot, allowNewContainerName, message); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite) - */ - protected Control createDialogArea(Composite parent) { - Composite container = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - container.setLayout(layout); - Group strategyGroup = new Group(container, SWT.NONE); - strategyGroup.setText("Strategy"); - GridData strategyGroupData = new GridData(GridData.FILL_BOTH); - strategyGroup.setLayoutData(strategyGroupData); - GridLayout strategyGroupLayout = new GridLayout(); - strategyGroupLayout.numColumns = 2; - strategyGroup.setLayout(strategyGroupLayout); - Label strategyLabel = new Label(strategyGroup, SWT.NONE); - strategyLabel.setText("Strategy : "); - strategies = new ComboViewer(strategyGroup); - strategies.setContentProvider(new ArrayContentProvider()); - strategies.setLabelProvider(new LabelProvider() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.LabelProvider#getText(java.lang.Object) - */ - public String getText(Object element) { - if (element instanceof AbstractPropertiesInitializer) { - return ((AbstractPropertiesInitializer)element).getName(); - } - return super.getText(element); - } - }); - strategies.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (event.getSelection() instanceof StructuredSelection - && ((StructuredSelection)event.getSelection()).getFirstElement() instanceof AbstractPropertiesInitializer) { - newStrategySelected((AbstractPropertiesInitializer)((StructuredSelection)event - .getSelection()).getFirstElement()); - } - } - - }); - description = new Label(strategyGroup, SWT.NONE); - description.setText("No description entered ..."); - GridData descriptionData = new GridData(); - descriptionData.horizontalSpan = 2; - description.setLayoutData(descriptionData); - Group targetGroup = new Group(container, SWT.NONE); - targetGroup.setText("Target"); - GridData targetGroupData = new GridData(GridData.FILL_BOTH); - targetGroup.setLayoutData(targetGroupData); - GridLayout targetGroupLayout = new GridLayout(); - targetGroup.setLayout(targetGroupLayout); - super.createDialogArea(targetGroup); - initStrategies(); - return container; - } - - public AbstractPropertiesInitializer getInitializer() { - return selectedStrategy; - } - - protected void newStrategySelected(AbstractPropertiesInitializer firstElement) { - description.setText(firstElement.getDescription()); - selectedStrategy = firstElement; - } - - private void initStrategies() { - List strategies2 = PropertiesInitializerStrategyServices.getInstance() - .getStrategies(); - strategies.setInput(strategies2); - if (strategies2.size() > 0) { - strategies.setSelection(new StructuredSelection(strategies2.get(0))); - description.setText(strategies2.get(0).getDescription()); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/validators/actions/PurifyEEFModelsAction.java b/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/validators/actions/PurifyEEFModelsAction.java deleted file mode 100644 index d0d2a6991..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src-custom/org/eclipse/emf/eef/codegen/ui/validators/actions/PurifyEEFModelsAction.java +++ /dev/null @@ -1,222 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.ui.validators.actions; - -import java.io.IOException; -import java.util.Collection; -import java.util.Collections; -import java.util.HashSet; -import java.util.Set; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature.Setting; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.ecore.util.EcoreUtil.CrossReferencer; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceImpl; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; -import org.eclipse.emf.eef.codegen.EEFCodegenPlugin; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.ui.IActionDelegate; -import org.eclipse.ui.IObjectActionDelegate; -import org.eclipse.ui.IWorkbenchPart; - -/** - * @author Goulwen Le Fur - */ -public class PurifyEEFModelsAction implements IObjectActionDelegate { - - private URI modelURI; - - private IFile selectedFile; - - private EEFGenModel eefGenModel; - - /** - * Constructor for Action1. - */ - public PurifyEEFModelsAction() { - super(); - selectedFile = null; - eefGenModel = null; - } - - /** - * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart) - */ - public void setActivePart(IAction action, IWorkbenchPart targetPart) { - } - - /** - * @see IActionDelegate#run(IAction) - */ - public void run(IAction action) { - if (selectedFile != null) { - try { - modelURI = URI.createPlatformResourceURI(selectedFile.getFullPath().toString(), true); - IContainer target = getGenContainer(); - if (target != null) { - int processCount = 0; - Set resourcesToSave = new HashSet(); - eefGenModel = getEEFGenModel(); - if (eefGenModel != null) { - int count = 0; - if (eefGenModel.getEditionContexts() != null) - count += eefGenModel.getEditionContexts().size(); - if (eefGenModel.getViewsRepositories() != null) - count += eefGenModel.getViewsRepositories().size(); - ResourceSet resourceSet = eefGenModel.eResource().getResourceSet(); - EcoreUtil.resolveAll(resourceSet); - CrossReferencer referencer = new CrossReferencer(resourceSet) { - /** - * Serialization ID - */ - private static final long serialVersionUID = -8116181119811335250L; - - { - crossReference(); - } - }; - for (GenViewsRepository genViewsRepository : eefGenModel.getViewsRepositories()) { - TreeIterator allContents = genViewsRepository.getViewsRepository() - .eAllContents(); - while (allContents.hasNext()) { - EObject next = allContents.next(); - if (next instanceof ElementEditor) { - ElementEditor elementEditor = (ElementEditor)next; - Collection references = referencer.get(next); - if (references == null || references.size() == 0) { - if (elementEditor.eContainer().eGet( - elementEditor.eContainingFeature()) instanceof EList) { - processCount++; - EEFCodegenPlugin.getDefault().getLog().log( - new Status(IStatus.WARNING, EEFCodegenPlugin.PLUGIN_ID, - elementEditor.getName() - + " (" - + ((XMIResourceImpl)elementEditor - .eResource()) - .getID(elementEditor) - + ") will be removed")); - resourcesToSave.add(elementEditor.eContainer().eResource()); - ((EList)elementEditor.eContainer().eGet( - elementEditor.eContainingFeature())) - .remove(elementEditor); - } - } - } - } - selectedFile = null; - eefGenModel = null; - } - for (Resource resource : resourcesToSave) { - resource.save(Collections.EMPTY_MAP); - } - EEFCodegenPlugin.getDefault().getLog().log( - new Status(IStatus.OK, EEFCodegenPlugin.PLUGIN_ID, "Purification done. " - + processCount + " element removed.")); - } - } - } catch (IOException e) { - e.printStackTrace(); - } - } - } - - /** - * @see IActionDelegate#selectionChanged(IAction, ISelection) - */ - public void selectionChanged(IAction action, ISelection selection) { - if (selection instanceof StructuredSelection) { - StructuredSelection sSelection = (StructuredSelection)selection; - if (sSelection.getFirstElement() instanceof IFile) { - this.selectedFile = (IFile)sSelection.getFirstElement(); - } - - } - } - - private EEFGenModel getEEFGenModel() throws IOException { - if (eefGenModel != null) - return eefGenModel; - else { - ResourceSet resourceSet = new ResourceSetImpl(); - String fileExtension = modelURI.fileExtension(); - if (fileExtension == null || fileExtension.length() == 0) { - fileExtension = Resource.Factory.Registry.DEFAULT_EXTENSION; - } - final Resource.Factory.Registry registry = Resource.Factory.Registry.INSTANCE; - final Object resourceFactory = registry.getExtensionToFactoryMap().get(fileExtension); - if (resourceFactory != null) { - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(fileExtension, - resourceFactory); - } else { - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(fileExtension, - new XMIResourceFactoryImpl()); - } - Resource res = resourceSet.createResource(modelURI); - res.load(Collections.EMPTY_MAP); - EcoreUtil.resolveAll(resourceSet); - if (res.getContents().size() > 0) { - EObject object = res.getContents().get(0); - if (object instanceof EEFGenModel) { - eefGenModel = (EEFGenModel)object; - if (eefGenModel != null) { - return eefGenModel; - } - } - } - return null; - } - } - - public IContainer getGenContainer() throws IOException { - eefGenModel = getEEFGenModel(); - if (eefGenModel != null) { - if (eefGenModel.getGenDirectory() != null) { - final IContainer target = (IContainer)ResourcesPlugin.getWorkspace().getRoot().getFolder( - new Path(eefGenModel.getGenDirectory())); - return target; - } - } - return null; - } - - class EEFElementEditorReferenceError { - - private ElementEditor element; - - public EEFElementEditorReferenceError(ElementEditor element) { - this.element = element; - } - - public String getErrorMsg() { - return "ElementEditor '" + element.getName() + "' (" - + ((XMIResourceImpl)element.eResource()).getID(element) + ") seems to not be referenced"; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/DynamicPropertiesEditionComponent.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/DynamicPropertiesEditionComponent.mtl deleted file mode 100644 index 3ddc1f3da..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/DynamicPropertiesEditionComponent.mtl +++ /dev/null @@ -1,184 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module DynamicPropertiesEditionComponent('http://www.eclipse.org/emf/eef/components/1.0.0','http://www.eclipse.org/emf/eef/views/1.0.0','http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public DynamicPropertiesEditionComponent(peContext : PropertiesEditionContext, basePackage : String)] -[for (pec : PropertiesEditionComponent | peContext.eAllContents(PropertiesEditionComponent))] - [for (topLevelView : View | pec.views) ? (topLevelView.explicit)] -[if (pec.mustDynamicPecBeGenerated(topLevelView))] -[peContext.initializeImportManager(pec.componentsPackage(), pec.subPECClass(topLevelView))/] -[file (pec.fullFilePath(topLevelView), false)] -[peContext.associatedGenModel().licenceText().trim()/] -package [pec.componentsPackage()/];[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService', - 'org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider'})/] - -[let content : String = peContext.fileContent(pec, topLevelView, basePackage)] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, topLevelView, basePackage)/] - -[content/] -[/let] -[/file] - [/if] - [/for] -[/for] -[/template] - -[template private fileContent(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, topLevelView : View, basePackage : String)] -/** - * [peContext.associatedGenModel().authorText().trim()/] - * [peContext.associatedGenModel().generationMark()/] - */ -public class [pec.subPECClass(topLevelView)/] extends ComposedPropertiesEditionComponent { - - public static String [topLevelView.viewPartConstant(pec)/] = "[topLevelView.viewKey(pec).toASCII()/]"; //$NON-NLS-1$ - - private String['['/][']'/] parts = {[topLevelView.viewPartConstant(pec)/]}; - - /** - * The EObject to edit - * [peContext.associatedGenModel().generationMark()/] - */ - private [pec.pecModelClass()/] [pec.pecModelClass().toJavaIdentifier()/]; - - /** - * The [topLevelView.viewKey(pec)/] part - * [peContext.associatedGenModel().generationMark()/] - */ - private [topLevelView.pepInterface()/] [topLevelView.viewIdentifier(pec)/]; - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent#partsList() - * [peContext.associatedGenModel().generationMark()/] - */ - public String['['/][']'/] partsList() { - return parts; - } - -[comment] -Implemented later ... -[for (view : View | pec.views) ? (pec.mustBeGenerated())] - private [pec.subPECClass(view)/] [pec.subPECClass(view).toLowerFirst()/]; -[/for] -[/comment] -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding->filter(PropertiesEditionComponent)) ? (subPec.mustBeGenerated())] - [for (view : View | subPec.views) ? (view.ancestors()->includes(topLevelView))] - /** - * The [subPec.subPECClass(view)/] sub component - * [peContext.associatedGenModel().generationMark()/] - */ - protected [include(subPec.subPECQualifiedClass(view))/] [subPec.subPECClass(view).toLowerFirst()/]; - - [/for] -[/for] - /** - * Parameterized constructor - * - * @param [pec.pecModelClass().toJavaIdentifier()/] the EObject to edit - * [peContext.associatedGenModel().generationMark()/] - */ - public [pec.subPECClass(topLevelView)/](EObject [pec.pecModelClass().toJavaIdentifier()/], String editing_mode) { - super(editing_mode); - if ([pec.pecModelClass().toJavaIdentifier()/] instanceof [pec.pecModelClass()/]) { -[comment] -Implemented later ... -[for (view : View | pec.views) ? (pec.mustBeGenerated())] - [pec.subPECClass(view).toLowerFirst()/] = new [pec.subPECClass(view)/]([pec.pecModelClass().toJavaIdentifier().trim()/], editing_mode); - addSubComponent([pec.subPECClass(view).toLowerFirst()/]); -[/for] -[/comment] -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding->filter(PropertiesEditionComponent)) ? (subPec.mustBeGenerated())] - [for (view : View | subPec.views) ? (view.ancestors()->includes(topLevelView))] - [subPec.subPECClass(view).toLowerFirst()/] = new [subPec.subPECClass(view)/]([pec.pecModelClass().toJavaIdentifier()/], editing_mode); - addSubComponent([subPec.subPECClass(view).toLowerFirst()/]); - [/for] -[/for] - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * [peContext.associatedGenModel().generationMark()/] - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if ([topLevelView.viewPartConstant(pec)/].equals(key) && [pec.pecModelClass().toJavaIdentifier()/] == null) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider([include(topLevelView.owningViewsRepository().vrQualifiedClass())/].class); - if (provider != null) { - [topLevelView.viewIdentifier(pec)/] = ([topLevelView.pepInterface()/])provider.getPropertiesEditionPart([topLevelView.editorID()/].class, kind, this); - } - return (IPropertiesEditionPart)[topLevelView.viewIdentifier(pec)/]; - } - return new NullCompositePropertiesEditionPart(this); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent#translatePart(java.lang.String) - * [peContext.associatedGenModel().generationMark()/] - */ - public java.lang.Class translatePart(String key) { - if ([topLevelView.viewPartConstant(pec)/].equals(key)) - return [topLevelView.editorID()/].class; - return super.translatePart(key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent#mustBeComposed(java.lang.Object, int) - * [peContext.associatedGenModel().generationMark()/] - */ - public boolean mustBeComposed(Object key, int kind) { - return [for (view : View | pec.dynamicViews(topLevelView)) separator (' || ')]key == [view.editorID()/].class[/for]; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent - * #initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.resource.ResourceSet) - * [peContext.associatedGenModel().generationMark()/] - */ - public void initPart(Object key, int kind, EObject element, ResourceSet allResource) { - if (key == [topLevelView.editorID()/].class) { - ((IPropertiesEditionPart)[topLevelView.viewIdentifier(pec)/]).setContext(element, allResource); -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding->filter(PropertiesEditionComponent)) ? (subPec.mustBeGenerated())] - [for (view : View | subPec.views) ? (view.ancestors()->includes(topLevelView))] - [subPec.subPECClass(view).toLowerFirst()/].setPropertiesEditionPart([view.editorID()/].class, kind, [topLevelView.viewIdentifier(pec)/].get[view.name.toJavaClassifier()/]SubView()); - [subPec.subPECClass(view).toLowerFirst()/].initPart([view.editorID()/].class, kind, element); - [/for] -[/for] - } - } -} -[/template] - -[template public fullFilePath(pec : PropertiesEditionComponent, view : View)] -[pec.subPECQualifiedClass(view).toPath()/].java -[/template] - -[comment overrides this template if additional imports are needed/] -[template public additionalImports (peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, topLevelView : View, basePackage : String)/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/PropertiesEditionComponent.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/PropertiesEditionComponent.mtl deleted file mode 100644 index 6e0cb810d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/PropertiesEditionComponent.mtl +++ /dev/null @@ -1,195 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module PropertiesEditionComponent('http://www.eclipse.org/emf/eef/components/1.0.0','http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public PropertiesEditionComponent(peContext : PropertiesEditionContext, basePackage : String)] -[for (pec : PropertiesEditionComponent | peContext.eAllContents(PropertiesEditionComponent))] -[if (pec.needComposedEditionComponent())] -[peContext.initializeImportManager(pec.componentsPackage(), pec.pecClass())/] -[file (pec.fullFilePath(), false)] -[peContext.associatedGenModel().licenceText().trim()/] -package [pec.componentsPackage()/];[addImports(Sequence{ - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent', - 'org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider', - 'org.eclipse.emf.eef.runtime.context.PropertiesEditingContext', - 'org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart', - 'org.eclipse.emf.ecore.resource.ResourceSet'})/] - -[let content : String = peContext.fileContent(pec, basePackage)] -[if (peContext.associatedGenModel().useJMergeForUserCode)] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, basePackage)/] -[else] -// [protected ('for imports')] - -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, basePackage)/] -// [/protected] -[/if] - -[content/] -[/let] -[/file] -[/if] -[/for] -[/template] - -[template private fileContent(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, basePackage : String) ] -/** - * [peContext.associatedGenModel().authorText().trim()/] - * [peContext.associatedGenModel().generationMark()/] - */ -public class [pec.pecClass()/] extends ComposedPropertiesEditionComponent { - -[for (view : View | pec.views) ? (view.explicit)] - /** - * The [view.viewKey(pec)/] part - * [peContext.associatedGenModel().generationMark()/] - */ - private [include(view.pepQualifiedInterface())/] [view.viewIdentifier(pec)/]; - - /** - * The [pec.subPECClass(view)/] sub component - * [peContext.associatedGenModel().generationMark()/] - */ - protected [include(pec.subPECQualifiedClass(view))/] [pec.subPECClass(view).toLowerFirst()/]; - -[/for] -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding->filter(PropertiesEditionComponent))] -[for (view : View | subPec.views) ? (view.explicit and view.ancestors()->filter(View)->excludesAll(pec.views->asSequence()))] - [if (view.isA1stLevelReferencedView(pec))] - /** - * The [subPec.pecClass()/] sub component - * [peContext.associatedGenModel().generationMark()/] - */ - protected [include(subPec.pecQualifiedClass())/] [subPec.pecClass().toLowerFirst()/]; - - [else] - /** - * The [subPec.subPECClass(view)/] sub component - * [peContext.associatedGenModel().generationMark()/] - */ - protected [include(subPec.subPECQualifiedClass(view))/] [subPec.subPECClass(view).toLowerFirst()/]; - - [/if] -[/for] -[/for] - /** - * Parameterized constructor - * - * @param [pec.pecModelClass().toJavaIdentifier()/] the EObject to edit - * [peContext.associatedGenModel().generationMark()/] - */ - public [pec.pecClass()/](PropertiesEditingContext editingContext, EObject [pec.pecModelClass().toJavaIdentifier()/], String editing_mode) { - super(editingContext, editing_mode); - if ([pec.pecModelClass().toJavaIdentifier()/] instanceof [include(pec.pecModelQualifiedClass())/]) { - PropertiesEditingProvider provider = null; -[for (view : View | pec.views) ? (view.explicit)] - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt([pec.pecModelClass().toJavaIdentifier()/], PropertiesEditingProvider.class); - [pec.subPECClass(view).toLowerFirst()/] = ([pec.subPECClass(view)/])provider.getPropertiesEditingComponent(editingContext, editing_mode, [pec.subPECClass(view)/].[view.viewPartConstant(pec)/], [pec.subPECClass(view)/].class); - addSubComponent([pec.subPECClass(view).toLowerFirst()/]); -[/for] -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding->filter(PropertiesEditionComponent))] - [for (view : View | subPec.views) ? (view.explicit and view.ancestors()->filter(View)->excludesAll(pec.views->asSequence()))] - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt([pec.pecModelClass().toJavaIdentifier()/], PropertiesEditingProvider.class); - [if (view.isA1stLevelReferencedView(pec))] - [subPec.pecClass().toLowerFirst()/] = ([subPec.pecClass()/])provider.getPropertiesEditingComponent(editingContext, editing_mode, [subPec.subPECClass(view)/].[view.viewPartConstant(subPec)/], [subPec.pecClass()/].class); - addSubComponent([subPec.pecClass().toLowerFirst()/]); - [else] - [subPec.pecClass().toLowerFirst()/] = ([subPec.pecClass()/])provider.getPropertiesEditingComponent(editingContext, editing_mode, [subPec.subPECClass(view)/].[view.viewPartConstant(subPec)/], [subPec.pecClass()/].class); - addSubComponent([subPec.subPECClass(view).toLowerFirst()/]); - [/if] - [/for] -[/for] - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * [peContext.associatedGenModel().generationMark()/] - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { -[for (view : View | pec.views) ? (view.explicit)] - if ([pec.subPECClass(view)/].[view.viewPartConstant(pec)/].equals(key)) { - [view.viewIdentifier(pec)/] = ([view.pepInterface()/])[pec.subPECClass(view).toLowerFirst()/].getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)[view.viewIdentifier(pec)/]; - } -[/for] - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * [peContext.associatedGenModel().generationMark()/] - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { -[for (view : View | pec.views) ? (view.explicit)] - if ([view.editorID()/].class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - [view.viewIdentifier(pec)/] = ([view.pepInterface()/])propertiesEditionPart; - } -[/for] - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * [peContext.associatedGenModel().generationMark()/] - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { -[for (view : View | pec.views)] - if (key == [view.editorID()/].class) { - super.initPart(key, kind, element, allResource); - [for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding.oclAsType(PropertiesEditionComponent))] - [for (refView : View | subPec.views->select(explicit))] - [if (view.eAllContents(ViewReference).view->filter(View)->includes(refView))] - [subPec.pecClass().toLowerFirst()/].setPropertiesEditionPart([refView.editorID()/].class, kind, [view.viewIdentifier(pec)/].get[refView.name.toJavaClassifier()/]ReferencedView()); - [subPec.pecClass().toLowerFirst()/].initPart([refView.editorID()/].class, kind, element, allResource); - [/if] - [/for] - [/for] - } -[/for] -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding.oclAsType(PropertiesEditionComponent))] - [for (refView : View | subPec.views->select(explicit))] - if (key == [refView.editorID()/].class) { - super.initPart(key, kind, element, allResource); - [comment what about referenced view resolution in this case ? /] - [/for] - } -[/for] - } -} -[/template] - -[template public fullFilePath(pec : PropertiesEditionComponent)] -[pec.pecQualifiedClass().toPath()/].java -[/template] - -[comment overrides this template if additional imports are needed/] -[template public additionalImports (peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, basePackage : String)/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/SubPropertiesEditionComponent.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/SubPropertiesEditionComponent.mtl deleted file mode 100644 index 6c8e865fb..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/components/SubPropertiesEditionComponent.mtl +++ /dev/null @@ -1,342 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module SubPropertiesEditionComponent('http://www.eclipse.org/emf/eef/components/1.0.0','http://www.eclipse.org/emf/eef/views/1.0.0','http://www.eclipse.org/emf/eef/mapping/1.0.0','http://www.eclipse.org/emf/2002/Ecore','http://www.eclipse.org/emf/eef/mapping/filters/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetControl /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::filters /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public SubPropertiesEditionComponent(peContext : PropertiesEditionContext, basePackage : String)] -[for (pec : PropertiesEditionComponent | peContext.eAllContents(PropertiesEditionComponent))] -[if (pec.mustBeGenerated())] - [for (view : View | pec.views) ? (not view.isDynamicView())] -[peContext.initializeImportManager(pec.componentsPackage(), pec.subPECClass(view))/] -[file (pec.fullFilePath(view, basePackage), false)] -[peContext.associatedGenModel().licenceText().trim()/] -package [pec.componentsPackage()/];[addImports(Sequence{ - 'org.eclipse.emf.common.util.WrappedException', - 'org.eclipse.emf.common.notify.Notification', - 'org.eclipse.emf.common.util.BasicDiagnostic', - 'org.eclipse.emf.common.util.Diagnostic', - 'org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter', - 'org.eclipse.emf.eef.runtime.api.notify.NotificationFilter', - 'org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.context.PropertiesEditingContext', - 'org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil', - 'org.eclipse.emf.ecore.resource.ResourceSet', - 'org.eclipse.emf.ecore.util.EcoreUtil', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.ecore.EStructuralFeature'})/] - -[let content : String = peContext.fileContent(pec, view, basePackage)] -[if (peContext.associatedGenModel().useJMergeForUserCode)] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, view, basePackage)/] -[else] -// [protected ('for imports')] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, view, basePackage)/] - -// [/protected] -[/if] - -[content/] -[/let] -[/file] - [/for] -[/if] -[/for] -[/template] - -[template private fileContent(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View, basePackage : String) ] -/** - * [peContext.associatedGenModel().authorText().trim()/] - * [peContext.associatedGenModel().generationMark().trim()/] - */ -public class [pec.subPECClass(view)/] extends [include(pec.pecQualifiedComponentSuperClass())/] { - - [peContext.associatedGenModel().generationComment()/] - public static String [view.viewPartConstant(pec)/] = "[view.viewKey(pec).toASCII()/]"; //$NON-NLS-1$ - - [for (editionElement : PropertiesEditionElement | pec.involvedEditionElementsInView(view))][editionElement.additionalComponentField(view, pec)/][/for] - [for (editionElement : PropertiesEditionElement | pec.involvedEditionElementsInView(view) -> select(pee : PropertiesEditionElement | pee.canGeneratemodelNavigation()))][addImports(Sequence{'org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFInitializer', 'org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFFilter'})/][editionElement.additionalComponentFieldForModelNavigation(view, pec)/][/for] - /** - * Default constructor - * [peContext.associatedGenModel().generationMark()/] - */ - public [pec.subPECClass(view)/](PropertiesEditingContext editingContext, EObject [pec.pecModelClass().toJavaIdentifier()/], String editing_mode) { - super(editingContext, [pec.pecModelClass().toJavaIdentifier()/], editing_mode); - parts = new String['['/][']'/] { [view.viewPartConstant(pec)/] }; - repositoryKey = [include(view.owningViewsRepository().vrQualifiedClass())/].class; - partKey = [view.editorID()/].class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * [peContext.associatedGenModel().generationMark()/] - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - [initEditorSettings(pec, view)/] - final [include(pec.pecModelQualifiedClass())/] [pec.pecModelClass().toJavaIdentifier()/] = ([pec.pecModelClass()/])elt; - final [include(view.pepQualifiedInterface())/] [view.viewIdentifier(pec)/] = ([view.pepInterface()/])editingPart; - // init values - [if (view.oclIsKindOf(views::CustomView) and not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('for'.concat(view.name).concat(' custom view initialization'))] - - // [/protected] - [else] - [for (pee : PropertiesEditionElement | pec.involvedEditionElementsInView(view))] - [pee.updater(view, pec)/] - [/for] - [/if] - // init filters -[for (pee : PropertiesEditionElement | pec.involvedEditionElementsInView(view))] - [pee.filterUpdater(view, pec)/] -[/for] - // init values for referenced views - [view.updaterForReferencedViews(pec)/] - // init filters for referenced views - [view.filterUpdaterForReferencedViews(pec)/] - } - setInitializing(false); - } - -[for (pee : PropertiesEditionElement | pec.involvedEditionElementsInView(view))] -[pee.javaDeclarationFilter()/] -[/for] -[view.javaDeclarationFilterForReferencedViews(pec)/] -[if (pec.involvedEditionElementsInView(view)->select(pee : PropertiesEditionElement | pee.hasModelNavigation())->notEmpty())] - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent#shouldProcess(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - */ - protected boolean shouldProcess(IPropertiesEditionEvent event) { - [for (pee : PropertiesEditionElement | pec.involvedEditionElementsInView(view)->select(pee : PropertiesEditionElement | pee.hasModelNavigation()))] - if (event.getAffectedEditor() == [pee.views->first().editorID()/]) { - return ([pee.name.toJavaIdentifier()/]Settings.getValue() == null) ? (event.getNewValue() != null) : (![pee.name.toJavaIdentifier()/]Settings.getValue().equals(event.getNewValue())); - } - [/for] - return super.shouldProcess(event); - } -[/if] - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - [for (pee : PropertiesEditionElement | pec.involvedEditionElementsInView(view)->select(pee : PropertiesEditionElement | not pee.hasModelNavigation()))] - if (editorKey == [pee.views->first().editorID()/]) { - return [pee.metamodelGetter()/]; - } - [/for] - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * [peContext.associatedGenModel().generationMark()/] - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - [if (view.oclIsTypeOf(views::CustomView) and not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('for updateSemanticModel body')] - - // [/protected] - [else] - [pec.pecModelClass()/] [pec.pecModelClass().toJavaIdentifier().disambiguation('event')/] = ([pec.pecModelClass()/])semanticObject; - [for (editionElement : PropertiesEditionElement | pec.involvedEditionElementsInView(view)->select(pee : PropertiesEditionElement | pee.model.changeable and not pee.views->first().readOnly))] - if ([editionElement.views->first().editorID()/] == event.getAffectedEditor()) { - [editionElement.declareEObjectUpdater(view, pec)/] - } - [/for] - [/if] - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - [if (view.oclIsTypeOf(views::CustomView) and not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('for updatePart body')] - - // [/protected] - [else] - [view.pepInterface()/] [view.viewIdentifier(pec)/] = ([view.pepInterface()/])editingPart; - [for (editionElement : PropertiesEditionElement | pec.involvedEditionElementsInView(view))] - [editionElement.liveUpdater(view, pec)/] - [/for] - [comment add ViewReference support/] - [view.liveUpdaterForReferencedViews(pec)/] - [/if] - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter['['/][']'/] getNotificationFilters() { -[let allPee : Sequence(PropertiesEditionElement) = view.referencedViews() -> including(view) -> collect(tmp | pec.involvedEditionElementsInView(tmp.oclAsType(View))) -> flatten() ] - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - [for (pee : PropertiesEditionElement | allPee) separator (',\n')] - [pee.metamodelGetter()/][if (pee.canGeneratemodelNavigation())][if (pee.navigation.oclIsKindOf(SmartModelNavigation))],[/if] - [pee.navigation.navigationMetamodelGetter()/][/if][/for] - ); -[/let] - return new NotificationFilter['['/][']'/] {filter,}; - } - -[if (not pec.properties.oclAsType(PropertiesEditionElement).views->includesAll(view.eAllContents(ElementEditor)))] - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#mustBeComposed(java.lang.Object, int) - */ - public boolean mustBeComposed(Object key, int kind) { - [let containers : OrderedSet(views::Container) = view.eAllContents(ElementEditor)->reject(e : ElementEditor | not pec.properties.views->includes(e)).ancestors()->select(e | e.oclIsTypeOf(views::Container))->asOrderedSet()] - return [if (pec.properties.oclAsType(PropertiesEditionElement)->select(pee : PropertiesEditionElement | view.eAllContents(ElementEditor)->includes(pee.views->first()))->size() = 0)]true[else][for (pee : PropertiesEditionElement | pec.properties.oclAsType(PropertiesEditionElement)->select(pee : PropertiesEditionElement | view.eAllContents(ElementEditor)->includes(pee.views->first()))) separator (' || ')]key == [pee.views->first().editorID()/][/for][if (containers->notEmpty())] || [for (cont : views::Container | containers) separator (' || ')]key == [cont.editorID()/].class[/for][/if][/if]; - [/let] - } -[/if][if (pec.properties.oclAsType(PropertiesEditionElement)->select(localPee : PropertiesEditionElement | localPee.model.required)->notEmpty())] - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * [peContext.associatedGenModel().generationMark()/] - */ - public boolean isRequired(Object key, int kind) { - return [for (pee : PropertiesEditionElement | pec.properties.oclAsType(PropertiesEditionElement)->select(f : PropertiesEditionElement | f.model.required)) separator (' || ')]key == [pee.views->first().editorID()/][/for]; - } -[/if] -[if (pec.properties.oclAsType(PropertiesEditionElement)->select(localPee : PropertiesEditionElement | not localPee.helpText().oclIsUndefined() and not (localPee.helpText().trim() = 'null'))->notEmpty())] - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * [peContext.associatedGenModel().generationMark()/] - */ - public String getHelpContent(Object key, int kind) { - [for (pee : PropertiesEditionElement | pec.properties.oclAsType(PropertiesEditionElement)->select(f : PropertiesEditionElement | not f.helpText().oclIsUndefined() and not (f.helpText().trim() = 'null')))] - if (key == [pee.views->first().editorID()/]) - return [pee.helpText().trim()/]; //$NON-NLS-1$ - [/for] - return super.getHelpContent(key, kind); - } -[/if] - -[pec.validateValue(peContext, view)/] - - [for (editionElement : PropertiesEditionElement | pec.involvedEditionElementsInView(view) -> select(pee : PropertiesEditionElement | pee.canGeneratemodelNavigation()))][editionElement.additionalComponentGetterForModelNavigation(view, pec)/][/for] - - [for (editionElement : PropertiesEditionElement | pec.involvedEditionElementsInView(view) -> select(pee : PropertiesEditionElement | pee.canGenerateEditorSettings()))][editionElement.additionalComponentGetterForEditorSettings(view, pec)/][/for] - -} -[/template] - -[template public initEditorSettings (pec : PropertiesEditionComponent, view : View) ] -[let pees : OrderedSet(PropertiesEditionElement) = pec.involvedEditionElementsInView(view)->select(pee : PropertiesEditionElement | pee.hasModelNavigation())] -[if (not pees->isEmpty())] -if (editingPart instanceof CompositePropertiesEditionPart) { -[/if] -[for (pee : PropertiesEditionElement | pees)] - [addImports(Sequence{'org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart'})/]((CompositePropertiesEditionPart) editingPart).getSettings().add([pee.name.toJavaIdentifier()/]Settings); -[/for] -[if (not pees->isEmpty())] -}[/if][/let] -[/template] - -[template public validateValue (pec : PropertiesEditionComponent, peContext : PropertiesEditionContext, view : View) ] - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * [peContext.associatedGenModel().generationMark()/] - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { -[for (editionElement : PropertiesEditionElement | pec.involvedEditionElementsInView(view)) ? (editionElement.model.oclIsTypeOf(EAttribute))] - if ([editionElement.views->first().editorID()/] == event.getAffectedEditor()) { - [if (editionElement.model.many)] - BasicDiagnostic chain = new BasicDiagnostic(); - for ([include('java.util.Iterator')/] iterator = (([include('java.util.List')/])event.getNewValue()).iterator(); iterator.hasNext();) { - chain.add([include('org.eclipse.emf.ecore.util.Diagnostician')/].INSTANCE.validate([editionElement.metamodelGetter()/].getEAttributeType(), iterator.next())); - } - ret = chain; - [else] - Object newValue = event.getNewValue(); - [if (editionElement.model.eType.instanceClassName <> 'String')] - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString([editionElement.metamodelGetter()/].getEAttributeType(), (String)newValue); - } - [/if] - ret = [include('org.eclipse.emf.ecore.util.Diagnostician')/].INSTANCE.validate([editionElement.metamodelGetter()/].getEAttributeType(), newValue); - [/if] - } -[/for] -[comment add ViewReference support/] -[for ( v : View | view.referencedViews())] - [for (editionElement : PropertiesEditionElement | pec.involvedEditionElementsInView(v)) ? (editionElement.model.oclIsTypeOf(EAttribute))] - if ([editionElement.views->first().editorID()/] == event.getAffectedEditor()) { - [if (editionElement.model.many)] - BasicDiagnostic chain = new BasicDiagnostic(); - for ([include('java.util.Iterator')/] iterator = (([include('java.util.List')/])event.getNewValue()).iterator(); iterator.hasNext();) { - chain.add([include('org.eclipse.emf.ecore.util.Diagnostician')/].INSTANCE.validate([editionElement.metamodelGetter()/].getEAttributeType(), iter.next())); - } - ret = chain; - [else] - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString([editionElement.metamodelGetter()/].getEAttributeType(), (String)newValue); - } - ret = [include('org.eclipse.emf.ecore.util.Diagnostician')/].INSTANCE.validate([editionElement.metamodelGetter()/].getEAttributeType(), newValue); - [/if] - } - [/for] -[/for] - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - -[/template] - -[template public fullFilePath(pec : PropertiesEditionComponent, view : View, basePackage : String)] -[pec.subPECQualifiedClass(view).toPath()/].java -[/template] - -[comment overrides this template if additional imports are needed/] -[template public additionalImports (peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View, basePackage : String)/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/launcher/EEFLauncher.java b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/launcher/EEFLauncher.java deleted file mode 100644 index 186cb0ce0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/launcher/EEFLauncher.java +++ /dev/null @@ -1,476 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.launcher; - -import java.io.File; -import java.io.IOException; -import java.net.URL; -import java.util.ArrayList; -import java.util.Enumeration; -import java.util.List; - -import org.eclipse.acceleo.engine.event.IAcceleoTextGenerationListener; -import org.eclipse.acceleo.engine.generation.strategy.IAcceleoGenerationStrategy; -import org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.codegen.ecore.genmodel.GenBase; -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.BasicMonitor; -import org.eclipse.emf.common.util.Monitor; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.osgi.framework.Bundle; - -/** - * Entry point of the 'EEFlauncher' generation module. - * - * @generated - */ -public class EEFLauncher extends AbstractAcceleoGenerator { - /** - * The name of the module. - * - * @generated - */ - public static final String MODULE_FILE_NAME = "/org/eclipse/emf/eef/codegen/launcher/EEFLauncher"; - - /** - * The name of the templates that are to be generated. - * - * @generated - */ - public static final String[] TEMPLATE_NAMES = { "EEFLauncher" }; - - /** - * The list of properties files from the launch parameters (Launch configuration). - * - * @generated - */ - private List propertiesFiles = new ArrayList(); - - /** - * Allows the public constructor to be used. Note that a generator created - * this way cannot be used to launch generations before one of - * {@link #initialize(EObject, File, List)} or - * {@link #initialize(URI, File, List)} is called. - *

- * The main reason for this constructor is to allow clients of this - * generation to call it from another Java file, as it allows for the - * retrieval of {@link #getProperties()} and - * {@link #getGenerationListeners()}. - *

- * - * @generated - */ - public EEFLauncher() { - // Empty implementation - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param modelURI - * URI where the model on which this generator will be used is located. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in three scenarios : the module cannot be found, it cannot be loaded, or - * the model cannot be loaded. - * @generated - */ - public EEFLauncher(URI modelURI, File targetFolder, - List arguments) throws IOException { - initialize(modelURI, targetFolder, arguments); - } - - /** - * This allows clients to instantiates a generator with all required information. - * - * @param model - * We'll iterate over the content of this element to find Objects matching the first parameter - * of the template we need to call. - * @param targetFolder - * This will be used as the output folder for this generation : it will be the base path - * against which all file block URLs will be resolved. - * @param arguments - * If the template which will be called requires more than one argument taken from the model, - * pass them here. - * @throws IOException - * This can be thrown in two scenarios : the module cannot be found, or it cannot be loaded. - * @generated - */ - public EEFLauncher(EObject model, File targetFolder, - List arguments) throws IOException { - initialize(model, targetFolder, arguments); - } - - /** - * FIX the build for Acceleo 3.1.3 - * @see org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator#createTemplateURI(java.lang.String) - */ - @Override - protected URI createTemplateURI(String entry) { - if (EMFPlugin.IS_ECLIPSE_RUNNING) { - Bundle bundle = Platform.getBundle("org.eclipse.emf.eef.codegen"); - Enumeration e = bundle.findEntries("/", "*.emtl", true); - while (e.hasMoreElements()) { - URL anUrl = e.nextElement(); - if (anUrl.toString().endsWith("org/eclipse/emf/eef/codegen/launcher/EEFLauncher.emtl")) { - return URI.createURI("platform:/plugin/org.eclipse.emf.eef.codegen" + anUrl.getPath()); - } - } - } - return super.createTemplateURI(entry); - } - - /** - * This can be used to launch the generation from a standalone application. - * - * @param args - * Arguments of the generation. - * @generated - */ - public static void main(String[] args) { - try { - if (args.length < 2) { - System.out.println("Arguments not valid : {model, folder}."); - } else { - URI modelURI = URI.createFileURI(args[0]); - File folder = new File(args[1]); - - List arguments = new ArrayList(); - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * Add in this list all the arguments used by the starting point of the generation - * If your main template is called on an element of your model and a String, you can - * add in "arguments" this "String" attribute. - */ - - EEFLauncher generator = new EEFLauncher(modelURI, folder, arguments); - - /* - * Add the properties from the launch arguments. - * If you want to programmatically add new properties, add them in "propertiesFiles" - * You can add the absolute path of a properties files, or even a project relative path. - * If you want to add another "protocol" for your properties files, please override - * "getPropertiesLoaderService(AcceleoService)" in order to return a new property loader. - * The behavior of the properties loader service is explained in the Acceleo documentation - * (Help -> Help Contents). - */ - - for (int i = 2; i < args.length; i++) { - generator.addPropertiesFile(args[i]); - } - - generator.doGenerate(new BasicMonitor()); - } - } catch (IOException e) { - e.printStackTrace(); - } - } - - /** - * Launches the generation described by this instance. - * - * @param monitor - * This will be used to display progress information to the user. - * @throws IOException - * This will be thrown if any of the output files cannot be saved to disk. - * @generated - */ - @Override - public void doGenerate(Monitor monitor) throws IOException { - /* - * TODO if you wish to change the generation as a whole, override this. The default behavior should - * be sufficient in most cases. If you want to change the content of this method, do NOT forget to - * change the "@generated" tag in the Javadoc of this method to "@generated NOT". Without this new tag, - * any compilation of the Acceleo module with the main template that has caused the creation of this - * class will revert your modifications. If you encounter a problem with an unresolved proxy during the - * generation, you can remove the comments in the following instructions to check for problems. Please - * note that those instructions may have a significant impact on the performances. - */ - - //org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(model); - - /* - * If you want to check for potential errors in your models before the launch of the generation, you - * use the code below. - */ - - //if (model != null && model.eResource() != null) { - // List errors = model.eResource().getErrors(); - // for (org.eclipse.emf.ecore.resource.Resource.Diagnostic diagnostic : errors) { - // System.err.println(diagnostic.toString()); - // } - //} - - super.doGenerate(monitor); - } - - - - @Override - public EObject getModel() { - EObject eObject = super.getModel(); - if (eObject instanceof EEFGenModel) { - ResourceSet resourceSet = null; - for (GenEditionContext context : ((EEFGenModel) eObject).getEditionContexts()) { - PropertiesEditionContext propertiesEditionContext = context.getPropertiesEditionContext(); - if (propertiesEditionContext != null) { - resourceSet = propertiesEditionContext.getModel().eResource().getResourceSet(); - Resource resource = resourceSet.getResource(URI.createPlatformPluginURI("org.eclipse.emf.ecore/model/XMLType.genmodel", true), true); - if (!resource.getContents().isEmpty() && resource.getContents().get(0) instanceof GenModel) { - ((GenModel) resource.getContents().get(0)).reconcile(); - }; - propertiesEditionContext.getModel().reconcile(); - } - } - // reconcile all genmodels of the resourceSet - if (resourceSet != null) { - for (Resource resource : resourceSet.getResources()) { - if (!resource.getContents().isEmpty() && resource.getContents().get(0) instanceof GenModel) { - ((GenModel) resource.getContents().get(0)).reconcile(); - }; - } - } - } - // load - return eObject; - } - - /** - * If this generator needs to listen to text generation events, listeners can be returned from here. - * - * @return List of listeners that are to be notified when text is generated through this launch. - * @generated - */ - @Override - public List getGenerationListeners() { - List listeners = super.getGenerationListeners(); - /* - * TODO if you need to listen to generation event, add listeners to the list here. If you want to change - * the content of this method, do NOT forget to change the "@generated" tag in the Javadoc of this method - * to "@generated NOT". Without this new tag, any compilation of the Acceleo module with the main template - * that has caused the creation of this class will revert your modifications. - */ - return listeners; - } - - /** - * If you need to change the way files are generated, this is your entry point. - *

- * The default is {@link org.eclipse.acceleo.engine.generation.strategy.DefaultStrategy}; it generates - * files on the fly. If you only need to preview the results, return a new - * {@link org.eclipse.acceleo.engine.generation.strategy.PreviewStrategy}. Both of these aren't aware of - * the running Eclipse and can be used standalone. - *

- *

- * If you need the file generation to be aware of the workspace (A typical example is when you wanna - * override files that are under clear case or any other VCS that could forbid the overriding), then - * return a new {@link org.eclipse.acceleo.engine.generation.strategy.WorkspaceAwareStrategy}. - * Note, however, that this cannot be used standalone. - *

- *

- * All three of these default strategies support merging through JMerge. - *

- * - * @return The generation strategy that is to be used for generations launched through this launcher. - * @generated - */ - @Override - public IAcceleoGenerationStrategy getGenerationStrategy() { - return super.getGenerationStrategy(); - } - - /** - * This will be called in order to find and load the module that will be launched through this launcher. - * We expect this name not to contain file extension, and the module to be located beside the launcher. - * - * @return The name of the module that is to be launched. - * @generated - */ - @Override - public String getModuleName() { - return MODULE_FILE_NAME; - } - - /** - * If the module(s) called by this launcher require properties files, return their qualified path from - * here.Take note that the first added properties files will take precedence over subsequent ones if they - * contain conflicting keys. - *

- * Properties need to be in source folders, the path that we expect to get as a result of this call are of - * the form <package>.<properties file name without extension>. For example, if you have a file - * named "messages.properties" in package "org.eclipse.acceleo.sample", the path that needs be returned by - * a call to {@link #getProperties()} is "org.eclipse.acceleo.sample.messages". - *

- * - * @return The list of properties file we need to add to the generation context. - * @see java.util.ResourceBundle#getBundle(String) - * @generated - */ - @Override - public List getProperties() { - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO if your generation module requires access to properties files, add their qualified path to the list here. - * - * Properties files can be located in an Eclipse plug-in or in the file system (all Acceleo projects are Eclipse - * plug-in). In order to use properties files located in an Eclipse plugin, you need to add the path of the properties - * files to the "propertiesFiles" list: - * - * final String prefix = "platform:/plugin/"; - * final String pluginName = "org.eclipse.acceleo.module.sample"; - * final String packagePath = "/org/eclipse/acceleo/module/sample/properties/"; - * final String fileName = "default.properties"; - * propertiesFiles.add(prefix + pluginName + packagePath + fileName); - * - * With this mechanism, you can load properties files from your plugin or from another plugin. - * - * You may want to load properties files from the file system, for that you need to add the absolute path of the file: - * - * propertiesFiles.add("C:\Users\MyName\MyFile.properties"); - * - * If you want to let your users add properties files located in the same folder as the model: - * - * if (EMFPlugin.IS_ECLIPSE_RUNNING && model != null && model.eResource() != null) { - * propertiesFiles.addAll(AcceleoEngineUtils.getPropertiesFilesNearModel(model.eResource())); - * } - * - * To learn more about Properties Files, have a look at the Acceleo documentation (Help -> Help Contents). - */ - return propertiesFiles; - } - - /** - * Adds a properties file in the list of properties files. - * - * @param propertiesFile - * The properties file to add. - * @generated - * @since 3.1 - */ - @Override - public void addPropertiesFile(String propertiesFile) { - this.propertiesFiles.add(propertiesFile); - } - - /** - * This will be used to get the list of templates that are to be launched by this launcher. - * - * @return The list of templates to call on the module {@link #getModuleName()}. - * @generated - */ - @Override - public String[] getTemplateNames() { - return TEMPLATE_NAMES; - } - - /** - * This can be used to update the resource set's package registry with all needed EPackages. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerPackages(ResourceSet resourceSet) { - super.registerPackages(resourceSet); - if (!isInWorkspace(org.eclipse.emf.ecore.EcorePackage.class)) { - resourceSet.getPackageRegistry().put(org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), org.eclipse.emf.ecore.EcorePackage.eINSTANCE); - } - - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * If you need additional package registrations, you can register them here. The following line - * (in comment) is an example of the package registration for UML. - * - * You can use the method "isInWorkspace(Class c)" to check if the package that you are about to - * register is in the workspace. - * - * To register a package properly, please follow the following conventions: - * - * If the package is located in another plug-in, already installed in Eclipse. The following content should - * have been generated at the beginning of this method. Do not register the package using this mechanism if - * the metamodel is located in the workspace. - * - * if (!isInWorkspace(UMLPackage.class)) { - * // The normal package registration if your metamodel is in a plugin. - * resourceSet.getPackageRegistry().put(UMLPackage.eNS_URI, UMLPackage.eINSTANCE); - * } - * - * If the package is located in another project in your workspace, the plugin containing the package has not - * been register by EMF and Acceleo should register it automatically. If you want to use the generator in - * stand alone, the regular registration (seen a couple lines before) is needed. - * - * To learn more about Package Registration, have a look at the Acceleo documentation (Help -> Help Contents). - */ - } - - /** - * This can be used to update the resource set's resource factory registry with all needed factories. - * - * @param resourceSet - * The resource set which registry has to be updated. - * @generated - */ - @Override - public void registerResourceFactories(ResourceSet resourceSet) { - super.registerResourceFactories(resourceSet); - /* - * If you want to change the content of this method, do NOT forget to change the "@generated" - * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation - * of the Acceleo module with the main template that has caused the creation of this class will - * revert your modifications. - */ - - /* - * TODO If you need additional resource factories registrations, you can register them here. the following line - * (in comment) is an example of the resource factory registration for UML. - * - * If you want to use the generator in stand alone, the resource factory registration will be required. - * - * To learn more about the registration of Resource Factories, have a look at the Acceleo documentation (Help -> Help Contents). - */ - - // resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE); - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/launcher/EEFLauncher.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/launcher/EEFLauncher.mtl deleted file mode 100644 index 88dd32b35..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/launcher/EEFLauncher.mtl +++ /dev/null @@ -1,68 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module EEFLauncher('http://www.eclipse.org/emf/eef/components/1.0.0','http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::components::PropertiesEditionComponent /] -[import org::eclipse::emf::eef::codegen::components::DynamicPropertiesEditionComponent /] -[import org::eclipse::emf::eef::codegen::components::SubPropertiesEditionComponent /] -[import org::eclipse::emf::eef::codegen::providers::ContextMessages /] -[import org::eclipse::emf::eef::codegen::providers::ContextMessagesProperties /] -[import org::eclipse::emf::eef::codegen::providers::ContextMessagesPropertiesFR /] -[import org::eclipse::emf::eef::codegen::providers::PackagePropertiesEditionProvider /] -[import org::eclipse::emf::eef::codegen::providers::PropertiesEditionProvider /] -[import org::eclipse::emf::eef::codegen::providers::PackagePropertiesEditionPartProvider /] -[import org::eclipse::emf::eef::codegen::parts::ViewsRepository /] -[import org::eclipse::emf::eef::codegen::parts::IPropertiesEditionPart /] -[import org::eclipse::emf::eef::codegen::parts::PropertiesEditionPart /] -[import org::eclipse::emf::eef::codegen::parts::FormPropertiesEditionPart /] -[import org::eclipse::emf::eef::codegen::plugin::plugin_xml /] - -[template public EEFLauncher(genModel : EEFGenModel)] -[comment @main /] -[for (editionContext : GenEditionContext | genModel.editionContexts)] - [let peContext : PropertiesEditionContext = editionContext.PropertiesEditionContext] - [let basePackage : String = editionContext.basePackage] - - [SubPropertiesEditionComponent(peContext, basePackage)/] - - [PropertiesEditionComponent(peContext, basePackage)/] - [DynamicPropertiesEditionComponent(peContext, basePackage)/] - [PropertiesEditionProvider(peContext, basePackage)/] - - [if (editionContext.descriptorsGenericPropertiesViews)] - [plugin_xml(peContext, basePackage)/] - [/if] - - [PropertiesEditionPart(peContext, basePackage)/] - [FormPropertiesEdionPart(peContext, basePackage)/] - - [PackagePropertiesEditionProvider(peContext, peContext.model.ecorePackage)/] - - [comment][GMF_Plugin_xml(peContext, basePackage)/][/comment] - [comment][PropertySection(peContext, basePackage)/][/comment] - - [/let] - [/let] -[/for] - -[for (genViewsRepository : GenViewsRepository | genModel.viewsRepositories)] - [let viewsRepository : ViewsRepository = genViewsRepository.viewsRepository] - [IPropertiesEditionPart(viewsRepository)/] - [ViewsRepository(viewsRepository)/] - [ContextMessages(viewsRepository)/] - [ContextMessagesProperties(viewsRepository)/] - [ContextMessagesPropertiesFR(viewsRepository)/] - [PackagePropertiesEditionPartProvider(viewsRepository)/] - [/let] -[/for] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/FormPropertiesEditionPart.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/FormPropertiesEditionPart.mtl deleted file mode 100644 index 7087685df..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/FormPropertiesEditionPart.mtl +++ /dev/null @@ -1,371 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module FormPropertiesEditionPart('http://www.eclipse.org/emf/eef/components/1.0.0','http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public FormPropertiesEdionPart(peContext : PropertiesEditionContext, basePackage : String)] -[for (inputPEC : PropertiesEditionComponent | peContext.eAllContents(PropertiesEditionComponent))] -[for (view : View | inputPEC.involvedViews()) ? (view.oclIsTypeOf(View))][let pec : PropertiesEditionComponent = if (inputPEC.views->includes(view)) - then inputPEC - else inputPEC.referencedBinding.binding->select(views->includes(view))->first().oclAsType(PropertiesEditionComponent) - endif] -[if (view.mustBeGenerated(inputPEC))] -[peContext.ViewPropertiesEditionPartForm(pec, view, basePackage, inputPEC)/] -[/if] -[/let][/for] -[for (view : View | inputPEC.involvedViews()) ? (inputPEC.explicit and view.oclIsTypeOf(CustomView))][let pec : PropertiesEditionComponent = if (inputPEC.views->includes(view)) - then inputPEC - else inputPEC.referencedBinding.binding->select(views->includes(view))->first().oclAsType(PropertiesEditionComponent) - endif] -[peContext.CustomViewPropertiesEditionPartForm(pec, view, basePackage, inputPEC)/] -[/let][/for] -[/for] -[/template] - -[template private ViewPropertiesEditionPartForm(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View, basePackage : String, inputPEC : PropertiesEditionComponent) ] -[peContext.initializeImportManager(view.partsFormPackage(), view.pepFormClass())/] - -[comment]Widget Imports[/comment] -[for (widget : Widget | view.eAllContents(ElementEditor).representation->select(not oclIsUndefined())->asSet())] -[widget.manageImports(pec, view, basePackage)/] -[/for] -[for (widget : Widget | view.eAllContents(views::Container).representation->asSet()) ? (not widget.oclIsUndefined())] -[widget.manageImports(pec, view, basePackage)/] -[/for] -[for (widget : Widget | view.eAllContents(views::Container).representation->asSet()) ? (not widget.oclIsUndefined())] -[widget.manageImports(pec, view, basePackage)/] -[/for] -[comment][for (widget : Widget | view.eAllContents(ViewReference).view.eAllContents(ElementEditor).representation->asSet())] -[widget.manageImports(pec, view, basePackage)/] -[/for][/comment] - -[file (view.fullFilePath(), false)] -[peContext.associatedGenModel().licenceText().trim()/] -package [view.partsFormPackage()/];[addImports(Sequence{ - 'org.eclipse.swt.layout.GridLayout', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.ui.forms.widgets.Form', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.ui.forms.widgets.ScrolledForm', - 'org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart', - 'org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent', - 'org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart', - 'org.eclipse.emf.eef.runtime.ui.parts.PartComposer'})/] - -[let content : String = peContext.fileContent(pec, view, basePackage, inputPEC)] -[if (peContext.associatedGenModel().useJMergeForUserCode)] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, view, basePackage)/] -[else] -// [protected ('for imports')] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, view, basePackage)/] -// [/protected] -[/if] - -[content/] -[/let] -[/file] -[/template] - -[template private fileContent(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View, basePackage : String, inputPEC : PropertiesEditionComponent) ] -/** - * [peContext.associatedGenModel().authorText().trim()/] - * [peContext.associatedGenModel().generationMark()/] - */ -public class [view.pepFormClass()/] extends [include(view.formQualifiedSuperclass())/] implements IFormPropertiesEditionPart, [include(view.pepQualifiedInterface())/] { - -[for (editor : ElementEditor | view.eAllContents(ElementEditor))] -[editor.widgetDeclaration()/] -[/for] -[comment managing ViewReferences/] -[view.widgetDeclarationForViewReference()/] -[comment managing SubViews/] -[view.widgetDeclarationForSubViews()/] - - /** - * For {@link ISection} use only. - */ - public [view.pepFormClass()/]() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * [peContext.associatedGenModel().generationMark()/] - */ - public [view.pepFormClass()/](IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * [peContext.associatedGenModel().generationMark()/] - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * [peContext.associatedGenModel().generationMark()/] - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - [view.compositionSequence()/] - composer = new PartComposer([view.compositionStepName()/]) { - - @Override - public Composite addToPart(Composite parent, Object key) { - [for (aView : ViewElement | view.eAllContents(ViewElement)->select(owningView() = view))] - [if (oclIsKindOf(CustomElementEditor))] - // [protected ('for '.concat(aView.name).concat(' addToPart creation'))] - - // [/protected] - [else] - if (key == [aView.editorID()/][if (aView.oclIsKindOf(Container))].class[/if]) { - [aView.implementation()/] - } - [/if] - [/for] - return parent; - } - }; - composer.compose(view); -[comment][for (aView : ViewElement | view.elements)] -[aView.implementation()/] - -[/for] -[if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('for additional ui definition')] - - // [/protected] -[/if] -[/comment] - } -[for (aView : ViewElement | view.eAllContents(ViewElement)->select(not oclIsTypeOf(CustomElementEditor) and owningView() = view))] -[aView.additionalImplementation(pec, inputPEC)/] - -[/for] -[for (subView : View | view.elements->filter(View))] -[subView.additionalImplementation(pec, inputPEC)/] - -[/for] - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * [peContext.associatedGenModel().generationMark()/] - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { -[if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('for tab synchronization')] - - // [/protected] -[/if] - } - -[for (elementEditor : ElementEditor | view.eAllContents(ElementEditor)->select(not oclIsTypeOf(CustomElementEditor) and owningView() = view))] -[elementEditor.getterImplementation(fullPartInterfacePath(pec.model.eefPackage(basePackage), view.pepInterface()))/] - -[elementEditor.setterImplementation(fullPartInterfacePath(pec.model.eefPackage(basePackage), view.pepInterface()))/] - -[/for] - -[comment managing viewReference/] -[view.elementEditorGetterSettersForViewReference(pec, basePackage)/] - -[comment managing subView/] -[view.elementEditorGetterSettersForSubViews(pec, basePackage)/] - -[if (not peContext.associatedGenModel().useJMergeForUserCode)] -[for (viewElement : ViewElement | view.eAllContents(CustomElementEditor)->select(owningView() = view))] - // [protected ('for '.concat(viewElement.name).concat(' specific getters and setters implementation'))] - - // [/protected] - -[/for] -[/if] - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * [peContext.associatedGenModel().generationMark()/] - */ - public String getTitle() { - return [include(view.owningViewsRepository().qualifiedMessagesProvider())/].[view.name.toJavaClassifier()/]_Part_Title; - } - -[view.additionalMethods()/] - -} -[/template] - -[template private CustomViewPropertiesEditionPartForm(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View, basePackage : String, inputPEC : PropertiesEditionComponent) ] -[peContext.initializeImportManager(view.partsFormPackage(), view.pepFormClass())/] -[file (view.fullFilePath(), false)] -[peContext.associatedGenModel().licenceText().trim()/] -package [view.partsFormPackage()/];[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent', - 'org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart', - 'org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart', - 'org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.layout.GridLayout', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.ui.forms.widgets.Form', - 'org.eclipse.ui.forms.widgets.ScrolledForm', - 'org.eclipse.ui.forms.widgets.FormToolkit'})/] - -[let content : String = peContext.fileContentCompositePart(pec, view)] -[if (peContext.associatedGenModel().useJMergeForUserCode)] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, view, basePackage)/] -[else] -// [protected ('for imports')] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, view, basePackage)/] - -// [/protected] -[/if] -[content/] -[/let] -[/file] -[/template] - -[template private fileContentCompositePart(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View) ] -/** - * [peContext.associatedGenModel().authorText().trim()/] - * [peContext.associatedGenModel().generationMark()/] - */ -public class [view.pepFormClass()/] extends CompositePropertiesEditionPart implements IFormPropertiesEditionPart, [include(view.pepQualifiedInterface())/] { - - [if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('widgets declaration')] - - // [/protected] - [/if] - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * [peContext.associatedGenModel().generationMark()/] - */ - public [view.pepFormClass()/](IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * [peContext.associatedGenModel().generationMark()/] - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * [peContext.associatedGenModel().generationMark()/] - */ - public void createControls(final FormToolkit widgetFactory, Composite p_view) { - view = widgetFactory.createComposite(p_view, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - view.setLayout(layout); - [if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('view visual definition')] - - // [/protected] - [/if] - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * [peContext.associatedGenModel().generationMark()/] - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - [if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('for tab synchronization')] - - // [/protected] - [/if] - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * [peContext.associatedGenModel().generationMark()/] - */ - public String getTitle() { - [if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('for title')] - return "CustomTitle"; - // [/protected] - [else] - return "CustomTitle"; - [/if] - } - -[view.additionalMethods()/] - -} -[/template] - -[template public additionalMethods(view : View)] - [if (not view.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - // [protected ('additional methods')] - - // [/protected] - [/if] -[/template] - -[template public fullFilePath(view : View)] -[view.pepFormQualifiedClass().toPath()/].java -[/template] - -[comment overrides this template if additional imports are needed/] -[template public additionalImports (peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View, basePackage : String)/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/IPropertiesEditionPart.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/IPropertiesEditionPart.mtl deleted file mode 100644 index 7e789c1d5..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/IPropertiesEditionPart.mtl +++ /dev/null @@ -1,147 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module IPropertiesEditionPart('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/views/toolkits/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public IPropertiesEditionPart(viewRepository : ViewsRepository)] -[for (view : View | viewRepository.eAllContents(View))] -[view.ViewPropertiesEditionPart(viewRepository)/] -[/for] -[for (view : View | viewRepository.eAllContents(CustomView))] -[view.CustomViewPropertiesEditionPart(viewRepository)/] -[/for] -[/template] - -[template private ViewPropertiesEditionPart(view : View, viewRepository : ViewsRepository) ] -[initializeImportManager(view.partsPackage(), view.pepInterface())/] -[file (view.fullFilePath(), false)] -[viewRepository.associatedGenModel().licenceText().trim()/] -package [view.partsPackage()/]; - -[let content : String = view.fileContent(viewRepository)] -[if (viewRepository.associatedGenModel().useJMergeForUserCode)] -[viewRepository.genSortedImports()/] -[additionalImports(view, viewRepository)/] -[else] -// [protected ('for imports')] -[viewRepository.genSortedImports()/] -[additionalImports(view, viewRepository)/] - -// [/protected] -[/if] - -[content/] -[/let] -[/file] -[/template] - -[template public fileContent(view : View, viewRepository : ViewsRepository)] -/** - * [viewRepository.associatedGenModel().authorText().trim()/] - * [viewRepository.associatedGenModel().generationMark()/] - */ -public interface [view.pepInterface()/] { - -[for (elementEditor : ElementEditor | view.eAllContents(ElementEditor)->select(not oclIsKindOf(CustomElementEditor) and owningView() = view))] -[elementEditor.genDeclaration()/] - -[/for] -[for (subView : View | view.eAllContents(View))] -[subView.genDeclarationForSubViews()/] -[/for] -[comment viewReference Support/] -[view.genDeclarationForViewReference()/] - -[if (not viewRepository.associatedGenModel().useJMergeForUserCode)] -[for (viewElement : ViewElement | view.eAllContents(ElementEditor)->select(oclIsTypeOf(CustomElementEditor)))] - // [protected ('for '.concat(viewElement.name).concat(' specific getters and setters declaration'))] - - // [/protected] -[/for] -[/if] - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * [viewRepository.associatedGenModel().generationMark()/] - */ - public String getTitle(); - - [if (not viewRepository.associatedGenModel().useJMergeForUserCode)] - // [protected ('for additional methods')] - - // [/protected] - [/if] - -} -[/template] - -[template private CustomViewPropertiesEditionPart(view : View, viewRepository : ViewsRepository) ] -[initializeImportManager(view.partsPackage(), view.pepInterface())/] -[file (view.fullFilePath(), false)] -[viewRepository.associatedGenModel().licenceText().trim()/] -package [view.partsPackage()/]; - -[let content : String = view.fileContentCustomView(viewRepository)] -[if (viewRepository.associatedGenModel().useJMergeForUserCode)] -[viewRepository.genSortedImports()/] -[additionalImports(view, viewRepository)/] -[else] -// [protected ('for imports')] -[viewRepository.genSortedImports()/] -[additionalImports(view, viewRepository)/] - -// [/protected] -[/if] - -[content/] -[/let] -[/file] -[/template] - -[template public fileContentCustomView(view : View, viewRepository : ViewsRepository)] -/** - * [viewRepository.associatedGenModel().authorText().trim()/] - * [viewRepository.associatedGenModel().generationMark()/] - */ -public interface [view.pepInterface()/] { - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * [viewRepository.associatedGenModel().generationMark()/] - */ - public String getTitle(); - - [if (not viewRepository.associatedGenModel().useJMergeForUserCode)] - // [protected (' for getters and setters declaration')] - - // [/protected] - [/if] - -} -[/template] - -[template public fullFilePath(view : View)] -[view.pepQualifiedInterface().toPath()/].java -[/template] - -[comment overrides this template if additional imports are needed/] -[template public additionalImports (view : View, viewRepository : ViewsRepository)/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/PropertiesEditionPart.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/PropertiesEditionPart.mtl deleted file mode 100644 index 29aa02b16..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/PropertiesEditionPart.mtl +++ /dev/null @@ -1,356 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module PropertiesEditionPart('http://www.eclipse.org/emf/eef/components/1.0.0','http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public PropertiesEditionPart(peContext : PropertiesEditionContext, basePackage : String)] -[for (inputPEC : PropertiesEditionComponent | peContext.eAllContents(PropertiesEditionComponent))] -[for (view : View | inputPEC.involvedViews()) ? (view.oclIsTypeOf(View))][let pec : PropertiesEditionComponent = if (inputPEC.views->includes(view)) - then inputPEC - else inputPEC.referencedBinding.binding->select(views->includes(view))->first().oclAsType(PropertiesEditionComponent) - endif] -[if (view.mustBeGenerated(inputPEC))] -[peContext.ViewPropertiesEditionPart(pec, view, basePackage, inputPEC)/] -[/if] -[/let][/for] -[for (view : View | inputPEC.involvedViews()) ? (inputPEC.explicit and view.oclIsTypeOf(CustomView))][let pec : PropertiesEditionComponent = if (inputPEC.views->includes(view)) - then inputPEC - else inputPEC.referencedBinding.binding->select(views->includes(view))->first().oclAsType(PropertiesEditionComponent) - endif] -[peContext.CustomViewPropertiesEditionPart(pec, view, basePackage, inputPEC)/] -[/let][/for] -[/for] -[/template] - -[template private ViewPropertiesEditionPart(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View, basePackage : String, inputPEC : PropertiesEditionComponent) ] -[peContext.initializeImportManager(view.partsImplPackage(), view.pepClass())/] - -[comment]Widget Imports[/comment] -[for (widget : Widget | view.eAllContents(ElementEditor).representation->select(not oclIsUndefined())->asSet())] -[widget.manageImports(pec, view, basePackage)/] -[/for] -[for (widget : Widget | view.eAllContents(views::Container).representation->asSet()) ? (not widget.oclIsUndefined())] -[widget.manageImports(pec, view, basePackage)/] -[/for] -[for (widget : Widget | view.eAllContents(views::Container).representation->asSet()) ? (not widget.oclIsUndefined())] -[widget.manageImports(pec, view, basePackage)/] -[/for] -[comment][for (widget : Widget | view.eAllContents(ViewReference).view.eAllContents(ElementEditor).representation->asSet())] -[widget.manageImports(pec, view, basePackage)/] -[/for][/comment] - -[file (view.fullFilePath(), false)] -[peContext.associatedGenModel().licenceText().trim()/] -package [view.partsImplPackage()/];[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.ui.parts.PartComposer', - 'org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent', - 'org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.layout.GridLayout', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart'})/] - -[let content : String = peContext.fileContent(pec, view, basePackage, inputPEC)] -[if (peContext.associatedGenModel().useJMergeForUserCode)] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, view, basePackage)/] -[else] -// [protected ('for imports')] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, view, basePackage)/] -// [/protected] -[/if] - -[content/] -[/let] -[/file] -[/template] - -[template private fileContent(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View, basePackage : String, inputPEC : PropertiesEditionComponent) ] -/** - * [peContext.associatedGenModel().authorText().trim()/] - * [peContext.associatedGenModel().generationMark()/] - */ -public class [view.pepClass()/] extends [include(view.partQualifiedSuperclass())/] implements ISWTPropertiesEditionPart, [include(view.pepQualifiedInterface())/] { - -[for (editor : ElementEditor | view.eAllContents(ElementEditor))] -[editor.widgetDeclaration()/] -[/for] -[comment managing ViewReferences/] -[view.widgetDeclarationForViewReference()/] -[comment managing SubViews/] -[view.widgetDeclarationForSubViews()/] - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * [peContext.associatedGenModel().generationMark()/] - */ - public [view.pepClass()/](IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * [peContext.associatedGenModel().generationMark()/] - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * [peContext.associatedGenModel().generationMark()/] - */ - public void createControls(Composite view) { - [view.compositionSequence()/] - composer = new PartComposer([view.compositionStepName()/]) { - - @Override - public Composite addToPart(Composite parent, Object key) { - [for (aView : ViewElement | view.eAllContents(ViewElement)->select(owningView() = view))] - [if (oclIsKindOf(CustomElementEditor))] - // [protected ('for '.concat(aView.name).concat(' addToPart creation'))] - - // [/protected] - [else] - if (key == [aView.editorID()/][if (aView.oclIsKindOf(Container))].class[/if]) { - [aView.implementation()/] - } - [/if] - [/for] - return parent; - } - }; - composer.compose(view); -[comment][for (aView : ViewElement | view.elements)] -[aView.implementation()/] - -[/for] - - [if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('for additional ui definition')] - - // [/protected] - [/if][/comment] - } - -[for (aView : ViewElement | view.eAllContents(ViewElement)->select(not oclIsTypeOf(CustomElementEditor) and owningView() = view))] -[aView.additionalImplementation(pec, inputPEC)/] - -[/for] -[for (subView : View | view.elements->filter(View))] -[subView.additionalImplementation(pec, inputPEC)/] - -[/for] - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * [peContext.associatedGenModel().generationMark()/] - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { -[if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('for tab synchronization')] - - // [/protected] -[/if] - } - -[for (elementEditor : ElementEditor | view.eAllContents(ElementEditor)->select(not oclIsTypeOf(CustomElementEditor) and owningView() = view))] -[elementEditor.getterImplementation(fullPartInterfacePath(pec.model.eefPackage(basePackage), view.pepInterface()))/] - -[elementEditor.setterImplementation(fullPartInterfacePath(pec.model.eefPackage(basePackage), view.pepInterface()))/] - -[/for] - -[comment managing viewReference/] -[view.elementEditorGetterSettersForViewReference(pec, basePackage)/] - -[comment managing subView/] -[view.elementEditorGetterSettersForSubViews(pec, basePackage)/] - -[if (not peContext.associatedGenModel().useJMergeForUserCode)] -[for (viewElement : ViewElement | view.eAllContents(CustomElementEditor)->select(owningView() = view))] - // [protected ('for '.concat(viewElement.name).concat(' specific getters and setters implementation'))] - - // [/protected] - -[/for] -[/if] - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * [peContext.associatedGenModel().generationMark()/] - */ - public String getTitle() { - return [include(view.owningViewsRepository().qualifiedMessagesProvider())/].[view.name.toJavaClassifier()/]_Part_Title; - } - -[view.additionalMethods()/] - -} -[/template] - -[template private CustomViewPropertiesEditionPart(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View, basePackage : String, inputPEC : PropertiesEditionComponent) ] -[peContext.initializeImportManager(view.partsImplPackage(), view.pepClass())/] -[file (view.fullFilePath(), false)] -[peContext.associatedGenModel().licenceText().trim()/] -package [view.partsImplPackage()/];[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart', - 'org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent', - 'org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.layout.GridLayout', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent'})/] - -[let content : String = peContext.fileContentCompositePart(pec, view)] -[if (peContext.associatedGenModel().useJMergeForUserCode)] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, view, basePackage)/] -[else] -// [protected ('for imports')] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec, view, basePackage)/] - -// [/protected] -[/if] -[content/] -[/let] -[/file] -[/template] - -[template private fileContentCompositePart(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View) ] -/** - * [peContext.associatedGenModel().authorText().trim()/] - */ -public class [view.pepClass()/] extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, [include(view.pepQualifiedInterface())/] { - - [if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('widgets declaration')] - - // [/protected] - [/if] - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * [peContext.associatedGenModel().generationMark()/] - */ - public [view.pepClass()/](IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * [peContext.associatedGenModel().generationMark()/] - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * [peContext.associatedGenModel().generationMark()/] - */ - public void createControls(Composite p_view) { - view = new Composite(p_view, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - view.setLayout(layout); - [if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('view visual definition')] - - // [/protected] - [/if] - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * [peContext.associatedGenModel().generationMark()/] - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - [if (not peContext.associatedGenModel().useJMergeForUserCode)] - // [protected ('for tab synchronization')] - - // [/protected] - [/if] - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * [peContext.associatedGenModel().generationMark()/] - */ - public String getTitle() { - [if (peContext.associatedGenModel().useJMergeForUserCode)] - return "CustomTitle"; - [else] - // [protected ('for title')] - return "CustomTitle"; - // [/protected] - [/if] - } - -[view.additionalMethods()/] - -} -[/template] - -[template public additionalMethods(view : View)] - [if (not view.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - // [protected ('additional methods')] - - // [/protected] - [/if] -[/template] - -[template public fullFilePath(view : View)] -[view.pepQualifiedClass().toPath()/].java -[/template] - -[comment overrides this template if additional imports are needed/] -[template public additionalImports (peContext : PropertiesEditionContext, pec : PropertiesEditionComponent, view : View, basePackage : String)/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/ViewsRepository.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/ViewsRepository.mtl deleted file mode 100644 index c140bb85c..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/parts/ViewsRepository.mtl +++ /dev/null @@ -1,111 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module ViewsRepository('http://www.eclipse.org/emf/eef/views/1.0.0','http://www.eclipse.org/emf/eef/components/1.0.0','http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] - -[comment - This template will generate a file for each ViewRepository in the EEF model. - /] -[template public ViewsRepository(viewRepository : ViewsRepository)] -[file (viewRepository.fullFilePath(), false)] -[viewRepository.associatedGenModel().licenceText().trim()/] -package [viewRepository.partsPackage()/]; - -/** - * [viewRepository.associatedGenModel().authorText().trim()/] - * [viewRepository.associatedGenModel().generationMark()/] - */ -public class [viewRepository.vrClass()/] { - - public static final int SWT_KIND = 0; - - public static final int FORM_KIND = 1; - -[viewRepository.viewDescriptors()/] -} -[/file] -[/template] - -[comment - Template used to call recursively on the viewRepository to get views - /] -[template public viewDescriptors(viewRepository : ViewsRepository)] -[for (view : View | viewRepository.views) separator ('\n')] -[view.viewDescriptor()/] -[/for] -[for (category : Category | viewRepository.eAllContents(views::Category)) separator ('\n')] -[for (view : View |category.views )] -[view.viewDescriptor()/] -[/for] -[/for] -[/template] - -[comment Template used to generate code for each views /] -[template public viewDescriptor(view : View)] - - /** - * [view.name/] view descriptor - * [view.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public static class [view.identifiedElementKey().toJavaClassifier()/] { -[if (view.oclIsTypeOf(views::CustomView) and not view.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - // [protected ('for '.concat(view.name).concat(' keys'))] - - // [/protected] -[else] -[for (viewElement : ViewElement | view.elements)] - [viewElement.viewElementDescriptor()/] -[/for] -[/if] - } -[/template] - -[comment - Template used to generate code for each elementEditor. it calls recursively on the content of each viewElement - /] -[template public viewElementDescriptor(viewElement : ViewElement)] -[if (viewElement.oclIsTypeOf(ElementEditor))] -[viewElement.owningViewsRepository().associatedGenModel().generationComment()/] -public static String [viewElement.oclAsType(ElementEditor).identifiedElementKey().toJavaIdentifier()/] = "[viewElement.oclAsType(ElementEditor).qualifiedIdentifier/]"; -[elseif (viewElement.oclIsTypeOf(CustomElementEditor) and not viewElement.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] -// [protected ('for '.concat(viewElement.name).concat(' ElementEditor key'))] -public static String [viewElement.oclAsType(CustomElementEditor).identifiedElementKey().toJavaIdentifier()/] = "[viewElement.oclAsType(CustomElementEditor).qualifiedIdentifier/]"; -// [/protected] -[elseif (viewElement.oclIsTypeOf(views::Container))] - public static class [viewElement.oclAsType(views::Container).identifiedElementKey().toJavaClassifier()/] { - - [for (ve : ViewElement | viewElement.oclAsType(views::Container).elements)] - [ve.viewElementDescriptor()/] - [/for] - - } -[elseif (viewElement.oclIsTypeOf(View))] -[for (v : View | viewElement.oclAsType(View))] - [v.viewDescriptor()/] -[/for] -[elseif (viewElement.oclIsTypeOf(ViewReference))] -[viewElement.owningViewsRepository().associatedGenModel().generationComment()/] -public static String [viewElement.oclAsType(ViewReference).identifiedElementKey().toJavaIdentifier()/] = "[viewElement.oclAsType(ViewReference).qualifiedIdentifier/]"; -[else] - //TODO FIXME invalid case for template public viewElementDescriptor(viewElement : ViewElement) in module ViewsRepository.mtl, viewElement : [viewElement/] -[/if] -[/template] - -[comment - Template used to determine the viewRepository's generated file full path - /] -[template public fullFilePath(repository : ViewsRepository)] -[repository.vrQualifiedClass().toPath()/].java -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/plugin/plugin_xml.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/plugin/plugin_xml.mtl deleted file mode 100644 index 5372dde91..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/plugin/plugin_xml.mtl +++ /dev/null @@ -1,119 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module plugin_xml('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::pluginservice /] - -[template public plugin_xml(editionContext : PropertiesEditionContext, basePackage : String)] - [file (editionContext.model.ecorePackage.name.concat('_properties.plugin.xml'), false)] - - - - - - - - - -[for (genViewRepository : GenViewsRepository | editionContext.associatedGenModel().viewsRepositories)] - - - - -[/for] - - - - - - - - - - - - - - -[for (entry : Sequence(OclAny) | editionContext.getPluginTabs())] -[editionContext.propertyTab(basePackage, entry -> at(1).oclAsType(View), entry -> at(2).oclAsType(PropertiesEditionComponent))/] -[/for] - - -[propertySections(editionContext, basePackage)/] - -[/file] -[/template] - -[template public propertySections(editionContext : PropertiesEditionContext, basePackage : String)] -[let pecs : Sequence(PropertiesEditionComponent) = - editionContext.eAllContents(PropertiesEditionComponent).oclAsType(PropertiesEditionComponent) -> - select(mustBeGenerated() and explicit and model.oclIsTypeOf(EClass) and not model.oclAsType(EClass).abstract)] -[if (not (pecs -> isEmpty()))] - - -[for (pec : PropertiesEditionComponent | pecs)] -[for (view : View | pec.involvedViews())] - - -[/for] -[/for] - - [/if] -[/let] -[/template] - -[template public propertyTab(editionContext : PropertiesEditionContext, basePackage : String, view : View, pec : PropertiesEditionComponent)] - indexOf(view) > 1)] - category="extended" - afterTab="[pec.previousView(view).genTabId(pec)/]"> - -[else] - category="default"> - -[/if] -[/template] - -[template public labelProvider(editionContext : PropertiesEditionContext)] -org.eclipse.gmf.runtime.common.ui.services.util.CommonLabelProvider -[/template] - -[query public genTabId (view : View, pec : PropertiesEditionComponent) : String = -view.viewKey(pec).toASCII()/] - -[query public previousView(pec : PropertiesEditionComponent, view : View) : View = - pec.involvedViews()->at(pec.involvedViews()->asOrderedSet()->indexOf(view) -1 ).oclAsType(View)/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessages.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessages.mtl deleted file mode 100644 index 0502673d1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessages.mtl +++ /dev/null @@ -1,124 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module ContextMessages('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] - -[template public ContextMessages(viewsRepository : ViewsRepository)] - [file (viewsRepository.fullFilePath(), false)] -[viewsRepository.associatedGenModel().licenceText().trim()/] -package [viewsRepository.messagesProviderPackage()/]; - -import org.eclipse.osgi.util.NLS; - -/** - * [viewsRepository.associatedGenModel().authorText().trim()/] - * [viewsRepository.associatedGenModel().generationMark()/] - */ -public class [viewsRepository.messagesProvider()/] extends NLS { - [viewsRepository.associatedGenModel().generationComment()/] - private static final String BUNDLE_NAME = "[viewsRepository.messagesProviderPackage()/].[viewsRepository.messagesProperties()/]"; //$NON-NLS-1$ - -[for (group : ViewElement | viewsRepository.eAllContents(views::Container)->select(e | e.oclIsTypeOf(views::Container))) ? (group.representationName('Group'))] - [viewsRepository.associatedGenModel().generationComment()/] - public static String [group.groupKey(group.owningView())/]; - -[/for] - -[for (view : View | viewsRepository.eAllContents(View))] - [viewsRepository.associatedGenModel().generationComment()/] - public static String [view.name.toJavaClassifier()/]_ReadOnly; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String [view.name.toJavaClassifier()/]_Part_Title; - -[/for] - -[for (editor : ElementEditor | viewsRepository.eAllContents(views::ElementEditor))] - [viewsRepository.associatedGenModel().generationComment()/] - public static String [editor.editorKey(editor.owningView())/]; - -[/for] - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_DocumentationLabel; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_IntegerValueMessage; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_FloatValueMessage; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_ShortValueMessage; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_LongValueMessage; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_ByteValueMessage; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_BigIntegerValueMessage; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_BigDecimalValueMessage; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_DoubleValueMessage; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_PropertiesGroupLabel; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_RequiredFeatureMessage; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_AddTableViewerLabel; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_EditTableViewerLabel; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_RemoveTableViewerLabel; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_AddListViewerLabel; - - [viewsRepository.associatedGenModel().generationComment()/] - public static String PropertiesEditionPart_RemoveListViewerLabel; - - [if (not viewsRepository.associatedGenModel().useJMergeForUserCode)] - // [protected ('for additionnal NLS Constants')] - - // [/protected] - - [/if] - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, [viewsRepository.messagesProvider()/].class); - } - - [viewsRepository.associatedGenModel().generationComment()/] - private [viewsRepository.messagesProvider()/]() { - //protect instanciation - } -} -[/file] -[/template] - -[template public fullFilePath(viewsRepository : ViewsRepository)] -[viewsRepository.messagesProviderPackage().toPath()/]/[viewsRepository.messagesProvider()/].java -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessagesProperties.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessagesProperties.mtl deleted file mode 100644 index 4c7b03de3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessagesProperties.mtl +++ /dev/null @@ -1,58 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module ContextMessagesProperties('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] - -[template public ContextMessagesProperties(viewsRepository : ViewsRepository)] - [file (viewsRepository.fullFilePath(), false)] -[viewsRepository.associatedGenModel().propertiesLicenceText().trim()/] - -# [protected ('for titles customization')] - -# [/protected] - -# default values ... -[for (group : ViewElement | viewsRepository.eAllContents(views::Container)->select(e | e.oclIsTypeOf(views::Container))) ? (group.representation.name = 'Group')] -[group.groupKey(group.owningView())/]=[group.name.toUpperFirst().toUnicode()/] -[/for] -[for (view : View | viewsRepository.eAllContents(View))] -[view.name.toJavaClassifier()/]_ReadOnly=This property is read only -[view.name.toJavaClassifier()/]_Part_Title=[if (not view.involvedPropertiesEditionComponent().oclIsUndefined())][view.genTabLabel(view.involvedPropertiesEditionComponent())/][/if] -[/for] -[for (editor : ElementEditor | viewsRepository.eAllContents(ElementEditor))] -[editor.editorKey(editor.owningView())/]=[editor.name.toUpperFirst().toUnicode()/][if ( not editor.representationName('Checkbox') and not editor.representationName('MultiValuedEditor'))] : [/if] -[/for] -PropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionPart_EditTableViewerLabel=Edit -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=The property {0} of the object shall be filled -PropertiesEditionPart_RemoveTableViewerLabel=Delete -PropertiesEditionPart_RemoveListViewerLabel=Delete -PropertiesEditionPart_IntegerValueMessage=The property {0} shall be an integer -PropertiesEditionPart_FloatValueMessage=The property {0} shall be a float -PropertiesEditionPart_ShortValueMessage=The property {0} shall be a short -PropertiesEditionPart_DoubleValueMessage=The property {0} shall be a double -PropertiesEditionPart_ByteValueMessage=The property {0} shall be a byte -PropertiesEditionPart_LongValueMessage=The property {0} shall be a long -PropertiesEditionPart_BigIntegerValueMessage=The property {0} shall be a BigInteger -PropertiesEditionPart_BigDecimalValueMessage=The property {0} shall be a BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Add -PropertiesEditionPart_AddListViewerLabel=Add -[/file] -[/template] - -[template public fullFilePath(viewsRepository : ViewsRepository)] -[viewsRepository.messagesProviderPackage().toPath()/]/[viewsRepository.messagesProperties()/].properties -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessagesPropertiesFR.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessagesPropertiesFR.mtl deleted file mode 100644 index 6ad53b266..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/ContextMessagesPropertiesFR.mtl +++ /dev/null @@ -1,58 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module ContextMessagesPropertiesFR('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/views/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] - -[template public ContextMessagesPropertiesFR(viewsRepository : ViewsRepository)] - [file (viewsRepository.fullFilePath(), false)] -[viewsRepository.associatedGenModel().propertiesLicenceText().trim()/] - -# [protected ('for titles customization')] - -# [/protected] - -# default values ... -[for (group : ViewElement | viewsRepository.eAllContents(views::Container)->select(e | e.oclIsTypeOf(views::Container))) ? (group.representation.name = 'Group')] -[group.groupKey(group.owningView())/]=[group.name.toUpperFirst().toUnicode()/] -[/for] -[for (view : View | viewsRepository.eAllContents(View))] -[view.name.toJavaClassifier()/]_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -[view.name.toJavaClassifier()/]_Part_Title=[if (not view.involvedPropertiesEditionComponent().oclIsUndefined())][view.genTabLabel(view.involvedPropertiesEditionComponent())/][/if] -[/for] -[for (editor : ElementEditor | viewsRepository.eAllContents(ElementEditor))] -[editor.editorKey(editor.owningView())/]=[editor.name.toUpperFirst().toUnicode()/][if ( not editor.representationName('Checkbox') and not editor.representationName('MultiValuedEditor'))] : [/if] -[/for] -PropertiesEditionPart_PropertiesGroupLabel=Propri\u00E9t\u00E9s -PropertiesEditionPart_EditTableViewerLabel=Editer -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=La propri\u00E9t\u00E9 {0} de l\u0027objet doit \u00EAtre renseign\u00E9e -PropertiesEditionPart_RemoveTableViewerLabel=Supprimer -PropertiesEditionPart_RemoveListViewerLabel=Supprimer -PropertiesEditionPart_IntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un entier -PropertiesEditionPart_FloatValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un flottant -PropertiesEditionPart_ShortValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un short -PropertiesEditionPart_DoubleValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un double -PropertiesEditionPart_ByteValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un byte -PropertiesEditionPart_LongValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un long -PropertiesEditionPart_BigIntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigInteger -PropertiesEditionPart_BigDecimalValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Ajouter -PropertiesEditionPart_AddListViewerLabel=Ajouter -[/file] -[/template] - -[template public fullFilePath(viewsRepository : ViewsRepository)] -[viewsRepository.messagesProviderPackage().toPath()/]/[viewsRepository.messagesProperties()/]_fr.properties -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PackagePropertiesEditionPartProvider.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PackagePropertiesEditionPartProvider.mtl deleted file mode 100644 index 6854190ac..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PackagePropertiesEditionPartProvider.mtl +++ /dev/null @@ -1,77 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module PackagePropertiesEditionPartProvider('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public PackagePropertiesEditionPartProvider(v : ViewsRepository)] -[v.initializeImportManager(v.partsProviderPackage(), v.pepProvider())/] -[file (v.fullFilePath(), false)] -[v.associatedGenModel().licenceText().trim()/] -package [v.vrPackage()/]providers;[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent', - 'org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart', - 'org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider'})/] - -[let content : String = v.fileContent()] -[v.genSortedImports()/] -[v.additionalImports()/] -[content/] -[/let] -[/file] -[/template] - -[template public fileContent(v : ViewsRepository)] -/** - * [v.associatedGenModel().authorText().trim()/] - * [v.associatedGenModel().generationMark()/] - */ -public class [v.pepProvider()/] implements IPropertiesEditionPartProvider { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#provides(java.lang.Object) - * [v.associatedGenModel().generationMark()/] - */ - public boolean provides(Object key) { - return key == [include(v.vrQualifiedClass())/].class; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#getPropertiesEditionPart(java.lang.Object, int, org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - * [v.associatedGenModel().generationMark()/] - */ - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, IPropertiesEditionComponent component) { - [for (view : View | v.eAllContents(View)) ? (view.elements->size() > 0)] - if (key == [view.editorID()/].class) { - if (kind == [v.vrClass()/].SWT_KIND) - return new [include(view.pepQualifiedClass())/](component); - if (kind == [v.vrClass()/].FORM_KIND) - return new [include(view.pepFormQualifiedClass())/](component); - } - [/for] - return null; - } - -} -[/template] - -[template public fullFilePath(repository : ViewsRepository)] -[repository.pepQualifiedProvider().toPath()/].java -[/template] - -[comment overrides this template if additional imports are needed/] -[template public additionalImports (repository : ViewsRepository)/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PackagePropertiesEditionProvider.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PackagePropertiesEditionProvider.mtl deleted file mode 100644 index 6aaab9cf1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PackagePropertiesEditionProvider.mtl +++ /dev/null @@ -1,85 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module PackagePropertiesEditionProvider('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::imports/] -[import org::eclipse::emf::eef::codegen::services::emfCodeGen /] - -[template public PackagePropertiesEditionProvider(peContext : PropertiesEditionContext, ePackage : EPackage)] -[peContext.initializeImportManager(peContext.providersPackage(), ePackage.pecPackageProviderClass())/] - [file (peContext.fullFilePath(ePackage), false)] -[peContext.associatedGenModel().licenceText().trim()/] -package [peContext.providersPackage()/]; - -[let content : String = peContext.fileContent(peContext, ePackage)] -[peContext.genSortedImports()/] -[peContext.additionalImports(ePackage)/] -[content/] -[/let] -[/file] -[/template] - -[template public includeAdapterFactoryImport(peContext : PropertiesEditionContext, ePackage : EPackage) post(trim())] -[let base : String = - if (not peContext.associatedEMFGenModel(ePackage).basePackage.oclIsUndefined()) and (peContext.associatedEMFGenModel(ePackage).basePackage.size() > 0) - then peContext.associatedEMFGenModel(ePackage).basePackage + '.' - else '' endif] -[include(base + ePackage.name.replaceKeywords() + '.util.' + peContext.associatedEMFGenModel(ePackage).prefix + 'AdapterFactory')/] -[/let] -[/template] - -[template private fileContent(peContext : PropertiesEditionContext, ePackage : EPackage) ] -/** - * [peContext.associatedGenModel().authorText().trim()/] - * [peContext.associatedGenModel().generationMark()/] - */ -public class [ePackage.pecPackageProviderClass()/] extends [includeAdapterFactoryImport(ePackage)/] { - -[for (eclass : EClass | ePackage.significantClass()->asOrderedSet())] - [let pec : PropertiesEditionComponent = eclass.associatedPEC(peContext)] - [if (not pec.oclIsUndefined() and pec.mustBeGenerated())] - /** - * {@inheritDoc} - * @see [peContext.associatedEMFGenModel(ePackage).basePackage/].[ePackage.name/].util.[peContext.associatedEMFGenModel(ePackage).prefix/]AdapterFactory#create[eclass.name.toJavaIdentifierDelegate().toUpperFirst()/]Adapter() - * [peContext.associatedGenModel().generationMark()/] - */ - public [include('org.eclipse.emf.common.notify.Adapter')/] create[eclass.name.toJavaIdentifierDelegate().toUpperFirst()/]Adapter() { - [if (pec.referencedBinding->size() > 0)] - [include('java.util.List')/]<[include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/]> providers = new [include('java.util.ArrayList')/]([pec.referencedBinding->size()/]); - [for (binding : PropertiesEditionComponent | pec.referencedBinding.binding.oclAsType(PropertiesEditionComponent))] - providers.add((PropertiesEditingProvider)create[binding.pecModelClass().toJavaIdentifierDelegate().toUpperFirst()/]Adapter()); - [/for] - return new [include(pec.pecProviderQualifiedClass())/](providers); - [else] - return new [include(pec.pecProviderQualifiedClass())/](); - [/if] - } - [/if] - [/let] -[/for] - -} -[/template] - -[template private genAdapterFactoryName(peContext : PropertiesEditionContext, ePackage : EPackage)] -[if ((not peContext.associatedEMFGenModel(ePackage).basePackage.oclIsUndefined()) and (peContext.associatedEMFGenModel(ePackage).basePackage.size() > 0))][peContext.associatedEMFGenModel(ePackage).basePackage/].[/if][ePackage.name.toJavaIdentifier()/].util.[peContext.associatedEMFGenModel(ePackage).prefix/]AdapterFactory -[/template] - -[template public fullFilePath(peContext : PropertiesEditionContext, ePackage : EPackage)] -[peContext.pecPackageProviderQualifiedClass(ePackage).toPath()/].java -[/template] - -[comment overrides this template if additional imports are needed/] -[template public additionalImports (peContext : PropertiesEditionContext, ePackage : EPackage)/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PropertiesEditionProvider.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PropertiesEditionProvider.mtl deleted file mode 100644 index 38b83fe56..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/providers/PropertiesEditionProvider.mtl +++ /dev/null @@ -1,261 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module PropertiesEditionProvider('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public PropertiesEditionProvider(peContext : PropertiesEditionContext, basePackage : String)] -[for (pec : PropertiesEditionComponent | peContext.eAllContents(PropertiesEditionComponent))] -[if (pec.mustBeGenerated())] - [peContext.initializeImportManager(pec.providersPackage(), pec.pecProviderClass())/] - [file (pec.fullFilePath(), false)] -[peContext.associatedGenModel().licenceText().trim()/] -package [pec.providersPackage()/];[addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent', - 'org.eclipse.emf.eef.runtime.context.PropertiesEditingContext', - 'org.eclipse.jface.viewers.IFilter', - 'java.util.List', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider'})/] - -[let content : String = peContext.fileContent(peContext, pec)] -[peContext.genSortedImports()/] -[peContext.additionalImports(pec)/] -[content/] -[/let] - [/file] -[/if] -[/for] -[/template] - -[template private fileContent(peContext : PropertiesEditionContext, pec : PropertiesEditionComponent) ] -/** - * [peContext.associatedGenModel().authorText().trim()/] - * [peContext.associatedGenModel().generationMark()/] - */ -public class [pec.pecProviderClass()/] extends [include(pec.pecRootProviderQualifiedClass())/] { - - /** - * Constructor without provider for super types. - */ - public [pec.pecProviderClass()/]() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public [pec.pecProviderClass()/](List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * [peContext.associatedGenModel().generationMark()/] - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof [include(pec.pecModelQualifiedClass())/]) - && ([pec.metamodelGetter()/] == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * [peContext.associatedGenModel().generationMark()/] - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof [pec.pecModelClass()/]) [pec.provideForPart().trim()/]; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * [peContext.associatedGenModel().generationMark()/] - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof [pec.pecModelClass()/]) [pec.provideForClass().trim()/]; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * [peContext.associatedGenModel().generationMark()/] - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof [pec.pecModelClass()/]) [pec.provideForPartAndClass().trim()/]; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * [peContext.associatedGenModel().generationMark()/] - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof [pec.pecModelClass()/]) { - return new [include(pec.pecQualifiedClass())/](editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * [peContext.associatedGenModel().generationMark()/] - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof [pec.pecModelClass()/]) { -[for (view : View | pec.views) ? (view.explicit)] - if ([pec.subPECClass(view)/].[view.viewPartConstant(pec)/].equals(part)) - return new [pec.subPECClass(view)/](editingContext, editingContext.getEObject(), mode); -[/for] -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding->filter(PropertiesEditionComponent))] - [for (view : View | subPec.views) ? (view.explicit and view.ancestors()->filter(View)->excludesAll(pec.views->asSequence()))] - if ([subPec.subPECClass(view)/].[view.viewPartConstant(subPec)/].equals(part)) - return new [subPec.pecClass()/](editingContext, editingContext.getEObject(), mode); - [/for] -[/for] - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof [pec.pecModelClass()/]) { -[for (view : View | pec.views) ? (view.explicit)] - if ([include(pec.subPECQualifiedClass(view))/].[view.viewPartConstant(pec)/].equals(part) - && refinement == [pec.subPECClass(view)/].class) - return new [pec.subPECClass(view)/](editingContext, editingContext.getEObject(), mode); -[/for] -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding->filter(PropertiesEditionComponent))] - [for (view : View | subPec.views) ? (view.explicit and view.ancestors()->filter(View)->excludesAll(pec.views->asSequence()))] - if ([include(subPec.subPECQualifiedClass(view))/].[view.viewPartConstant(subPec)/].equals(part) - && refinement == [subPec.pecClass()/].class) - return new [subPec.pecClass()/](editingContext, editingContext.getEObject(), mode); - [/for] -[/for] - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - [genEditionFilter(pec)/] - -} -[/template] - -[template public genEditionFilter (peContext : PropertiesEditionContext, pec : PropertiesEditionComponent) ] -/** - * Provides the filter used by the plugin.xml to assign part forms. - */ -public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - [genSelectEditionFilter(pec)/] - } - -} -[/template] - -[template public genSelectEditionFilter (peContext : PropertiesEditionContext, pec : PropertiesEditionComponent) ] -EObject eObj = [include('org.eclipse.emf.eef.runtime.impl.utils.EEFUtils')/].resolveSemanticObject(toTest); -return eObj != null && [pec.metamodelGetter()/] == eObj.eClass(); -[/template] - -[template public provideForPart(pec : PropertiesEditionComponent)] -[if (pec.providePart().size() > 0)] -&& ([pec.providePart().replaceAll('\n\r','').replaceAll('\r\n','').replaceAll('\n', '')/]) -[/if] -[/template] - -[template public providePart(pec : PropertiesEditionComponent)] -[let view : View = pec.views->select(explicit)->first()] -[if (not view.oclIsUndefined())][for (v : View | pec.views) separator (' || ') ? (v.explicit)] -[pec.subPECClass(v)/].[v.viewPartConstant(pec)/].equals(part)[/for][/if] -[if (pec.referencedBinding->size()>0)][let subPec : PropertiesEditionComponent = pec.referencedBinding.binding->filter(PropertiesEditionComponent)->first()] -[if (not subPec.oclIsUndefined())][let view2 : View = subPec.views->select(v:View | v.explicit and v.ancestors()->filter(View)->excludesAll(pec.views->asSequence()))->first()] -[if (not view2.oclIsUndefined())][if (not view.oclIsUndefined())] || [/if] -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding->filter(PropertiesEditionComponent)) separator (' || ')] -[for (view : View | subPec.views) separator (' || ') ? (view.explicit and view.ancestors()->filter(View)->excludesAll(pec.views->asSequence()))] -[subPec.subPECClass(view)/].[view.viewPartConstant(subPec)/].equals(part)[/for][/for] -[/if][/let][/if] -[/let] -[/if] -[/let] -[/template] - -[template public provideForClass(pec : PropertiesEditionComponent)] -[if (pec.provideClass().size() > 0)] -&& ([pec.provideClass().replaceAll('\n\r','').replaceAll('\r\n','').replaceAll('\n', '')/]) -[/if] -[/template] - -[template public provideClass(pec : PropertiesEditionComponent)] -[let view : View = pec.views->select(explicit)->first()] -[if (not view.oclIsUndefined())][for (v : View | pec.views) separator (' || ') ? (v.explicit)] -refinement == [pec.subPECClass(v)/].class[/for][/if] -[if (pec.referencedBinding->size()>0)][let subPec : PropertiesEditionComponent = pec.referencedBinding.binding->filter(PropertiesEditionComponent)->first()] -[if (not subPec.oclIsUndefined())][let view2 : View = subPec.views->select(v:View | v.explicit and v.ancestors()->filter(View)->excludesAll(pec.views->asSequence()))->first()] -[if (not view2.oclIsUndefined())][if (not view.oclIsUndefined())] || [/if] -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding->filter(PropertiesEditionComponent)) separator (' || ')] -[for (view : View | subPec.views) separator (' || ') ? (view.explicit and view.ancestors()->filter(View)->excludesAll(pec.views->asSequence()))] -refinement == [subPec.pecClass()/].class[/for][/for] -[/if][/let][/if] -[/let] -[/if] -[/let] -[/template] - - -[template public provideForPartAndClass(pec : PropertiesEditionComponent)] -[if (pec.providePartAndClass().size() > 0)] -&& ([pec.providePartAndClass().replaceAll('\n\r','').replaceAll('\r\n','').replaceAll('\n', '')/]) -[/if] -[/template] - -[template public providePartAndClass(pec : PropertiesEditionComponent)] -[let view : View = pec.views->select(explicit)->first()] -[if (not view.oclIsUndefined())][for (v : View | pec.views) separator (' || ') ? (v.explicit)] -([pec.subPECClass(v)/].[v.viewPartConstant(pec)/].equals(part) && refinement == [include(pec.subPECQualifiedClass(v))/].class)[/for][/if] -[if (pec.referencedBinding->size()>0)][let subPec : PropertiesEditionComponent = pec.referencedBinding.binding->filter(PropertiesEditionComponent)->first()] -[if (not subPec.oclIsUndefined())][let view2 : View = subPec.views->select(v:View | v.explicit and v.ancestors()->filter(View)->excludesAll(pec.views->asSequence()))->first()] -[if (not view2.oclIsUndefined())][if (not view.oclIsUndefined())] || [/if] -[for (subPec : PropertiesEditionComponent | pec.referencedBinding.binding->filter(PropertiesEditionComponent)) separator (' || ')] -[for (view : View | subPec.views) separator (' || ') ? (view.explicit and view.ancestors()->filter(View)->excludesAll(pec.views->asSequence()))] -([subPec.subPECClass(view)/].[view.viewPartConstant(subPec)/].equals(part) && refinement == [include(subPec.pecQualifiedClass())/].class)[/for][/for] -[/if][/let][/if] -[/let] -[/if] -[/let] -[/template] - -[template public fullFilePath(pec : PropertiesEditionComponent)] -[pec.pecProviderQualifiedClass().toPath()/].java -[/template] - -[comment overrides this template if additional imports are needed/] -[template public additionalImports (peContext : PropertiesEditionContext, pec : PropertiesEditionComponent)/] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/EcoreService.java b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/EcoreService.java deleted file mode 100644 index 255437cfe..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/EcoreService.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.services; - -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.util.CodeGenUtil; -import org.eclipse.emf.codegen.util.ImportManager; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; - -/** - * This class is used to implement Ecore related services. - * - * @author William Piers - * @since 1.1 - */ -public class EcoreService { - - /** - * Retrieves the Ecore genModel. - * - * @param eo - * any EObject. - * @return the Ecore genModel - */ - public GenModel getEcoreGenModel(EObject eo) { - Resource genModelResource = new ResourceSetImpl().getResource( - URI.createURI("platform:/plugin/org.eclipse.emf.ecore/model/Ecore.genmodel"), true); - if (genModelResource != null) { - GenModel genModel = (GenModel)genModelResource.getContents().get(0); - - // WARNING: the gen model needs an import manager to make getters usable. So we set a dummy one. - genModel.setImportManager(new ImportManager("dummy")); - - return genModel; - } - throw new RuntimeException("Unable to retrieve Ecore gen model from " + eo); - } - - public String getFormattedName(String name) { - String string = CodeGenUtil.upperName(name); - return CodeGenUtil.format(string, '_', null, false, false); - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/ImportService.java b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/ImportService.java deleted file mode 100644 index 4358cf6e7..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/ImportService.java +++ /dev/null @@ -1,90 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.services; - -import org.eclipse.emf.codegen.ecore.genmodel.GenModel; -import org.eclipse.emf.codegen.util.ImportManager; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; - -/** - * This class is used to implement some behaviors regarding GenModels that cannot be properly implemented with - * acceleo alone. - * - * @author Stephane Bouchet - * @author William Piers - */ -public class ImportService { - - /** - * Initializing EMF importManager. - * - * @since 1.1 - */ - public void initializeImportManager(EObject caller, String packageName, String className) { - ImportManager importManager = new ImportManager(packageName, className); - getGenModel(caller).setImportManager(importManager); - } - - /** - * Initializing EMF importManager on a genmodel. - * To fix call of import manager in a genmodel which is not the genmodel used by the default import manager - */ - public void initializeImportManagerForGenmodel(EObject caller, GenModel model, String packageName, String className) { - ImportManager importManager = new ImportManager(packageName, className); - model.setImportManager(importManager); - } - - /** - * Adds an import. - */ - public void addImport(EObject caller, String qualifiedName) { - GenModel genModel = getGenModel(caller); - genModel.addImport(qualifiedName); - } - - /** - * Generate sorted imports. - * - * @since 1.1 - */ - public String genSortedImports(EObject caller) { - return getGenModel(caller).getImportManager().computeSortedImports(); - } - - /** - * Retrieves the genModel from any EObject from the components model. - * - * @param eo - * any EObject from the components model. - * @return the EMF genModel (intended to hold the ImportManager) - */ - public GenModel getGenModel(EObject eo) { - if (eo.eResource() != null && eo.eResource().getResourceSet() != null) { - for (Resource resource : eo.eResource().getResourceSet().getResources()) { - if (!resource.getContents().isEmpty() && resource.getContents().get(0) instanceof GenModel) { - return (GenModel)resource.getContents().get(0); - } - } - } - throw new RuntimeException("Unable to retrieve gen model from " + eo); - } - - /** - * @deprecated. EEF is using EMF importmanager directy. - * @param cur - * the current Eobject - * @return the importmarker string - */ - public String getImports(EObject cur) { - return ""; - } -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/PluginService.java b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/PluginService.java deleted file mode 100644 index 2609b537e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/PluginService.java +++ /dev/null @@ -1,72 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.services; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Set; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.views.View; - -/** - * @author William Piers - * @since 1.1 - */ -public class PluginService { - - public List> getPluginTabs(EObject arg0) { - List keys = new ArrayList(); - List> res = new ArrayList>(); - PropertiesEditionContext editionContext = (PropertiesEditionContext)arg0; - for (Iterator iterator = editionContext.eAllContents(); iterator.hasNext();) { - EObject o = (EObject)iterator.next(); - if (o instanceof PropertiesEditionComponent) { - PropertiesEditionComponent pec = (PropertiesEditionComponent)o; - for (View view : getInvolvedViews(pec)) { - String key = getViewKey(view, pec); - if (!keys.contains(key)) { - List entry = new ArrayList(); - entry.add(view); - entry.add(pec); - res.add(entry); - keys.add(key); - } - } - } - } - return res; - } - - private Set getInvolvedViews(PropertiesEditionComponent pec) { - Set res = new LinkedHashSet(); - res.addAll(pec.getViews()); - for (ElementBindingReference rb : pec.getReferencedBinding()) { - res.addAll(rb.getBinding().getViews()); - } - return res; - } - - private String getViewKey(View view, PropertiesEditionComponent pec) { - if (view.getName().equals(pec.getName())) { - // or view.eInverse()->first().oclIsTypeOf(views::ViewReference)) // TODO recode condition - return "Base"; - } else { - return view.getName(); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/StringUtilService.java b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/StringUtilService.java deleted file mode 100644 index 0fee3c075..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/StringUtilService.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.codegen.services; - -/** - * This class is used to manipulate strings. - * - * @author Stephane Bouchet - * @since 1.1 - */ -public class StringUtilService { - - public String toUnicode(String input) { - StringBuffer buf = new StringBuffer(input.length()); - - for (int i = 0; i < input.length(); i++) { - char ch = input.charAt(i); - // Does the char need to be converted to unicode? - if ((ch >= 0x0020) && (ch <= 0x007e)) { - // No. - buf.append(ch); - } else { - // Yes. - buf.append("\\u"); - // Get hex value of the char. - String hex = Integer.toHexString(input.charAt(i) & 0xFFFF); - for (int j = 0; j < 4 - hex.length(); j++) - // Prepend zeros because unicode requires 4 digits - buf.append("0"); - buf.append(hex.toLowerCase()); // standard unicode format. - } - } - - return buf.toString(); - } - -// public String toASCII(String input) { -// return Normalizer.normalize(input, Normalizer.Form.NFD).replaceAll( -// "\\p{InCombiningDiacriticalMarks}+", ""); -// } -} diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/common.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/common.mtl deleted file mode 100644 index 060f80501..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/common.mtl +++ /dev/null @@ -1,522 +0,0 @@ -[comment encoding=UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module common('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::imports /] -[import org::eclipse::emf::eef::codegen::services::emfCodeGen /] - -[comment --------------- Common queries --------------- /] - -[comment Check if at least one views of the propertyBinding is contained by the given view /] -[query public involvedViews(pec : PropertiesEditionComponent) : OrderedSet(View) = - pec.views->asSequence()->union(pec.referencedBinding.binding.views->select(ancestors(View)->excludesAll(pec.views->asSequence())))->asOrderedSet()/] - -[query public involvedEditionElements(pec : PropertiesEditionComponent) : OrderedSet(PropertiesEditionElement) = - pec.properties->asSequence()->union(pec.referencedBinding.binding.properties)->asOrderedSet()/] - -[query public editionContext(pec : PropertiesEditionComponent) : PropertiesEditionContext = - if (pec.ancestors()->select(oclIsTypeOf(PropertiesEditionContext))->notEmpty()) then - pec.ancestors()->select(oclIsTypeOf(PropertiesEditionContext))->first() - else null - endif/] - -[query public owningView(element : ViewElement) : View = - if (element.oclIsKindOf(View)) - then element.oclAsType(View) - else element.container.owningView() - endif/] - -[query public owningViewString(element : ViewElement) : String = - if (element.oclIsKindOf(View)) - then element.oclAsType(View).name.toJavaClassifier() - else element.container.owningViewString() - endif/] - -[query public hasOwningViewsRepository(view : View) : Boolean = view.ancestors(ViewsRepository)->notEmpty()/] - -[query public owningViewsRepository(view : View) : ViewsRepository = - if (view.hasOwningViewsRepository()) then - view.ancestors(ViewsRepository)->first() - else null - endif/] - -[query public owningViewsRepository(element : ViewElement) : ViewsRepository = - element.owningView().owningViewsRepository()/] - -[query public referencedViews(view : View) : Sequence(View) = - view.eAllContents(ViewReference).view->select(oclIsTypeOf(View))/] - -[query public ownedBy(element : ViewElement, view : View) : Boolean = - element.owningView() = view/] - -[query public involvedEditionElementsInView(pec : PropertiesEditionComponent, v : View) : OrderedSet(PropertiesEditionElement) = - pec.involvedEditionElements()->select(views->first().ownedBy(v))/] - -[query public propertiesEditionElement(element : ElementEditor, pec : PropertiesEditionComponent) : PropertiesEditionElement = - pec.properties->select(views->includes(element))->first().oclAsType(PropertiesEditionElement)/] - -[query public relatedComponent(view : View, pec : PropertiesEditionComponent) : PropertiesEditionComponent = - if (pec.views->includes(view)) - then pec.oclAsType(PropertiesEditionComponent) - else pec.referencedBinding.binding->select(views->includes(view))->first().oclAsType(PropertiesEditionComponent) - endif/] - -[query public fullPartInterfacePath(pepCompletePackage : String, pepInterface : String) : String = - pepCompletePackage.concat('.parts.').concat(pepInterface)/] - -[query public associatedGenFeature(pee : PropertiesEditionElement) : GenFeature = - let genFeatures : OrderedSet(GenFeature) = pee.model.eInverse(GenFeature) in - if genFeatures->isEmpty() then null else genFeatures->first() endif/] - -[query public associatedGenPackage(p : EPackage) : GenPackage = - p.eInverse(GenPackage)->first()/] - -[query public associatedGenPackage(pec : PropertiesEditionComponent) : GenPackage = - pec.model.ePackage.associatedGenPackage()/] - -[query public associatedGenContext(peco : PropertiesEditionContext) : GenEditionContext = - peco.eInverse(GenEditionContext)->first()/] - -[query public associatedGenContext(pec : PropertiesEditionComponent) : GenEditionContext = - pec.editionContext().associatedGenContext() /] - -[query public associatedGenModel(pec : PropertiesEditionContext) : EEFGenModel = - pec.associatedGenContext().eefGenModel/] - -[query public associatedEMFGenModel(pec : PropertiesEditionContext, ePackage : EPackage) : GenPackage = - if (pec.model.ecorePackage = ePackage) - then pec.model - else if (pec.model.eAllContents(GenPackage)->select(p : GenPackage | p.ecorePackage = ePackage)->size() > 0) - then pec.model.eAllContents(GenPackage)->select(p : GenPackage | p.ecorePackage = ePackage)->first() - else null - endif - endif/] - -[query public associatedGenRepository(view : View) : GenViewsRepository = - view.owningViewsRepository().associatedGenRepository()/] - -[query public associatedGenRepository(viewsRepository : ViewsRepository) : GenViewsRepository = - viewsRepository.eInverse(GenViewsRepository) -> first()/] - -[query public associatedGenModel(viewsRepository : ViewsRepository) : EEFGenModel = - if not viewsRepository.associatedGenRepository().oclIsUndefined() - then viewsRepository.associatedGenRepository().eefGenModel - else null - endif/] - -[query public associatedPEC(eclass : EClass, peContext : PropertiesEditionContext) : PropertiesEditionComponent = if eclass.eInverse(PropertiesEditionComponent)->isEmpty() then null else eclass.eInverse(PropertiesEditionComponent)->first() endif/] - -[query public significantClass(ePackage : EPackage) : Set(EClass) = ePackage.eClassifiers->filter(EClass).classAndHierarchy()->asOrderedSet() /] - -[query private classAndHierarchy(eclass : EClass) : Set(EClass) = eclass.eSuperTypes.classAndHierarchy()->including(eclass)->asOrderedSet() /] - - -[comment Defines if a SubPropertiesEditionComponent must be generated. A SubPropertiesEdtionComponent must be generated if : - - its 'explicit' property is set to true - - A ElementBindingReference reference it and it contains at least 1 PEE/] -[query public mustBeGenerated(pec : PropertiesEditionComponent) : Boolean = - (pec.explicit and (pec.eAllContents(PropertiesEditionElement)->notEmpty() or pec.referencedBinding->notEmpty())) or pec.eInverse(ElementBindingReference)->notEmpty()/] - -[comment Defines if a ComposedPropertiesEditionComponent must be generated. A ComposedPropertiesEditionComponent must be generated if : - - its 'explicit' property is set to true and it has more than 1 view to manage - - the component has to manage only reference binding /] -[query public needComposedEditionComponent(pec : PropertiesEditionComponent) : Boolean = - (pec.explicit and pec.involvedViews()->size() > 1) or (pec.views->isEmpty() and pec.involvedViews()->notEmpty())/] - -[comment Defines if a DynamicPropertiesEditionComponent must be generated. A DynamicPropertiesEdtionComponent must be generated if : - - its 'explicit' property is set to true - - the given view is a dynamic view /] -[query public mustDynamicPecBeGenerated(pec : PropertiesEditionComponent, view : View) : Boolean = - pec.explicit and view.isDynamicView()/] - -[comment A view is Dynamic if it have subViews ... /] -[query public isDynamicView(view : View) : Boolean = - view.elements->filter(View)->notEmpty()/] - -[query public dynamicViews(pec : PropertiesEditionComponent, topLevelView : View) : Sequence(View) = - pec.referencedBinding.binding->filter(PropertiesEditionComponent)->select(mustBeGenerated()).views->select(ancestors()->includes(topLevelView))/] - -[comment TODOGLF: List of parts that a component have to manage/] -[query public partToManage(pec : PropertiesEditionComponent) : OrderedSet(View) = pec.involvedViews()/] - -[query public mustBeGenerated(view : View, pec : PropertiesEditionComponent) : Boolean = - view.oclAsType(EObject).eResource() = pec.oclAsType(EObject).eResource()/] - -[query public needBeGenerated(ref : ViewReference) : Boolean = - if (ref.view.oclIsTypeOf(View)) - then not ref.view.oclAsType(View).involvedPropertiesEditionComponent().oclIsUndefined() - else false - endif/] - -[query public isA1stLevelReferencedView(toCheck : View, pec : PropertiesEditionComponent) : Boolean = - pec.views.eAllContents(ViewReference).view->filter(View)->includes(toCheck)/] - -[comment ----- StructuralFeatures classification ----- /] -[query public isReferenceMany(feature : EStructuralFeature) : Boolean = - feature.oclIsTypeOf(EReference) - and not (feature.oclAsType(EReference).containment) - and feature.many/] - -[query public isReferenceSingle(feature : EStructuralFeature) : Boolean = - feature.oclIsTypeOf(EReference) - and not (feature.oclAsType(EReference).containment) - and not (feature.many)/] - -[query public isContainment(feature : EStructuralFeature) : Boolean = - feature.oclIsTypeOf(EReference) - and feature.oclAsType(EReference).containment/] - -[query public isContainmentMany(feature : EStructuralFeature) : Boolean = - feature.oclIsTypeOf(EReference) - and feature.oclAsType(EReference).containment - and feature.many/] - -[query public isContainmentSingle(feature : EStructuralFeature) : Boolean = - feature.oclIsTypeOf(EReference) - and feature.oclAsType(EReference).containment - and not (feature.many)/] - -[query public isAttributeMany(feature : EStructuralFeature) : Boolean = - feature.oclIsTypeOf(EAttribute) - and feature.many/] - -[query public isAttributeSingle(feature : EStructuralFeature) : Boolean = - feature.oclIsTypeOf(EAttribute) - and not (feature.many)/] - -[comment ---- Views related queries ----- /] -[query public representationName(editionElement : PropertiesEditionElement, nameToCheck : String) : Boolean = - editionElement.views->first().representationName(nameToCheck)/] - -[query public representationName(view : ViewElement, nameToCheck : String) : Boolean = - if view.representation.name.oclIsUndefined() - then false - else view.representation.name = nameToCheck - endif/] - -[comment ----- Editor ID queries ---------/] -[query public editorIDSequence(editorElement : IdentifiedElement) : Sequence(String) = - editorElement.qualifiedIdentifier.tokenize('::')/] - -[query public identifiedElementKey(editorElement : IdentifiedElement) : String = - editorElement.qualifiedIdentifier.tokenize('::')->last()/] - -[comment ----- Model Navigation ---------/] -[query public hasModelNavigation(pee : PropertiesEditionElement) : Boolean = - not pee.navigation.oclIsUndefined()/] - -[query public canGeneratemodelNavigation(pee : PropertiesEditionElement) : Boolean = - pee.hasModelNavigation() and not pee.handleByOldReferenceSettingsSystem()/] - -[query public handleByOldReferenceSettingsSystem(pee : PropertiesEditionElement) : Boolean = - (pee.hasModelNavigation() and - ((pee.representationName('FlatReferencesTable')) - or (pee.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and ( - (pee.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentMany() and pee.model.isReferenceSingle() and (pee.representationName('ReferencesTable') or pee.representationName('AdvancedReferencesTable'))) - or (pee.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and pee.model.isReferenceMany() and (pee.representationName('ReferencesTable') or pee.representationName('AdvancedReferencesTable'))) - or (pee.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and pee.model.isContainmentMany() and (pee.representationName('TableComposition') or pee.representationName('AdvancedTableComposition'))) - or (pee.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentMany() and pee.model.isContainmentSingle() and (pee.representationName('TableComposition') or pee.representationName('AdvancedTableComposition'))) - or (pee.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and pee.model.isReferenceSingle() and (pee.representationName('EObjectFlatComboViewer') or pee.representationName('AdvancedEObjectFlatComboViewer') or pee.representationName('LinkEObjectFlatComboViewer') or pee.representationName('LinkERefenceViewer'))) - ))) or (pee.model.isContainmentSingle() and (pee.representationName('EObjectFlatComboViewer') or pee.representationName('AdvancedEObjectFlatComboViewer') or pee.representationName('LinkEObjectFlatComboViewer') or pee.representationName('LinkEReferenceViewer'))))/] - -[comment ----- Editor settings ---------/] -[query public canGenerateEditorSettings(pee : PropertiesEditionElement) : Boolean = - not pee.editorSetting.oclIsUndefined()/] - -[comment --------------- Common templates --------------- /] - -[query public ecoreGenModelAnnotation(modelElement : EModelElement) : OrderedSet(EAnnotation) = - modelElement.eAnnotations->select(annot : EAnnotation | annot.source = 'http://www.eclipse.org/emf/2002/GenModel')/] - -[query public ecoreDocumentationAnnotation(modelElement : EModelElement) : Sequence(EStringToStringMapEntry) = - modelElement.ecoreGenModelAnnotation()->first().details.oclAsType(EStringToStringMapEntry) - ->select(entry : EStringToStringMapEntry | entry.key = 'documentation')/] - -[query public ecoreHelp(modelElement : EModelElement) : String = - if (modelElement.ecoreGenModelAnnotation()->size() = 1) - then if (modelElement.ecoreDocumentationAnnotation()->size() = 1) - then modelElement.ecoreDocumentationAnnotation()->first().value.replaceAll('"','\\"').replaceAll('\n','').replaceAll('\r','') - else null - endif - else null - endif/] - -[template public helpText(pee : PropertiesEditionElement)] -[if (not pee.views->first().owningViewsRepository().associatedGenRepository().oclIsUndefined())] -[if (pee.views->first().owningViewsRepository().associatedGenRepository().helpStrategy = HELP_STRATEGY::GENMODEL)] -[if ((not pee.associatedGenFeature().oclIsUndefined()) and (not pee.associatedGenFeature().propertyDescription.oclIsUndefined()))]"[pee.associatedGenFeature().propertyDescription.replaceAll('"','\\"')/]"[else]null[/if] -[elseif (pee.views->first().owningViewsRepository().associatedGenRepository().helpStrategy = HELP_STRATEGY::ECOREMODEL)] -[if (pee.model.ecoreHelp().oclIsUndefined())]"[pee.model.ecoreHelp().trim()/]"[else]null[/if] -[/if] -[/if] -[/template] - -[template public licenceText(eefGenModel : EEFGenModel)] -[if (not eefGenModel.license.oclIsUndefined())] -[eefGenModel.license/] -[else] -/** - * Generated with Acceleo - */ -[/if] -[/template] - -[template public propertiesLicenceText(eefGenModel : EEFGenModel)] -[if (not eefGenModel.license.oclIsUndefined())] -[eefGenModel.license.replaceAll('/\\*\\*', '##').replaceAll('\\*/', '#').replaceAll(' \\*', '#').replaceAll('\\*', '#')/] -[else] -# -# Generated with Acceleo -# -[/if] -[/template] - -[template public generationMark(eefGenModel : EEFGenModel) ] -[if (eefGenModel.useJMergeForUserCode)]@generated[/if] -[/template] - -[template public generationComment(eefGenModel : EEFGenModel) ] -[if (eefGenModel.useJMergeForUserCode)] -/** - * [eefGenModel.generationMark()/] - */ -[/if] -[/template] - -[template public authorText(eefGenModel : EEFGenModel)] -[if (not eefGenModel.author.oclIsUndefined())] -@author [eefGenModel.author/] -[/if] -[/template] - -[comment --------------- View Common templates --------------- /] -[template public viewCompletePackageGetter(view : ViewElement)] -[view.viewPackageGetter()/]() -[/template] - -[template public viewPackageGetter(view : ViewElement)] -get[view.viewPackageSignature()/] -[/template] - -[template public viewPackageSignature(view : ViewElement)] -[view.name.toJavaClassifier()/] -[/template] - -[template public viewPackageSetter(view : ViewElement)] -set[view.viewPackageSignature()/] -[/template] - -[template public viewCompletePackageSetter(view : ViewElement)] -[view.viewPackageSetter()/]([view.toJavaType().trim()/] newValue) -[/template] - -[template public toJavaType(view : ViewElement)] -[if (view.representationName('Text') or view.representationName('Textarea') or view.representationName('RichText') or view.representationName('ImageViewer') or view.representationName('SelectionDialog'))] -String -[elseif (view.representationName('EMFComboViewer'))] -[include('org.eclipse.emf.common.util.Enumerator')/] -[elseif (view.representationName('MultiValuedEditor'))] -[include('org.eclipse.emf.common.util.EList')/] -[elseif (view.representationName('EObjectFlatComboViewer') or view.representationName('LinkEReferenceViewer')or view.representationName('LinkEObjectFlatComboViewer') or view.representationName('AdvancedEObjectFlatComboViewer') or view.representationName('SingleCompositionViewer') or view.representationName('SingleCompositionEditor'))] -[include('org.eclipse.emf.ecore.EObject')/] -[elseif (view.representationName('ReferencesTable') or view.representationName('AdvancedReferencesTable') or view.representationName('FlatReferencesTable') or view.representationName('TableComposition') or view.representationName('AdvancedTableComposition'))] -[include('java.util.List')/] -[elseif (view.representationName('Checkbox'))] -Boolean -[elseif (view.representationName('Radio'))] -[comment can be used for Enums or Boolean/] -Object -[elseif (view.representationName('Combo'))] -[comment can be used for References, Enums or Boolean/] -Object -[else] -//FIXME ERROR INVALID CASE INTO template public toJavaType(view : ViewElement) in common.mtl module for representation [view.representation.name/] -[/if] -[/template] - -[query public toPath(s : String) : String = s.substituteAll('.', '/')/] - -[comment][query public toASCII(s : String) : String - = invoke('org.eclipse.emf.eef.codegen.services.StringUtilService', 'toASCII(java.lang.String)', Sequence{s}) /][/comment] - -[query public toUnicode(s : String) : String - = invoke('org.eclipse.emf.eef.codegen.services.StringUtilService', 'toUnicode(java.lang.String)', Sequence{s}) /] - -[template public toASCII(s : String)] -[s.substituteAll('à', 'a') - .substituteAll('é', 'e') - .substituteAll('è', 'e') - .substituteAll('ê', 'e') - .substituteAll('ë', 'e') - .substituteAll('ï', 'i') - .substituteAll('î', 'i') - .substituteAll('ö', 'o') - .substituteAll('ô', 'o') - .substituteAll('ù', 'u') - .substituteAll('ü', 'u') - .substituteAll('û', 'u') - .substituteAll('-', '')/] -[/template] - -[comment] template used for the properties files to handle accents -DEPRECATED. using now a java service to do so. -[template public toUnicode(s : String)] -[s.substituteAll('à', '\\u00E0').substituteAll('À', '\\u00C0') - .substituteAll('á', '\\u00E1').substituteAll('Ã', '\\u00C1') - .substituteAll('â', '\\u00E2').substituteAll('Â', '\\u00C2') - .substituteAll('ä', '\\u00E4').substituteAll('Ä', '\\u00C4') - .substituteAll('æ', '\\u00E6').substituteAll('Æ', '\\u00C6') - .substituteAll('ç', '\\u00E7').substituteAll('Ç', '\\u00C8') - .substituteAll('é', '\\u00E9').substituteAll('É', '\\u00C9') - .substituteAll('ê', '\\u00EA').substituteAll('Ê', '\\u00CA') - .substituteAll('ë', '\\u00EB').substituteAll('Ë', '\\u00CC') - .substituteAll('í', '\\u00EC').substituteAll('Ã', '\\u00CC') - .substituteAll('î', '\\u00EE').substituteAll('ÃŽ', '\\u00CE') - .substituteAll('ï', '\\u00EF').substituteAll('Ã', '\\u00CF') - .substituteAll('ñ', '\\u00F1').substituteAll('Ñ', '\\u00D1') - .substituteAll('ò', '\\u00F2').substituteAll('Ã’', '\\u00D2') - .substituteAll('ó', '\\u00F3').substituteAll('Ó', '\\u00D3') - .substituteAll('ô', '\\u00F4').substituteAll('Ô', '\\u00D4') - .substituteAll('ö', '\\u00F6').substituteAll('Ö', '\\u00D6') - .substituteAll('ù', '\\u00F9').substituteAll('Ù', '\\u00D9') - .substituteAll('ú', '\\u00FA').substituteAll('Ú', '\\u00DA') - .substituteAll('û', '\\u00FB').substituteAll('Û', '\\u00DB') - .substituteAll('ü', '\\u00FC').substituteAll('Ü', '\\u00DC') - .substituteAll('Å“', '\\u0153').substituteAll('Å’', '\\u0152') - .substituteAll('«', '\\u00AB').substituteAll('»', '\\u00BB') - .substituteAll('$', '\\u0024').substituteAll('€', '\\u20AC') - .substituteAll('\'', '\\u0027')/] -[/template][/comment] - -[comment Sequence{1..s.size()}-> - iterate(i; result : String = "" | - if i = 1 then result.concat(s.substring(i,i).toLower()) - else if s.substring(i,i) = " " then result - else result.concat(s.substring(i,i)) - endif - ) /] - -[comment TODO: fixed in Acceleo 3.0.0M7/] -[query public startsWithADigit(s : String) : Boolean = not s.first(1).isAlpha()/] -[comment][query public startsWithADigit(s : String) : Boolean = - s.firstChar() = '0' - or s.firstChar() = '1' - or s.firstChar() = '2' - or s.firstChar() = '3' - or s.firstChar() = '4' - or s.firstChar() = '5' - or s.firstChar() = '6' - or s.firstChar() = '7' - or s.firstChar() = '8' - or s.firstChar() = '9'/] - -[template public firstChar(s : String)] -[if (s.oclIsUndefined())][''/][elseif (s = '')][''/][else][s.substring(1,1)/][/if] -[/template] -[/comment] - -[template public toJavaIdentifierDelegate(s : String)] -[if (s.startsWithADigit())]_[/if][for (str : String | s.toASCII().tokenize(' '))][str.toUpperFirst()/][/for] -[/template] - -[comment === escape some special keywords (java and EEF) /] -[query public toJavaIdentifier(s : String) : String = s.toJavaIdentifierDelegate().toLowerFirst().replaceKeywords()/] - -[query public replaceKeywords(s : String) : String = s.replaceAll('(?i)^((title)|(parent)|(abstract)|(continue)|(for)|(new)|(switch)|(assert)|(default)|(goto)|(package)|(synchronized)|(boolean)|(do)|(if)|(private)|(this)|(break)|(double)|(implements)|(protected)|(throw)|(byte)|(else)|(import)|(public)|(throws)|(case)|(enum)|(instanceof)|(return)|(transient)|(catch)|(extends)|(int)|(short)|(try)|(char)|(final)|(interface)|(static)|(void)|(class)|(finally)|(long)|(strictfp)|(volatile)|(const)|(float)|(native)|(super)|(while))$','$1_')/] - -[query public toJavaClassifier(s : String) : String = s.toJavaIdentifierDelegate().replaceKeywords().toUpperFirst()/] - -[query public toJavaMetamodelIdentifier(s : String) : String = s.replaceAll('^(Class)$','$1_')/] - -[query public toJavaConstant(s: String) : String = s.toJavaIdentifierDelegate().replaceKeywords().toUpper()/] - -[comment ==== For multiples model features getters (thanks to UML !) ==== /] -[template public toMany(s: String)] -[s/] -[/template] - -[comment ==== For boolean model features getters (thanks to UML !) ==== /] -[template public booleanGetter(feature : EStructuralFeature)] -[if (feature.eType.name() = 'EBooleanObject')]get[else]is[/if] -[/template] - -[query public eefPackage(eClassifier : EClassifier, basePackage : String) : String = eClassifier.ePackage.eefPackage(basePackage)/] - -[template public eefPackage(ePackage : EPackage, basePackage : String)] -[if ((not ePackage.associatedGenPackage().basePackage.oclIsUndefined()) and (ePackage.associatedGenPackage().basePackage.size() > 0))][basePackage/].[/if][ePackage.name/] -[/template] - -[comment queries for model navigation /] -[query public simpleModelNavigationType(modelNavigation : SimpleModelNavigation) : String = - if (modelNavigation.discriminatorType.oclIsUndefined()) - then modelNavigation.feature.eType.name - else modelNavigation.discriminatorType.name - endif/] - -[query public simpleModelNavigationMetamodelFactory(modelNavigation : SimpleModelNavigation) : String = - if (modelNavigation.discriminatorType.oclIsUndefined()) - then modelNavigation.feature.eType.ePackage.metamodelPrefix() - else modelNavigation.discriminatorType.ePackage.metamodelPrefix() - endif/] - -[comment] -@param PropertiesEditionElement the PEE of the composition -@param EStructuralFeature : the feature of the composition -[/comment] -[query public involvedPropertiesEditionElement(peElement : PropertiesEditionElement, f : EStructuralFeature) : PropertiesEditionElement = - peElement.element.category.eContainer(PropertiesEditionContext).categories.bindings->select(oclIsTypeOf(PropertiesEditionComponent)).oclAsType(PropertiesEditionComponent).properties->select(oclIsTypeOf(PropertiesEditionElement)).oclAsType(PropertiesEditionElement)->select(pee : PropertiesEditionElement | pee.model=f)->first()/] - -[query public involvedPropertiesEditionElement(element : ElementEditor) : PropertiesEditionElement = - element.eInverse(PropertiesEditionElement)->first()/] - -[query public involvedPropertiesEditionElement(view : ViewElement, pec : PropertiesEditionComponent) : PropertiesEditionElement = - pec.involvedEditionElements()->select(views.oclAsType(ViewElement)->includes(view))->first()/] - -[query public involvedPropertiesEditionComponent(view : View) : PropertiesEditionComponent = - view.eInverse(PropertiesEditionComponent)->first()/] - -[comment ==== Metamodel getters, with imports management ==== /] -[comment -NOTE: Imports are managed here because addImport must be called from a model element from the currently generated model. -/] - -[template public metamodelGetter(p : PropertiesEditionComponent)] -[p.model.metamodelGetter()/][p.addImport(p.model.ePackage.qualifiedMetamodelPackage())/] -[/template] - -[template public metamodelGetter(p : PropertiesEditionElement)] -[p.model.metamodelGetter()/][p.addImport(p.model.eContainingClass.ePackage.qualifiedMetamodelPackage())/] -[/template] - -[template public metamodelTypeGetter(p : PropertiesEditionElement)] -[p.model.eType.metamodelGetter()/][p.addImport(p.model.eType.ePackage.qualifiedMetamodelPackage())/] -[/template] - -[template public metamodelGetter(s : SimpleModelNavigation)] -[s.feature.metamodelGetter()/][s.addImport(s.feature.eContainingClass.ePackage.qualifiedMetamodelPackage())/] -[/template] - -[template public metamodelGetter(s : DeclarativeNavigationStep)] -[s.feature.metamodelGetter()/][s.addImport(s.feature.eContainingClass.ePackage.qualifiedMetamodelPackage())/] -[/template] - -[template public metamodelGetter(e : EReferenceViewerSettings) post (trim())] -[if (e.model.eInverse(GenFeature).genClass.genPackage.genModel.toString() <> e.getImportGenModel())] - [e.initializeImportManagerForGenmodel(e.model.eInverse(GenFeature)->first().genClass.genPackage.genModel, '', '')/] -[/if] -[e.model.metamodelGetter()/][e.addImport(e.model.eContainingClass.ePackage.qualifiedMetamodelPackage())/] -[/template] - -[template public factoryCreator(p : PropertiesEditionElement)] -[p.model.eType.factoryCreator()/][p.addImport(p.model.eType.getQualifiedFactoryInterfaceName())/] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/emfCodeGen.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/emfCodeGen.mtl deleted file mode 100644 index e97a21f92..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/emfCodeGen.mtl +++ /dev/null @@ -1,145 +0,0 @@ -[comment encoding=UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module emfCodeGen('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::services::imports /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenPackage /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClass /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenClassifier /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenFeature /] -[import org::eclipse::emf::eef::codegen::ecore::services::wrappers::GenDataType /] - -[comment -------------------------------------------------------------------------- - Names - ---------------------------------------------------------------------------------- /] - -[template public metamodelPackage(ePackage : EPackage)] -[ePackage.getGenPackage().getPackageInterfaceName()/] -[/template] - -[template public qualifiedMetamodelPackage(ePackage : EPackage)] -[if (ePackage.nsURI='http://www.eclipse.org/emf/2003/XMLType')] -org.eclipse.emf.ecore.xml.type.XMLTypePackage -[else] -[ePackage.getGenPackage().getQualifiedPackageInterfaceName()/] -[/if] -[/template] - -[template public completePackage(ePackage : EPackage)] -[ePackage.getGenPackage().getQualifiedPackageName()/] -[/template] - -[template public getQualifiedFactoryInterfaceName(eClassifier : EClassifier)] -[eClassifier.ePackage.getGenPackage().getQualifiedFactoryInterfaceName()/] -[/template] - -[query public metamodelPrefix(ePackage : EPackage) : String = ePackage.getGenPackage().prefix/] - -[query public name(eClassifier : EClassifier) : String = let qualifiedName : String = eClassifier.qualifiedName() in -qualifiedName.substring(qualifiedName.lastIndex('.') + 1)/] - - [query public qualifiedName(eClassifier : EClassifier) : String = -if eClassifier.oclIsTypeOf(EClass) - then - let genClass : GenClass = eClassifier.oclAsType(EClass).getGenClass() in - genClass.getQualifiedInterfaceName() - else eClassifier.ePackage.completePackage() + '.' + eClassifier.name -endif/] - -[comment -------------------------------------------------------------------------- - Accessors - ---------------------------------------------------------------------------------- /] - -[template public metamodelGetter(eClassifier : EClassifier)] -[eClassifier.eInverse(GenClassifier).getQualifiedClassifierAccessor()/] -[/template] - -[template public metamodelGetter(eDataType : EDataType) post (trim())] -[if (self.ePackage.nsURI='http://www.eclipse.org/emf/2003/XMLType')] -XMLTypePackage.Literals.[eDataType.getFormattedName()/] -[else] -[eDataType.getGenDataType().getQualifiedClassifierAccessor()/] -[/if] -[/template] - -[template public metamodelGetter(eClass : EClass)] -[eClass.getGenClass().getQualifiedClassifierAccessor()/] -[/template] - -[template public metamodelGetter(e : EStructuralFeature)] -[e.getGenFeature().getQualifiedFeatureAccessorName()/]() -[/template] - -[template public metamodelGetter(e : EReference)] -[e.getGenFeature().getQualifiedFeatureAccessorName()/]() -[/template] - -[template public metamodelStrictFilterGetter(eClass : EClassifier) post (trim())] -[if (eClass.eInverse(GenClassifier).oclAsType(GenClassifier).genPackage.genModel->first().toString() <> eClass.getImportGenModel())] - [eClass.initializeImportManagerForGenmodel(eClass.eInverse(GenClassifier).oclAsType(GenClassifier).genPackage.genModel->first(), '', '')/] -[/if] -[eClass.eInverse(GenClassifier).getQualifiedClassifierAccessor()/] -[/template] - -[template public factoryCreator(eClassifier : EClassifier) post (trim())] -[if (eClassifier.oclIsTypeOf(EClass))] -[let genClass : GenClass = eClassifier.oclAsType(EClass).getGenClass()] -[if (genClass.isMapEntry())] - [genClass.genPackage.getQualifiedEFactoryInstanceAccessor()/].create([genClass.getQualifiedClassifierAccessor()/]) -[else] - [genClass.genPackage.getQualifiedFactoryInstanceAccessor()/].create[genClass.getName()/]() -[/if] -[/let] -[/if] -[/template] - -[template public ecorePackageSignature(e : EStructuralFeature)] -[e.getGenFeature().getFeatureAccessorName()/] -[/template] - -[comment -------------------------------------------------------------------------- - Utilities to retrieve EMF Gen elements - ---------------------------------------------------------------------------------- /] - -[query private getEcoreGenModel(arg0 : EObject) : GenModel - = invoke('org.eclipse.emf.eef.codegen.services.EcoreService', 'getEcoreGenModel(org.eclipse.emf.ecore.EObject)', Sequence{arg0}) /] - -[query private getGenPackage(ePackage : EPackage) : GenPackage = -if ePackage.nsURI = 'http://www.eclipse.org/emf/2002/Ecore' - then self.getEcoreGenModel().genPackages -> first() - else self.eInverse(GenPackage) -> first() -endif/] - -[comment]NOTE: in the ecore case, as the metamodel and genmodel cannot be in the same resourceSet, we use a basic name comparison[/comment] -[query private getGenFeature(eStructuralFeature : EStructuralFeature) : GenFeature = -if self.eContainingClass.ePackage.nsURI = 'http://www.eclipse.org/emf/2002/Ecore' - then self.eContainingClass.getGenClass().genFeatures -> select(ecoreFeature.name = eStructuralFeature.name) -> first() - else self.eInverse(GenFeature) -> first() -endif/] - -[comment]NOTE: in the ecore case, as the metamodel and genmodel cannot be in the same resourceSet, we use a basic name comparison[/comment] -[query private getGenClass (eClass : EClass) : GenClass = -if self.ePackage.nsURI = 'http://www.eclipse.org/emf/2002/Ecore' - then self.ePackage.getGenPackage().genClasses -> select(ecoreClass.name = eClass.name) -> first() - else self.eInverse(GenClass) -> first() -endif/] - -[comment]NOTE: in the ecore case, as the metamodel and genmodel cannot be in the same resourceSet, we use a basic name comparison[/comment] -[query private getGenDataType(eDataType : EDataType) : GenDataType = -if self.ePackage.nsURI = 'http://www.eclipse.org/emf/2002/Ecore' - then self.ePackage.getGenPackage().genDataTypes -> select(ecoreDataType.name = eDataType.name) -> first() - else self.eInverse(GenDataType) -> first() -endif/] - -[query public getFormattedName(e : EDataType) : String - = invoke('org.eclipse.emf.eef.codegen.services.EcoreService', 'getFormattedName(java.lang.String)', Sequence{e.name}) /] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/filters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/filters.mtl deleted file mode 100644 index 7f9365f7e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/filters.mtl +++ /dev/null @@ -1,98 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module filters('http://www.eclipse.org/emf/eef/mapping/filters/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] -[import org::eclipse::emf::eef::codegen::services::emfCodeGen /] - -[template public filterBody(bindingFilter : BindingFilter, editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] -// FIXME default case for filter body generation. -[/template] - -[template public filterBody(bindingFilter : StrictTypingFilter, editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] -[comment Do nothing. Here to avoid FIXME tag generation /] -[/template] - -[template public filterBody(filter : JavaDeclarationFilter, editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - return [filter.methodName/](viewer, parentElement, element); - } - - }); -[/template] - -[template public filterBody(filter : JavaExpressionFilter, editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - [if (filter.javaBody->size()> 0)][filter.javaBody/][else]return false;[/if] - } - - }); -[/template] - -[template public filterBody(filter : OnlyReferenceTypeFilter, editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - Object result = [include('org.eclipse.emf.eef.runtime.impl.utils.EEFUtils')/].choiceOfValues([pec.subPECClass(view)/].this.semanticObject, [filter.reference.metamodelGetter()/][addImport(filter.reference.eContainingClass.ePackage.qualifiedMetamodelPackage())/]); - if (result instanceof [include('java.util.Collection')/]) { - return ((Collection)result).contains(element); - } else if (result instanceof ResourceSet && element instanceof EObject) { - return ((EObject)element).eResource() != null && ((EObject)element).eResource().getResourceSet() != null && ((EObject)element).eResource().getResourceSet().equals(result); - } - return element instanceof [include('org.eclipse.emf.ecore.resource.Resource')/]; - } - }); -[/template] - -[template public filterBody(bindingFilter : OCLFilter, editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] - // OCLFilter not implemented yet -[/template] - -[template public javaDeclarationFilter(pee : PropertiesEditionElement)] -[for (bindingFilter : JavaDeclarationFilter | pee.bindingFilters->filter(JavaDeclarationFilter)) separator ('\n')] - /** - * [bindingFilter.documentation/] - */ - private boolean [bindingFilter.methodName/](Viewer viewer, Object parentElement, Object element){ - [if (pee.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - return true; - [else] - // [protected ('for user filter '.concat(bindingFilter.methodName))] - return true; - // [/protected] - [/if] - } -[/for] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/imports.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/imports.mtl deleted file mode 100644 index bcfc69151..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/imports.mtl +++ /dev/null @@ -1,107 +0,0 @@ -[comment encoding=UTF-8 - ******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module imports('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel')/] - -[comment ************ IMPORT MANAGER ****************************************** /] - -[** - * Initializes an import manager for the given class. - * - * WARNING: Using a template is mandatory to avoid queries cache side effects - * - * @param caller any EObject from the components model - * @param packageName the package of the generated class - * @param className the generated class name - */] -[template public initializeImportManager(caller : EObject, packageName : String, className : String) post (trim())] -[invoke( - 'org.eclipse.emf.eef.codegen.services.ImportService', - 'initializeImportManager(org.eclipse.emf.ecore.EObject,java.lang.String,java.lang.String)', - Sequence{caller, packageName, className}) /] -[/template] - -[** - * Adds an import sequence. - * - * WARNING: Using a template is mandatory to avoid queries cache side effects - * - * @param caller any EObject from the components model - * @param qualifiedNames the imports qualified names - */] -[template public addImports(caller : EObject, qualifiedNames : Collection(String)) post (trim())] -[for (qualifiedName : String | qualifiedNames)] -[invoke( - 'org.eclipse.emf.eef.codegen.services.ImportService', - 'addImport(org.eclipse.emf.ecore.EObject, java.lang.String)', - Sequence{caller, qualifiedName}) /] -[/for] -[/template] - -[** - * Adds an import. - * - * WARNING: Using a template is mandatory to avoid queries cache side effects - * - * @param caller any EObject from the components model - * @param qualifiedNames the imports qualified names - */] -[template public addImport(caller : EObject, qualifiedName : String) post (trim())] -[invoke( - 'org.eclipse.emf.eef.codegen.services.ImportService', - 'addImport(org.eclipse.emf.ecore.EObject, java.lang.String)', - Sequence{caller, qualifiedName}) /] -[/template] - -[** - * Includes an import, i.e. add it to the import manager and returns the class name. - * - * WARNING: Using a template is mandatory to avoid queries cache side effects - * - * @param caller any EObject from the components model - * @param qualifiedName the import qualified name - */] -[template public include(caller : EObject, qualifiedName : String) post (trim())] -[invoke( - 'org.eclipse.emf.eef.codegen.services.ImportService', - 'addImport(org.eclipse.emf.ecore.EObject, java.lang.String)', - Sequence{caller, qualifiedName}) /][qualifiedName.substring(qualifiedName.lastIndex('.') + 1)/] -[/template] - -[** - * Generates the list of sorted imports - * - * WARNING: Using a template is mandatory to avoid queries cache side effects - * - * @param caller any EObject from the components model - */] -[template public genSortedImports(caller : EObject) post (trim())] -[invoke( - 'org.eclipse.emf.eef.codegen.services.ImportService', - 'genSortedImports(org.eclipse.emf.ecore.EObject)', - Sequence{caller}) /] -[/template] - -[template public getImportGenModel(caller : EObject) post (trim())] -[invoke( - 'org.eclipse.emf.eef.codegen.services.ImportService', - 'getGenModel(org.eclipse.emf.ecore.EObject)', - Sequence{caller}) /] -[/template] - -[comment To fix call of import manager in a genmodel which is not the genmodel used by the default import manager /] -[template public initializeImportManagerForGenmodel(caller : EObject, model : GenModel, packageName : String, className : String) post (trim())] -[invoke( - 'org.eclipse.emf.eef.codegen.services.ImportService', - 'initializeImportManagerForGenmodel(org.eclipse.emf.ecore.EObject, org.eclipse.emf.codegen.ecore.genmodel.GenModel,java.lang.String,java.lang.String)', - Sequence{caller, model, packageName, className}) /] -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/naming.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/naming.mtl deleted file mode 100644 index 35ae0ae4a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/naming.mtl +++ /dev/null @@ -1,333 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module naming('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/navigation/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0', 'http://www.eclipse.org/emf/2002/GenModel')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::imports /] -[import org::eclipse::emf::eef::codegen::services::emfCodeGen /] - -[comment -------------------------------------------------------------------------- - Master packages management - ---------------------------------------------------------------------------------- /] -[template public contextPackage(peContext : PropertiesEditionContext)] -[peContext.associatedGenContext().basePackage/] -[/template] - -[template public contextCompletePackage(peContext : PropertiesEditionContext)] -[if ((not peContext.associatedGenContext().basePackage.oclIsUndefined()) and (peContext.associatedGenContext().basePackage.size() > 0))][peContext.associatedGenContext().basePackage/].[/if][peContext.model.ecorePackage.name.replaceKeywords()/] -[/template] - -[template public vrPackage(repository : ViewsRepository) post (trim())] -[if ((not repository.associatedGenRepository().basePackage.oclIsUndefined()) and (repository.associatedGenRepository().basePackage.size() > 0))][repository.associatedGenRepository().basePackage/].[/if] -[/template] - -[comment -------------------------------------------------------------------------- - Components naming - ---------------------------------------------------------------------------------- /] -[template public componentsPackage(pec : PropertiesEditionComponent)] -[pec.editionContext().contextCompletePackage()/].components -[/template] - -[template public pecClass(pec : PropertiesEditionComponent)] -[pec.name.toUpperFirst()/]PropertiesEditionComponent -[/template] - -[template public pecQualifiedClass(pec : PropertiesEditionComponent)] -[pec.componentsPackage()/].[pec.pecClass()/] -[/template] - -[template public subPECClass(pec : PropertiesEditionComponent, view : View)] -[pec.name.toUpperFirst()/][if (pec.involvedViews()->size() > 1)][view.viewKey(pec).toJavaClassifier()/][/if]PropertiesEditionComponent -[/template] - -[template public subPECQualifiedClass(pec : PropertiesEditionComponent, view : View)] -[pec.componentsPackage()/].[pec.subPECClass(view)/] -[/template] - -[template public pecQualifiedComponentSuperClass(pec : PropertiesEditionComponent) post (trim())] -[if (pec.associatedGenContext().leafComponentsSuperClass.oclIsUndefined() or pec.associatedGenContext().leafComponentsSuperClass.size() = 0)] -org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent -[else] -[pec.associatedGenContext().leafComponentsSuperClass/] -[/if] -[/template] - -[template public pecComponentSuperClass(pec : PropertiesEditionComponent) post (trim())] -[if (pec.associatedGenContext().leafComponentsSuperClass.oclIsUndefined() or pec.associatedGenContext().leafComponentsSuperClass.size() = 0)] -SinglePartPropertiesEditingComponent -[else] -[pec.associatedGenContext().leafComponentsSuperClass.tokenize('.')->last()/] -[/if] -[/template] - - -[comment -------------------------------------------------------------------------- - Providers naming - ---------------------------------------------------------------------------------- /] -[template public providersPackage(pec : PropertiesEditionComponent)] -[pec.editionContext().contextCompletePackage()/].providers -[/template] - -[template public pecProviderClass(pec : PropertiesEditionComponent)] -[pec.name.toJavaClassifier()/]PropertiesEditionProvider -[/template] - -[template public pecProviderQualifiedClass(pec : PropertiesEditionComponent)] -[pec.providersPackage()/].[pec.pecProviderClass()/] -[/template] - -[template public providersPackage(pec : PropertiesEditionContext)] -[pec.contextCompletePackage()/].providers -[/template] - -[template public pecRootProviderQualifiedClass(pec : PropertiesEditionComponent) post (trim())] -[if (pec.associatedGenContext().propertiesEditingProvidersSuperClass.oclIsUndefined() or pec.associatedGenContext().propertiesEditingProvidersSuperClass.size() = 0)] -org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl -[else] -[pec.associatedGenContext().propertiesEditingProvidersSuperClass/] -[/if] -[/template] - -[template public pecRootProviderClass(pec : PropertiesEditionComponent) post (trim())] -[if (pec.associatedGenContext().propertiesEditingProvidersSuperClass.oclIsUndefined() or pec.associatedGenContext().propertiesEditingProvidersSuperClass.size() = 0)] -PropertiesEditingProviderImpl -[else] -[pec.associatedGenContext().propertiesEditingProvidersSuperClass.tokenize('.')->last()/] -[/if] -[/template] - -[template public pecPackageProviderClass(ePack : EPackage)] -[ePack.name.toJavaClassifier()/]EEFAdapterFactory -[/template] - -[template public pecPackageProviderClass(pec : PropertiesEditionContext)] -[pec.model.ecorePackage.pecPackageProviderClass()/] -[/template] - -[template public pecPackageProviderQualifiedClass(pec : PropertiesEditionContext, ePackage : EPackage)] -[pec.providersPackage()/].[ePackage.pecPackageProviderClass()/] -[/template] - -[comment -------------------------------------------------------------------------- - Parts naming - ---------------------------------------------------------------------------------- /] -[template public partsPackage(repository : ViewsRepository)] -[repository.vrPackage()/]parts -[/template] - -[template public partsPackage(view : View)] -[view.owningViewsRepository().vrPackage()/]parts -[/template] - -[template public partsImplPackage(view : View)] -[view.partsPackage()/].impl -[/template] - -[template public partsFormPackage(view : View)] -[view.partsPackage()/].forms -[/template] - -[template public pepInterface(view : View)] -[view.name.toJavaClassifier()/]PropertiesEditionPart -[/template] - -[template public pepQualifiedInterface(view : View)] -[view.partsPackage()/].[view.pepInterface()/] -[/template] - -[template public pepClass(view : View)] -[view.name.toJavaClassifier()/]PropertiesEditionPartImpl -[/template] - -[template public pepQualifiedClass(view : View)] -[view.partsImplPackage()/].[view.pepClass()/] -[/template] - -[template public pepQualifiedFormClass(view : View)] -[view.partsFormPackage()/].[view.pepFormClass()/] -[/template] - -[template public pepFormClass(view : View)] -[view.name.toJavaClassifier()/]PropertiesEditionPartForm -[/template] - -[template public pepFormQualifiedClass(view : View)] -[view.partsFormPackage()/].[view.pepFormClass()/] -[/template] - -[template public partQualifiedSuperclass(view : View) post (trim())] -[if (view.associatedGenRepository().partsSuperClass.oclIsUndefined() or view.associatedGenRepository().partsSuperClass.size() = 0)] -org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart -[else] -[view.associatedGenRepository().partsSuperClass/] -[/if] -[/template] - -[template public formQualifiedSuperclass(view : View) post (trim())] -[if (view.associatedGenRepository().formsSuperClass.oclIsUndefined() or view.associatedGenRepository().formsSuperClass.size() = 0)] -org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart -[else] -[view.associatedGenRepository().formsSuperClass/] -[/if] -[/template] - -[template public partSuperclass(view : View) post (trim())] -[if (view.associatedGenRepository().partsSuperClass.oclIsUndefined() or view.associatedGenRepository().partsSuperClass.size() = 0)] -CompositePropertiesEditionPart -[else] -[view.associatedGenRepository().partsSuperClass.tokenize('.')->last()/] -[/if] -[/template] - -[template public formSuperclass(view : View) post (trim())] -[if (view.associatedGenRepository().formsSuperClass.oclIsUndefined() or view.associatedGenRepository().formsSuperClass.size() = 0)] -SectionPropertiesEditingPart -[else] -[view.associatedGenRepository().formsSuperClass.tokenize('.')->last()/] -[/if] -[/template] - -[template public vrClass(repository : ViewsRepository)] -[repository.name.toJavaClassifier()/]ViewsRepository -[/template] - -[template public vrQualifiedClass(repository : ViewsRepository)] -[repository.partsPackage()/].[repository.vrClass()/] -[/template] - -[template public partsProviderPackage(repository : ViewsRepository)] -[repository.vrPackage()/]providers -[/template] - -[template public pepProvider(repository : ViewsRepository)] -[repository.name.toJavaClassifier()/]PropertiesEditionPartProvider -[/template] - -[template public pepQualifiedProvider(repository : ViewsRepository)] -[repository.partsProviderPackage()/].[repository.pepProvider()/] -[/template] - -[comment -------------------------------------------------------------------------- - i18n management - ---------------------------------------------------------------------------------- /] -[template public messagesProperties(viewsRepository : ViewsRepository)] -[viewsRepository.name.toJavaIdentifier()/]Messages -[/template] - -[template public messagesProvider(viewsRepository : ViewsRepository)] -[viewsRepository.name.toJavaClassifier()/]Messages -[/template] - -[template public messagesProviderPackage(viewsRepository : ViewsRepository)] -[viewsRepository.associatedGenRepository().basePackage/].providers -[/template] - -[template public qualifiedMessagesProvider(viewsRepository : ViewsRepository)] -[viewsRepository.messagesProviderPackage()/].[viewsRepository.messagesProvider()/] -[/template] - -[comment containingView must be remove when bug # resolved /] -[template public groupKey(group : ViewElement, containingView : View) ? (group.oclIsTypeOf(views::Container) and group.representation.name = 'Group')] -[containingView.name.toJavaClassifier()/]PropertiesEditionPart_[group.name.toJavaClassifier()/]GroupLabel -[/template] - -[template public editorKey(editor : ViewElement, containingView : View)] -[containingView.name.toJavaClassifier()/]PropertiesEditionPart_[editor.name.toJavaClassifier()/]Label -[/template] - -[comment -------------------------------------------------------------------------- - Properties management - ---------------------------------------------------------------------------------- /] -[template public propertiesPackage(pec : PropertiesEditionContext)] -[pec.contextCompletePackage()/].properties -[/template] - -[template public propertySection(pec : PropertiesEditionComponent, view : View)] -[pec.name.toJavaClassifier()/][view.viewKey(pec).toJavaClassifier()/]PropertySection -[/template] - -[template public qualifiedPropertySection(pec : PropertiesEditionComponent, view : View)] -[pec.editionContext().propertiesPackage()/].[pec.propertySection(view)/] -[/template] - -[template public contributorID(editionContext : PropertiesEditionContext, basePackage : String)] -[if (not editionContext.associatedGenContext().oclIsUndefined() and not editionContext.associatedGenContext().descriptorsContributorID.oclIsUndefined() and editionContext.associatedGenContext().descriptorsContributorID <> '')] -[editionContext.associatedGenContext().descriptorsContributorID/] -[else] -[editionContext.model.ecorePackage.eefPackage(basePackage)/].properties -[/if] -[/template] - -[comment -------------------------------------------------------------------------- - Misc - ---------------------------------------------------------------------------------- /] -[query public viewClassifier(view : View) : String = view.name.toJavaClassifier()/] - -[query public elementEditorName(editor : ElementEditor) : String = editor.name.toJavaIdentifier().disambiguation('view') /] - -[template public peeModelQualifiedClass(pee : PropertiesEditionElement)] -[pee.model.eType.qualifiedName()/] -[/template] - -[template public pecModelQualifiedClass(pec : PropertiesEditionComponent)] -[pec.model.qualifiedName()/] -[/template] - -[template public peeModelClass(pee : PropertiesEditionElement)] -[pee.model.eType.name()/] -[/template] - -[template public pecModelClass(pec : PropertiesEditionComponent)] -[pec.model.name()/] -[/template] - -[template public viewPartConstant(view : View, pec : PropertiesEditionComponent)] -[view.viewKey(pec).toJavaConstant()/]_PART -[/template] - -[template public viewKey(view : View, pec : PropertiesEditionComponent)] -[if (view.name = pec.name or view.eInverse()->first().oclIsTypeOf(ViewReference))]Base[else][view.name/][/if] -[/template] - -[template public viewIdentifier(view : View, pec : PropertiesEditionComponent)] -[view.viewKey(pec).toJavaIdentifier()/]Part -[/template] - -[template public editorID(viewElement : ViewElement)] -// FIXME: defines the editorID computing for the element : [viewElement/] -[/template] - -[template public editorID(editor : ElementEditor)] -[include(editor.owningView().owningViewsRepository().vrQualifiedClass())/].[for (s : String | editor.editorIDSequence()->subSequence(2, editor.editorIDSequence()->size() - 1)) separator ('.')][s.toJavaClassifier()/][/for].[editor.identifiedElementKey().toJavaIdentifier()/] -[/template] - -[template public editorID(containerElement : Container)] -[include(containerElement.owningView().owningViewsRepository().vrQualifiedClass())/].[for (s : String | containerElement.editorIDSequence()->subSequence(2, containerElement.editorIDSequence()->size())) separator ('.')][s.toJavaClassifier()/][/for] -[/template] - -[template public editorID(view : View)] -[include(view.owningViewsRepository().vrQualifiedClass())/].[for (s : String | view.editorIDSequence()->subSequence(2, view.editorIDSequence()->size())) separator ('.')][s.toJavaClassifier()/][/for] -[/template] - -[template public editorID(reference : ViewReference)] -[include(reference.owningView().owningViewsRepository().vrQualifiedClass())/].[for (s : String | reference.editorIDSequence()->subSequence(2, reference.editorIDSequence()->size() - 1)) separator ('.')][s.toJavaClassifier()/][/for].[reference.identifiedElementKey().toJavaIdentifier()/] -[/template] - -[template public genTabLabel(view : View, pec : PropertiesEditionComponent) post (trim())] -[if (view.label.oclIsUndefined())] - [view.viewKey(pec)/] -[else] - [view.label/] -[/if] -[/template] -[query public disambiguation(input : String, exclude : String) : String = if (input = exclude) then input.concat('_') else input endif /] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/navigationStep.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/navigationStep.mtl deleted file mode 100644 index 6b23c6de0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/navigationStep.mtl +++ /dev/null @@ -1,37 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module navigationStep('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/navigation/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/filters/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[template public filterBody(stepFilter : StepFilter)] -// FIXME default case for filter body generation. -[/template] - -[template public filterBody(stepFilter : JavaBodyStepFilter)] -[stepFilter._body/] -[/template] - -[template public filterBody(stepFilter : JavaDeclarationStepFilter)] -[if (stepFilter.staticMethod)] return [stepFilter.qualifiedClass/].[stepFilter.methodName/](semanticObject);[else] return new [stepFilter.qualifiedClass/]().[stepFilter.methodName/](semanticObject);[/if] -[/template] - -[template public initBody(stepInit : StepInitializer)] -// FIXME default case for filter body generation. -[/template] - -[template public initBody(stepInit : JavaBodyStepInitializer)] -[stepInit._body/] -[/template] - -[template public initBody(stepInit : JavaDeclarationStepInitializer)] -[if (stepInit.staticMethod)] return [stepInit.qualifiedClass/].[stepInit.methodName/](semanticObject);[else] return new [stepInit.qualifiedClass/]().[stepInit.methodName/](semanticObject);[/if] -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/pluginservice.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/pluginservice.mtl deleted file mode 100644 index 74705ccc3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/pluginservice.mtl +++ /dev/null @@ -1,16 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] - [module pluginservice('http://www.eclipse.org/emf/eef/components/1.0.0')/] - -[query public getPluginTabs(arg0 : PropertiesEditionContext) : Sequence(OclAny) - = invoke('org.eclipse.emf.eef.codegen.services.PluginService', 'getPluginTabs(org.eclipse.emf.ecore.EObject)', Sequence{arg0}) /] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/typeUtils.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/typeUtils.mtl deleted file mode 100644 index 28f9cfa4d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/typeUtils.mtl +++ /dev/null @@ -1,37 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module typeUtils('http://www.eclipse.org/emf/2002/Ecore')/] - -[query public isBoolean(a : EAttribute) : Boolean = - not oclIsUndefined() and eType.name = 'EBool' or eType.name = 'EBoolean' or eType.name = 'Boolean' or eType.name = 'boolean' or eType.name = 'EBooleanObject'/] - -[query public isString(a : EAttribute) : Boolean = - not oclIsUndefined() and eType.name = 'EString' or eType.name = 'String' or eType.instanceClassName = 'java.lang.String'/] - -[query public isInteger(a : EAttribute) : Boolean = - not oclIsUndefined() and eType.name = 'EInteger' or eType.name = 'Integer' or eType.name = 'EInt' or eType.instanceClassName = 'int' or eType.instanceClassName = 'java.lang.Integer'/] - -[query public isShort(a : EAttribute) : Boolean = - not oclIsUndefined() and eType.name = 'EShort' or eType.name = 'Short' or eType.instanceClassName = 'java.lang.Short' or eType.instanceClassName = 'short'/] - -[query public isEnum(a : EAttribute) : Boolean = - not oclIsUndefined() and eType.oclIsKindOf(EEnum)/] - -[query public isLong(a : EAttribute) : Boolean = - not oclIsUndefined() and eType.name = 'ELong' or eType.name = 'Long'/] - -[query public isDouble(a : EAttribute) : Boolean = - not oclIsUndefined() and eType.name = 'EDouble' or eType.name = 'Double'/] - -[query public isPrimitiveType(a : EStructuralFeature) : Boolean = - not oclIsUndefined() and eType.instanceClassName = 'byte' or eType.instanceClassName = 'short' or eType.instanceClassName = 'int' or eType.instanceClassName = 'long' or eType.instanceClassName = 'float' or eType.instanceClassName = 'double' or eType.instanceClassName = 'char' or eType.instanceClassName = 'boolean'/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/viewCommon.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/viewCommon.mtl deleted file mode 100644 index 586521584..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/services/viewCommon.mtl +++ /dev/null @@ -1,343 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module viewCommon('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/navigation/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/filters/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::imports /] -[import org::eclipse::emf::eef::codegen::services::emfCodeGen /] -[import org::eclipse::emf::eef::codegen::services::navigationStep /] - -[comment] -Common tools for views generation purpose. -TODO: externalise model/controler reference after Unedic non-reg -[/comment] - -[comment --------------- Views related templates --------------- /] -[template public genDeclaration(elementEditor : ElementEditor)] -[elementEditor.getterDeclaration()/] - -[elementEditor.setterDeclaration()/] - -[/template] - -[template public genDeclarationForSubView(view : View)] - [view.getterForSubViewDeclaration()/] -[/template] - -[template public genDeclarationForReferencedView(view : View)] - [view.getterForReferencedViewDeclaration()/] -[/template] - -[template public genDeclarationForViewReference(view : View)] -[for (viewReference : ViewReference | view.eAllContents(ViewReference))] -[viewReference.view.oclAsType(View).genDeclarationForReferencedView()/] - [for (elementEditor : ElementEditor | viewReference.view.eAllContents(ElementEditor))] -[elementEditor.genDeclaration()/] - [/for] -[if (viewReference.view.eAllContents(ViewReference)->notEmpty())][genDeclarationForViewReferenceDelegate(viewReference.view.oclAsType(View))/][/if] -[/for] -[/template] - -[template public genDeclarationForViewReferenceDelegate(view : View)] -[for (viewReference : ViewReference | view.eAllContents(ViewReference))] - [for (elementEditor : ElementEditor | viewReference.view.eAllContents(ElementEditor))] -[elementEditor.genDeclaration()/] - [/for] -[if (viewReference.view.eAllContents(ViewReference)->notEmpty())][genDeclarationForViewReferenceDelegate(viewReference.view.oclAsType(View))/][/if] -[/for] -[/template] - -[template public genDeclarationForSubViews(view : View)] -[view.genDeclarationForSubView()/] - -[for (elementEditor : ElementEditor | view.eAllContents(ElementEditor))] -[elementEditor.genDeclaration()/] -[/for] -[/template] - -[template public compositionStepName(view : IdentifiedElement)] -[view.identifiedElementKey().toJavaIdentifier()/]Step -[/template] - -[template public compositionSequence(view : View)] -[include('org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence')/] [view.compositionStepName()/] = new [include('org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence')/](propertiesEditionComponent); -[for (elem : ViewElement | view.elements)] -[elem.compositionSequence()/] -[/for] -[/template] - -[template public compositionSequence(viewElement : ViewElement)] -// FIXME: composition step generation must be defined for this case : [viewElement/] -[/template] - -[template public compositionSequence(containerElement : Container)] -[if (containerElement.elements->size() > 1)] -[include('org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep')/] [containerElement.compositionStepName()/] = [containerElement.eContainer().oclAsType(IdentifiedElement).compositionStepName()/].addStep([containerElement.editorID()/].class); -[for (element : ViewElement | containerElement.elements)] -[element.compositionSequence()/] -[/for] -[else] -[containerElement.eContainer().oclAsType(IdentifiedElement).compositionStepName()/] - .addStep([containerElement.editorID()/].class)[if (containerElement.elements->isEmpty())];[else] - - .addStep([containerElement.elements->first().editorID()/]); - [/if] -[/if] -[/template] - -[template public compositionSequence(reference : ViewReference)] -[reference.eContainer().oclAsType(IdentifiedElement).compositionStepName()/].addStep([reference.editorID()/]); -[/template] - -[template public compositionSequence(editor : ElementEditor)] -[editor.eContainer().oclAsType(IdentifiedElement).compositionStepName()/].addStep([editor.editorID()/]); -[/template] - -[template public additionalComponentGetterForModelNavigation(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] - -/** - * @ return settings for [editionElement.name/] editor - */ -public EEFEditorSettingsImpl get[editionElement.name.toJavaClassifier()/]Settings() { - return [editionElement.name.toJavaIdentifier()/]Settings; -} -[/template] - -[template public additionalComponentFieldForModelNavigation(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] - -/** - * Settings for [editionElement.name/] editor - */ -protected [include('org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFEditorSettingsBuilder.EEFEditorSettingsImpl')/] [editionElement.name.toJavaIdentifier()/]Settings = (EEFEditorSettingsImpl) [include('org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFEditorSettingsBuilder')/].create(semanticObject, [editionElement.metamodelGetter()/]) -[editionElement.navigation.generateNavigation()/] -.build(); - -[/template] - -[template public generateNavigation(navigation : ModelNavigation)/] - -[template public generateNavigation(navigation : CustomModelNavigation)] -// [protected ('for '.concat(navigation.eContainer(PropertiesEditionElement).name).concat(' model navigation implementation'))] - -// [/protected] -[/template] - -[template public generateNavigation(navigation : SimpleModelNavigation)] -.nextStep([include('org.eclipse.emf.eef.runtime.ui.widgets.settings.NavigationStepBuilder')/].create([navigation.metamodelGetter()/])[if (not navigation.index.oclIsUndefined())] - -.index([navigation.index/])[/if][if (not navigation.discriminatorType.oclIsUndefined())] - -.discriminator([navigation.discriminatorType.metamodelGetter()/][addImport(navigation.discriminatorType.ePackage.qualifiedMetamodelPackage())/])[/if].build()) -[/template] - -[template public generateNavigation(navigation : ChainedModelNavigation)] -[navigation.current.generateNavigation()/] -[navigation.next.generateNavigation()/] -[/template] - -[template public generateNavigation(navigation : navigation::SmartModelNavigation)] -[navigation.step.generateStep()/] -[/template] - -[template public generateStep(step : NavigationStep)/] - -[template public generateStep(step : DeclarativeNavigationStep)] -.nextStep([include('org.eclipse.emf.eef.runtime.ui.widgets.settings.NavigationStepBuilder')/].create([step.metamodelGetter()/])[if (not step.index.oclIsUndefined())] - -.index([step.index/])[/if][if (not step.discriminatorType.oclIsUndefined())] - -.discriminator([step.discriminatorType.metamodelGetter()/][addImport(step.discriminatorType.ePackage.qualifiedMetamodelPackage())/])[/if][if (not step.initializer.oclIsUndefined())] - -[step.initNavigationStep()/][/if][if (not step.filters->isEmpty())] - -[for (filter : StepFilter | step.filters)][filter.filterNavigationStep()/][/for][/if].build())[if (not step.subStep.oclIsUndefined())] - -[step.subStep.generateStep()/][/if] -[/template] - -[template public filterNavigationStep (filter : StepFilter) ] -.filter(new EEFFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFFilter#select(org.eclipse.emf.ecore.EObject) - */ - @Override - protected boolean select(EObject semanticObject) { -[filter.filterBody()/] - } - -}) - -[/template] - -[template public initNavigationStep(step : DeclarativeNavigationStep)] -.init(new EEFInitializer() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFInit#init(org.eclipse.emf.ecore.EObject) - */ - @Override - protected EObject init(EObject semanticObject) { -[step.initializer.initBody()/] - } - -}) -[/template] - -[template public navigationMetamodelGetter(navigation : ModelNavigation)/] - -[template public navigationMetamodelGetter(navigation : SmartModelNavigation)] -[navigation.step.stepMetamodelGetter()/] -[/template] - -[template public stepMetamodelGetter(step : NavigationStep)/] - -[template public stepMetamodelGetter(step : DeclarativeNavigationStep)] -[step.metamodelGetter()/][if (not step.subStep.oclIsUndefined())], - [step.subStep.stepMetamodelGetter()/][/if] -[/template] - -[comment ====== Widgets getters signature ====== /] -[template public partGetterAddSignature(editor : PropertiesEditionElement) ? (editor.views->first().representation.name = 'ReferencesTable' or editor.views->first().representation.name = 'AdvancedReferencesTable')] -public List get[editor.model.eContainingClass.name.toUpperFirst()/]_[editor.model.name.toUpperFirst()/]ToAdd() -[/template] - -[template public partGetterRemoveSignature(editor : PropertiesEditionElement) ? (editor.views->first().representation.name = 'ReferencesTable' or editor.views->first().representation.name = 'AdvancedReferencesTable')] -public List get[editor.model.eContainingClass.name.toUpperFirst()/]_[editor.model.name.toUpperFirst()/]ToRemove() -[/template] - -[template public partGetterAddSignature(editor : PropertiesEditionElement) ? (editor.views->first().representation.name = 'TableComposition')] -public List get[editor.model.eContainingClass.name.toUpperFirst()/]_[editor.model.name.toUpperFirst()/]ToAdd() -[/template] - -[template public partGetterEditSignature(editor : PropertiesEditionElement) ? (editor.views->first().representation.name = 'TableComposition')] -public Map get[editor.model.eContainingClass.name.toUpperFirst()/]_[editor.model.name.toUpperFirst()/]ToEdit() -[/template] - -[template public partGetterRemoveSignature(editor : PropertiesEditionElement) ? (editor.views->first().representation.name = 'TableComposition')] -public List get[editor.model.eContainingClass.name.toUpperFirst()/]_[editor.model.name.toUpperFirst()/]ToRemove() -[/template] - -[template public partGetterTableListSignature(editor : PropertiesEditionElement) ? (editor.views->first().representation.name = 'TableComposition')] -public List get[editor.model.eContainingClass.name.toUpperFirst()/]_[editor.model.name.toUpperFirst()/]() -[/template] - -[comment ====== Widgets setters signature ====== /] -[template public partSetterSignature(editor : PropertiesEditionElement)] -public void set[editor.model.ecorePackageSignature()/]() -[/template] - -[template public partSetterAddSignature(editor : PropertiesEditionElement)] -public void add[editor.model.eContainingClass.name.toUpperFirst()/]_[editor.model.name.toUpperFirst()/](EObject newValue) -[/template] - -[template public partSetterRemoveSignature(editor : PropertiesEditionElement)] -public void remove[editor.model.eContainingClass.name.toUpperFirst()/]_[editor.model.name.toUpperFirst()/](EObject value) -[/template] - -[template public partSetterUpdateSignature(editor : PropertiesEditionElement)] -public void update[editor.model.eContainingClass.name.toUpperFirst()/]_[editor.model.name.toUpperFirst()/](EObject value) -[/template] - -[comment ====== Widgets getters ====== /] -[template public partSetter(editor : PropertiesEditionElement) ? (editor.views->first().representation.name = 'MultiValuedEditor')] -[editor.partSetterSignature()/] { - [editor.views->first().name.toJavaIdentifier()/]List = newValue; - [editor.views->first().name.toJavaIdentifier()/]Text.setText([editor.views->first().name.toJavaIdentifier()/]List.toString()); - } -[/template] - -[template public partSetter(editor : PropertiesEditionElement) ? (editor.model.oclAsType(EAttribute).isString() and (editor.model.upperBound = 0 or editor.model.upperBound = 1))] -[editor.partSetterSignature()/] { - [editor.views->first().name.toJavaIdentifier()/].setText(newValue); - } -[/template] - -[template public partSetter(editor : PropertiesEditionElement) ? (editor.model.oclAsType(EAttribute).isBoolean())] -[editor.partSetterSignature()/] { - [editor.views->first().name.toJavaIdentifier()/].setSelection(newValue.booleanValue()); - } -[/template] - -[template public partSetter(editor : PropertiesEditionElement) ? (editor.model.oclAsType(EAttribute).isInteger() or editor.model.oclAsType(EAttribute).isShort() or editor.model.oclAsType(EAttribute).isLong())] -[editor.partSetterSignature()/] { - [editor.views->first().name.toJavaIdentifier()/].setText(newValue.toString()); - } -[/template] - -[template public partSetter(editor : PropertiesEditionElement) ? (editor.views->first().representation.name = 'EObjectFlatComboViewer' or editor.views->first().representation.name = 'AdvancedEObjectFlatComboViewer')] -[editor.partSetterSignature()/] { - if (newValue != null) - [editor.views->first().name.toJavaIdentifier()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](newValue)); - else - [editor.views->first().name.toJavaIdentifier()/].setSelection(new StructuredSelection()); - } -[/template] - -[comment === ViewReference managing ===/] -[template public elementEditorGetterSettersForViewReference(view : View, pec : PropertiesEditionComponent, basePackage : String)] -[for (viewRef : ViewReference | view.eAllContents(ViewReference))] -[viewRef.view.oclAsType(View).getterForReferencedViewImplementation(pec.model.eefPackage(basePackage).fullPartInterfacePath(view.pepInterface()))/] -[for (elementEditor : ElementEditor | viewRef.view.eAllContents(ElementEditor))] -[elementEditor.getterImplementationDelegate(fullPartInterfacePath(pec.model.eefPackage(basePackage),view.pepInterface()),viewRef.view.oclAsType(View))/] - -[elementEditor.setterImplementationDelegate(fullPartInterfacePath(pec.model.eefPackage(basePackage),view.pepInterface()),viewRef.view.oclAsType(View))/] - -[/for] -[viewRef.view.oclAsType(View).elementEditorGetterSettersForSubViewReference(pec, basePackage, viewRef)/] -[/for] -[/template] - -[template public elementEditorGetterSettersForSubViewReference(view : View, pec : PropertiesEditionComponent, basePackage : String, initViewRef : ViewReference)] -[for (viewRef : ViewReference | view.eAllContents(ViewReference))] -[for (elementEditor : ElementEditor | viewRef.view.eAllContents(views::ElementEditor))] -[elementEditor.getterImplementationDelegate(fullPartInterfacePath(pec.model.eefPackage(basePackage),view.pepInterface()),initViewRef.view.oclAsType(View))/] - -[elementEditor.setterImplementationDelegate(fullPartInterfacePath(pec.model.eefPackage(basePackage),view.pepInterface()),initViewRef.view.oclAsType(View))/] - -[/for] -[viewRef.view.oclAsType(View).elementEditorGetterSettersForSubViewReference(pec, basePackage, initViewRef)/] -[/for] -[/template] - -[template public elementEditorGetterSettersForSubViews(view : View, pec : PropertiesEditionComponent, basePackage : String)] -[for (subView : View | view.elements->filter(View))] -[subView.getterForSubViewImplementationDelegate(pec.model.eefPackage(basePackage).fullPartInterfacePath(view.pepInterface()))/] -[for (elementEditor : ElementEditor | subView.eAllContents(ElementEditor)->select(owningView() = subView))] -[elementEditor.getterImplementationDelegate(fullPartInterfacePath(pec.model.eefPackage(basePackage),view.pepInterface()),subView)/] - -[elementEditor.setterImplementationDelegate(fullPartInterfacePath(pec.model.eefPackage(basePackage),view.pepInterface()),subView)/] - -[/for] -[subView.elementEditorGetterSettersForSubViewsDelegate(pec, basePackage, subView)/] -[/for] -[/template] - -[template public elementEditorGetterSettersForSubViewsDelegate(view : View, pec : PropertiesEditionComponent, basePackage : String, initView : View)] -[for (subView : View | view.elements->filter(View))] -[for (elementEditor : ElementEditor | subView.eAllContents(ElementEditor)->select(owningView() = subView))] -[elementEditor.getterImplementationDelegate(fullPartInterfacePath(pec.model.eefPackage(basePackage),view.pepInterface()),initView)/] - - -[elementEditor.setterImplementationDelegate(fullPartInterfacePath(pec.model.eefPackage(basePackage),view.pepInterface()),initView)/] -[/for] -[view.elementEditorGetterSettersForSubViewsDelegate(pec, basePackage, initView)/] -[/for] -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetControl.mtl deleted file mode 100644 index 0626672b5..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetControl.mtl +++ /dev/null @@ -1,114 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - - This module define the widget generation. It is composed of templates that need to be - override by the templates that implements wigdets for EEF. - /] -[module widgetControl('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0')/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::filters /] - -[comment ===== Widget generation API ===== /] - -[comment declareEObjectUpdate : templates that override this one must define the method to update an EObject when a view throw an update - event /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] -// FIXME INVALID CASE you must override the template 'declareEObjectUpdater' for the case : [editionElement.name/], [view.name/], [pec.name/]. -[/template] - -[comment liveupdater : templates that override this one must define the behaviour of the generated widget when the associated - feature of the edited element has changed /] -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] -// FIXME INVALID CASE INTO template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) in widgetControl.mtl module, with the values : [editionElement.name/], [view.name/], [pec.name/]. -[/template] - -[comment updater : templates that override this one must define the operation to execute at the initialization of the - component for the given widget /] -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] -// FIXME NO VALID CASE INTO template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) in widgetControl.mtl module, with the values : [editionElement.name/], [view.name/], [pec.name/]. -[/template] - -[comment filterUpdater : templates that override this one must define the operation to execute at the initialization of the - component for the filters of the given widget /] -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] -// FIXME NO VALID CASE INTO template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) in widgetControl.mtl module, with the values : [editionElement.name/], [view.name/], [pec.name/]. -[/template] - -[comment additionalComponentField : templates that override this one must definethe additional fields to generate in the component - manage the given element /] -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)/] - -[template public liveUpdaterForReferencedViews(view : View, pec : PropertiesEditionComponent)] -[for (v : View | view.referencedViews())] -[for (editionElement : PropertiesEditionElement | pec.properties->filter(PropertiesEditionElement)->select(views->first().ownedBy(v)))] -[editionElement.liveUpdater(v, pec)/] -[/for] -[comment][if (v.referencedViews()->notEmpty())][v.liveUpdaterForReferencedViews(pec.referencedBinding.binding->select(oclIsTypeOf(PropertiesEditionComponent))->first().oclAsType(PropertiesEditionComponent))/][/if][/comment] -[/for] -[/template] - - -[template public liveUpdaterNavigationCondition (editionElement : PropertiesEditionElement, pec : PropertiesEditionComponent) ] -[if (editionElement.canGeneratemodelNavigation())][editionElement.name.toJavaIdentifier()/]Settings.isAffectingEvent(msg)[else][editionElement.metamodelGetter()/].equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject)[/if] -[/template] - -[template public liveUpdaterNavigationConditionForText (editionElement : PropertiesEditionElement, pec : PropertiesEditionComponent) ] -[if (editionElement.canGeneratemodelNavigation())]!(msg.getNewValue() instanceof EObject) && [editionElement.name.toJavaIdentifier()/]Settings.isAffectingEvent(msg)[else][editionElement.metamodelGetter()/].equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject)[/if] -[/template] - -[template public updaterForReferencedViews(view : View, pec : PropertiesEditionComponent)] -[for (v : View | view.referencedViews())] - [view.viewIdentifier(pec)/].get[v.name.toJavaClassifier()/]ReferencedView().setContext(elt, allResource); -[for (editionElement : PropertiesEditionElement | pec.properties->filter(PropertiesEditionElement)->select(views->first().ownedBy(v)))] -[editionElement.updater(v, pec)/] -[/for] -[comment][if (v.referencedViews()->notEmpty())][v.updaterForSubReferencedViews(pec.referencedBinding.binding->select(oclIsTypeOf(PropertiesEditionComponent))->first().oclAsType(PropertiesEditionComponent), pec)/][/if][/comment] -[/for] -[/template] - -[template public updaterForSubReferencedViews(view : View, pec : PropertiesEditionComponent, inputPEC : PropertiesEditionComponent)] -[for (v : View | view.referencedViews())] -[for (editionElement : PropertiesEditionElement | pec.properties->filter(PropertiesEditionElement)->select(views->first().ownedBy(v)))] -[editionElement.updater(v, inputPEC)/] -[/for] -[comment][if (v.referencedViews()->notEmpty())][v.updaterForSubReferencedViews(pec.referencedBinding.binding->select(oclIsTypeOf(PropertiesEditionComponent))->first().oclAsType(PropertiesEditionComponent), inputPEC)/][/if][/comment] -[/for] -[/template] - -[template public filterUpdaterForReferencedViews(view : View, pec : PropertiesEditionComponent)] -[for (v : View | view.referencedViews())] -[for (editionElement : PropertiesEditionElement | pec.involvedEditionElementsInView(v))] -[editionElement.filterUpdater(view, pec)/] -[/for] -[comment][if (v.referencedViews()->notEmpty())][v.filterUpdaterForReferencedViews(pec.referencedBinding.binding->select(oclIsTypeOf(PropertiesEditionComponent))->first().oclAsType(PropertiesEditionComponent))/][/if][/comment] -[/for] -[/template] - -[template public javaDeclarationFilterForReferencedViews(view : View, pec : PropertiesEditionComponent)] -[for (v : View | view.referencedViews())] -[for (editionElement : PropertiesEditionElement | pec.involvedEditionElementsInView(v))] -[editionElement.javaDeclarationFilter()/] -[/for] -[comment][if (v.referencedViews()->notEmpty())][v.filterUpdaterForReferencedViews(pec.referencedBinding.binding->select(oclIsTypeOf(PropertiesEditionComponent))->first().oclAsType(PropertiesEditionComponent))/][/if][/comment] -[/for] -[/template] - -[comment Global template used to fix bug #347122 /] -[template public additionalBusinessFilterProtectedArea(editionElement : PropertiesEditionElement)] -// [protected ('for additional businessfilters for '.concat(editionElement.name))] -// [/protected] -[/template] - -[comment additionalComponentGetterForEditorSettings : template to add methods in component class /] -[template public additionalComponentGetterForEditorSettings(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetFormImpl.mtl deleted file mode 100644 index 27da5b11a..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetFormImpl.mtl +++ /dev/null @@ -1,90 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module widgetFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case DEFAULT = NEED TO BE THE LAST CHOICE ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) /] - -[template public widgetDeclaration(editor : ElementEditor)] -//FIXME INVALID CASE INTO template public widgetDeclaration(editor : ElementEditor) in Form Impl for ElementEditor [editor.name/] -[/template] - -[template public implementation(editor : ViewElement)] -//FIXME INVALID CASE INTO template public implementation(editor : ViewElement) in Form Impl for ViewElement [editor.name/] -[/template] - -[template public additionalImplementation(editor : ViewElement, pec : PropertiesEditionComponent, inputPEC : PropertiesEditionComponent)] -//FIXME INVALID CASE INTO template public additionalImplementation(editor : ViewElement, pec : PropertiesEditionComponent, inputPEC : PropertiesEditionComponent) in Form Impl for ViewElement [editor.name/] -[/template] - -[comment ===== ViewReference support ===== /] -[template public widgetDeclaration(reference : ViewReference)] - private [include(reference.view.oclAsType(View).pepQualifiedInterface())/] [reference.view.oclAsType(View).pepInterface().toLowerFirst()/]; -[/template] - -[template public implementation(reference : ViewReference)] -return create[reference.view.name.toJavaClassifier()/](widgetFactory, parent); -[/template] - -[template public additionalImplementation(reference : ViewReference, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent)][let referencedView : View = reference.view.oclAsType(View)] - protected Composite create[reference.view.name.toJavaClassifier()/](FormToolkit widgetFactory, Composite container) { - [include('org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider')/] provider = [include('org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService')/].getInstance().getProvider([include(referencedView.owningViewsRepository().vrQualifiedClass())/].class); - [referencedView.pepInterface().toLowerFirst()/] = ([referencedView.pepInterface()/])provider.getPropertiesEditionPart([referencedView.editorID()/].class, [referencedView.owningViewsRepository().vrClass()/].FORM_KIND, propertiesEditionComponent); - ((IFormPropertiesEditionPart)[referencedView.pepInterface().toLowerFirst()/]).createControls(widgetFactory, container); - return container; - } -[/let] -[/template] - -[template public widgetDeclarationForViewReference(view : View)] -[for (element : ViewReference | view.eAllContents(ViewReference))] -[element.widgetDeclaration()/] -[/for] -[/template] - -[comment ===== SubView support ===== /] -[template public widgetDeclaration(subView : View)] - private [include(subView.pepQualifiedInterface())/] [subView.pepInterface().toLowerFirst()/]; -[/template] - -[template public implementation(view : View)] - if (propertiesEditionComponent.mustBeComposed([view.editorID()/].class, [view.owningViewsRepository().vrClass()/].FORM_KIND)) - return create[view.name.toJavaClassifier()/]SubView(widgetFactory, parent); -[/template] - -[template public additionalImplementation(view : View, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent)] - protected Composite create[view.name.toJavaClassifier()/]SubView(FormToolkit widgetFactory, Composite container) { - [include('org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider')/] provider = [include('org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService')/].getInstance().getProvider([include(view.owningViewsRepository().vrQualifiedClass())/].class); - [view.pepInterface().toLowerFirst()/] = ([view.pepInterface()/])provider.getPropertiesEditionPart([view.editorID()/].class, [view.owningViewsRepository().vrClass()/].FORM_KIND, propertiesEditionComponent); - ((IFormPropertiesEditionPart)[view.pepInterface().toLowerFirst()/]).createControls(widgetFactory, container); - return container; - } -[/template] - -[template public widgetDeclarationForSubViews(view : View)] -[for (element : View | view.elements->filter(View))] -[element.widgetDeclaration()/] -[/for] -[/template] - -[comment --------------- Views related queries --------------- /] - -[query public editionPart(editor : ViewElement) : String = - if editor.container.oclIsTypeOf(Container) then editor.container.editionPart() - else editor.container.oclAsType(View).pepFormClass() - endif/] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetGettersSetters.mtl deleted file mode 100644 index 5246745a6..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetGettersSetters.mtl +++ /dev/null @@ -1,424 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module widgetGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::services::common/] -[import org::eclipse::emf::eef::codegen::services::naming/] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment TODO: A TRAITER /] -[template public initSignature(elementEditor : ElementEditor) /] - -[template public initSignatureImplementation(elementEditor : ElementEditor) /] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) /] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) /] - -[comment ====== View getters for declaration ====== /] -[template public getterForSubViewDeclaration(view : View)] -[view.getterForSubViewSignatureDocumentation()/] - [view.getterForSubViewSignature()/]; -[/template] - -[template public getterForReferencedViewDeclaration(view : View)] -[view.getterForReferencedViewSignatureDocumentation()/] - [view.getterForReferencedViewSignature()/]; -[/template] - -[comment ====== Widgets View getters for declaration ====== /] -[template public getterDeclaration(elementEditor : ElementEditor)] -[elementEditor.getterSignatureDocumentation()/] -[elementEditor.getterSignature()/]; -[/template] - -[comment ====== Signatures ====== /] -[template public getterForSubViewSignature(view : View)] - public [include('org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart')/] get[view.name.toJavaClassifier()/]SubView() -[/template] - -[template public getterForReferencedViewSignature(view : View)] -public [include('org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart')/] get[view.name.toJavaClassifier()/]ReferencedView() -[/template] - -[template public getterSignature(elementEditor : ElementEditor)] - public [elementEditor.toJavaType().trim()/] [elementEditor.viewCompletePackageGetter()/] -[/template] - -[template public getterAddSignature(elementEditor : ElementEditor)] - public List [elementEditor.viewPackageGetter()/]ToAdd() -[/template] - -[template public getterRemoveSignature(elementEditor : ElementEditor)] - public List [elementEditor.viewPackageGetter()/]ToRemove() -[/template] - -[template public getterMoveSignature(elementEditor : ElementEditor)] - public List [elementEditor.viewPackageGetter()/]ToMove() -[/template] - -[template public getterEditSignature(elementEditor : ElementEditor)] - public Map [elementEditor.viewPackageGetter()/]ToEdit() -[/template] - -[template public getterTableListSignature(elementEditor : ElementEditor)] - public List [elementEditor.viewPackageGetter()/]Table() -[/template] - -[template public getterForSubViewSignatureDocumentation(view : View)] - /** - * @return the [view.name/] SubView - * [view.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public getterForReferencedViewSignatureDocumentation(view : View)] -/** - * @return the [view.name/] referenced view - * [view.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public getterSignatureDocumentation(elementEditor : ElementEditor)] - /** - * @return the [elementEditor.name/] - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public getterAddSignatureDocumentation(elementEditor : ElementEditor)] - /** - * @return the [elementEditor.name/] to add - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public getterRemoveSignatureDocumentation(elementEditor : ElementEditor)] - /** - * @return the [elementEditor.name/] to remove - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public getterMoveSignatureDocumentation(elementEditor : ElementEditor)] - /** - * @return the [elementEditor.name/] to move - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public getterEditSignatureDocumentation(elementEditor : ElementEditor)] - /** - * @return the [elementEditor.name/] to edit - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public getterTableListSignatureDocumentation(elementEditor : ElementEditor)] - /** - * @return the current [elementEditor.name/] table - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[comment ====== Widgets View setters for declaration ====== /] -[template public setterDeclaration(elementEditor : ElementEditor)] -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; -[/template] - -[template public setterSignature(elementEditor : ElementEditor)] - public void [elementEditor.viewCompletePackageSetter()/] -[/template] - -[template public setterButtonModeSignature(elementEditor : ElementEditor)] - public void [elementEditor.viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/] newValue) -[/template] - -[template public updateSignature(elementEditor : ElementEditor)] - public void update[elementEditor.viewPackageSignature()/]() -[/template] - -[template public setterSignatureDocumentation(elementEditor : ElementEditor)] - /** - * Defines a new [elementEditor.name/] - * @param newValue the new [elementEditor.name/] to set - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public setterButtonModeSignatureDocumentation(elementEditor : ElementEditor)] - /** - * Defines the button mode - * @param newValue the new mode to set - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public updateSignatureDocumentation(elementEditor : ElementEditor)] - /** - * Update the [elementEditor.name/] - * @param newValue the [elementEditor.name/] to update - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public addFilterSignatureDocumentation(elementEditor : ElementEditor)] - /** - * Adds the given filter to the [elementEditor.name/] edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public addFilterSignature(elementEditor : ElementEditor)] - public void addFilterTo[elementEditor.viewPackageSignature()/]([include('org.eclipse.jface.viewers.ViewerFilter')/] filter) -[/template] - -[template public addBusinessFilterSignatureDocumentation(elementEditor : ElementEditor)] - /** - * Adds the given filter to the [elementEditor.name/] edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public addBusinessFilterSignature(elementEditor : ElementEditor)] - public void addBusinessFilterTo[elementEditor.viewPackageSignature()/]([include('org.eclipse.jface.viewers.ViewerFilter')/] filter) -[/template] - -[template public isContainedInTableSignatureDocumentation(elementEditor : ElementEditor)] - /** - * @return true if the given element is contained inside the [elementEditor.name/] table - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public isContainedInTableSignature(elementEditor : ElementEditor)] - public boolean isContainedIn[elementEditor.viewPackageSignature()/]Table([include('org.eclipse.emf.ecore.EObject')/] element) -[/template] - -[comment ====== Widgets getter implementation ====== /] -[template public getterImplementation(elementEditor : ElementEditor, fullInterfacePath : String)] -[getterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.getterSignatureImplementation()/] -[/template] - -[comment delegate implementation for SubView/] -[template public getterForSubViewImplementationDelegate(view : View, fullInterfacePath : String)] -[view.getterForSubViewSignatureDocumentationImplementation(fullInterfacePath)/] - [view.getterForSubViewSignature()/] { - return ([include('org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart')/]) [view.pepInterface().toLowerFirst()/]; - } -[/template] - -[comment delegate implementation for ViewReference/] -[template public getterForReferencedViewImplementation(view : View, fullInterfacePath : String)] -[view.getterForReferencedViewSignatureDocumentationImplementation(fullInterfacePath)/] - [view.getterForReferencedViewSignature()/] { - return ([include('org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart')/]) [view.pepInterface().toLowerFirst()/]; - } -[/template] - -[template public getterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View)] -[getterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.getterSignature()/] { - return [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewCompletePackageGetter()/]; - } -[/template] - -[template public getterSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String)] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#[elementEditor.viewCompletePackageGetter()/] - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public getterForSubViewSignatureDocumentationImplementation(view : View, fullInterfacePath : String)] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#get[view.name.toJavaClassifier()/]SubView() - * [view.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public getterForReferencedViewSignatureDocumentationImplementation(view : View, fullInterfacePath : String)] -/** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#get[view.name.toJavaClassifier()/]ReferencedView() - * [view.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public getterSignatureImplementation(elementEditor : ElementEditor)] -[elementEditor.getterSignature()/] { - //FIXME ERROR NO VALID CASE INTO template public getterSignatureImplementation(elementEditor : ElementEditor) in viewgetterSetters.mtl module - return null; - } -[/template] - -[comment ====== Widgets setter implementation ====== /] -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String)] -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View)] -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/](newValue); - } -[/template] - -[comment Setters/] -[template public setterSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String)] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#[elementEditor.viewCompletePackageSetter()/] - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor)] -[elementEditor.setterSignature()/] { - // FIXME ERROR NO VALID CASE INTO template public setterSignatureImplementation(elementEditor : ElementEditor) in widgetGettersSetters.mtl module - } -[/template] - -[template public setterButtonModeSignatureImplementation(elementEditor : ElementEditor)] -[elementEditor.setterButtonModeSignature()/] { - [elementEditor.elementEditorName()/].setButtonMode(newValue); - } -[/template] - -[template public updateSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String)] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#update[elementEditor.viewPackageSignature()/]() - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public updateSignatureImplementation(elementEditor : ElementEditor)] -[elementEditor.updateSignature()/] { - [elementEditor.elementEditorName()/].refresh(); -} -[/template] - -[comment ======== AddFilter signature implementation ======/] -[template public addFilterSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String)] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#addFilter[elementEditor.viewPackageSignature()/](ViewerFilter filter) - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[template public addFilterSignatureImplementation(elementEditor : ElementEditor)] -[elementEditor.addFilterSignature()/] { - [elementEditor.elementEditorName()/].addFilter(filter); - } -[/template] - -[comment ======== AddBusinessFilter signature implementation ======/] -[template public addBusinessFilterSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String)] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#addBusinessFilter[elementEditor.viewPackageSignature()/](ViewerFilter filter) - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[comment ======== IsContainedInXYZTable signature implementation ======/] -[template public isContainedInTableSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String)] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#isContainedIn[elementEditor.viewPackageSignature()/]Table(EObject element) - * [elementEditor.owningViewsRepository().associatedGenModel().generationMark()/] - */ -[/template] - -[comment ======== read only implementation ======/] -[template public setReadOnly (editor : ElementEditor)] -[editor.elementEditorName()/].setEnabled(false); -[editor.elementEditorName()/].setToolTipText([editor.owningViewsRepository().messagesProvider()/].[editor.owningViewString()/]_ReadOnly); -[/template] - -[template public unsetReadOnly (editor : ElementEditor)] -[editor.elementEditorName()/].setEnabled(true); -[/template] - -[template public setRemoveButtonReadOnly (editor : ElementEditor) ] -remove[editor.name.toJavaClassifier()/].setEnabled(false); -remove[editor.name.toJavaClassifier()/].setToolTipText([editor.owningViewsRepository().messagesProvider()/].[editor.owningViewString()/]_ReadOnly); -[/template] - -[template public unsetRemoveButtonReadOnly (editor : ElementEditor) ] -remove[editor.name.toJavaClassifier()/].setEnabled(true); -[/template] - -[template public setAddButtonReadOnly (editor : ElementEditor) ] -add[editor.name.toJavaClassifier()/].setEnabled(false); -add[editor.name.toJavaClassifier()/].setToolTipText([editor.owningViewsRepository().messagesProvider()/].[editor.owningViewString()/]_ReadOnly); -[/template] - -[template public unsetAddButtonReadOnly (editor : ElementEditor) ] -add[editor.name.toJavaClassifier()/].setEnabled(true); -[/template] - -[template public setEditButtonReadOnly (editor : ElementEditor) ] -edit[editor.name.toJavaClassifier()/].setEnabled(false); -edit[editor.name.toJavaClassifier()/].setToolTipText([editor.owningViewsRepository().messagesProvider()/].[editor.owningViewString()/]_ReadOnly); -[/template] - -[template public unsetEditButtonReadOnly (editor : ElementEditor) ] -edit[editor.name.toJavaClassifier()/].setEnabled(true); -[/template] - -[template public readOnly (editor : ElementEditor)] -[if (editor.readOnly)] -[editor.setReadOnly()/] -[else] -boolean eefElementEditorReadOnlyState = isReadOnly([editor.editorID()/][navigationReadOnly()/]); -if (eefElementEditorReadOnlyState && [editor.elementEditorName()/].isEnabled()) { - [editor.setReadOnly()/] -} else if (!eefElementEditorReadOnlyState && ![editor.elementEditorName()/].isEnabled()) { - [editor.unsetReadOnly()/] -} -[/if] -[/template] - -[template public navigationReadOnly (editor : ElementEditor) post (trim())] -[if (editor.involvedPropertiesEditionElement().canGeneratemodelNavigation())] - , (([addImports(Sequence{editor.getPecImport()})/][editor.involvedPropertiesEditionElement().eContainer(PropertiesEditionComponent).subPECClass(editor.owningView())/]) propertiesEditionComponent).get[editor.involvedPropertiesEditionElement().name.toJavaClassifier()/]Settings().getOrCreateSignificantObject() -[/if] -[/template] - -[template public getPecImport(editor : ElementEditor) post (trim())] -[editor.involvedPropertiesEditionElement().eContainer(PropertiesEditionComponent).componentsPackage()/].[editor.involvedPropertiesEditionElement().eContainer(PropertiesEditionComponent).subPECClass(editor.owningView())/] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetSWTImpl.mtl deleted file mode 100644 index 1e6b089f8..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/api/widgetSWTImpl.mtl +++ /dev/null @@ -1,90 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module widgetSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore')/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case DEFAULT = NEED TO BE THE LAST CHOICE ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) /] - -[template public widgetDeclaration(editor : ElementEditor)] -//FIXME INVALID CASE INTO template public widgetDeclaration(editor : ElementEditor) in SWT Impl for ElementEditor [editor.name/] -[/template] - -[template public implementation(editor : ViewElement)] -//FIXME INVALID CASE INTO template public implementation(editor : ViewElement) in SWT Impl for ViewElement [editor.name/] -[/template] - -[template public additionalImplementation(editor : ViewElement, pec : PropertiesEditionComponent, inputPEC : PropertiesEditionComponent)] -//FIXME INVALID CASE INTO template public additionalImplementation(editor : ViewElement, pec : PropertiesEditionComponent, inputPEC : PropertiesEditionComponent) in SWT Impl for ViewElement [editor.name/] -[/template] - -[comment ===== ViewReference support ===== /] -[template public widgetDeclaration(reference : ViewReference)] - private [include(reference.view.oclAsType(View).pepQualifiedInterface())/] [reference.view.oclAsType(View).pepInterface().toLowerFirst()/]; -[/template] - -[template public implementation(reference : ViewReference)] -return create[reference.view.name.toJavaClassifier()/](parent); -[/template] - -[template public additionalImplementation(reference : ViewReference, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent)][let referencedView : View = reference.view.oclAsType(View)] - protected Composite create[referencedView.name.toJavaClassifier()/](Composite container) { - [include('org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider')/] provider = [include('org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService')/].getInstance().getProvider([include(referencedView.owningViewsRepository().vrQualifiedClass())/].class); - [referencedView.pepInterface().toLowerFirst()/] = ([referencedView.pepInterface()/])provider.getPropertiesEditionPart([referencedView.editorID()/].class, [referencedView.owningViewsRepository().vrClass()/].SWT_KIND, propertiesEditionComponent); - ((ISWTPropertiesEditionPart)[referencedView.pepInterface().toLowerFirst()/]).createControls(container); - return container; - } -[/let] -[/template] - -[template public widgetDeclarationForViewReference(view : View)] -[for (element : ViewReference | view.eAllContents(ViewReference))] -[element.widgetDeclaration()/] -[/for] -[/template] - -[comment ===== SubView support ===== /] -[template public widgetDeclaration(subView : View)] - private [include(subView.pepQualifiedInterface())/] [subView.pepInterface().toLowerFirst()/]; -[/template] - -[template public implementation(view : View)] - if (propertiesEditionComponent.mustBeComposed([view.editorID()/].class, [view.owningViewsRepository().vrClass()/].SWT_KIND)) - return create[view.name.toJavaClassifier()/]SubView(parent); -[/template] - -[template public additionalImplementation(view : View, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent)] - protected Composite create[view.name.toJavaClassifier()/]SubView(Composite container) { - [include('org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider')/] provider = [include('org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService')/].getInstance().getProvider([include(view.owningViewsRepository().vrQualifiedClass())/].class); - [view.pepInterface().toLowerFirst()/] = ([view.pepInterface()/])provider.getPropertiesEditionPart([view.editorID()/].class, [view.owningViewsRepository().vrClass()/].SWT_KIND, propertiesEditionComponent); - ((ISWTPropertiesEditionPart)[view.pepInterface().toLowerFirst()/]).createControls(container); - return container; - } -[/template] - -[template public widgetDeclarationForSubViews(view : View)] -[for (element : View | view.elements->filter(View))] -[element.widgetDeclaration()/] -[/for] -[/template] - -[comment --------------- Views related queries --------------- /] - -[query public editionPart(editor : ViewElement) : String = - if (editor.container.oclIsTypeOf(views::Container)) then editor.container.editionPart() - else editor.container.oclAsType(View).pepClass() - endif/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxControl.mtl deleted file mode 100644 index eb4db93c0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxControl.mtl +++ /dev/null @@ -1,70 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module checkboxControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] - -[comment ===== Case : model = Attribute(1) - view = Checkbox ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Checkbox') and not editionElement.canGeneratemodelNavigation())] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/]((Boolean)event.getNewValue()); -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Checkbox'))] -[if (editionElement.model.oclAsType(EAttribute).isBoolean())] -if ([editionElement.liveUpdaterNavigationCondition(pec)/] && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[else] -//FIXME invalid case in liveUpdater(), Case : model = Attribute(1) : [editionElement.model.name/] - view = Checkbox -[/if] -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Checkbox') and not editionElement.canGeneratemodelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [if (editionElement.model.oclAsType(EAttribute).isBoolean())] - [if (editionElement.model.many)] - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([pec.pecModelClass().toJavaIdentifier()/].[editionElement.model.booleanGetter()/][editionElement.model.name.toMany().toUpperFirst()/]()); - [else] - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([pec.pecModelClass().toJavaIdentifier()/].[editionElement.model.booleanGetter()/][editionElement.model.name.toUpperFirst()/]()); - [/if] - [elseif (editionElement.model.oclAsType(EAttribute).isBoolean())] - [if (editionElement.model.many)] - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toMany().toUpperFirst()/]()); - [else] - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]()); - [/if] - [else] - //FIXME invalid case in updater(), Case : model = Attribute(1) : [editionElement.model.name/] - view = Checkbox - [/if] -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Checkbox'))] -[comment no filters for checkbox /] -[/template] - -[comment ===== Case : model = Attribute(1) - view = Checkbox - ModelNavigation ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Checkbox') and editionElement.canGeneratemodelNavigation())] -[editionElement.name.toJavaIdentifier()/]Settings.setValue((Boolean)event.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Checkbox') and editionElement.canGeneratemodelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [if (editionElement.model.oclAsType(EAttribute).isBoolean())] - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]((Boolean)[editionElement.name.toJavaIdentifier()/]Settings.getValue()); - [else] - //FIXME invalid case in updater(), Case : model = Attribute(1) : [editionElement.model.name/] - view = Checkbox - [/if] -} -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxFormImpl.mtl deleted file mode 100644 index d4f063bb8..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxFormImpl.mtl +++ /dev/null @@ -1,72 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module checkboxFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case Widget = Checkbox ===== /] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Checkbox')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'Checkbox')] - protected [include('org.eclipse.swt.widgets.Button')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'Checkbox')] -return create[editor.name.toJavaClassifier()/]Checkbox(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'Checkbox')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]Checkbox(FormToolkit widgetFactory, Composite parent) { - [editor.elementEditorName()/] = widgetFactory.createButton(parent, getDescription([editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]), SWT.CHECK); - [editor.elementEditorName()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean([editor.elementEditorName()/].getSelection()))); - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 2; - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - EditingUtils.setID([editor.elementEditorName()/], [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/], "eef::[editor.representation.name/]"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('Checkbox'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxGettersSetters.mtl deleted file mode 100644 index 2cbd56872..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxGettersSetters.mtl +++ /dev/null @@ -1,34 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module checkboxGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('Checkbox'))] -[elementEditor.getterSignature()/] { - return Boolean.valueOf([elementEditor.elementEditorName()/].getSelection()); - } -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('Checkbox'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].setSelection(newValue.booleanValue()); - } else { - [elementEditor.elementEditorName()/].setSelection(false); - } - [elementEditor.readOnly()/] - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxSWTImpl.mtl deleted file mode 100644 index 5346836de..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/checkbox/checkboxSWTImpl.mtl +++ /dev/null @@ -1,72 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module checkboxSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case Widget = Checkbox ===== /] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Checkbox')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'Checkbox')] - protected [include('org.eclipse.swt.widgets.Button')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'Checkbox')] -return create[editor.name.toJavaClassifier()/]Checkbox(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'Checkbox')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]Checkbox(Composite parent) { - [editor.elementEditorName()/] = new Button(parent, SWT.CHECK); - [editor.elementEditorName()/].setText(getDescription([editor.editorID() /], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/])); - [editor.elementEditorName()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean([editor.elementEditorName()/].getSelection()))); - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 2; - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - EditingUtils.setID([editor.elementEditorName()/], [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/], "eef::[editor.representation.name/]"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('Checkbox'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboControl.mtl deleted file mode 100644 index a2897a05d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboControl.mtl +++ /dev/null @@ -1,109 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module comboControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::filters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case : model = Reference - view = Combo ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isReferenceSingle() and editionElement.representationName('Combo') and not editionElement.canGeneratemodelNavigation())] -[pec.model.name.toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](!"".equals(event.getNewValue()) ? ([include(editionElement.peeModelQualifiedClass())/]) event.getNewValue() : null); -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isReferenceSingle() and editionElement.representationName('Combo'))] -if ([editionElement.liveUpdaterNavigationCondition(pec)/] && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isReferenceSingle() and editionElement.representationName('Combo') and not editionElement.canGeneratemodelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.impl.utils.EEFUtils')/].choiceOfValues([pec.model.name.toJavaIdentifier()/], [editionElement.metamodelGetter()/]), [pec.model.name.toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]()); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isReferenceSingle() and editionElement.representationName('Combo'))] -[for (filter : BindingFilter | editionElement.bindingFilters)] -[filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] -[additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -[/template] - -[comment ===== Case : model = Reference - view = Combo - ModelNavigation ===== /] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isReferenceSingle() and editionElement.representationName('Combo') and editionElement.canGeneratemodelNavigation())] -[editionElement.name.toJavaIdentifier()/]Settings.setValue(!"".equals(event.getNewValue()) ? ([include(editionElement.peeModelQualifiedClass())/]) event.getNewValue() : null); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isReferenceSingle() and editionElement.representationName('Combo') and editionElement.canGeneratemodelNavigation())] -if ([editionElement.name.toJavaIdentifier()/]Settings.getSignificantObject() != null && isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.impl.utils.EEFUtils')/].choiceOfValues([editionElement.name.toJavaIdentifier()/]Settings.getSignificantObject(), [editionElement.metamodelGetter()/]), [editionElement.name.toJavaIdentifier()/]Settings.getValue()); -} -[/template] - -[comment ===== Case : model = Attribute - view = Combo ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Combo') and not editionElement.canGeneratemodelNavigation())][pec.pecModelClass().toJavaIdentifier()/].set[editionElement.model.name.toUpperFirst()/](([editionElement.model.eType.instanceClass/])event.getNewValue()); -[pec.model.name.toJavaIdentifier()/].set[editionElement.model.name.toUpperFirst()/](([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Combo'))] -if ([editionElement.liveUpdaterNavigationCondition(pec)/] && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Combo') and not editionElement.canGeneratemodelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [if (pec.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [defaultInitialization()/] - [else] - // [protected ('for '.concat(editionElement.name).concat(' editor initialization'))] - [defaultInitialization()/] - // [/protected] - [/if] - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/](input[editionElement.name.toJavaClassifier()/], [pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]()); -} -[/template] - -[template private defaultInitialization(editionElement : PropertiesEditionElement) ] -java.util.Collection input[editionElement.name.toJavaClassifier()/] = new ArrayList(3); -input[editionElement.name.toJavaClassifier()/].add("one"); -input[editionElement.name.toJavaClassifier()/].add("two"); -input[editionElement.name.toJavaClassifier()/].add("three"); -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Combo'))] -[/template] - -[comment ===== Case : model = Attribute - view = Combo - ModelNavigation ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Combo') and editionElement.canGeneratemodelNavigation())] -[editionElement.name.toJavaIdentifier()/]Settings.setValue(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Combo') and editionElement.canGeneratemodelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [if (pec.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [defaultInitialization()/] - [else] - // [protected ('for '.concat(editionElement.name).concat(' editor initialization'))] - [defaultInitialization()/] - // [/protected] - [/if] - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/](input[editionElement.name.toJavaClassifier()/], [editionElement.name.toJavaIdentifier()/]Settings.getValue()); -} -[/template] - - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboFormImpl.mtl deleted file mode 100644 index bb8a6c9ef..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboFormImpl.mtl +++ /dev/null @@ -1,78 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module comboFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = Combo ===== /] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Combo')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.providers.EMFListContentProvider', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'Combo')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'Combo')] -return create[editor.name.toJavaClassifier()/]EMFComboViewer(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'Combo')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]EMFComboViewer(FormToolkit widgetFactory, Composite parent) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new EMFComboViewer(parent); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].getCombo().setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - [editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, get[editor.name.toJavaClassifier()/]())); - } - - }); - [editor.elementEditorName()/].setContentProvider(new EMFListContentProvider()); - EditingUtils.setID([editor.elementEditorName()/].getCombo(), [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/].getCombo(), "eef::[editor.representation.name/]"); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('EMFComboViewer'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboGettersSetters.mtl deleted file mode 100644 index c5e3ec645..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboGettersSetters.mtl +++ /dev/null @@ -1,127 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module comboGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[import org::eclipse::emf::eef::codegen::services::common/] -[import org::eclipse::emf::eef::codegen::services::naming/] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('Combo'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; - -[elementEditor.addFilterSignatureDocumentation()/] -[elementEditor.addFilterSignature()/]; -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('Combo'))] - public void init[elementEditor.viewPackageSignature()/](Object input, Object currentValue) -[/template] - - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('Combo'))] - /** - * Init the [elementEditor.name/] - * @param input choice of values - * @param currentValue the current value - */ -[/template] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('Combo'))] -[elementEditor.getterSignature()/] { - if ([elementEditor.elementEditorName()/].getSelection() instanceof [include('org.eclipse.jface.viewers.StructuredSelection')/]) { - return ((StructuredSelection) [elementEditor.elementEditorName()/].getSelection()).getFirstElement(); - } - return ""; - } -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('Combo'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignatureImplementation()/] - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('Combo'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](allResources, current); - } - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/](newValue); - } - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addBusinessFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('Combo'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].modelUpdating(new StructuredSelection(newValue)); - } else { - [elementEditor.elementEditorName()/].modelUpdating(new StructuredSelection("")); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] - -[template public setterButtonModeSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) ? (elementEditor.representationName('Combo'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#[elementEditor.viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/] newValue) - */ -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides initSignatureDocumentationImplementation ? (elementEditor.representationName('Combo'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](Object input, Object currentValue) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('Combo'))] -[elementEditor.initSignature()/] { - [elementEditor.elementEditorName()/].setInput(input); - if (currentValue != null) { - [elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](currentValue)); - } - } -[/template] - -[template public addBusinessFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('Combo'))] -[elementEditor.addBusinessFilterSignature()/] { - [elementEditor.elementEditorName()/].addBusinessRuleFilter(filter); - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboSWTImpl.mtl deleted file mode 100644 index 3634d09ba..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/combo/comboSWTImpl.mtl +++ /dev/null @@ -1,77 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module comboSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = Combo ===== /] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Combo')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.providers.EMFListContentProvider', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'Combo')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'Combo')] -return create[editor.name.toJavaClassifier()/]EMFComboViewer(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'Combo')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]EMFComboViewer(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new EMFComboViewer(parent); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].getCombo().setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - [editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, get[editor.name.toJavaClassifier()/]())); - } - - }); - [editor.elementEditorName()/].setContentProvider(new EMFListContentProvider()); - EditingUtils.setID([editor.elementEditorName()/].getCombo(), [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/].getCombo(), "eef::[editor.representation.name/]"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('EMFComboViewer'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customControl.mtl deleted file mode 100644 index 606a00053..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customControl.mtl +++ /dev/null @@ -1,45 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module customControl('http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::common /] - -[comment ===== Case : model = any - view = CustomElementEditor ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.views->first().oclIsTypeOf(CustomElementEditor))] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] -// [protected ('for update'.concat(editionElement.name.toJavaClassifier()).concat(' method body'))] -// [/protected] -[/if] -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.views->first().oclIsTypeOf(CustomElementEditor))] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - // [protected ('for '.concat(editionElement.name).concat(' live update'))] - - // [/protected] -[/if] -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.views->first().oclIsTypeOf(CustomElementEditor))] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] -// [protected (' for '.concat(editionElement.name).concat(' command update'))] -// [/protected] -[/if] -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.views->first().oclIsTypeOf(CustomElementEditor))] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] -// [protected (' for '.concat(editionElement.name).concat(' filter update'))] -// [/protected] -[/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customFormImpl.mtl deleted file mode 100644 index 3d8db32e2..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customFormImpl.mtl +++ /dev/null @@ -1,31 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module customFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl /] - -[import org::eclipse::emf::eef::codegen::services::common /] - -[template public widgetDeclaration(editor : CustomElementEditor) overrides widgetDeclaration] - [if (not editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - // [protected (' for '.concat(editor.name).concat(' widgets declarations'))] - - // [/protected] - [/if] -[/template] - -[template public implementation(editor : CustomElementEditor) overrides implementation] -[if (not editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - // [protected ('for '.concat(editor.name).concat(' widgets implementation'))] - - // [/protected] -[/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customSWTImpl.mtl deleted file mode 100644 index d727cdba6..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/custom/customSWTImpl.mtl +++ /dev/null @@ -1,32 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module customSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] - -[template public widgetDeclaration(editor : CustomElementEditor) overrides widgetDeclaration] - [if (not editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - // [protected (' for '.concat(editor.name).concat(' widgets declarations'))] - - // [/protected] - [/if] -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.oclIsTypeOf(views::CustomElementEditor))] - [if (not editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - // [protected ('for '.concat(editor.name).concat(' implementation'))] - - // [/protected] - [/if] -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerControl.mtl deleted file mode 100644 index 008585304..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerControl.mtl +++ /dev/null @@ -1,54 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module emfcomboviewerControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case : model = Attribute(1) - view = EMFComboViewer ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('EMFComboViewer') and not editionElement.canGeneratemodelNavigation())] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('EMFComboViewer'))] -[if (editionElement.model.oclAsType(EAttribute).isEnum())] -if ([editionElement.liveUpdaterNavigationCondition(pec)/] && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([include(editionElement.peeModelQualifiedClass())/])msg.getNewValue()); -[else] -//FIXME invalid case in liveUpdater(), Case : model = Attribute(1) : [editionElement.model.name/] - view = EMFComboViewer -[/if] -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('EMFComboViewer') and not editionElement.canGeneratemodelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.impl.utils.EEFUtils')/].choiceOfValues([pec.model.name.toJavaIdentifier()/], [editionElement.metamodelGetter()/]), [pec.model.name.toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]()); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('EMFComboViewer'))] -[comment no filters for emfcomboviewer /] -[/template] - -[comment ===== Case : model = Attribute(1) - view = EMFComboViewer - ModelNavigation ===== /] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('EMFComboViewer') and editionElement.canGeneratemodelNavigation())] -[editionElement.name.toJavaIdentifier()/]Settings.setValue(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('EMFComboViewer') and editionElement.canGeneratemodelNavigation())] -if ([editionElement.name.toJavaIdentifier()/]Settings.getSignificantObject() != null && isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.impl.utils.EEFUtils')/].choiceOfValues([editionElement.name.toJavaIdentifier()/]Settings.getSignificantObject(), [editionElement.metamodelGetter()/]), ([editionElement.views->first().toJavaType().trim()/])[editionElement.name.toJavaIdentifier()/]Settings.getValue()); -} -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerFormImpl.mtl deleted file mode 100644 index 0b7a68473..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerFormImpl.mtl +++ /dev/null @@ -1,78 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module emfcomboviewerFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'EMFComboViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.common.util.Enumerator', - 'org.eclipse.emf.ecore.util.EcoreAdapterFactory', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.emf.eef.runtime.EEFRuntimePlugin', - 'org.eclipse.jface.viewers.ArrayContentProvider', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'EMFComboViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'EMFComboViewer')] -return create[editor.name.toJavaClassifier()/]EMFComboViewer(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'EMFComboViewer')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]EMFComboViewer(FormToolkit widgetFactory, Composite parent) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new EMFComboViewer(parent); - [editor.elementEditorName()/].setContentProvider(new ArrayContentProvider()); - [editor.elementEditorName()/].setLabelProvider(new AdapterFactoryLabelProvider(EEFRuntimePlugin.getDefault().getAdapterFactory())); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].getCombo().setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.viewCompletePackageGetter()/])); - } - - }); - [editor.elementEditorName()/].setID([editor.editorID()/]); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('EMFComboViewer'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerGettersSetters.mtl deleted file mode 100644 index 766483fc0..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerGettersSetters.mtl +++ /dev/null @@ -1,89 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module emfcomboviewerGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('EMFComboViewer'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('EMFComboViewer'))] - public void init[elementEditor.viewPackageSignature()/](Object input, [include('org.eclipse.emf.ecore.Enumerator')/] current) -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('EMFComboViewer'))] - /** - * Init the [elementEditor.name/] - * @param input the viewer input - * @param current the current value - */ -[/template] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('EMFComboViewer'))] -[elementEditor.getterSignature()/] { - [include('org.eclipse.emf.ecore.Enumerator')/] selection = (Enumerator) (([include('org.eclipse.jface.viewers.StructuredSelection')/]) [elementEditor.elementEditorName()/].getSelection()).getFirstElement(); - return selection; - } -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('EMFComboViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('EMFComboViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](input, current); - } - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/](newValue); - } -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('EMFComboViewer'))] -[elementEditor.initSignature()/] { - [elementEditor.elementEditorName()/].setInput(input); - [elementEditor.elementEditorName()/].modelUpdating(new StructuredSelection(current)); - [elementEditor.readOnly()/] - } -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('EMFComboViewer'))] -[elementEditor.setterSignature()/] { - [elementEditor.elementEditorName()/].modelUpdating(new StructuredSelection(newValue)); - [elementEditor.readOnly()/] - } -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides initSignatureDocumentationImplementation ? (elementEditor.representationName('EMFComboViewer'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](Object input, Enumerator current) - */ -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerSWTImpl.mtl deleted file mode 100644 index fae015f78..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/emfcomboviewer/emfcomboviewerSWTImpl.mtl +++ /dev/null @@ -1,76 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module emfcomboviewerSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'EMFComboViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.common.util.Enumerator', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.EEFRuntimePlugin', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.jface.viewers.ArrayContentProvider', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'EMFComboViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'EMFComboViewer')] -return create[editor.name.toJavaClassifier()/]EMFComboViewer(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'EMFComboViewer')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]EMFComboViewer(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new EMFComboViewer(parent); - [editor.elementEditorName()/].setContentProvider(new ArrayContentProvider()); - [editor.elementEditorName()/].setLabelProvider(new AdapterFactoryLabelProvider(EEFRuntimePlugin.getDefault().getAdapterFactory())); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].getCombo().setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.viewCompletePackageGetter()/])); - } - - }); - [editor.elementEditorName()/].setID([editor.editorID()/]); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('EMFComboViewer'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerControl.mtl deleted file mode 100644 index 59986bd0c..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerControl.mtl +++ /dev/null @@ -1,258 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module eobjectflatcomboviewerControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::filters /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case : model = Reference(1) - view = EObjectFlatComboViewer or AdvancedEObjectFlatComboViewer ===== /] -[query public validCaseForSingleReference(editionElement : PropertiesEditionElement) : Boolean = - (not editionElement.hasModelNavigation()) - and editionElement.model.isReferenceSingle() - and (editionElement.representationName('EObjectFlatComboViewer') or editionElement.representationName('AdvancedEObjectFlatComboViewer'))/] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForSingleReference())] - -/** - * Settings for [editionElement.name/] EObjectFlatComboViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForSingleReference())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [if (not editionElement.model.eType.oclAsType(EClass).abstract)] - [include(editionElement.peeModelQualifiedClass())/] eObject = [editionElement.factoryCreator()/]; - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(eObject); - [else] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] - [/if] -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForSingleReference())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForSingleReference()) ] -if (isAccessible([editionElement.views->first().editorID()/])) { - // init part - [editionElement.name.toJavaIdentifier()/]Settings = new EObjectFlatComboSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); - // set the button mode - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/].BROWSE); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (not editionElement.hasModelNavigation() and editionElement.model.isReferenceSingle() and (editionElement.representationName('EObjectFlatComboViewer')))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - return [if (editionElement.model.lowerBound = 0)](element instanceof String && element.equals("")) || [/if](element instanceof [include(editionElement.peeModelQualifiedClass())/]);[if (editionElement.model.lowerBound = 0)] //$NON-NLS-1$ [/if] - } - - }); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (not editionElement.hasModelNavigation() and editionElement.model.isReferenceSingle() and (editionElement.representationName('AdvancedEObjectFlatComboViewer')))] -[/template] - -[comment ===== Case : model = Simple Navigation A (0-1) -> B (0-1) -> C - view = EObjectFlatComboViewer or AdvancedEObjectFlatComboViewer ===== /] -[query public validCaseForContainmentNavigation(editionElement : PropertiesEditionElement) : Boolean = - editionElement.hasModelNavigation() - and (editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isReferenceSingle())) - and (editionElement.representationName('EObjectFlatComboViewer') or editionElement.representationName('AdvancedEObjectFlatComboViewer')) /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForContainmentNavigation())] - -/** - * Settings for [editionElement.name/] EObjectFlatComboViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForContainmentNavigation())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [if (not editionElement.model.eType.oclAsType(EClass).abstract)] - [include(editionElement.peeModelQualifiedClass())/] eObject = [editionElement.factoryCreator()/]; - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(eObject); - [else] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] - [/if] -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForContainmentNavigation())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForContainmentNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - // init part - [editionElement.name.toJavaIdentifier()/]Settings = new EObjectFlatComboSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).metamodelGetter()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); - // set the button mode - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/].BROWSE); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.hasModelNavigation() and editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isReferenceSingle() and (editionElement.representationName('EObjectFlatComboViewer'))))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - return [if (editionElement.model.lowerBound = 0)](element instanceof String && element.equals("")) || [/if](element instanceof [include(editionElement.peeModelQualifiedClass())/]);[if (editionElement.model.lowerBound = 0)] //$NON-NLS-1$ [/if] - } - - }); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.hasModelNavigation() and editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isReferenceSingle() and (editionElement.representationName('AdvancedEObjectFlatComboViewer'))))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter')/]([editionElement.metamodelTypeGetter()/])); -} -[/template] - -[comment ===== Case : model = Containment(1), Simple navigation or not - view = EObjectFlatComboViewer or AdvancedEObjectFlatComboViewer ===== /] -[query public validCaseForContainment(editionElement : PropertiesEditionElement) : Boolean = - editionElement.model.isContainmentSingle() - and (editionElement.representationName('EObjectFlatComboViewer') or editionElement.representationName('AdvancedEObjectFlatComboViewer')) /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForContainment())] - -/** - * Settings for [editionElement.name/] EObjectFlatComboViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForContainment())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [if (not editionElement.model.eType.oclAsType(EClass).abstract)] - [include(editionElement.peeModelQualifiedClass())/] eObject = [editionElement.factoryCreator()/]; - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(eObject); - [else] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] - [/if] -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForContainment())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForContainment() and not editionElement.hasModelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - // init part - [editionElement.name.toJavaIdentifier()/]Settings = new EObjectFlatComboSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); - // set the button mode - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/].CREATE); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForContainment())] -[comment no filters on creation/] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerFormImpl.mtl deleted file mode 100644 index 6fa81a4b1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerFormImpl.mtl +++ /dev/null @@ -1,143 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module eobjectflatcomboviewerFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = EObjectFlatComboViewer ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'EObjectFlatComboViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'EObjectFlatComboViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'EObjectFlatComboViewer')] -return create[editor.name.toJavaClassifier()/]FlatComboViewer(parent, widgetFactory); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'EObjectFlatComboViewer')] - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]FlatComboViewer(Composite parent, FormToolkit widgetFactory) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [editor.owningViewsRepository().messagesProvider()/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - widgetFactory.adapt([editor.elementEditorName()/]); - [editor.elementEditorName()/].setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, get[editor.name.toJavaClassifier()/]())); - } - - }); - [editor.elementEditorName()/].setID([editor.editorID()/]); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('FlatComboViewer'))] - - // [/protected] - return parent; - } -[/template] - -[comment ===== Case Widget = AdvancedEObjectFlatComboViewer ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'AdvancedEObjectFlatComboViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.AbstractAdvancedEObjectFlatComboViewer.EObjectFlatComboViewerListener', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'AdvancedEObjectFlatComboViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.AdvancedEObjectFlatComboViewer')/] [editor.elementEditorName()/]; - protected [include('org.eclipse.jface.viewers.ViewerFilter')/] [editor.elementEditorName()/]Filter; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'AdvancedEObjectFlatComboViewer')] -return create[editor.name.toJavaClassifier()/]FlatComboViewer(parent, widgetFactory); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'AdvancedEObjectFlatComboViewer')] - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]FlatComboViewer(Composite parent, FormToolkit widgetFactory) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - // create callback listener - EObjectFlatComboViewerListener listener = new EObjectFlatComboViewerListener(){ - public void handleSet(EObject element){ - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, element)); - } - public void navigateTo(EObject element){ } - - public EObject handleCreate() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, null)); - return [editor.viewCompletePackageGetter()/]; - } - - public void handleEdit(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, element)); - } - - }; - //create widget - [editor.elementEditorName()/] = new AdvancedEObjectFlatComboViewer([editor.owningViewsRepository().messagesProvider()/].[editor.editorKey(editor.owningView())/], resourceSet, [editor.elementEditorName()/]Filter, propertiesEditionComponent.getEditingContext().getAdapterFactory(), listener); - [editor.elementEditorName()/].createControls(parent, widgetFactory); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setID([editor.editorID()/]); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('FlatComboViewer'))] - - // [/protected] - return parent; - } - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerGettersSetters.mtl deleted file mode 100644 index 177f5c918..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerGettersSetters.mtl +++ /dev/null @@ -1,173 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module eobjectflatcomboviewerGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('EObjectFlatComboViewer') or elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; - -[elementEditor.setterButtonModeSignatureDocumentation()/] -[elementEditor.setterButtonModeSignature()/]; - -[elementEditor.addFilterSignatureDocumentation()/] -[elementEditor.addFilterSignature()/]; - -[elementEditor.addBusinessFilterSignatureDocumentation()/] -[elementEditor.addBusinessFilterSignature()/]; -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('EObjectFlatComboViewer') or elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] - /** - * Init the [elementEditor.name/] - * @param settings the combo setting - */ -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('EObjectFlatComboViewer') or elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] - public void init[elementEditor.viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] settings) -[/template] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('EObjectFlatComboViewer'))] -[elementEditor.getterSignature()/] { - if ([elementEditor.elementEditorName()/].getSelection() instanceof [include('org.eclipse.jface.viewers.StructuredSelection')/]) { - Object firstElement = ((StructuredSelection) [elementEditor.elementEditorName()/].getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } -[/template] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] -[elementEditor.getterSignature()/] { - return [elementEditor.elementEditorName()/].getSelection(); - } -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('EObjectFlatComboViewer') or elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignatureImplementation()/] - -[setterButtonModeSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterButtonModeSignatureImplementation()/] - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignatureImplementation()/] - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('EObjectFlatComboViewer') or elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](settings); - } - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/](newValue); - } - -[setterButtonModeSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterButtonModeSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/]ButtonMode(newValue); - } - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addBusinessFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('EObjectFlatComboViewer'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](newValue)); - } else { - [elementEditor.elementEditorName()/].setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](newValue)); - } else { - [elementEditor.elementEditorName()/].setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] - -[template public setterButtonModeSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) ? (elementEditor.representationName('EObjectFlatComboViewer') or elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#[elementEditor.viewPackageSetter()/]ButtonMode(ButtonsModeEnum newValue) - */ -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) ? (elementEditor.representationName('EObjectFlatComboViewer') or elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](EObjectFlatComboSettings) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('EObjectFlatComboViewer'))] -[elementEditor.initSignature()/] { - [elementEditor.elementEditorName()/].setInput(settings); - if (current != null) { - [elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](settings.getValue())); - } - [elementEditor.readOnly()/] - } -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] -[elementEditor.initSignature()/] { - [elementEditor.elementEditorName()/].setInput(settings); - if (current != null) { - [elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](settings.getValue())); - } - [elementEditor.readOnly()/] - } -[/template] - -[template public addBusinessFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('EObjectFlatComboViewer') or elementEditor.representationName('AdvancedEObjectFlatComboViewer'))] -[elementEditor.addBusinessFilterSignature()/] { - [elementEditor.elementEditorName()/].addBusinessRuleFilter(filter); - } -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerSWTImpl.mtl deleted file mode 100644 index ecfaf96a2..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/eobjectflatcomboviewer/eobjectflatcomboviewerSWTImpl.mtl +++ /dev/null @@ -1,132 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module eobjectflatcomboviewerSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = EObjectFlatComboViewer ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports? (widget.name = 'EObjectFlatComboViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'EObjectFlatComboViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'EObjectFlatComboViewer')] -return create[editor.name.toJavaClassifier()/]FlatComboViewer(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'EObjectFlatComboViewer')] - /** - * @param parent the parent composite - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]FlatComboViewer(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [editor.elementEditorName()/].setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - [editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, get[editor.name.toJavaClassifier()/]())); - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setID([editor.editorID()/]); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('FlatComboViewer'))] - - // [/protected] - return parent; - } -[/template] - -[comment ===== Case Widget = AdvancedEObjectFlatComboViewer ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'AdvancedEObjectFlatComboViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.AbstractAdvancedEObjectFlatComboViewer.EObjectFlatComboViewerListener', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'AdvancedEObjectFlatComboViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.AdvancedEObjectFlatComboViewer')/] [editor.elementEditorName()/]; - protected [include('org.eclipse.jface.viewers.ViewerFilter')/] [editor.elementEditorName()/]Filter; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'AdvancedEObjectFlatComboViewer')] -return create[editor.name.toJavaClassifier()/]AdvancedFlatComboViewer(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'AdvancedEObjectFlatComboViewer')] - /** - * @param parent the parent composite - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]AdvancedFlatComboViewer(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - // create callback listener - EObjectFlatComboViewerListener listener = new EObjectFlatComboViewerListener(){ - public void handleSet(EObject element){ - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, element)); - } - public void navigateTo(EObject element){ } - - public EObject handleCreate() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, null)); - return [editor.viewCompletePackageGetter()/]; - } - - public void handleEdit(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, element)); - } - }; - //create widget - [editor.elementEditorName()/] = new AdvancedEObjectFlatComboViewer(getDescription([editor.editorID()/], [editor.owningViewsRepository().messagesProvider()/].[editor.editorKey(editor.owningView())/]), resourceSet, [editor.elementEditorName()/]Filter, propertiesEditionComponent.getEditingContext().getAdapterFactory(), listener); - [editor.elementEditorName()/].createControls(parent); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setID([editor.editorID()/]); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('AdvancedFlatComboViewer'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerControl.mtl deleted file mode 100644 index 087f3d496..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerControl.mtl +++ /dev/null @@ -1,184 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module ereferencesviewerControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::filters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case : model = Reference(*) - view = EReferencesViewer===== /] -[query public validCaseForSimpleReference(editionElement : PropertiesEditionElement) : Boolean = - (not editionElement.hasModelNavigation()) - and editionElement.model.isReferenceMany() - and editionElement.representationName('EReferencesViewer') /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForSimpleReference())] - -/** - * Settings for [editionElement.name/] EReferencesViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForSimpleReference())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].ADD) { - if (event.getNewValue() instanceof [include(editionElement.peeModelQualifiedClass())/]) { - [editionElement.name.toJavaIdentifier()/]Settings.addToReference((EObject) event.getNewValue()); - } -} else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.removeFromReference((EObject) event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.MOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.move(event.getNewIndex(), ([editionElement.peeModelClass()/]) event.getNewValue()); -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForSimpleReference())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForSimpleReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForSimpleReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter')/]([editionElement.metamodelTypeGetter()/])); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] - -[comment ===== Case : model = Reference(*) in Simple Navigation - view = EReferencesViewer===== /] -[query public validCaseForMultipleModelReference(editionElement : PropertiesEditionElement) : Boolean = - editionElement.hasModelNavigation() - and (editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isReferenceMany())) - and editionElement.representationName('EReferencesViewer')/] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForMultipleModelReference())] - -/** - * Settings for [editionElement.name/] EReferencesViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForMultipleModelReference())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].ADD) { - if (event.getNewValue() instanceof [include(editionElement.peeModelQualifiedClass())/]) { - [editionElement.name.toJavaIdentifier()/]Settings.addToReference((EObject) event.getNewValue()); - } -} else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.removeFromReference((EObject) event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.MOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.move(event.getNewIndex(), ([editionElement.peeModelClass()/]) event.getNewValue()); -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForMultipleModelReference())] -if ([editionElement.name.toJavaIdentifier()/]Settings.isAffectingFeature((EStructuralFeature)msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForMultipleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).metamodelGetter()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForMultipleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.emf.eef.runtime.impl.filters.EObjectStrictFilter')/]([editionElement.metamodelTypeGetter()/])); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] - -[comment ===== Case : model = Reference(1) - view = EReferencesViewer===== /] -[query public validCaseForSingleModelReference(editionElement : PropertiesEditionElement) : Boolean = - editionElement.hasModelNavigation() - and (editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentMany() and editionElement.model.isReferenceSingle())) - and editionElement.representationName('EReferencesViewer')/] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForSingleModelReference())] - -/** - * Settings for [editionElement.name/] EReferencesViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForSingleModelReference())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].ADD) { - if (event.getNewValue() instanceof [include(editionElement.peeModelQualifiedClass())/]) { - [editionElement.name.toJavaIdentifier()/]Settings.addToReference((EObject) event.getNewValue()); - } -} else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.removeFromReference((EObject) event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.MOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.move(event.getNewIndex(), ([editionElement.peeModelClass()/]) event.getNewValue()); -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForSingleModelReference())] -if ([editionElement.name.toJavaIdentifier()/]Settings.isAffectingFeature((EStructuralFeature)msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -} -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForSingleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).metamodelGetter()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForSingleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - return [if (editionElement.model.lowerBound = 0)](element instanceof String && element.equals("")) || [/if](element instanceof [include(editionElement.peeModelQualifiedClass())/]);[if (editionElement.model.lowerBound = 0)] //$NON-NLS-1$ [/if] - } - - }); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerFormImpl.mtl deleted file mode 100644 index b2718ba28..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerFormImpl.mtl +++ /dev/null @@ -1,149 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module ereferencesviewerFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = AdvancedReferencesTable ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'EReferencesViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'java.util.Iterator', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.IStructuredSelection', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext', - 'org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider', - 'org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy', - 'org.eclipse.emf.eef.runtime.ui.widgets.ElementSelectionDialog', - 'org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'EReferencesViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable')/] [editor.elementEditorName()/]; - protected [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> [editor.elementEditorName()/]BusinessFilters = new [include('java.util.ArrayList')/](); - protected List [editor.elementEditorName()/]Filters = new ArrayList(); -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'EReferencesViewer')] -return create[editor.name.toJavaClassifier()/]ReferencesTable(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'EReferencesViewer')] - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]ReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.[editor.elementEditorName()/] = new ReferencesTable(getDescription([editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]), new ReferencesTableListener () { - public void handleAdd() { add[editor.name.toJavaClassifier()/](); } - public void handleEdit(EObject element) { edit[editor.name.toJavaClassifier()/](element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { move[editor.name.toJavaClassifier()/](element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFrom[editor.name.toJavaClassifier()/](element); } - public void navigateTo(EObject element) { } - }); - this.[editor.elementEditorName()/].setHelpText(propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - this.[editor.elementEditorName()/].createControls(parent, widgetFactory); - this.[editor.elementEditorName()/].addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 3; - this.[editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - this.[editor.elementEditorName()/].disableMove(); - [editor.elementEditorName()/].setID([editor.editorID()/]); - [editor.elementEditorName()/].setEEFType("eef::[editor.representation.name/]"); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('ReferencesTable'))] - - // [/protected] - return parent; - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void add[editor.name.toJavaClassifier()/]() { - [editor.defaultAddOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void move[editor.name.toJavaClassifier()/](EObject element, int oldIndex, int newIndex) { - [editor.defaultMoveOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void removeFrom[editor.name.toJavaClassifier()/](EObject element) { - [editor.defaultRemoveOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void edit[editor.name.toJavaClassifier()/](EObject element) { - [editor.defaultEditOperation()/] - } -[/template] - -[template public defaultAddOperation (editor : ElementEditor) ] -ElementSelectionDialog dialog = new ElementSelectionDialog([editor.elementEditorName()/].getInput(), [editor.elementEditorName()/]Filters, [editor.elementEditorName()/]BusinessFilters, -"[editor.name/]", propertiesEditionComponent.getEditingContext().getAdapterFactory()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - [editor.elementEditorName()/].refresh(); - } -}; -dialog.open(); -[/template] - -[template public defaultMoveOperation (editor : ElementEditor) ] -propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); -[editor.elementEditorName()/].refresh(); -[/template] - -[template public defaultEditOperation (editor : ElementEditor)] -EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); -PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); -if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - [editor.elementEditorName()/].refresh(); - } -} -[/template] - -[template public defaultRemoveOperation (editor : ElementEditor) ] -propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); -[editor.elementEditorName()/].refresh(); -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerGettersSetters.mtl deleted file mode 100644 index 5777f63d9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerGettersSetters.mtl +++ /dev/null @@ -1,150 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module ereferencesviewerGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public getterDeclaration(elementEditor : ElementEditor) overrides getterDeclaration ? (elementEditor.representationName('EReferencesViewer'))] -[/template] - -[template public getterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides getterImplementation ? (elementEditor.representationName('EReferencesViewer'))] -[/template] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('EReferencesViewer'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.updateSignatureDocumentation()/] -[elementEditor.updateSignature()/]; - -[elementEditor.addFilterSignatureDocumentation()/] -[elementEditor.addFilterSignature()/]; - -[elementEditor.addBusinessFilterSignatureDocumentation()/] -[elementEditor.addBusinessFilterSignature()/]; - -[elementEditor.isContainedInTableSignatureDocumentation()/] -[elementEditor.isContainedInTableSignature()/]; -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('EReferencesViewer'))] - public void init[elementEditor.viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] settings) -[/template] - -[template public getterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides getterImplementationDelegate ? (elementEditor.representationName('EReferencesViewer'))] -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('EReferencesViewer'))] - /** - * Init the [elementEditor.name/] - * @param settings settings for the [elementEditor.name/] ReferencesTable - */ -[/template] - - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('EReferencesViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[updateSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.updateSignatureImplementation()/] - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignatureImplementation()/] - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignatureImplementation()/] - -[isContainedInTableSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.isContainedInTableSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('EReferencesViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](settings); - } - -[updateSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.updateSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.update[elementEditor.viewPackageSignature()/](); - } - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addBusinessFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[isContainedInTableSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.isContainedInTableSignature()/] { - return [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.isContainedIn[elementEditor.viewPackageSignature()/]Table(element); - } -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides initSignatureDocumentationImplementation ? (elementEditor.representationName('EReferencesViewer'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('EReferencesViewer'))] -[elementEditor.initSignature()/] { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider')/] contentProvider = new ReferencesTableContentProvider(); - [elementEditor.elementEditorName()/].setContentProvider(contentProvider); - [elementEditor.elementEditorName()/].setInput(settings); - [elementEditor.readOnly()/] - } -[/template] - -[template public addFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('EReferencesViewer'))] -[elementEditor.addFilterSignature()/] { - [elementEditor.elementEditorName()/]Filters.add(filter); - } -[/template] - -[template public addBusinessFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('EReferencesViewer'))] -[elementEditor.addBusinessFilterSignature()/] { - [elementEditor.elementEditorName()/]BusinessFilters.add(filter); - } -[/template] - -[template public isContainedInTableSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('EReferencesViewer'))] -[elementEditor.isContainedInTableSignature()/] { - return ((ReferencesTableSettings)[elementEditor.elementEditorName()/].getInput()).contains(element); - } -[/template] - -[template public readOnly (editor : ElementEditor) overrides readOnly ? (editor.representationName('EReferencesViewer'))] -[if (editor.readOnly)] -[setReadOnly()/] -[else] -boolean eefElementEditorReadOnlyState = isReadOnly([editor.editorID()/][navigationReadOnly()/]); -if (eefElementEditorReadOnlyState && [editor.elementEditorName()/].getTable().isEnabled()) { - [editor.setReadOnly()/] -} else if (!eefElementEditorReadOnlyState && ![editor.elementEditorName()/].getTable().isEnabled()) { - [editor.unsetReadOnly()/] -} -[/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerSWTImpl.mtl deleted file mode 100644 index 757073366..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/ereferencesviewer/ereferencesviewerSWTImpl.mtl +++ /dev/null @@ -1,150 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module ereferencesviewerSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = EReferencesViewer ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'EReferencesViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'java.util.Iterator', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.IStructuredSelection', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext', - 'org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider', - 'org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy', - 'org.eclipse.emf.eef.runtime.ui.widgets.ElementSelectionDialog', - 'org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'EReferencesViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable')/] [editor.elementEditorName()/]; - protected [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> [editor.elementEditorName()/]BusinessFilters = new [include('java.util.ArrayList')/](); - protected List [editor.elementEditorName()/]Filters = new ArrayList(); -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'EReferencesViewer')] -return create[editor.name.toJavaClassifier()/]AdvancedReferencesTable(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'EReferencesViewer')] - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]AdvancedReferencesTable(Composite parent) { - [if (editor.nameAsLabel)] - String label = [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/] - [else] - String label = getDescription([editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - this.[editor.elementEditorName()/] = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { add[editor.name.toJavaClassifier()/](); } - public void handleEdit(EObject element) { edit[editor.name.toJavaClassifier()/](element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { move[editor.name.toJavaClassifier()/](element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFrom[editor.name.toJavaClassifier()/](element); } - public void navigateTo(EObject element) { } - }); - this.[editor.elementEditorName()/].setHelpText(propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - this.[editor.elementEditorName()/].createControls(parent); - this.[editor.elementEditorName()/].addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 3; - this.[editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - this.[editor.elementEditorName()/].disableMove(); - [editor.elementEditorName()/].setID([editor.editorID()/]); - [editor.elementEditorName()/].setEEFType("eef::[editor.representation.name/]"); //$NON-NLS-1$ - return parent; - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void add[editor.name.toJavaClassifier()/]() { - [editor.defaultAddOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void move[editor.name.toJavaClassifier()/](EObject element, int oldIndex, int newIndex) { - [editor.defaultMoveOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void removeFrom[editor.name.toJavaClassifier()/](EObject element) { - [editor.defaultRemoveOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void edit[editor.name.toJavaClassifier()/](EObject element) { - [editor.defaultEditOperation()/] - } -[/template] - -[template public defaultAddOperation (editor : ElementEditor) ] -ElementSelectionDialog dialog = new ElementSelectionDialog([editor.elementEditorName()/].getInput(), [editor.elementEditorName()/]Filters, [editor.elementEditorName()/]BusinessFilters, -"[editor.name/]", propertiesEditionComponent.getEditingContext().getAdapterFactory()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - [editor.elementEditorName()/].refresh(); - } -}; -dialog.open(); -[/template] - -[template public defaultMoveOperation (editor : ElementEditor) ] -propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); -[editor.elementEditorName()/].refresh(); -[/template] - -[template public defaultEditOperation (editor : ElementEditor) ] -EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); -PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); -if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - [editor.elementEditorName()/].refresh(); - } -} -[/template] - -[template public defaultRemoveOperation(editor : ElementEditor) ] -propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); -[editor.elementEditorName()/].refresh(); -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableControl.mtl deleted file mode 100644 index 69de9c896..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableControl.mtl +++ /dev/null @@ -1,124 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module flatreferencestableControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::filters /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case : model = Reference(*) - view = FlatReferencesTable===== /] -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (not editionElement.hasModelNavigation() and editionElement.model.isReferenceMany() and editionElement.representationName('FlatReferencesTable'))] - -/** - * Settings for [editionElement.name/] ReferencesTable - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (not editionElement.hasModelNavigation() and editionElement.model.isReferenceMany() and editionElement.representationName('FlatReferencesTable'))] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include('java.util.List')/]) event.getNewValue()); -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (not editionElement.hasModelNavigation() and editionElement.model.isReferenceMany() and editionElement.representationName('FlatReferencesTable'))] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? ((not editionElement.hasModelNavigation()) and editionElement.model.isReferenceMany() and editionElement.representationName('FlatReferencesTable'))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? ((not editionElement.hasModelNavigation()) and editionElement.model.isReferenceMany() and editionElement.representationName('FlatReferencesTable'))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - if (element instanceof EObject) - return (![view.viewIdentifier(pec)/].isContainedIn[editionElement.views->first().viewPackageSignature()/]Table((EObject)element)); - return [if (not editionElement.model.required)]element instanceof String && element.equals("")[else]false[/if]; - } - - }); - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.emf.eef.runtime.impl.filters.EObjectStrictFilter')/]([editionElement.metamodelTypeGetter()/])); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] - -[comment ===== Case : model = Reference(*) in Simple Navigation - view = FlatReferencesTable===== /] -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.hasModelNavigation() and editionElement.representationName('FlatReferencesTable'))] - -/** - * Settings for [editionElement.name/] ReferencesTable - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.hasModelNavigation() and editionElement.representationName('FlatReferencesTable'))] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include('java.util.List')/]) event.getNewValue()); -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.hasModelNavigation() and editionElement.representationName('FlatReferencesTable'))] -if ([editionElement.name.toJavaIdentifier()/]Settings.isAffectingFeature((EStructuralFeature)msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.hasModelNavigation() and editionElement.representationName('FlatReferencesTable'))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).metamodelGetter()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.hasModelNavigation() and editionElement.representationName('FlatReferencesTable'))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - if (element instanceof EObject) - return (![view.viewIdentifier(pec)/].isContainedIn[editionElement.views->first().viewPackageSignature()/]Table((EObject)element)); - return [if (not editionElement.model.required)]element instanceof String && element.equals("")[else]false[/if]; - } - - }); - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.emf.eef.runtime.impl.filters.EObjectStrictFilter')/]([editionElement.metamodelTypeGetter()/])); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filterBody(filter, editionElement, view, pec) /] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableFormImpl.mtl deleted file mode 100644 index 47ae5b40e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableFormImpl.mtl +++ /dev/null @@ -1,73 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module flatreferencestableFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = ReferencesTable ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'FlatReferencesTable')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.jface.viewers.StructuredSelection', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'FlatReferencesTable')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.FlatReferencesTable')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'FlatReferencesTable')] -return create[editor.name.toJavaClassifier()/]FlatReferencesTable(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'FlatReferencesTable')] - /** - * @param parent - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]FlatReferencesTable(FormToolkit widgetFactory, Composite parent) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new FlatReferencesTable(parent); - [editor.elementEditorName()/].setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - [editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - if (event.getSelection() instanceof StructuredSelection) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, ((StructuredSelection)event.getSelection()).toList())); - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setID([editor.editorID()/]); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('FlatReferencesTable'))] - - // [/protected] - return parent; - } - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableGettersSetters.mtl deleted file mode 100644 index 0e310e6a2..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableGettersSetters.mtl +++ /dev/null @@ -1,133 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module flatreferencestableGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public getterDeclaration(elementEditor : ElementEditor) overrides getterDeclaration ? (elementEditor.representationName('FlatReferencesTable'))] -[/template] - -[template public getterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides getterImplementation ? (elementEditor.representationName('FlatReferencesTable'))] -[/template] - -[template public getterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides getterImplementationDelegate ? (elementEditor.representationName('FlatReferencesTable'))] -[/template] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('FlatReferencesTable'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.updateSignatureDocumentation()/] -[elementEditor.updateSignature()/]; - -[elementEditor.addFilterSignatureDocumentation()/] -[elementEditor.addFilterSignature()/]; - -[elementEditor.addBusinessFilterSignatureDocumentation()/] -[elementEditor.addBusinessFilterSignature()/]; - -[elementEditor.isContainedInTableSignatureDocumentation()/] -[elementEditor.isContainedInTableSignature()/]; -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('FlatReferencesTable'))] - public void init[elementEditor.viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] settings) -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('FlatReferencesTable'))] - /** - * Init the [elementEditor.name/] - * @param settings settings for the [elementEditor.name/] ReferencesTable - */ -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('FlatReferencesTable'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[updateSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.updateSignatureImplementation()/] - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignatureImplementation()/] - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignatureImplementation()/] - -[isContainedInTableSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.isContainedInTableSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('FlatReferencesTable'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](settings); - } - -[updateSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.updateSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.update[elementEditor.viewPackageSignature()/](); - } - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addBusinessFilterTo[elementEditor.viewPackageSignature()/](filter); - } -[isContainedInTableSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.isContainedInTableSignature()/] { - return [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.isContainedIn[elementEditor.viewPackageSignature()/]Table(element); - } -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides initSignatureDocumentationImplementation ? (elementEditor.representationName('FlatReferencesTable'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](ReferencesTableSettings) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('FlatReferencesTable'))] -[elementEditor.initSignature()/] { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - [elementEditor.elementEditorName()/].setInput(settings); - [elementEditor.readOnly()/] - } -[/template] - -[template public addFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('FlatReferencesTable'))] -[elementEditor.addFilterSignature()/] { - [elementEditor.elementEditorName()/].addFilter(filter); - } -[/template] - -[template public addBusinessFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('FlatReferencesTable'))] -[elementEditor.addBusinessFilterSignature()/] { - [elementEditor.elementEditorName()/].addBusinessRuleFilter(filter); - } -[/template] - -[template public isContainedInTableSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('FlatReferencesTable'))] -[elementEditor.isContainedInTableSignature()/] { - return ((ReferencesTableSettings)[elementEditor.elementEditorName()/].getInput()).contains(element); - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableSWTImpl.mtl deleted file mode 100644 index d9d6a328c..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/flatreferencestable/flatreferencestableSWTImpl.mtl +++ /dev/null @@ -1,72 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module flatreferencestableSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = ReferencesTable ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'FlatReferencesTable')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.jface.viewers.StructuredSelection', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'FlatReferencesTable')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.FlatReferencesTable')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'FlatReferencesTable')] -return create[editor.name.toJavaClassifier()/]FlatReferencesTable(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'FlatReferencesTable')] - /** - * @param parent - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]FlatReferencesTable(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new FlatReferencesTable(parent); - [editor.elementEditorName()/].setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - [editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - if (event.getSelection() instanceof StructuredSelection) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, ((StructuredSelection)event.getSelection()).toList())); - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setID([editor.editorID()/]); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('FlatReferencesTable'))] - - // [/protected] - return parent; - } - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/group/groupFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/group/groupFormImpl.mtl deleted file mode 100644 index 7d3f4ddb2..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/group/groupFormImpl.mtl +++ /dev/null @@ -1,50 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module groupFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Group')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.ui.forms.widgets.Section', - 'org.eclipse.swt.layout.GridLayout', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public implementation(container : Container) overrides implementation ? (container.representation.name = 'Group')] -return create[container.name.toJavaClassifier()/]Group(widgetFactory, parent); -[/template] - -[template public additionalImplementation(container : Container, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (container.representation.name = 'Group')] - /** - * [container.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[container.name.toJavaClassifier()/]Group(FormToolkit widgetFactory, final Composite parent) { - Section [container.name.toJavaIdentifier()/]Section = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - [container.name.toJavaIdentifier()/]Section.setText([include(container.owningViewsRepository().qualifiedMessagesProvider())/].[container.groupKey(container.owningView())/]); - GridData [container.name.toJavaIdentifier()/]SectionData = new GridData(GridData.FILL_HORIZONTAL); - [container.name.toJavaIdentifier()/]SectionData.horizontalSpan = 3; - [container.name.toJavaIdentifier()/]Section.setLayoutData([container.name.toJavaIdentifier()/]SectionData); - Composite [container.name.toJavaIdentifier()/]Group = widgetFactory.createComposite([container.name.toJavaIdentifier()/]Section); - GridLayout [container.name.toJavaIdentifier()/]GroupLayout = new GridLayout(); - [container.name.toJavaIdentifier()/]GroupLayout.numColumns = 3; - [container.name.toJavaIdentifier()/]Group.setLayout([container.name.toJavaIdentifier()/]GroupLayout); - [container.name.toJavaIdentifier()/]Section.setClient([container.name.toJavaIdentifier()/]Group); - return [container.name.toJavaIdentifier()/]Group; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/group/groupSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/group/groupSWTImpl.mtl deleted file mode 100644 index 24b12645d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/group/groupSWTImpl.mtl +++ /dev/null @@ -1,48 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module groupSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Group')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Group', - 'org.eclipse.swt.layout.GridLayout', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public implementation(container : Container) overrides implementation ? (container.representation.name = 'Group')] -return create[container.name.toJavaClassifier()/]Group(parent); -[/template] - -[template public additionalImplementation(container : Container, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (container.representation.name = 'Group')] - /** - * [container.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[container.name.toJavaClassifier()/]Group(Composite parent) { - Group [container.name.toJavaIdentifier()/]Group = new Group(parent, SWT.NONE); - [container.name.toJavaIdentifier()/]Group.setText([include(container.owningViewsRepository().qualifiedMessagesProvider())/].[container.groupKey(container.owningView())/]); - GridData [container.name.toJavaIdentifier()/]GroupData = new GridData(GridData.FILL_HORIZONTAL); - [container.name.toJavaIdentifier()/]GroupData.horizontalSpan = 3; - [container.name.toJavaIdentifier()/]Group.setLayoutData([container.name.toJavaIdentifier()/]GroupData); - GridLayout [container.name.toJavaIdentifier()/]GroupLayout = new GridLayout(); - [container.name.toJavaIdentifier()/]GroupLayout.numColumns = 3; - [container.name.toJavaIdentifier()/]Group.setLayout([container.name.toJavaIdentifier()/]GroupLayout); - return [container.name.toJavaIdentifier()/]Group; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/hbox/hboxFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/hbox/hboxFormImpl.mtl deleted file mode 100644 index eb36517cf..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/hbox/hboxFormImpl.mtl +++ /dev/null @@ -1,53 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module hboxFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'HorizontalBox')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.emf.eef.runtime.ui.widgets.HorizontalBox', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.layout.GridLayout'})/] -[/template] - -[template public implementation(container : Container) overrides implementation ? (container.representation.name = 'HorizontalBox')] -return create[container.name.toJavaClassifier()/]HBox(widgetFactory, parent); -[/template] - -[template public additionalImplementation(container : Container, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (container.representation.name = 'HorizontalBox')] - [container.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[container.name.toJavaClassifier()/]HBox(FormToolkit widgetFactory, Composite parent) { - Composite container = widgetFactory.createComposite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - container.setLayout(layout); - GridData gridData = new GridData(GridData.FILL_HORIZONTAL); - gridData.horizontalSpan=3; - container.setLayoutData(gridData); - HorizontalBox [container.name.toJavaIdentifier()/]HBox = new HorizontalBox(container); - [if (container.elements->select(representation.name='Checkbox')->notEmpty())] - //Apply constraint for checkbox - GridData constraint = new GridData(GridData.FILL_HORIZONTAL); - constraint.horizontalAlignment = GridData.BEGINNING; - [container.name.toJavaIdentifier()/]HBox.setLayoutData(constraint); - [/if] - widgetFactory.adapt([container.name.toJavaIdentifier()/]HBox); - return [container.name.toJavaIdentifier()/]HBox; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/hbox/hboxSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/hbox/hboxSWTImpl.mtl deleted file mode 100644 index f0ec27af1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/hbox/hboxSWTImpl.mtl +++ /dev/null @@ -1,51 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module hboxSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'HorizontalBox')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.emf.eef.runtime.ui.widgets.HorizontalBox', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.layout.GridLayout'})/] -[/template] - -[template public implementation(container : Container) overrides implementation ? (container.representation.name = 'HorizontalBox')] -return create[container.name.toJavaClassifier()/]HBox(parent); -[/template] - -[template public additionalImplementation(container : Container, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (container.representation.name = 'HorizontalBox')] - [container.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[container.name.toJavaClassifier()/]HBox(Composite parent) { - Composite container = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - container.setLayout(layout); - GridData gridData = new GridData(GridData.FILL_HORIZONTAL); - gridData.horizontalSpan = 3; - container.setLayoutData(gridData); - HorizontalBox [container.name.toJavaIdentifier()/]HBox = new HorizontalBox(container); - [if (container.elements->select(representation.name='Checkbox')->notEmpty())] - //Apply constraint for checkbox - GridData constraint = new GridData(GridData.FILL_HORIZONTAL); - constraint.horizontalAlignment = GridData.BEGINNING; - [container.name.toJavaIdentifier()/]HBox.setLayoutData(constraint); - [/if] - return [container.name.toJavaIdentifier()/]HBox; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerControl.mtl deleted file mode 100644 index 5e8dbe158..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerControl.mtl +++ /dev/null @@ -1,73 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module imageViewerControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] - -[comment ===== Case : model = Attribute(1) - view = Text ===== /] -[comment @Override widgetControl.declareEObjectUpdater /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('ImageViewer') and not editionElement.model.derived and not editionElement.canGeneratemodelNavigation())] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/]((String)event.getNewValue()); -[/template] - -[comment @Override widgetControl.liveUpdater /] -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('ImageViewer') and not editionElement.model.derived)] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])){ -[if (editionElement.model.oclAsType(EAttribute).isString())] - if (msg.getNewValue() != null) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]((String)msg.getNewValue()); - } -[else] -//FIXME invalid case in liveUpdater(), Case : model = Attribute(1) : [editionElement.model.name/] - view = ImageViewer -[/if] - else { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](""); - } -} -[/template] - -[comment @Override widgetControl.updater /] -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('ImageViewer') and not editionElement.model.derived and not editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.oclAsType(EAttribute).isString())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/](EcoreUtil.getIdentification([pec.pecModelClass().toJavaIdentifier()/]), [pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toJavaClassifier()/]()); -} -[else] -//FIXME invalid case in updater(), Case : model = Attribute(1) : [editionElement.model.name/] - view = ImageViewer -[/if] -[/template] - -[comment @Override widgetControl.filterUpdater /] -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('ImageViewer') and not editionElement.model.derived)] -[/template] - -[comment ===== Case : model = Attribute(1) - view = Text - ModelNavigation ===== /] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('ImageViewer') and not editionElement.model.derived and editionElement.canGeneratemodelNavigation())] -[editionElement.name.toJavaIdentifier()/]Settings.setValue((String)event.getNewValue()); -[/template] - -[comment @Override widgetControl.updater /] -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('ImageViewer') and not editionElement.model.derived and editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.oclAsType(EAttribute).isString())] -if ([editionElement.name.toJavaIdentifier()/]Settings.getValue() && isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/](EcoreUtil.getIdentification([pec.pecModelClass().toJavaIdentifier()/]), [editionElement.name.toJavaIdentifier()/]Settings.getValue()); -} -[else] -//FIXME invalid case in updater(), Case : model = Attribute(1) : [editionElement.model.name/] - view = ImageViewer -[/if] -[/template] - - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerFormImpl.mtl deleted file mode 100644 index 6c38e7284..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerFormImpl.mtl +++ /dev/null @@ -1,80 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module imageViewerFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'ImageViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representationName('ImageViewer'))] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.imageviewer.EEFImageViewer')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representationName('ImageViewer'))] -return create[editor.name.toJavaClassifier()/]ImageViewer(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representationName('ImageViewer'))] - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]ImageViewer(FormToolkit widgetFactory, Composite parent) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new EEFImageViewer(parent, SWT.BORDER); - GridData [editor.elementEditorName()/]Data = new GridData(); - [if (editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - [editor.defaultLayoutData()/] - [else] - // [protected (' for '.concat(editor.name).concat(' layout data customization'))] - [editor.defaultLayoutData()/] - // [/protected] - [/if] - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.viewCompletePackageGetter()/])); - } - }); - [editor.elementEditorName()/].setID([editor.editorID()/]); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('ImageViewer'))] - - // [/protected] - return parent; - } -[/template] - -[template private defaultLayoutData (editor : ElementEditor) ] - [editor.elementEditorName()/]Data.widthHint = 200; - [editor.elementEditorName()/]Data.heightHint = 200; - [editor.elementEditorName()/]Data.horizontalAlignment = SWT.CENTER; - [editor.elementEditorName()/]Data.verticalAlignment = SWT.CENTER; - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerGettersSetters.mtl deleted file mode 100644 index a46a24cb9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerGettersSetters.mtl +++ /dev/null @@ -1,88 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module imageViewerGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ================== Getter generation ================== /] -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('ImageViewer'))] -[elementEditor.getterSignature()/] { - [include('org.eclipse.jface.viewers.ISelection')/] selection = [elementEditor.elementEditorName()/].getSelection(); - if (selection instanceof [include('org.eclipse.jface.viewers.StructuredSelection')/] && ((StructuredSelection)selection).getFirstElement() instanceof String) { - return (String)((StructuredSelection)selection).getFirstElement(); - } - return null; - } -[/template] - -[comment ================== Setter generation ================== /] -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('ImageViewer'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('ImageViewer'))] - /** - * Init the [elementEditor.name/] - * @param key the key of the editor - * @param current the new path of the pics - */ -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('ImageViewer'))] - public void init[elementEditor.viewPackageSignature()/](String key, String newValue) -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('ImageViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignatureImplementation()/] -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('ImageViewer'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](newValue)); - } else { - [elementEditor.elementEditorName()/].setSelection(new StructuredSelection("")); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides initSignatureDocumentationImplementation ? (elementEditor.representationName('ImageViewer'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](String key, String newValue) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('ImageViewer'))] -[elementEditor.initSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].initViewer(key, newValue); - } else { - [elementEditor.elementEditorName()/].initViewer(key, ""); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerSWTImpl.mtl deleted file mode 100644 index ed9e6df43..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/imageviewer/imageViewerSWTImpl.mtl +++ /dev/null @@ -1,75 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module imageViewerSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'ImageViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representationName('ImageViewer'))] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.imageviewer.EEFImageViewer')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representationName('ImageViewer'))] -return create[editor.name.toJavaClassifier()/]ImageViewer(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representationName('ImageViewer'))] - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]ImageViewer(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new EEFImageViewer(parent, SWT.BORDER); - GridData [editor.elementEditorName()/]Data = new GridData(); - // [protected (' for '.concat(editor.name).concat(' layout data customization'))] - [defaultLayoutData()/] - // [/protected] - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.viewCompletePackageGetter()/])); - } - }); - [editor.elementEditorName()/].setID([editor.editorID()/]); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('ImageViewer'))] - - // [/protected] - return parent; - } -[/template] - -[template private defaultLayoutData (editor : ElementEditor) ] - [editor.elementEditorName()/]Data.widthHint = 200; - [editor.elementEditorName()/]Data.heightHint = 200; - [editor.elementEditorName()/]Data.horizontalAlignment = SWT.CENTER; - [editor.elementEditorName()/]Data.verticalAlignment = SWT.CENTER; - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerControl.mtl deleted file mode 100644 index 8f1640e3d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerControl.mtl +++ /dev/null @@ -1,239 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2013 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module linkeobjectflatcomboviewerControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::filters /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case : model = Reference(1) - view = LinkEObjectFlatComboViewer ===== /] -[query public validCaseForSingleReference(editionElement : PropertiesEditionElement) : Boolean = - (not editionElement.hasModelNavigation()) - and editionElement.model.isReferenceSingle() - and (editionElement.representationName('LinkEObjectFlatComboViewer'))/] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForSingleReference())] - -/** - * Settings for [editionElement.name/] LinkEObjectFlatComboViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForSingleReference())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.EDIT) { - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); - if (editionPolicy != null) { - editionPolicy.execute(); - } - } -} else if (event.getKind() == PropertiesEditionEvent.ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [if (not editionElement.model.eType.oclAsType(EClass).abstract)] - [include(editionElement.peeModelQualifiedClass())/] eObject = [editionElement.factoryCreator()/]; - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(eObject); - [else] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] - [/if] -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForSingleReference())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForSingleReference()) ] -if (isAccessible([editionElement.views->first().editorID()/])) { - // init part - [editionElement.name.toJavaIdentifier()/]Settings = new EObjectFlatComboSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); - // set the button mode - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/].BROWSE); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (not editionElement.hasModelNavigation() and editionElement.model.isReferenceSingle() and (editionElement.representationName('LinkEObjectFlatComboViewer')))] -[/template] - -[comment ===== Case : model = Simple Navigation A (0-1) -> B (0-1) -> C - view = LinkEObjectFlatComboViewer ===== /] -[query public validCaseForContainmentNavigation(editionElement : PropertiesEditionElement) : Boolean = - editionElement.hasModelNavigation() - and (editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isReferenceSingle())) - and (editionElement.representationName('LinkEObjectFlatComboViewer')) /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForContainmentNavigation())] - -/** - * Settings for [editionElement.name/] LinkEObjectFlatComboViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForContainmentNavigation())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.EDIT) { - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); - if (editionPolicy != null) { - editionPolicy.execute(); - } - } -} else if (event.getKind() == PropertiesEditionEvent.ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [if (not editionElement.model.eType.oclAsType(EClass).abstract)] - [include(editionElement.peeModelQualifiedClass())/] eObject = [editionElement.factoryCreator()/]; - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(eObject); - [else] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] - [/if] -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForContainmentNavigation())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForContainmentNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - // init part - [editionElement.name.toJavaIdentifier()/]Settings = new EObjectFlatComboSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).metamodelGetter()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); - // set the button mode - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/].BROWSE); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.hasModelNavigation() and editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isReferenceSingle() and (editionElement.representationName('LinkEObjectFlatComboViewer'))))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter')/]([editionElement.metamodelTypeGetter()/])); -} -[/template] - -[comment ===== Case : model = Containment(1), Simple navigation or not - view = LinkEObjectFlatComboViewer ===== /] -[query public validCaseForContainment(editionElement : PropertiesEditionElement) : Boolean = - editionElement.model.isContainmentSingle() - and (editionElement.representationName('LinkEObjectFlatComboViewer')) /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForContainment())] - -/** - * Settings for [editionElement.name/] EObjectFlatComboViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForContainment())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.EDIT) { - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); - if (editionPolicy != null) { - editionPolicy.execute(); - } - } -} else if (event.getKind() == PropertiesEditionEvent.ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [if (not editionElement.model.eType.oclAsType(EClass).abstract)] - [include(editionElement.peeModelQualifiedClass())/] eObject = [editionElement.factoryCreator()/]; - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(eObject); - [else] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] - [/if] -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForContainment())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForContainment() and not editionElement.hasModelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - // init part - [editionElement.name.toJavaIdentifier()/]Settings = new EObjectFlatComboSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); - // set the button mode - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/].CREATE); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForContainment())] -[comment no filters on creation/] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerFormImpl.mtl deleted file mode 100644 index 89f544984..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerFormImpl.mtl +++ /dev/null @@ -1,81 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2013 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module linkeobjectflatcomboviewerFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = AdvancedEObjectFlatComboViewer ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'LinkEObjectFlatComboViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.AbstractAdvancedEObjectFlatComboViewer.EObjectFlatComboViewerListener', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'LinkEObjectFlatComboViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.LinkEObjectFlatComboViewer')/] [editor.elementEditorName()/]; - protected [include('org.eclipse.jface.viewers.ViewerFilter')/] [editor.elementEditorName()/]Filter; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'LinkEObjectFlatComboViewer')] -return create[editor.name.toJavaClassifier()/]LinkFlatComboViewer(parent, widgetFactory); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'LinkEObjectFlatComboViewer')] - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]LinkFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - // create callback listener - EObjectFlatComboViewerListener listener = new EObjectFlatComboViewerListener(){ - public void handleSet(EObject element){ - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, element)); - } - public void navigateTo(EObject element){ } - - public EObject handleCreate() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, null)); - return [editor.viewCompletePackageGetter()/]; - } - - public void handleEdit(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, element)); - } - }; - //create widget - [editor.elementEditorName()/] = new LinkEObjectFlatComboViewer([editor.owningViewsRepository().messagesProvider()/].[editor.editorKey(editor.owningView())/], resourceSet, [editor.elementEditorName()/]Filter, propertiesEditionComponent.getEditingContext().getAdapterFactory(), listener); - [editor.elementEditorName()/].createControls(parent, widgetFactory); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setID([editor.editorID()/]); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('LinkFlatComboViewer'))] - - // [/protected] - return parent; - } - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerGettersSetters.mtl deleted file mode 100644 index 799bc878e..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerGettersSetters.mtl +++ /dev/null @@ -1,141 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2013 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module linkeobjectflatcomboviewerGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; - -[elementEditor.setterButtonModeSignatureDocumentation()/] -[elementEditor.setterButtonModeSignature()/]; - -[elementEditor.addFilterSignatureDocumentation()/] -[elementEditor.addFilterSignature()/]; - -[elementEditor.addBusinessFilterSignatureDocumentation()/] -[elementEditor.addBusinessFilterSignature()/]; -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] - /** - * Init the [elementEditor.name/] - * @param settings the combo setting - */ -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] - public void init[elementEditor.viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] settings) -[/template] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] -[elementEditor.getterSignature()/] { - return [elementEditor.elementEditorName()/].getSelection(); - } -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignatureImplementation()/] - -[setterButtonModeSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterButtonModeSignatureImplementation()/] - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignatureImplementation()/] - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](settings); - } - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/](newValue); - } - -[setterButtonModeSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterButtonModeSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/]ButtonMode(newValue); - } - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addBusinessFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](newValue)); - } else { - [elementEditor.elementEditorName()/].setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] - -[template public setterButtonModeSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#[elementEditor.viewPackageSetter()/]ButtonMode(ButtonsModeEnum newValue) - */ -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](EObjectFlatComboSettings) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] -[elementEditor.initSignature()/] { - [elementEditor.elementEditorName()/].setInput(settings); - if (current != null) { - [elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](settings.getValue())); - } - [elementEditor.readOnly()/] - } -[/template] - -[template public addBusinessFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('LinkEObjectFlatComboViewer'))] -[elementEditor.addBusinessFilterSignature()/] { - [elementEditor.elementEditorName()/].addBusinessRuleFilter(filter); - } -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerSWTImpl.mtl deleted file mode 100644 index b6789f4ce..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkeobjectflatcomboviewer/linkeobjectflatcomboviewerSWTImpl.mtl +++ /dev/null @@ -1,79 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2013 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module linkeobjectflatcomboviewerSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = LinkEObjectFlatComboViewer ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'LinkEObjectFlatComboViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.AbstractAdvancedEObjectFlatComboViewer.EObjectFlatComboViewerListener', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'LinkEObjectFlatComboViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.LinkEObjectFlatComboViewer')/] [editor.elementEditorName()/]; - protected [include('org.eclipse.jface.viewers.ViewerFilter')/] [editor.elementEditorName()/]Filter; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'LinkEObjectFlatComboViewer')] -return create[editor.name.toJavaClassifier()/]LinkFlatComboViewer(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'LinkEObjectFlatComboViewer')] - /** - * @param parent the parent composite - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]LinkFlatComboViewer(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - // create callback listener - EObjectFlatComboViewerListener listener = new EObjectFlatComboViewerListener(){ - public void handleSet(EObject element){ - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, element)); - } - public void navigateTo(EObject element){ } - - public EObject handleCreate() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, null)); - return [editor.viewCompletePackageGetter()/]; - } - - public void handleEdit(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, element)); - } - }; - //create widget - [editor.elementEditorName()/] = new LinkEObjectFlatComboViewer(getDescription([editor.editorID()/], [editor.owningViewsRepository().messagesProvider()/].[editor.editorKey(editor.owningView())/]), resourceSet, [editor.elementEditorName()/]Filter, propertiesEditionComponent.getEditingContext().getAdapterFactory(), listener); - [editor.elementEditorName()/].createControls(parent); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setID([editor.editorID()/]); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('LinkFlatComboViewer'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerControl.mtl deleted file mode 100644 index 87e03f570..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerControl.mtl +++ /dev/null @@ -1,282 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2013 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module linkereferenceviewerControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::filters /] -[import org::eclipse::emf::eef::codegen::services::imports/] -[import org::eclipse::emf::eef::codegen::services::navigationStep /] - -[comment ===== Case : model = Reference(1) - view = LinkEReferenceViewer ===== /] -[query public validCaseForSingleReference(editionElement : PropertiesEditionElement) : Boolean = - (not editionElement.hasModelNavigation()) - and editionElement.model.isReferenceSingle() - and (editionElement.representationName('LinkEReferenceViewer'))/] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForSingleReference())] - -/** - * Settings for [editionElement.name/] LinkEReferenceViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -/** - * Creation Settings for [editionElement.name/] LinkEReferenceViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]CreateSettings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForSingleReference())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.EDIT) { - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); - if (editionPolicy != null) { - editionPolicy.execute(); - } - } -} else if (event.getKind() == PropertiesEditionEvent.ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [if (not editionElement.model.eType.oclAsType(EClass).abstract)] - [include(editionElement.peeModelQualifiedClass())/] eObject = [editionElement.factoryCreator()/]; - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]CreateSettings, editingContext.getAdapterFactory()); - context.addInstanciableTypeFilter(new [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext.InstanciableTypeFilter')/]() { - public boolean select([include('org.eclipse.emf.ecore.EClass')/] instanciableType) { - return [editionElement.metamodelTypeGetter()/] == instanciableType; - } - }); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(context.getEObject()); - (([view.pepInterface()/])editingPart).[editionElement.views->first().viewPackageSetter()/](context.getEObject()); - [else] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] - [/if] -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForSingleReference())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForSingleReference()) ] -if (isAccessible([editionElement.views->first().editorID()/])) { - // init part - [editionElement.name.toJavaIdentifier()/]Settings = new EObjectFlatComboSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [editionElement.name.toJavaIdentifier()/]CreateSettings = new ReferencesTableSettings(get[editionElement.name.toJavaIdentifier()/]CreateSettingsSource(), [if (not editionElement.editorSetting.oclIsUndefined())][editionElement.editorSetting.oclAsType(EReferenceViewerSettings).metamodelGetter()/][/if]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); - // set the button mode - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/].BROWSE); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (not editionElement.hasModelNavigation() and editionElement.model.isReferenceSingle() and (editionElement.representationName('LinkEReferenceViewer')))] -[/template] - -[comment ===== Case : model = Simple Navigation A (0-1) -> B (0-1) -> C - view = LinkEReferenceViewer ===== /] -[query public validCaseForContainmentNavigation(editionElement : PropertiesEditionElement) : Boolean = - editionElement.hasModelNavigation() - and (editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isReferenceSingle())) - and (editionElement.representationName('LinkEReferenceViewer')) /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForContainmentNavigation())] - -/** - * Settings for [editionElement.name/] LinkEReferenceViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForContainmentNavigation())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.EDIT) { - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); - if (editionPolicy != null) { - editionPolicy.execute(); - } - } -} else if (event.getKind() == PropertiesEditionEvent.ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [if (not editionElement.model.eType.oclAsType(EClass).abstract)] - [include(editionElement.peeModelQualifiedClass())/] eObject = [editionElement.factoryCreator()/]; - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]CreateSettings, editingContext.getAdapterFactory()); - context.addInstanciableTypeFilter(new [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext.InstanciableTypeFilter')/]() { - public boolean select([include('org.eclipse.emf.ecore.EClass')/] instanciableType) { - return [editionElement.metamodelTypeGetter()/] == instanciableType; - } - }); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(context.getEObject()); - (([view.pepInterface()/])editingPart).[editionElement.views->first().viewPackageSetter()/](context.getEObject()); - [else] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] - [/if] -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForContainmentNavigation())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForContainmentNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - // init part - [editionElement.name.toJavaIdentifier()/]Settings = new EObjectFlatComboSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).metamodelGetter()/], [editionElement.metamodelGetter()/]); - [editionElement.name.toJavaIdentifier()/]CreateSettings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); - // set the button mode - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/].BROWSE); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.hasModelNavigation() and editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isReferenceSingle() and (editionElement.representationName('LinkEReferenceViewer'))))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter')/]([editionElement.metamodelTypeGetter()/])); -} -[/template] - -[comment ===== Case : model = Containment(1), Simple navigation or not - view = LinkEReferenceViewer ===== /] -[query public validCaseForContainment(editionElement : PropertiesEditionElement) : Boolean = - editionElement.model.isContainmentSingle() - and (editionElement.representationName('LinkEReferenceViewer')) /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForContainment())] - -/** - * Settings for [editionElement.name/] LinkEReferenceViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -/** - * Creation Settings for [editionElement.name/] LinkEReferenceViewer - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]CreateSettings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForContainment())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(([include(editionElement.peeModelQualifiedClass())/])event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.EDIT) { - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); - if (editionPolicy != null) { - editionPolicy.execute(); - } - } -} else if (event.getKind() == PropertiesEditionEvent.ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [if (not editionElement.model.eType.oclAsType(EClass).abstract)] - [include(editionElement.peeModelQualifiedClass())/] eObject = [editionElement.factoryCreator()/]; - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]CreateSettings, editingContext.getAdapterFactory()); - context.addInstanciableTypeFilter(new [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext.InstanciableTypeFilter')/]() { - public boolean select([include('org.eclipse.emf.ecore.EClass')/] instanciableType) { - return [editionElement.metamodelTypeGetter()/] == instanciableType; - } - }); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(context.getEObject()); - (([view.pepInterface()/])editingPart).[editionElement.views->first().viewPackageSetter()/](context.getEObject()); - [else] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] - [/if] -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForContainment())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForContainment() and not editionElement.hasModelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - // init part - [editionElement.name.toJavaIdentifier()/]Settings = new EObjectFlatComboSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); - // set the button mode - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]ButtonMode([include('org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum')/].CREATE); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForContainment())] -[comment no filters on creation/] -[/template] - -[template public additionalComponentGetterForEditorSettings(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentGetterForEditorSettings ? (editionElement.validCaseForSingleReference())] -[if (editionElement.canGenerateEditorSettings())] - -/** - * @ return source setting for [editionElement.name.toJavaIdentifier()/]CreateSettings - */ -public EObject get[editionElement.name.toJavaIdentifier()/]CreateSettingsSource() { - [if (not editionElement.editorSetting.oclIsUndefined())][editionElement.editorSetting.oclAsType(EReferenceViewerSettings).filter.filterBody()/][/if] -} -[/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerFormImpl.mtl deleted file mode 100644 index a705549cc..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerFormImpl.mtl +++ /dev/null @@ -1,81 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2013 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module linkereferenceviewerFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = LinkEReferenceViewer ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'LinkEReferenceViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.AbstractAdvancedEObjectFlatComboViewer.EObjectFlatComboViewerListener', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'LinkEReferenceViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.LinkEReferenceViewer')/] [editor.elementEditorName()/]; - protected [include('org.eclipse.jface.viewers.ViewerFilter')/] [editor.elementEditorName()/]Filter; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'LinkEReferenceViewer')] -return create[editor.name.toJavaClassifier()/]LinkEReferenceViewer(parent, widgetFactory); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'LinkEReferenceViewer')] - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]LinkEReferenceViewer(Composite parent, FormToolkit widgetFactory) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - // create callback listener - EObjectFlatComboViewerListener listener = new EObjectFlatComboViewerListener(){ - public void handleSet(EObject element){ - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, element)); - } - public void navigateTo(EObject element){ } - - public EObject handleCreate() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, null)); - return [editor.viewCompletePackageGetter()/]; - } - - public void handleEdit(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, element)); - } - }; - //create widget - [editor.elementEditorName()/] = new LinkEReferenceViewer([editor.owningViewsRepository().messagesProvider()/].[editor.editorKey(editor.owningView())/], resourceSet, [editor.elementEditorName()/]Filter, propertiesEditionComponent.getEditingContext().getAdapterFactory(), listener); - [editor.elementEditorName()/].createControls(parent, widgetFactory); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setID([editor.editorID()/]); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('LinkEReferenceViewer'))] - - // [/protected] - return parent; - } - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerGettersSetters.mtl deleted file mode 100644 index c73bcc378..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerGettersSetters.mtl +++ /dev/null @@ -1,141 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2013 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module linkereferenceviewerGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('LinkEReferenceViewer'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; - -[elementEditor.setterButtonModeSignatureDocumentation()/] -[elementEditor.setterButtonModeSignature()/]; - -[elementEditor.addFilterSignatureDocumentation()/] -[elementEditor.addFilterSignature()/]; - -[elementEditor.addBusinessFilterSignatureDocumentation()/] -[elementEditor.addBusinessFilterSignature()/]; -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('LinkEReferenceViewer'))] - /** - * Init the [elementEditor.name/] - * @param settings the combo setting - */ -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('LinkEReferenceViewer'))] - public void init[elementEditor.viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] settings) -[/template] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('LinkEReferenceViewer'))] -[elementEditor.getterSignature()/] { - return [elementEditor.elementEditorName()/].getSelection(); - } -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('LinkEReferenceViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignatureImplementation()/] - -[setterButtonModeSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterButtonModeSignatureImplementation()/] - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignatureImplementation()/] - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('LinkEReferenceViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](settings); - } - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/](newValue); - } - -[setterButtonModeSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterButtonModeSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/]ButtonMode(newValue); - } - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addBusinessFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('LinkEReferenceViewer'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](newValue)); - } else { - [elementEditor.elementEditorName()/].setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] - -[template public setterButtonModeSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) ? (elementEditor.representationName('LinkEReferenceViewer'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#[elementEditor.viewPackageSetter()/]ButtonMode(ButtonsModeEnum newValue) - */ -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) ? (elementEditor.representationName('LinkEReferenceViewer'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](EObjectFlatComboSettings) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('LinkEReferenceViewer'))] -[elementEditor.initSignature()/] { - [elementEditor.elementEditorName()/].setInput(settings); - if (current != null) { - [elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](settings.getValue())); - } - [elementEditor.readOnly()/] - } -[/template] - -[template public addBusinessFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('LinkEReferenceViewer'))] -[elementEditor.addBusinessFilterSignature()/] { - [elementEditor.elementEditorName()/].addBusinessRuleFilter(filter); - } -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerSWTImpl.mtl deleted file mode 100644 index 026c8d126..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/linkereferenceviewer/linkereferenceviewerSWTImpl.mtl +++ /dev/null @@ -1,79 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2013 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module linkereferenceviewerSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = LinkEReferenceViewer ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'LinkEReferenceViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.AbstractAdvancedEObjectFlatComboViewer.EObjectFlatComboViewerListener', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'LinkEReferenceViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.LinkEReferenceViewer')/] [editor.elementEditorName()/]; - protected [include('org.eclipse.jface.viewers.ViewerFilter')/] [editor.elementEditorName()/]Filter; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'LinkEReferenceViewer')] -return create[editor.name.toJavaClassifier()/]LinkEReferenceViewer(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'LinkEReferenceViewer')] - /** - * @param parent the parent composite - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]LinkEReferenceViewer(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - // create callback listener - EObjectFlatComboViewerListener listener = new EObjectFlatComboViewerListener(){ - public void handleSet(EObject element){ - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, element)); - } - public void navigateTo(EObject element){ } - - public EObject handleCreate() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, null)); - return [editor.viewCompletePackageGetter()/]; - } - - public void handleEdit(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, element)); - } - }; - //create widget - [editor.elementEditorName()/] = new LinkEReferenceViewer(getDescription([editor.editorID()/], [editor.owningViewsRepository().messagesProvider()/].[editor.editorKey(editor.owningView())/]), resourceSet, [editor.elementEditorName()/]Filter, propertiesEditionComponent.getEditingContext().getAdapterFactory(), listener); - [editor.elementEditorName()/].createControls(parent); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].setID([editor.editorID()/]); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('LinkEReferenceViewer'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorControl.mtl deleted file mode 100644 index ff8d5ad44..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorControl.mtl +++ /dev/null @@ -1,68 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module multivaluededitorControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case : model = Attribute(*) - view = MultiValuedEditor ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeMany() and editionElement.representationName('MultiValuedEditor') and not editionElement.canGeneratemodelNavigation())]if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].SET) { - [pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].get[editionElement.model.name.toMany().toUpperFirst()/]().clear(); - [pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].get[editionElement.model.name.toMany().toUpperFirst()/]().addAll((([include('org.eclipse.emf.common.util.EList')/]) event.getNewValue())); -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeMany() and editionElement.representationName('MultiValuedEditor'))] -[if (editionElement.model.oclAsType(EAttribute).many)] -if ([editionElement.liveUpdaterNavigationCondition(pec)/] && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) { - if (msg.getNewValue() instanceof EList) { - [view.viewIdentifier(pec)/].set[editionElement.views->first().name.toJavaClassifier()/]((EList)msg.getNewValue()); - } else if (msg.getNewValue() == null) { - [view.viewIdentifier(pec)/].set[editionElement.views->first().name.toJavaClassifier()/](new [include('org.eclipse.emf.common.util.BasicEList')/]()); - } else { - BasicEList newValueAsList = new BasicEList(); - newValueAsList.add(msg.getNewValue()); - [view.viewIdentifier(pec)/].set[editionElement.views->first().name.toJavaClassifier()/](newValueAsList); - } -} -[else] -//FIXME invalid case in liveUpdater(), Case : model = Attribute(*) : [editionElement.model.name/] - view = MultiValuedEditor -[/if] -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeMany() and editionElement.representationName('MultiValuedEditor') and not editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.many)] -if (isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toMany().toUpperFirst()/]()); -[else] -if (isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]()); -[/if] -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isAttributeMany() and editionElement.representationName('MultiValuedEditor'))] -[comment no filters for multiValuedEditor /] -[/template] - -[comment ===== Case : model = Attribute(*) - view = MultiValuedEditor - ModelNavigation ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeMany() and editionElement.representationName('MultiValuedEditor') and editionElement.canGeneratemodelNavigation())] -[editionElement.name.toJavaIdentifier()/]Settings.setValue((List)event.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeMany() and editionElement.representationName('MultiValuedEditor') and editionElement.canGeneratemodelNavigation())] -if ([editionElement.name.toJavaIdentifier()/]Settings.getSignificantObject() != null && isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].set[editionElement.views->first().viewPackageSignature()/]((EList)[editionElement.name.toJavaIdentifier()/]Settings.getValue()); -} -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorFormImpl.mtl deleted file mode 100644 index 4a5d947a4..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorFormImpl.mtl +++ /dev/null @@ -1,95 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module multivaluededitorFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'MultiValuedEditor')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.common.util.BasicEList', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.emf.eef.runtime.ui.widgets.EEFFeatureEditorDialog', - 'org.eclipse.jface.window.Window', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'MultiValuedEditor')] - protected [include('org.eclipse.swt.widgets.Text')/] [editor.elementEditorName()/]; - protected [include('org.eclipse.swt.widgets.Button')/] edit[editor.name.toJavaClassifier().disambiguation('view')/]; - protected [include('org.eclipse.emf.common.util.EList')/] [editor.elementEditorName()/]List; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'MultiValuedEditor')] -return create[editor.name.toJavaClassifier()/]MultiValuedEditor(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'MultiValuedEditor')] - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]MultiValuedEditor(FormToolkit widgetFactory, Composite parent) { - [editor.elementEditorName()/] = widgetFactory.createText(parent, "", SWT.READ_ONLY); //$NON-NLS-1$ - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 2; - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - EditingUtils.setID([editor.elementEditorName()/], [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/], "eef::[editor.representation.name/]::field"); //$NON-NLS-1$ - edit[editor.name.toJavaClassifier()/] = widgetFactory.createButton(parent, getDescription([editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]), SWT.NONE); - [if (editor.readOnly)] - edit[editor.name.toJavaClassifier()/].setEnabled(false); - [/if] - GridData edit[editor.name.toJavaClassifier()/]Data = new GridData(); - edit[editor.name.toJavaClassifier()/].setLayoutData(edit[editor.name.toJavaClassifier()/]Data); - edit[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - EEFFeatureEditorDialog dialog = new EEFFeatureEditorDialog( - [editor.elementEditorName()/].getShell(), "[pec.pecModelClass()/]", new AdapterFactoryLabelProvider(adapterFactory), //$NON-NLS-1$ - [editor.elementEditorName()/]List, [editor.involvedPropertiesEditionElement().metamodelGetter()/].getEType(), null, - false, true, - null, null); - if (dialog.open() == Window.OK) { - [editor.elementEditorName()/]List = dialog.getResult(); - if ([editor.elementEditorName()/]List == null) { - [editor.elementEditorName()/]List = new BasicEList(); - } - [editor.elementEditorName()/].setText([editor.elementEditorName()/]List.toString()); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new BasicEList([editor.elementEditorName()/]List))); - setHasChanged(true); - } - } - }); - EditingUtils.setID(edit[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(edit[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::browsebutton"); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('MultiValuedEditor'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorGettersSetters.mtl deleted file mode 100644 index 2a9c8d6c2..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorGettersSetters.mtl +++ /dev/null @@ -1,87 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module multivaluededitorGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('MultiValuedEditor'))] -[elementEditor.getterSignature()/] { - return [elementEditor.elementEditorName()/]List; - } -[/template] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('MultiValuedEditor'))] -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; - -[elementEditor.addSignatureDocumentation()/] -[elementEditor.addSignature()/]; - -[elementEditor.removeSignatureDocumentation()/] -[elementEditor.removeSignature()/]; -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('MultiValuedEditor'))] -[elementEditor.setterSignature()/] { - [elementEditor.elementEditorName()/]List = newValue; - if (newValue != null) { - [elementEditor.elementEditorName()/].setText([elementEditor.elementEditorName()/]List.toString()); - } else { - [elementEditor.elementEditorName()/].setText(""); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } - -[elementEditor.addSignature()/] { - [elementEditor.elementEditorName()/]List.add(newValue); - if (newValue != null) { - [elementEditor.elementEditorName()/].setText([elementEditor.elementEditorName()/]List.toString()); - } else { - [elementEditor.elementEditorName()/].setText(""); //$NON-NLS-1$ - } - } - -[elementEditor.removeSignature()/] { - [elementEditor.elementEditorName()/]List.remove(newValue); - if (newValue != null) { - [elementEditor.elementEditorName()/].setText([elementEditor.elementEditorName()/]List.toString()); - } else { - [elementEditor.elementEditorName()/].setText(""); //$NON-NLS-1$ - } - } -[/template] - - -[template public addSignatureDocumentation(elementEditor : ElementEditor) ] - /** - * Add a value to the [elementEditor.name/] multivalued attribute. - * @param newValue the value to add - */ -[/template] - -[template public addSignature(elementEditor : ElementEditor) ] - public void addTo[elementEditor.name.toJavaClassifier()/](Object newValue) -[/template] - -[template public removeSignatureDocumentation(elementEditor : ElementEditor) ] - /** - * Remove a value to the [elementEditor.name/] multivalued attribute. - * @param newValue the value to remove - */ -[/template] - -[template public removeSignature(elementEditor : ElementEditor) ] - public void removeTo[elementEditor.name.toJavaClassifier()/](Object newValue) -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorSWTImpl.mtl deleted file mode 100644 index d87dfdef3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/multivaluededitor/multivaluededitorSWTImpl.mtl +++ /dev/null @@ -1,92 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module multivaluededitorSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'MultiValuedEditor')] -[pec.addImports(Sequence{ - 'org.eclipse.emf.common.util.BasicEList', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.emf.eef.runtime.ui.widgets.EEFFeatureEditorDialog', - 'org.eclipse.jface.window.Window', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'MultiValuedEditor')] - protected [include('org.eclipse.swt.widgets.Text')/] [editor.elementEditorName()/]; - protected [include('org.eclipse.swt.widgets.Button')/] edit[editor.name.toJavaClassifier().disambiguation('view')/]; - protected [include('org.eclipse.emf.common.util.EList')/] [editor.elementEditorName()/]List; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'MultiValuedEditor')] -return create[editor.name.toJavaClassifier()/]MultiValuedEditor(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'MultiValuedEditor')] - protected Composite create[editor.name.toJavaClassifier()/]MultiValuedEditor(Composite parent) { - [editor.elementEditorName()/] = SWTUtils.createScrollableText(parent, SWT.BORDER | SWT.READ_ONLY); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 2; - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - EditingUtils.setID([editor.elementEditorName()/], [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/], "eef::[editor.representation.name/]::field"); //$NON-NLS-1$ - edit[editor.name.toJavaClassifier()/] = new Button(parent, SWT.NONE); - [if (editor.readOnly)] - edit[editor.name.toJavaClassifier()/].setEnabled(false); - [/if] - edit[editor.name.toJavaClassifier()/].setText(getDescription([editor.editorID()/], [editor.owningViewsRepository().messagesProvider()/].[editor.editorKey(editor.owningView())/])); - GridData edit[editor.name.toJavaClassifier()/]Data = new GridData(); - edit[editor.name.toJavaClassifier()/].setLayoutData(edit[editor.name.toJavaClassifier()/]Data); - edit[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - EEFFeatureEditorDialog dialog = new EEFFeatureEditorDialog( - [editor.elementEditorName()/].getShell(), "[pec.pecModelClass()/]", new AdapterFactoryLabelProvider(adapterFactory), //$NON-NLS-1$ - [editor.elementEditorName()/]List, [editor.involvedPropertiesEditionElement().metamodelGetter()/].getEType(), null, - false, true, - null, null); - if (dialog.open() == Window.OK) { - [editor.elementEditorName()/]List = dialog.getResult(); - if ([editor.elementEditorName()/]List == null) { - [editor.elementEditorName()/]List = new BasicEList(); - } - [editor.elementEditorName()/].setText([editor.elementEditorName()/]List.toString()); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new BasicEList([editor.elementEditorName()/]List))); - setHasChanged(true); - } - } - }); - EditingUtils.setID(edit[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(edit[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::browsebutton"); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('MultiValuedEditor'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioControl.mtl deleted file mode 100644 index 6b5f6e665..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioControl.mtl +++ /dev/null @@ -1,64 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module radioControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case : model = Attribute(1) - view = Radio ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Radio') and not editionElement.canGeneratemodelNavigation())] -[pec.model.name.toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([if editionElement.model.eType.instanceTypeName.oclIsUndefined()][editionElement.model.eType.name/][else][editionElement.model.eType.instanceTypeName/][/if])event.getNewValue()); -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Radio') and editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.oclAsType(EAttribute).isEnum())] -if ([editionElement.liveUpdaterNavigationCondition(pec)/] && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([if editionElement.model.eType.instanceTypeName.oclIsUndefined()][editionElement.model.eType.name/][else][editionElement.model.eType.instanceTypeName/][/if])msg.getNewValue()); -[else] -//FIXME invalid case in liveUpdater(), Case : model = Attribute(1) : [editionElement.model.name/] - view = Radio -[/if] -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Radio') and not editionElement.canGeneratemodelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.impl.utils.EEFUtils')/].choiceOfValues([pec.model.name.toJavaIdentifier()/], [editionElement.metamodelGetter()/]), [pec.model.name.toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]()); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Radio'))] -[comment not filters for radio /] -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Radio'))] -[if (editionElement.model.oclAsType(EAttribute).isEnum())] -if ([editionElement.liveUpdaterNavigationCondition(pec)/] && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[else] -//FIXME invalid case in liveUpdater(), Case : model = Attribute(1) : [editionElement.model.name/] - view = Radio -[/if] -[/template] - -[comment ===== Case : model = Attribute(1) - view = Radio - ModelNavigation ===== /] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Radio') and editionElement.canGeneratemodelNavigation())] -[editionElement.name.toJavaIdentifier()/]Settings.setValue(([if editionElement.model.eType.instanceTypeName.oclIsUndefined()][editionElement.model.eType.name/][else][editionElement.model.eType.instanceTypeName/][/if])event.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Radio') and editionElement.canGeneratemodelNavigation())] -if ([editionElement.name.toJavaIdentifier()/]Settings.getSignificantObject() != null && isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/](EEFUtils.choiceOfValues([editionElement.name.toJavaIdentifier()/]Settings.getSignificantObject(), [editionElement.metamodelGetter()/]), /* TODO : toJavaType cast short circuited */ (Enumerator) [editionElement.name.toJavaIdentifier()/]Settings.getValue()); -} -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioFormImpl.mtl deleted file mode 100644 index 0f05786e8..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioFormImpl.mtl +++ /dev/null @@ -1,63 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module radioFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Radio')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.emf.ecore.EEnumLiteral', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'Radio')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.RadioViewer')/] [editor.elementEditorName()/]RadioViewer; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'Radio')] -return create[editor.name.toJavaClassifier()/]RadioViewer(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'Radio')] - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]RadioViewer(Composite parent) { - [editor.elementEditorName()/]RadioViewer = new RadioViewer(parent, SWT.CHECK); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 2; - [editor.elementEditorName()/]RadioViewer.setLayoutData([editor.elementEditorName()/]Data); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); - [editor.elementEditorName()/]RadioViewer.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, ((StructuredSelection)event.getSelection()).getFirstElement())); - } - }); - [editor.elementEditorName()/]RadioViewer.setID([editor.editorID()/]); - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('RadioViewer'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioGettersSetters.mtl deleted file mode 100644 index a7653b6b6..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioGettersSetters.mtl +++ /dev/null @@ -1,113 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module radioGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('Radio'))] -[elementEditor.getterSignature()/] { - if ([elementEditor.elementEditorName()/]RadioViewer.getSelection() instanceof StructuredSelection) { - StructuredSelection sSelection = (StructuredSelection) [elementEditor.elementEditorName()/]RadioViewer.getSelection(); - return sSelection.getFirstElement(); - } - return null; - } -[/template] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('Radio'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('Radio'))] - public void init[elementEditor.viewPackageSignature()/](Object input, [include('org.eclipse.emf.common.util.Enumerator')/] current) -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('Radio'))] - /** - * Init the [elementEditor.name/] - * @param input the viewer input - * @param current the current value - */ -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('Radio'))] -[elementEditor.setterSignature()/] { - [elementEditor.elementEditorName()/]RadioViewer.setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](newValue)); - [elementEditor.readOnly()/] - } -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('Radio'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('Radio'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](eenum, current); - } - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/](new StructuredSelection(newValue)); - } -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides initSignatureDocumentationImplementation ? (elementEditor.representationName('Radio'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](Object input, Enumerator current) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('Radio'))] -[elementEditor.initSignature()/] { - [elementEditor.elementEditorName()/]RadioViewer.setInput(input); - [elementEditor.elementEditorName()/]RadioViewer.setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](current)); - [elementEditor.readOnly()/] - } -[/template] - -[template public setReadOnly (editor : ElementEditor) overrides setReadOnly ? (editor.representation.name = 'Radio')] -[editor.elementEditorName()/]RadioViewer.setEnabled(false); -[editor.elementEditorName()/]RadioViewer.setToolTipText([include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.owningViewString()/]_ReadOnly); -[/template] - -[template public unsetReadOnly (editor : ElementEditor) overrides unsetReadOnly ? (editor.representation.name = 'Radio')] -[editor.elementEditorName()/]RadioViewer.setEnabled(true); -[/template] - -[template public readOnly (editor : ElementEditor) overrides readOnly ? (editor.representation.name = 'Radio')] -[if (editor.readOnly)] -[editor.setReadOnly()/] -[else] -boolean eefElementEditorReadOnlyState = isReadOnly([editor.editorID()/][navigationReadOnly()/]); -if (eefElementEditorReadOnlyState && [editor.elementEditorName()/]RadioViewer.isEnabled()) { - [editor.setReadOnly()/] -} else if (!eefElementEditorReadOnlyState && ![editor.elementEditorName()/]RadioViewer.isEnabled()) { - [editor.unsetReadOnly()/] -} -[/if] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioSWTImpl.mtl deleted file mode 100644 index 1f301ce46..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/radio/radioSWTImpl.mtl +++ /dev/null @@ -1,64 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module radioSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Radio')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.emf.ecore.EEnumLiteral', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'Radio')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.RadioViewer')/] [editor.elementEditorName()/]RadioViewer; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'Radio')] -return create[editor.name.toJavaClassifier()/]RadioViewer(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'Radio')] - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]RadioViewer(Composite parent) { - [editor.elementEditorName()/]RadioViewer = new RadioViewer(parent, SWT.CHECK); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 2; - [editor.elementEditorName()/]RadioViewer.setLayoutData([editor.elementEditorName()/]Data); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); - [editor.elementEditorName()/]RadioViewer.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, ((StructuredSelection)event.getSelection()).getFirstElement())); - } - }); - [editor.elementEditorName()/]RadioViewer.setID([editor.editorID()/]); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('RadioViewer'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableControl.mtl deleted file mode 100644 index 46eb9b971..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableControl.mtl +++ /dev/null @@ -1,210 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module referencetableControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::filters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case : model = Reference(*) - view = ReferencesTable or AdvancedReferencesTable===== /] -[query public validCaseForSimpleReference(editionElement : PropertiesEditionElement) : Boolean = - (not editionElement.hasModelNavigation()) - and editionElement.model.isReferenceMany() - and (editionElement.representationName('ReferencesTable') or editionElement.representationName('AdvancedReferencesTable')) /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForSimpleReference())] - -/** - * Settings for [editionElement.name/] ReferencesTable - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForSimpleReference())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].ADD) { - if (event.getNewValue() instanceof [include(editionElement.peeModelQualifiedClass())/]) { - [editionElement.name.toJavaIdentifier()/]Settings.addToReference((EObject) event.getNewValue()); - } -} else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.removeFromReference((EObject) event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.MOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.move(event.getNewIndex(), ([editionElement.peeModelClass()/]) event.getNewValue()); -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForSimpleReference())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForSimpleReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? ((not editionElement.hasModelNavigation()) and editionElement.model.isReferenceMany() and editionElement.representationName('ReferencesTable'))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - if (element instanceof EObject) - return (![view.viewIdentifier(pec)/].isContainedIn[editionElement.views->first().viewPackageSignature()/]Table((EObject)element)); - return [if (not editionElement.model.required)]element instanceof String && element.equals("")[else]false[/if]; - } - - }); - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.emf.eef.runtime.impl.filters.EObjectStrictFilter')/]([editionElement.metamodelTypeGetter()/])); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? ((not editionElement.hasModelNavigation()) and editionElement.model.isReferenceMany() and editionElement.representationName('AdvancedReferencesTable'))] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter')/]([editionElement.metamodelTypeGetter()/])); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] - -[comment ===== Case : model = Reference(*) in Simple Navigation - view = ReferencesTable or AdvancedReferencesTable===== /] -[query public validCaseForMultipleModelReference(editionElement : PropertiesEditionElement) : Boolean = - editionElement.hasModelNavigation() - and (editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isReferenceMany())) - and (editionElement.representationName('ReferencesTable') or editionElement.representationName('AdvancedReferencesTable'))/] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForMultipleModelReference())] - -/** - * Settings for [editionElement.name/] ReferencesTable - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForMultipleModelReference())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].ADD) { - if (event.getNewValue() instanceof [include(editionElement.peeModelQualifiedClass())/]) { - [editionElement.name.toJavaIdentifier()/]Settings.addToReference((EObject) event.getNewValue()); - } -} else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.removeFromReference((EObject) event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.MOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.move(event.getNewIndex(), ([editionElement.peeModelClass()/]) event.getNewValue()); -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForMultipleModelReference())] -if ([editionElement.name.toJavaIdentifier()/]Settings.isAffectingFeature((EStructuralFeature)msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForMultipleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).metamodelGetter()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForMultipleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.emf.eef.runtime.impl.filters.EObjectStrictFilter')/]([editionElement.metamodelTypeGetter()/])); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] - -[comment ===== Case : model = Reference(1) - view = ReferencesTable or AdvancedReferencesTable===== /] -[query public validCaseForSingleModelReference(editionElement : PropertiesEditionElement) : Boolean = - editionElement.hasModelNavigation() - and (editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentMany() and editionElement.model.isReferenceSingle())) - and (editionElement.representationName('ReferencesTable') or editionElement.representationName('AdvancedReferencesTable'))/] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForSingleModelReference())] - -/** - * Settings for [editionElement.name/] ReferencesTable - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForSingleModelReference())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].ADD) { - if (event.getNewValue() instanceof [include(editionElement.peeModelQualifiedClass())/]) { - [editionElement.name.toJavaIdentifier()/]Settings.addToReference((EObject) event.getNewValue()); - } -} else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.removeFromReference((EObject) event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.MOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.move(event.getNewIndex(), ([editionElement.peeModelClass()/]) event.getNewValue()); -} -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForSingleModelReference())] -if ([editionElement.name.toJavaIdentifier()/]Settings.isAffectingFeature((EStructuralFeature)msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -} -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForSingleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).metamodelGetter()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForSingleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - return [if (editionElement.model.lowerBound = 0)](element instanceof String && element.equals("")) || [/if](element instanceof [include(editionElement.peeModelQualifiedClass())/]);[if (editionElement.model.lowerBound = 0)] //$NON-NLS-1$ [/if] - } - - }); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableFormImpl.mtl deleted file mode 100644 index 9fc2869d8..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableFormImpl.mtl +++ /dev/null @@ -1,374 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module referencetableFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = ReferencesTable ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'ReferencesTable')] -[pec.addImports(Sequence{ - 'java.util.Iterator', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.common.notify.AdapterFactory', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.EMFModelViewerDialog', - 'org.eclipse.jface.viewers.ILabelProviderListener', - 'org.eclipse.jface.viewers.ITableLabelProvider', - 'org.eclipse.jface.viewers.TableViewer', - 'org.eclipse.jface.viewers.IStructuredSelection', - 'org.eclipse.swt.graphics.Image', - 'org.eclipse.swt.widgets.Label', - 'org.eclipse.swt.widgets.TableColumn', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'ReferencesTable')] - protected [include('org.eclipse.jface.viewers.TableViewer')/] [editor.elementEditorName()/]; - protected [include('org.eclipse.swt.widgets.Button')/] add[editor.name.toJavaClassifier()/]; - protected Button remove[editor.name.toJavaClassifier()/]; - protected [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> [editor.elementEditorName()/]BusinessFilters = new [include('java.util.ArrayList')/](); - protected List [editor.elementEditorName()/]Filters = new ArrayList(); -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'ReferencesTable')] -return create[editor.name.toJavaClassifier()/]ReferencesTable(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'ReferencesTable')] - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]ReferencesTable(FormToolkit widgetFactory, Composite parent) { - [if (editor.nameAsLabel)] - Label [editor.elementEditorName()/]Label = [include('org.eclipse.emf.eef.runtime.ui.widgets.FormUtils')/].createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - Label [editor.elementEditorName()/]Label = createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - GridData [editor.elementEditorName()/]LabelData = new GridData(); - [editor.elementEditorName()/]LabelData.horizontalSpan = 3; - [editor.elementEditorName()/]Label.setLayoutData([editor.elementEditorName()/]LabelData); - [editor.elementEditorName()/] = create[editor.name.toJavaClassifier()/]Viewer(parent, widgetFactory, adapterFactory); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 2; - [editor.elementEditorName()/]Data.minimumHeight = 120; - [editor.elementEditorName()/]Data.heightHint = 120; - [editor.elementEditorName()/].getTable().setLayoutData([editor.elementEditorName()/]Data); - EditingUtils.setID([editor.elementEditorName()/].getTable(), [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/].getTable(), "eef::[editor.representation.name/]::field"); //$NON-NLS-1$ - create[editor.name.toJavaClassifier()/]ControlPanel(parent, widgetFactory); - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('ReferencesTable'))] - - // [/protected] - return parent; - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected TableViewer create[editor.name.toJavaClassifier()/]Viewer(Composite container, FormToolkit widgetFactory, AdapterFactory adapter) { - org.eclipse.swt.widgets.Table table = widgetFactory.createTable(container, SWT.FULL_SELECTION); - table.setHeaderVisible(true); - GridData gd = new GridData(); - gd.grabExcessHorizontalSpace = true; - gd.horizontalAlignment = GridData.FILL; - gd.grabExcessVerticalSpace = true; - gd.verticalAlignment = GridData.FILL; - table.setLayoutData(gd); - table.setLinesVisible(true); - [if (editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - [editor.defaultColumnInitialisation()/] - [else] - // [protected ('for table '.concat(editor.name).concat(' s columns definition'))] - [editor.defaultColumnInitialisation()/] - // [/protected] - [/if] - - TableViewer result = new TableViewer(table); - result.setLabelProvider(new ITableLabelProvider() { - - [if (editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - [editor.defaultLabelProviderInitialisation()/] - [else] - // [protected ('for table '.concat(editor.name).concat(' label provider'))] - [editor.defaultLabelProviderInitialisation()/] - - // [/protected] - [/if] - - public Image getColumnImage(Object element, int columnIndex) { - return null; - } - - public void addListener(ILabelProviderListener listener) { - } - - public void dispose() { - } - - public boolean isLabelProperty(Object element, String property) { - return false; - } - - public void removeListener(ILabelProviderListener listener) { - } - - }); - return result; - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void create[editor.name.toJavaClassifier()/]ControlPanel(Composite container, FormToolkit widgetFactory) { - Composite result = widgetFactory.createComposite(container, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - result.setLayout(layout); - add[editor.name.toJavaClassifier()/] = widgetFactory.createButton(result, [editor.owningViewsRepository().messagesProvider()/].PropertiesEditionPart_AddListViewerLabel, SWT.NONE); - GridData addData = new GridData(GridData.FILL_HORIZONTAL); - add[editor.name.toJavaClassifier()/].setLayoutData(addData); - add[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - add[editor.name.toJavaClassifier()/](); - } - - }); - EditingUtils.setID(add[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(add[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::addbutton"); //$NON-NLS-1$ - remove[editor.name.toJavaClassifier()/] = widgetFactory.createButton(result, [editor.owningViewsRepository().messagesProvider()/].PropertiesEditionPart_RemoveListViewerLabel, SWT.NONE); - GridData removeData = new GridData(GridData.FILL_HORIZONTAL); - remove[editor.name.toJavaClassifier()/].setLayoutData(removeData); - remove[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - if ([editor.elementEditorName()/].getSelection() instanceof IStructuredSelection) { - remove[editor.name.toJavaClassifier()/]((IStructuredSelection) [editor.elementEditorName()/].getSelection()); - } - } - - }); - EditingUtils.setID(remove[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(remove[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::removebutton"); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('ControlPanel'))] - - // [/protected] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void add[editor.name.toJavaClassifier()/]() { - - EMFModelViewerDialog dialog = new EMFModelViewerDialog(new AdapterFactoryLabelProvider(adapterFactory), [editor.elementEditorName()/].getInput(), [editor.elementEditorName()/]Filters, [editor.elementEditorName()/]BusinessFilters, false, true) { - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - } - - }; - // [protected ('for add'.concat(editor.name.toJavaClassifier()))] - - // [/protected] - dialog.open(); - [editor.elementEditorName()/].refresh(); - } - - /** - * @param selection the [editor.name/] to remove - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void remove[editor.name.toJavaClassifier()/](IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, elem)); - } - [editor.elementEditorName()/].refresh(); - } -[/template] - -[template private defaultLabelProviderInitialisation (editor : ElementEditor) ] - public String getColumnText(Object object, int columnIndex) { - AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory); - if (object instanceof EObject) { - switch (columnIndex) { - case 0: - return labelProvider.getText(object); - } - } - return ""; //$NON-NLS-1$ - } - -[/template] - -[template private defaultColumnInitialisation (editor : ElementEditor) ] - TableColumn name = new TableColumn(table, SWT.NONE); - name.setWidth(80); - name.setText("Label"); //$NON-NLS-1$ - -[/template] - -[comment ===== Case Widget = AdvancedReferencesTable ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'AdvancedReferencesTable')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'java.util.Iterator', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.IStructuredSelection', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext', - 'org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider', - 'org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy', - 'org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog', - 'org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'AdvancedReferencesTable')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable')/] [editor.elementEditorName()/]; - protected [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> [editor.elementEditorName()/]BusinessFilters = new [include('java.util.ArrayList')/](); - protected List [editor.elementEditorName()/]Filters = new ArrayList(); -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'AdvancedReferencesTable')] -return create[editor.name.toJavaClassifier()/]ReferencesTable(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'AdvancedReferencesTable')] - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]ReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.[editor.elementEditorName()/] = new ReferencesTable(getDescription([editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]), new ReferencesTableListener () { - public void handleAdd() { add[editor.name.toJavaClassifier()/](); } - public void handleEdit(EObject element) { edit[editor.name.toJavaClassifier()/](element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { move[editor.name.toJavaClassifier()/](element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFrom[editor.name.toJavaClassifier()/](element); } - public void navigateTo(EObject element) { } - }); - this.[editor.elementEditorName()/].setHelpText(propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - this.[editor.elementEditorName()/].createControls(parent, widgetFactory); - this.[editor.elementEditorName()/].addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 3; - this.[editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - this.[editor.elementEditorName()/].disableMove(); - [editor.elementEditorName()/].setID([editor.editorID()/]); - [editor.elementEditorName()/].setEEFType("eef::[editor.representation.name/]"); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('ReferencesTable'))] - - // [/protected] - return parent; - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void add[editor.name.toJavaClassifier()/]() { - [editor.defaultAddOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void move[editor.name.toJavaClassifier()/](EObject element, int oldIndex, int newIndex) { - [editor.defaultMoveOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void removeFrom[editor.name.toJavaClassifier()/](EObject element) { - [editor.defaultRemoveOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void edit[editor.name.toJavaClassifier()/](EObject element) { - [editor.defaultEditOperation()/] - } -[/template] - -[template public defaultAddOperation (editor : ElementEditor) ] -TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog([editor.elementEditorName()/].getInput(), [editor.elementEditorName()/]Filters, [editor.elementEditorName()/]BusinessFilters, -"[editor.name/]", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - [editor.elementEditorName()/].refresh(); - } -}; -dialog.open(); -[/template] - -[template public defaultMoveOperation (editor : ElementEditor) ] -propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); -[editor.elementEditorName()/].refresh(); -[/template] - -[template public defaultEditOperation (editor : ElementEditor)] -EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); -PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); -if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - [editor.elementEditorName()/].refresh(); - } -} -[/template] - -[template public defaultRemoveOperation (editor : ElementEditor) ] -propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); -[editor.elementEditorName()/].refresh(); -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableGettersSetters.mtl deleted file mode 100644 index a89f1ca50..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableGettersSetters.mtl +++ /dev/null @@ -1,165 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module referencetableGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public getterDeclaration(elementEditor : ElementEditor) overrides getterDeclaration ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] -[/template] - -[template public getterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides getterImplementation ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] -[/template] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.updateSignatureDocumentation()/] -[elementEditor.updateSignature()/]; - -[elementEditor.addFilterSignatureDocumentation()/] -[elementEditor.addFilterSignature()/]; - -[elementEditor.addBusinessFilterSignatureDocumentation()/] -[elementEditor.addBusinessFilterSignature()/]; - -[elementEditor.isContainedInTableSignatureDocumentation()/] -[elementEditor.isContainedInTableSignature()/]; -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] - public void init[elementEditor.viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] settings) -[/template] - -[template public getterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides getterImplementationDelegate ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] - /** - * Init the [elementEditor.name/] - * @param settings settings for the [elementEditor.name/] ReferencesTable - */ -[/template] - - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[updateSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.updateSignatureImplementation()/] - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignatureImplementation()/] - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignatureImplementation()/] - -[isContainedInTableSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.isContainedInTableSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](settings); - } - -[updateSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.updateSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.update[elementEditor.viewPackageSignature()/](); - } - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addBusinessFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[isContainedInTableSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.isContainedInTableSignature()/] { - return [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.isContainedIn[elementEditor.viewPackageSignature()/]Table(element); - } -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides initSignatureDocumentationImplementation ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] -[elementEditor.initSignature()/] { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider')/] contentProvider = new ReferencesTableContentProvider(); - [elementEditor.elementEditorName()/].setContentProvider(contentProvider); - [elementEditor.elementEditorName()/].setInput(settings); - [elementEditor.elementEditorName()/]BusinessFilters.clear(); - [elementEditor.elementEditorName()/]Filters.clear(); - [elementEditor.readOnly()/] - } -[/template] - -[template public addFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] -[elementEditor.addFilterSignature()/] { - [elementEditor.elementEditorName()/]Filters.add(filter); - } -[/template] - -[template public addBusinessFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] -[elementEditor.addBusinessFilterSignature()/] { - [elementEditor.elementEditorName()/]BusinessFilters.add(filter); - } -[/template] - -[template public isContainedInTableSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('ReferencesTable') or elementEditor.representationName('AdvancedReferencesTable'))] -[elementEditor.isContainedInTableSignature()/] { - return ((ReferencesTableSettings)[elementEditor.elementEditorName()/].getInput()).contains(element); - } -[/template] - -[template public readOnly (editor : ElementEditor) overrides readOnly ? (editor.representation.name = 'ReferencesTable' or editor.representationName('AdvancedReferencesTable'))] -[if (editor.readOnly)] -[setReadOnly()/] -[else] -boolean eefElementEditorReadOnlyState = isReadOnly([editor.editorID()/][navigationReadOnly()/]); -if (eefElementEditorReadOnlyState && [editor.elementEditorName()/].getTable().isEnabled()) { - [editor.setReadOnly()/] -} else if (!eefElementEditorReadOnlyState && ![editor.elementEditorName()/].getTable().isEnabled()) { - [editor.unsetReadOnly()/] -} -[/if] -[/template] - -[template public setReadOnly (editor : ElementEditor) overrides setReadOnly ? (editor.representation.name = 'ReferencesTable')] -[editor.elementEditorName()/].getTable().setEnabled(false); -[editor.elementEditorName()/].getTable().setToolTipText([editor.owningViewsRepository().messagesProvider()/].[editor.owningViewString()/]_ReadOnly); -[editor.setAddButtonReadOnly()/] -[editor.setRemoveButtonReadOnly()/] -[/template] - -[template public unsetReadOnly (editor : ElementEditor) overrides unsetReadOnly ? (editor.representation.name = 'ReferencesTable')] -[editor.elementEditorName()/].getTable().setEnabled(true); -[editor.unsetAddButtonReadOnly()/] -[editor.unsetRemoveButtonReadOnly()/] -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableSWTImpl.mtl deleted file mode 100644 index 56d786796..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/referencetable/referencetableSWTImpl.mtl +++ /dev/null @@ -1,369 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module referencetableSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = ReferencesTable ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'ReferencesTable')] -[pec.addImports(Sequence{ - 'java.util.Iterator', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.common.notify.AdapterFactory', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.EMFModelViewerDialog', - 'org.eclipse.jface.viewers.ILabelProviderListener', - 'org.eclipse.jface.viewers.ITableLabelProvider', - 'org.eclipse.jface.viewers.TableViewer', - 'org.eclipse.jface.viewers.IStructuredSelection', - 'org.eclipse.swt.graphics.Image', - 'org.eclipse.swt.widgets.Label', - 'org.eclipse.swt.widgets.TableColumn', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'ReferencesTable')] - protected [include('org.eclipse.jface.viewers.TableViewer')/] [editor.elementEditorName()/]; - protected [include('org.eclipse.swt.widgets.Button')/] add[editor.name.toJavaClassifier()/]; - protected Button remove[editor.name.toJavaClassifier()/]; - protected [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> [editor.elementEditorName()/]BusinessFilters = new [include('java.util.ArrayList')/](); - protected List [editor.elementEditorName()/]Filters = new ArrayList(); -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'ReferencesTable')] -return create[editor.name.toJavaClassifier()/]ReferencesTable(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'ReferencesTable')] - /** - * @param parent - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]ReferencesTable(Composite parent) { - [if (editor.nameAsLabel)] - Label [editor.elementEditorName()/]Label = [include('org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils')/].createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - Label [editor.elementEditorName()/]Label = createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - GridData [editor.elementEditorName()/]LabelData = new GridData(); - [editor.elementEditorName()/]LabelData.horizontalSpan = 3; - [editor.elementEditorName()/]Label.setLayoutData([editor.elementEditorName()/]LabelData); - [editor.elementEditorName()/] = create[editor.name.toJavaClassifier()/]Viewer(parent, adapterFactory); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 2; - [editor.elementEditorName()/]Data.minimumHeight = 120; - [editor.elementEditorName()/]Data.heightHint = 120; - [editor.elementEditorName()/].getTable().setLayoutData([editor.elementEditorName()/]Data); - EditingUtils.setID([editor.elementEditorName()/].getTable(), [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/].getTable(), "eef::[editor.representation.name/]::field"); //$NON-NLS-1$ - create[editor.name.toJavaClassifier()/]ControlPanel(parent); - return parent; - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected TableViewer create[editor.name.toJavaClassifier()/]Viewer(Composite container, AdapterFactory adapter) { - org.eclipse.swt.widgets.Table table = new org.eclipse.swt.widgets.Table(container, SWT.FULL_SELECTION); - table.setHeaderVisible(true); - GridData gd = new GridData(); - gd.grabExcessHorizontalSpace = true; - gd.horizontalAlignment = GridData.FILL; - gd.grabExcessVerticalSpace = true; - gd.verticalAlignment = GridData.FILL; - table.setLayoutData(gd); - table.setLinesVisible(true); - [if (editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - [editor.defaultColumnInitialisation()/] - [else] - // [protected ('for table '.concat(editor.name).concat(' s columns definition'))] - [editor.defaultColumnInitialisation()/] - // [/protected] - [/if] - - TableViewer result = new TableViewer(table); - result.setLabelProvider(new ITableLabelProvider() { - - [if (editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - [editor.defaultLabelProviderInitialisation()/] - [else] - // [protected ('for table '.concat(editor.name).concat(' label provider'))] - [editor.defaultLabelProviderInitialisation()/] - // [/protected] - [/if] - - public void addListener(ILabelProviderListener listener) { - } - - public void dispose() { - } - - public boolean isLabelProperty(Object element, String property) { - return false; - } - - public void removeListener(ILabelProviderListener listener) { - } - - }); - return result; - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void create[editor.name.toJavaClassifier()/]ControlPanel(Composite container) { - Composite result = new Composite(container, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - result.setLayout(layout); - add[editor.name.toJavaClassifier()/] = new Button(result, SWT.NONE); - add[editor.name.toJavaClassifier()/].setText([editor.owningViewsRepository().messagesProvider()/].PropertiesEditionPart_AddListViewerLabel); - GridData addData = new GridData(GridData.FILL_HORIZONTAL); - add[editor.name.toJavaClassifier()/].setLayoutData(addData); - add[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - add[editor.name.toJavaClassifier()/](); - } - - }); - EditingUtils.setID(add[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(add[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::addbutton"); //$NON-NLS-1$ - remove[editor.name.toJavaClassifier()/] = new Button(result, SWT.NONE); - remove[editor.name.toJavaClassifier()/].setText([editor.owningViewsRepository().messagesProvider()/].PropertiesEditionPart_RemoveListViewerLabel); - GridData removeData = new GridData(GridData.FILL_HORIZONTAL); - remove[editor.name.toJavaClassifier()/].setLayoutData(removeData); - remove[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - if ([editor.elementEditorName()/].getSelection() instanceof IStructuredSelection) { - remove[editor.name.toJavaClassifier()/]((IStructuredSelection) [editor.elementEditorName()/].getSelection()); - } - } - - }); - EditingUtils.setID(remove[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(remove[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::removebutton"); //$NON-NLS-1$ - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void add[editor.name.toJavaClassifier()/]() { - EMFModelViewerDialog dialog = new EMFModelViewerDialog(new AdapterFactoryLabelProvider(adapterFactory), [editor.elementEditorName()/].getInput(), [editor.elementEditorName()/]Filters, [editor.elementEditorName()/]BusinessFilters, false, true) { - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - } - - }; - dialog.open(); - // [protected ('for add'.concat(editor.name.toJavaClassifier()))] - - // [/protected] - [editor.elementEditorName()/].refresh(); - } - - /** - * @param selection the [editor.name/] to remove - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void remove[editor.name.toJavaClassifier()/](IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, elem)); - } - [editor.elementEditorName()/].refresh(); - } -[/template] - -[template private defaultLabelProviderInitialisation(editor : ElementEditor) ] - public String getColumnText(Object object, int columnIndex) { - AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory); - if (object instanceof EObject) { - switch (columnIndex) { - case 0: - return labelProvider.getText(object); - } - } - return ""; //$NON-NLS-1$ - } - - public Image getColumnImage(Object element, int columnIndex) { - return null; - } - -[/template] - -[template private defaultColumnInitialisation (editor : ElementEditor) ] - TableColumn name = new TableColumn(table, SWT.NONE); - name.setWidth(80); - name.setText("Label"); //$NON-NLS-1$ - -[/template] - -[comment ===== Case Widget = AdvancedReferencesTable ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'AdvancedReferencesTable')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'java.util.Iterator', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.IStructuredSelection', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext', - 'org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider', - 'org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy', - 'org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog', - 'org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'AdvancedReferencesTable')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable')/] [editor.elementEditorName()/]; - protected [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> [editor.elementEditorName()/]BusinessFilters = new [include('java.util.ArrayList')/](); - protected List [editor.elementEditorName()/]Filters = new ArrayList(); -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'AdvancedReferencesTable')] -return create[editor.name.toJavaClassifier()/]AdvancedReferencesTable(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'AdvancedReferencesTable')] - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]AdvancedReferencesTable(Composite parent) { - [if (editor.nameAsLabel)] - String label = [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/] - [else] - String label = getDescription([editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - this.[editor.elementEditorName()/] = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { add[editor.name.toJavaClassifier()/](); } - public void handleEdit(EObject element) { edit[editor.name.toJavaClassifier()/](element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { move[editor.name.toJavaClassifier()/](element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFrom[editor.name.toJavaClassifier()/](element); } - public void navigateTo(EObject element) { } - }); - this.[editor.elementEditorName()/].setHelpText(propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - this.[editor.elementEditorName()/].createControls(parent); - this.[editor.elementEditorName()/].addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 3; - this.[editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - this.[editor.elementEditorName()/].disableMove(); - [editor.elementEditorName()/].setID([editor.editorID()/]); - [editor.elementEditorName()/].setEEFType("eef::[editor.representation.name/]"); //$NON-NLS-1$ - return parent; - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void add[editor.name.toJavaClassifier()/]() { - [editor.defaultAddOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void move[editor.name.toJavaClassifier()/](EObject element, int oldIndex, int newIndex) { - [editor.defaultMoveOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void removeFrom[editor.name.toJavaClassifier()/](EObject element) { - [editor.defaultRemoveOperation()/] - } - - /** - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected void edit[editor.name.toJavaClassifier()/](EObject element) { - [editor.defaultEditOperation()/] - } -[/template] - -[template public defaultAddOperation (editor : ElementEditor) ] -TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog([editor.elementEditorName()/].getInput(), [editor.elementEditorName()/]Filters, [editor.elementEditorName()/]BusinessFilters, -"[editor.name/]", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - [editor.elementEditorName()/].refresh(); - } -}; -dialog.open(); -[/template] - -[template public defaultMoveOperation (editor : ElementEditor) ] -propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); -[editor.elementEditorName()/].refresh(); -[/template] - -[template public defaultEditOperation (editor : ElementEditor) ] -EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); -PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); -if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - [editor.elementEditorName()/].refresh(); - } -} -[/template] - -[template public defaultRemoveOperation(editor : ElementEditor) ] -propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); -[editor.elementEditorName()/].refresh(); -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogControl.mtl deleted file mode 100644 index a51630248..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogControl.mtl +++ /dev/null @@ -1,64 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module selectionDialogControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('SelectionDialog') and not editionElement.model.derived and not editionElement.canGeneratemodelNavigation())] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/]((String)event.getNewValue()); -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('SelectionDialog'))] -if ([editionElement.liveUpdaterNavigationConditionForText(pec)/] && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) { - if (msg.getNewValue() != null) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EcoreUtil.convertToString([editionElement.metamodelGetter()/].getEAttributeType(), msg.getNewValue())); - } else { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](""); - } -} -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('SelectionDialog') and not editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.isPrimitiveType())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].convertToString([editionElement.metamodelGetter()/].getEAttributeType(), [pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]())); -} -[else] - if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].convertToString([editionElement.metamodelGetter()/].getEAttributeType(), [pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]())); - } -[/if] -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('SelectionDialog') and not editionElement.model.derived and editionElement.canGeneratemodelNavigation())] -[editionElement.name.toJavaIdentifier()/]Settings.setValue((String)event.getNewValue()); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('SelectionDialog') and editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.isPrimitiveType())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].convertToString([editionElement.metamodelGetter()/].getEAttributeType(), [pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]())); -} -[else] - if ([editionElement.name.toJavaIdentifier()/]Settings.getValue() != null && isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/]([include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].convertToString([editionElement.metamodelGetter()/].getEAttributeType(), [editionElement.name.toJavaIdentifier()/]Settings.getValue())); - } -[/if] -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('SelectionDialog'))] -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogFormImpl.mtl deleted file mode 100644 index c8913f9eb..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogFormImpl.mtl +++ /dev/null @@ -1,113 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module selectionDialogFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'SelectionDialog')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.events.KeyAdapter', - 'org.eclipse.swt.events.KeyEvent', - 'org.eclipse.core.resources.IFile', - 'org.eclipse.ui.PlatformUI', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.swt.events.FocusAdapter', - 'org.eclipse.swt.events.FocusEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.widgets.Shell', - 'org.eclipse.emf.common.ui.dialogs.WorkspaceResourceDialog', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representationName('SelectionDialog'))] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.SelectionDialog')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representationName('SelectionDialog'))] -return create[editor.name.toJavaClassifier()/]SelectionDialog(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representationName('SelectionDialog'))] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]SelectionDialog(FormToolkit widgetFactory, Composite parent) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new SelectionDialog(parent, SWT.NONE, widgetFactory); - GridData generatorData = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData(generatorData); - - [editor.elementEditorName()/].addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent e) { - [editor.elementEditorName()/]SelectionDialog(); - } - }); - - [editor.elementEditorName()/].addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - }); - [editor.elementEditorName()/].addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - } - }); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('SelectionDialog'))] - - // [/protected] - return parent; - } - - protected void [editor.elementEditorName()/]SelectionDialog() { - //[protected ('browse button selection dialog')] - if (PlatformUI.getWorkbench() != null && PlatformUI.getWorkbench().getActiveWorkbenchWindow() != null) { - Shell theShell = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(); - IFile['['/][']'/] file = WorkspaceResourceDialog.openFileSelection(theShell, "File Selection", "", false, null, null); - if(file.length == 1) { - [editor.elementEditorName()/].setText(file['['/]0[']'/].getProject().getName() + "/" + file['['/]0[']'/].getProjectRelativePath().toString()); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - } - //[/protected] - } -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogGettersSetters.mtl deleted file mode 100644 index 186424ae1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogGettersSetters.mtl +++ /dev/null @@ -1,35 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module selectionDialogGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('SelectionDialog'))] -[elementEditor.getterSignature()/] { - return [elementEditor.elementEditorName()/].getText(); - } -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('SelectionDialog'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].setText(newValue); - } else { - [elementEditor.elementEditorName()/].setText(""); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogSWTImpl.mtl deleted file mode 100644 index 9cb6156f8..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/selectionfile/selectionDialogSWTImpl.mtl +++ /dev/null @@ -1,111 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module selectionDialogSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'SelectionDialog')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.events.KeyAdapter', - 'org.eclipse.swt.events.KeyEvent', - 'org.eclipse.core.resources.IFile', - 'org.eclipse.ui.PlatformUI', - 'org.eclipse.swt.events.FocusAdapter', - 'org.eclipse.swt.events.FocusEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.widgets.Shell', - 'org.eclipse.emf.common.ui.dialogs.WorkspaceResourceDialog', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representationName('SelectionDialog'))] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.SelectionDialog')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representationName('SelectionDialog'))] -return create[editor.name.toJavaClassifier()/]SelectionDialog(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representationName('SelectionDialog'))] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]SelectionDialog(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = new SelectionDialog(parent, SWT.NONE); - GridData generatorData = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData(generatorData); - - [editor.elementEditorName()/].addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent e) { - [editor.elementEditorName()/]SelectionDialog(); - } - }); - - [editor.elementEditorName()/].addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - }); - [editor.elementEditorName()/].addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - } - }); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('SelectionDialog'))] - - // [/protected] - return parent; - } - - protected void [editor.elementEditorName()/]SelectionDialog() { - //[protected ('browse button selection dialog')] - if (PlatformUI.getWorkbench() != null && PlatformUI.getWorkbench().getActiveWorkbenchWindow() != null) { - Shell theShell = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(); - IFile['['/][']'/] file = WorkspaceResourceDialog.openFileSelection(theShell, "File Selection", "", false, null, null); - if(file.length == 1) { - [editor.elementEditorName()/].setText(file['['/]0[']'/].getProject().getName() + "/" + file['['/]0[']'/].getProjectRelativePath().toString()); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - } - //[/protected] - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorControl.mtl deleted file mode 100644 index f5cd953aa..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorControl.mtl +++ /dev/null @@ -1,90 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2012 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module singlecompositioneditorControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::filters /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case : model = Composition(1) - view = SingleCompositionEditor ===== /] - - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForContainment())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].EDIT) { - if ([editionElement.name.toJavaIdentifier()/]Settings.getValue() == "") { - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(editingContext.getEObject(), PropertiesEditingProvider.class); - Object result = null; - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - result = ((CreateEditingPolicy) policy).getResult(); - } - } - if (result != null) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(result); - } - } else { - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, (EObject) [editionElement.name.toJavaIdentifier()/]Settings.getValue(), editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt([editionElement.name.toJavaIdentifier()/]Settings.getValue(), PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - } -} else if (event.getKind() == PropertiesEditionEvent.UNSET) { - [editionElement.name.toJavaIdentifier()/]Settings.setToReference(null); -} - -[/template] - - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.hasModelNavigation() and editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isReferenceSingle() and (editionElement.representationName('SingleCompositionEditor'))))] -[/template] - -[comment ===== Case : model = Containment(1), Simple navigation or not - view = SingleCompositionEditor ===== /] -[query public validCaseForContainment(editionElement : PropertiesEditionElement) : Boolean = - editionElement.model.isContainmentSingle() - and (editionElement.representationName('SingleCompositionEditor')) /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForContainment())] - -/** - * Settings for [editionElement.name/] SingleCompositionEditor - */ -private [include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForContainment())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](([editionElement.views->first().toJavaType().trim()/])msg.getNewValue()); -[/template] - - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForContainment() and not editionElement.hasModelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) { - // init part - [editionElement.name.toJavaIdentifier()/]Settings = new EObjectFlatComboSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForContainment())] -[comment no filters on creation/] -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorFormImpl.mtl deleted file mode 100644 index 2876e4425..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorFormImpl.mtl +++ /dev/null @@ -1,76 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2012 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module singlecompositioneditorFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = SingleCompositionEditor ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'SingleCompositionEditor')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.SingleCompositionEditor.SingleCompositionListener', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'SingleCompositionEditor')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.SingleCompositionEditor')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'SingleCompositionEditor')] -return create[editor.name.toJavaClassifier()/]SingleCompositionEditor(parent, widgetFactory); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'SingleCompositionEditor')] - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]SingleCompositionEditor(Composite parent, FormToolkit widgetFactory) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - //create widget - [editor.elementEditorName()/] = new SingleCompositionEditor(widgetFactory, parent, SWT.NONE); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addEditorListener(new SingleCompositionListener() { - - public void edit() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, null)); - [editor.elementEditorName()/].refresh(); - } - - public void clear() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.UNSET, null, null)); - [editor.elementEditorName()/].refresh(); - } - }); - [editor.elementEditorName()/].setID([editor.editorID()/]); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('SingleCompositionEditor'))] - - // [/protected] - return parent; - } - -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorGettersSetters.mtl deleted file mode 100644 index 4ac8198cd..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorGettersSetters.mtl +++ /dev/null @@ -1,93 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2012 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module singlecompositioneditorGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('SingleCompositionEditor'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('SingleCompositionEditor'))] - /** - * Init the [elementEditor.name/] - * @param settings the combo setting - */ -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('SingleCompositionEditor'))] - public void init[elementEditor.viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings')/] settings) -[/template] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('SingleCompositionEditor'))] -[elementEditor.getterSignature()/] { - return (EObject) [elementEditor.elementEditorName()/].getInput(); - } -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('SingleCompositionEditor'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('SingleCompositionEditor'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](settings); - } - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/](newValue); - } - -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('SingleCompositionEditor'))] -[elementEditor.setterSignature()/] { - [elementEditor.elementEditorName()/].refresh(); - [elementEditor.readOnly()/] - } -[/template] - -[template public setterButtonModeSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) ? (elementEditor.representationName('SingleCompositionEditor'))] -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) ? (elementEditor.representationName('SingleCompositionEditor'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](EObjectFlatComboSettings) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('SingleCompositionEditor'))] -[elementEditor.initSignature()/] { - [elementEditor.elementEditorName()/].setAdapterFactory(adapterFactory); - [elementEditor.elementEditorName()/].setInput(settings); - [elementEditor.readOnly()/] - } -[/template] - -[template public addBusinessFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('SingleCompositionEditor'))] -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorSWTImpl.mtl deleted file mode 100644 index a29149021..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singleCompositionEditor/singlecompositioneditorSWTImpl.mtl +++ /dev/null @@ -1,73 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2012 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module singlecompositioneditorSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = SingleCompositionEditor ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'SingleCompositionEditor')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.ecore.EObject', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.widgets.SingleCompositionEditor.SingleCompositionListener', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'SingleCompositionEditor')] - private [include('org.eclipse.emf.eef.runtime.ui.widgets.SingleCompositionEditor')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'SingleCompositionEditor')] -return create[editor.name.toJavaClassifier()/]SingleCompositionEditor(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'SingleCompositionEditor')] - /** - * @param parent the parent composite - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]SingleCompositionEditor(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - //create widget - [editor.elementEditorName()/] = new SingleCompositionEditor(parent, SWT.NONE); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addEditorListener(new SingleCompositionListener() { - - public void edit() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, null)); - [editor.elementEditorName()/].refresh(); - } - - public void clear() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.UNSET, null, null)); - [editor.elementEditorName()/].refresh(); - } - }); - [editor.elementEditorName()/].setID([editor.editorID()/]); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('SingleCompositionEditor'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerControl.mtl deleted file mode 100644 index 96b01b744..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerControl.mtl +++ /dev/null @@ -1,35 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module singlecompositionviewerControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] - -[comment ===== Case : model = Reference(1) - view = SingleCompositionViewer ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isContainmentSingle() and editionElement.representationName('SingleCompositionViewer'))] -//FIXME: Sorry this widget is deprecated for this version. -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isContainmentSingle() and editionElement.representationName('SingleCompositionViewer'))] -//FIXME: Sorry this widget is deprecated for this version. -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.representationName('SingleCompositionViewer'))] -//FIXME: Sorry this widget is deprecated for this version. -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.representationName('SingleCompositionViewer'))] -//FIXME: Sorry this widget is deprecated for this version. -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerFormImpl.mtl deleted file mode 100644 index 6d4bf8017..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerFormImpl.mtl +++ /dev/null @@ -1,88 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module singlecompositionviewerFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'SingleCompositionViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionListener', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'SingleCompositionViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.SingleCompositionViewer')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'SingleCompositionViewer')] -return create[editor.name.toJavaClassifier()/]SingleCompositionViewer(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'SingleCompositionViewer')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]SingleCompositionViewer(FormToolkit widgetFactory, Composite parent) { - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 3; - this.[editor.elementEditorName()/] = new SingleCompositionViewer(getDescription([editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]), parent, SWT.NONE, widgetFactory, [editor.owningViewsRepository().vrClass()/].FORM_KIND, propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - this.[editor.elementEditorName()/].setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - this.[editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [if (editor.readOnly)] - [editor.elementEditorName()/].setEnabled(false); - [else] - this.[editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.viewPackageGetter()/]())); - } - } - }); - - this.[editor.elementEditorName()/].addCheckBoxSelectionListener(new SelectionListener() { - - public void widgetSelected(SelectionEvent e) { - if(![editor.elementEditorName()/].getCheckBoxSelection()) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, null)); - } - } - } - - public void widgetDefaultSelected(SelectionEvent e) { - - } - }); - [/if] - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('SingleCompositionViewer'))] - - // [/protected] - return parent; - } -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerGettersSetters.mtl deleted file mode 100644 index 66fb3d67b..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerGettersSetters.mtl +++ /dev/null @@ -1,125 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module singlecompositionviewerGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('SingleCompositionViewer'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.setterSignatureDocumentation()/] -[elementEditor.setterSignature()/]; - -[elementEditor.addControlListenerSignatureDocumentation()/] -[elementEditor.addControlListenerSignature()/]; -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('SingleCompositionViewer'))] - public void init[elementEditor.viewPackageSignature()/]([include('org.eclipse.emf.ecore.EObject')/] current, [include('org.eclipse.emf.ecore.EReference')/] containingFeature, EReference feature, [include('org.eclipse.emf.edit.domain.EditingDomain')/] editingDomain) -[/template] - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('SingleCompositionViewer'))] - /** - * Init the [elementEditor.name/] - * @param current the current value - * @param containingFeature the feature where to navigate if necessary - * @param feature the feature to manage - * @param editingDomain - */ -[/template] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('SingleCompositionViewer'))] -[elementEditor.getterSignature()/] { - return [elementEditor.elementEditorName()/].getElement(); - } -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('SingleCompositionViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignatureImplementation()/] - -[addControlListenerSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addControlListenerSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('SingleCompositionViewer'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](current, containingFeature, feature, editingDomain); - } - -[setterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.setterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.[elementEditor.viewPackageSetter()/](newValue); - } -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('SingleCompositionViewer'))] -[elementEditor.initSignature()/] { - this.[elementEditor.elementEditorName()/].setInput(current, feature, resourceSet); - this.[elementEditor.elementEditorName()/].init(editingDomain); - if (current != null) { - this.[elementEditor.elementEditorName()/].setSelection(new [include('org.eclipse.jface.viewers.StructuredSelection')/](current), feature); - } - [elementEditor.elementEditorName()/].refresh(); - - } -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('SingleCompositionViewer'))] -[elementEditor.setterSignature()/] { - [elementEditor.elementEditorName()/].update(newValue); - [elementEditor.readOnly()/] - } -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides initSignatureDocumentationImplementation ? (elementEditor.representationName('SingleCompositionViewer'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](EObject current, EReference containingFeature, EReference feature, EditingDomain editingDomain) - */ -[/template] - -[template public addControlListenerSignatureDocumentation(elementEditor : ElementEditor)] - /** - * Add a listener on [elementEditor.name/] widget control. - * @param listener the Control Listener - */ -[/template] - -[template public addControlListenerSignature(elementEditor : ElementEditor)] - public void add[elementEditor.name.toJavaClassifier() /]ControlListener([include('org.eclipse.swt.events.ControlListener')/] listener) -[/template] - -[template public addControlListenerSignatureImplementation(elementEditor : ElementEditor)] -[elementEditor.addControlListenerSignature() /] { - [elementEditor.elementEditorName()/].addControlListener(listener); - } -[/template] - -[template public addControlListenerSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String)] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](ControlListener listener) - */ -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerSWTImpl.mtl deleted file mode 100644 index acedf6be3..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/singlecompositionviewer/singlecompositionviewerSWTImpl.mtl +++ /dev/null @@ -1,100 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module singlecompositionviewerSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'SingleCompositionViewer')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.jface.viewers.ISelectionChangedListener', - 'org.eclipse.jface.viewers.SelectionChangedEvent', - 'org.eclipse.ui.internal.forms.widgets.FormUtil', - 'org.eclipse.swt.custom.ScrolledComposite', - 'org.eclipse.swt.graphics.Rectangle', - 'org.eclipse.swt.graphics.Point', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionListener', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'SingleCompositionViewer')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.SingleCompositionViewer')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'SingleCompositionViewer')] -return create[editor.name.toJavaClassifier()/]SingleCompositionViewer(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'SingleCompositionViewer')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]SingleCompositionViewer(Composite parent) { - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 3; - this.[editor.elementEditorName()/] = new SingleCompositionViewer(getDescription([editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]), parent, SWT.NONE, null, [editor.owningViewsRepository().vrClass()/].SWT_KIND, propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - this.[editor.elementEditorName()/].setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - this.[editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [if (editor.readOnly)] - [editor.elementEditorName()/].setEnabled(false); - [else] - this.[editor.elementEditorName()/].addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.viewPackageGetter()/]())); - [editor.elementEditorName()/].update([editor.viewPackageGetter()/]()); - ScrolledComposite scrolledComposite = (ScrolledComposite)view.getParent().getParent(); - Composite c = (Composite) view.getParent(); - Rectangle clientArea = scrolledComposite.getClientArea(); - - Point newSize = scrolledComposite.computeSize(FormUtil.getWidthHint( - clientArea.width, c), FormUtil.getHeightHint(clientArea.height, - c)); - scrolledComposite.setMinSize(newSize); - } - } - }); - - this.[editor.elementEditorName()/].addCheckBoxSelectionListener(new SelectionListener() { - - public void widgetSelected(SelectionEvent e) { - if(![editor.elementEditorName()/].getCheckBoxSelection()) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, null)); - [editor.elementEditorName()/].update(null); - } - } - } - - public void widgetDefaultSelected(SelectionEvent e) { - - } - }); - [/if] - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('SingleCompositionViewer'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionControl.mtl deleted file mode 100644 index 629887d25..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionControl.mtl +++ /dev/null @@ -1,296 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module tablecompositionControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::filters /] -[import org::eclipse::emf::eef::codegen::services::imports /] -[import org::eclipse::emf::eef::codegen::services::emfCodeGen /] - -[comment ===== Case : model = Containment(*) - view = TableComposition or AdvancedTableComposition===== /] -[query public validCaseForSimpleReference(editionElement : PropertiesEditionElement) : Boolean = - (not editionElement.hasModelNavigation()) - and editionElement.model.isContainmentMany() - and (editionElement.representationName('TableComposition') or editionElement.representationName('AdvancedTableComposition')) /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForSimpleReference())] - -/** - * Settings for [editionElement.name/] ReferencesTable - */ -protected [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForSimpleReference())] -[editionElement.genericDeclareEObjectUpdater()/] -[/template] - - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForSimpleReference())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForSimpleReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForSimpleReference())] -[editionElement.genericFilterUpdater(view, pec)/] -[/template] - -[comment ===== Case : model = Containment(1) - view = TableComposition or AdvancedTableComposition===== /] -[query public validCaseForSingleContainment(editionElement : PropertiesEditionElement) : Boolean = - (not editionElement.hasModelNavigation()) - and editionElement.model.isContainmentSingle() - and (editionElement.representationName('TableComposition') or editionElement.representationName('AdvancedTableComposition')) /] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForSingleContainment())] - -/** - * Settings for [editionElement.name/] ReferencesTable - */ -protected [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForSingleContainment())] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [if (editionElement.hasStrictTypingFilter())] - [for (eClassifier : EClassifier | editionElement.strictTypingFiltersTypes())] - context.addInstanciableTypeFilter(new [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext.InstanciableTypeFilter')/]() { - public boolean select([include('org.eclipse.emf.ecore.EClass')/] instanciableType) { - return [eClassifier.metamodelStrictFilterGetter()/][addImport(eClassifier.ePackage.qualifiedMetamodelPackage())/] == instanciableType; - } - }); - [/for] - [/if] - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] -} else if (event.getKind() == PropertiesEditionEvent.EDIT) { - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] editionPolicy = provider.getPolicy(context); - if (editionPolicy != null) { - editionPolicy.execute(); - } - } -} else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.removeFromReference((EObject) event.getNewValue()); -} -[/template] - - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForSingleContainment())] -if ([editionElement.metamodelGetter()/].equals(msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForSingleContainment())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForSingleContainment())] -[editionElement.genericFilterUpdater(view, pec)/] -[/template] - -[comment ===== Case : model = Containment(*) in Simple Navigation - view = TableComposition or AdvancedTableComposition===== /] -[query public validCaseForMultipleModelReference(editionElement : PropertiesEditionElement) : Boolean = - editionElement.hasModelNavigation() - and (editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentSingle() and editionElement.model.isContainmentMany())) - and (editionElement.representationName('TableComposition') or editionElement.representationName('AdvancedTableComposition'))/] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForMultipleModelReference())] - -/** - * Settings for [editionElement.name/] ReferencesTable - */ -protected [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForMultipleModelReference())] -[editionElement.genericDeclareEObjectUpdater()/] -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForMultipleModelReference())] -if ([editionElement.name.toJavaIdentifier()/]Settings.isAffectingFeature((EStructuralFeature)msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForMultipleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).metamodelGetter()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForMultipleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - [if (editionElement.model.lowerBound = 0)]if (element instanceof String) - return element.equals(""); //$NON-NLS-1$ - [/if] - if (element instanceof [include(editionElement.peeModelQualifiedClass())/]) - return true; - return element instanceof [include('org.eclipse.emf.ecore.resource.Resource')/]; - } - - }); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] - -[comment ===== Case : model = Containment(1) - view = TableComposition or AdvancedTableComposition===== /] -[query public validCaseForSingleModelReference(editionElement : PropertiesEditionElement) : Boolean = - editionElement.hasModelNavigation() - and (editionElement.navigation.oclIsKindOf(navigation::SimpleModelNavigation) and (editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).feature.isContainmentMany() and editionElement.model.isContainmentSingle())) - and (editionElement.representationName('TableComposition') or editionElement.representationName('AdvancedTableComposition'))/] - -[template public additionalComponentField(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides additionalComponentField ? (editionElement.validCaseForSingleModelReference())] - -/** - * Settings for [editionElement.name/] ReferencesTable - */ -protected [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] [editionElement.name.toJavaIdentifier()/]Settings; - -[/template] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.validCaseForSingleModelReference())] -[editionElement.genericDeclareEObjectUpdater()/] -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.validCaseForSingleModelReference())] -if ([editionElement.name.toJavaIdentifier()/]Settings.isAffectingFeature((EStructuralFeature)msg.getFeature()) && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].update[editionElement.views->first().viewPackageSignature()/](); -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.validCaseForSingleModelReference())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [editionElement.name.toJavaIdentifier()/]Settings = new ReferencesTableSettings([pec.pecModelClass().toJavaIdentifier()/], [editionElement.navigation.oclAsType(navigation::SimpleModelNavigation).metamodelGetter()/], [editionElement.metamodelGetter()/]); - [view.viewIdentifier(pec)/].init[editionElement.views->first().viewPackageSignature()/]([editionElement.name.toJavaIdentifier()/]Settings); -} -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.validCaseForSingleModelReference())] -[editionElement.genericFilterUpdater(view, pec)/] -[/template] - -[template private genericDeclareEObjectUpdater(editionElement : PropertiesEditionElement)] -if (event.getKind() == [include('org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent')/].ADD) { - [if (editionElement.model.eType.oclIsTypeOf(EClass))] - [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext')/] context = new EReferencePropertiesEditionContext(editingContext, this, [editionElement.name.toJavaIdentifier()/]Settings, editingContext.getAdapterFactory()); - [if (editionElement.hasStrictTypingFilter())] - [for (eClassifier : EClassifier | editionElement.strictTypingFiltersTypes())] - context.addInstanciableTypeFilter(new [include('org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext.InstanciableTypeFilter')/]() { - public boolean select([include('org.eclipse.emf.ecore.EClass')/] instanciableType) { - return [eClassifier.metamodelStrictFilterGetter()/][addImport(eClassifier.ePackage.qualifiedMetamodelPackage())/] == instanciableType; - } - }); - [/for] - [/if] - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] policy = provider.getPolicy(context); - if (policy instanceof [include('org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy')/]) { - policy.execute(); - } - } - [/if] -} else if (event.getKind() == PropertiesEditionEvent.EDIT) { - [include('org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext')/] context = new EObjectPropertiesEditionContext(editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); - [include('org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider')/] provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); - if (provider != null) { - [include('org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy')/] editionPolicy = provider.getPolicy(context); - if (editionPolicy != null) { - editionPolicy.execute(); - } - } -} else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.removeFromReference((EObject) event.getNewValue()); -} else if (event.getKind() == PropertiesEditionEvent.MOVE) { - [editionElement.name.toJavaIdentifier()/]Settings.move(event.getNewIndex(), ([include(editionElement.peeModelQualifiedClass())/]) event.getNewValue()); -} -[/template] - -[template private genericFilterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent)] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].addFilterTo[editionElement.views->first().viewPackageSignature()/](new [include('org.eclipse.jface.viewers.ViewerFilter')/]() { - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select([include('org.eclipse.jface.viewers.Viewer')/] viewer, Object parentElement, Object element) { - return [if (editionElement.model.lowerBound = 0)](element instanceof String && element.equals("")) || [/if][editionElement.testOnTypes()/];[if (editionElement.model.lowerBound = 0)] //$NON-NLS-1$ [/if] - } - - }); -[for (filter : BindingFilter | editionElement.bindingFilters)] - [filter.filterBody(editionElement,view,pec)/] -[/for] -[if (not editionElement.element.eContainer(PropertiesEditionContext).associatedGenModel().useJMergeForUserCode)] - [additionalBusinessFilterProtectedArea(editionElement)/] -[/if] -} -[/template] - -[template private testOnTypes(editionElement : PropertiesEditionElement) post (trim())] -[if (editionElement.hasStrictTypingFilter())] -[editionElement.strictTypingFiltersTypes().testInstanceOfOnClassifier()->sep(' || ')/] -[else] -(element instanceof [include(editionElement.peeModelQualifiedClass())/]) -[/if] -[/template] - -[template private testInstanceOfOnClassifier(eClassifier : EClassifier) post (trim())] -(element instanceof [include(eClassifier.qualifiedName())/]) -[/template] - -[query private hasStrictTypingFilter(editingElement : PropertiesEditionElement) : Boolean = -editingElement.bindingFilters->filter(StrictTypingFilter)->notEmpty() -/] - -[query private strictTypingFiltersTypes(editingElement : PropertiesEditionElement) : Sequence(EClassifier) = -editingElement.bindingFilters->filter(StrictTypingFilter).type -/] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionFormImpl.mtl deleted file mode 100644 index a8da24b11..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionFormImpl.mtl +++ /dev/null @@ -1,320 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module tablecompositionFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = TableComposition ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'TableComposition')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.jface.viewers.ILabelProviderListener', - 'org.eclipse.jface.viewers.ITableLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.jface.viewers.ArrayContentProvider', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Listener', - 'org.eclipse.swt.graphics.Image', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.layout.GridLayout', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.widgets.Button', - 'org.eclipse.swt.widgets.TableColumn', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.jface.viewers.IStructuredSelection'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'TableComposition')] - protected [include('org.eclipse.jface.viewers.TableViewer')/] [editor.elementEditorName()/]; - protected [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> [editor.elementEditorName()/]BusinessFilters = new [include('java.util.ArrayList')/](); - protected List [editor.elementEditorName()/]Filters = new ArrayList(); - protected Button add[editor.name.toJavaClassifier()/]; - protected Button remove[editor.name.toJavaClassifier()/]; - protected Button edit[editor.name.toJavaClassifier()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'TableComposition')] -return create[editor.name.toJavaClassifier()/]TableComposition(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'TableComposition')] - /** - * @param container - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]TableComposition(FormToolkit widgetFactory, Composite container) { - Composite tableContainer = widgetFactory.createComposite(container, SWT.NONE); - GridLayout tableContainerLayout = new GridLayout(); - GridData tableContainerData = new GridData(GridData.FILL_BOTH); - tableContainerData.horizontalSpan = 3; - tableContainer.setLayoutData(tableContainerData); - tableContainerLayout.numColumns = 2; - tableContainer.setLayout(tableContainerLayout); - org.eclipse.swt.widgets.Table table[editor.name.toJavaClassifier()/] = widgetFactory.createTable(tableContainer, SWT.FULL_SELECTION | SWT.BORDER); - table[editor.name.toJavaClassifier()/].setHeaderVisible(true); - GridData gd[editor.name.toJavaClassifier()/] = new GridData(); - gd[editor.name.toJavaClassifier()/].grabExcessHorizontalSpace = true; - gd[editor.name.toJavaClassifier()/].horizontalAlignment = GridData.FILL; - gd[editor.name.toJavaClassifier()/].grabExcessVerticalSpace = true; - gd[editor.name.toJavaClassifier()/].verticalAlignment = GridData.FILL; - table[editor.name.toJavaClassifier()/].setLayoutData(gd[editor.name.toJavaClassifier()/]); - table[editor.name.toJavaClassifier()/].setLinesVisible(true); - - [if (editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - [editor.defaultColumnInitialisation()/] - [else] - // [protected ('for columns definition for '.concat(editor.name.toJavaClassifier()))] - [editor.defaultColumnInitialisation()/] - // [/protected] - [/if] - - [editor.elementEditorName()/] = new TableViewer(table[editor.name.toJavaClassifier()/]); - [editor.elementEditorName()/].setContentProvider(new ArrayContentProvider()); - [editor.elementEditorName()/].setLabelProvider(new ITableLabelProvider() { - [if (editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - [editor.defaultLabelProviderInitialisation()/] - [else] - //[protected ('for label provider definition for '.concat(editor.name.toJavaClassifier()))] - [editor.defaultLabelProviderInitialisation()/] - //[/protected] - [/if] - - public void addListener(ILabelProviderListener listener) { - } - - public void dispose() { - } - - public boolean isLabelProperty(Object element, String property) { - return false; - } - - public void removeListener(ILabelProviderListener listener) { - } - - }); - [editor.elementEditorName()/].getTable().addListener(SWT.MouseDoubleClick, new Listener(){ - - public void handleEvent([include('org.eclipse.swt.widgets.Event')/] event) { - if ([editor.elementEditorName()/].getSelection() instanceof IStructuredSelection) { - IStructuredSelection selection = (IStructuredSelection) [editor.elementEditorName()/].getSelection(); - if (selection.getFirstElement() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, selection.getFirstElement())); - [editor.elementEditorName()/].refresh(); - } - } - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.minimumHeight = 120; - [editor.elementEditorName()/]Data.heightHint = 120; - [editor.elementEditorName()/].getTable().setLayoutData([editor.elementEditorName()/]Data); - for (ViewerFilter filter : this.[editor.elementEditorName()/]Filters) { - [editor.elementEditorName()/].addFilter(filter); - } - EditingUtils.setID([editor.elementEditorName()/].getTable(), [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/].getTable(), "eef::[editor.representation.name/]::field"); //$NON-NLS-1$ - create[editor.name.toJavaClassifier()/]Panel(widgetFactory, tableContainer); - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('TableComposition'))] - - // [/protected] - return container; - } - - /** - * @param container - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]Panel(FormToolkit widgetFactory, Composite container) { - Composite [editor.elementEditorName()/]Panel = widgetFactory.createComposite(container, SWT.NONE); - GridLayout [editor.elementEditorName()/]PanelLayout = new GridLayout(); - [editor.elementEditorName()/]PanelLayout.numColumns = 1; - [editor.elementEditorName()/]Panel.setLayout([editor.elementEditorName()/]PanelLayout); - add[editor.name.toJavaClassifier()/] = widgetFactory.createButton([editor.elementEditorName()/]Panel, [editor.owningViewsRepository().messagesProvider()/].PropertiesEditionPart_AddTableViewerLabel, SWT.NONE); - GridData add[editor.name.toJavaClassifier()/]Data = new GridData(GridData.FILL_HORIZONTAL); - add[editor.name.toJavaClassifier()/].setLayoutData(add[editor.name.toJavaClassifier()/]Data); - add[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, null)); - [editor.elementEditorName()/].refresh(); - } - }); - EditingUtils.setID(add[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(add[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::addbutton"); //$NON-NLS-1$ - remove[editor.name.toJavaClassifier()/] = widgetFactory.createButton([editor.elementEditorName()/]Panel, [editor.owningViewsRepository().messagesProvider()/].PropertiesEditionPart_RemoveTableViewerLabel, SWT.NONE); - GridData remove[editor.name.toJavaClassifier()/]Data = new GridData(GridData.FILL_HORIZONTAL); - remove[editor.name.toJavaClassifier()/].setLayoutData(remove[editor.name.toJavaClassifier()/]Data); - remove[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - if ([editor.elementEditorName()/].getSelection() instanceof IStructuredSelection) { - IStructuredSelection selection = (IStructuredSelection) [editor.elementEditorName()/].getSelection(); - if (selection.getFirstElement() instanceof EObject) { - EObject selectedElement = (EObject) selection.getFirstElement(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.REMOVE, null, selectedElement)); - [editor.elementEditorName()/].refresh(); - } - } - } - - }); - EditingUtils.setID(remove[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(remove[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::removebutton"); //$NON-NLS-1$ - edit[editor.name.toJavaClassifier()/] = widgetFactory.createButton([editor.elementEditorName()/]Panel, [editor.owningViewsRepository().messagesProvider()/].PropertiesEditionPart_EditTableViewerLabel, SWT.NONE); - GridData edit[editor.name.toJavaClassifier()/]Data = new GridData(GridData.FILL_HORIZONTAL); - edit[editor.name.toJavaClassifier()/].setLayoutData(edit[editor.name.toJavaClassifier()/]Data); - edit[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - if ([editor.elementEditorName()/].getSelection() instanceof IStructuredSelection) { - IStructuredSelection selection = (IStructuredSelection) [editor.elementEditorName()/].getSelection(); - if (selection.getFirstElement() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, selection.getFirstElement())); - [editor.elementEditorName()/].refresh(); - } - } - } - - }); - EditingUtils.setID(edit[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(edit[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::editbutton"); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('Panel'))] - - // [/protected] - return [editor.elementEditorName()/]Panel; - } -[/template] - -[template private defaultLabelProviderInitialisation (editor : ElementEditor) ] - public String getColumnText(Object object, int columnIndex) { - AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory); - if (object instanceof EObject) { - switch (columnIndex) { - case 0: - return labelProvider.getText(object); - } - } - return ""; //$NON-NLS-1$ - } - - public Image getColumnImage(Object element, int columnIndex) { - return null; - } - -[/template] - -[template private defaultColumnInitialisation(editor : ElementEditor) ] - TableColumn name = new TableColumn(table[editor.name.toJavaClassifier()/], SWT.NONE); - name.setWidth(80); - name.setText("Label"); //$NON-NLS-1$ -[/template] - -[comment ===== Case Widget = AdvancedTableComposition ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'AdvancedTableComposition')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'AdvancedTableComposition')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable')/] [editor.elementEditorName()/]; - protected [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> [editor.elementEditorName()/]BusinessFilters = new [include('java.util.ArrayList')/](); - protected List [editor.elementEditorName()/]Filters = new ArrayList(); -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'TableComposition' or editor.representation.name = 'AdvancedTableComposition')] -return create[editor.name.toJavaClassifier()/]TableComposition(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'AdvancedTableComposition')] - /** - * @param container - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]TableComposition(FormToolkit widgetFactory, Composite parent) { - this.[editor.elementEditorName()/] = new ReferencesTable(getDescription([editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]), new ReferencesTableListener() { - public void handleAdd() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, null)); - [editor.elementEditorName()/].refresh(); - } - public void handleEdit(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, element)); - [editor.elementEditorName()/].refresh(); - } - public void handleMove(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - [editor.elementEditorName()/].refresh(); - } - public void handleRemove(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - [editor.elementEditorName()/].refresh(); - } - public void navigateTo(EObject element) { } - }); - for (ViewerFilter filter : this.[editor.elementEditorName()/]Filters) { - this.[editor.elementEditorName()/].addFilter(filter); - } - this.[editor.elementEditorName()/].setHelpText(propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - this.[editor.elementEditorName()/].createControls(parent, widgetFactory); - this.[editor.elementEditorName()/].addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 3; - this.[editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - this.[editor.elementEditorName()/].setLowerBound([editor.involvedPropertiesEditionElement(pec).model.lowerBound/]); - this.[editor.elementEditorName()/].setUpperBound([editor.involvedPropertiesEditionElement(pec).model.upperBound/]); - [editor.elementEditorName()/].setID([editor.editorID()/]); - [editor.elementEditorName()/].setEEFType("eef::[editor.representation.name/]"); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('TableComposition'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionGettersSetters.mtl deleted file mode 100644 index b5386670f..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionGettersSetters.mtl +++ /dev/null @@ -1,171 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module tablecompositionGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ====== Widgets View getters for declaration ====== /] -[template public getterDeclaration(elementEditor : ElementEditor) overrides getterDeclaration ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] -[/template] - -[template public getterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides getterImplementation ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] -[/template] - -[template public setterDeclaration(elementEditor : ElementEditor) overrides setterDeclaration ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] -[elementEditor.initSignatureDocumentation()/] -[elementEditor.initSignature()/]; - -[elementEditor.updateSignatureDocumentation()/] -[elementEditor.updateSignature()/]; - -[elementEditor.addFilterSignatureDocumentation()/] -[elementEditor.addFilterSignature()/]; - -[elementEditor.addBusinessFilterSignatureDocumentation()/] -[elementEditor.addBusinessFilterSignature()/]; - -[elementEditor.isContainedInTableSignatureDocumentation()/] -[elementEditor.isContainedInTableSignature()/]; -[/template] - -[template public getterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides getterImplementationDelegate ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] -[/template] - -[template public initSignature(elementEditor : ElementEditor) overrides initSignature ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] - public void init[elementEditor.viewPackageSignature()/]([include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings')/] settings) -[/template] - - -[template public initSignatureDocumentation(elementEditor : ElementEditor) overrides initSignatureDocumentation ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] - /** - * Init the [elementEditor.name/] - * @param current the current value - * @param containgFeature the feature where to navigate if necessary - * @param feature the feature to manage - */ -[/template] - -[template public setterImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides setterImplementation ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignatureImplementation()/] - -[updateSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.updateSignatureImplementation()/] - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignatureImplementation()/] - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignatureImplementation()/] - -[isContainedInTableSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.isContainedInTableSignatureImplementation()/] -[/template] - -[template public setterImplementationDelegate(elementEditor : ElementEditor, fullInterfacePath : String, referencedView : View) overrides setterImplementationDelegate ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] -[initSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.initSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.init[elementEditor.viewPackageSignature()/](settings); - } - -[updateSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.updateSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.update[elementEditor.viewPackageSignature()/](); - } - -[addFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[addBusinessFilterSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.addBusinessFilterSignature()/] { - [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.addBusinessFilterTo[elementEditor.viewPackageSignature()/](filter); - } - -[isContainedInTableSignatureDocumentationImplementation(elementEditor, fullInterfacePath)/] -[elementEditor.isContainedInTableSignature()/] { - return [referencedView.name.toJavaIdentifier()/]PropertiesEditionPart.isContainedIn[elementEditor.viewPackageSignature()/]Table(element); - } -[/template] - -[template public initSignatureDocumentationImplementation(elementEditor : ElementEditor, fullInterfacePath : String) overrides initSignatureDocumentationImplementation ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] - /** - * {@inheritDoc} - * - * @see [fullInterfacePath/]#init[elementEditor.viewPackageSignature()/](EObject current, EReference containingFeature, EReference feature) - */ -[/template] - -[template public initSignatureImplementation(elementEditor : ElementEditor) overrides initSignatureImplementation ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] -[elementEditor.initSignature()/] { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider')/] contentProvider = new [include('org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider')/](); - [elementEditor.elementEditorName()/].setContentProvider(contentProvider); - [elementEditor.elementEditorName()/].setInput(settings); - [elementEditor.readOnly()/] - } -[/template] - -[template public addFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] -[elementEditor.addFilterSignature()/] { - [elementEditor.elementEditorName()/]Filters.add(filter); - if (this.[elementEditor.elementEditorName()/] != null) { - this.[elementEditor.elementEditorName()/].addFilter(filter); - } - } -[/template] - -[template public addBusinessFilterSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] -[elementEditor.addBusinessFilterSignature()/] { - [elementEditor.elementEditorName()/]BusinessFilters.add(filter); - } -[/template] - -[template public isContainedInTableSignatureImplementation(elementEditor : ElementEditor) ? (elementEditor.representationName('TableComposition') or elementEditor.representationName('AdvancedTableComposition'))] -[elementEditor.isContainedInTableSignature()/] { - return ((ReferencesTableSettings)[elementEditor.elementEditorName()/].getInput()).contains(element); - } -[/template] - -[template public readOnly (editor : ElementEditor) overrides readOnly ? (editor.representation.name = 'TableComposition')] -[if (editor.readOnly)] -[setReadOnly()/] -[else] -boolean eefElementEditorReadOnlyState = isReadOnly([editor.editorID()/][navigationReadOnly()/]); -if (eefElementEditorReadOnlyState && [editor.name.toJavaIdentifier()/].getTable().isEnabled()) { - [editor.setReadOnly()/] -} else if (!eefElementEditorReadOnlyState && ![editor.name.toJavaIdentifier()/].getTable().isEnabled()) { - [editor.unsetReadOnly()/] -} -[/if] -[/template] - -[template public setReadOnly (editor : ElementEditor) overrides setReadOnly ? (editor.representation.name = 'TableComposition')] -[editor.name.toJavaIdentifier()/].getTable().setEnabled(false); -[editor.name.toJavaIdentifier()/].getTable().setToolTipText([editor.owningViewsRepository().messagesProvider()/].[editor.owningViewString()/]_ReadOnly); -[editor.setAddButtonReadOnly()/] -[editor.setRemoveButtonReadOnly()/] -[editor.setEditButtonReadOnly()/] -[/template] - -[template public unsetReadOnly (editor : ElementEditor) overrides unsetReadOnly ? (editor.representation.name = 'TableComposition')] -[editor.name.toJavaIdentifier()/].getTable().setEnabled(true); -[editor.unsetAddButtonReadOnly()/] -[editor.unsetRemoveButtonReadOnly()/] -[editor.unsetEditButtonReadOnly()/] -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionSWTImpl.mtl deleted file mode 100644 index 604449b67..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/tablecomposition/tablecompositionSWTImpl.mtl +++ /dev/null @@ -1,321 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module tablecompositionSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[comment ===== Case Widget = TableComposition ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'TableComposition')] -[pec.addImports(Sequence{ - 'org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider', - 'org.eclipse.jface.viewers.ArrayContentProvider', - 'org.eclipse.jface.viewers.ILabelProviderListener', - 'org.eclipse.jface.viewers.ITableLabelProvider', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Listener', - 'org.eclipse.swt.graphics.Image', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.layout.GridLayout', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.widgets.Button', - 'org.eclipse.swt.widgets.TableColumn', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.jface.viewers.IStructuredSelection'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'TableComposition')] - protected [include('org.eclipse.jface.viewers.TableViewer')/] [editor.elementEditorName()/]; - protected [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> [editor.elementEditorName()/]BusinessFilters = new [include('java.util.ArrayList')/](); - protected List [editor.elementEditorName()/]Filters = new ArrayList(); - protected Button add[editor.name.toJavaClassifier()/]; - protected Button remove[editor.name.toJavaClassifier()/]; - protected Button edit[editor.name.toJavaClassifier()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'TableComposition')] -return create[editor.name.toJavaClassifier()/]TableComposition(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'TableComposition')] - /** - * @param container - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]TableComposition(Composite container) { - Composite tableContainer = new Composite(container, SWT.NONE); - GridLayout tableContainerLayout = new GridLayout(); - GridData tableContainerData = new GridData(GridData.FILL_BOTH); - tableContainerData.horizontalSpan = 3; - tableContainer.setLayoutData(tableContainerData); - tableContainerLayout.numColumns = 2; - tableContainer.setLayout(tableContainerLayout); - org.eclipse.swt.widgets.Table table[editor.name.toJavaClassifier()/] = new org.eclipse.swt.widgets.Table(tableContainer, SWT.FULL_SELECTION); - table[editor.name.toJavaClassifier()/].setHeaderVisible(true); - GridData gd[editor.name.toJavaClassifier()/] = new GridData(); - gd[editor.name.toJavaClassifier()/].grabExcessHorizontalSpace = true; - gd[editor.name.toJavaClassifier()/].horizontalAlignment = GridData.FILL; - gd[editor.name.toJavaClassifier()/].grabExcessVerticalSpace = true; - gd[editor.name.toJavaClassifier()/].verticalAlignment = GridData.FILL; - table[editor.name.toJavaClassifier()/].setLayoutData(gd[editor.name.toJavaClassifier()/]); - table[editor.name.toJavaClassifier()/].setLinesVisible(true); - - [if (editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - [editor.defaultColumnInitialisation()/] - [else] - // [protected ('for columns definition for '.concat(editor.name.toJavaClassifier()))] - [editor.defaultColumnInitialisation()/] - // [/protected] - [/if] - - [editor.elementEditorName()/] = new TableViewer(table[editor.name.toJavaClassifier()/]); - [editor.elementEditorName()/].setContentProvider(new ArrayContentProvider()); - [editor.elementEditorName()/].setLabelProvider(new ITableLabelProvider() { - [if (editor.owningViewsRepository().associatedGenModel().useJMergeForUserCode)] - [editor.defaultLabelProviderInitialisation()/] - [else] - //[protected ('for label provider definition for '.concat(editor.name.toJavaClassifier()))] - [editor.defaultLabelProviderInitialisation()/] - //[/protected] - [/if] - - public void addListener(ILabelProviderListener listener) { - } - - public void dispose() { - } - - public boolean isLabelProperty(Object element, String property) { - return false; - } - - public void removeListener(ILabelProviderListener listener) { - } - - }); - [editor.elementEditorName()/].getTable().addListener(SWT.MouseDoubleClick, new Listener(){ - - public void handleEvent([include('org.eclipse.swt.widgets.Event')/] event) { - if ([editor.elementEditorName()/].getSelection() instanceof IStructuredSelection) { - IStructuredSelection selection = (IStructuredSelection) [editor.elementEditorName()/].getSelection(); - if (selection.getFirstElement() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, selection.getFirstElement())); - [editor.elementEditorName()/].refresh(); - } - } - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.minimumHeight = 120; - [editor.elementEditorName()/]Data.heightHint = 120; - [editor.elementEditorName()/].getTable().setLayoutData([editor.elementEditorName()/]Data); - for (ViewerFilter filter : this.[editor.elementEditorName()/]Filters) { - [editor.elementEditorName()/].addFilter(filter); - } - EditingUtils.setID([editor.elementEditorName()/].getTable(), [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/].getTable(), "eef::[editor.representation.name/]::field"); //$NON-NLS-1$ - create[editor.name.toJavaClassifier()/]Panel(tableContainer); - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('TableComposition'))] - - // [/protected] - return container; - } - - /** - * @param container - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]Panel(Composite container) { - Composite [editor.elementEditorName()/]Panel = new Composite(container, SWT.NONE); - GridLayout [editor.elementEditorName()/]PanelLayout = new GridLayout(); - [editor.elementEditorName()/]PanelLayout.numColumns = 1; - [editor.elementEditorName()/]Panel.setLayout([editor.elementEditorName()/]PanelLayout); - add[editor.name.toJavaClassifier()/] = new Button([editor.elementEditorName()/]Panel, SWT.NONE); - add[editor.name.toJavaClassifier()/].setText([editor.owningViewsRepository().messagesProvider()/].PropertiesEditionPart_AddTableViewerLabel); - GridData add[editor.name.toJavaClassifier()/]Data = new GridData(GridData.FILL_HORIZONTAL); - add[editor.name.toJavaClassifier()/].setLayoutData(add[editor.name.toJavaClassifier()/]Data); - add[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, null)); - [editor.elementEditorName()/].refresh(); - } - }); - EditingUtils.setID(add[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(add[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::addbutton"); //$NON-NLS-1$ - remove[editor.name.toJavaClassifier()/] = new Button([editor.elementEditorName()/]Panel, SWT.NONE); - remove[editor.name.toJavaClassifier()/].setText([editor.owningViewsRepository().messagesProvider()/].PropertiesEditionPart_RemoveTableViewerLabel); - GridData remove[editor.name.toJavaClassifier()/]Data = new GridData(GridData.FILL_HORIZONTAL); - remove[editor.name.toJavaClassifier()/].setLayoutData(remove[editor.name.toJavaClassifier()/]Data); - remove[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - if ([editor.elementEditorName()/].getSelection() instanceof IStructuredSelection) { - IStructuredSelection selection = (IStructuredSelection) [editor.elementEditorName()/].getSelection(); - if (selection.getFirstElement() instanceof EObject) { - EObject selectedElement = (EObject) selection.getFirstElement(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.REMOVE, null, selectedElement)); - [editor.elementEditorName()/].refresh(); - } - } - } - - }); - EditingUtils.setID(remove[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(remove[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::removebutton"); //$NON-NLS-1$ - edit[editor.name.toJavaClassifier()/] = new Button([editor.elementEditorName()/]Panel, SWT.NONE); - edit[editor.name.toJavaClassifier()/].setText([editor.owningViewsRepository().messagesProvider()/].PropertiesEditionPart_EditTableViewerLabel); - GridData edit[editor.name.toJavaClassifier()/]Data = new GridData(GridData.FILL_HORIZONTAL); - edit[editor.name.toJavaClassifier()/].setLayoutData(edit[editor.name.toJavaClassifier()/]Data); - edit[editor.name.toJavaClassifier()/].addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void widgetSelected(SelectionEvent e) { - if ([editor.elementEditorName()/].getSelection() instanceof IStructuredSelection) { - IStructuredSelection selection = (IStructuredSelection) [editor.elementEditorName()/].getSelection(); - if (selection.getFirstElement() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, selection.getFirstElement())); - [editor.elementEditorName()/].refresh(); - } - } - } - - }); - EditingUtils.setID(edit[editor.name.toJavaClassifier()/], [editor.editorID()/]); - EditingUtils.setEEFtype(edit[editor.name.toJavaClassifier()/], "eef::[editor.representation.name/]::editbutton"); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('Panel'))] - - // [/protected] - return [editor.elementEditorName()/]Panel; - } -[/template] - -[template private defaultLabelProviderInitialisation(editor : ElementEditor) ] - public String getColumnText(Object object, int columnIndex) { - AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory); - if (object instanceof EObject) { - switch (columnIndex) { - case 0: - return labelProvider.getText(object); - } - } - return ""; //$NON-NLS-1$ - } - - public Image getColumnImage(Object element, int columnIndex) { - return null; - } - -[/template] - -[template private defaultColumnInitialisation (editor : ElementEditor) ] - TableColumn name = new TableColumn(table[editor.name.toJavaClassifier()/], SWT.NONE); - name.setWidth(80); - name.setText("Label"); //$NON-NLS-1$ -[/template] - -[comment ===== Case Widget = AdvancedTableComposition ===== /] -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'AdvancedTableComposition')] -[pec.addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.events.SelectionEvent', - 'org.eclipse.swt.events.SelectionAdapter', - 'org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'AdvancedTableComposition')] - protected [include('org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable')/] [editor.elementEditorName()/]; - protected [include('java.util.List')/]<[include('org.eclipse.jface.viewers.ViewerFilter')/]> [editor.elementEditorName()/]BusinessFilters = new [include('java.util.ArrayList')/](); - protected List [editor.elementEditorName()/]Filters = new ArrayList(); -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'AdvancedTableComposition')] -return create[editor.name.toJavaClassifier()/]AdvancedTableComposition(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'AdvancedTableComposition')] - /** - * @param container - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - protected Composite create[editor.name.toJavaClassifier()/]AdvancedTableComposition(Composite parent) { - this.[editor.elementEditorName()/] = new ReferencesTable(getDescription([editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]), new ReferencesTableListener() { - public void handleAdd() { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, null)); - [editor.elementEditorName()/].refresh(); - } - public void handleEdit(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.EDIT, null, element)); - [editor.elementEditorName()/].refresh(); - } - public void handleMove(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - [editor.elementEditorName()/].refresh(); - } - public void handleRemove(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - [editor.elementEditorName()/].refresh(); - } - public void navigateTo(EObject element) { } - }); - for (ViewerFilter filter : this.[editor.elementEditorName()/]Filters) { - this.[editor.elementEditorName()/].addFilter(filter); - } - this.[editor.elementEditorName()/].setHelpText(propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - this.[editor.elementEditorName()/].createControls(parent); - this.[editor.elementEditorName()/].addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 3; - this.[editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - this.[editor.elementEditorName()/].setLowerBound([editor.involvedPropertiesEditionElement(pec).model.lowerBound/]); - this.[editor.elementEditorName()/].setUpperBound([editor.involvedPropertiesEditionElement(pec).model.upperBound/]); - [editor.elementEditorName()/].setID([editor.editorID()/]); - [editor.elementEditorName()/].setEEFType("eef::[editor.representation.name/]"); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('AdvancedTableComposition'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textControl.mtl deleted file mode 100644 index 8c3b1fad1..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textControl.mtl +++ /dev/null @@ -1,73 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module textControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case : model = Attribute(1) - view = Text ===== /] -[query public validCaseForDirectAttribute(editionElement : PropertiesEditionElement) : Boolean = editionElement.model.isAttributeSingle() and editionElement.representationName('Text') /] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.validCaseForDirectAttribute() and not editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.isPrimitiveType())] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].create[editionElement.model.eType.instanceClassName.toUpperFirst()/]FromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue())));[else] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([editionElement.model.eType.instanceClassName/])[include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].createFromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue()));[/if] -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Text'))] -if ([editionElement.liveUpdaterNavigationConditionForText(pec)/] && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])) { - if (msg.getNewValue() != null) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EcoreUtil.convertToString([editionElement.metamodelTypeGetter()/], msg.getNewValue())); - } else { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](""); - } -} -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Text') and not editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.isPrimitiveType())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EEFConverterUtil.convertToString([editionElement.metamodelTypeGetter()/], [pec.pecModelClass().toJavaIdentifier()/].[if isBoolean(editionElement.model.oclAsType(EAttribute))]is[else]get[/if][editionElement.model.name.toUpperFirst()/]())); -} -[else] -if (isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EEFConverterUtil.convertToString([editionElement.metamodelTypeGetter()/], [pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]())); -[/if] -[/template] - - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Text'))] -[comment no filters for text /] -[/template] - -[comment ===== Case : model = Attribute(1) - view = Text - ModelNavigation ===== /] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Text') and editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.isPrimitiveType())] -[editionElement.name.toJavaIdentifier()/]Settings.setValue(([include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].create[editionElement.model.eType.instanceClassName.toUpperFirst()/]FromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue())));[else] -[editionElement.name.toJavaIdentifier()/]Settings.setValue(([editionElement.model.eType.instanceClassName/])[include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].createFromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue()));[/if] -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Text') and editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.isPrimitiveType())] -if (isAccessible([editionElement.views->first().editorID()/])) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EEFConverterUtil.convertToString([editionElement.metamodelTypeGetter()/], [editionElement.name.toJavaIdentifier()/]Settings.getValue())); -} -[else] -if ([editionElement.name.toJavaIdentifier()/]Settings.getValue() != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EEFConverterUtil.convertToString([editionElement.metamodelTypeGetter()/], [editionElement.name.toJavaIdentifier()/]Settings.getValue())); -[/if] -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textFormImpl.mtl deleted file mode 100644 index 0c2033711..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textFormImpl.mtl +++ /dev/null @@ -1,115 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module textFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Text')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.swt.SWT', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.events.FocusAdapter', - 'org.eclipse.swt.events.FocusEvent', - 'org.eclipse.swt.events.KeyAdapter', - 'org.eclipse.swt.events.KeyEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representationName('Text'))] - protected [include('org.eclipse.swt.widgets.Text')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representationName('Text'))] -return create[editor.name.toJavaClassifier()/]Text(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representationName('Text'))] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]Text(FormToolkit widgetFactory, Composite parent) { - [if (editor.nameAsLabel)] - FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - [editor.elementEditorName()/].setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - [editor.editionPart()/].this, - [editor.editorID()/], - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - [editor.editionPart()/].this, - [editor.editorID()/], - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, [editor.elementEditorName()/].getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - [editor.editionPart()/].this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - [editor.elementEditorName()/].addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - } - }); - EditingUtils.setID([editor.elementEditorName()/], [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/], "eef::[editor.representation.name/]"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('Text'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textGettersSetters.mtl deleted file mode 100644 index d4d40f7f9..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textGettersSetters.mtl +++ /dev/null @@ -1,35 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module textGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('Text'))] -[elementEditor.getterSignature()/] { - return [elementEditor.elementEditorName()/].getText(); - } -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('Text'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].setText(newValue); - } else { - [elementEditor.elementEditorName()/].setText(""); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textSWTImpl.mtl deleted file mode 100644 index b0110892d..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/text/textSWTImpl.mtl +++ /dev/null @@ -1,95 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module textSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Text')] -[pec.addImports(Sequence{ - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.swt.SWT', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.events.FocusAdapter', - 'org.eclipse.swt.events.FocusEvent', - 'org.eclipse.swt.events.KeyAdapter', - 'org.eclipse.swt.events.KeyEvent', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representationName('Text'))] - protected [include('org.eclipse.swt.widgets.Text')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representationName('Text'))] -return create[editor.name.toJavaClassifier()/]Text(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representationName('Text'))] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]Text(Composite parent) { - [if (editor.nameAsLabel)] - SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - createDescription(parent, [editor.editorID()/], [editor.owningViewsRepository().messagesProvider()/].[editor.editorKey(editor.owningView())/]); - [/if] - [editor.elementEditorName()/] = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - - }); - [editor.elementEditorName()/].addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - } - - }); - EditingUtils.setID([editor.elementEditorName()/], [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/], "eef::[editor.representation.name/]"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('Text'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaControl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaControl.mtl deleted file mode 100644 index 4ff75c185..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaControl.mtl +++ /dev/null @@ -1,59 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2010 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module textareaControl('http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/2002/GenModel', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/mapping/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetControl/] - -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::typeUtils /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[comment ===== Case : model = Attribute(1) - view = Textarea ===== /] -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Textarea') and not editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.isPrimitiveType())] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].create[editionElement.model.eType.instanceClassName.toUpperFirst()/]FromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue())));[else] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([editionElement.model.eType.instanceClassName/])[include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].createFromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue()));[/if] -[/template] - -[template public liveUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides liveUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Textarea'))] -if ([editionElement.liveUpdaterNavigationConditionForText(pec)/] && [view.viewIdentifier(pec)/] != null && isAccessible([editionElement.views->first().editorID()/])){ - if (msg.getNewValue() != null) { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EcoreUtil.convertToString([editionElement.metamodelTypeGetter()/], msg.getNewValue())); - } else { - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](""); - } -} -[/template] - - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Textarea') and not editionElement.canGeneratemodelNavigation())] -if (isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EcoreUtil.convertToString([editionElement.metamodelTypeGetter()/], [pec.pecModelClass().toJavaIdentifier()/].get[editionElement.model.name.toUpperFirst()/]())); -[/template] - -[template public filterUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides filterUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Textarea'))] -[comment no filters for textarea /] -[/template] - -[comment ===== Case : model = Attribute(1) - view = Textarea - ModelNavigation ===== /] - -[template public declareEObjectUpdater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides declareEObjectUpdater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Textarea') and editionElement.canGeneratemodelNavigation())] -[if (editionElement.model.isPrimitiveType())] -[pec.pecModelClass().toJavaIdentifier().disambiguation('event')/].set[editionElement.model.name.toUpperFirst()/](([include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].create[editionElement.model.eType.instanceClassName.toUpperFirst()/]FromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue())));[else] -[editionElement.name.toJavaIdentifier()/]Settings.setValue(([editionElement.model.eType.instanceClassName/])[include('org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil')/].createFromString([editionElement.metamodelTypeGetter()/], (String)event.getNewValue()));[/if] -[/template] - -[template public updater(editionElement : PropertiesEditionElement, view : View, pec : PropertiesEditionComponent) overrides updater ? (editionElement.model.isAttributeSingle() and editionElement.representationName('Textarea') and editionElement.canGeneratemodelNavigation())] -if ([editionElement.name.toJavaIdentifier()/]Settings.getValue() != null && isAccessible([editionElement.views->first().editorID()/])) - [view.viewIdentifier(pec)/].[editionElement.views->first().viewPackageSetter()/](EcoreUtil.convertToString([editionElement.metamodelTypeGetter()/], [editionElement.name.toJavaIdentifier()/]Settings.getValue())); -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaFormImpl.mtl deleted file mode 100644 index 4673911b5..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaFormImpl.mtl +++ /dev/null @@ -1,105 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module textareaFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Textarea')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.events.FocusAdapter', - 'org.eclipse.swt.events.FocusEvent', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.emf.eef.runtime.ui.widgets.FormUtils', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.swt.widgets.Label', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'Textarea')] - protected [include('org.eclipse.swt.widgets.Text')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'Textarea')] -return create[editor.name.toJavaClassifier()/]Textarea(widgetFactory, parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'Textarea')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]Textarea(FormToolkit widgetFactory, Composite parent) { - [if (editor.nameAsLabel)] - Label [editor.elementEditorName()/]Label = FormUtils.createPartLabel(widgetFactory, parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND)); - [else] - Label [editor.elementEditorName()/]Label = createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - GridData [editor.elementEditorName()/]LabelData = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]LabelData.horizontalSpan = 3; - [editor.elementEditorName()/]Label.setLayoutData([editor.elementEditorName()/]LabelData); - [editor.elementEditorName()/] = widgetFactory.createText(parent, "", SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); //$NON-NLS-1$ - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 2; - [editor.elementEditorName()/]Data.heightHint = 80; - [editor.elementEditorName()/]Data.widthHint = 200; - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - [editor.editionPart()/].this, - [editor.editorID()/], - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - [editor.editionPart()/].this, - [editor.editorID()/], - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, [editor.elementEditorName()/].getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - [editor.editionPart()/].this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - EditingUtils.setID([editor.elementEditorName()/], [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/], "eef::[editor.representation.name/]"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].FORM_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('TextArea'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaGettersSetters.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaGettersSetters.mtl deleted file mode 100644 index d71f00e46..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaGettersSetters.mtl +++ /dev/null @@ -1,44 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module textareaGettersSetters('http://www.eclipse.org/emf/eef/views/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::widgets::api::widgetGettersSetters /] - -[template public getterSignatureImplementation(elementEditor : ElementEditor) overrides getterSignatureImplementation ? (elementEditor.representationName('Textarea'))] -[elementEditor.getterSignature()/] { - return [elementEditor.elementEditorName()/].getText(); - } -[/template] - -[template public setterSignatureImplementation(elementEditor : ElementEditor) overrides setterSignatureImplementation ? (elementEditor.representationName('Textarea'))] -[elementEditor.setterSignature()/] { - if (newValue != null) { - [elementEditor.elementEditorName()/].setText(newValue); - } else { - [elementEditor.elementEditorName()/].setText(""); //$NON-NLS-1$ - } - [elementEditor.readOnly()/] - } -[/template] - -[template public setReadOnly (editor : ElementEditor) overrides setReadOnly ? (editor.representation.name = 'Textarea')] -[editor.elementEditorName()/].setEnabled(false); -[editor.elementEditorName()/].setBackground([editor.elementEditorName()/].getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); -[editor.elementEditorName()/].setToolTipText([editor.owningViewsRepository().messagesProvider()/].[editor.owningViewString()/]_ReadOnly); -[/template] - -[template public unsetReadOnly (editor : ElementEditor) overrides setReadOnly ? (editor.representation.name = 'Textarea')] -[editor.elementEditorName()/].setEnabled(true); -[/template] \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaSWTImpl.mtl deleted file mode 100644 index eed09b9ea..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/textarea/textareaSWTImpl.mtl +++ /dev/null @@ -1,80 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module textareaSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports /] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'Textarea')] -[pec.addImports(Sequence{ - 'org.eclipse.swt.events.FocusAdapter', - 'org.eclipse.swt.events.FocusEvent', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils', - 'org.eclipse.emf.eef.runtime.ui.utils.EditingUtils', - 'org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent', - 'org.eclipse.swt.widgets.Label', - 'org.eclipse.swt.layout.GridData'})/] -[/template] - -[template public widgetDeclaration(editor : ElementEditor) overrides widgetDeclaration ? (editor.representation.name = 'Textarea')] - protected [include('org.eclipse.swt.widgets.Text')/] [editor.elementEditorName()/]; -[/template] - -[template public implementation(editor : ElementEditor) overrides implementation ? (editor.representation.name = 'Textarea')] -return create[editor.name.toJavaClassifier()/]Textarea(parent); -[/template] - -[template public additionalImplementation(editor : ElementEditor, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (editor.representation.name = 'Textarea')] - [editor.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[editor.name.toJavaClassifier()/]Textarea(Composite parent) { - [if (editor.nameAsLabel)] - Label [editor.elementEditorName()/]Label = SWTUtils.createPartLabel(parent, [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/], propertiesEditionComponent.isRequired([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND)); - [else] - Label [editor.elementEditorName()/]Label = createDescription(parent, [editor.editorID()/], [include(editor.owningViewsRepository().qualifiedMessagesProvider())/].[editor.editorKey(editor.owningView())/]); - [/if] - GridData [editor.elementEditorName()/]LabelData = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]LabelData.horizontalSpan = 3; - [editor.elementEditorName()/]Label.setLayoutData([editor.elementEditorName()/]LabelData); - [editor.elementEditorName()/] = SWTUtils.createScrollableText(parent, SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); - GridData [editor.elementEditorName()/]Data = new GridData(GridData.FILL_HORIZONTAL); - [editor.elementEditorName()/]Data.horizontalSpan = 2; - [editor.elementEditorName()/]Data.heightHint = 80; - [editor.elementEditorName()/]Data.widthHint = 200; - [editor.elementEditorName()/].setLayoutData([editor.elementEditorName()/]Data); - [editor.elementEditorName()/].addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * [editor.owningViewsRepository().associatedGenModel().generationMark()/] - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent([editor.editionPart()/].this, [editor.editorID()/], PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, [editor.elementEditorName()/].getText())); - } - - }); - EditingUtils.setID([editor.elementEditorName()/], [editor.editorID()/]); - EditingUtils.setEEFtype([editor.elementEditorName()/], "eef::[editor.representation.name/]"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent([editor.editorID()/], [editor.owningViewsRepository().vrClass()/].SWT_KIND), null); //$NON-NLS-1$ - // [protected ('for create'.concat(editor.name.toJavaClassifier()).concat('TextArea'))] - - // [/protected] - return parent; - } -[/template] diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/vbox/vboxFormImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/vbox/vboxFormImpl.mtl deleted file mode 100644 index 159adf0d2..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/vbox/vboxFormImpl.mtl +++ /dev/null @@ -1,45 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module vboxFormImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetFormImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'VerticalBox')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.layout.GridLayout', - 'org.eclipse.emf.eef.runtime.ui.widgets.VerticalBox'})/] -[/template] - -[template public implementation(container : Container) overrides implementation ? (container.representation.name = 'VerticalBox')] -return create[container.name.toJavaClassifier()/]VBox(widgetFactory, parent); -[/template] - -[template public additionalImplementation(container : Container, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (container.representation.name = 'VerticalBox')] - [container.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[container.name.toJavaClassifier()/]VBox(FormToolkit widgetFactory, Composite parent) { - Composite container = widgetFactory.createComposite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - container.setLayout(layout); - container.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true)); - VerticalBox [container.name.toJavaIdentifier()/]VBox = new VerticalBox(container); - return [container.name.toJavaIdentifier()/]VBox; - } -[/template] - diff --git a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/vbox/vboxSWTImpl.mtl b/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/vbox/vboxSWTImpl.mtl deleted file mode 100644 index 70d11c995..000000000 --- a/plugins/org.eclipse.emf.eef.codegen/src/org/eclipse/emf/eef/codegen/widgets/impl/vbox/vboxSWTImpl.mtl +++ /dev/null @@ -1,44 +0,0 @@ -[comment encoding = UTF-8 - ******************************************************************************* - * Copyright (c) 2008-2009 Obeo. - * 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: - * Obeo - initial API and implementation - ******************************************************************************* - /] -[module vboxSWTImpl('http://www.eclipse.org/emf/eef/views/1.0.0', 'http://www.eclipse.org/emf/eef/components/1.0.0', 'http://www.eclipse.org/emf/2002/Ecore', 'http://www.eclipse.org/emf/eef/generation/1.0.0') extends org::eclipse::emf::eef::codegen::widgets::api::widgetSWTImpl/] - -[import org::eclipse::emf::eef::codegen::services::common /] -[import org::eclipse::emf::eef::codegen::services::naming /] -[import org::eclipse::emf::eef::codegen::services::viewCommon /] -[import org::eclipse::emf::eef::codegen::services::imports/] - -[template public manageImports(widget : Widget, pec : PropertiesEditionComponent, view : View, basePackage : String) overrides manageImports ? (widget.name = 'VerticalBox')] -[pec.addImports(Sequence{ - 'org.eclipse.ui.forms.widgets.FormToolkit', - 'org.eclipse.swt.widgets.Composite', - 'org.eclipse.swt.SWT', - 'org.eclipse.swt.layout.GridData', - 'org.eclipse.swt.layout.GridLayout', - 'org.eclipse.emf.eef.runtime.ui.widgets.VerticalBox'})/] -[/template] - -[template public implementation(container : Container) overrides implementation ? (container.representation.name = 'VerticalBox')] -return create[container.name.toJavaClassifier()/]VBox(parent); -[/template] - -[template public additionalImplementation(container : Container, pec : PropertiesEditionComponent, inputPEC: PropertiesEditionComponent) overrides additionalImplementation ? (container.representation.name = 'VerticalBox')] - [container.owningViewsRepository().associatedGenModel().generationComment()/] - protected Composite create[container.name.toJavaClassifier()/]VBox(Composite parent) { - Composite container = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - container.setLayout(layout); - VerticalBox [container.name.toJavaIdentifier()/]VBox = new VerticalBox(container); - return [container.name.toJavaIdentifier()/]VBox; - } -[/template] - diff --git a/plugins/org.eclipse.emf.eef.components.edit/.checkstyle b/plugins/org.eclipse.emf.eef.components.edit/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components.edit/.classpath b/plugins/org.eclipse.emf.eef.components.edit/.classpath deleted file mode 100644 index 756f42890..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/.classpath +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components.edit/.gitignore b/plugins/org.eclipse.emf.eef.components.edit/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.components.edit/.project b/plugins/org.eclipse.emf.eef.components.edit/.project deleted file mode 100644 index 1fc68e489..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.components.edit - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.components.edit/.settings/org.eclipse.jdt.ui.prefs b/plugins/org.eclipse.emf.eef.components.edit/.settings/org.eclipse.jdt.ui.prefs deleted file mode 100644 index b23523422..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/.settings/org.eclipse.jdt.ui.prefs +++ /dev/null @@ -1,4 +0,0 @@ -#Mon May 25 14:42:41 CEST 2009 -eclipse.preferences.version=1 -formatter_settings_version=11 -org.eclipse.jdt.ui.text.custom_code_templates= diff --git a/plugins/org.eclipse.emf.eef.components.edit/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.components.edit/META-INF/MANIFEST.MF deleted file mode 100644 index f3a837ac3..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/META-INF/MANIFEST.MF +++ /dev/null @@ -1,28 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Components Edit Support -Bundle-SymbolicName: org.eclipse.emf.eef.components.edit;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Activator: org.eclipse.emf.eef.components.provider.ComponentsEditPlugin$Implementation -Bundle-Vendor: Eclipse Modeling Project -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.components.parts, - org.eclipse.emf.eef.components.provider, - org.eclipse.emf.eef.components.resources, - org.eclipse.emf.eef.mapping.provider -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.emf.validation;bundle-version="1.2.0", - org.eclipse.emf.edit;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.ecore;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.ecore.xmi;bundle-version="2.4.0", - org.eclipse.emf.ecore.edit;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.codegen.ecore.ui;bundle-version="2.4.0", - org.eclipse.emf.eef.mapping;visibility:=reexport, - org.eclipse.emf.eef.mapping.edit;visibility:=reexport, - org.eclipse.emf.eef.views;visibility:=reexport, - org.eclipse.emf.eef.views.edit;visibility:=reexport, - org.eclipse.emf.eef.runtime;visibility:=reexport, - org.eclipse.emf.eef.components;visibility:=reexport -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.components.edit/about.html b/plugins/org.eclipse.emf.eef.components.edit/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.components.edit/build.properties b/plugins/org.eclipse.emf.eef.components.edit/build.properties deleted file mode 100644 index 797abb889..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/build.properties +++ /dev/null @@ -1,23 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -bin.includes = .,\ - icons/,\ - META-INF/,\ - plugin.xml,\ - plugin.properties,\ - about.html,\ - model/ -jars.compile.order = . -source.. = src-gen/,\ - src/ -output.. = bin/ -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateAbstractElementBinding_properties_PropertiesEditionElement.gif b/plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateAbstractElementBinding_properties_PropertiesEditionElement.gif deleted file mode 100644 index 813b6e10c89906bd5f847d4e2c46607b6c2f0350..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6yx6nnW>3$Vw6p^b4*&nh&yTnNf8V~L zp`mHbwcws(mc?syBHMONR|BH0la$wW$uDh^npY_{vqbpc-}gZD_w#um`tyA8@4L-F z(;z_cCkrEpr2`^Bb~3QWC@A!$MB1q_%shK|%7v|y`kVVEm3SI|HtD&RJxNncyYLM_VN?#B7ItOPMvhKV$e~$@9knC5Y#aHMZ$+gC)=48Cb-GpXsNlKt9ANidOkx= OO;c)PQ?{xigEasM2Vk=R diff --git a/plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateAbstractElementBinding_properties_PropertiesMultiEditionElement.gif b/plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateAbstractElementBinding_properties_PropertiesMultiEditionElement.gif deleted file mode 100644 index eeca32a9bec88cf255731c63f1f5fb7dc8f774ea..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6Tzau*)6JflXVMxDIQ;(~KR@37|9$(0 zhK8m!*MfVFSr)I+iEP_7T@8q~PEuaiCBL*uYF?$-%o5>$f8PVq-_PfP=+E=Tzwb5! zO@jc%pDc_ZmJWyj*~!2fqoB~25^1N#F!Su;DHpa*>Tm9wRN`s;*`()M_9RU)^?s@3 zOy@w2*~?F`i}Y#DId#&_ia|&1zPF2oKv2W%7YQF0oor`XnBXRVqow9{uGZ<7>G=#f OHBG6FP1&l74AuaO9${ht diff --git a/plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateAbstractElementBinding_subElements_PropertiesEditionComponent.gif b/plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateAbstractElementBinding_subElements_PropertiesEditionComponent.gif deleted file mode 100644 index 527229bf76f3c5e234979f14046d7f1df5771dff..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6T)WnE>{#%cHI{8{I{*L2&yTnNf8V~L zp`mHbwcws(mc?syBHMONR|BH0la$wW$uDh^npY_{vqbpc-}gZD_w#um`tyA8@4L-F z(;z_cCkrEpr2`^Bb~3QWC@A!$MB1q_%shK|%7v|y`kVVEm3SI|HtD&RJxNncyYLM_VN?#B7ItOPMvhKV$e~$@9knC5Y#aHMZ$+gC)=48Cb-GpXsNlKt9ANidOkx= OO;c)PQ?{xigEaui_F!ND diff --git a/plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateCategory_bindings_PropertiesEditionComponent.gif b/plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateCategory_bindings_PropertiesEditionComponent.gif deleted file mode 100644 index 7efb4a9bea1fe15fe621b115d0cca60c4fdfcd39..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6T)WnE>{#%cHI{8{I{*L2&yTnNf8V~L zq2c$}-*1k-xj+B@rOHdYrmF$b)=A3iy5yHONzJPin^_|K@9%pc`uq7j5dC?+`1jpr zplJ}G_>+YZ#L@u~AUhdYV-ytnQX=it7-pV5JmtdHN&U@zlS({|Kb!Pi%buhurrs}= zoar2>F?;z5c9A}8}5D03R{UYJRqLb}R3lrSrZ?x3h&eb~oGCiLm Pr=}^ju_;?sk--`OWldyO diff --git a/plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateDatabinding_bindings_PropertiesEditionComponent.gif b/plugins/org.eclipse.emf.eef.components.edit/icons/full/ctool16/CreateDatabinding_bindings_PropertiesEditionComponent.gif deleted file mode 100644 index 7efb4a9bea1fe15fe621b115d0cca60c4fdfcd39..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6T)WnE>{#%cHI{8{I{*L2&yTnNf8V~L zq2c$}-*1k-xj+B@rOHdYrmF$b)=A3iy5yHONzJPin^_|K@9%pc`uq7j5dC?+`1jpr zplJ}G_>+YZ#L@u~AUhdYV-ytnQX=it7-pV5JmtdHN&U@zlS({|Kb!Pi%buhurrs}= zoar2>F?;z5c9A}8}5D03R{UYJRqLb}R3lrSrZ?x3h&eb~oGCiLm Pr=}^ju_;?sk--`OWldyO diff --git a/plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/EEFElement.gif b/plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/EEFElement.gif deleted file mode 100644 index c4fb30e96873d2484faec9d508dcbdd69e73d82e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 129 zcmZ?wbhEHb6krfw*vtS14M4Jip`qcxfddT<4GjN*-2XuK|Nmgte-L}loH;;I&}kR~x;L)6}k-mG`XF Sa~8g>rXuRbnfxzs5xg=T>fzA-lzO+k4kqvt=ady%4>FiZ2r>|c#dDV*PTQ*GC zxv6K%`u_dfI`(Yo+PSIs|Ns9CGy{r1Sr{1@5*c(rHh|)Uf&ENFVpDTVYmgi*E-sqAzi{@xvIU2$79W|s_0r-UCztLzt&%pYd-cA}$Ii`OIDh5J zY5TWzJUG#RWmCqLO_{g$)?D3`dHM3?OP4NPxNzazxpP~$Ze72A{p!`LSFKvLa^=bu zD^@I9w(S4^{|saS#h)yU3=FyqIw0L3KQXYi9hg?&p~Gi+f?x1xh@fR7gNBJqr_1sw z0>ukitQ7pUnKyR$s6Tgp$e_Y8`&x>kWUot*7n_r|YQL(s z6VsHbPC7GYy3Ka=(P(p;w?H>6B5GlHq*F>-hTod>%%YOAip{0vQIbt9D(m;O_D-01 RXu>4jnX^uu)Ny361_1i>mpK3c diff --git a/plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/PropertiesEditionElement.gif b/plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/PropertiesEditionElement.gif deleted file mode 100644 index 15805af54c525f62d6e0e848bfe23b79349e42e9..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 318 zcmZ?wbhEHb6krfwxXQqw=hgc5)6ch`et1`J^sd=>|K*qG@4k7}Z1k$x;8VZZyJmxb z)3(MXCmWZXxb*PDji;aPzx@2{-M4_Y9f55-gFE*GckK@C*%#Wg_tL}nH=cgH|LRLv z-~P@Gmo7befBoslx1WF9c=qxC|Njg$1ByRc7#SE88FWB4fc(V37JXnsfrkzkTCW)B-O@25SJl8gH}! diff --git a/plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/PropertiesMultiEditionElement.gif b/plugins/org.eclipse.emf.eef.components.edit/icons/full/obj16/PropertiesMultiEditionElement.gif deleted file mode 100644 index e4bc22dd17e82d9350631bd55ad9671957cdaf50..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 129 zcmZ?wbhEHb6krfw*vtS14M4Jip`qcxfddT<4GjN*-2XuK|Nmgt|Noa>?Adg)XXcr- zh64_YKUo+V7&sYpKsrHYFtF$uob+71*W&e;Zz}u`3thLHvffHb@LI6&tBu~rX=+!^ W%6nF7^6M^V>~uRaQAn7P!5RPwrZD0F diff --git a/plugins/org.eclipse.emf.eef.components.edit/model/components.components b/plugins/org.eclipse.emf.eef.components.edit/model/components.components deleted file mode 100755 index 64752eff2..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/model/components.components +++ /dev/null @@ -1,155 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - SWT - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components.edit/model/components.eefgen b/plugins/org.eclipse.emf.eef.components.edit/model/components.eefgen deleted file mode 100755 index 60ad7040f..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/model/components.eefgen +++ /dev/null @@ -1,15 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components.edit/plugin.properties b/plugins/org.eclipse.emf.eef.components.edit/plugin.properties deleted file mode 100644 index 6ffd22886..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/plugin.properties +++ /dev/null @@ -1,38 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -_UI_CreateChild_text = {0} -_UI_CreateChild_text2 = {1} {0} -_UI_CreateChild_text3 = {1} -_UI_CreateChild_tooltip = Create New {0} Under {1} Feature -_UI_CreateChild_description = Create a new child of type {0} for the {1} feature of the selected {2}. -_UI_CreateSibling_description = Create a new sibling of type {0} for the selected {2}, under the {1} feature of their parent. - -_UI_PropertyDescriptor_description = The {0} of the {1} - -_UI_PropertiesEditionContext_type = Properties Edition Context -_UI_PropertiesEditionComponent_type = Properties Edition Component -_UI_PropertiesEditionElement_type = Properties Edition Element -_UI_Unknown_type = Object - -_UI_Unknown_datatype= Value - -_UI_PropertiesEditionContext_model_feature = Model -_UI_PropertiesEditionComponent_explicite_feature = Explicite -_UI_Unknown_feature = Unspecified - -_UI_PropertiesMultiEditionElement_type = Properties Multi Edition Element -_UI_PropertiesEditionComponent_explicit_feature = Explicit -_UI_EEFElement_type = EEF Element -_UI_EEFElement_helpID_feature = Help ID -_UI_PropertiesEditionContext_model_description = The GenPackage for this edition context -_UI_PropertiesEditionComponent_explicit_description = Whether the component can be directly used -_UI_EEFElement_helpID_description = The ID of the dynamic help associated to this element diff --git a/plugins/org.eclipse.emf.eef.components.edit/plugin.xml b/plugins/org.eclipse.emf.eef.components.edit/plugin.xml deleted file mode 100644 index d2d76b739..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/plugin.xml +++ /dev/null @@ -1,173 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - All element editor referenced in a properties edition element must be child of views mapped by the properties edition component ... - - - The element editor {0} is not a child of the views mapped by the properties edition element {1}. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components.edit/pom.xml b/plugins/org.eclipse.emf.eef.components.edit/pom.xml deleted file mode 100644 index 42b47688c..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/pom.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.components.edit - eclipse-plugin - - EEF Components Edit Plug-in - diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/components_properties.plugin.xml b/plugins/org.eclipse.emf.eef.components.edit/src-gen/components_properties.plugin.xml deleted file mode 100644 index c498ccdc8..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/components_properties.plugin.xml +++ /dev/null @@ -1,110 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionComponentBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionComponentBasePropertiesEditionComponent.java deleted file mode 100644 index 5d6ab68bf..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionComponentBasePropertiesEditionComponent.java +++ /dev/null @@ -1,354 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.components; - -// Start of user code for imports - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionComponentBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for views ReferencesTable - */ - private ReferencesTableSettings viewsSettings; - - /** - * Settings for model EObjectFlatComboViewer - */ - private EObjectFlatComboSettings modelSettings; - - - /** - * Default constructor - * - */ - public PropertiesEditionComponentBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject propertiesEditionComponent, String editing_mode) { - super(editingContext, propertiesEditionComponent, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = ComponentsViewsRepository.class; - partKey = ComponentsViewsRepository.PropertiesEditionComponent.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final PropertiesEditionComponent propertiesEditionComponent = (PropertiesEditionComponent)elt; - final PropertiesEditionComponentPropertiesEditionPart basePart = (PropertiesEditionComponentPropertiesEditionPart)editingPart; - // init values - if (isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Properties.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, propertiesEditionComponent.getName())); - - if (isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views)) { - viewsSettings = new ReferencesTableSettings(propertiesEditionComponent, MappingPackage.eINSTANCE.getAbstractElementBinding_Views()); - basePart.initViews(viewsSettings); - } - if (isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model)) { - // init part - modelSettings = new EObjectFlatComboSettings(propertiesEditionComponent, MappingPackage.eINSTANCE.getEMFElementBinding_Model()); - basePart.initModel(modelSettings); - // set the button mode - basePart.setModelButtonMode(ButtonsModeEnum.BROWSE); - } - if (isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID)) - basePart.setHelpID(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, propertiesEditionComponent.getHelpID())); - - if (isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit)) { - basePart.setExplicit(propertiesEditionComponent.isExplicit()); - } - // init filters - - if (isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views)) { - basePart.addFilterToViews(new EObjectFilter(ViewsPackage.Literals.VIEW)); - // Start of user code for additional businessfilters for views - - // End of user code - } - if (isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model)) { - basePart.addFilterToModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EClassifier); - } - - }); - // Start of user code for additional businessfilters for model - - // End of user code - } - - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == ComponentsViewsRepository.PropertiesEditionComponent.Properties.name) { - return MappingPackage.eINSTANCE.getAbstractElementBinding_Name(); - } - if (editorKey == ComponentsViewsRepository.PropertiesEditionComponent.Binding.views) { - return MappingPackage.eINSTANCE.getAbstractElementBinding_Views(); - } - if (editorKey == ComponentsViewsRepository.PropertiesEditionComponent.Binding.model) { - return MappingPackage.eINSTANCE.getEMFElementBinding_Model(); - } - if (editorKey == ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID) { - return ComponentsPackage.eINSTANCE.getEEFElement_HelpID(); - } - if (editorKey == ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit) { - return ComponentsPackage.eINSTANCE.getPropertiesEditionComponent_Explicit(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - PropertiesEditionComponent propertiesEditionComponent = (PropertiesEditionComponent)semanticObject; - if (ComponentsViewsRepository.PropertiesEditionComponent.Properties.name == event.getAffectedEditor()) { - propertiesEditionComponent.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (ComponentsViewsRepository.PropertiesEditionComponent.Binding.views == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof View) { - viewsSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - viewsSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - viewsSettings.move(event.getNewIndex(), (View) event.getNewValue()); - } - } - if (ComponentsViewsRepository.PropertiesEditionComponent.Binding.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - modelSettings.setToReference((EClassifier)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, modelSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - if (ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID == event.getAffectedEditor()) { - propertiesEditionComponent.setHelpID((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit == event.getAffectedEditor()) { - propertiesEditionComponent.setExplicit((Boolean)event.getNewValue()); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - PropertiesEditionComponentPropertiesEditionPart basePart = (PropertiesEditionComponentPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getAbstractElementBinding_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Properties.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (MappingPackage.eINSTANCE.getAbstractElementBinding_Views().equals(msg.getFeature()) && isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views)) - basePart.updateViews(); - if (MappingPackage.eINSTANCE.getEMFElementBinding_Model().equals(msg.getFeature()) && basePart != null && isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model)) - basePart.setModel((EObject)msg.getNewValue()); - if (ComponentsPackage.eINSTANCE.getEEFElement_HelpID().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID)) { - if (msg.getNewValue() != null) { - basePart.setHelpID(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setHelpID(""); - } - } - if (ComponentsPackage.eINSTANCE.getPropertiesEditionComponent_Explicit().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit)) - basePart.setExplicit((Boolean)msg.getNewValue()); - - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getAbstractElementBinding_Name(), - MappingPackage.eINSTANCE.getAbstractElementBinding_Views(), - MappingPackage.eINSTANCE.getEMFElementBinding_Model(), - ComponentsPackage.eINSTANCE.getEEFElement_HelpID(), - ComponentsPackage.eINSTANCE.getPropertiesEditionComponent_Explicit() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.name || key == ComponentsViewsRepository.PropertiesEditionComponent.Binding.views || key == ComponentsViewsRepository.PropertiesEditionComponent.Binding.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.name) - return "The name of this element binding"; //$NON-NLS-1$ - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Binding.views) - return "The mapped views"; //$NON-NLS-1$ - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Binding.model) - return "The mapped classifier"; //$NON-NLS-1$ - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID) - return "The ID of the dynamic help associated to this element (not implemented for the moment)"; //$NON-NLS-1$ - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit) - return "Whether the component can be directly used"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (ComponentsViewsRepository.PropertiesEditionComponent.Properties.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getAbstractElementBinding_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getAbstractElementBinding_Name().getEAttributeType(), newValue); - } - if (ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(ComponentsPackage.eINSTANCE.getEEFElement_HelpID().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(ComponentsPackage.eINSTANCE.getEEFElement_HelpID().getEAttributeType(), newValue); - } - if (ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(ComponentsPackage.eINSTANCE.getPropertiesEditionComponent_Explicit().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(ComponentsPackage.eINSTANCE.getPropertiesEditionComponent_Explicit().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionComponentPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionComponentPropertiesEditionComponent.java deleted file mode 100644 index c8db19bff..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionComponentPropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.components; - -// Start of user code for imports - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionComponentPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private PropertiesEditionComponentPropertiesEditionPart basePart; - - /** - * The PropertiesEditionComponentBasePropertiesEditionComponent sub component - * - */ - protected PropertiesEditionComponentBasePropertiesEditionComponent propertiesEditionComponentBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param propertiesEditionComponent the EObject to edit - * - */ - public PropertiesEditionComponentPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject propertiesEditionComponent, String editing_mode) { - super(editingContext, editing_mode); - if (propertiesEditionComponent instanceof PropertiesEditionComponent) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(propertiesEditionComponent, PropertiesEditingProvider.class); - propertiesEditionComponentBasePropertiesEditionComponent = (PropertiesEditionComponentBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, PropertiesEditionComponentBasePropertiesEditionComponent.BASE_PART, PropertiesEditionComponentBasePropertiesEditionComponent.class); - addSubComponent(propertiesEditionComponentBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(propertiesEditionComponent, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (PropertiesEditionComponentBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (PropertiesEditionComponentPropertiesEditionPart)propertiesEditionComponentBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (ComponentsViewsRepository.PropertiesEditionComponent.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (PropertiesEditionComponentPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == ComponentsViewsRepository.PropertiesEditionComponent.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionContextBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionContextBasePropertiesEditionComponent.java deleted file mode 100644 index 12b8ebbfb..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionContextBasePropertiesEditionComponent.java +++ /dev/null @@ -1,231 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.components; - -// Start of user code for imports - -import org.eclipse.emf.codegen.ecore.genmodel.GenModelFactory; -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionContextBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for model EObjectFlatComboViewer - */ - private EObjectFlatComboSettings modelSettings; - - - /** - * Default constructor - * - */ - public PropertiesEditionContextBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject propertiesEditionContext, String editing_mode) { - super(editingContext, propertiesEditionContext, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = ComponentsViewsRepository.class; - partKey = ComponentsViewsRepository.PropertiesEditionContext.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final PropertiesEditionContext propertiesEditionContext = (PropertiesEditionContext)elt; - final PropertiesEditionContextPropertiesEditionPart basePart = (PropertiesEditionContextPropertiesEditionPart)editingPart; - // init values - if (isAccessible(ComponentsViewsRepository.PropertiesEditionContext.Binding.model)) { - // init part - modelSettings = new EObjectFlatComboSettings(propertiesEditionContext, ComponentsPackage.eINSTANCE.getPropertiesEditionContext_Model()); - basePart.initModel(modelSettings); - // set the button mode - basePart.setModelButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - if (isAccessible(ComponentsViewsRepository.PropertiesEditionContext.Binding.model)) { - basePart.addFilterToModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof GenPackage); - } - - }); - // Start of user code for additional businessfilters for model - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == ComponentsViewsRepository.PropertiesEditionContext.Binding.model) { - return ComponentsPackage.eINSTANCE.getPropertiesEditionContext_Model(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - PropertiesEditionContext propertiesEditionContext = (PropertiesEditionContext)semanticObject; - if (ComponentsViewsRepository.PropertiesEditionContext.Binding.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - modelSettings.setToReference((GenPackage)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - GenPackage eObject = GenModelFactory.eINSTANCE.createGenPackage(); - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - modelSettings.setToReference(eObject); - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - PropertiesEditionContextPropertiesEditionPart basePart = (PropertiesEditionContextPropertiesEditionPart)editingPart; - if (ComponentsPackage.eINSTANCE.getPropertiesEditionContext_Model().equals(msg.getFeature()) && basePart != null && isAccessible(ComponentsViewsRepository.PropertiesEditionContext.Binding.model)) - basePart.setModel((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - ComponentsPackage.eINSTANCE.getPropertiesEditionContext_Model() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == ComponentsViewsRepository.PropertiesEditionContext.Binding.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == ComponentsViewsRepository.PropertiesEditionContext.Binding.model) - return "The GenPackage for this edition context"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionContextPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionContextPropertiesEditionComponent.java deleted file mode 100644 index b9d44743b..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionContextPropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.components; - -// Start of user code for imports - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionContextPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private PropertiesEditionContextPropertiesEditionPart basePart; - - /** - * The PropertiesEditionContextBasePropertiesEditionComponent sub component - * - */ - protected PropertiesEditionContextBasePropertiesEditionComponent propertiesEditionContextBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param propertiesEditionContext the EObject to edit - * - */ - public PropertiesEditionContextPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject propertiesEditionContext, String editing_mode) { - super(editingContext, editing_mode); - if (propertiesEditionContext instanceof PropertiesEditionContext) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(propertiesEditionContext, PropertiesEditingProvider.class); - propertiesEditionContextBasePropertiesEditionComponent = (PropertiesEditionContextBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, PropertiesEditionContextBasePropertiesEditionComponent.BASE_PART, PropertiesEditionContextBasePropertiesEditionComponent.class); - addSubComponent(propertiesEditionContextBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(propertiesEditionContext, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (PropertiesEditionContextBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (PropertiesEditionContextPropertiesEditionPart)propertiesEditionContextBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (ComponentsViewsRepository.PropertiesEditionContext.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (PropertiesEditionContextPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == ComponentsViewsRepository.PropertiesEditionContext.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionElementBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionElementBasePropertiesEditionComponent.java deleted file mode 100644 index 5c7b7832c..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionElementBasePropertiesEditionComponent.java +++ /dev/null @@ -1,363 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.components; - -// Start of user code for imports - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectStrictFilter; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionElementBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for views ReferencesTable - */ - private ReferencesTableSettings viewsSettings; - - /** - * Settings for model EObjectFlatComboViewer - */ - private EObjectFlatComboSettings modelSettings; - - - /** - * Default constructor - * - */ - public PropertiesEditionElementBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject propertiesEditionElement, String editing_mode) { - super(editingContext, propertiesEditionElement, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = ComponentsViewsRepository.class; - partKey = ComponentsViewsRepository.PropertiesEditionElement.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final PropertiesEditionElement propertiesEditionElement = (PropertiesEditionElement)elt; - final PropertiesEditionElementPropertiesEditionPart basePart = (PropertiesEditionElementPropertiesEditionPart)editingPart; - // init values - if (isAccessible(ComponentsViewsRepository.PropertiesEditionElement.Properties.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, propertiesEditionElement.getName())); - - if (isAccessible(ComponentsViewsRepository.PropertiesEditionElement.Binding.views)) { - viewsSettings = new ReferencesTableSettings(propertiesEditionElement, MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views()); - basePart.initViews(viewsSettings); - } - if (isAccessible(ComponentsViewsRepository.PropertiesEditionElement.Binding.model)) { - // init part - modelSettings = new EObjectFlatComboSettings(propertiesEditionElement, MappingPackage.eINSTANCE.getEMFPropertyBinding_Model()); - basePart.initModel(modelSettings); - // set the button mode - basePart.setModelButtonMode(ButtonsModeEnum.BROWSE); - } - if (isAccessible(ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID)) - basePart.setHelpID(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, propertiesEditionElement.getHelpID())); - - // init filters - - if (isAccessible(ComponentsViewsRepository.PropertiesEditionElement.Binding.views)) { - basePart.addFilterToViews(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - if (element instanceof EObject) - return (!basePart.isContainedInViewsTable((EObject)element)); - return false; - } - - }); - basePart.addFilterToViews(new EObjectStrictFilter(ViewsPackage.Literals.ELEMENT_EDITOR)); - basePart.addFilterToViews(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - Object result = EEFUtils.choiceOfValues(PropertiesEditionElementBasePropertiesEditionComponent.this.semanticObject, MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views()); - if (result instanceof Collection) { - return ((Collection)result).contains(element); - } else if (result instanceof ResourceSet && element instanceof EObject) { - return ((EObject)element).eResource() != null && ((EObject)element).eResource().getResourceSet() != null && ((EObject)element).eResource().getResourceSet().equals(result); - } - return element instanceof Resource; - } - }); - // Start of user code for additional businessfilters for views - - // End of user code - } - if (isAccessible(ComponentsViewsRepository.PropertiesEditionElement.Binding.model)) { - basePart.addFilterToModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EStructuralFeature); - } - - }); - // Start of user code for additional businessfilters for model - - // End of user code - } - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == ComponentsViewsRepository.PropertiesEditionElement.Properties.name) { - return MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name(); - } - if (editorKey == ComponentsViewsRepository.PropertiesEditionElement.Binding.views) { - return MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views(); - } - if (editorKey == ComponentsViewsRepository.PropertiesEditionElement.Binding.model) { - return MappingPackage.eINSTANCE.getEMFPropertyBinding_Model(); - } - if (editorKey == ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID) { - return ComponentsPackage.eINSTANCE.getEEFElement_HelpID(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - PropertiesEditionElement propertiesEditionElement = (PropertiesEditionElement)semanticObject; - if (ComponentsViewsRepository.PropertiesEditionElement.Properties.name == event.getAffectedEditor()) { - propertiesEditionElement.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (ComponentsViewsRepository.PropertiesEditionElement.Binding.views == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof ElementEditor) { - viewsSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - viewsSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - viewsSettings.move(event.getNewIndex(), (ElementEditor) event.getNewValue()); - } - } - if (ComponentsViewsRepository.PropertiesEditionElement.Binding.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - modelSettings.setToReference((EStructuralFeature)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, modelSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - if (ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID == event.getAffectedEditor()) { - propertiesEditionElement.setHelpID((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - PropertiesEditionElementPropertiesEditionPart basePart = (PropertiesEditionElementPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(ComponentsViewsRepository.PropertiesEditionElement.Properties.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views().equals(msg.getFeature()) && isAccessible(ComponentsViewsRepository.PropertiesEditionElement.Binding.views)) - basePart.updateViews(); - if (MappingPackage.eINSTANCE.getEMFPropertyBinding_Model().equals(msg.getFeature()) && basePart != null && isAccessible(ComponentsViewsRepository.PropertiesEditionElement.Binding.model)) - basePart.setModel((EObject)msg.getNewValue()); - if (ComponentsPackage.eINSTANCE.getEEFElement_HelpID().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID)) { - if (msg.getNewValue() != null) { - basePart.setHelpID(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setHelpID(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name(), - MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views(), - MappingPackage.eINSTANCE.getEMFPropertyBinding_Model(), - ComponentsPackage.eINSTANCE.getEEFElement_HelpID() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == ComponentsViewsRepository.PropertiesEditionElement.Properties.name || key == ComponentsViewsRepository.PropertiesEditionElement.Binding.views || key == ComponentsViewsRepository.PropertiesEditionElement.Binding.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == ComponentsViewsRepository.PropertiesEditionElement.Properties.name) - return "The name of this property binding"; //$NON-NLS-1$ - if (key == ComponentsViewsRepository.PropertiesEditionElement.Binding.views) - return "The mapped views"; //$NON-NLS-1$ - if (key == ComponentsViewsRepository.PropertiesEditionElement.Binding.model) - return "The mapped structural feature"; //$NON-NLS-1$ - if (key == ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID) - return "The ID of the dynamic help associated to this element (not implemented for the moment)"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (ComponentsViewsRepository.PropertiesEditionElement.Properties.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().getEAttributeType(), newValue); - } - if (ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(ComponentsPackage.eINSTANCE.getEEFElement_HelpID().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(ComponentsPackage.eINSTANCE.getEEFElement_HelpID().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionElementPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionElementPropertiesEditionComponent.java deleted file mode 100644 index 680c49042..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesEditionElementPropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.components; - -// Start of user code for imports - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionElementPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private PropertiesEditionElementPropertiesEditionPart basePart; - - /** - * The PropertiesEditionElementBasePropertiesEditionComponent sub component - * - */ - protected PropertiesEditionElementBasePropertiesEditionComponent propertiesEditionElementBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param propertiesEditionElement the EObject to edit - * - */ - public PropertiesEditionElementPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject propertiesEditionElement, String editing_mode) { - super(editingContext, editing_mode); - if (propertiesEditionElement instanceof PropertiesEditionElement) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(propertiesEditionElement, PropertiesEditingProvider.class); - propertiesEditionElementBasePropertiesEditionComponent = (PropertiesEditionElementBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, PropertiesEditionElementBasePropertiesEditionComponent.BASE_PART, PropertiesEditionElementBasePropertiesEditionComponent.class); - addSubComponent(propertiesEditionElementBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(propertiesEditionElement, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (PropertiesEditionElementBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (PropertiesEditionElementPropertiesEditionPart)propertiesEditionElementBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (ComponentsViewsRepository.PropertiesEditionElement.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (PropertiesEditionElementPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == ComponentsViewsRepository.PropertiesEditionElement.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesMultiEditionElementBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesMultiEditionElementBasePropertiesEditionComponent.java deleted file mode 100644 index 8ea80de33..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesMultiEditionElementBasePropertiesEditionComponent.java +++ /dev/null @@ -1,321 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.components; - -// Start of user code for imports - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesMultiEditionElement; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectStrictFilter; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesMultiEditionElementBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for views ReferencesTable - */ - private ReferencesTableSettings viewsSettings; - - /** - * Settings for model ReferencesTable - */ - private ReferencesTableSettings modelSettings; - - - /** - * Default constructor - * - */ - public PropertiesMultiEditionElementBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject propertiesMultiEditionElement, String editing_mode) { - super(editingContext, propertiesMultiEditionElement, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = ComponentsViewsRepository.class; - partKey = ComponentsViewsRepository.PropertiesMultiEditionElement.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final PropertiesMultiEditionElement propertiesMultiEditionElement = (PropertiesMultiEditionElement)elt; - final PropertiesMultiEditionElementPropertiesEditionPart basePart = (PropertiesMultiEditionElementPropertiesEditionPart)editingPart; - // init values - if (isAccessible(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, propertiesMultiEditionElement.getName())); - - if (isAccessible(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views)) { - viewsSettings = new ReferencesTableSettings(propertiesMultiEditionElement, MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views()); - basePart.initViews(viewsSettings); - } - if (isAccessible(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model)) { - modelSettings = new ReferencesTableSettings(propertiesMultiEditionElement, MappingPackage.eINSTANCE.getEMFMultiPropertiesBinding_Model()); - basePart.initModel(modelSettings); - } - if (isAccessible(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID)) - basePart.setHelpID(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, propertiesMultiEditionElement.getHelpID())); - - // init filters - - if (isAccessible(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views)) { - basePart.addFilterToViews(new EObjectFilter(ViewsPackage.Literals.ELEMENT_EDITOR)); - // Start of user code for additional businessfilters for views - - // End of user code - } - if (isAccessible(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model)) { - basePart.addFilterToModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - if (element instanceof EObject) - return (!basePart.isContainedInModelTable((EObject)element)); - return false; - } - - }); - basePart.addFilterToModel(new EObjectStrictFilter(EcorePackage.Literals.ESTRUCTURAL_FEATURE)); - // Start of user code for additional businessfilters for model - - // End of user code - } - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name) { - return MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name(); - } - if (editorKey == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views) { - return MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views(); - } - if (editorKey == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model) { - return MappingPackage.eINSTANCE.getEMFMultiPropertiesBinding_Model(); - } - if (editorKey == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID) { - return ComponentsPackage.eINSTANCE.getEEFElement_HelpID(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - PropertiesMultiEditionElement propertiesMultiEditionElement = (PropertiesMultiEditionElement)semanticObject; - if (ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name == event.getAffectedEditor()) { - propertiesMultiEditionElement.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof ElementEditor) { - viewsSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - viewsSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - viewsSettings.move(event.getNewIndex(), (ElementEditor) event.getNewValue()); - } - } - if (ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof EStructuralFeature) { - modelSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - modelSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - modelSettings.move(event.getNewIndex(), (EStructuralFeature) event.getNewValue()); - } - } - if (ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID == event.getAffectedEditor()) { - propertiesMultiEditionElement.setHelpID((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - PropertiesMultiEditionElementPropertiesEditionPart basePart = (PropertiesMultiEditionElementPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views().equals(msg.getFeature()) && isAccessible(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views)) - basePart.updateViews(); - if (MappingPackage.eINSTANCE.getEMFMultiPropertiesBinding_Model().equals(msg.getFeature()) && isAccessible(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model)) - basePart.updateModel(); - if (ComponentsPackage.eINSTANCE.getEEFElement_HelpID().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID)) { - if (msg.getNewValue() != null) { - basePart.setHelpID(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setHelpID(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name(), - MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views(), - MappingPackage.eINSTANCE.getEMFMultiPropertiesBinding_Model(), - ComponentsPackage.eINSTANCE.getEEFElement_HelpID() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name || key == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views || key == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name) - return "The name of this property binding"; //$NON-NLS-1$ - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views) - return "The mapped views"; //$NON-NLS-1$ - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model) - return "The mapped properties"; //$NON-NLS-1$ - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID) - return "The ID of the dynamic help associated to this element (not implemented for the moment)"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().getEAttributeType(), newValue); - } - if (ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(ComponentsPackage.eINSTANCE.getEEFElement_HelpID().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(ComponentsPackage.eINSTANCE.getEEFElement_HelpID().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesMultiEditionElementPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesMultiEditionElementPropertiesEditionComponent.java deleted file mode 100644 index b36bd9f2d..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/components/PropertiesMultiEditionElementPropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.components; - -// Start of user code for imports - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.components.PropertiesMultiEditionElement; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesMultiEditionElementPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private PropertiesMultiEditionElementPropertiesEditionPart basePart; - - /** - * The PropertiesMultiEditionElementBasePropertiesEditionComponent sub component - * - */ - protected PropertiesMultiEditionElementBasePropertiesEditionComponent propertiesMultiEditionElementBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param propertiesMultiEditionElement the EObject to edit - * - */ - public PropertiesMultiEditionElementPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject propertiesMultiEditionElement, String editing_mode) { - super(editingContext, editing_mode); - if (propertiesMultiEditionElement instanceof PropertiesMultiEditionElement) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(propertiesMultiEditionElement, PropertiesEditingProvider.class); - propertiesMultiEditionElementBasePropertiesEditionComponent = (PropertiesMultiEditionElementBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, PropertiesMultiEditionElementBasePropertiesEditionComponent.BASE_PART, PropertiesMultiEditionElementBasePropertiesEditionComponent.class); - addSubComponent(propertiesMultiEditionElementBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(propertiesMultiEditionElement, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (PropertiesMultiEditionElementBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (PropertiesMultiEditionElementPropertiesEditionPart)propertiesMultiEditionElementBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (ComponentsViewsRepository.PropertiesMultiEditionElement.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (PropertiesMultiEditionElementPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/ComponentsViewsRepository.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/ComponentsViewsRepository.java deleted file mode 100644 index 312af82a5..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/ComponentsViewsRepository.java +++ /dev/null @@ -1,130 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts; - -/** - * @author Nathalie Lepine - * - */ -public class ComponentsViewsRepository { - - public static final int SWT_KIND = 0; - - public static final int FORM_KIND = 1; - - - - /** - * PropertiesEditionContext view descriptor - * - */ - public static class PropertiesEditionContext { - public static class Binding { - - - public static String model = "components::PropertiesEditionContext::Binding::model"; - - - } - - } - - /** - * PropertiesEditionComponent view descriptor - * - */ - public static class PropertiesEditionComponent { - public static class Properties { - - - public static String name = "components::PropertiesEditionComponent::Properties::name"; - - - public static String helpID = "components::PropertiesEditionComponent::Properties::helpID"; - - - public static String explicit = "components::PropertiesEditionComponent::Properties::explicit"; - - - } - - public static class Binding { - - - public static String model = "components::PropertiesEditionComponent::Binding::model"; - - - public static String views = "components::PropertiesEditionComponent::Binding::views"; - - - } - - } - - /** - * PropertiesEditionElement view descriptor - * - */ - public static class PropertiesEditionElement { - public static class Properties { - - - public static String name = "components::PropertiesEditionElement::Properties::name"; - - - public static String helpID = "components::PropertiesEditionElement::Properties::helpID"; - - - } - - public static class Binding { - - - public static String model = "components::PropertiesEditionElement::Binding::model"; - - - public static String views = "components::PropertiesEditionElement::Binding::views"; - - - } - - } - - /** - * PropertiesMultiEditionElement view descriptor - * - */ - public static class PropertiesMultiEditionElement { - public static class Properties { - - - public static String name = "components::PropertiesMultiEditionElement::Properties::name"; - - - public static String helpID = "components::PropertiesMultiEditionElement::Properties::helpID"; - - - } - - public static class Binding { - - - public static String model = "components::PropertiesMultiEditionElement::Binding::model"; - - - public static String views = "components::PropertiesMultiEditionElement::Binding::views"; - - - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionComponentPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionComponentPropertiesEditionPart.java deleted file mode 100644 index 0cd5d48cd..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionComponentPropertiesEditionPart.java +++ /dev/null @@ -1,176 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts; - -// Start of user code for imports - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface PropertiesEditionComponentPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the helpID - * - */ - public String getHelpID(); - - /** - * Defines a new helpID - * @param newValue the new helpID to set - * - */ - public void setHelpID(String newValue); - - - /** - * @return the explicit - * - */ - public Boolean getExplicit(); - - /** - * Defines a new explicit - * @param newValue the new explicit to set - * - */ - public void setExplicit(Boolean newValue); - - - /** - * @return the model - * - */ - public EObject getModel(); - - /** - * Init the model - * @param settings the combo setting - */ - public void initModel(EObjectFlatComboSettings settings); - - /** - * Defines a new model - * @param newValue the new model to set - * - */ - public void setModel(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setModelButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - - - - /** - * Init the views - * @param settings settings for the views ReferencesTable - */ - public void initViews(ReferencesTableSettings settings); - - /** - * Update the views - * @param newValue the views to update - * - */ - public void updateViews(); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViews(ViewerFilter filter); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the views table - * - */ - public boolean isContainedInViewsTable(EObject element); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionContextPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionContextPropertiesEditionPart.java deleted file mode 100644 index 617591012..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionContextPropertiesEditionPart.java +++ /dev/null @@ -1,91 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts; - -// Start of user code for imports - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface PropertiesEditionContextPropertiesEditionPart { - - /** - * @return the model - * - */ - public EObject getModel(); - - /** - * Init the model - * @param settings the combo setting - */ - public void initModel(EObjectFlatComboSettings settings); - - /** - * Defines a new model - * @param newValue the new model to set - * - */ - public void setModel(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setModelButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionElementPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionElementPropertiesEditionPart.java deleted file mode 100644 index 0cfecb033..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesEditionElementPropertiesEditionPart.java +++ /dev/null @@ -1,162 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts; - -// Start of user code for imports - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface PropertiesEditionElementPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the helpID - * - */ - public String getHelpID(); - - /** - * Defines a new helpID - * @param newValue the new helpID to set - * - */ - public void setHelpID(String newValue); - - - /** - * @return the model - * - */ - public EObject getModel(); - - /** - * Init the model - * @param settings the combo setting - */ - public void initModel(EObjectFlatComboSettings settings); - - /** - * Defines a new model - * @param newValue the new model to set - * - */ - public void setModel(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setModelButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - - - - /** - * Init the views - * @param settings settings for the views ReferencesTable - */ - public void initViews(ReferencesTableSettings settings); - - /** - * Update the views - * @param newValue the views to update - * - */ - public void updateViews(); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViews(ViewerFilter filter); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the views table - * - */ - public boolean isContainedInViewsTable(EObject element); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesMultiEditionElementPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesMultiEditionElementPropertiesEditionPart.java deleted file mode 100644 index 1fde09e1b..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/PropertiesMultiEditionElementPropertiesEditionPart.java +++ /dev/null @@ -1,155 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts; - -// Start of user code for imports - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface PropertiesMultiEditionElementPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the helpID - * - */ - public String getHelpID(); - - /** - * Defines a new helpID - * @param newValue the new helpID to set - * - */ - public void setHelpID(String newValue); - - - - - /** - * Init the model - * @param settings settings for the model ReferencesTable - */ - public void initModel(ReferencesTableSettings settings); - - /** - * Update the model - * @param newValue the model to update - * - */ - public void updateModel(); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the model table - * - */ - public boolean isContainedInModelTable(EObject element); - - - - - /** - * Init the views - * @param settings settings for the views ReferencesTable - */ - public void initViews(ReferencesTableSettings settings); - - /** - * Update the views - * @param newValue the views to update - * - */ - public void updateViews(); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViews(ViewerFilter filter); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the views table - * - */ - public boolean isContainedInViewsTable(EObject element); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionComponentPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionComponentPropertiesEditionPartForm.java deleted file mode 100644 index 6e08644d5..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionComponentPropertiesEditionPartForm.java +++ /dev/null @@ -1,765 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts.forms; - -// Start of user code for imports - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart; -import org.eclipse.emf.eef.components.providers.ComponentsMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionComponentPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, PropertiesEditionComponentPropertiesEditionPart { - - protected Text name; - protected Text helpID; - protected Button explicit; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * For {@link ISection} use only. - */ - public PropertiesEditionComponentPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public PropertiesEditionComponentPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence propertiesEditionComponentStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = propertiesEditionComponentStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Properties.class); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Properties.name); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit); - - CompositionStep bindingStep = propertiesEditionComponentStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Binding.class); - bindingStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model); - bindingStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views); - - - composer = new PartComposer(propertiesEditionComponentStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.name) { - return createNameText(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID) { - return createHelpIDText(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit) { - return createExplicitCheckbox(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Binding.model) { - return createModelFlatComboViewer(parent, widgetFactory); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Binding.views) { - return createViewsReferencesTable(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionComponent.Properties.name, ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionComponentPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesEditionComponent.Properties.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionComponentPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesEditionComponent.Properties.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionComponentPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionComponent.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, ComponentsViewsRepository.PropertiesEditionComponent.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionComponent.Properties.name, ComponentsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createHelpIDText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID, ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_HelpIDLabel); - helpID = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - helpID.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData helpIDData = new GridData(GridData.FILL_HORIZONTAL); - helpID.setLayoutData(helpIDData); - helpID.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionComponentPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionComponentPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, helpID.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionComponentPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - helpID.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - } - } - }); - EditingUtils.setID(helpID, ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID); - EditingUtils.setEEFtype(helpID, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID, ComponentsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createHelpIDText - - // End of user code - return parent; - } - - - protected Composite createExplicitCheckbox(FormToolkit widgetFactory, Composite parent) { - explicit = widgetFactory.createButton(parent, getDescription(ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit, ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_ExplicitLabel), SWT.CHECK); - explicit.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(explicit.getSelection()))); - } - - }); - GridData explicitData = new GridData(GridData.FILL_HORIZONTAL); - explicitData.horizontalSpan = 2; - explicit.setLayoutData(explicitData); - EditingUtils.setID(explicit, ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit); - EditingUtils.setEEFtype(explicit, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit, ComponentsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createExplicitCheckbox - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createModelFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionComponent.Binding.model, ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model, ComponentsViewsRepository.FORM_KIND)); - widgetFactory.adapt(model); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionComponent.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - model.setID(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model, ComponentsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.views = new ReferencesTable(getDescription(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_ViewsLabel), new ReferencesTableListener () { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, ComponentsViewsRepository.FORM_KIND)); - this.views.createControls(parent, widgetFactory); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - // Start of user code for createViewsReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#getHelpID() - * - */ - public String getHelpID() { - return helpID.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#setHelpID(String newValue) - * - */ - public void setHelpID(String newValue) { - if (newValue != null) { - helpID.setText(newValue); - } else { - helpID.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID); - if (eefElementEditorReadOnlyState && helpID.isEnabled()) { - helpID.setEnabled(false); - helpID.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !helpID.isEnabled()) { - helpID.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#getExplicit() - * - */ - public Boolean getExplicit() { - return Boolean.valueOf(explicit.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#setExplicit(Boolean newValue) - * - */ - public void setExplicit(Boolean newValue) { - if (newValue != null) { - explicit.setSelection(newValue.booleanValue()); - } else { - explicit.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit); - if (eefElementEditorReadOnlyState && explicit.isEnabled()) { - explicit.setEnabled(false); - explicit.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !explicit.isEnabled()) { - explicit.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return ComponentsMessages.PropertiesEditionComponent_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionContextPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionContextPropertiesEditionPartForm.java deleted file mode 100644 index 92fe12bef..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionContextPropertiesEditionPartForm.java +++ /dev/null @@ -1,291 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts.forms; - -// Start of user code for imports - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart; -import org.eclipse.emf.eef.components.providers.ComponentsMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionContextPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, PropertiesEditionContextPropertiesEditionPart { - - protected EObjectFlatComboViewer model; - - - - /** - * For {@link ISection} use only. - */ - public PropertiesEditionContextPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public PropertiesEditionContextPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence propertiesEditionContextStep = new BindingCompositionSequence(propertiesEditionComponent); - propertiesEditionContextStep - .addStep(ComponentsViewsRepository.PropertiesEditionContext.Binding.class) - .addStep(ComponentsViewsRepository.PropertiesEditionContext.Binding.model); - - - composer = new PartComposer(propertiesEditionContextStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == ComponentsViewsRepository.PropertiesEditionContext.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionContext.Binding.model) { - return createModelFlatComboViewer(parent, widgetFactory); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(ComponentsMessages.PropertiesEditionContextPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createModelFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionContext.Binding.model, ComponentsMessages.PropertiesEditionContextPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(ComponentsViewsRepository.PropertiesEditionContext.Binding.model, ComponentsViewsRepository.FORM_KIND)); - widgetFactory.adapt(model); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionContextPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionContext.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - model.setID(ComponentsViewsRepository.PropertiesEditionContext.Binding.model); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionContext.Binding.model, ComponentsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - // Nothing to do - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionContext.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionContext.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return ComponentsMessages.PropertiesEditionContext_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionElementPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionElementPropertiesEditionPartForm.java deleted file mode 100644 index 1757e60c5..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionElementPropertiesEditionPartForm.java +++ /dev/null @@ -1,805 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts.forms; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; - -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart; - -import org.eclipse.emf.eef.components.providers.ComponentsMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EMFModelViewerDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; - -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; - -import org.eclipse.jface.viewers.ILabelProviderListener; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ITableLabelProvider; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.TableViewer; -import org.eclipse.jface.viewers.ViewerFilter; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; - -import org.eclipse.swt.graphics.Image; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.TableColumn; -import org.eclipse.swt.widgets.Text; - -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionElementPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, PropertiesEditionElementPropertiesEditionPart { - - protected Text name; - protected Text helpID; - protected EObjectFlatComboViewer model; - protected TableViewer views; - protected Button addViews; - protected Button removeViews; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * For {@link ISection} use only. - */ - public PropertiesEditionElementPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public PropertiesEditionElementPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence propertiesEditionElementStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = propertiesEditionElementStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Properties.class); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Properties.name); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID); - - CompositionStep bindingStep = propertiesEditionElementStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Binding.class); - bindingStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Binding.model); - bindingStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Binding.views); - - - composer = new PartComposer(propertiesEditionElementStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == ComponentsViewsRepository.PropertiesEditionElement.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.Properties.name) { - return createNameText(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID) { - return createHelpIDText(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.Binding.model) { - return createModelFlatComboViewer(parent, widgetFactory); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.Binding.views) { - return createViewsReferencesTable(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionElement.Properties.name, ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionElementPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesEditionElement.Properties.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionElementPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesEditionElement.Properties.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionElementPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionElement.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, ComponentsViewsRepository.PropertiesEditionElement.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionElement.Properties.name, ComponentsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createHelpIDText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID, ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_HelpIDLabel); - helpID = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - helpID.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData helpIDData = new GridData(GridData.FILL_HORIZONTAL); - helpID.setLayoutData(helpIDData); - helpID.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionElementPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionElementPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, helpID.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesEditionElementPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - helpID.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - } - } - }); - EditingUtils.setID(helpID, ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID); - EditingUtils.setEEFtype(helpID, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID, ComponentsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createHelpIDText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createModelFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionElement.Binding.model, ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(ComponentsViewsRepository.PropertiesEditionElement.Binding.model, ComponentsViewsRepository.FORM_KIND)); - widgetFactory.adapt(model); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionElement.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - model.setID(ComponentsViewsRepository.PropertiesEditionElement.Binding.model); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionElement.Binding.model, ComponentsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsReferencesTable(FormToolkit widgetFactory, Composite parent) { - Label viewsLabel = createDescription(parent, ComponentsViewsRepository.PropertiesEditionElement.Binding.views, ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_ViewsLabel); - GridData viewsLabelData = new GridData(); - viewsLabelData.horizontalSpan = 3; - viewsLabel.setLayoutData(viewsLabelData); - views = createViewsViewer(parent, widgetFactory, adapterFactory); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 2; - viewsData.minimumHeight = 120; - viewsData.heightHint = 120; - views.getTable().setLayoutData(viewsData); - EditingUtils.setID(views.getTable(), ComponentsViewsRepository.PropertiesEditionElement.Binding.views); - EditingUtils.setEEFtype(views.getTable(), "eef::ReferencesTable::field"); //$NON-NLS-1$ - createViewsControlPanel(parent, widgetFactory); - // Start of user code for createViewsReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected TableViewer createViewsViewer(Composite container, FormToolkit widgetFactory, AdapterFactory adapter) { - org.eclipse.swt.widgets.Table table = widgetFactory.createTable(container, SWT.FULL_SELECTION); - table.setHeaderVisible(true); - GridData gd = new GridData(); - gd.grabExcessHorizontalSpace = true; - gd.horizontalAlignment = GridData.FILL; - gd.grabExcessVerticalSpace = true; - gd.verticalAlignment = GridData.FILL; - table.setLayoutData(gd); - table.setLinesVisible(true); - // Start of user code for table views s columns definition - TableColumn name = new TableColumn(table, SWT.NONE); - name.setWidth(80); - name.setText("Label"); //$NON-NLS-1$ - // End of user code - - TableViewer result = new TableViewer(table); - result.setLabelProvider(new ITableLabelProvider() { - - // Start of user code for table views label provider - public String getColumnText(Object object, int columnIndex) { - AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory); - if (object instanceof EObject) { - switch (columnIndex) { - case 0: - return labelProvider.getText(object); - } - } - return ""; //$NON-NLS-1$ - } - // End of user code - - public Image getColumnImage(Object element, int columnIndex) { - return null; - } - - public void addListener(ILabelProviderListener listener) { - } - - public void dispose() { - } - - public boolean isLabelProperty(Object element, String property) { - return false; - } - - public void removeListener(ILabelProviderListener listener) { - } - - }); - return result; - } - - /** - * - */ - protected void createViewsControlPanel(Composite container, FormToolkit widgetFactory) { - Composite result = widgetFactory.createComposite(container, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - result.setLayout(layout); - addViews = widgetFactory.createButton(result, ComponentsMessages.PropertiesEditionPart_AddListViewerLabel, SWT.NONE); - GridData addData = new GridData(GridData.FILL_HORIZONTAL); - addViews.setLayoutData(addData); - addViews.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - addViews(); - } - - }); - EditingUtils.setID(addViews, ComponentsViewsRepository.PropertiesEditionElement.Binding.views); - EditingUtils.setEEFtype(addViews, "eef::ReferencesTable::addbutton"); //$NON-NLS-1$ - removeViews = widgetFactory.createButton(result, ComponentsMessages.PropertiesEditionPart_RemoveListViewerLabel, SWT.NONE); - GridData removeData = new GridData(GridData.FILL_HORIZONTAL); - removeViews.setLayoutData(removeData); - removeViews.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (views.getSelection() instanceof IStructuredSelection) { - removeViews((IStructuredSelection) views.getSelection()); - } - } - - }); - EditingUtils.setID(removeViews, ComponentsViewsRepository.PropertiesEditionElement.Binding.views); - EditingUtils.setEEFtype(removeViews, "eef::ReferencesTable::removebutton"); //$NON-NLS-1$ - // Start of user code for createViewsControlPanel - - // End of user code - } - - /** - * - */ - protected void addViews() { - - EMFModelViewerDialog dialog = new EMFModelViewerDialog(new AdapterFactoryLabelProvider(adapterFactory), views.getInput(), viewsFilters, viewsBusinessFilters, false, true) { - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionElement.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - } - - }; - // Start of user code for addViews - - // End of user code - dialog.open(); - views.refresh(); - } - - /** - * @param selection the views to remove - * - */ - protected void removeViews(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesEditionElement.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, elem)); - } - views.refresh(); - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionElement.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#getHelpID() - * - */ - public String getHelpID() { - return helpID.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#setHelpID(String newValue) - * - */ - public void setHelpID(String newValue) { - if (newValue != null) { - helpID.setText(newValue); - } else { - helpID.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID); - if (eefElementEditorReadOnlyState && helpID.isEnabled()) { - helpID.setEnabled(false); - helpID.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !helpID.isEnabled()) { - helpID.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionElement.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionElement.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionElement.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.getTable().setEnabled(false); - views.getTable().setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - addViews.setEnabled(false); - addViews.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - removeViews.setEnabled(false); - removeViews.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.getTable().setEnabled(true); - addViews.setEnabled(true); - removeViews.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return ComponentsMessages.PropertiesEditionElement_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesMultiEditionElementPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesMultiEditionElementPropertiesEditionPartForm.java deleted file mode 100644 index 3c2f54f69..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/forms/PropertiesMultiEditionElementPropertiesEditionPartForm.java +++ /dev/null @@ -1,842 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts.forms; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; - -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart; - -import org.eclipse.emf.eef.components.providers.ComponentsMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; - -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.EMFModelViewerDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; - -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; - -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; - -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; - -import org.eclipse.jface.viewers.ILabelProviderListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ITableLabelProvider; -import org.eclipse.jface.viewers.TableViewer; -import org.eclipse.jface.viewers.ViewerFilter; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; - -import org.eclipse.swt.graphics.Image; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.TableColumn; -import org.eclipse.swt.widgets.Text; - -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesMultiEditionElementPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, PropertiesMultiEditionElementPropertiesEditionPart { - - protected Text name; - protected Text helpID; - protected TableViewer model; - protected Button addModel; - protected Button removeModel; - protected List modelBusinessFilters = new ArrayList(); - protected List modelFilters = new ArrayList(); - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * For {@link ISection} use only. - */ - public PropertiesMultiEditionElementPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public PropertiesMultiEditionElementPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence propertiesMultiEditionElementStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = propertiesMultiEditionElementStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.class); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID); - - CompositionStep bindingStep = propertiesMultiEditionElementStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.class); - bindingStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model); - bindingStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views); - - - composer = new PartComposer(propertiesMultiEditionElementStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name) { - return createNameText(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID) { - return createHelpIDText(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model) { - return createModelReferencesTable(widgetFactory, parent); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views) { - return createViewsReferencesTable(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name, ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - PropertiesMultiEditionElementPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesMultiEditionElementPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesMultiEditionElementPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name, ComponentsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createHelpIDText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID, ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_HelpIDLabel); - helpID = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - helpID.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData helpIDData = new GridData(GridData.FILL_HORIZONTAL); - helpID.setLayoutData(helpIDData); - helpID.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - PropertiesMultiEditionElementPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesMultiEditionElementPropertiesEditionPartForm.this, - ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, helpID.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PropertiesMultiEditionElementPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - helpID.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - } - } - }); - EditingUtils.setID(helpID, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID); - EditingUtils.setEEFtype(helpID, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID, ComponentsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createHelpIDText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * - */ - protected Composite createModelReferencesTable(FormToolkit widgetFactory, Composite parent) { - Label modelLabel = createDescription(parent, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model, ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_ModelLabel); - GridData modelLabelData = new GridData(); - modelLabelData.horizontalSpan = 3; - modelLabel.setLayoutData(modelLabelData); - model = createModelViewer(parent, widgetFactory, adapterFactory); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - modelData.horizontalSpan = 2; - modelData.minimumHeight = 120; - modelData.heightHint = 120; - model.getTable().setLayoutData(modelData); - EditingUtils.setID(model.getTable(), ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model); - EditingUtils.setEEFtype(model.getTable(), "eef::ReferencesTable::field"); //$NON-NLS-1$ - createModelControlPanel(parent, widgetFactory); - // Start of user code for createModelReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected TableViewer createModelViewer(Composite container, FormToolkit widgetFactory, AdapterFactory adapter) { - org.eclipse.swt.widgets.Table table = widgetFactory.createTable(container, SWT.FULL_SELECTION); - table.setHeaderVisible(true); - GridData gd = new GridData(); - gd.grabExcessHorizontalSpace = true; - gd.horizontalAlignment = GridData.FILL; - gd.grabExcessVerticalSpace = true; - gd.verticalAlignment = GridData.FILL; - table.setLayoutData(gd); - table.setLinesVisible(true); - // Start of user code for table model s columns definition - TableColumn name = new TableColumn(table, SWT.NONE); - name.setWidth(80); - name.setText("Label"); //$NON-NLS-1$ - - // End of user code - - TableViewer result = new TableViewer(table); - result.setLabelProvider(new ITableLabelProvider() { - - // Start of user code for table model label provider - public String getColumnText(Object object, int columnIndex) { - AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory); - if (object instanceof EObject) { - switch (columnIndex) { - case 0: - return labelProvider.getText(object); - } - } - return ""; //$NON-NLS-1$ - } - - - // End of user code - - public Image getColumnImage(Object element, int columnIndex) { - return null; - } - - public void addListener(ILabelProviderListener listener) { - } - - public void dispose() { - } - - public boolean isLabelProperty(Object element, String property) { - return false; - } - - public void removeListener(ILabelProviderListener listener) { - } - - }); - return result; - } - - /** - * - */ - protected void createModelControlPanel(Composite container, FormToolkit widgetFactory) { - Composite result = widgetFactory.createComposite(container, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - result.setLayout(layout); - addModel = widgetFactory.createButton(result, ComponentsMessages.PropertiesEditionPart_AddListViewerLabel, SWT.NONE); - GridData addData = new GridData(GridData.FILL_HORIZONTAL); - addModel.setLayoutData(addData); - addModel.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - addModel(); - } - - }); - EditingUtils.setID(addModel, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model); - EditingUtils.setEEFtype(addModel, "eef::ReferencesTable::addbutton"); //$NON-NLS-1$ - removeModel = widgetFactory.createButton(result, ComponentsMessages.PropertiesEditionPart_RemoveListViewerLabel, SWT.NONE); - GridData removeData = new GridData(GridData.FILL_HORIZONTAL); - removeModel.setLayoutData(removeData); - removeModel.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (model.getSelection() instanceof IStructuredSelection) { - removeModel((IStructuredSelection) model.getSelection()); - } - } - - }); - EditingUtils.setID(removeModel, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model); - EditingUtils.setEEFtype(removeModel, "eef::ReferencesTable::removebutton"); //$NON-NLS-1$ - // Start of user code for createModelControlPanel - - // End of user code - } - - /** - * - */ - protected void addModel() { - - EMFModelViewerDialog dialog = new EMFModelViewerDialog(new AdapterFactoryLabelProvider(adapterFactory), model.getInput(), modelFilters, modelBusinessFilters, false, true) { - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - } - - }; - // Start of user code for addModel - - // End of user code - dialog.open(); - model.refresh(); - } - - /** - * @param selection the model to remove - * - */ - protected void removeModel(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, elem)); - } - model.refresh(); - } - - /** - * - */ - protected Composite createViewsReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.views = new ReferencesTable(getDescription(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_ViewsLabel), new ReferencesTableListener () { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, ComponentsViewsRepository.FORM_KIND)); - this.views.createControls(parent, widgetFactory); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - // Start of user code for createViewsReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartForm.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#getHelpID() - * - */ - public String getHelpID() { - return helpID.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#setHelpID(String newValue) - * - */ - public void setHelpID(String newValue) { - if (newValue != null) { - helpID.setText(newValue); - } else { - helpID.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID); - if (eefElementEditorReadOnlyState && helpID.isEnabled()) { - helpID.setEnabled(false); - helpID.setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !helpID.isEnabled()) { - helpID.setEnabled(true); - } - - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#initModel(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initModel(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - model.setContentProvider(contentProvider); - model.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model); - if (eefElementEditorReadOnlyState && model.getTable().isEnabled()) { - model.getTable().setEnabled(false); - model.getTable().setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - addModel.setEnabled(false); - addModel.setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - removeModel.setEnabled(false); - removeModel.setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.getTable().isEnabled()) { - model.getTable().setEnabled(true); - addModel.setEnabled(true); - removeModel.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#updateModel() - * - */ - public void updateModel() { - model.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - modelFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - modelBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#isContainedInModelTable(EObject element) - * - */ - public boolean isContainedInModelTable(EObject element) { - return ((ReferencesTableSettings)model.getInput()).contains(element); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return ComponentsMessages.PropertiesMultiEditionElement_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionComponentPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionComponentPropertiesEditionPartImpl.java deleted file mode 100644 index d0fec8aca..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionComponentPropertiesEditionPartImpl.java +++ /dev/null @@ -1,702 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts.impl; - -// Start of user code for imports - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart; -import org.eclipse.emf.eef.components.providers.ComponentsMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionComponentPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, PropertiesEditionComponentPropertiesEditionPart { - - protected Text name; - protected Text helpID; - protected Button explicit; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public PropertiesEditionComponentPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence propertiesEditionComponentStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = propertiesEditionComponentStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Properties.class); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Properties.name); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit); - - CompositionStep bindingStep = propertiesEditionComponentStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Binding.class); - bindingStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model); - bindingStep.addStep(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views); - - - composer = new PartComposer(propertiesEditionComponentStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.name) { - return createNameText(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID) { - return createHelpIDText(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit) { - return createExplicitCheckbox(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Binding.class) { - return createBindingGroup(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Binding.model) { - return createModelFlatComboViewer(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.Binding.views) { - return createViewsAdvancedReferencesTable(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionComponent.Properties.name, ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionComponent.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionComponent.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, ComponentsViewsRepository.PropertiesEditionComponent.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionComponent.Properties.name, ComponentsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createHelpIDText(Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID, ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_HelpIDLabel); - helpID = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData helpIDData = new GridData(GridData.FILL_HORIZONTAL); - helpID.setLayoutData(helpIDData); - helpID.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - } - - }); - helpID.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - } - } - - }); - EditingUtils.setID(helpID, ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID); - EditingUtils.setEEFtype(helpID, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID, ComponentsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createHelpIDText - - // End of user code - return parent; - } - - - protected Composite createExplicitCheckbox(Composite parent) { - explicit = new Button(parent, SWT.CHECK); - explicit.setText(getDescription(ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit, ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_ExplicitLabel)); - explicit.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(explicit.getSelection()))); - } - - }); - GridData explicitData = new GridData(GridData.FILL_HORIZONTAL); - explicitData.horizontalSpan = 2; - explicit.setLayoutData(explicitData); - EditingUtils.setID(explicit, ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit); - EditingUtils.setEEFtype(explicit, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit, ComponentsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createExplicitCheckbox - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createModelFlatComboViewer(Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionComponent.Binding.model, ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model, ComponentsViewsRepository.SWT_KIND)); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - model.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionComponent.Binding.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.setID(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model, ComponentsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsAdvancedReferencesTable(Composite parent) { - String label = getDescription(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, ComponentsMessages.PropertiesEditionComponentPropertiesEditionPart_ViewsLabel); - this.views = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, ComponentsViewsRepository.SWT_KIND)); - this.views.createControls(parent); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionComponentPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionComponent.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#getHelpID() - * - */ - public String getHelpID() { - return helpID.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#setHelpID(String newValue) - * - */ - public void setHelpID(String newValue) { - if (newValue != null) { - helpID.setText(newValue); - } else { - helpID.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Properties.helpID); - if (eefElementEditorReadOnlyState && helpID.isEnabled()) { - helpID.setEnabled(false); - helpID.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !helpID.isEnabled()) { - helpID.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#getExplicit() - * - */ - public Boolean getExplicit() { - return Boolean.valueOf(explicit.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#setExplicit(Boolean newValue) - * - */ - public void setExplicit(Boolean newValue) { - if (newValue != null) { - explicit.setSelection(newValue.booleanValue()); - } else { - explicit.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Properties.explicit); - if (eefElementEditorReadOnlyState && explicit.isEnabled()) { - explicit.setEnabled(false); - explicit.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !explicit.isEnabled()) { - explicit.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionComponent.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(ComponentsMessages.PropertiesEditionComponent_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionComponentPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return ComponentsMessages.PropertiesEditionComponent_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionContextPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionContextPropertiesEditionPartImpl.java deleted file mode 100644 index 57fe16a6b..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionContextPropertiesEditionPartImpl.java +++ /dev/null @@ -1,272 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts.impl; - -// Start of user code for imports - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart; -import org.eclipse.emf.eef.components.providers.ComponentsMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionContextPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, PropertiesEditionContextPropertiesEditionPart { - - protected EObjectFlatComboViewer model; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public PropertiesEditionContextPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence propertiesEditionContextStep = new BindingCompositionSequence(propertiesEditionComponent); - propertiesEditionContextStep - .addStep(ComponentsViewsRepository.PropertiesEditionContext.Binding.class) - .addStep(ComponentsViewsRepository.PropertiesEditionContext.Binding.model); - - - composer = new PartComposer(propertiesEditionContextStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == ComponentsViewsRepository.PropertiesEditionContext.Binding.class) { - return createBindingGroup(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionContext.Binding.model) { - return createModelFlatComboViewer(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(ComponentsMessages.PropertiesEditionContextPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createModelFlatComboViewer(Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionContext.Binding.model, ComponentsMessages.PropertiesEditionContextPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(ComponentsViewsRepository.PropertiesEditionContext.Binding.model, ComponentsViewsRepository.SWT_KIND)); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - model.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionContextPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionContext.Binding.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.setID(ComponentsViewsRepository.PropertiesEditionContext.Binding.model); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionContext.Binding.model, ComponentsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionContext.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionContext.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionContextPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return ComponentsMessages.PropertiesEditionContext_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionElementPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionElementPropertiesEditionPartImpl.java deleted file mode 100644 index c906f3c7d..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionElementPropertiesEditionPartImpl.java +++ /dev/null @@ -1,744 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts.impl; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; - -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart; - -import org.eclipse.emf.eef.components.providers.ComponentsMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EMFModelViewerDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; - -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; - -import org.eclipse.jface.viewers.ILabelProviderListener; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ITableLabelProvider; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.TableViewer; -import org.eclipse.jface.viewers.ViewerFilter; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; - -import org.eclipse.swt.graphics.Image; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.TableColumn; -import org.eclipse.swt.widgets.Text; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionElementPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, PropertiesEditionElementPropertiesEditionPart { - - protected Text name; - protected Text helpID; - protected EObjectFlatComboViewer model; - protected TableViewer views; - protected Button addViews; - protected Button removeViews; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public PropertiesEditionElementPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence propertiesEditionElementStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = propertiesEditionElementStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Properties.class); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Properties.name); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID); - - CompositionStep bindingStep = propertiesEditionElementStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Binding.class); - bindingStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Binding.model); - bindingStep.addStep(ComponentsViewsRepository.PropertiesEditionElement.Binding.views); - - - composer = new PartComposer(propertiesEditionElementStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == ComponentsViewsRepository.PropertiesEditionElement.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.Properties.name) { - return createNameText(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID) { - return createHelpIDText(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.Binding.class) { - return createBindingGroup(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.Binding.model) { - return createModelFlatComboViewer(parent); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.Binding.views) { - return createViewsReferencesTable(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionElement.Properties.name, ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionElement.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionElement.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, ComponentsViewsRepository.PropertiesEditionElement.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionElement.Properties.name, ComponentsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createHelpIDText(Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID, ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_HelpIDLabel); - helpID = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData helpIDData = new GridData(GridData.FILL_HORIZONTAL); - helpID.setLayoutData(helpIDData); - helpID.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - } - - }); - helpID.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - } - } - - }); - EditingUtils.setID(helpID, ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID); - EditingUtils.setEEFtype(helpID, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID, ComponentsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createHelpIDText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createModelFlatComboViewer(Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesEditionElement.Binding.model, ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(ComponentsViewsRepository.PropertiesEditionElement.Binding.model, ComponentsViewsRepository.SWT_KIND)); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - model.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionElement.Binding.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.setID(ComponentsViewsRepository.PropertiesEditionElement.Binding.model); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesEditionElement.Binding.model, ComponentsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * @param parent - * - */ - protected Composite createViewsReferencesTable(Composite parent) { - Label viewsLabel = createDescription(parent, ComponentsViewsRepository.PropertiesEditionElement.Binding.views, ComponentsMessages.PropertiesEditionElementPropertiesEditionPart_ViewsLabel); - GridData viewsLabelData = new GridData(); - viewsLabelData.horizontalSpan = 3; - viewsLabel.setLayoutData(viewsLabelData); - views = createViewsViewer(parent, adapterFactory); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 2; - viewsData.minimumHeight = 120; - viewsData.heightHint = 120; - views.getTable().setLayoutData(viewsData); - EditingUtils.setID(views.getTable(), ComponentsViewsRepository.PropertiesEditionElement.Binding.views); - EditingUtils.setEEFtype(views.getTable(), "eef::ReferencesTable::field"); //$NON-NLS-1$ - createViewsControlPanel(parent); - return parent; - } - - /** - * - */ - protected TableViewer createViewsViewer(Composite container, AdapterFactory adapter) { - org.eclipse.swt.widgets.Table table = new org.eclipse.swt.widgets.Table(container, SWT.FULL_SELECTION); - table.setHeaderVisible(true); - GridData gd = new GridData(); - gd.grabExcessHorizontalSpace = true; - gd.horizontalAlignment = GridData.FILL; - gd.grabExcessVerticalSpace = true; - gd.verticalAlignment = GridData.FILL; - table.setLayoutData(gd); - table.setLinesVisible(true); - // Start of user code for table views s columns definition - TableColumn name = new TableColumn(table, SWT.NONE); - name.setWidth(80); - name.setText("Label"); //$NON-NLS-1$ - - // End of user code - - TableViewer result = new TableViewer(table); - result.setLabelProvider(new ITableLabelProvider() { - - // Start of user code for table views label provider - public String getColumnText(Object object, int columnIndex) { - AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory); - if (object instanceof EObject) { - switch (columnIndex) { - case 0: - return labelProvider.getText(object); - } - } - return ""; //$NON-NLS-1$ - } - - public Image getColumnImage(Object element, int columnIndex) { - return null; - } - - // End of user code - - public void addListener(ILabelProviderListener listener) { - } - - public void dispose() { - } - - public boolean isLabelProperty(Object element, String property) { - return false; - } - - public void removeListener(ILabelProviderListener listener) { - } - - }); - return result; - } - - /** - * - */ - protected void createViewsControlPanel(Composite container) { - Composite result = new Composite(container, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - result.setLayout(layout); - addViews = new Button(result, SWT.NONE); - addViews.setText(ComponentsMessages.PropertiesEditionPart_AddListViewerLabel); - GridData addData = new GridData(GridData.FILL_HORIZONTAL); - addViews.setLayoutData(addData); - addViews.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - addViews(); - } - - }); - EditingUtils.setID(addViews, ComponentsViewsRepository.PropertiesEditionElement.Binding.views); - EditingUtils.setEEFtype(addViews, "eef::ReferencesTable::addbutton"); //$NON-NLS-1$ - removeViews = new Button(result, SWT.NONE); - removeViews.setText(ComponentsMessages.PropertiesEditionPart_RemoveListViewerLabel); - GridData removeData = new GridData(GridData.FILL_HORIZONTAL); - removeViews.setLayoutData(removeData); - removeViews.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (views.getSelection() instanceof IStructuredSelection) { - removeViews((IStructuredSelection) views.getSelection()); - } - } - - }); - EditingUtils.setID(removeViews, ComponentsViewsRepository.PropertiesEditionElement.Binding.views); - EditingUtils.setEEFtype(removeViews, "eef::ReferencesTable::removebutton"); //$NON-NLS-1$ - } - - /** - * - */ - protected void addViews() { - EMFModelViewerDialog dialog = new EMFModelViewerDialog(new AdapterFactoryLabelProvider(adapterFactory), views.getInput(), viewsFilters, viewsBusinessFilters, false, true) { - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionElement.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - } - - }; - dialog.open(); - // Start of user code for addViews - - // End of user code - views.refresh(); - } - - /** - * @param selection the views to remove - * - */ - protected void removeViews(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesEditionElement.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, elem)); - } - views.refresh(); - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionElement.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#getHelpID() - * - */ - public String getHelpID() { - return helpID.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#setHelpID(String newValue) - * - */ - public void setHelpID(String newValue) { - if (newValue != null) { - helpID.setText(newValue); - } else { - helpID.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID); - if (eefElementEditorReadOnlyState && helpID.isEnabled()) { - helpID.setEnabled(false); - helpID.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !helpID.isEnabled()) { - helpID.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionElement.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionElement.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesEditionElement.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.getTable().setEnabled(false); - views.getTable().setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - addViews.setEnabled(false); - addViews.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - removeViews.setEnabled(false); - removeViews.setToolTipText(ComponentsMessages.PropertiesEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.getTable().setEnabled(true); - addViews.setEnabled(true); - removeViews.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesEditionElementPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return ComponentsMessages.PropertiesEditionElement_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesMultiEditionElementPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesMultiEditionElementPropertiesEditionPartImpl.java deleted file mode 100644 index b4ff1068d..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/parts/impl/PropertiesMultiEditionElementPropertiesEditionPartImpl.java +++ /dev/null @@ -1,783 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts.impl; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; - -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart; - -import org.eclipse.emf.eef.components.providers.ComponentsMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.EMFModelViewerDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; - -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; - -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; - -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; - -import org.eclipse.jface.viewers.ILabelProviderListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ITableLabelProvider; -import org.eclipse.jface.viewers.TableViewer; -import org.eclipse.jface.viewers.ViewerFilter; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; - -import org.eclipse.swt.graphics.Image; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.TableColumn; -import org.eclipse.swt.widgets.Text; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesMultiEditionElementPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, PropertiesMultiEditionElementPropertiesEditionPart { - - protected Text name; - protected Text helpID; - protected TableViewer model; - protected Button addModel; - protected Button removeModel; - protected List modelBusinessFilters = new ArrayList(); - protected List modelFilters = new ArrayList(); - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public PropertiesMultiEditionElementPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence propertiesMultiEditionElementStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = propertiesMultiEditionElementStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.class); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name); - propertiesStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID); - - CompositionStep bindingStep = propertiesMultiEditionElementStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.class); - bindingStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model); - bindingStep.addStep(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views); - - - composer = new PartComposer(propertiesMultiEditionElementStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name) { - return createNameText(parent); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID) { - return createHelpIDText(parent); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.class) { - return createBindingGroup(parent); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model) { - return createModelReferencesTable(parent); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views) { - return createViewsAdvancedReferencesTable(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name, ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name, ComponentsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createHelpIDText(Composite parent) { - createDescription(parent, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID, ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_HelpIDLabel); - helpID = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData helpIDData = new GridData(GridData.FILL_HORIZONTAL); - helpID.setLayoutData(helpIDData); - helpID.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - } - - }); - helpID.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, helpID.getText())); - } - } - - }); - EditingUtils.setID(helpID, ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID); - EditingUtils.setEEFtype(helpID, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID, ComponentsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createHelpIDText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * @param parent - * - */ - protected Composite createModelReferencesTable(Composite parent) { - Label modelLabel = createDescription(parent, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model, ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_ModelLabel); - GridData modelLabelData = new GridData(); - modelLabelData.horizontalSpan = 3; - modelLabel.setLayoutData(modelLabelData); - model = createModelViewer(parent, adapterFactory); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - modelData.horizontalSpan = 2; - modelData.minimumHeight = 120; - modelData.heightHint = 120; - model.getTable().setLayoutData(modelData); - EditingUtils.setID(model.getTable(), ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model); - EditingUtils.setEEFtype(model.getTable(), "eef::ReferencesTable::field"); //$NON-NLS-1$ - createModelControlPanel(parent); - return parent; - } - - /** - * - */ - protected TableViewer createModelViewer(Composite container, AdapterFactory adapter) { - org.eclipse.swt.widgets.Table table = new org.eclipse.swt.widgets.Table(container, SWT.FULL_SELECTION); - table.setHeaderVisible(true); - GridData gd = new GridData(); - gd.grabExcessHorizontalSpace = true; - gd.horizontalAlignment = GridData.FILL; - gd.grabExcessVerticalSpace = true; - gd.verticalAlignment = GridData.FILL; - table.setLayoutData(gd); - table.setLinesVisible(true); - // Start of user code for table model s columns definition - TableColumn name = new TableColumn(table, SWT.NONE); - name.setWidth(80); - name.setText("Label"); //$NON-NLS-1$ - - // End of user code - - TableViewer result = new TableViewer(table); - result.setLabelProvider(new ITableLabelProvider() { - - // Start of user code for table model label provider - public String getColumnText(Object object, int columnIndex) { - AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory); - if (object instanceof EObject) { - switch (columnIndex) { - case 0: - return labelProvider.getText(object); - } - } - return ""; //$NON-NLS-1$ - } - - public Image getColumnImage(Object element, int columnIndex) { - return null; - } - - // End of user code - - public void addListener(ILabelProviderListener listener) { - } - - public void dispose() { - } - - public boolean isLabelProperty(Object element, String property) { - return false; - } - - public void removeListener(ILabelProviderListener listener) { - } - - }); - return result; - } - - /** - * - */ - protected void createModelControlPanel(Composite container) { - Composite result = new Composite(container, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - result.setLayout(layout); - addModel = new Button(result, SWT.NONE); - addModel.setText(ComponentsMessages.PropertiesEditionPart_AddListViewerLabel); - GridData addData = new GridData(GridData.FILL_HORIZONTAL); - addModel.setLayoutData(addData); - addModel.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - addModel(); - } - - }); - EditingUtils.setID(addModel, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model); - EditingUtils.setEEFtype(addModel, "eef::ReferencesTable::addbutton"); //$NON-NLS-1$ - removeModel = new Button(result, SWT.NONE); - removeModel.setText(ComponentsMessages.PropertiesEditionPart_RemoveListViewerLabel); - GridData removeData = new GridData(GridData.FILL_HORIZONTAL); - removeModel.setLayoutData(removeData); - removeModel.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (model.getSelection() instanceof IStructuredSelection) { - removeModel((IStructuredSelection) model.getSelection()); - } - } - - }); - EditingUtils.setID(removeModel, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model); - EditingUtils.setEEFtype(removeModel, "eef::ReferencesTable::removebutton"); //$NON-NLS-1$ - } - - /** - * - */ - protected void addModel() { - EMFModelViewerDialog dialog = new EMFModelViewerDialog(new AdapterFactoryLabelProvider(adapterFactory), model.getInput(), modelFilters, modelBusinessFilters, false, true) { - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - } - - }; - dialog.open(); - // Start of user code for addModel - - // End of user code - model.refresh(); - } - - /** - * @param selection the model to remove - * - */ - protected void removeModel(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, elem)); - } - model.refresh(); - } - - /** - * - */ - protected Composite createViewsAdvancedReferencesTable(Composite parent) { - String label = getDescription(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, ComponentsMessages.PropertiesMultiEditionElementPropertiesEditionPart_ViewsLabel); - this.views = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, ComponentsViewsRepository.SWT_KIND)); - this.views.createControls(parent); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PropertiesMultiEditionElementPropertiesEditionPartImpl.this, ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#getHelpID() - * - */ - public String getHelpID() { - return helpID.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#setHelpID(String newValue) - * - */ - public void setHelpID(String newValue) { - if (newValue != null) { - helpID.setText(newValue); - } else { - helpID.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesMultiEditionElement.Properties.helpID); - if (eefElementEditorReadOnlyState && helpID.isEnabled()) { - helpID.setEnabled(false); - helpID.setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !helpID.isEnabled()) { - helpID.setEnabled(true); - } - - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#initModel(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initModel(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - model.setContentProvider(contentProvider); - model.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.model); - if (eefElementEditorReadOnlyState && model.getTable().isEnabled()) { - model.getTable().setEnabled(false); - model.getTable().setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - addModel.setEnabled(false); - addModel.setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - removeModel.setEnabled(false); - removeModel.setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.getTable().isEnabled()) { - model.getTable().setEnabled(true); - addModel.setEnabled(true); - removeModel.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#updateModel() - * - */ - public void updateModel() { - model.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - modelFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - modelBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#isContainedInModelTable(EObject element) - * - */ - public boolean isContainedInModelTable(EObject element) { - return ((ReferencesTableSettings)model.getInput()).contains(element); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(ComponentsViewsRepository.PropertiesMultiEditionElement.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(ComponentsMessages.PropertiesMultiEditionElement_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.PropertiesMultiEditionElementPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return ComponentsMessages.PropertiesMultiEditionElement_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/ComponentsEditPlugin.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/ComponentsEditPlugin.java deleted file mode 100644 index 65c830a1b..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/ComponentsEditPlugin.java +++ /dev/null @@ -1,103 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.provider; - -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelEditPlugin; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.EValidator; -import org.eclipse.emf.ecore.provider.EcoreEditPlugin; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.mapping.provider.MappingEditPlugin; -import org.eclipse.emf.eef.runtime.impl.validation.EEFValidator; -import org.eclipse.emf.eef.views.provider.ViewsEditPlugin; - -/** - * This is the central singleton for the Components edit plugin. - * - * - * @generated - */ -public final class ComponentsEditPlugin extends EMFPlugin { - /** - * Keep track of the singleton. - * - * - * @generated - */ - public static final ComponentsEditPlugin INSTANCE = new ComponentsEditPlugin(); - - /** - * Keep track of the singleton. - * - * - * @generated - */ - private static Implementation plugin; - - /** - * Create the instance. - * - * - * @generated - */ - public ComponentsEditPlugin() { - super(new ResourceLocator[] {EcoreEditPlugin.INSTANCE, GenModelEditPlugin.INSTANCE, - MappingEditPlugin.INSTANCE, ViewsEditPlugin.INSTANCE,}); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - @Override - public ResourceLocator getPluginResourceLocator() { - return plugin; - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * - * @generated - */ - public static class Implementation extends EclipsePlugin { - /** - * Creates an instance. - * - * - * @generated NOT - */ - public Implementation() { - super(); - - // Remember the static instance. - // - plugin = this; - EValidator.Registry.INSTANCE.put(ComponentsPackage.eINSTANCE, new EEFValidator()); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/ComponentsItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/ComponentsItemProviderAdapterFactory.java deleted file mode 100644 index b7952bbc6..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/ComponentsItemProviderAdapterFactory.java +++ /dev/null @@ -1,452 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.provider; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.command.CommandParameter; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ChildCreationExtenderManager; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.components.ComponentsFactory; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.util.ComponentsAdapterFactory; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.util.MappingSwitch; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class ComponentsItemProviderAdapterFactory extends ComponentsAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable, IChildCreationExtender { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This helps manage the child creation extenders. - * - * - * @generated - */ - protected ChildCreationExtenderManager childCreationExtenderManager = new ChildCreationExtenderManager( - ComponentsEditPlugin.INSTANCE, ComponentsPackage.eNS_URI); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public ComponentsItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.components.PropertiesEditionContext} instances. - * - * - * @generated - */ - protected PropertiesEditionContextItemProvider propertiesEditionContextItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.components.PropertiesEditionContext}. - * - * - * @generated - */ - @Override - public Adapter createPropertiesEditionContextAdapter() { - if (propertiesEditionContextItemProvider == null) { - propertiesEditionContextItemProvider = new PropertiesEditionContextItemProvider(this); - } - - return propertiesEditionContextItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.components.PropertiesEditionComponent} instances. - * - * - * @generated - */ - protected PropertiesEditionComponentItemProvider propertiesEditionComponentItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.components.PropertiesEditionComponent}. - * - * - * @generated - */ - @Override - public Adapter createPropertiesEditionComponentAdapter() { - if (propertiesEditionComponentItemProvider == null) { - propertiesEditionComponentItemProvider = new PropertiesEditionComponentItemProvider(this); - } - - return propertiesEditionComponentItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.components.PropertiesEditionElement} instances. - * - * - * @generated - */ - protected PropertiesEditionElementItemProvider propertiesEditionElementItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.components.PropertiesEditionElement}. - * - * - * @generated - */ - @Override - public Adapter createPropertiesEditionElementAdapter() { - if (propertiesEditionElementItemProvider == null) { - propertiesEditionElementItemProvider = new PropertiesEditionElementItemProvider(this); - } - - return propertiesEditionElementItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.components.PropertiesMultiEditionElement} instances. - * - * - * @generated - */ - protected PropertiesMultiEditionElementItemProvider propertiesMultiEditionElementItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.components.PropertiesMultiEditionElement}. - * - * - * @generated - */ - @Override - public Adapter createPropertiesMultiEditionElementAdapter() { - if (propertiesMultiEditionElementItemProvider == null) { - propertiesMultiEditionElementItemProvider = new PropertiesMultiEditionElementItemProvider(this); - } - - return propertiesMultiEditionElementItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) || (((Class)type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * - * - * @generated - */ - public List getChildCreationExtenders() { - return childCreationExtenderManager.getChildCreationExtenders(); - } - - /** - * - * - * @generated - */ - public Collection getNewChildDescriptors(Object object, EditingDomain editingDomain) { - return childCreationExtenderManager.getNewChildDescriptors(object, editingDomain); - } - - /** - * - * - * @generated - */ - public ResourceLocator getResourceLocator() { - return childCreationExtenderManager; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (propertiesEditionContextItemProvider != null) - propertiesEditionContextItemProvider.dispose(); - if (propertiesEditionComponentItemProvider != null) - propertiesEditionComponentItemProvider.dispose(); - if (propertiesEditionElementItemProvider != null) - propertiesEditionElementItemProvider.dispose(); - if (propertiesMultiEditionElementItemProvider != null) - propertiesMultiEditionElementItemProvider.dispose(); - } - - /** - * A child creation extender for the {@link MappingPackage}. - * - * - * @generated - */ - public static class MappingChildCreationExtender implements IChildCreationExtender { - /** - * The switch for creating child descriptors specific to each extended class. - * - * - * @generated - */ - protected static class CreationSwitch extends MappingSwitch { - /** - * The child descriptors being populated. - * - * - * @generated - */ - protected List newChildDescriptors; - - /** - * The domain in which to create the children. - * - * - * @generated - */ - protected EditingDomain editingDomain; - - /** - * Creates the a switch for populating child descriptors in the given domain. - * - * - * @generated - */ - CreationSwitch(List newChildDescriptors, EditingDomain editingDomain) { - this.newChildDescriptors = newChildDescriptors; - this.editingDomain = editingDomain; - } - - /** - * - * - * @generated - */ - @Override - public Object caseDatabinding(Databinding object) { - newChildDescriptors.add(createChildParameter(MappingPackage.Literals.DATABINDING__BINDINGS, - ComponentsFactory.eINSTANCE.createPropertiesEditionComponent())); - - return null; - } - - /** - * - * - * @generated - */ - @Override - public Object caseAbstractElementBinding(AbstractElementBinding object) { - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS, - ComponentsFactory.eINSTANCE.createPropertiesEditionComponent())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__PROPERTIES, - ComponentsFactory.eINSTANCE.createPropertiesEditionElement())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__PROPERTIES, - ComponentsFactory.eINSTANCE.createPropertiesMultiEditionElement())); - - return null; - } - - /** - * - * - * @generated - */ - @Override - public Object caseCategory(Category object) { - newChildDescriptors.add(createChildParameter(MappingPackage.Literals.CATEGORY__BINDINGS, - ComponentsFactory.eINSTANCE.createPropertiesEditionComponent())); - - return null; - } - - /** - * - * - * @generated - */ - protected CommandParameter createChildParameter(Object feature, Object child) { - return new CommandParameter(null, feature, child); - } - - } - - /** - * - * - * @generated - */ - public Collection getNewChildDescriptors(Object object, EditingDomain editingDomain) { - ArrayList result = new ArrayList(); - new CreationSwitch(result, editingDomain).doSwitch((EObject)object); - return result; - } - - /** - * - * - * @generated - */ - public ResourceLocator getResourceLocator() { - return ComponentsEditPlugin.INSTANCE; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/EEFElementItemProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/EEFElementItemProvider.java deleted file mode 100644 index e8d577c73..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/EEFElementItemProvider.java +++ /dev/null @@ -1,147 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.EEFElement; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.components.EEFElement} object. - * - * - * @generated - */ -public class EEFElementItemProvider extends ItemProviderAdapter implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFElementItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addHelpIDPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Help ID feature. - * - * - * @generated - */ - protected void addHelpIDPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), - getString("_UI_EEFElement_helpID_feature"), getString("_UI_EEFElement_helpID_description"), - ComponentsPackage.Literals.EEF_ELEMENT__HELP_ID, true, false, false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - - /** - * This returns EEFElement.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/EEFElement")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EEFElement)object).getHelpID(); - return label == null || label.length() == 0 ? getString("_UI_EEFElement_type") - : getString("_UI_EEFElement_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(EEFElement.class)) { - case ComponentsPackage.EEF_ELEMENT__HELP_ID: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, - true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender)adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionComponentItemProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionComponentItemProvider.java deleted file mode 100644 index 535ea8d4c..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionComponentItemProvider.java +++ /dev/null @@ -1,172 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.components.ComponentsFactory; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.MappingFactory; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.provider.EMFElementBindingItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.components.PropertiesEditionComponent} object. - * - * - * @generated - */ -public class PropertiesEditionComponentItemProvider extends EMFElementBindingItemProvider implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public PropertiesEditionComponentItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addHelpIDPropertyDescriptor(object); - addExplicitPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Help ID feature. - * - * - * @generated - */ - protected void addHelpIDPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), - getString("_UI_EEFElement_helpID_feature"), getString("_UI_EEFElement_helpID_description"), - ComponentsPackage.Literals.EEF_ELEMENT__HELP_ID, true, false, false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - - /** - * This adds a property descriptor for the Explicit feature. - * - * - * @generated - */ - protected void addExplicitPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), - getString("_UI_PropertiesEditionComponent_explicit_feature"), - getString("_UI_PropertiesEditionComponent_explicit_description"), - ComponentsPackage.Literals.PROPERTIES_EDITION_COMPONENT__EXPLICIT, true, false, false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, null, null)); - } - - /** - * This returns PropertiesEditionComponent.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/PropertiesEditionComponent")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((PropertiesEditionComponent)object).getName(); - return label == null || label.length() == 0 ? getString("_UI_PropertiesEditionComponent_type") - : getString("_UI_PropertiesEditionComponent_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(PropertiesEditionComponent.class)) { - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__HELP_ID: - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__EXPLICIT: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, - true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated NOT - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - //super.collectNewChildDescriptors(newChildDescriptors, object); - // - //newChildDescriptors - // .add(createChildParameter( - // MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS, - // ComponentsFactory.eINSTANCE - // .createPropertiesEditionComponent())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__PROPERTIES, - ComponentsFactory.eINSTANCE.createPropertiesEditionElement())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__PROPERTIES, - ComponentsFactory.eINSTANCE.createPropertiesMultiEditionElement())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING, - MappingFactory.eINSTANCE.createElementBindingReference())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionContextItemProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionContextItemProvider.java deleted file mode 100644 index d2bd42953..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionContextItemProvider.java +++ /dev/null @@ -1,135 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.components.ComponentsFactory; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.mapping.MappingFactory; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.provider.DatabindingItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.components.PropertiesEditionContext} object. - * - * - * @generated - */ -public class PropertiesEditionContextItemProvider extends DatabindingItemProvider implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public PropertiesEditionContextItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addModelPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Model feature. - * - * - * @generated - */ - protected void addModelPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), - getString("_UI_PropertiesEditionContext_model_feature"), - getString("_UI_PropertiesEditionContext_model_description"), - ComponentsPackage.Literals.PROPERTIES_EDITION_CONTEXT__MODEL, true, false, true, null, null, - null)); - } - - /** - * This returns PropertiesEditionContext.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/PropertiesEditionContext")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((PropertiesEditionContext)object).getDocumentation(); - return label == null || label.length() == 0 ? getString("_UI_PropertiesEditionContext_type") - : getString("_UI_PropertiesEditionContext_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated NOT - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - //super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add(createChildParameter(MappingPackage.Literals.DATABINDING__CATEGORIES, - MappingFactory.eINSTANCE.createCategory())); - - newChildDescriptors.add(createChildParameter(MappingPackage.Literals.DATABINDING__BINDINGS, - ComponentsFactory.eINSTANCE.createPropertiesEditionComponent())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionElementItemProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionElementItemProvider.java deleted file mode 100644 index a73fb2bf5..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesEditionElementItemProvider.java +++ /dev/null @@ -1,134 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.mapping.provider.EMFPropertyBindingItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.components.PropertiesEditionElement} object. - * - * - * @generated - */ -public class PropertiesEditionElementItemProvider extends EMFPropertyBindingItemProvider implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public PropertiesEditionElementItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addHelpIDPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Help ID feature. - * - * - * @generated - */ - protected void addHelpIDPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), - getString("_UI_EEFElement_helpID_feature"), getString("_UI_EEFElement_helpID_description"), - ComponentsPackage.Literals.EEF_ELEMENT__HELP_ID, true, false, false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - - /** - * This returns PropertiesEditionElement.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/PropertiesEditionElement")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((PropertiesEditionElement)object).getName(); - return label == null || label.length() == 0 ? getString("_UI_PropertiesEditionElement_type") - : getString("_UI_PropertiesEditionElement_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(PropertiesEditionElement.class)) { - case ComponentsPackage.PROPERTIES_EDITION_ELEMENT__HELP_ID: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, - true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesMultiEditionElementItemProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesMultiEditionElementItemProvider.java deleted file mode 100644 index 55ecf7b02..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/provider/PropertiesMultiEditionElementItemProvider.java +++ /dev/null @@ -1,134 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesMultiEditionElement; -import org.eclipse.emf.eef.mapping.provider.EMFMultiPropertiesBindingItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.components.PropertiesMultiEditionElement} object. - * - * - * @generated - */ -public class PropertiesMultiEditionElementItemProvider extends EMFMultiPropertiesBindingItemProvider implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public PropertiesMultiEditionElementItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addHelpIDPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Help ID feature. - * - * - * @generated - */ - protected void addHelpIDPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), - getString("_UI_EEFElement_helpID_feature"), getString("_UI_EEFElement_helpID_description"), - ComponentsPackage.Literals.EEF_ELEMENT__HELP_ID, true, false, false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - - /** - * This returns PropertiesMultiEditionElement.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/PropertiesMultiEditionElement")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((PropertiesMultiEditionElement)object).getName(); - return label == null || label.length() == 0 ? getString("_UI_PropertiesMultiEditionElement_type") - : getString("_UI_PropertiesMultiEditionElement_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(PropertiesMultiEditionElement.class)) { - case ComponentsPackage.PROPERTIES_MULTI_EDITION_ELEMENT__HELP_ID: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, - true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsEEFAdapterFactory.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsEEFAdapterFactory.java deleted file mode 100644 index 0c8f25cc8..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsEEFAdapterFactory.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.providers; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.notify.Adapter; - -import org.eclipse.emf.eef.components.util.ComponentsAdapterFactory; - -import org.eclipse.emf.eef.mapping.providers.DocumentedElementPropertiesEditionProvider; -import org.eclipse.emf.eef.mapping.providers.EMFElementBindingPropertiesEditionProvider; -import org.eclipse.emf.eef.mapping.providers.EMFMultiPropertiesBindingPropertiesEditionProvider; -import org.eclipse.emf.eef.mapping.providers.EMFPropertyBindingPropertiesEditionProvider; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -/** - * @author Nathalie Lepine - * - */ -public class ComponentsEEFAdapterFactory extends ComponentsAdapterFactory { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.components.util.ComponentsAdapterFactory#createDocumentedElementAdapter() - * - */ - public Adapter createDocumentedElementAdapter() { - return new DocumentedElementPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.components.util.ComponentsAdapterFactory#createPropertiesEditionContextAdapter() - * - */ - public Adapter createPropertiesEditionContextAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new PropertiesEditionContextPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.components.util.ComponentsAdapterFactory#createEMFElementBindingAdapter() - * - */ - public Adapter createEMFElementBindingAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new EMFElementBindingPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.components.util.ComponentsAdapterFactory#createPropertiesEditionComponentAdapter() - * - */ - public Adapter createPropertiesEditionComponentAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new PropertiesEditionComponentPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.components.util.ComponentsAdapterFactory#createEMFPropertyBindingAdapter() - * - */ - public Adapter createEMFPropertyBindingAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new EMFPropertyBindingPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.components.util.ComponentsAdapterFactory#createPropertiesEditionElementAdapter() - * - */ - public Adapter createPropertiesEditionElementAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new PropertiesEditionElementPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.components.util.ComponentsAdapterFactory#createEMFMultiPropertiesBindingAdapter() - * - */ - public Adapter createEMFMultiPropertiesBindingAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new EMFMultiPropertiesBindingPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.components.util.ComponentsAdapterFactory#createPropertiesMultiEditionElementAdapter() - * - */ - public Adapter createPropertiesMultiEditionElementAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new PropertiesMultiEditionElementPropertiesEditionProvider(providers); - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsMessages.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsMessages.java deleted file mode 100644 index 4735b79ce..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsMessages.java +++ /dev/null @@ -1,174 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.providers; - -import org.eclipse.osgi.util.NLS; - -/** - * @author Nathalie Lepine - * - */ -public class ComponentsMessages extends NLS { - - private static final String BUNDLE_NAME = "org.eclipse.emf.eef.components.providers.componentsMessages"; //$NON-NLS-1$ - - - public static String PropertiesEditionContextPropertiesEditionPart_BindingGroupLabel; - - - public static String PropertiesEditionComponentPropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesEditionComponentPropertiesEditionPart_BindingGroupLabel; - - - public static String PropertiesEditionElementPropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesEditionElementPropertiesEditionPart_BindingGroupLabel; - - - public static String PropertiesMultiEditionElementPropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesMultiEditionElementPropertiesEditionPart_BindingGroupLabel; - - - - public static String PropertiesEditionContext_ReadOnly; - - - public static String PropertiesEditionContext_Part_Title; - - - public static String PropertiesEditionComponent_ReadOnly; - - - public static String PropertiesEditionComponent_Part_Title; - - - public static String PropertiesEditionElement_ReadOnly; - - - public static String PropertiesEditionElement_Part_Title; - - - public static String PropertiesMultiEditionElement_ReadOnly; - - - public static String PropertiesMultiEditionElement_Part_Title; - - - - public static String PropertiesEditionContextPropertiesEditionPart_ModelLabel; - - - public static String PropertiesEditionComponentPropertiesEditionPart_NameLabel; - - - public static String PropertiesEditionComponentPropertiesEditionPart_HelpIDLabel; - - - public static String PropertiesEditionComponentPropertiesEditionPart_ExplicitLabel; - - - public static String PropertiesEditionComponentPropertiesEditionPart_ModelLabel; - - - public static String PropertiesEditionComponentPropertiesEditionPart_ViewsLabel; - - - public static String PropertiesEditionElementPropertiesEditionPart_NameLabel; - - - public static String PropertiesEditionElementPropertiesEditionPart_HelpIDLabel; - - - public static String PropertiesEditionElementPropertiesEditionPart_ModelLabel; - - - public static String PropertiesEditionElementPropertiesEditionPart_ViewsLabel; - - - public static String PropertiesMultiEditionElementPropertiesEditionPart_NameLabel; - - - public static String PropertiesMultiEditionElementPropertiesEditionPart_HelpIDLabel; - - - public static String PropertiesMultiEditionElementPropertiesEditionPart_ModelLabel; - - - public static String PropertiesMultiEditionElementPropertiesEditionPart_ViewsLabel; - - - - public static String PropertiesEditionPart_DocumentationLabel; - - - public static String PropertiesEditionPart_IntegerValueMessage; - - - public static String PropertiesEditionPart_FloatValueMessage; - - - public static String PropertiesEditionPart_ShortValueMessage; - - - public static String PropertiesEditionPart_LongValueMessage; - - - public static String PropertiesEditionPart_ByteValueMessage; - - - public static String PropertiesEditionPart_BigIntegerValueMessage; - - - public static String PropertiesEditionPart_BigDecimalValueMessage; - - - public static String PropertiesEditionPart_DoubleValueMessage; - - - public static String PropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesEditionPart_RequiredFeatureMessage; - - - public static String PropertiesEditionPart_AddTableViewerLabel; - - - public static String PropertiesEditionPart_EditTableViewerLabel; - - - public static String PropertiesEditionPart_RemoveTableViewerLabel; - - - public static String PropertiesEditionPart_AddListViewerLabel; - - - public static String PropertiesEditionPart_RemoveListViewerLabel; - - // Start of user code for additionnal NLS Constants - - // End of user code - - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, ComponentsMessages.class); - } - - - private ComponentsMessages() { - //protect instanciation - } -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsPropertiesEditionPartProvider.java deleted file mode 100644 index 087e4acdf..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/ComponentsPropertiesEditionPartProvider.java +++ /dev/null @@ -1,79 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.providers; - -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; - -import org.eclipse.emf.eef.components.parts.forms.PropertiesEditionComponentPropertiesEditionPartForm; -import org.eclipse.emf.eef.components.parts.forms.PropertiesEditionContextPropertiesEditionPartForm; -import org.eclipse.emf.eef.components.parts.forms.PropertiesEditionElementPropertiesEditionPartForm; -import org.eclipse.emf.eef.components.parts.forms.PropertiesMultiEditionElementPropertiesEditionPartForm; - -import org.eclipse.emf.eef.components.parts.impl.PropertiesEditionComponentPropertiesEditionPartImpl; -import org.eclipse.emf.eef.components.parts.impl.PropertiesEditionContextPropertiesEditionPartImpl; -import org.eclipse.emf.eef.components.parts.impl.PropertiesEditionElementPropertiesEditionPartImpl; -import org.eclipse.emf.eef.components.parts.impl.PropertiesMultiEditionElementPropertiesEditionPartImpl; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; - -/** - * @author Nathalie Lepine - * - */ -public class ComponentsPropertiesEditionPartProvider implements IPropertiesEditionPartProvider { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#provides(java.lang.Object) - * - */ - public boolean provides(Object key) { - return key == ComponentsViewsRepository.class; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#getPropertiesEditionPart(java.lang.Object, int, org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, IPropertiesEditionComponent component) { - if (key == ComponentsViewsRepository.PropertiesEditionContext.class) { - if (kind == ComponentsViewsRepository.SWT_KIND) - return new PropertiesEditionContextPropertiesEditionPartImpl(component); - if (kind == ComponentsViewsRepository.FORM_KIND) - return new PropertiesEditionContextPropertiesEditionPartForm(component); - } - if (key == ComponentsViewsRepository.PropertiesEditionComponent.class) { - if (kind == ComponentsViewsRepository.SWT_KIND) - return new PropertiesEditionComponentPropertiesEditionPartImpl(component); - if (kind == ComponentsViewsRepository.FORM_KIND) - return new PropertiesEditionComponentPropertiesEditionPartForm(component); - } - if (key == ComponentsViewsRepository.PropertiesEditionElement.class) { - if (kind == ComponentsViewsRepository.SWT_KIND) - return new PropertiesEditionElementPropertiesEditionPartImpl(component); - if (kind == ComponentsViewsRepository.FORM_KIND) - return new PropertiesEditionElementPropertiesEditionPartForm(component); - } - if (key == ComponentsViewsRepository.PropertiesMultiEditionElement.class) { - if (kind == ComponentsViewsRepository.SWT_KIND) - return new PropertiesMultiEditionElementPropertiesEditionPartImpl(component); - if (kind == ComponentsViewsRepository.FORM_KIND) - return new PropertiesMultiEditionElementPropertiesEditionPartForm(component); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionComponentPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionComponentPropertiesEditionProvider.java deleted file mode 100644 index 50cb9492f..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionComponentPropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; - -import org.eclipse.emf.eef.components.components.PropertiesEditionComponentBasePropertiesEditionComponent; -import org.eclipse.emf.eef.components.components.PropertiesEditionComponentPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionComponentPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public PropertiesEditionComponentPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public PropertiesEditionComponentPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof PropertiesEditionComponent) - && (ComponentsPackage.Literals.PROPERTIES_EDITION_COMPONENT == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof PropertiesEditionComponent) && (PropertiesEditionComponentBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof PropertiesEditionComponent) && (refinement == PropertiesEditionComponentBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof PropertiesEditionComponent) && ((PropertiesEditionComponentBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == PropertiesEditionComponentBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof PropertiesEditionComponent) { - return new PropertiesEditionComponentPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof PropertiesEditionComponent) { - if (PropertiesEditionComponentBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new PropertiesEditionComponentBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof PropertiesEditionComponent) { - if (PropertiesEditionComponentBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == PropertiesEditionComponentBasePropertiesEditionComponent.class) - return new PropertiesEditionComponentBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && ComponentsPackage.Literals.PROPERTIES_EDITION_COMPONENT == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionContextPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionContextPropertiesEditionProvider.java deleted file mode 100644 index fa674ddf8..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionContextPropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionContext; - -import org.eclipse.emf.eef.components.components.PropertiesEditionContextBasePropertiesEditionComponent; -import org.eclipse.emf.eef.components.components.PropertiesEditionContextPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionContextPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public PropertiesEditionContextPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public PropertiesEditionContextPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof PropertiesEditionContext) - && (ComponentsPackage.Literals.PROPERTIES_EDITION_CONTEXT == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof PropertiesEditionContext) && (PropertiesEditionContextBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof PropertiesEditionContext) && (refinement == PropertiesEditionContextBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof PropertiesEditionContext) && ((PropertiesEditionContextBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == PropertiesEditionContextBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof PropertiesEditionContext) { - return new PropertiesEditionContextPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof PropertiesEditionContext) { - if (PropertiesEditionContextBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new PropertiesEditionContextBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof PropertiesEditionContext) { - if (PropertiesEditionContextBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == PropertiesEditionContextBasePropertiesEditionComponent.class) - return new PropertiesEditionContextBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && ComponentsPackage.Literals.PROPERTIES_EDITION_CONTEXT == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionElementPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionElementPropertiesEditionProvider.java deleted file mode 100644 index 2efb26c0d..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesEditionElementPropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionElement; - -import org.eclipse.emf.eef.components.components.PropertiesEditionElementBasePropertiesEditionComponent; -import org.eclipse.emf.eef.components.components.PropertiesEditionElementPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesEditionElementPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public PropertiesEditionElementPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public PropertiesEditionElementPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof PropertiesEditionElement) - && (ComponentsPackage.Literals.PROPERTIES_EDITION_ELEMENT == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof PropertiesEditionElement) && (PropertiesEditionElementBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof PropertiesEditionElement) && (refinement == PropertiesEditionElementBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof PropertiesEditionElement) && ((PropertiesEditionElementBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == PropertiesEditionElementBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof PropertiesEditionElement) { - return new PropertiesEditionElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof PropertiesEditionElement) { - if (PropertiesEditionElementBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new PropertiesEditionElementBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof PropertiesEditionElement) { - if (PropertiesEditionElementBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == PropertiesEditionElementBasePropertiesEditionComponent.class) - return new PropertiesEditionElementBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && ComponentsPackage.Literals.PROPERTIES_EDITION_ELEMENT == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesMultiEditionElementPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesMultiEditionElementPropertiesEditionProvider.java deleted file mode 100644 index a94477801..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/PropertiesMultiEditionElementPropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesMultiEditionElement; - -import org.eclipse.emf.eef.components.components.PropertiesMultiEditionElementBasePropertiesEditionComponent; -import org.eclipse.emf.eef.components.components.PropertiesMultiEditionElementPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class PropertiesMultiEditionElementPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public PropertiesMultiEditionElementPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public PropertiesMultiEditionElementPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof PropertiesMultiEditionElement) - && (ComponentsPackage.Literals.PROPERTIES_MULTI_EDITION_ELEMENT == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof PropertiesMultiEditionElement) && (PropertiesMultiEditionElementBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof PropertiesMultiEditionElement) && (refinement == PropertiesMultiEditionElementBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof PropertiesMultiEditionElement) && ((PropertiesMultiEditionElementBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == PropertiesMultiEditionElementBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof PropertiesMultiEditionElement) { - return new PropertiesMultiEditionElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof PropertiesMultiEditionElement) { - if (PropertiesMultiEditionElementBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new PropertiesMultiEditionElementBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof PropertiesMultiEditionElement) { - if (PropertiesMultiEditionElementBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == PropertiesMultiEditionElementBasePropertiesEditionComponent.class) - return new PropertiesMultiEditionElementBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && ComponentsPackage.Literals.PROPERTIES_MULTI_EDITION_ELEMENT == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/componentsMessages.properties b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/componentsMessages.properties deleted file mode 100644 index 45e69c1b5..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/componentsMessages.properties +++ /dev/null @@ -1,61 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -#End of user code - -# default values ... -PropertiesEditionContextPropertiesEditionPart_BindingGroupLabel=Binding -PropertiesEditionComponentPropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionComponentPropertiesEditionPart_BindingGroupLabel=Binding -PropertiesEditionElementPropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionElementPropertiesEditionPart_BindingGroupLabel=Binding -PropertiesMultiEditionElementPropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesMultiEditionElementPropertiesEditionPart_BindingGroupLabel=Binding -PropertiesEditionContext_ReadOnly=This property is read only -PropertiesEditionContext_Part_Title=Base -PropertiesEditionComponent_ReadOnly=This property is read only -PropertiesEditionComponent_Part_Title=Base -PropertiesEditionElement_ReadOnly=This property is read only -PropertiesEditionElement_Part_Title=Base -PropertiesMultiEditionElement_ReadOnly=This property is read only -PropertiesMultiEditionElement_Part_Title=Base -PropertiesEditionContextPropertiesEditionPart_ModelLabel=Model : -PropertiesEditionComponentPropertiesEditionPart_NameLabel=Name : -PropertiesEditionComponentPropertiesEditionPart_HelpIDLabel=HelpID : -PropertiesEditionComponentPropertiesEditionPart_ExplicitLabel=Explicit -PropertiesEditionComponentPropertiesEditionPart_ModelLabel=Model : -PropertiesEditionComponentPropertiesEditionPart_ViewsLabel=Views : -PropertiesEditionElementPropertiesEditionPart_NameLabel=Name : -PropertiesEditionElementPropertiesEditionPart_HelpIDLabel=HelpID : -PropertiesEditionElementPropertiesEditionPart_ModelLabel=Model : -PropertiesEditionElementPropertiesEditionPart_ViewsLabel=Views : -PropertiesMultiEditionElementPropertiesEditionPart_NameLabel=Name : -PropertiesMultiEditionElementPropertiesEditionPart_HelpIDLabel=HelpID : -PropertiesMultiEditionElementPropertiesEditionPart_ModelLabel=Model : -PropertiesMultiEditionElementPropertiesEditionPart_ViewsLabel=Views : -PropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionPart_EditTableViewerLabel=Edit -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=The property {0} of the object shall be filled -PropertiesEditionPart_RemoveTableViewerLabel=Delete -PropertiesEditionPart_RemoveListViewerLabel=Delete -PropertiesEditionPart_IntegerValueMessage=The property {0} shall be an integer -PropertiesEditionPart_FloatValueMessage=The property {0} shall be a float -PropertiesEditionPart_ShortValueMessage=The property {0} shall be a short -PropertiesEditionPart_DoubleValueMessage=The property {0} shall be a double -PropertiesEditionPart_ByteValueMessage=The property {0} shall be a byte -PropertiesEditionPart_LongValueMessage=The property {0} shall be a long -PropertiesEditionPart_BigIntegerValueMessage=The property {0} shall be a BigInteger -PropertiesEditionPart_BigDecimalValueMessage=The property {0} shall be a BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Add -PropertiesEditionPart_AddListViewerLabel=Add diff --git a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/componentsMessages_fr.properties b/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/componentsMessages_fr.properties deleted file mode 100644 index 2cac00a23..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src-gen/org/eclipse/emf/eef/components/providers/componentsMessages_fr.properties +++ /dev/null @@ -1,61 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -PropertiesEditionContextPropertiesEditionPart_BindingGroupLabel=Binding -PropertiesEditionComponentPropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionComponentPropertiesEditionPart_BindingGroupLabel=Binding -PropertiesEditionElementPropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionElementPropertiesEditionPart_BindingGroupLabel=Binding -PropertiesMultiEditionElementPropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesMultiEditionElementPropertiesEditionPart_BindingGroupLabel=Binding -PropertiesEditionContext_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -PropertiesEditionContext_Part_Title=Base -PropertiesEditionComponent_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -PropertiesEditionComponent_Part_Title=Base -PropertiesEditionElement_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -PropertiesEditionElement_Part_Title=Base -PropertiesMultiEditionElement_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -PropertiesMultiEditionElement_Part_Title=Base -PropertiesEditionContextPropertiesEditionPart_ModelLabel=Model : -PropertiesEditionComponentPropertiesEditionPart_NameLabel=Name : -PropertiesEditionComponentPropertiesEditionPart_HelpIDLabel=HelpID : -PropertiesEditionComponentPropertiesEditionPart_ExplicitLabel=Explicit -PropertiesEditionComponentPropertiesEditionPart_ModelLabel=Model : -PropertiesEditionComponentPropertiesEditionPart_ViewsLabel=Views : -PropertiesEditionElementPropertiesEditionPart_NameLabel=Name : -PropertiesEditionElementPropertiesEditionPart_HelpIDLabel=HelpID : -PropertiesEditionElementPropertiesEditionPart_ModelLabel=Model : -PropertiesEditionElementPropertiesEditionPart_ViewsLabel=Views : -PropertiesMultiEditionElementPropertiesEditionPart_NameLabel=Name : -PropertiesMultiEditionElementPropertiesEditionPart_HelpIDLabel=HelpID : -PropertiesMultiEditionElementPropertiesEditionPart_ModelLabel=Model : -PropertiesMultiEditionElementPropertiesEditionPart_ViewsLabel=Views : -PropertiesEditionPart_PropertiesGroupLabel=Propri\u00E9t\u00E9s -PropertiesEditionPart_EditTableViewerLabel=Editer -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=La propri\u00E9t\u00E9 {0} de l\u0027objet doit \u00EAtre renseign\u00E9e -PropertiesEditionPart_RemoveTableViewerLabel=Supprimer -PropertiesEditionPart_RemoveListViewerLabel=Supprimer -PropertiesEditionPart_IntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un entier -PropertiesEditionPart_FloatValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un flottant -PropertiesEditionPart_ShortValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un short -PropertiesEditionPart_DoubleValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un double -PropertiesEditionPart_ByteValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un byte -PropertiesEditionPart_LongValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un long -PropertiesEditionPart_BigIntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigInteger -PropertiesEditionPart_BigDecimalValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Ajouter -PropertiesEditionPart_AddListViewerLabel=Ajouter diff --git a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionElementCustomPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionElementCustomPropertiesEditionPartForm.java deleted file mode 100644 index c663e544f..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/parts/forms/PropertiesEditionElementCustomPropertiesEditionPartForm.java +++ /dev/null @@ -1,42 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.parts.forms; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.jface.viewers.StructuredSelection; - -/** - * @author Goulwen Le Fur - */ -public class PropertiesEditionElementCustomPropertiesEditionPartForm extends PropertiesEditionElementPropertiesEditionPartForm { - - public PropertiesEditionElementCustomPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.forms.PropertiesEditionElementPropertiesEditionPartForm#initModel(org.eclipse.emf.ecore.resource.ResourceSet, - * org.eclipse.emf.ecore.EObject) - */ - public void initModel(ResourceSet allResources, EObject current) { - model.setInput(EEFUtils.choiceOfValues(this.current, MappingPackage.eINSTANCE.getEMFPropertyBinding_Model())); - if (current != null) { - model.setSelection(new StructuredSelection(current)); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionElementCustomPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionElementCustomPropertiesEditionPartImpl.java deleted file mode 100644 index c30f34642..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/parts/impl/PropertiesEditionElementCustomPropertiesEditionPartImpl.java +++ /dev/null @@ -1,48 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.components.parts.impl; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.jface.viewers.StructuredSelection; - -/** - * @author Goulwen Le Fur - */ -public class PropertiesEditionElementCustomPropertiesEditionPartImpl extends PropertiesEditionElementPropertiesEditionPartImpl { - - /** - * @param editionComponent - */ - public PropertiesEditionElementCustomPropertiesEditionPartImpl( - IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.components.parts.forms.PropertiesEditionElementPropertiesEditionPartForm#initModel(org.eclipse.emf.ecore.resource.ResourceSet, - * org.eclipse.emf.ecore.EObject) - */ - public void initModel(ResourceSet allResources, EObject current) { - model.setInput(EEFUtils.choiceOfValues(this.current, MappingPackage.eINSTANCE - .getEMFPropertyBinding_Model())); - if (current != null) { - model.setSelection(new StructuredSelection(current)); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/providers/ComponentsCustomPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/providers/ComponentsCustomPropertiesEditionPartProvider.java deleted file mode 100644 index 4d7d0d0a8..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/providers/ComponentsCustomPropertiesEditionPartProvider.java +++ /dev/null @@ -1,36 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.providers; - -import org.eclipse.emf.eef.components.parts.ComponentsViewsRepository; -import org.eclipse.emf.eef.components.parts.forms.PropertiesEditionElementCustomPropertiesEditionPartForm; -import org.eclipse.emf.eef.components.parts.impl.PropertiesEditionElementCustomPropertiesEditionPartImpl; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -/** - * @author Nathalie Lepine - */ -public class ComponentsCustomPropertiesEditionPartProvider extends ComponentsPropertiesEditionPartProvider { - - @Override - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, - IPropertiesEditionComponent component) { - if (key == ComponentsViewsRepository.PropertiesEditionElement.class) { - if (kind == ComponentsViewsRepository.SWT_KIND) - return new PropertiesEditionElementCustomPropertiesEditionPartImpl(component); - if (kind == ComponentsViewsRepository.FORM_KIND) - return new PropertiesEditionElementCustomPropertiesEditionPartForm(component); - } - return super.getPropertiesEditionPart(key, kind, component); - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/resources/ComponentsResource.java b/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/resources/ComponentsResource.java deleted file mode 100644 index 77b35c879..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/resources/ComponentsResource.java +++ /dev/null @@ -1,64 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.resources; - -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.xmi.XMLHelper; -import org.eclipse.emf.ecore.xmi.impl.XMIHelperImpl; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceImpl; - -/** - * @author Goulwen Le Fur - */ -public class ComponentsResource extends XMIResourceImpl { - - /** - * - */ - public ComponentsResource() { - } - - /** - * @param uri - */ - public ComponentsResource(URI uri) { - super(uri); - } - - @Override - protected boolean useUUIDs() { - return true; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.ecore.xmi.impl.XMIResourceImpl#createXMLHelper() - */ - @Override - protected XMLHelper createXMLHelper() { - return new XMIHelperImpl(this) { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.ecore.xmi.impl.XMLHelperImpl#deresolve(org.eclipse.emf.common.util.URI) - */ - @Override - public URI deresolve(URI uri) { - return uri; - } - - }; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/resources/ComponentsResourceFactory.java b/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/resources/ComponentsResourceFactory.java deleted file mode 100644 index 64375e49b..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/resources/ComponentsResourceFactory.java +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.resources; - -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; - - -/** - * @author Goulwen Le Fur - */ -public class ComponentsResourceFactory extends XMIResourceFactoryImpl { - - @Override - public Resource createResource(URI uri) { - return new ComponentsResource(uri); - } - - - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/validation/BadReferencedEditorConstraint.java b/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/validation/BadReferencedEditorConstraint.java deleted file mode 100644 index 964e95d24..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/components/validation/BadReferencedEditorConstraint.java +++ /dev/null @@ -1,78 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.validation; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.views.Container; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewElement; -import org.eclipse.emf.validation.AbstractModelConstraint; -import org.eclipse.emf.validation.EMFEventType; -import org.eclipse.emf.validation.IValidationContext; - -/** - * @author Stephane Bouchet - */ -public class BadReferencedEditorConstraint extends AbstractModelConstraint { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.validation.AbstractModelConstraint#validate(org.eclipse.emf.validation.IValidationContext) - */ - @Override - public IStatus validate(IValidationContext ctx) { - EObject eObj = ctx.getTarget(); - EMFEventType eType = ctx.getEventType(); - // In the case of batch mode. - if (eType == EMFEventType.NULL) { - if (eObj instanceof PropertiesEditionElement) { - for (ElementEditor elementEditor : ((PropertiesEditionElement)eObj).getViews()) { - if (!existElementEditorInInvolvedViews((PropertiesEditionComponent)eObj.eContainer(), - elementEditor)) - return ctx.createFailureStatus(new Object[] {elementEditor, - ((PropertiesEditionElement)eObj).getName()}); - } - } - } - return ctx.createSuccessStatus(); - } - - /** - * @param obj - * @return - */ - private boolean existElementEditorInInvolvedViews(PropertiesEditionComponent pec, - ElementEditor elementEditor) { - for (View view : pec.getViews()) { - for (ViewElement viewElement : view.getElements()) - if (existElementEditorInViewElements(viewElement, elementEditor)) - return true; - } - return false; - } - - private boolean existElementEditorInViewElements(ViewElement viewElement, ElementEditor elementEditor) { - if (viewElement.equals(elementEditor)) - return true; - if (viewElement instanceof Container) { - for (ViewElement ve2 : ((Container)viewElement).getElements()) { - if (existElementEditorInViewElements(ve2, elementEditor)) - return true; - } - } - return false; - } -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/mapping/provider/CategoryCustomItemProvider.java b/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/mapping/provider/CategoryCustomItemProvider.java deleted file mode 100644 index bd91f5bb5..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/mapping/provider/CategoryCustomItemProvider.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.eef.mapping.MappingFactory; -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.Category} object. - * - * - * @generated - */ -public class CategoryCustomItemProvider extends CategoryItemProvider { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public CategoryCustomItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.CATEGORY__CATEGORIES, - MappingFactory.eINSTANCE.createCategory())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/mapping/provider/MappingCustomItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/mapping/provider/MappingCustomItemProviderAdapterFactory.java deleted file mode 100644 index 6ef1fcf5f..000000000 --- a/plugins/org.eclipse.emf.eef.components.edit/src/org/eclipse/emf/eef/mapping/provider/MappingCustomItemProviderAdapterFactory.java +++ /dev/null @@ -1,35 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import org.eclipse.emf.common.notify.Adapter; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class MappingCustomItemProviderAdapterFactory extends MappingItemProviderAdapterFactory { - - @Override - public Adapter createCategoryAdapter() { - if (categoryItemProvider == null) { - categoryItemProvider = new CategoryCustomItemProvider(this); - } - - return categoryItemProvider; - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.editor/.checkstyle b/plugins/org.eclipse.emf.eef.components.editor/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components.editor/.classpath b/plugins/org.eclipse.emf.eef.components.editor/.classpath deleted file mode 100644 index f9c46b584..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components.editor/.gitignore b/plugins/org.eclipse.emf.eef.components.editor/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.components.editor/.project b/plugins/org.eclipse.emf.eef.components.editor/.project deleted file mode 100644 index 7403c7df0..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.components.editor - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.components.editor/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.components.editor/META-INF/MANIFEST.MF deleted file mode 100644 index 8324c11e0..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/META-INF/MANIFEST.MF +++ /dev/null @@ -1,22 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Components Editor -Bundle-SymbolicName: org.eclipse.emf.eef.components.editor;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Activator: org.eclipse.emf.eef.components.presentation.ComponentsEditorPlugin$Implementation -Bundle-Vendor: Eclipse Modeling Project -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.components.presentation -Require-Bundle: org.eclipse.ui.ide;bundle-version="3.4.0";visibility:=reexport, - org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.core.resources;bundle-version="3.4.0";visibility:=reexport, - org.eclipse.emf.edit.ui;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.ecore.xmi;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.ecore.edit;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.codegen.ecore.ui;bundle-version="2.4.0", - org.eclipse.emf.eef.components.edit;visibility:=reexport, - org.eclipse.emf.eef.mapping.edit;visibility:=reexport, - org.eclipse.emf.eef.views.edit;visibility:=reexport -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.components.editor/about.html b/plugins/org.eclipse.emf.eef.components.editor/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.components.editor/build.properties b/plugins/org.eclipse.emf.eef.components.editor/build.properties deleted file mode 100644 index 1b789c93a..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/build.properties +++ /dev/null @@ -1,21 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -bin.includes = .,\ - icons/,\ - META-INF/,\ - plugin.xml,\ - plugin.properties,\ - about.html -jars.compile.order = . -source.. = src-gen/ -output.. = bin/ -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.components.editor/icons/full/obj16/ComponentsModelFile.gif b/plugins/org.eclipse.emf.eef.components.editor/icons/full/obj16/ComponentsModelFile.gif deleted file mode 100644 index 33be7d827dc3962ea74fb6a0c180c45b1dd896af..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 617 zcmZ?wbhEHb6krfwc*el+@8AE7vPn4={n-^03ah)l^A{IX_vnQ88%9quPnc$vJi|71 zmP5u|$Bely+4J3V7kU*e_AOrKU$Wf4ba`Oe3hl67o$y}0$O(oqlZ<008^=vHOPFQ} z)Ri{NrEFD2ecSK9|Ns8`zw7GT6{lZry!hte&3Artt_IJ$mb&6r-rBoWoA1v#_PnB@ zEoRA$mfepg9(wZO=l?Ii{~tYd_UGUKS3muK^Yj0w-~X?E{=f0)+1Ee+zx?_C!|(s^ ze*gde_y6yI|KI%n|MTDfzyJUL`~SbTxv93fv9+_Nt)r&5r=q{NeA=YqxzqBN&&gOk zGkej@?EnA&GYmeU_>+Z^fx(YK2jnzRoG`E-Yw#0g7nhKdmXYP*<7X8V7V(o)Q`gnd z)Y8+}R#s6`ohT|M&LPRk#m(CzASg7^+kE4u&E_U1-hLabc3T;ViW=>)+Tmk|gH!t&5w#1e@$O~jH| zE3r#rtBR6D7#fYJM2Qp;G?p$#XUw>N#eL6n-XFj7eCK?ht-XzzxvwMO2H-PbFT1ZBl3O9g&W~^|k8rNx&)gyjZjpG87@|i^>4Ug(@AyieJu2Xdq=4kA zpp=@>w7T$&=Mfq8(Z5q3XE!FGn}5T${)TBuE2bffX{ge!tkP}_sSmryi^A%DT-^Y! zj!9@3ENf(y?=eJf;ndSdsa<0Vp4Giz9^{>8;i+mH7L=k(d$XCGJIH~-4q)k2?*2zXfQw~D2oJNF~cj2 zIN9k!NW#aSG00c}(O3S;HqS`EWsndGGV23CzB-?=hZ+Suh8bx;UYg64>ucD@so9u& zDyUs37o+A?-N7+l25e%AuYMKs(6?rFq~9z!3w;V_9^$INnqlUM;)#^)nVWtmBl-*z zi|n<2KUmEM;MKm;E5T3uQ*lO}pu;eQ9_@Tksdt8r12K_WDXj)lJG4X9sRs3^r$v_l zMhpms3k50ZWs?hxcDIjIoB>X z!&pBy1T!Ov9G$dgI$!c5(_@3+4JhV*>oBqfiKY9HoP zXj7rkT{$+Pxq-rigr6m}cUw*W8H-jMXlR>BDd#)#d z8*g=hF-7v^BHo7%S(^#nhezZbx)vBBt->c?TF$o^b3b3+ma{nRHnbKmzNrRI_`r~j z?$DmADSn+zkGt}d2&ihMGN0?+u=5)GS@j8k=|jw4XgW~_6_tNa{!1i6_gK6TyZt<7 z^0Le8uP&A61nI7q6>F#Z$P3nZ<31^F)C7bmIq&QkD2p!9yKwQklYcmT*WuacFCCqY zVEO6y3R;SjG-cb8CghO|70Rbe)V&Inoi($|B$rqfTS7mL;d>h315M03I=<=GKw`aJ zgrNU;u8Ol3`FmB%GwLLel_vFi>X90|n+BIo0ntwe4tCIA*#xd5*(aW=cz~z1uYIG9Z)WLT zU}Ew@ZA`OG*!Eg;SlipW!w1B+#s=t^bPtl2rJ%^#VWXfHrf-<#!-n0J-vvr<4*h)$ z;M~m4I02R1g4J=nh}c53ki>k5bL>0F2`6bQ9gbrIyekhK89`KobL2|k`?9;MrcaHR z$S0i*S~KRe(oHn_vI9&=ghkk*`A9qmwgE(-tXMxrnmZU?)XA}TsD94J?fx8H*-GHS z`YjkXZOG8*B5$el76^CkqoR(6#I?p6r|XoWoDgN+)nwDTahl|I;HAn`@`DG z(Au@#)a@qZ*Bixj?L51Ei}n73t!h~k_)zT~$`plLRj3ED^!H$m=DBLx-N~>Yjz^aM z07?}Q+%*2PAC&py#1D5>4QEpiW|OJWxp{W?h=0aeCL9GH!`{1bCtd5cAF8Efzj?jA zJ`VYvi&KM2$UWB`*Svk?i<&)v44-cu1^rr|nlg@lbIpx}bOER~`soK=#%pBl0|AZ| zvWMY1q~ehUePDtw3~G&694z@%P?duu3X85xHMdo18yJoX^zPVX?Be1MBMz40Fl5hv56uog;MqW?j@z z(X4fSDdX`ok2lJh7a97;5oz1ip-lUlIc5J&ioPtwS6bw^yunzh!2BJPNN@SOp!?m# WnpT>px2$#`csply@qoHIz~Uc@0mY>N diff --git a/plugins/org.eclipse.emf.eef.components.editor/plugin.properties b/plugins/org.eclipse.emf.eef.components.editor/plugin.properties deleted file mode 100644 index 86a20a297..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/plugin.properties +++ /dev/null @@ -1,58 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -_UI_ComponentsEditor_menu = &EEF Components Editor - -_UI_CreateChild_menu_item = &New Child -_UI_CreateSibling_menu_item = N&ew Sibling - -_UI_ShowPropertiesView_menu_item = Show &Properties View -_UI_RefreshViewer_menu_item = &Refresh - -_UI_SelectionPage_label = Selection -_UI_ParentPage_label = Parent -_UI_ListPage_label = List -_UI_TreePage_label = Tree -_UI_TablePage_label = Table -_UI_TreeWithColumnsPage_label = Tree with Columns -_UI_ObjectColumn_label = Object -_UI_SelfColumn_label = Self - -_UI_NoObjectSelected = Selected Nothing -_UI_SingleObjectSelected = Selected Object: {0} -_UI_MultiObjectSelected = Selected {0} Objects - -_UI_OpenEditorError_label = Open Editor - -_UI_Wizard_category = EMF Editing Framework - -_UI_CreateModelError_message = Problems encountered in file "{0}" - -_UI_ComponentsModelWizard_label = EEF Components Model -_UI_ComponentsModelWizard_description = Create a new EEF Components model - -_UI_ComponentsEditor_label = EEF Components Model Editor - -_UI_ComponentsEditorFilenameDefaultBase = My -_UI_ComponentsEditorFilenameExtensions = components - -_UI_Wizard_label = New - -_WARN_FilenameExtension = The file name must end in ''.{0}'' -_WARN_FilenameExtensions = The file name must have one of the following extensions: {0} - -_UI_ModelObject = &Model Object -_UI_XMLEncoding = &XML Encoding -_UI_XMLEncodingChoices = UTF-8 ASCII UTF-16 UTF-16BE UTF-16LE ISO-8859-1 -_UI_Wizard_initial_object_description = Select a model object to create - -_UI_FileConflict_label = File Conflict -_WARN_FileConflict = There are unsaved changes that conflict with changes made outside the editor. Do you wish to discard this editor's changes? - diff --git a/plugins/org.eclipse.emf.eef.components.editor/plugin.xml b/plugins/org.eclipse.emf.eef.components.editor/plugin.xml deleted file mode 100644 index bbb0f7262..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/plugin.xml +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - - - - - %_UI_ComponentsModelWizard_description - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components.editor/pom.xml b/plugins/org.eclipse.emf.eef.components.editor/pom.xml deleted file mode 100644 index d25313d35..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/pom.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.components.editor - eclipse-plugin - - EEF Components Editor Plug-in - diff --git a/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsActionBarContributor.java b/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsActionBarContributor.java deleted file mode 100644 index 8c404d352..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsActionBarContributor.java +++ /dev/null @@ -1,428 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.presentation; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.ui.viewer.IViewerProvider; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; -import org.eclipse.emf.edit.ui.action.ControlAction; -import org.eclipse.emf.edit.ui.action.CreateChildAction; -import org.eclipse.emf.edit.ui.action.CreateSiblingAction; -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; -import org.eclipse.emf.edit.ui.action.LoadResourceAction; -import org.eclipse.emf.edit.ui.action.ValidateAction; -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.ActionContributionItem; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.action.IContributionItem; -import org.eclipse.jface.action.IContributionManager; -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.action.SubContributionItem; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.PartInitException; - -/** - * This is the action bar contributor for the Components model editor. - * - * - * @generated - */ -public class ComponentsActionBarContributor extends EditingDomainActionBarContributor implements ISelectionChangedListener { - /** - * This keeps track of the active editor. - * - * - * @generated - */ - protected IEditorPart activeEditorPart; - - /** - * This keeps track of the current selection provider. - * - * - * @generated - */ - protected ISelectionProvider selectionProvider; - - /** - * This action opens the Properties view. - * - * - * @generated - */ - protected IAction showPropertiesViewAction = new Action( - ComponentsEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) { - @Override - public void run() { - try { - getPage().showView("org.eclipse.ui.views.PropertySheet"); - } catch (PartInitException exception) { - ComponentsEditorPlugin.INSTANCE.log(exception); - } - } - }; - - /** - * This action refreshes the viewer of the current editor if the editor - * implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}. - * - * - * @generated - */ - protected IAction refreshViewerAction = new Action( - ComponentsEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) { - @Override - public boolean isEnabled() { - return activeEditorPart instanceof IViewerProvider; - } - - @Override - public void run() { - if (activeEditorPart instanceof IViewerProvider) { - Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer(); - if (viewer != null) { - viewer.refresh(); - } - } - } - }; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected Collection createChildActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateChild actions. - * - * - * @generated - */ - protected IMenuManager createChildMenuManager; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected Collection createSiblingActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateSibling actions. - * - * - * @generated - */ - protected IMenuManager createSiblingMenuManager; - - /** - * This creates an instance of the contributor. - * - * - * @generated - */ - public ComponentsActionBarContributor() { - super(ADDITIONS_LAST_STYLE); - loadResourceAction = new LoadResourceAction(); - validateAction = new ValidateAction(); - controlAction = new ControlAction(); - } - - /** - * This adds Separators for editor additions to the tool bar. - * - * - * @generated - */ - @Override - public void contributeToToolBar(IToolBarManager toolBarManager) { - toolBarManager.add(new Separator("components-settings")); - toolBarManager.add(new Separator("components-additions")); - } - - /** - * This adds to the menu bar a menu and some separators for editor additions, - * as well as the sub-menus for object creation items. - * - * - * @generated - */ - @Override - public void contributeToMenu(IMenuManager menuManager) { - super.contributeToMenu(menuManager); - - IMenuManager submenuManager = new MenuManager( - ComponentsEditorPlugin.INSTANCE.getString("_UI_ComponentsEditor_menu"), - "org.eclipse.emf.eef.componentsMenuID"); - menuManager.insertAfter("additions", submenuManager); - submenuManager.add(new Separator("settings")); - submenuManager.add(new Separator("actions")); - submenuManager.add(new Separator("additions")); - submenuManager.add(new Separator("additions-end")); - - // Prepare for CreateChild item addition or removal. - // - createChildMenuManager = new MenuManager( - ComponentsEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); - submenuManager.insertBefore("additions", createChildMenuManager); - - // Prepare for CreateSibling item addition or removal. - // - createSiblingMenuManager = new MenuManager( - ComponentsEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); - submenuManager.insertBefore("additions", createSiblingMenuManager); - - // Force an update because Eclipse hides empty menus now. - // - submenuManager.addMenuListener(new IMenuListener() { - public void menuAboutToShow(IMenuManager menuManager) { - menuManager.updateAll(true); - } - }); - - addGlobalActions(submenuManager); - } - - /** - * When the active editor changes, this remembers the change and registers with it as a selection provider. - * - * - * @generated - */ - @Override - public void setActiveEditor(IEditorPart part) { - super.setActiveEditor(part); - activeEditorPart = part; - - // Switch to the new selection provider. - // - if (selectionProvider != null) { - selectionProvider.removeSelectionChangedListener(this); - } - if (part == null) { - selectionProvider = null; - } else { - selectionProvider = part.getSite().getSelectionProvider(); - selectionProvider.addSelectionChangedListener(this); - - // Fake a selection changed event to update the menus. - // - if (selectionProvider.getSelection() != null) { - selectionChanged(new SelectionChangedEvent(selectionProvider, - selectionProvider.getSelection())); - } - } - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionChangedListener}, - * handling {@link org.eclipse.jface.viewers.SelectionChangedEvent}s by querying for the children and siblings - * that can be added to the selected object and updating the menus accordingly. - * - * - * @generated - */ - public void selectionChanged(SelectionChangedEvent event) { - // Remove any menu items for old selection. - // - if (createChildMenuManager != null) { - depopulateManager(createChildMenuManager, createChildActions); - } - if (createSiblingMenuManager != null) { - depopulateManager(createSiblingMenuManager, createSiblingActions); - } - - // Query the new selection for appropriate new child/sibling descriptors - // - Collection newChildDescriptors = null; - Collection newSiblingDescriptors = null; - - ISelection selection = event.getSelection(); - if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) { - Object object = ((IStructuredSelection)selection).getFirstElement(); - - EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain(); - - newChildDescriptors = domain.getNewChildDescriptors(object, null); - newSiblingDescriptors = domain.getNewChildDescriptors(null, object); - } - - // Generate actions for selection; populate and redraw the menus. - // - createChildActions = generateCreateChildActions(newChildDescriptors, selection); - createSiblingActions = generateCreateSiblingActions(newSiblingDescriptors, selection); - - if (createChildMenuManager != null) { - populateManager(createChildMenuManager, createChildActions, null); - createChildMenuManager.update(true); - } - if (createSiblingMenuManager != null) { - populateManager(createSiblingMenuManager, createSiblingActions, null); - createSiblingMenuManager.update(true); - } - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateChildAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected Collection generateCreateChildActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateChildAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected Collection generateCreateSiblingActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateSiblingAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This populates the specified manager with {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection, - * by inserting them before the specified contribution item contributionID. - * If contributionID is null, they are simply added. - * - * - * @generated - */ - protected void populateManager(IContributionManager manager, Collection actions, - String contributionID) { - if (actions != null) { - for (IAction action : actions) { - if (contributionID != null) { - manager.insertBefore(contributionID, action); - } else { - manager.add(action); - } - } - } - } - - /** - * This removes from the specified manager all {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection. - * - * - * @generated - */ - protected void depopulateManager(IContributionManager manager, Collection actions) { - if (actions != null) { - IContributionItem[] items = manager.getItems(); - for (int i = 0; i < items.length; i++) { - // Look into SubContributionItems - // - IContributionItem contributionItem = items[i]; - while (contributionItem instanceof SubContributionItem) { - contributionItem = ((SubContributionItem)contributionItem).getInnerItem(); - } - - // Delete the ActionContributionItems with matching action. - // - if (contributionItem instanceof ActionContributionItem) { - IAction action = ((ActionContributionItem)contributionItem).getAction(); - if (actions.contains(action)) { - manager.remove(contributionItem); - } - } - } - } - } - - /** - * This populates the pop-up menu before it appears. - * - * - * @generated - */ - @Override - public void menuAboutToShow(IMenuManager menuManager) { - super.menuAboutToShow(menuManager); - MenuManager submenuManager = null; - - submenuManager = new MenuManager( - ComponentsEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); - populateManager(submenuManager, createChildActions, null); - menuManager.insertBefore("edit", submenuManager); - - submenuManager = new MenuManager( - ComponentsEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); - populateManager(submenuManager, createSiblingActions, null); - menuManager.insertBefore("edit", submenuManager); - } - - /** - * This inserts global actions before the "additions-end" separator. - * - * - * @generated - */ - @Override - protected void addGlobalActions(IMenuManager menuManager) { - menuManager.insertAfter("additions-end", new Separator("ui-actions")); - menuManager.insertAfter("ui-actions", showPropertiesViewAction); - - refreshViewerAction.setEnabled(refreshViewerAction.isEnabled()); - menuManager.insertAfter("ui-actions", refreshViewerAction); - - super.addGlobalActions(menuManager); - } - - /** - * This ensures that a delete action will clean up all references to deleted objects. - * - * - * @generated - */ - @Override - protected boolean removeAllReferencesOnDelete() { - return true; - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsEditor.java b/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsEditor.java deleted file mode 100644 index 543a37da2..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsEditor.java +++ /dev/null @@ -1,1503 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.presentation; - -import java.io.IOException; -import java.io.InputStream; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.EventObject; -import java.util.HashMap; -import java.util.Iterator; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IMarker; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.IResourceChangeEvent; -import org.eclipse.core.resources.IResourceChangeListener; -import org.eclipse.core.resources.IResourceDelta; -import org.eclipse.core.resources.IResourceDeltaVisitor; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelItemProviderAdapterFactory; -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.command.CommandStack; -import org.eclipse.emf.common.command.CommandStackListener; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.ui.MarkerHelper; -import org.eclipse.emf.common.ui.editor.ProblemEditorPart; -import org.eclipse.emf.common.ui.viewer.IViewerProvider; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EValidator; -import org.eclipse.emf.ecore.provider.EcoreItemProviderAdapterFactory; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.EContentAdapter; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; -import org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory; -import org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory; -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; -import org.eclipse.emf.edit.ui.celleditor.AdapterFactoryTreeEditor; -import org.eclipse.emf.edit.ui.dnd.EditingDomainViewerDropAdapter; -import org.eclipse.emf.edit.ui.dnd.LocalTransfer; -import org.eclipse.emf.edit.ui.dnd.ViewerDragAdapter; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.edit.ui.provider.UnwrappingSelectionProvider; -import org.eclipse.emf.edit.ui.util.EditUIMarkerHelper; -import org.eclipse.emf.edit.ui.util.EditUIUtil; -import org.eclipse.emf.eef.components.provider.ComponentsItemProviderAdapterFactory; -import org.eclipse.emf.eef.mapping.filters.provider.FiltersItemProviderAdapterFactory; -import org.eclipse.emf.eef.mapping.navigation.provider.NavigationItemProviderAdapterFactory; -import org.eclipse.emf.eef.mapping.provider.MappingCustomItemProviderAdapterFactory; -import org.eclipse.emf.eef.runtime.ui.notify.OpenWizardOnDoubleClick; -import org.eclipse.emf.eef.toolkits.provider.ToolkitsItemProviderAdapterFactory; -import org.eclipse.emf.eef.views.provider.ViewsItemProviderAdapterFactory; -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IStatusLineManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.dialogs.MessageDialog; -import org.eclipse.jface.dialogs.ProgressMonitorDialog; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.jface.viewers.TreeViewer; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.swt.SWT; -import org.eclipse.swt.custom.CTabFolder; -import org.eclipse.swt.dnd.DND; -import org.eclipse.swt.dnd.Transfer; -import org.eclipse.swt.events.ControlAdapter; -import org.eclipse.swt.events.ControlEvent; -import org.eclipse.swt.graphics.Point; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Menu; -import org.eclipse.swt.widgets.Tree; -import org.eclipse.ui.IActionBars; -import org.eclipse.ui.IEditorInput; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IEditorSite; -import org.eclipse.ui.IPartListener; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.PartInitException; -import org.eclipse.ui.actions.WorkspaceModifyOperation; -import org.eclipse.ui.dialogs.SaveAsDialog; -import org.eclipse.ui.ide.IGotoMarker; -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.MultiPageEditorPart; -import org.eclipse.ui.views.contentoutline.ContentOutline; -import org.eclipse.ui.views.contentoutline.ContentOutlinePage; -import org.eclipse.ui.views.contentoutline.IContentOutlinePage; -import org.eclipse.ui.views.properties.IPropertySheetPage; -import org.eclipse.ui.views.properties.PropertySheet; -import org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; - -/** - * This is an example of a Components model editor. - * - * - * @generated NOT - */ -public class ComponentsEditor extends MultiPageEditorPart implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker, ITabbedPropertySheetPageContributor { - /** - * This keeps track of the editing domain that is used to track all changes to the model. - * - * - * @generated - */ - protected AdapterFactoryEditingDomain editingDomain; - - /** - * This is the one adapter factory used for providing views of the model. - * - * - * @generated - */ - protected ComposedAdapterFactory adapterFactory; - - /** - * This is the content outline page. - * - * - * @generated - */ - protected IContentOutlinePage contentOutlinePage; - - /** - * This is a kludge... - * - * - * @generated - */ - protected IStatusLineManager contentOutlineStatusLineManager; - - /** - * This is the content outline page's viewer. - * - * - * @generated - */ - protected TreeViewer contentOutlineViewer; - - /** - * This is the property sheet page. - * - * - * @generated NOT - */ - protected TabbedPropertySheetPage propertySheetPage; - - /** - * @generated NOT - */ - public static final String PROPERTIES_CONTRIBUTOR = "org.eclipse.emf.eef.properties"; - - /** - * This is the viewer that shadows the selection in the content outline. - * The parent relation must be correctly defined for this to work. - * - * - * @generated - */ - protected TreeViewer selectionViewer; - - /** - * This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer. - * - * - * @generated - */ - protected Viewer currentViewer; - - /** - * This listens to which ever viewer is active. - * - * - * @generated - */ - protected ISelectionChangedListener selectionChangedListener; - - /** - * This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor. - * - * - * @generated - */ - protected Collection selectionChangedListeners = new ArrayList(); - - /** - * This keeps track of the selection of the editor as a whole. - * - * - * @generated - */ - protected ISelection editorSelection = StructuredSelection.EMPTY; - - /** - * The MarkerHelper is responsible for creating workspace resource markers presented - * in Eclipse's Problems View. - * - * - * @generated - */ - protected MarkerHelper markerHelper = new EditUIMarkerHelper(); - - /** - * This listens for when the outline becomes active - * - * - * @generated - */ - protected IPartListener partListener = new IPartListener() { - public void partActivated(IWorkbenchPart p) { - if (p instanceof ContentOutline) { - if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) { - getActionBarContributor().setActiveEditor(ComponentsEditor.this); - - setCurrentViewer(contentOutlineViewer); - } - } else if (p instanceof PropertySheet) { - if (((PropertySheet)p).getCurrentPage() == propertySheetPage) { - getActionBarContributor().setActiveEditor(ComponentsEditor.this); - handleActivate(); - } - } else if (p == ComponentsEditor.this) { - handleActivate(); - } - } - - public void partBroughtToTop(IWorkbenchPart p) { - // Ignore. - } - - public void partClosed(IWorkbenchPart p) { - // Ignore. - } - - public void partDeactivated(IWorkbenchPart p) { - // Ignore. - } - - public void partOpened(IWorkbenchPart p) { - // Ignore. - } - }; - - /** - * Resources that have been removed since last activation. - * - * - * @generated - */ - protected Collection removedResources = new ArrayList(); - - /** - * Resources that have been changed since last activation. - * - * - * @generated - */ - protected Collection changedResources = new ArrayList(); - - /** - * Resources that have been saved. - * - * - * @generated - */ - protected Collection savedResources = new ArrayList(); - - /** - * Map to store the diagnostic associated with a resource. - * - * - * @generated - */ - protected Map resourceToDiagnosticMap = new LinkedHashMap(); - - /** - * Controls whether the problem indication should be updated. - * - * - * @generated - */ - protected boolean updateProblemIndication = true; - - /** - * Adapter used to update the problem indication when resources are demanded loaded. - * - * - * @generated - */ - protected EContentAdapter problemIndicationAdapter = new EContentAdapter() { - @Override - public void notifyChanged(Notification notification) { - if (notification.getNotifier() instanceof Resource) { - switch (notification.getFeatureID(Resource.class)) { - case Resource.RESOURCE__IS_LOADED: - case Resource.RESOURCE__ERRORS: - case Resource.RESOURCE__WARNINGS: { - Resource resource = (Resource)notification.getNotifier(); - Diagnostic diagnostic = analyzeResourceProblems(resource, null); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, diagnostic); - } else { - resourceToDiagnosticMap.remove(resource); - } - - if (updateProblemIndication) { - getSite().getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - break; - } - } - } else { - super.notifyChanged(notification); - } - } - - @Override - protected void setTarget(Resource target) { - basicSetTarget(target); - } - - @Override - protected void unsetTarget(Resource target) { - basicUnsetTarget(target); - } - }; - - /** - * This listens for workspace changes. - * - * - * @generated - */ - protected IResourceChangeListener resourceChangeListener = new IResourceChangeListener() { - public void resourceChanged(IResourceChangeEvent event) { - IResourceDelta delta = event.getDelta(); - try { - class ResourceDeltaVisitor implements IResourceDeltaVisitor { - protected ResourceSet resourceSet = editingDomain.getResourceSet(); - - protected Collection changedResources = new ArrayList(); - - protected Collection removedResources = new ArrayList(); - - public boolean visit(IResourceDelta delta) { - if (delta.getResource().getType() == IResource.FILE) { - if (delta.getKind() == IResourceDelta.REMOVED - || delta.getKind() == IResourceDelta.CHANGED - && delta.getFlags() != IResourceDelta.MARKERS) { - Resource resource = resourceSet.getResource( - URI.createURI(delta.getFullPath().toString()), false); - if (resource != null) { - if (delta.getKind() == IResourceDelta.REMOVED) { - removedResources.add(resource); - } else if (!savedResources.remove(resource)) { - changedResources.add(resource); - } - } - } - } - - return true; - } - - public Collection getChangedResources() { - return changedResources; - } - - public Collection getRemovedResources() { - return removedResources; - } - } - - ResourceDeltaVisitor visitor = new ResourceDeltaVisitor(); - delta.accept(visitor); - - if (!visitor.getRemovedResources().isEmpty()) { - removedResources.addAll(visitor.getRemovedResources()); - if (!isDirty()) { - getSite().getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - getSite().getPage().closeEditor(ComponentsEditor.this, false); - } - }); - } - } - - if (!visitor.getChangedResources().isEmpty()) { - changedResources.addAll(visitor.getChangedResources()); - if (getSite().getPage().getActiveEditor() == ComponentsEditor.this) { - getSite().getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - handleActivate(); - } - }); - } - } - } catch (CoreException exception) { - ComponentsEditorPlugin.INSTANCE.log(exception); - } - } - }; - - /** - * Handles activation of the editor or it's associated views. - * - * - * @generated - */ - protected void handleActivate() { - // Recompute the read only state. - // - if (editingDomain.getResourceToReadOnlyMap() != null) { - editingDomain.getResourceToReadOnlyMap().clear(); - - // Refresh any actions that may become enabled or disabled. - // - setSelection(getSelection()); - } - - if (!removedResources.isEmpty()) { - if (handleDirtyConflict()) { - getSite().getPage().closeEditor(ComponentsEditor.this, false); - } else { - removedResources.clear(); - changedResources.clear(); - savedResources.clear(); - } - } else if (!changedResources.isEmpty()) { - changedResources.removeAll(savedResources); - handleChangedResources(); - changedResources.clear(); - savedResources.clear(); - } - } - - /** - * Handles what to do with changed resources on activation. - * - * - * @generated - */ - protected void handleChangedResources() { - if (!changedResources.isEmpty() && (!isDirty() || handleDirtyConflict())) { - if (isDirty()) { - changedResources.addAll(editingDomain.getResourceSet().getResources()); - } - editingDomain.getCommandStack().flush(); - - updateProblemIndication = false; - for (Resource resource : changedResources) { - if (resource.isLoaded()) { - resource.unload(); - try { - resource.load(Collections.EMPTY_MAP); - } catch (IOException exception) { - if (!resourceToDiagnosticMap.containsKey(resource)) { - resourceToDiagnosticMap.put(resource, - analyzeResourceProblems(resource, exception)); - } - } - } - } - - if (AdapterFactoryEditingDomain.isStale(editorSelection)) { - setSelection(StructuredSelection.EMPTY); - } - - updateProblemIndication = true; - updateProblemIndication(); - } - } - - /** - * Updates the problems indication with the information described in the specified diagnostic. - * - * - * @generated - */ - protected void updateProblemIndication() { - if (updateProblemIndication) { - BasicDiagnostic diagnostic = new BasicDiagnostic(Diagnostic.OK, - "org.eclipse.emf.eef.components.editor", 0, null, - new Object[] {editingDomain.getResourceSet()}); - for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) { - if (childDiagnostic.getSeverity() != Diagnostic.OK) { - diagnostic.add(childDiagnostic); - } - } - - int lastEditorPage = getPageCount() - 1; - if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) { - ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic); - if (diagnostic.getSeverity() != Diagnostic.OK) { - setActivePage(lastEditorPage); - } - } else if (diagnostic.getSeverity() != Diagnostic.OK) { - ProblemEditorPart problemEditorPart = new ProblemEditorPart(); - problemEditorPart.setDiagnostic(diagnostic); - problemEditorPart.setMarkerHelper(markerHelper); - try { - addPage(++lastEditorPage, problemEditorPart, getEditorInput()); - setPageText(lastEditorPage, problemEditorPart.getPartName()); - setActivePage(lastEditorPage); - showTabs(); - } catch (PartInitException exception) { - ComponentsEditorPlugin.INSTANCE.log(exception); - } - } - - if (markerHelper.hasMarkers(editingDomain.getResourceSet())) { - markerHelper.deleteMarkers(editingDomain.getResourceSet()); - if (diagnostic.getSeverity() != Diagnostic.OK) { - try { - markerHelper.createMarkers(diagnostic); - } catch (CoreException exception) { - ComponentsEditorPlugin.INSTANCE.log(exception); - } - } - } - } - } - - /** - * Shows a dialog that asks if conflicting changes should be discarded. - * - * - * @generated - */ - protected boolean handleDirtyConflict() { - return MessageDialog.openQuestion(getSite().getShell(), getString("_UI_FileConflict_label"), - getString("_WARN_FileConflict")); - } - - /** - * This creates a model editor. - * - * - * @generated - */ - public ComponentsEditor() { - super(); - initializeEditingDomain(); - } - - /** - * This sets up the editing domain for the model editor. - * - * - * @generated NOT - */ - protected void initializeEditingDomain() { - // Create an adapter factory that yields item providers. - // - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - - adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ComponentsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new GenModelItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new MappingCustomItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ViewsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ToolkitsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new FiltersItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new NavigationItemProviderAdapterFactory()); - - // Create the command stack that will notify this editor as commands are executed. - // - BasicCommandStack commandStack = new BasicCommandStack(); - - // Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus. - commandStack.addCommandStackListener(new CommandStackListener() { - public void commandStackChanged(final EventObject event) { - getContainer().getDisplay().asyncExec(new Runnable() { - public void run() { - firePropertyChange(IEditorPart.PROP_DIRTY); - - // Try to select the affected objects. - // - Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand(); - if (mostRecentCommand != null) { - Collection affectedObjects = mostRecentCommand.getAffectedObjects(); - if (affectedObjects.size() > 0) { - List selectedList = new ArrayList(); - selectedList.add(affectedObjects.toArray()[0]); - setSelectionToViewer(selectedList); - } else - setSelectionToViewer(affectedObjects); - } - if (propertySheetPage != null && !propertySheetPage.getControl().isDisposed()) { - propertySheetPage.refresh(); - } - } - }); - } - }); - - // Create the editing domain with a special command stack. - // - editingDomain = new AdapterFactoryEditingDomain(adapterFactory, commandStack, - new HashMap()); - } - - /** - * This is here for the listener to be able to call it. - * - * - * @generated - */ - @Override - protected void firePropertyChange(int action) { - super.firePropertyChange(action); - } - - /** - * This sets the selection into whichever viewer is active. - * - * - * @generated - */ - public void setSelectionToViewer(Collection collection) { - final Collection theSelection = collection; - // Make sure it's okay. - // - if (theSelection != null && !theSelection.isEmpty()) { - // I don't know if this should be run this deferred - // because we might have to give the editor a chance to process the viewer update events - // and hence to update the views first. - // - // - Runnable runnable = new Runnable() { - public void run() { - // Try to select the items in the current content viewer of the editor. - // - if (currentViewer != null) { - currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true); - } - } - }; - runnable.run(); - } - } - - /** - * This returns the editing domain as required by the {@link IEditingDomainProvider} interface. - * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} - * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}. - * - * - * @generated - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * - * - * @generated - */ - public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider { - /** - * - * - * @generated - */ - public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * - * - * @generated - */ - @Override - public Object[] getElements(Object object) { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ - @Override - public Object[] getChildren(Object object) { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ - @Override - public boolean hasChildren(Object object) { - Object parent = super.getParent(object); - return parent != null; - } - - /** - * - * - * @generated - */ - @Override - public Object getParent(Object object) { - return null; - } - } - - /** - * This makes sure that one content viewer, either for the current page or the outline view, if it has focus, - * is the current one. - * - * - * @generated - */ - public void setCurrentViewer(Viewer viewer) { - // If it is changing... - // - if (currentViewer != viewer) { - if (selectionChangedListener == null) { - // Create the listener on demand. - // - selectionChangedListener = new ISelectionChangedListener() { - // This just notifies those things that are affected by the section. - // - public void selectionChanged(SelectionChangedEvent selectionChangedEvent) { - setSelection(selectionChangedEvent.getSelection()); - } - }; - } - - // Stop listening to the old one. - // - if (currentViewer != null) { - currentViewer.removeSelectionChangedListener(selectionChangedListener); - } - - // Start listening to the new one. - // - if (viewer != null) { - viewer.addSelectionChangedListener(selectionChangedListener); - } - - // Remember it. - // - currentViewer = viewer; - - // Set the editors selection based on the current viewer's selection. - // - setSelection(currentViewer == null ? StructuredSelection.EMPTY : currentViewer.getSelection()); - } - } - - /** - * This returns the viewer as required by the {@link IViewerProvider} interface. - * - * - * @generated - */ - public Viewer getViewer() { - return currentViewer; - } - - /** - * This creates a context menu for the viewer and adds a listener as well registering the menu for extension. - * - * - * @generated - */ - protected void createContextMenuFor(StructuredViewer viewer) { - MenuManager contextMenu = new MenuManager("#PopUp"); - contextMenu.add(new Separator("additions")); - contextMenu.setRemoveAllWhenShown(true); - contextMenu.addMenuListener(this); - Menu menu = contextMenu.createContextMenu(viewer.getControl()); - viewer.getControl().setMenu(menu); - getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer)); - - int dndOperations = DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK; - Transfer[] transfers = new Transfer[] {LocalTransfer.getInstance()}; - viewer.addDragSupport(dndOperations, transfers, new ViewerDragAdapter(viewer)); - viewer.addDropSupport(dndOperations, transfers, new EditingDomainViewerDropAdapter(editingDomain, - viewer)); - } - - /** - * This is the method called to load a resource into the editing domain's resource set based on the editor's input. - * - * - * @generated - */ - public void createModel() { - URI resourceURI = EditUIUtil.getURI(getEditorInput()); - Exception exception = null; - Resource resource = null; - try { - // Load the resource through the editing domain. - // - resource = editingDomain.getResourceSet().getResource(resourceURI, true); - } catch (Exception e) { - exception = e; - resource = editingDomain.getResourceSet().getResource(resourceURI, false); - } - - Diagnostic diagnostic = analyzeResourceProblems(resource, exception); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter); - } - - /** - * Returns a diagnostic describing the errors and warnings listed in the resource - * and the specified exception (if any). - * - * - * @generated - */ - public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) { - if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) { - BasicDiagnostic basicDiagnostic = new BasicDiagnostic(Diagnostic.ERROR, - "org.eclipse.emf.eef.components.editor", 0, getString("_UI_CreateModelError_message", - resource.getURI()), new Object[] {exception == null ? (Object)resource - : exception}); - basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true)); - return basicDiagnostic; - } else if (exception != null) { - return new BasicDiagnostic(Diagnostic.ERROR, "org.eclipse.emf.eef.components.editor", 0, - getString("_UI_CreateModelError_message", resource.getURI()), new Object[] {exception}); - } else { - return Diagnostic.OK_INSTANCE; - } - } - - /** - * This is the method used by the framework to install your own controls. - * - * - * @generated NOT - */ - @Override - public void createPages() { - // Creates the model from the editor input - // - createModel(); - - // Only creates the other pages if there is something that can be edited - // - if (!getEditingDomain().getResourceSet().getResources().isEmpty()) { - // Create a page for the selection tree view. - // - Tree tree = new Tree(getContainer(), SWT.MULTI); - selectionViewer = new TreeViewer(tree); - setCurrentViewer(selectionViewer); - - selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - selectionViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - selectionViewer.setInput(editingDomain.getResourceSet()); - selectionViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet() - .getResources().get(0)), true); - selectionViewer - .addDoubleClickListener(new OpenWizardOnDoubleClick(editingDomain, adapterFactory)); - - new AdapterFactoryTreeEditor(selectionViewer.getTree(), adapterFactory); - - createContextMenuFor(selectionViewer); - int pageIndex = addPage(tree); - setPageText(pageIndex, getString("_UI_SelectionPage_label")); - - getSite().getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - setActivePage(0); - } - }); - } - - // Ensures that this editor will only display the page's tab - // area if there are more than one page - // - getContainer().addControlListener(new ControlAdapter() { - boolean guard = false; - - @Override - public void controlResized(ControlEvent event) { - if (!guard) { - guard = true; - hideTabs(); - guard = false; - } - } - }); - - getSite().getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - - /** - * If there is just one page in the multi-page editor part, - * this hides the single tab at the bottom. - * - * - * @generated - */ - protected void hideTabs() { - if (getPageCount() <= 1) { - setPageText(0, ""); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(1); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y + 6); - } - } - } - - /** - * If there is more than one page in the multi-page editor part, - * this shows the tabs at the bottom. - * - * - * @generated - */ - protected void showTabs() { - if (getPageCount() > 1) { - setPageText(0, getString("_UI_SelectionPage_label")); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y - 6); - } - } - } - - /** - * This is used to track the active viewer. - * - * - * @generated - */ - @Override - protected void pageChange(int pageIndex) { - super.pageChange(pageIndex); - - if (contentOutlinePage != null) { - handleContentOutlineSelection(contentOutlinePage.getSelection()); - } - } - - /** - * This is how the framework determines which interfaces we implement. - * - * - * @generated - */ - @Override - public Object getAdapter(Class key) { - if (key.equals(IContentOutlinePage.class)) { - return showOutlineView() ? getContentOutlinePage() : null; - } else if (key.equals(IPropertySheetPage.class)) { - return getPropertySheetPage(); - } else if (key.equals(IGotoMarker.class)) { - return this; - } else { - return super.getAdapter(key); - } - } - - /** - * This accesses a cached version of the content outliner. - * - * - * @generated - */ - public IContentOutlinePage getContentOutlinePage() { - if (contentOutlinePage == null) { - // The content outline is just a tree. - // - class MyContentOutlinePage extends ContentOutlinePage { - @Override - public void createControl(Composite parent) { - super.createControl(parent); - contentOutlineViewer = getTreeViewer(); - contentOutlineViewer.addSelectionChangedListener(this); - - // Set up the tree viewer. - // - contentOutlineViewer - .setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - contentOutlineViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - contentOutlineViewer.setInput(editingDomain.getResourceSet()); - - // Make sure our popups work. - // - createContextMenuFor(contentOutlineViewer); - - if (!editingDomain.getResourceSet().getResources().isEmpty()) { - // Select the root object in the view. - // - contentOutlineViewer.setSelection(new StructuredSelection(editingDomain - .getResourceSet().getResources().get(0)), true); - } - } - - @Override - public void makeContributions(IMenuManager menuManager, IToolBarManager toolBarManager, - IStatusLineManager statusLineManager) { - super.makeContributions(menuManager, toolBarManager, statusLineManager); - contentOutlineStatusLineManager = statusLineManager; - } - - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - } - - contentOutlinePage = new MyContentOutlinePage(); - - // Listen to selection so that we can handle it is a special way. - // - contentOutlinePage.addSelectionChangedListener(new ISelectionChangedListener() { - // This ensures that we handle selections correctly. - // - public void selectionChanged(SelectionChangedEvent event) { - handleContentOutlineSelection(event.getSelection()); - } - }); - } - - return contentOutlinePage; - } - - /** - * This accesses a cached version of the property sheet. - * - * - * @generated NOT - */ - public IPropertySheetPage getPropertySheetPage() { - if (propertySheetPage == null || propertySheetPage.getControl().isDisposed()) { - propertySheetPage = new TabbedPropertySheetPage(ComponentsEditor.this) { - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - }; - } - - return propertySheetPage; - } - - /** - * This deals with how we want selection in the outliner to affect the other views. - * - * - * @generated - */ - public void handleContentOutlineSelection(ISelection selection) { - if (selectionViewer != null && !selection.isEmpty() && selection instanceof IStructuredSelection) { - Iterator selectedElements = ((IStructuredSelection)selection).iterator(); - if (selectedElements.hasNext()) { - // Get the first selected element. - // - Object selectedElement = selectedElements.next(); - - ArrayList selectionList = new ArrayList(); - selectionList.add(selectedElement); - while (selectedElements.hasNext()) { - selectionList.add(selectedElements.next()); - } - - // Set the selection to the widget. - // - selectionViewer.setSelection(new StructuredSelection(selectionList)); - } - } - } - - /** - * This is for implementing {@link IEditorPart} and simply tests the command stack. - * - * - * @generated - */ - @Override - public boolean isDirty() { - return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded(); - } - - /** - * This is for implementing {@link IEditorPart} and simply saves the model file. - * - * - * @generated - */ - @Override - public void doSave(IProgressMonitor progressMonitor) { - // Save only resources that have actually changed. - // - final Map saveOptions = new HashMap(); - saveOptions.put(Resource.OPTION_SAVE_ONLY_IF_CHANGED, - Resource.OPTION_SAVE_ONLY_IF_CHANGED_MEMORY_BUFFER); - - // Do the work within an operation because this is a long running activity that modifies the workbench. - // - WorkspaceModifyOperation operation = new WorkspaceModifyOperation() { - // This is the method that gets invoked when the operation runs. - // - @Override - public void execute(IProgressMonitor monitor) { - // Save the resources to the file system. - // - boolean first = true; - for (Resource resource : editingDomain.getResourceSet().getResources()) { - if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) - && !editingDomain.isReadOnly(resource)) { - try { - long timeStamp = resource.getTimeStamp(); - resource.save(saveOptions); - if (resource.getTimeStamp() != timeStamp) { - savedResources.add(resource); - } - } catch (Exception exception) { - resourceToDiagnosticMap.put(resource, - analyzeResourceProblems(resource, exception)); - } - first = false; - } - } - } - }; - - updateProblemIndication = false; - try { - // This runs the options, and shows progress. - // - new ProgressMonitorDialog(getSite().getShell()).run(true, false, operation); - - // Refresh the necessary state. - // - ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone(); - firePropertyChange(IEditorPart.PROP_DIRTY); - } catch (Exception exception) { - // Something went wrong that shouldn't. - // - ComponentsEditorPlugin.INSTANCE.log(exception); - } - updateProblemIndication = true; - updateProblemIndication(); - } - - /** - * This returns whether something has been persisted to the URI of the specified resource. - * The implementation uses the URI converter from the editor's resource set to try to open an input stream. - * - * - * @generated - */ - protected boolean isPersisted(Resource resource) { - boolean result = false; - try { - InputStream stream = editingDomain.getResourceSet().getURIConverter() - .createInputStream(resource.getURI()); - if (stream != null) { - result = true; - stream.close(); - } - } catch (IOException e) { - // Ignore - } - return result; - } - - /** - * This always returns true because it is not currently supported. - * - * - * @generated - */ - @Override - public boolean isSaveAsAllowed() { - return true; - } - - /** - * This also changes the editor's input. - * - * - * @generated - */ - @Override - public void doSaveAs() { - SaveAsDialog saveAsDialog = new SaveAsDialog(getSite().getShell()); - saveAsDialog.open(); - IPath path = saveAsDialog.getResult(); - if (path != null) { - IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path); - if (file != null) { - doSaveAs(URI.createPlatformResourceURI(file.getFullPath().toString(), true), - new FileEditorInput(file)); - } - } - } - - /** - * - * - * @generated - */ - protected void doSaveAs(URI uri, IEditorInput editorInput) { - (editingDomain.getResourceSet().getResources().get(0)).setURI(uri); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - IProgressMonitor progressMonitor = getActionBars().getStatusLineManager() != null ? getActionBars() - .getStatusLineManager().getProgressMonitor() : new NullProgressMonitor(); - doSave(progressMonitor); - } - - /** - * - * - * @generated - */ - public void gotoMarker(IMarker marker) { - try { - if (marker.getType().equals(EValidator.MARKER)) { - String uriAttribute = marker.getAttribute(EValidator.URI_ATTRIBUTE, null); - if (uriAttribute != null) { - URI uri = URI.createURI(uriAttribute); - EObject eObject = editingDomain.getResourceSet().getEObject(uri, true); - if (eObject != null) { - setSelectionToViewer(Collections.singleton(editingDomain.getWrapper(eObject))); - } - } - } - } catch (CoreException exception) { - ComponentsEditorPlugin.INSTANCE.log(exception); - } - } - - /** - * This is called during startup. - * - * - * @generated - */ - @Override - public void init(IEditorSite site, IEditorInput editorInput) { - setSite(site); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - site.setSelectionProvider(this); - site.getPage().addPartListener(partListener); - ResourcesPlugin.getWorkspace().addResourceChangeListener(resourceChangeListener, - IResourceChangeEvent.POST_CHANGE); - } - - /** - * - * - * @generated - */ - @Override - public void setFocus() { - getControl(getActivePage()).setFocus(); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void addSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.add(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void removeSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.remove(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection. - * - * - * @generated - */ - public ISelection getSelection() { - return editorSelection; - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to set this editor's overall selection. - * Calling this result will notify the listeners. - * - * - * @generated - */ - public void setSelection(ISelection selection) { - editorSelection = selection; - - for (ISelectionChangedListener listener : selectionChangedListeners) { - listener.selectionChanged(new SelectionChangedEvent(this, selection)); - } - setStatusLineManager(selection); - } - - /** - * - * - * @generated - */ - public void setStatusLineManager(ISelection selection) { - IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ? contentOutlineStatusLineManager - : getActionBars().getStatusLineManager(); - - if (statusLineManager != null) { - if (selection instanceof IStructuredSelection) { - Collection collection = ((IStructuredSelection)selection).toList(); - switch (collection.size()) { - case 0: { - statusLineManager.setMessage(getString("_UI_NoObjectSelected")); - break; - } - case 1: { - String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection - .iterator().next()); - statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text)); - break; - } - default: { - statusLineManager.setMessage(getString("_UI_MultiObjectSelected", - Integer.toString(collection.size()))); - break; - } - } - } else { - statusLineManager.setMessage(""); - } - } - } - - /** - * This looks up a string in the plugin's plugin.properties file. - * - * - * @generated - */ - private static String getString(String key) { - return ComponentsEditorPlugin.INSTANCE.getString(key); - } - - /** - * This looks up a string in plugin.properties, making a substitution. - * - * - * @generated - */ - private static String getString(String key, Object s1) { - return ComponentsEditorPlugin.INSTANCE.getString(key, new Object[] {s1}); - } - - /** - * This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu. - * - * - * @generated - */ - public void menuAboutToShow(IMenuManager menuManager) { - ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager); - } - - /** - * - * - * @generated - */ - public EditingDomainActionBarContributor getActionBarContributor() { - return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor(); - } - - /** - * - * - * @generated - */ - public IActionBars getActionBars() { - return getActionBarContributor().getActionBars(); - } - - /** - * - * - * @generated - */ - public AdapterFactory getAdapterFactory() { - return adapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public void dispose() { - updateProblemIndication = false; - - ResourcesPlugin.getWorkspace().removeResourceChangeListener(resourceChangeListener); - - getSite().getPage().removePartListener(partListener); - - adapterFactory.dispose(); - - if (getActionBarContributor().getActiveEditor() == this) { - getActionBarContributor().setActiveEditor(null); - } - - if (propertySheetPage != null) { - propertySheetPage.dispose(); - } - - if (contentOutlinePage != null) { - contentOutlinePage.dispose(); - } - - super.dispose(); - } - - /** - * Returns whether the outline view should be presented to the user. - * - * - * @generated - */ - protected boolean showOutlineView() { - return false; - } - - /** - * @see org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor#getContributorId() - * @generated NOT - */ - public String getContributorId() { - return PROPERTIES_CONTRIBUTOR; - } -} diff --git a/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsEditorPlugin.java b/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsEditorPlugin.java deleted file mode 100644 index 23ad7c67f..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsEditorPlugin.java +++ /dev/null @@ -1,100 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.presentation; - -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelEditPlugin; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.ui.EclipseUIPlugin; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.provider.EcoreEditPlugin; -import org.eclipse.emf.eef.mapping.provider.MappingEditPlugin; -import org.eclipse.emf.eef.views.provider.ViewsEditPlugin; - -/** - * This is the central singleton for the Components editor plugin. - * - * - * @generated - */ -public final class ComponentsEditorPlugin extends EMFPlugin { - /** - * Keep track of the singleton. - * - * - * @generated - */ - public static final ComponentsEditorPlugin INSTANCE = new ComponentsEditorPlugin(); - - /** - * Keep track of the singleton. - * - * - * @generated - */ - private static Implementation plugin; - - /** - * Create the instance. - * - * - * @generated - */ - public ComponentsEditorPlugin() { - super(new ResourceLocator[] {EcoreEditPlugin.INSTANCE, GenModelEditPlugin.INSTANCE, - MappingEditPlugin.INSTANCE, ViewsEditPlugin.INSTANCE,}); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - @Override - public ResourceLocator getPluginResourceLocator() { - return plugin; - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * - * @generated - */ - public static class Implementation extends EclipseUIPlugin { - /** - * Creates an instance. - * - * - * @generated - */ - public Implementation() { - super(); - - // Remember the static instance. - // - plugin = this; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsModelWizard.java b/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsModelWizard.java deleted file mode 100644 index 85f758c0c..000000000 --- a/plugins/org.eclipse.emf.eef.components.editor/src-gen/org/eclipse/emf/eef/components/presentation/ComponentsModelWizard.java +++ /dev/null @@ -1,615 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.presentation; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.MissingResourceException; -import java.util.StringTokenizer; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.CommonPlugin; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.ecore.xmi.XMLResource; -import org.eclipse.emf.edit.ui.provider.ExtendedImageRegistry; -import org.eclipse.emf.eef.components.ComponentsFactory; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.provider.ComponentsEditPlugin; -import org.eclipse.jface.dialogs.MessageDialog; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.wizard.Wizard; -import org.eclipse.jface.wizard.WizardPage; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.ModifyEvent; -import org.eclipse.swt.events.ModifyListener; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Combo; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; -import org.eclipse.ui.INewWizard; -import org.eclipse.ui.IWorkbench; -import org.eclipse.ui.IWorkbenchPage; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.IWorkbenchWindow; -import org.eclipse.ui.PartInitException; -import org.eclipse.ui.actions.WorkspaceModifyOperation; -import org.eclipse.ui.dialogs.WizardNewFileCreationPage; -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.ISetSelectionTarget; - -/** - * This is a simple wizard for creating a new model file. - * - * - * @generated - */ -public class ComponentsModelWizard extends Wizard implements INewWizard { - /** - * The supported extensions for created files. - * - * - * @generated - */ - public static final List FILE_EXTENSIONS = Collections.unmodifiableList(Arrays - .asList(ComponentsEditorPlugin.INSTANCE.getString("_UI_ComponentsEditorFilenameExtensions") - .split("\\s*,\\s*"))); - - /** - * A formatted list of supported file extensions, suitable for display. - * - * - * @generated - */ - public static final String FORMATTED_FILE_EXTENSIONS = ComponentsEditorPlugin.INSTANCE.getString( - "_UI_ComponentsEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", "); - - /** - * This caches an instance of the model package. - * - * - * @generated - */ - protected ComponentsPackage componentsPackage = ComponentsPackage.eINSTANCE; - - /** - * This caches an instance of the model factory. - * - * - * @generated - */ - protected ComponentsFactory componentsFactory = componentsPackage.getComponentsFactory(); - - /** - * This is the file creation page. - * - * - * @generated - */ - protected ComponentsModelWizardNewFileCreationPage newFileCreationPage; - - /** - * This is the initial object creation page. - * - * - * @generated - */ - protected ComponentsModelWizardInitialObjectCreationPage initialObjectCreationPage; - - /** - * Remember the selection during initialization for populating the default container. - * - * - * @generated - */ - protected IStructuredSelection selection; - - /** - * Remember the workbench during initialization. - * - * - * @generated - */ - protected IWorkbench workbench; - - /** - * Caches the names of the types that can be created as the root object. - * - * - * @generated - */ - protected List initialObjectNames; - - /** - * This just records the information. - * - * - * @generated - */ - public void init(IWorkbench workbench, IStructuredSelection selection) { - this.workbench = workbench; - this.selection = selection; - setWindowTitle(ComponentsEditorPlugin.INSTANCE.getString("_UI_Wizard_label")); - setDefaultPageImageDescriptor(ExtendedImageRegistry.INSTANCE - .getImageDescriptor(ComponentsEditorPlugin.INSTANCE.getImage("full/wizban/NewComponents"))); - } - - /** - * Returns the names of the types that can be created as the root object. - * - * - * @generated - */ - protected Collection getInitialObjectNames() { - if (initialObjectNames == null) { - initialObjectNames = new ArrayList(); - for (EClassifier eClassifier : componentsPackage.getEClassifiers()) { - if (eClassifier instanceof EClass) { - EClass eClass = (EClass)eClassifier; - if (!eClass.isAbstract()) { - initialObjectNames.add(eClass.getName()); - } - } - } - Collections.sort(initialObjectNames, CommonPlugin.INSTANCE.getComparator()); - } - return initialObjectNames; - } - - /** - * Create a new model. - * - * - * @generated - */ - protected EObject createInitialModel() { - EClass eClass = (EClass)componentsPackage.getEClassifier(initialObjectCreationPage - .getInitialObjectName()); - EObject rootObject = componentsFactory.create(eClass); - return rootObject; - } - - /** - * Do the work after everything is specified. - * - * - * @generated - */ - @Override - public boolean performFinish() { - try { - // Remember the file. - // - final IFile modelFile = getModelFile(); - - // Do the work within an operation. - // - WorkspaceModifyOperation operation = new WorkspaceModifyOperation() { - @Override - protected void execute(IProgressMonitor progressMonitor) { - try { - // Create a resource set - // - ResourceSet resourceSet = new ResourceSetImpl(); - - // Get the URI of the model file. - // - URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true); - - // Create a resource for this file. - // - Resource resource = resourceSet.createResource(fileURI); - - // Add the initial model object to the contents. - // - EObject rootObject = createInitialModel(); - if (rootObject != null) { - resource.getContents().add(rootObject); - } - - // Save the contents of the resource to the file system. - // - Map options = new HashMap(); - options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding()); - resource.save(options); - } catch (Exception exception) { - ComponentsEditorPlugin.INSTANCE.log(exception); - } finally { - progressMonitor.done(); - } - } - }; - - getContainer().run(false, false, operation); - - // Select the new file resource in the current view. - // - IWorkbenchWindow workbenchWindow = workbench.getActiveWorkbenchWindow(); - IWorkbenchPage page = workbenchWindow.getActivePage(); - final IWorkbenchPart activePart = page.getActivePart(); - if (activePart instanceof ISetSelectionTarget) { - final ISelection targetSelection = new StructuredSelection(modelFile); - getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - ((ISetSelectionTarget)activePart).selectReveal(targetSelection); - } - }); - } - - // Open an editor on the new file. - // - try { - page.openEditor(new FileEditorInput(modelFile), workbench.getEditorRegistry() - .getDefaultEditor(modelFile.getFullPath().toString()).getId()); - } catch (PartInitException exception) { - MessageDialog.openError(workbenchWindow.getShell(), - ComponentsEditorPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), - exception.getMessage()); - return false; - } - - return true; - } catch (Exception exception) { - ComponentsEditorPlugin.INSTANCE.log(exception); - return false; - } - } - - /** - * This is the one page of the wizard. - * - * - * @generated - */ - public class ComponentsModelWizardNewFileCreationPage extends WizardNewFileCreationPage { - /** - * Pass in the selection. - * - * - * @generated - */ - public ComponentsModelWizardNewFileCreationPage(String pageId, IStructuredSelection selection) { - super(pageId, selection); - } - - /** - * The framework calls this to see if the file is correct. - * - * - * @generated - */ - @Override - protected boolean validatePage() { - if (super.validatePage()) { - String extension = new Path(getFileName()).getFileExtension(); - if (extension == null || !FILE_EXTENSIONS.contains(extension)) { - String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" - : "_WARN_FilenameExtension"; - setErrorMessage(ComponentsEditorPlugin.INSTANCE.getString(key, - new Object[] {FORMATTED_FILE_EXTENSIONS})); - return false; - } - return true; - } - return false; - } - - /** - * - * - * @generated - */ - public IFile getModelFile() { - return ResourcesPlugin.getWorkspace().getRoot() - .getFile(getContainerFullPath().append(getFileName())); - } - } - - /** - * This is the page where the type of object to create is selected. - * - * - * @generated - */ - public class ComponentsModelWizardInitialObjectCreationPage extends WizardPage { - /** - * - * - * @generated - */ - protected Combo initialObjectField; - - /** - * @generated - * - * - */ - protected List encodings; - - /** - * - * - * @generated - */ - protected Combo encodingField; - - /** - * Pass in the selection. - * - * - * @generated - */ - public ComponentsModelWizardInitialObjectCreationPage(String pageId) { - super(pageId); - } - - /** - * - * - * @generated - */ - public void createControl(Composite parent) { - Composite composite = new Composite(parent, SWT.NONE); - { - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - layout.verticalSpacing = 12; - composite.setLayout(layout); - - GridData data = new GridData(); - data.verticalAlignment = GridData.FILL; - data.grabExcessVerticalSpace = true; - data.horizontalAlignment = GridData.FILL; - composite.setLayoutData(data); - } - - Label containerLabel = new Label(composite, SWT.LEFT); - { - containerLabel.setText(ComponentsEditorPlugin.INSTANCE.getString("_UI_ModelObject")); - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - containerLabel.setLayoutData(data); - } - - initialObjectField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - initialObjectField.setLayoutData(data); - } - - for (String objectName : getInitialObjectNames()) { - initialObjectField.add(getLabel(objectName)); - } - - if (initialObjectField.getItemCount() == 1) { - initialObjectField.select(0); - } - initialObjectField.addModifyListener(validator); - - Label encodingLabel = new Label(composite, SWT.LEFT); - { - encodingLabel.setText(ComponentsEditorPlugin.INSTANCE.getString("_UI_XMLEncoding")); - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - encodingLabel.setLayoutData(data); - } - encodingField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - encodingField.setLayoutData(data); - } - - for (String encoding : getEncodings()) { - encodingField.add(encoding); - } - - encodingField.select(0); - encodingField.addModifyListener(validator); - - setPageComplete(validatePage()); - setControl(composite); - } - - /** - * - * - * @generated - */ - protected ModifyListener validator = new ModifyListener() { - public void modifyText(ModifyEvent e) { - setPageComplete(validatePage()); - } - }; - - /** - * - * - * @generated - */ - protected boolean validatePage() { - return getInitialObjectName() != null && getEncodings().contains(encodingField.getText()); - } - - /** - * - * - * @generated - */ - @Override - public void setVisible(boolean visible) { - super.setVisible(visible); - if (visible) { - if (initialObjectField.getItemCount() == 1) { - initialObjectField.clearSelection(); - encodingField.setFocus(); - } else { - encodingField.clearSelection(); - initialObjectField.setFocus(); - } - } - } - - /** - * - * - * @generated - */ - public String getInitialObjectName() { - String label = initialObjectField.getText(); - - for (String name : getInitialObjectNames()) { - if (getLabel(name).equals(label)) { - return name; - } - } - return null; - } - - /** - * - * - * @generated - */ - public String getEncoding() { - return encodingField.getText(); - } - - /** - * Returns the label for the specified type name. - * - * - * @generated - */ - protected String getLabel(String typeName) { - try { - return ComponentsEditPlugin.INSTANCE.getString("_UI_" + typeName + "_type"); - } catch (MissingResourceException mre) { - ComponentsEditorPlugin.INSTANCE.log(mre); - } - return typeName; - } - - /** - * - * - * @generated - */ - protected Collection getEncodings() { - if (encodings == null) { - encodings = new ArrayList(); - for (StringTokenizer stringTokenizer = new StringTokenizer( - ComponentsEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer - .hasMoreTokens();) { - encodings.add(stringTokenizer.nextToken()); - } - } - return encodings; - } - } - - /** - * The framework calls this to create the contents of the wizard. - * - * - * @generated - */ - @Override - public void addPages() { - // Create a page, set the title, and the initial model file name. - // - newFileCreationPage = new ComponentsModelWizardNewFileCreationPage("Whatever", selection); - newFileCreationPage.setTitle(ComponentsEditorPlugin.INSTANCE - .getString("_UI_ComponentsModelWizard_label")); - newFileCreationPage.setDescription(ComponentsEditorPlugin.INSTANCE - .getString("_UI_ComponentsModelWizard_description")); - newFileCreationPage.setFileName(ComponentsEditorPlugin.INSTANCE - .getString("_UI_ComponentsEditorFilenameDefaultBase") + "." + FILE_EXTENSIONS.get(0)); - addPage(newFileCreationPage); - - // Try and get the resource selection to determine a current directory for the file dialog. - // - if (selection != null && !selection.isEmpty()) { - // Get the resource... - // - Object selectedElement = selection.iterator().next(); - if (selectedElement instanceof IResource) { - // Get the resource parent, if its a file. - // - IResource selectedResource = (IResource)selectedElement; - if (selectedResource.getType() == IResource.FILE) { - selectedResource = selectedResource.getParent(); - } - - // This gives us a directory... - // - if (selectedResource instanceof IFolder || selectedResource instanceof IProject) { - // Set this for the container. - // - newFileCreationPage.setContainerFullPath(selectedResource.getFullPath()); - - // Make up a unique new name here. - // - String defaultModelBaseFilename = ComponentsEditorPlugin.INSTANCE - .getString("_UI_ComponentsEditorFilenameDefaultBase"); - String defaultModelFilenameExtension = FILE_EXTENSIONS.get(0); - String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension; - for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) { - modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension; - } - newFileCreationPage.setFileName(modelFilename); - } - } - } - initialObjectCreationPage = new ComponentsModelWizardInitialObjectCreationPage("Whatever2"); - initialObjectCreationPage.setTitle(ComponentsEditorPlugin.INSTANCE - .getString("_UI_ComponentsModelWizard_label")); - initialObjectCreationPage.setDescription(ComponentsEditorPlugin.INSTANCE - .getString("_UI_Wizard_initial_object_description")); - addPage(initialObjectCreationPage); - } - - /** - * Get the file from the page. - * - * - * @generated - */ - public IFile getModelFile() { - return newFileCreationPage.getModelFile(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.components/.checkstyle b/plugins/org.eclipse.emf.eef.components/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.components/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components/.classpath b/plugins/org.eclipse.emf.eef.components/.classpath deleted file mode 100644 index f9c46b584..000000000 --- a/plugins/org.eclipse.emf.eef.components/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components/.gitignore b/plugins/org.eclipse.emf.eef.components/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.components/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.components/.project b/plugins/org.eclipse.emf.eef.components/.project deleted file mode 100644 index 4fc4a8bb6..000000000 --- a/plugins/org.eclipse.emf.eef.components/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.components - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.components/.settings/org.eclipse.core.resources.prefs b/plugins/org.eclipse.emf.eef.components/.settings/org.eclipse.core.resources.prefs deleted file mode 100644 index bc99986db..000000000 --- a/plugins/org.eclipse.emf.eef.components/.settings/org.eclipse.core.resources.prefs +++ /dev/null @@ -1,4 +0,0 @@ -#Thu Oct 23 19:51:07 CEST 2008 -eclipse.preferences.version=1 -encoding//model/components.ecore=UTF-8 -encoding//model/components.ecorediag=UTF-8 diff --git a/plugins/org.eclipse.emf.eef.components/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.components/META-INF/MANIFEST.MF deleted file mode 100644 index 8393f8399..000000000 --- a/plugins/org.eclipse.emf.eef.components/META-INF/MANIFEST.MF +++ /dev/null @@ -1,17 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Components Model -Bundle-SymbolicName: org.eclipse.emf.eef.components;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Vendor: Eclipse Modeling Project -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.components, - org.eclipse.emf.eef.components.impl, - org.eclipse.emf.eef.components.util -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.emf.ecore;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.codegen.ecore;bundle-version="2.4.0", - org.eclipse.emf.eef.mapping;visibility:=reexport, - org.eclipse.emf.eef.views -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.components/about.html b/plugins/org.eclipse.emf.eef.components/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.components/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.components/build.properties b/plugins/org.eclipse.emf.eef.components/build.properties deleted file mode 100644 index f4df03748..000000000 --- a/plugins/org.eclipse.emf.eef.components/build.properties +++ /dev/null @@ -1,19 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = .,\ - model/,\ - META-INF/,\ - plugin.xml,\ - about.html -jars.compile.order = . -source.. = src-gen/ -output.. = bin/ -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.components/model/components.ecore b/plugins/org.eclipse.emf.eef.components/model/components.ecore deleted file mode 100644 index b2ab521c5..000000000 --- a/plugins/org.eclipse.emf.eef.components/model/components.ecore +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components/model/components.ecorediag b/plugins/org.eclipse.emf.eef.components/model/components.ecorediag deleted file mode 100644 index 5db6d497d..000000000 --- a/plugins/org.eclipse.emf.eef.components/model/components.ecorediag +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components/model/components.genmodel b/plugins/org.eclipse.emf.eef.components/model/components.genmodel deleted file mode 100644 index 33938a9b8..000000000 --- a/plugins/org.eclipse.emf.eef.components/model/components.genmodel +++ /dev/null @@ -1,27 +0,0 @@ - - - components.ecore - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components/plugin.xml b/plugins/org.eclipse.emf.eef.components/plugin.xml deleted file mode 100644 index ade5be5f7..000000000 --- a/plugins/org.eclipse.emf.eef.components/plugin.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.components/pom.xml b/plugins/org.eclipse.emf.eef.components/pom.xml deleted file mode 100644 index 107754102..000000000 --- a/plugins/org.eclipse.emf.eef.components/pom.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.components - eclipse-plugin - - EEF Components Model Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/ComponentsFactory.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/ComponentsFactory.java deleted file mode 100644 index bd68802db..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/ComponentsFactory.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.components.ComponentsPackage - * @generated - */ -public interface ComponentsFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - ComponentsFactory eINSTANCE = org.eclipse.emf.eef.components.impl.ComponentsFactoryImpl.init(); - - /** - * Returns a new object of class 'Properties Edition Context'. - * - * - * @return a new object of class 'Properties Edition Context'. - * @generated - */ - PropertiesEditionContext createPropertiesEditionContext(); - - /** - * Returns a new object of class 'Properties Edition Component'. - * - * - * @return a new object of class 'Properties Edition Component'. - * @generated - */ - PropertiesEditionComponent createPropertiesEditionComponent(); - - /** - * Returns a new object of class 'Properties Edition Element'. - * - * - * @return a new object of class 'Properties Edition Element'. - * @generated - */ - PropertiesEditionElement createPropertiesEditionElement(); - - /** - * Returns a new object of class 'Properties Multi Edition Element'. - * - * - * @return a new object of class 'Properties Multi Edition Element'. - * @generated - */ - PropertiesMultiEditionElement createPropertiesMultiEditionElement(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - ComponentsPackage getComponentsPackage(); - -} //ComponentsFactory diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/ComponentsPackage.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/ComponentsPackage.java deleted file mode 100644 index 19f27c2ef..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/ComponentsPackage.java +++ /dev/null @@ -1,651 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.components.ComponentsFactory - * @model kind="package" - * @generated - */ -public interface ComponentsPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "components"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/components/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-components"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - ComponentsPackage eINSTANCE = org.eclipse.emf.eef.components.impl.ComponentsPackageImpl.init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.components.impl.PropertiesEditionContextImpl Properties Edition Context}' class. - * - * - * @see org.eclipse.emf.eef.components.impl.PropertiesEditionContextImpl - * @see org.eclipse.emf.eef.components.impl.ComponentsPackageImpl#getPropertiesEditionContext() - * @generated - */ - int PROPERTIES_EDITION_CONTEXT = 0; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_CONTEXT__DOCUMENTATION = MappingPackage.DATABINDING__DOCUMENTATION; - - /** - * The feature id for the 'Bindings' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_CONTEXT__BINDINGS = MappingPackage.DATABINDING__BINDINGS; - - /** - * The feature id for the 'Categories' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_CONTEXT__CATEGORIES = MappingPackage.DATABINDING__CATEGORIES; - - /** - * The feature id for the 'Model' reference. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_CONTEXT__MODEL = MappingPackage.DATABINDING_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Properties Edition Context' class. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_CONTEXT_FEATURE_COUNT = MappingPackage.DATABINDING_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.components.impl.PropertiesEditionComponentImpl Properties Edition Component}' class. - * - * - * @see org.eclipse.emf.eef.components.impl.PropertiesEditionComponentImpl - * @see org.eclipse.emf.eef.components.impl.ComponentsPackageImpl#getPropertiesEditionComponent() - * @generated - */ - int PROPERTIES_EDITION_COMPONENT = 1; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__DOCUMENTATION = MappingPackage.EMF_ELEMENT_BINDING__DOCUMENTATION; - - /** - * The feature id for the 'Sub Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__SUB_ELEMENTS = MappingPackage.EMF_ELEMENT_BINDING__SUB_ELEMENTS; - - /** - * The feature id for the 'Properties' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__PROPERTIES = MappingPackage.EMF_ELEMENT_BINDING__PROPERTIES; - - /** - * The feature id for the 'Databinding' container reference. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__DATABINDING = MappingPackage.EMF_ELEMENT_BINDING__DATABINDING; - - /** - * The feature id for the 'Super Element' container reference. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__SUPER_ELEMENT = MappingPackage.EMF_ELEMENT_BINDING__SUPER_ELEMENT; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__NAME = MappingPackage.EMF_ELEMENT_BINDING__NAME; - - /** - * The feature id for the 'Referenced Binding' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__REFERENCED_BINDING = MappingPackage.EMF_ELEMENT_BINDING__REFERENCED_BINDING; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__VIEWS = MappingPackage.EMF_ELEMENT_BINDING__VIEWS; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__CATEGORY = MappingPackage.EMF_ELEMENT_BINDING__CATEGORY; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__BINDING_FILTERS = MappingPackage.EMF_ELEMENT_BINDING__BINDING_FILTERS; - - /** - * The feature id for the 'Model' reference. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__MODEL = MappingPackage.EMF_ELEMENT_BINDING__MODEL; - - /** - * The feature id for the 'Help ID' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__HELP_ID = MappingPackage.EMF_ELEMENT_BINDING_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Explicit' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT__EXPLICIT = MappingPackage.EMF_ELEMENT_BINDING_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Properties Edition Component' class. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_COMPONENT_FEATURE_COUNT = MappingPackage.EMF_ELEMENT_BINDING_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.components.impl.PropertiesEditionElementImpl Properties Edition Element}' class. - * - * - * @see org.eclipse.emf.eef.components.impl.PropertiesEditionElementImpl - * @see org.eclipse.emf.eef.components.impl.ComponentsPackageImpl#getPropertiesEditionElement() - * @generated - */ - int PROPERTIES_EDITION_ELEMENT = 2; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_ELEMENT__DOCUMENTATION = MappingPackage.EMF_PROPERTY_BINDING__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_ELEMENT__NAME = MappingPackage.EMF_PROPERTY_BINDING__NAME; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_ELEMENT__VIEWS = MappingPackage.EMF_PROPERTY_BINDING__VIEWS; - - /** - * The feature id for the 'Element' container reference. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_ELEMENT__ELEMENT = MappingPackage.EMF_PROPERTY_BINDING__ELEMENT; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_ELEMENT__BINDING_FILTERS = MappingPackage.EMF_PROPERTY_BINDING__BINDING_FILTERS; - - /** - * The feature id for the 'Model' reference. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_ELEMENT__MODEL = MappingPackage.EMF_PROPERTY_BINDING__MODEL; - - /** - * The feature id for the 'Navigation' containment reference. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_ELEMENT__NAVIGATION = MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION; - - /** - * The feature id for the 'Help ID' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_ELEMENT__HELP_ID = MappingPackage.EMF_PROPERTY_BINDING_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Properties Edition Element' class. - * - * - * @generated - * @ordered - */ - int PROPERTIES_EDITION_ELEMENT_FEATURE_COUNT = MappingPackage.EMF_PROPERTY_BINDING_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.components.impl.PropertiesMultiEditionElementImpl Properties Multi Edition Element}' class. - * - * - * @see org.eclipse.emf.eef.components.impl.PropertiesMultiEditionElementImpl - * @see org.eclipse.emf.eef.components.impl.ComponentsPackageImpl#getPropertiesMultiEditionElement() - * @generated - */ - int PROPERTIES_MULTI_EDITION_ELEMENT = 3; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_MULTI_EDITION_ELEMENT__DOCUMENTATION = MappingPackage.EMF_MULTI_PROPERTIES_BINDING__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_MULTI_EDITION_ELEMENT__NAME = MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAME; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_MULTI_EDITION_ELEMENT__VIEWS = MappingPackage.EMF_MULTI_PROPERTIES_BINDING__VIEWS; - - /** - * The feature id for the 'Element' container reference. - * - * - * @generated - * @ordered - */ - int PROPERTIES_MULTI_EDITION_ELEMENT__ELEMENT = MappingPackage.EMF_MULTI_PROPERTIES_BINDING__ELEMENT; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_MULTI_EDITION_ELEMENT__BINDING_FILTERS = MappingPackage.EMF_MULTI_PROPERTIES_BINDING__BINDING_FILTERS; - - /** - * The feature id for the 'Model' reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_MULTI_EDITION_ELEMENT__MODEL = MappingPackage.EMF_MULTI_PROPERTIES_BINDING__MODEL; - - /** - * The feature id for the 'Navigation' containment reference. - * - * - * @generated - * @ordered - */ - int PROPERTIES_MULTI_EDITION_ELEMENT__NAVIGATION = MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION; - - /** - * The feature id for the 'Help ID' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_MULTI_EDITION_ELEMENT__HELP_ID = MappingPackage.EMF_MULTI_PROPERTIES_BINDING_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Properties Multi Edition Element' class. - * - * - * @generated - * @ordered - */ - int PROPERTIES_MULTI_EDITION_ELEMENT_FEATURE_COUNT = MappingPackage.EMF_MULTI_PROPERTIES_BINDING_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.components.impl.EEFElementImpl EEF Element}' class. - * - * - * @see org.eclipse.emf.eef.components.impl.EEFElementImpl - * @see org.eclipse.emf.eef.components.impl.ComponentsPackageImpl#getEEFElement() - * @generated - */ - int EEF_ELEMENT = 4; - - /** - * The feature id for the 'Help ID' attribute. - * - * - * @generated - * @ordered - */ - int EEF_ELEMENT__HELP_ID = 0; - - /** - * The number of structural features of the 'EEF Element' class. - * - * - * @generated - * @ordered - */ - int EEF_ELEMENT_FEATURE_COUNT = 1; - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.components.PropertiesEditionContext Properties Edition Context}'. - * - * - * @return the meta object for class 'Properties Edition Context'. - * @see org.eclipse.emf.eef.components.PropertiesEditionContext - * @generated - */ - EClass getPropertiesEditionContext(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.components.PropertiesEditionContext#getModel Model}'. - * - * - * @return the meta object for the reference 'Model'. - * @see org.eclipse.emf.eef.components.PropertiesEditionContext#getModel() - * @see #getPropertiesEditionContext() - * @generated - */ - EReference getPropertiesEditionContext_Model(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.components.PropertiesEditionComponent Properties Edition Component}'. - * - * - * @return the meta object for class 'Properties Edition Component'. - * @see org.eclipse.emf.eef.components.PropertiesEditionComponent - * @generated - */ - EClass getPropertiesEditionComponent(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.components.PropertiesEditionComponent#isExplicit Explicit}'. - * - * - * @return the meta object for the attribute 'Explicit'. - * @see org.eclipse.emf.eef.components.PropertiesEditionComponent#isExplicit() - * @see #getPropertiesEditionComponent() - * @generated - */ - EAttribute getPropertiesEditionComponent_Explicit(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.components.PropertiesEditionElement Properties Edition Element}'. - * - * - * @return the meta object for class 'Properties Edition Element'. - * @see org.eclipse.emf.eef.components.PropertiesEditionElement - * @generated - */ - EClass getPropertiesEditionElement(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.components.PropertiesMultiEditionElement Properties Multi Edition Element}'. - * - * - * @return the meta object for class 'Properties Multi Edition Element'. - * @see org.eclipse.emf.eef.components.PropertiesMultiEditionElement - * @generated - */ - EClass getPropertiesMultiEditionElement(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.components.EEFElement EEF Element}'. - * - * - * @return the meta object for class 'EEF Element'. - * @see org.eclipse.emf.eef.components.EEFElement - * @generated - */ - EClass getEEFElement(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.components.EEFElement#getHelpID Help ID}'. - * - * - * @return the meta object for the attribute 'Help ID'. - * @see org.eclipse.emf.eef.components.EEFElement#getHelpID() - * @see #getEEFElement() - * @generated - */ - EAttribute getEEFElement_HelpID(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - ComponentsFactory getComponentsFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.components.impl.PropertiesEditionContextImpl Properties Edition Context}' class. - * - * - * @see org.eclipse.emf.eef.components.impl.PropertiesEditionContextImpl - * @see org.eclipse.emf.eef.components.impl.ComponentsPackageImpl#getPropertiesEditionContext() - * @generated - */ - EClass PROPERTIES_EDITION_CONTEXT = eINSTANCE.getPropertiesEditionContext(); - - /** - * The meta object literal for the 'Model' reference feature. - * - * - * @generated - */ - EReference PROPERTIES_EDITION_CONTEXT__MODEL = eINSTANCE.getPropertiesEditionContext_Model(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.components.impl.PropertiesEditionComponentImpl Properties Edition Component}' class. - * - * - * @see org.eclipse.emf.eef.components.impl.PropertiesEditionComponentImpl - * @see org.eclipse.emf.eef.components.impl.ComponentsPackageImpl#getPropertiesEditionComponent() - * @generated - */ - EClass PROPERTIES_EDITION_COMPONENT = eINSTANCE.getPropertiesEditionComponent(); - - /** - * The meta object literal for the 'Explicit' attribute feature. - * - * - * @generated - */ - EAttribute PROPERTIES_EDITION_COMPONENT__EXPLICIT = eINSTANCE - .getPropertiesEditionComponent_Explicit(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.components.impl.PropertiesEditionElementImpl Properties Edition Element}' class. - * - * - * @see org.eclipse.emf.eef.components.impl.PropertiesEditionElementImpl - * @see org.eclipse.emf.eef.components.impl.ComponentsPackageImpl#getPropertiesEditionElement() - * @generated - */ - EClass PROPERTIES_EDITION_ELEMENT = eINSTANCE.getPropertiesEditionElement(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.components.impl.PropertiesMultiEditionElementImpl Properties Multi Edition Element}' class. - * - * - * @see org.eclipse.emf.eef.components.impl.PropertiesMultiEditionElementImpl - * @see org.eclipse.emf.eef.components.impl.ComponentsPackageImpl#getPropertiesMultiEditionElement() - * @generated - */ - EClass PROPERTIES_MULTI_EDITION_ELEMENT = eINSTANCE.getPropertiesMultiEditionElement(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.components.impl.EEFElementImpl EEF Element}' class. - * - * - * @see org.eclipse.emf.eef.components.impl.EEFElementImpl - * @see org.eclipse.emf.eef.components.impl.ComponentsPackageImpl#getEEFElement() - * @generated - */ - EClass EEF_ELEMENT = eINSTANCE.getEEFElement(); - - /** - * The meta object literal for the 'Help ID' attribute feature. - * - * - * @generated - */ - EAttribute EEF_ELEMENT__HELP_ID = eINSTANCE.getEEFElement_HelpID(); - - } - -} //ComponentsPackage diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/EEFElement.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/EEFElement.java deleted file mode 100644 index fd6cc0efc..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/EEFElement.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'EEF Element'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.components.EEFElement#getHelpID Help ID}
  • - *
- *

- * - * @see org.eclipse.emf.eef.components.ComponentsPackage#getEEFElement() - * @model abstract="true" - * @generated - */ -public interface EEFElement extends EObject { - /** - * Returns the value of the 'Help ID' attribute. - * - *

- * If the meaning of the 'Help ID' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Help ID' attribute. - * @see #setHelpID(String) - * @see org.eclipse.emf.eef.components.ComponentsPackage#getEEFElement_HelpID() - * @model - * @generated - */ - String getHelpID(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.components.EEFElement#getHelpID Help ID}' attribute. - * - * - * @param value the new value of the 'Help ID' attribute. - * @see #getHelpID() - * @generated - */ - void setHelpID(String value); - -} // EEFElement diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionComponent.java deleted file mode 100644 index c77fa392f..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionComponent.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components; - -import org.eclipse.emf.eef.mapping.EMFElementBinding; - -/** - * - * A representation of the model object 'Properties Edition Component'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.components.PropertiesEditionComponent#isExplicit Explicit}
  • - *
- *

- * - * @see org.eclipse.emf.eef.components.ComponentsPackage#getPropertiesEditionComponent() - * @model - * @generated - */ -public interface PropertiesEditionComponent extends EMFElementBinding, EEFElement { - /** - * Returns the value of the 'Explicit' attribute. - * The default value is "true". - * - *

- * If the meaning of the 'Explicit' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Explicit' attribute. - * @see #setExplicit(boolean) - * @see org.eclipse.emf.eef.components.ComponentsPackage#getPropertiesEditionComponent_Explicit() - * @model default="true" - * @generated - */ - boolean isExplicit(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.components.PropertiesEditionComponent#isExplicit Explicit}' attribute. - * - * - * @param value the new value of the 'Explicit' attribute. - * @see #isExplicit() - * @generated - */ - void setExplicit(boolean value); - -} // PropertiesEditionComponent diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionContext.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionContext.java deleted file mode 100644 index 47c0c9bac..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionContext.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components; - -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; - -import org.eclipse.emf.eef.mapping.Databinding; - -/** - * - * A representation of the model object 'Properties Edition Context'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.components.PropertiesEditionContext#getModel Model}
  • - *
- *

- * - * @see org.eclipse.emf.eef.components.ComponentsPackage#getPropertiesEditionContext() - * @model - * @generated - */ -public interface PropertiesEditionContext extends Databinding { - /** - * Returns the value of the 'Model' reference. - * - *

- * If the meaning of the 'Model' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Model' reference. - * @see #setModel(GenPackage) - * @see org.eclipse.emf.eef.components.ComponentsPackage#getPropertiesEditionContext_Model() - * @model required="true" - * @generated - */ - GenPackage getModel(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.components.PropertiesEditionContext#getModel Model}' reference. - * - * - * @param value the new value of the 'Model' reference. - * @see #getModel() - * @generated - */ - void setModel(GenPackage value); - -} // PropertiesEditionContext diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionElement.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionElement.java deleted file mode 100644 index b4e153c22..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesEditionElement.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components; - -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; - -/** - * - * A representation of the model object 'Properties Edition Element'. - * - * - * - * @see org.eclipse.emf.eef.components.ComponentsPackage#getPropertiesEditionElement() - * @model - * @generated - */ -public interface PropertiesEditionElement extends EMFPropertyBinding, EEFElement { -} // PropertiesEditionElement diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesMultiEditionElement.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesMultiEditionElement.java deleted file mode 100644 index e67af3c55..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/PropertiesMultiEditionElement.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components; - -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; - -/** - * - * A representation of the model object 'Properties Multi Edition Element'. - * - * - * - * @see org.eclipse.emf.eef.components.ComponentsPackage#getPropertiesMultiEditionElement() - * @model - * @generated - */ -public interface PropertiesMultiEditionElement extends EMFMultiPropertiesBinding, EEFElement { -} // PropertiesMultiEditionElement diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/ComponentsFactoryImpl.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/ComponentsFactoryImpl.java deleted file mode 100644 index f768fe8f1..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/ComponentsFactoryImpl.java +++ /dev/null @@ -1,143 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.impl.EFactoryImpl; -import org.eclipse.emf.ecore.plugin.EcorePlugin; -import org.eclipse.emf.eef.components.ComponentsFactory; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.components.PropertiesMultiEditionElement; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class ComponentsFactoryImpl extends EFactoryImpl implements ComponentsFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static ComponentsFactory init() { - try { - ComponentsFactory theComponentsFactory = (ComponentsFactory)EPackage.Registry.INSTANCE - .getEFactory("http://www.eclipse.org/emf/eef/components/1.0.0"); - if (theComponentsFactory != null) { - return theComponentsFactory; - } - } catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new ComponentsFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public ComponentsFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case ComponentsPackage.PROPERTIES_EDITION_CONTEXT: - return createPropertiesEditionContext(); - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT: - return createPropertiesEditionComponent(); - case ComponentsPackage.PROPERTIES_EDITION_ELEMENT: - return createPropertiesEditionElement(); - case ComponentsPackage.PROPERTIES_MULTI_EDITION_ELEMENT: - return createPropertiesMultiEditionElement(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() - + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public PropertiesEditionContext createPropertiesEditionContext() { - PropertiesEditionContextImpl propertiesEditionContext = new PropertiesEditionContextImpl(); - return propertiesEditionContext; - } - - /** - * - * - * @generated - */ - public PropertiesEditionComponent createPropertiesEditionComponent() { - PropertiesEditionComponentImpl propertiesEditionComponent = new PropertiesEditionComponentImpl(); - return propertiesEditionComponent; - } - - /** - * - * - * @generated - */ - public PropertiesEditionElement createPropertiesEditionElement() { - PropertiesEditionElementImpl propertiesEditionElement = new PropertiesEditionElementImpl(); - return propertiesEditionElement; - } - - /** - * - * - * @generated - */ - public PropertiesMultiEditionElement createPropertiesMultiEditionElement() { - PropertiesMultiEditionElementImpl propertiesMultiEditionElement = new PropertiesMultiEditionElementImpl(); - return propertiesMultiEditionElement; - } - - /** - * - * - * @generated - */ - public ComponentsPackage getComponentsPackage() { - return (ComponentsPackage)getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static ComponentsPackage getPackage() { - return ComponentsPackage.eINSTANCE; - } - -} //ComponentsFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/ComponentsPackageImpl.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/ComponentsPackageImpl.java deleted file mode 100644 index 524887736..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/ComponentsPackageImpl.java +++ /dev/null @@ -1,326 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.impl; - -import org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage; -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.impl.EPackageImpl; -import org.eclipse.emf.eef.components.ComponentsFactory; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.EEFElement; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.components.PropertiesMultiEditionElement; -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class ComponentsPackageImpl extends EPackageImpl implements ComponentsPackage { - /** - * - * - * @generated - */ - private EClass propertiesEditionContextEClass = null; - - /** - * - * - * @generated - */ - private EClass propertiesEditionComponentEClass = null; - - /** - * - * - * @generated - */ - private EClass propertiesEditionElementEClass = null; - - /** - * - * - * @generated - */ - private EClass propertiesMultiEditionElementEClass = null; - - /** - * - * - * @generated - */ - private EClass eefElementEClass = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.components.ComponentsPackage#eNS_URI - * @see #init() - * @generated - */ - private ComponentsPackageImpl() { - super(eNS_URI, ComponentsFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link ComponentsPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static ComponentsPackage init() { - if (isInited) - return (ComponentsPackage)EPackage.Registry.INSTANCE.getEPackage(ComponentsPackage.eNS_URI); - - // Obtain or create and register package - ComponentsPackageImpl theComponentsPackage = (ComponentsPackageImpl)(EPackage.Registry.INSTANCE - .get(eNS_URI) instanceof ComponentsPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) - : new ComponentsPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - GenModelPackage.eINSTANCE.eClass(); - MappingPackage.eINSTANCE.eClass(); - - // Create package meta-data objects - theComponentsPackage.createPackageContents(); - - // Initialize created meta-data - theComponentsPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theComponentsPackage.freeze(); - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(ComponentsPackage.eNS_URI, theComponentsPackage); - return theComponentsPackage; - } - - /** - * - * - * @generated - */ - public EClass getPropertiesEditionContext() { - return propertiesEditionContextEClass; - } - - /** - * - * - * @generated - */ - public EReference getPropertiesEditionContext_Model() { - return (EReference)propertiesEditionContextEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getPropertiesEditionComponent() { - return propertiesEditionComponentEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getPropertiesEditionComponent_Explicit() { - return (EAttribute)propertiesEditionComponentEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getPropertiesEditionElement() { - return propertiesEditionElementEClass; - } - - /** - * - * - * @generated - */ - public EClass getPropertiesMultiEditionElement() { - return propertiesMultiEditionElementEClass; - } - - /** - * - * - * @generated - */ - public EClass getEEFElement() { - return eefElementEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getEEFElement_HelpID() { - return (EAttribute)eefElementEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public ComponentsFactory getComponentsFactory() { - return (ComponentsFactory)getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) - return; - isCreated = true; - - // Create classes and their features - propertiesEditionContextEClass = createEClass(PROPERTIES_EDITION_CONTEXT); - createEReference(propertiesEditionContextEClass, PROPERTIES_EDITION_CONTEXT__MODEL); - - propertiesEditionComponentEClass = createEClass(PROPERTIES_EDITION_COMPONENT); - createEAttribute(propertiesEditionComponentEClass, PROPERTIES_EDITION_COMPONENT__EXPLICIT); - - propertiesEditionElementEClass = createEClass(PROPERTIES_EDITION_ELEMENT); - - propertiesMultiEditionElementEClass = createEClass(PROPERTIES_MULTI_EDITION_ELEMENT); - - eefElementEClass = createEClass(EEF_ELEMENT); - createEAttribute(eefElementEClass, EEF_ELEMENT__HELP_ID); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) - return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - MappingPackage theMappingPackage = (MappingPackage)EPackage.Registry.INSTANCE - .getEPackage(MappingPackage.eNS_URI); - GenModelPackage theGenModelPackage = (GenModelPackage)EPackage.Registry.INSTANCE - .getEPackage(GenModelPackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - propertiesEditionContextEClass.getESuperTypes().add(theMappingPackage.getDatabinding()); - propertiesEditionComponentEClass.getESuperTypes().add(theMappingPackage.getEMFElementBinding()); - propertiesEditionComponentEClass.getESuperTypes().add(this.getEEFElement()); - propertiesEditionElementEClass.getESuperTypes().add(theMappingPackage.getEMFPropertyBinding()); - propertiesEditionElementEClass.getESuperTypes().add(this.getEEFElement()); - propertiesMultiEditionElementEClass.getESuperTypes().add( - theMappingPackage.getEMFMultiPropertiesBinding()); - propertiesMultiEditionElementEClass.getESuperTypes().add(this.getEEFElement()); - - // Initialize classes and features; add operations and parameters - initEClass(propertiesEditionContextEClass, PropertiesEditionContext.class, - "PropertiesEditionContext", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getPropertiesEditionContext_Model(), theGenModelPackage.getGenPackage(), null, - "model", null, 1, 1, PropertiesEditionContext.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - - initEClass(propertiesEditionComponentEClass, PropertiesEditionComponent.class, - "PropertiesEditionComponent", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getPropertiesEditionComponent_Explicit(), ecorePackage.getEBoolean(), "explicit", - "true", 0, 1, PropertiesEditionComponent.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, - !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(propertiesEditionElementEClass, PropertiesEditionElement.class, - "PropertiesEditionElement", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(propertiesMultiEditionElementEClass, PropertiesMultiEditionElement.class, - "PropertiesMultiEditionElement", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(eefElementEClass, EEFElement.class, "EEFElement", IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getEEFElement_HelpID(), ecorePackage.getEString(), "helpID", null, 0, 1, - EEFElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, - IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - // Create resource - createResource(eNS_URI); - } - -} //ComponentsPackageImpl diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/EEFElementImpl.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/EEFElementImpl.java deleted file mode 100644 index 9c4a04123..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/EEFElementImpl.java +++ /dev/null @@ -1,170 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.EEFElement; - -/** - * - * An implementation of the model object 'EEF Element'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.components.impl.EEFElementImpl#getHelpID Help ID}
  • - *
- *

- * - * @generated - */ -public abstract class EEFElementImpl extends EObjectImpl implements EEFElement { - /** - * The default value of the '{@link #getHelpID() Help ID}' attribute. - * - * - * @see #getHelpID() - * @generated - * @ordered - */ - protected static final String HELP_ID_EDEFAULT = null; - - /** - * The cached value of the '{@link #getHelpID() Help ID}' attribute. - * - * - * @see #getHelpID() - * @generated - * @ordered - */ - protected String helpID = HELP_ID_EDEFAULT; - - /** - * - * - * @generated - */ - protected EEFElementImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ComponentsPackage.Literals.EEF_ELEMENT; - } - - /** - * - * - * @generated - */ - public String getHelpID() { - return helpID; - } - - /** - * - * - * @generated - */ - public void setHelpID(String newHelpID) { - String oldHelpID = helpID; - helpID = newHelpID; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, ComponentsPackage.EEF_ELEMENT__HELP_ID, - oldHelpID, helpID)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ComponentsPackage.EEF_ELEMENT__HELP_ID: - return getHelpID(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ComponentsPackage.EEF_ELEMENT__HELP_ID: - setHelpID((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ComponentsPackage.EEF_ELEMENT__HELP_ID: - setHelpID(HELP_ID_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ComponentsPackage.EEF_ELEMENT__HELP_ID: - return HELP_ID_EDEFAULT == null ? helpID != null : !HELP_ID_EDEFAULT.equals(helpID); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (helpID: "); - result.append(helpID); - result.append(')'); - return result.toString(); - } - -} //EEFElementImpl diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionComponentImpl.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionComponentImpl.java deleted file mode 100644 index ecce83c40..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionComponentImpl.java +++ /dev/null @@ -1,262 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.EEFElement; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.impl.EMFElementBindingImpl; - -/** - * - * An implementation of the model object 'Properties Edition Component'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.components.impl.PropertiesEditionComponentImpl#getHelpID Help ID}
  • - *
  • {@link org.eclipse.emf.eef.components.impl.PropertiesEditionComponentImpl#isExplicit Explicit}
  • - *
- *

- * - * @generated - */ -public class PropertiesEditionComponentImpl extends EMFElementBindingImpl implements PropertiesEditionComponent { - /** - * The default value of the '{@link #getHelpID() Help ID}' attribute. - * - * - * @see #getHelpID() - * @generated - * @ordered - */ - protected static final String HELP_ID_EDEFAULT = null; - - /** - * The cached value of the '{@link #getHelpID() Help ID}' attribute. - * - * - * @see #getHelpID() - * @generated - * @ordered - */ - protected String helpID = HELP_ID_EDEFAULT; - - /** - * The default value of the '{@link #isExplicit() Explicit}' attribute. - * - * - * @see #isExplicit() - * @generated - * @ordered - */ - protected static final boolean EXPLICIT_EDEFAULT = true; - - /** - * The cached value of the '{@link #isExplicit() Explicit}' attribute. - * - * - * @see #isExplicit() - * @generated - * @ordered - */ - protected boolean explicit = EXPLICIT_EDEFAULT; - - /** - * - * - * @generated - */ - protected PropertiesEditionComponentImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ComponentsPackage.Literals.PROPERTIES_EDITION_COMPONENT; - } - - /** - * - * - * @generated - */ - public String getHelpID() { - return helpID; - } - - /** - * - * - * @generated - */ - public void setHelpID(String newHelpID) { - String oldHelpID = helpID; - helpID = newHelpID; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - ComponentsPackage.PROPERTIES_EDITION_COMPONENT__HELP_ID, oldHelpID, helpID)); - } - - /** - * - * - * @generated - */ - public boolean isExplicit() { - return explicit; - } - - /** - * - * - * @generated - */ - public void setExplicit(boolean newExplicit) { - boolean oldExplicit = explicit; - explicit = newExplicit; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - ComponentsPackage.PROPERTIES_EDITION_COMPONENT__EXPLICIT, oldExplicit, explicit)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__HELP_ID: - return getHelpID(); - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__EXPLICIT: - return isExplicit(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__HELP_ID: - setHelpID((String)newValue); - return; - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__EXPLICIT: - setExplicit((Boolean)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__HELP_ID: - setHelpID(HELP_ID_EDEFAULT); - return; - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__EXPLICIT: - setExplicit(EXPLICIT_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__HELP_ID: - return HELP_ID_EDEFAULT == null ? helpID != null : !HELP_ID_EDEFAULT.equals(helpID); - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__EXPLICIT: - return explicit != EXPLICIT_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class baseClass) { - if (baseClass == EEFElement.class) { - switch (derivedFeatureID) { - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT__HELP_ID: - return ComponentsPackage.EEF_ELEMENT__HELP_ID; - default: - return -1; - } - } - return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); - } - - /** - * - * - * @generated - */ - @Override - public int eDerivedStructuralFeatureID(int baseFeatureID, Class baseClass) { - if (baseClass == EEFElement.class) { - switch (baseFeatureID) { - case ComponentsPackage.EEF_ELEMENT__HELP_ID: - return ComponentsPackage.PROPERTIES_EDITION_COMPONENT__HELP_ID; - default: - return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (helpID: "); - result.append(helpID); - result.append(", explicit: "); - result.append(explicit); - result.append(')'); - return result.toString(); - } - -} //PropertiesEditionComponentImpl diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionContextImpl.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionContextImpl.java deleted file mode 100644 index ae3577042..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionContextImpl.java +++ /dev/null @@ -1,165 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.impl; - -import org.eclipse.emf.codegen.ecore.genmodel.GenPackage; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.mapping.impl.DatabindingImpl; - -/** - * - * An implementation of the model object 'Properties Edition Context'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.components.impl.PropertiesEditionContextImpl#getModel Model}
  • - *
- *

- * - * @generated - */ -public class PropertiesEditionContextImpl extends DatabindingImpl implements PropertiesEditionContext { - /** - * The cached value of the '{@link #getModel() Model}' reference. - * - * - * @see #getModel() - * @generated - * @ordered - */ - protected GenPackage model; - - /** - * - * - * @generated - */ - protected PropertiesEditionContextImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ComponentsPackage.Literals.PROPERTIES_EDITION_CONTEXT; - } - - /** - * - * - * @generated - */ - public GenPackage getModel() { - if (model != null && model.eIsProxy()) { - InternalEObject oldModel = (InternalEObject)model; - model = (GenPackage)eResolveProxy(oldModel); - if (model != oldModel) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - ComponentsPackage.PROPERTIES_EDITION_CONTEXT__MODEL, oldModel, model)); - } - } - return model; - } - - /** - * - * - * @generated - */ - public GenPackage basicGetModel() { - return model; - } - - /** - * - * - * @generated - */ - public void setModel(GenPackage newModel) { - GenPackage oldModel = model; - model = newModel; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - ComponentsPackage.PROPERTIES_EDITION_CONTEXT__MODEL, oldModel, model)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_CONTEXT__MODEL: - if (resolve) - return getModel(); - return basicGetModel(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_CONTEXT__MODEL: - setModel((GenPackage)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_CONTEXT__MODEL: - setModel((GenPackage)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_CONTEXT__MODEL: - return model != null; - } - return super.eIsSet(featureID); - } - -} //PropertiesEditionContextImpl diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionElementImpl.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionElementImpl.java deleted file mode 100644 index 2ceacda48..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesEditionElementImpl.java +++ /dev/null @@ -1,207 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.EEFElement; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.mapping.impl.EMFPropertyBindingImpl; - -/** - * - * An implementation of the model object 'Properties Edition Element'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.components.impl.PropertiesEditionElementImpl#getHelpID Help ID}
  • - *
- *

- * - * @generated - */ -public class PropertiesEditionElementImpl extends EMFPropertyBindingImpl implements PropertiesEditionElement { - /** - * The default value of the '{@link #getHelpID() Help ID}' attribute. - * - * - * @see #getHelpID() - * @generated - * @ordered - */ - protected static final String HELP_ID_EDEFAULT = null; - - /** - * The cached value of the '{@link #getHelpID() Help ID}' attribute. - * - * - * @see #getHelpID() - * @generated - * @ordered - */ - protected String helpID = HELP_ID_EDEFAULT; - - /** - * - * - * @generated - */ - protected PropertiesEditionElementImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ComponentsPackage.Literals.PROPERTIES_EDITION_ELEMENT; - } - - /** - * - * - * @generated - */ - public String getHelpID() { - return helpID; - } - - /** - * - * - * @generated - */ - public void setHelpID(String newHelpID) { - String oldHelpID = helpID; - helpID = newHelpID; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - ComponentsPackage.PROPERTIES_EDITION_ELEMENT__HELP_ID, oldHelpID, helpID)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_ELEMENT__HELP_ID: - return getHelpID(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_ELEMENT__HELP_ID: - setHelpID((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_ELEMENT__HELP_ID: - setHelpID(HELP_ID_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_EDITION_ELEMENT__HELP_ID: - return HELP_ID_EDEFAULT == null ? helpID != null : !HELP_ID_EDEFAULT.equals(helpID); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class baseClass) { - if (baseClass == EEFElement.class) { - switch (derivedFeatureID) { - case ComponentsPackage.PROPERTIES_EDITION_ELEMENT__HELP_ID: - return ComponentsPackage.EEF_ELEMENT__HELP_ID; - default: - return -1; - } - } - return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); - } - - /** - * - * - * @generated - */ - @Override - public int eDerivedStructuralFeatureID(int baseFeatureID, Class baseClass) { - if (baseClass == EEFElement.class) { - switch (baseFeatureID) { - case ComponentsPackage.EEF_ELEMENT__HELP_ID: - return ComponentsPackage.PROPERTIES_EDITION_ELEMENT__HELP_ID; - default: - return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (helpID: "); - result.append(helpID); - result.append(')'); - return result.toString(); - } - -} //PropertiesEditionElementImpl diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesMultiEditionElementImpl.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesMultiEditionElementImpl.java deleted file mode 100644 index 4a2e01aaa..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/impl/PropertiesMultiEditionElementImpl.java +++ /dev/null @@ -1,207 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.EEFElement; -import org.eclipse.emf.eef.components.PropertiesMultiEditionElement; -import org.eclipse.emf.eef.mapping.impl.EMFMultiPropertiesBindingImpl; - -/** - * - * An implementation of the model object 'Properties Multi Edition Element'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.components.impl.PropertiesMultiEditionElementImpl#getHelpID Help ID}
  • - *
- *

- * - * @generated - */ -public class PropertiesMultiEditionElementImpl extends EMFMultiPropertiesBindingImpl implements PropertiesMultiEditionElement { - /** - * The default value of the '{@link #getHelpID() Help ID}' attribute. - * - * - * @see #getHelpID() - * @generated - * @ordered - */ - protected static final String HELP_ID_EDEFAULT = null; - - /** - * The cached value of the '{@link #getHelpID() Help ID}' attribute. - * - * - * @see #getHelpID() - * @generated - * @ordered - */ - protected String helpID = HELP_ID_EDEFAULT; - - /** - * - * - * @generated - */ - protected PropertiesMultiEditionElementImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ComponentsPackage.Literals.PROPERTIES_MULTI_EDITION_ELEMENT; - } - - /** - * - * - * @generated - */ - public String getHelpID() { - return helpID; - } - - /** - * - * - * @generated - */ - public void setHelpID(String newHelpID) { - String oldHelpID = helpID; - helpID = newHelpID; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - ComponentsPackage.PROPERTIES_MULTI_EDITION_ELEMENT__HELP_ID, oldHelpID, helpID)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_MULTI_EDITION_ELEMENT__HELP_ID: - return getHelpID(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_MULTI_EDITION_ELEMENT__HELP_ID: - setHelpID((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_MULTI_EDITION_ELEMENT__HELP_ID: - setHelpID(HELP_ID_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ComponentsPackage.PROPERTIES_MULTI_EDITION_ELEMENT__HELP_ID: - return HELP_ID_EDEFAULT == null ? helpID != null : !HELP_ID_EDEFAULT.equals(helpID); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class baseClass) { - if (baseClass == EEFElement.class) { - switch (derivedFeatureID) { - case ComponentsPackage.PROPERTIES_MULTI_EDITION_ELEMENT__HELP_ID: - return ComponentsPackage.EEF_ELEMENT__HELP_ID; - default: - return -1; - } - } - return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); - } - - /** - * - * - * @generated - */ - @Override - public int eDerivedStructuralFeatureID(int baseFeatureID, Class baseClass) { - if (baseClass == EEFElement.class) { - switch (baseFeatureID) { - case ComponentsPackage.EEF_ELEMENT__HELP_ID: - return ComponentsPackage.PROPERTIES_MULTI_EDITION_ELEMENT__HELP_ID; - default: - return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (helpID: "); - result.append(helpID); - result.append(')'); - return result.toString(); - } - -} //PropertiesMultiEditionElementImpl diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/util/ComponentsAdapterFactory.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/util/ComponentsAdapterFactory.java deleted file mode 100644 index 34b2f85b3..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/util/ComponentsAdapterFactory.java +++ /dev/null @@ -1,345 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.EEFElement; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.components.PropertiesMultiEditionElement; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.AbstractPropertyBinding; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.components.ComponentsPackage - * @generated - */ -public class ComponentsAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static ComponentsPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public ComponentsAdapterFactory() { - if (modelPackage == null) { - modelPackage = ComponentsPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject)object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected ComponentsSwitch modelSwitch = new ComponentsSwitch() { - @Override - public Adapter casePropertiesEditionContext(PropertiesEditionContext object) { - return createPropertiesEditionContextAdapter(); - } - - @Override - public Adapter casePropertiesEditionComponent(PropertiesEditionComponent object) { - return createPropertiesEditionComponentAdapter(); - } - - @Override - public Adapter casePropertiesEditionElement(PropertiesEditionElement object) { - return createPropertiesEditionElementAdapter(); - } - - @Override - public Adapter casePropertiesMultiEditionElement(PropertiesMultiEditionElement object) { - return createPropertiesMultiEditionElementAdapter(); - } - - @Override - public Adapter caseEEFElement(EEFElement object) { - return createEEFElementAdapter(); - } - - @Override - public Adapter caseDocumentedElement(DocumentedElement object) { - return createDocumentedElementAdapter(); - } - - @Override - public Adapter caseDatabinding(Databinding object) { - return createDatabindingAdapter(); - } - - @Override - public Adapter caseAbstractElementBinding(AbstractElementBinding object) { - return createAbstractElementBindingAdapter(); - } - - @Override - public Adapter caseEMFElementBinding(EMFElementBinding object) { - return createEMFElementBindingAdapter(); - } - - @Override - public Adapter caseAbstractPropertyBinding(AbstractPropertyBinding object) { - return createAbstractPropertyBindingAdapter(); - } - - @Override - public Adapter caseEMFPropertyBinding(EMFPropertyBinding object) { - return createEMFPropertyBindingAdapter(); - } - - @Override - public Adapter caseEMFMultiPropertiesBinding(EMFMultiPropertiesBinding object) { - return createEMFMultiPropertiesBindingAdapter(); - } - - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject)target); - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.components.PropertiesEditionContext Properties Edition Context}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.components.PropertiesEditionContext - * @generated - */ - public Adapter createPropertiesEditionContextAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.components.PropertiesEditionComponent Properties Edition Component}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.components.PropertiesEditionComponent - * @generated - */ - public Adapter createPropertiesEditionComponentAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.components.PropertiesEditionElement Properties Edition Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.components.PropertiesEditionElement - * @generated - */ - public Adapter createPropertiesEditionElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.components.PropertiesMultiEditionElement Properties Multi Edition Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.components.PropertiesMultiEditionElement - * @generated - */ - public Adapter createPropertiesMultiEditionElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.components.EEFElement EEF Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.components.EEFElement - * @generated - */ - public Adapter createEEFElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.DocumentedElement Documented Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.DocumentedElement - * @generated - */ - public Adapter createDocumentedElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.Databinding Databinding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.Databinding - * @generated - */ - public Adapter createDatabindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding Abstract Element Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding - * @generated - */ - public Adapter createAbstractElementBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.EMFElementBinding EMF Element Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.EMFElementBinding - * @generated - */ - public Adapter createEMFElementBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding Abstract Property Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.AbstractPropertyBinding - * @generated - */ - public Adapter createAbstractPropertyBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.EMFPropertyBinding EMF Property Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.EMFPropertyBinding - * @generated - */ - public Adapter createEMFPropertyBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding EMF Multi Properties Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding - * @generated - */ - public Adapter createEMFMultiPropertiesBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //ComponentsAdapterFactory diff --git a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/util/ComponentsSwitch.java b/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/util/ComponentsSwitch.java deleted file mode 100644 index 17c2389bd..000000000 --- a/plugins/org.eclipse.emf.eef.components/src-gen/org/eclipse/emf/eef/components/util/ComponentsSwitch.java +++ /dev/null @@ -1,364 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.components.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.components.EEFElement; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.components.PropertiesMultiEditionElement; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.AbstractPropertyBinding; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.components.ComponentsPackage - * @generated - */ -public class ComponentsSwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static ComponentsPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public ComponentsSwitch() { - if (modelPackage == null) { - modelPackage = ComponentsPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } else { - List eSuperTypes = theEClass.getESuperTypes(); - return eSuperTypes.isEmpty() ? defaultCase(theEObject) : doSwitch(eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case ComponentsPackage.PROPERTIES_EDITION_CONTEXT: { - PropertiesEditionContext propertiesEditionContext = (PropertiesEditionContext)theEObject; - T result = casePropertiesEditionContext(propertiesEditionContext); - if (result == null) - result = caseDatabinding(propertiesEditionContext); - if (result == null) - result = caseDocumentedElement(propertiesEditionContext); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case ComponentsPackage.PROPERTIES_EDITION_COMPONENT: { - PropertiesEditionComponent propertiesEditionComponent = (PropertiesEditionComponent)theEObject; - T result = casePropertiesEditionComponent(propertiesEditionComponent); - if (result == null) - result = caseEMFElementBinding(propertiesEditionComponent); - if (result == null) - result = caseEEFElement(propertiesEditionComponent); - if (result == null) - result = caseAbstractElementBinding(propertiesEditionComponent); - if (result == null) - result = caseDocumentedElement(propertiesEditionComponent); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case ComponentsPackage.PROPERTIES_EDITION_ELEMENT: { - PropertiesEditionElement propertiesEditionElement = (PropertiesEditionElement)theEObject; - T result = casePropertiesEditionElement(propertiesEditionElement); - if (result == null) - result = caseEMFPropertyBinding(propertiesEditionElement); - if (result == null) - result = caseEEFElement(propertiesEditionElement); - if (result == null) - result = caseAbstractPropertyBinding(propertiesEditionElement); - if (result == null) - result = caseDocumentedElement(propertiesEditionElement); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case ComponentsPackage.PROPERTIES_MULTI_EDITION_ELEMENT: { - PropertiesMultiEditionElement propertiesMultiEditionElement = (PropertiesMultiEditionElement)theEObject; - T result = casePropertiesMultiEditionElement(propertiesMultiEditionElement); - if (result == null) - result = caseEMFMultiPropertiesBinding(propertiesMultiEditionElement); - if (result == null) - result = caseEEFElement(propertiesMultiEditionElement); - if (result == null) - result = caseAbstractPropertyBinding(propertiesMultiEditionElement); - if (result == null) - result = caseDocumentedElement(propertiesMultiEditionElement); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case ComponentsPackage.EEF_ELEMENT: { - EEFElement eefElement = (EEFElement)theEObject; - T result = caseEEFElement(eefElement); - if (result == null) - result = defaultCase(theEObject); - return result; - } - default: - return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'Properties Edition Context'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Properties Edition Context'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T casePropertiesEditionContext(PropertiesEditionContext object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Properties Edition Component'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Properties Edition Component'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T casePropertiesEditionComponent(PropertiesEditionComponent object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Properties Edition Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Properties Edition Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T casePropertiesEditionElement(PropertiesEditionElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Properties Multi Edition Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Properties Multi Edition Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T casePropertiesMultiEditionElement(PropertiesMultiEditionElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EEF Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EEF Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFElement(EEFElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Documented Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Documented Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDocumentedElement(DocumentedElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Databinding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Databinding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDatabinding(Databinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Abstract Element Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Abstract Element Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAbstractElementBinding(AbstractElementBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EMF Element Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EMF Element Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEMFElementBinding(EMFElementBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Abstract Property Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Abstract Property Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAbstractPropertyBinding(AbstractPropertyBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EMF Property Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EMF Property Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEMFPropertyBinding(EMFPropertyBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EMF Multi Properties Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EMF Multi Properties Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEMFMultiPropertiesBinding(EMFMultiPropertiesBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //ComponentsSwitch diff --git a/plugins/org.eclipse.emf.eef.editor.model/.classpath b/plugins/org.eclipse.emf.eef.editor.model/.classpath deleted file mode 100644 index f9c46b584..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.editor.model/.gitignore b/plugins/org.eclipse.emf.eef.editor.model/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.editor.model/.project b/plugins/org.eclipse.emf.eef.editor.model/.project deleted file mode 100644 index cbcfba75f..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.editor.model - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.editor.model/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.editor.model/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index 8f07037c6..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,8 +0,0 @@ -#Wed Dec 22 22:56:53 CET 2010 -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.editor.model/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.editor.model/META-INF/MANIFEST.MF deleted file mode 100644 index f12f93e6b..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/META-INF/MANIFEST.MF +++ /dev/null @@ -1,31 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Editor Model -Bundle-SymbolicName: org.eclipse.emf.eef.editor.model;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Activator: org.eclipse.emf.eef.extended.editor.provider.ExtendedEditPlugin$Implementation -Bundle-Vendor: Eclipse Modeling Project -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.extended.editor, - org.eclipse.emf.eef.extended.editor.impl, - org.eclipse.emf.eef.extended.editor.provider, - org.eclipse.emf.eef.extended.editor.util, - org.eclipse.emf.eef.extended.query, - org.eclipse.emf.eef.extended.query.impl, - org.eclipse.emf.eef.extended.query.provider, - org.eclipse.emf.eef.extended.query.util -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.emf.ecore;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.eef.components;visibility:=reexport, - org.eclipse.emf.codegen.ecore;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.eef.mapping;visibility:=reexport, - org.eclipse.emf.eef.views;visibility:=reexport, - org.eclipse.emf.edit;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.eef.components.edit;visibility:=reexport, - org.eclipse.emf.ecore.edit;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.codegen.ecore.ui;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.eef.mapping.edit;visibility:=reexport, - org.eclipse.emf.eef.views.edit;visibility:=reexport -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.editor.model/about.html b/plugins/org.eclipse.emf.eef.editor.model/about.html deleted file mode 100755 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.editor.model/build.properties b/plugins/org.eclipse.emf.eef.editor.model/build.properties deleted file mode 100644 index 1b789c93a..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/build.properties +++ /dev/null @@ -1,21 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -bin.includes = .,\ - icons/,\ - META-INF/,\ - plugin.xml,\ - plugin.properties,\ - about.html -jars.compile.order = . -source.. = src-gen/ -output.. = bin/ -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_PartFilter.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_PartFilter.gif deleted file mode 100644 index 433da751138a8eda6edad347f424c4b56142eae5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6eEt37=$jk!@9(d?wCw-?`1$en|L@y3 zG&D4=xfa}W%(8fmPGsAz>1sf1sf1sf? diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateAbstractElementBinding_subElements_StaticEEFEditorContribution.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateAbstractElementBinding_subElements_StaticEEFEditorContribution.gif deleted file mode 100644 index 08d7d5221061a7dfe11b142270f8685878e8b04c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{Qmm;&Cxga=ik3ndFlWE`1$en|L@y3 zG&D4=xfa}W%(8fmPGsAz>1sf+YZ#L@u~AUhdYV-ytnQX=it7-pV5JmtdHN&U@zlS({|Kb!Pi%buhurrs}= zoar2>F?;z5c9A}8}5D03R{UYJRqLb}R3lrSrZ?x3h&eb~oGCiLm Pr=}^ju_;?sk--`OWIJQ? diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_bindings_DynamicEEFEditorContribution.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_bindings_DynamicEEFEditorContribution.gif deleted file mode 100644 index d08a6f84a0349c6c6d745bd33039a9674db30fdb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{Qmm;&Cxga=ik3ndFlWE`1$en|L@y3 zG&CTK@0zX#L|Z2*uj`Uu+9WlvQfy|4@V~$Bf#~n&^FZ|H`QqPqn}Mc5fZ|UUMi5H} zM1bsMV2x2w=u3&TQ)8HU_VAPoTPO85_f0DCH2!STb1i$4rkHxaRC1$ zwC0>T>1M^Cqjulh#X=ycVfKrJ4~tH=Gc8PTlfThYb30e-^vm>ohMbzF)W)W4RYeAC E0L7$df&c&j diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_bindings_EEFEditorContribution.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_bindings_EEFEditorContribution.gif deleted file mode 100644 index c41c6fc9d2e8c0eccdee7afabd66f7faa32a5c6c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6eEsqJ=#4k?_usEvcIp5B`1$en|L@y3 zG&KDF`uok%H}~h?zf^f?*K{=?+B!*jU6=gQCaHOqVlzvG|NVUrM1Mb@2ckdE7yrK7 z3^WY_6o0ZXf>=5r0%RuxYm9q!{Ee2H+qqh&U#90X QOV diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_bindings_StaticEEFEditorContribution.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_bindings_StaticEEFEditorContribution.gif deleted file mode 100644 index d08a6f84a0349c6c6d745bd33039a9674db30fdb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{Qmm;&Cxga=ik3ndFlWE`1$en|L@y3 zG&CTK@0zX#L|Z2*uj`Uu+9WlvQfy|4@V~$Bf#~n&^FZ|H`QqPqn}Mc5fZ|UUMi5H} zM1bsMV2x2w=u3&TQ)8HU_VAPoTPO85_f0DCH2!STb1i$4rkHxaRC1$ zwC0>T>1M^Cqjulh#X=ycVfKrJ4~tH=Gc8PTlfThYb30e-^vm>ohMbzF)W)W4RYeAC E0L7$df&c&j diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_categories_EEFEditorContributions.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_categories_EEFEditorContributions.gif deleted file mode 100644 index 4833facbbbe2e81dbf0a255d06a51ec1c7580442..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b|NQ$64Gj(s4*&nh&yTnNf8QR+ z{r&a#o1<^;&%b}E^3ty9YCyDglJdGP`K3)#^D4z=mI(j*`yPn?em)OGf1WS?eYY8C z8U!f*WMKrcbU*~iP6pN(1%MmLCOy}(CuxeQ_e&*b zItOaZUVegIq)%(ksgrJ23_5D}yf*NMONcgbmWINNs1ULB`Ej71uwNAfG&u7S~ OX-aKu%2rimum%8A;AA}j diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_categories_EEFEditorPages.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_categories_EEFEditorPages.gif deleted file mode 100644 index b71213d94286ac9d3bc5f69abad09e809000e962..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6?0NB`=jP3{GiMwQ9Qgk~etx|D|NHh0 z4Gq7){(f`x&HefJFI8UJHC+vewoX!B*CoHSNoroD*vt~)e}CTt(cjPKf#}ck#lP=1 z15JYf#h)yUAeIh@0NKgF8l#}lmlA2G#xV2j;VBokPU>&&n^fXy{Mn@ETJ|JOG4+0_ z=y|i7M*NoTA1J_f1{=5cCOaxm+AQo PIW1sf_ja)m2x^%9BH_cLlkH3k6Wru)wA9?r)jIt$J)a?` OrYW_tDO**M!5RS8zhv_O diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_views_TreeMasterPage.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateCategory_views_TreeMasterPage.gif deleted file mode 100644 index 027f1b702718a54abdad340f25abd1f6f0f8419f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@bX4;vCh6V=*hyVZM=f~Uszi$uZ z{{H&=&Cxga=ik3nd1=>lH6YqLNqJqD{L&_=d6i-_ON9UZeGf!`Kc5GpKhGEczS|5m z4FVK@vM_>JIv@gMCj)DYfrlb&nYlQhND`=ydI zodY#yFF(O9(x)}&)JZoh1|7Bg-YymbK@GECBz#zOvYlyRf}8w}mYUnSTBl#8=QHHg OG^I8+WvePOSOWn4T4T!q diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateContainer_elements_EEFMasterPage.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateContainer_elements_EEFMasterPage.gif deleted file mode 100644 index a982f41fa57c350730803e25688ee24ba455a18e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6Tx(i$EVyTlWpSHMzg-6@86$)=~Csc>1sf_ja)m2x^%9BH_cLlkH3k6Wru)wA9?r)jIt$J)a?` OrYW_tDO**M!5RS9g=F&p diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateContainer_elements_TreeMasterPage.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateContainer_elements_TreeMasterPage.gif deleted file mode 100644 index 25c8e63061c7a44411f97daa8e01d576180b57eb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@bX4;vCh6V=*hyVZM=f~Uszi$uZ z{{H>-&6}h5@6W$JIv@gMCj)DYfrlb&nYlQhND`=ydI zodY#yFF(O9(x)}&)JZoh1|7Bg-YymbK@GECBz#zOvYlyRf}8w}mYUnSTBl#8=QHHg OG^I8+WvePOSOWn5AY;n_ diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_bindings_DynamicEEFEditorContribution.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_bindings_DynamicEEFEditorContribution.gif deleted file mode 100644 index d08a6f84a0349c6c6d745bd33039a9674db30fdb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{Qmm;&Cxga=ik3ndFlWE`1$en|L@y3 zG&CTK@0zX#L|Z2*uj`Uu+9WlvQfy|4@V~$Bf#~n&^FZ|H`QqPqn}Mc5fZ|UUMi5H} zM1bsMV2x2w=u3&TQ)8HU_VAPoTPO85_f0DCH2!STb1i$4rkHxaRC1$ zwC0>T>1M^Cqjulh#X=ycVfKrJ4~tH=Gc8PTlfThYb30e-^vm>ohMbzF)W)W4RYeAC E0L7$df&c&j diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_bindings_EEFEditorContribution.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_bindings_EEFEditorContribution.gif deleted file mode 100644 index c41c6fc9d2e8c0eccdee7afabd66f7faa32a5c6c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6eEsqJ=#4k?_usEvcIp5B`1$en|L@y3 zG&KDF`uok%H}~h?zf^f?*K{=?+B!*jU6=gQCaHOqVlzvG|NVUrM1Mb@2ckdE7yrK7 z3^WY_6o0ZXf>=5r0%RuxYm9q!{Ee2H+qqh&U#90X QOV diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_bindings_StaticEEFEditorContribution.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_bindings_StaticEEFEditorContribution.gif deleted file mode 100644 index d08a6f84a0349c6c6d745bd33039a9674db30fdb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{Qmm;&Cxga=ik3ndFlWE`1$en|L@y3 zG&CTK@0zX#L|Z2*uj`Uu+9WlvQfy|4@V~$Bf#~n&^FZ|H`QqPqn}Mc5fZ|UUMi5H} zM1bsMV2x2w=u3&TQ)8HU_VAPoTPO85_f0DCH2!STb1i$4rkHxaRC1$ zwC0>T>1M^Cqjulh#X=ycVfKrJ4~tH=Gc8PTlfThYb30e-^vm>ohMbzF)W)W4RYeAC E0L7$df&c&j diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_categories_EEFEditorContributions.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateDatabinding_categories_EEFEditorContributions.gif deleted file mode 100644 index 4833facbbbe2e81dbf0a255d06a51ec1c7580442..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b|NQ$64Gj(s4*&nh&yTnNf8QR+ z{r&a#o1<^;&%b}E^3ty9YCyDglJdGP`K3)#^D4z=mI(j*`yPn?em)OGf1WS?eYY8C z8U!f*WMKrcbU*~iP6pN(1%MmLCOy}(CuxeQ_e&*b zItOaZUVegIq)%(ksgrJ23_5D}yf*NMONcgbmWINNs1ULB`Ej71uwNAfG&u7S~ OX-aKu%2rimum%8A;AA}j diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFEditorContribution_input_AllResourcesRootsRelativeInput.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFEditorContribution_input_AllResourcesRootsRelativeInput.gif deleted file mode 100644 index eb4681ab36c19a31d11b4bfd16b753a98e6e1a33..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{P_L##+#%2@6TU$sq+8-`1$en|L@y3 zG&Fqu@%!kFH}m)3uUvL%*K{=?+B!*jU6=gQCaHOqVlzvG|NVUrM1Mb@2ckdE7yrK7 z3^WY_6o0ZXf>=5r0%RuxYm9q!{Ee2H+qqh&U#90X Q_ja)m2x^%9BH_cLlkH3k6Wru)wA9?r)jIt$J)a?` OrYW_tDO**M!5RQO4`dbq diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFEditorContribution_model_AllResourcesRootsRelativeInput.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFEditorContribution_model_AllResourcesRootsRelativeInput.gif deleted file mode 100644 index eb4681ab36c19a31d11b4bfd16b753a98e6e1a33..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{P_L##+#%2@6TU$sq+8-`1$en|L@y3 zG&Fqu@%!kFH}m)3uUvL%*K{=?+B!*jU6=gQCaHOqVlzvG|NVUrM1Mb@2ckdE7yrK7 z3^WY_6o0ZXf>=5r0%RuxYm9q!{Ee2H+qqh&U#90X Q_ja)m2x^%9BH_cLlkH3k6Wru)wA9?r)jIt$J)a?` OrYW_tDO**M!5RQO4`dbq diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFPageInput_query_ExplicitPathQuery.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFPageInput_query_ExplicitPathQuery.gif deleted file mode 100644 index c449285fd3579ff6e5719f57abaccfe292bfdbb3..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6Tx+^^Ecn=5r z0%RuxYm9q!{Ee2H+qqh&U#90X;DgXcg diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFPageInput_query_OCLQuery.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateEEFPageInput_query_OCLQuery.gif deleted file mode 100644 index 9f36b38d3493026e94c45b05ba8721f82e9aa92e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6yx4Q;X3wTGX)_NvH2nV`KR@37|9$(0 zhK6fR*Nz1rTVuJVO{ZJIv@gMCj)DYfrlb&nYlQhND`=ydI zodY#yFF(O9(x)}&)JZoh1|7Bg-YymbK@GECBz#zOvYlyRf}8w}mYUnSTBl#8=QHHg OG^I8+WvePOSOWlvMPkeV diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateViewsRepository_views_EEFMasterPage.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateViewsRepository_views_EEFMasterPage.gif deleted file mode 100644 index e7da41eb872d901afe76d198219425f0ebe16344..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6Tx(i$EVyTlWpSHM z9H=pS`3ZKBKCL;YPP$n!=&0TIcCio$YMA{Z;lrYn?Mw?3+~jYx)ZEV1I{h*|pCPBF NDYdaFTUC+48UU>DU{C-6 diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateViewsRepository_views_StandardFormPage.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateViewsRepository_views_StandardFormPage.gif deleted file mode 100644 index 1d1578bb715d247f59e8d851a0b328bf6fb2858e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?74GqD^j{W~1KR@37|9yKP z7cM^2IBnN-H6YqLNqJqD{L&_=d6i-_ON9UZeGf!`Kc5GpKhGEczS|5m4FVK@vM_>J zIv@gMCj)DYfrlb&nYlQhND`=ydIodY#yFF(O9 z(x)}&)JZoh1|7Bg-YymbK@GECBz#zOvYlyRf}8w}mYUnSTBl#8=QHHgG^I8+WvePO GSOWmJ6k)dj diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateViewsRepository_views_TreeMasterPage.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/ctool16/CreateViewsRepository_views_TreeMasterPage.gif deleted file mode 100644 index a85ee8f4953030db7eebfb75457273fe50738d6d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@bX4;vCh6V=*hyVZM=f~Uszi$uZ z0>$UdnFD0ZG)~(!T@8q~PEuaiCBL*uYF?$-%o5>$f8PVq-_PfP=+E=Tzwb5!O@jc% zpDc_ZmJWyj*~!2fqoB~25^1N#F!Su;DHpa*>Tm9wRN`s;*`()M_9RU)^?s@3Oy@w2 z*~?F`i}Y#DId#&_ia|&1zPF2oKv2W%7YQF0oor`XnBXRVqow9{uGZ<7>G=#fHBG6F KP1&l74AubMuV9Y= diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/AllResourcesRootsRelativeInput.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/AllResourcesRootsRelativeInput.gif deleted file mode 100644 index 14a11a578c66ef0ac28048456c8b86dcb4bdca4a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 163 zcmZ?wbhEHb6krfw*v!Dd(9jS+fByXa`|sc1|Ns8{|Ns9VIB)LMKbXSg zuwXNz=+UtA+|z`)6%1JVgHgMmfQ;H2m3y%w*(d{g0nSm?Ull=W6hg4cqDUv2b0PE)&T WR^GExlV5i^W2f7Zi9*7R4AuatYBLM~ diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/EEFEditorContribution.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/EEFEditorContribution.gif deleted file mode 100644 index 1ff93cb93a44b7e962e8d80b6bbb4b7cfc7ff7d3..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 587 zcmZ?wbhEHb6krfwc*el+~!>`vLe|`M= z`}zA{Uw{1h_Vdrr-+zDq`TP9iyF0I+oqv4WYFbRfy4s|5b*UR03%7S0P7Ky-_cfgo zZaFE^X?CJ*f0XBf4A-fNzVovJm*j^oDhQgB8!#g)dR0aIn(CM(Wsx%rGB!2mZfS4Z zHPd}=%DMALXUv#5dshFyzwehVY`=Sb*W&qI^XK$#T~)VXdE@FOt$)9qKfbl_$mZgM z8_V~utK7M!`tRrSTPG@Sous^Ly4s)Ti|18}Eo+oo)+DvGNork}{O`NXGfRa3|NqZ0 zxPjtN7DfgJF9scuGeL2}z`mlvtEsuAwXNN;#j?An+sMe#ptH%6W!iKWetQQ42Ztsr z25~`#rOfUY7ItE6^md0s pO_D7cA}1OW53>tth>0z5d~vj~Tf%ss!jnadkN3;6vobMQ0{{{r%xWSy(??~em=i-qVm>B z%Dbkk{dvB4UZvQwMyX{@QcIhp)^*AMzS}&rMEL*z{|tnH;!hSv1_l!b9gsqhpBUH{ zILs>W(7EJtBBf}DR2SQY7fvcMv9q>Zd~mQqPfRV!t2A(BhAe~l0kMXp`TSg8J0}W= zurW7&nUi3kqpxS8%Ec!v%;nDjGURhnOVj{uDvWu;)ql=GA)kN%wn55#AX)|U>yO}Ilv}B3Qxi#xHh_XtZ+p&vf QC!55%qfd^QI5JoR03ive1ONa4 diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/EEFEditorPages.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/EEFEditorPages.gif deleted file mode 100644 index 761a07802727450831bcb1c2a5293d88f53f3489..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 604 zcmZ?wbhEHb6krfwc*el+=g+^tfB${|@#p8SKh0fJ?!NeO|K*RTZ-2i0@axB~zYkyk z{Py#2{^b3KFFgsW-w@WcIjnheRO{C0)~)d!+v7X8C->}3>Diglzvt+cr!Hly+{#zG zRjl@`T;p52-nV95V8g~Uk3M(yPFQ{E?e-h*58wNkvH4;Cwnr7ap0pfzHsRQdd1qdI z`ThUgWI0KmWh`_5ba!{~vz;|MKVmt6%?L|N1|1Qs=B$ z6K2eq`0wxgxwCs`PHUbyt);%yY0 mVq%j`t|)q(;1<(yYA9h0I?*?|sbNLTNg<9!)AgAd8LR=A=noeF diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/EEFMasterPage.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/EEFMasterPage.gif deleted file mode 100644 index 6ff3783cfb54a5293d88cc8490be9d33572e814f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 565 zcmZ?wbhEHb6krfwc*elc+%@Ibpa0s?Gd1&%XyzW&%sZ%+vsWv7k7m|(t*jlI>6^5G zC}oXS@@lQbrCMFEQ|~cE(|&#hlApTfqhbgOH*@8 zYg>DpsIZ^_KOZj_CmRcM3$v88jI5lzxP+v_)Mil;A*MbaZVqX)BO@&>#}+3IJ#7Z7D_5OboXssP81(Pm)3I-{(@<76Ry9z4 uschY1siC5x_(|=Pie-zbhB_mII)iJ3MPjo+Z!?FmoXe374;MNxSOWl$gtWu} diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/ExplicitPathQuery.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/ExplicitPathQuery.gif deleted file mode 100644 index 55a7bace546a02d2fa3da7cf886a948c4079c06c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 576 zcmZ?wbhEHb6krfwc*el+?fdV~Uw^09uFPp%`|Qn+SMPs*`uh9Zk3T#zLYoio>+d-&@6w;#XXeg5_N+poCR zEm!Wndimk!$FIL!E7s^_FP2W8_wDCzkz7m35<9sXXO(6T&2C@4i9trwLrrH#Oxqc@ z`c%-`<59=1CY-;MeEmU6b&3Dp9rGK?{OZg6`s+N~D}Cm)xJ++yo6_KMXy?3D-3}|d z92T@WKRD69WrFR7KKmu@&Q~^N+}d07|Nno6AqW(IvM@3*I5X&g+zyHp2KKoP&P~nD zc5Q7folW)}y-s#rEmn&BytaB*vPr3zvl!E{&^PlisvBy=hZM)24#1 z9pw}ERe;dm+Gz(r{{H{r&;OtQ{(t!Q|KtDv-~Rvq{{R1v|Nnpf|Nra%|KI=r|M~y_ z-~a!`S@y+Q4#n9HCE1Rpxvu3o4n>&`#aWIO`R*0@-c7}JwfXjydCp}yuI;7P)2fXp zRG4;`S*&W)UD#kSyUuV%wZWWvqeU&IE7~m{9cy0KrnROYC}Z5GBYybE5lN#yT~U6Xo$Ra(3=+D1dScga+z`_1)0SMcgq@9vNlLp8WqPZmZ721N!PkPRR|F|gGhm{8!M!)JYB ziIL?Uop~2tBpE-^QJch>a=NvkZB}cGQX>xsBO}8i$+UGhJzNy0r?<^G`uO6F-`^#i z#ku)f+uFsQ#kzZXdz?jsCW$)paL3LN;Bn^UR#1?iDZuH>F;7ljFg=q&ki(gsTYhtW X9lJAIOZ#p%XV(1(4jxc+WUvMR=0bUJ diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/OCLQuery.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/OCLQuery.gif deleted file mode 100644 index eed6acec1eea76feda64be9486f76517a42a117c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 101 zcmZ?wbhEHb6krfwn8?8J=*4IEoK^F;T>t<7zv538Mg|6E1|0?<0Le2jna$~6d3vo7 z+l*qC#sw`8nYtxsnK|4j?ODjVY@+m{)DNATR3;bSxOH}IvSh>hNe$(*btm(Y?!&Aw5w|Ng%J`{~%WbLPKw)$;B Og`P}9k*1m=gEav5gIBTu diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/ReferenceableObject.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/ReferenceableObject.gif deleted file mode 100644 index caf2804510dc36959fb4e045e8af91d01229dcd7..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 129 zcmZ?wbhEHb6krfw*vtS14M4Jip`qcxfddT<4GjN*-2XuK|Nmgt|Np+|z`)6%1JVgHgMmfQ;H2m3y%w*(d{g0nSm?Ull=W6hg4cqDUv2b0PE)&T WR^GExlV5i^W2f7Zi9*7R4AuatYBLM~ diff --git a/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/StandardFormPage.gif b/plugins/org.eclipse.emf.eef.editor.model/icons/full/obj16/StandardFormPage.gif deleted file mode 100644 index 55ca8f3a9bfca92ec765a53d8531f8f64a425eb8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 351 zcmV-l0igazNk%w1VGsZi0M!5hXm*lsdX8>-jw@T4DR0CnZNVvS!76OMDr>wcYPTwC zxG86{Drd4PWUMMD`~CmB-TKDl{m|+D zfxhjB!S9d8@R`f=q|)`T*Z0`&|M>j>`u+d+{QvX&|Lpny@B07M^Z)Dl|L*$#`2GLs z`Ty+t|Lgky@B9Dr{Qvj;|NH*``u_idhJk{GfR2rNjf{GjlX9S$Y^R)P|Ns9000000 z00000A^8LW002AyEC2ui01yBW000JjK%Q_&EE~!>`vLe|`M= z`}zA{Uw{1h_Vdrr-+zDq`TP9iyF0I+oqv4WYFbRfy4s|5b*UR03%7S0P7Ky-_cfgo zZaFE^X?CJ*f0XBf4A-fNzVovJm*j^oDhQgB8!#g)dR0aIn(CM(Wsx%rGB!2mZfS4Z zHPd}=%DMALXUv#5dshFyzwehVY`=Sb*W&qI^XK$#T~)VXdE@FOt$)9qKfbl_$mZgM z8_V~utK7M!`tRrSTPG@Sous^Ly4s)Ti|18}Eo+oo)+DvGNork}{O`NXGfRa3|NqZ0 zxPjtN7DfgJF9scuGeL2}z`mlvtEsuAwXNN;#j?An+sMe#ptH%6W!iKWetQQ42Ztsr z25~`#rOfUY7ItE6^md0s pO_D7cA}1OW53>tth>0z5d~vj~Tf%ss!jnadkN3;6vobMQ0{{{r%z{Qmsy&$l0cax42|s#Yb` ztxap*IC1Img6iHE?|;4e@ax^@-)}$t`uy#8PS^I5+O8Mxf4=$j`{UQ&MH6C@x+p#N)yZZ0qQ;y#+vKquQ8JrKDCDTsQcuF24ayjKcw!BlA9Os!f-xkwA#cZ z<(oO{ss;3%bkxKf8WIJiwVkxoWVj?G*c2Kh1T~%1)g-vs*@YJ@me6ogRTJi7Wo2Y- xkY!hKQdVQ`2v1~TR(29qV_-UTsDX(?)QL~+@R>7wPMjAnUB2vg&Bc+y8UU-9s5t-t diff --git a/plugins/org.eclipse.emf.eef.editor.model/model/extended.components b/plugins/org.eclipse.emf.eef.editor.model/model/extended.components deleted file mode 100644 index 8ee2b493b..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/model/extended.components +++ /dev/null @@ -1,285 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - SWT - Form - - - - - - - - - - - - - - - - - - - - - - - - SWT - Form - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.editor.model/model/extended.ecore b/plugins/org.eclipse.emf.eef.editor.model/model/extended.ecore deleted file mode 100644 index f32a3f1bf..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/model/extended.ecore +++ /dev/null @@ -1,58 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.editor.model/model/extended.ecorediag b/plugins/org.eclipse.emf.eef.editor.model/model/extended.ecorediag deleted file mode 100644 index 7b9e1a0da..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/model/extended.ecorediag +++ /dev/null @@ -1,798 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.editor.model/model/extended.eefgen b/plugins/org.eclipse.emf.eef.editor.model/model/extended.eefgen deleted file mode 100644 index 43a78bbc9..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/model/extended.eefgen +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.editor.model/model/extended.genmodel b/plugins/org.eclipse.emf.eef.editor.model/model/extended.genmodel deleted file mode 100644 index 0f1426fa6..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/model/extended.genmodel +++ /dev/null @@ -1,59 +0,0 @@ - - - extended.ecore - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.editor.model/plugin.properties b/plugins/org.eclipse.emf.eef.editor.model/plugin.properties deleted file mode 100644 index c49cf9225..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/plugin.properties +++ /dev/null @@ -1,51 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -_UI_CreateChild_text = {0} -_UI_CreateChild_text2 = {1} {0} -_UI_CreateChild_text3 = {1} -_UI_CreateChild_tooltip = Create New {0} Under {1} Feature -_UI_CreateChild_description = Create a new child of type {0} for the {1} feature of the selected {2}. -_UI_CreateSibling_description = Create a new sibling of type {0} for the selected {2}, under the {1} feature of their parent. -_UI_PropertyDescriptor_description = The {0} of the {1} -_UI_EEFEditorContribution_type = EEF Editor Contribution -_UI_EEFPage_type = EEF Page -_UI_StandardFormPage_type = Standard Form Page -_UI_MasterDetailsPage_type = Master Details Page -_UI_EEFMasterPage_type = EEF Master Page -_UI_TreeMasterPage_type = Tree Master Page -_UI_EEFPageInput_type = EEF Page Input -_UI_AllResourcesRootsRelativeInput_type = All Resources Roots Relative Input -_UI_FirstResourceRootRelativeInput_type = First Resource Root Relative Input -_UI_PartFilter_type = Part Filter -_UI_EEFEditorContributions_type = EEF Editor Contributions -_UI_EEFEditorPages_type = EEF Editor Pages -_UI_EEFUnderstandableQuery_type = EEF Understandable Query -_UI_OCLQuery_type = OCL Query -_UI_ExplicitPathQuery_type = Explicit Path Query -_UI_Unknown_type = Object -_UI_Unknown_datatype= Value -_UI_EEFEditorContribution_model_feature = Model -_UI_EEFPage_title_feature = Title -_UI_EEFMasterPage_orientable_feature = Orientable -_UI_EEFMasterPage_showValidatePage_feature = Show Validate Page -_UI_TreeMasterPage_toolbarVisible_feature = Toolbar Visible -_UI_EEFPageInput_query_feature = Query -_UI_PartFilter_filteredPart_feature = Filtered Part -_UI_PartFilter_contextualComponent_feature = Contextual Component -_UI_OCLQuery_query_feature = Query -_UI_OCLQuery_context_feature = Context -_UI_ExplicitPathQuery_query_feature = Query -_UI_Unknown_feature = Unspecified -_UI_StaticEEFEditorContribution_type = Static EEF Editor Contribution -_UI_DynamicEEFEditorContribution_type = Dynamic EEF Editor Contribution -_UI_EEFEditorContribution_input_feature = Input -_UI_ReferenceableObject_type = Referenceable Object diff --git a/plugins/org.eclipse.emf.eef.editor.model/plugin.xml b/plugins/org.eclipse.emf.eef.editor.model/plugin.xml deleted file mode 100644 index 8cb3d83c7..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/plugin.xml +++ /dev/null @@ -1,266 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.editor.model/pom.xml b/plugins/org.eclipse.emf.eef.editor.model/pom.xml deleted file mode 100644 index eab7e5b98..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/pom.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.editor.model - eclipse-plugin - - EEF Editor Model Plug-in - diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/editor_properties.plugin.xml b/plugins/org.eclipse.emf.eef.editor.model/src-gen/editor_properties.plugin.xml deleted file mode 100644 index a1e6bfab7..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/editor_properties.plugin.xml +++ /dev/null @@ -1,164 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/AllResourcesRootsRelativeInput.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/AllResourcesRootsRelativeInput.java deleted file mode 100644 index 8c3f6bdca..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/AllResourcesRootsRelativeInput.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - - -/** - * - * A representation of the model object 'All Resources Roots Relative Input'. - * - * - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getAllResourcesRootsRelativeInput() - * @model - * @generated - */ -public interface AllResourcesRootsRelativeInput extends EEFPageInput { -} // AllResourcesRootsRelativeInput diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/DynamicEEFEditorContribution.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/DynamicEEFEditorContribution.java deleted file mode 100644 index dd3d60938..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/DynamicEEFEditorContribution.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.eef.mapping.EMFElementBinding; - -/** - * - * A representation of the model object 'Dynamic EEF Editor Contribution'. - * - * - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getDynamicEEFEditorContribution() - * @model - * @generated - */ -public interface DynamicEEFEditorContribution extends EMFElementBinding, EEFEditorContribution { -} // DynamicEEFEditorContribution diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorContribution.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorContribution.java deleted file mode 100644 index f9a672a80..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorContribution.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'EEF Editor Contribution'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.EEFEditorContribution#getInput Input}
  • - *
- *

- * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFEditorContribution() - * @model abstract="true" - * @generated - */ -public interface EEFEditorContribution extends EObject { - /** - * Returns the value of the 'Input' containment reference. - * - *

- * If the meaning of the 'Input' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Input' containment reference. - * @see #setInput(EEFPageInput) - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFEditorContribution_Input() - * @model containment="true" required="true" - * @generated - */ - EEFPageInput getInput(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.editor.EEFEditorContribution#getInput Input}' containment reference. - * - * - * @param value the new value of the 'Input' containment reference. - * @see #getInput() - * @generated - */ - void setInput(EEFPageInput value); - -} // EEFEditorContribution diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorContributions.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorContributions.java deleted file mode 100644 index ab3aa5bf4..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorContributions.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.eef.mapping.Category; - -/** - * - * A representation of the model object 'EEF Editor Contributions'. - * - * - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFEditorContributions() - * @model - * @generated - */ -public interface EEFEditorContributions extends Category { -} // EEFEditorContributions diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorPages.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorPages.java deleted file mode 100644 index 0b821380c..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFEditorPages.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.eef.views.Category; - -/** - * - * A representation of the model object 'EEF Editor Pages'. - * - * - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFEditorPages() - * @model - * @generated - */ -public interface EEFEditorPages extends Category { -} // EEFEditorPages diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFMasterPage.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFMasterPage.java deleted file mode 100644 index 5dec38a1f..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFMasterPage.java +++ /dev/null @@ -1,84 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - - -/** - * - * A representation of the model object 'EEF Master Page'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.EEFMasterPage#isOrientable Orientable}
  • - *
  • {@link org.eclipse.emf.eef.extended.editor.EEFMasterPage#isShowValidatePage Show Validate Page}
  • - *
- *

- * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFMasterPage() - * @model - * @generated - */ -public interface EEFMasterPage extends MasterDetailsPage { - /** - * Returns the value of the 'Orientable' attribute. - * - *

- * If the meaning of the 'Orientable' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Orientable' attribute. - * @see #setOrientable(boolean) - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFMasterPage_Orientable() - * @model - * @generated - */ - boolean isOrientable(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.editor.EEFMasterPage#isOrientable Orientable}' attribute. - * - * - * @param value the new value of the 'Orientable' attribute. - * @see #isOrientable() - * @generated - */ - void setOrientable(boolean value); - - /** - * Returns the value of the 'Show Validate Page' attribute. - * - *

- * If the meaning of the 'Show Validate Page' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Show Validate Page' attribute. - * @see #setShowValidatePage(boolean) - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFMasterPage_ShowValidatePage() - * @model - * @generated - */ - boolean isShowValidatePage(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.editor.EEFMasterPage#isShowValidatePage Show Validate Page}' attribute. - * - * - * @param value the new value of the 'Show Validate Page' attribute. - * @see #isShowValidatePage() - * @generated - */ - void setShowValidatePage(boolean value); - -} // EEFMasterPage diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFPage.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFPage.java deleted file mode 100644 index c1345e700..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFPage.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.eef.views.View; - -/** - * - * A representation of the model object 'EEF Page'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.EEFPage#getTitle Title}
  • - *
- *

- * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFPage() - * @model abstract="true" - * @generated - */ -public interface EEFPage extends View { - /** - * Returns the value of the 'Title' attribute. - * - *

- * If the meaning of the 'Title' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Title' attribute. - * @see #setTitle(String) - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFPage_Title() - * @model - * @generated - */ - String getTitle(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.editor.EEFPage#getTitle Title}' attribute. - * - * - * @param value the new value of the 'Title' attribute. - * @see #getTitle() - * @generated - */ - void setTitle(String value); - -} // EEFPage diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFPageInput.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFPageInput.java deleted file mode 100644 index a9db63244..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EEFPageInput.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery; - -/** - * - * A representation of the model object 'EEF Page Input'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.EEFPageInput#getQuery Query}
  • - *
- *

- * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFPageInput() - * @model abstract="true" - * @generated - */ -public interface EEFPageInput extends EObject { - /** - * Returns the value of the 'Query' containment reference. - * - *

- * If the meaning of the 'Query' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Query' containment reference. - * @see #setQuery(EEFUnderstandableQuery) - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getEEFPageInput_Query() - * @model containment="true" - * @generated - */ - EEFUnderstandableQuery getQuery(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.editor.EEFPageInput#getQuery Query}' containment reference. - * - * - * @param value the new value of the 'Query' containment reference. - * @see #getQuery() - * @generated - */ - void setQuery(EEFUnderstandableQuery value); - -} // EEFPageInput diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EditorFactory.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EditorFactory.java deleted file mode 100644 index 62aa5f612..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EditorFactory.java +++ /dev/null @@ -1,140 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage - * @generated - */ -public interface EditorFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - EditorFactory eINSTANCE = org.eclipse.emf.eef.extended.editor.impl.EditorFactoryImpl.init(); - - /** - * Returns a new object of class 'Standard Form Page'. - * - * - * @return a new object of class 'Standard Form Page'. - * @generated - */ - StandardFormPage createStandardFormPage(); - - /** - * Returns a new object of class 'EEF Master Page'. - * - * - * @return a new object of class 'EEF Master Page'. - * @generated - */ - EEFMasterPage createEEFMasterPage(); - - /** - * Returns a new object of class 'Tree Master Page'. - * - * - * @return a new object of class 'Tree Master Page'. - * @generated - */ - TreeMasterPage createTreeMasterPage(); - - /** - * Returns a new object of class 'All Resources Roots Relative Input'. - * - * - * @return a new object of class 'All Resources Roots Relative Input'. - * @generated - */ - AllResourcesRootsRelativeInput createAllResourcesRootsRelativeInput(); - - /** - * Returns a new object of class 'First Resource Root Relative Input'. - * - * - * @return a new object of class 'First Resource Root Relative Input'. - * @generated - */ - FirstResourceRootRelativeInput createFirstResourceRootRelativeInput(); - - /** - * Returns a new object of class 'Part Filter'. - * - * - * @return a new object of class 'Part Filter'. - * @generated - */ - PartFilter createPartFilter(); - - /** - * Returns a new object of class 'EEF Editor Contributions'. - * - * - * @return a new object of class 'EEF Editor Contributions'. - * @generated - */ - EEFEditorContributions createEEFEditorContributions(); - - /** - * Returns a new object of class 'EEF Editor Pages'. - * - * - * @return a new object of class 'EEF Editor Pages'. - * @generated - */ - EEFEditorPages createEEFEditorPages(); - - /** - * Returns a new object of class 'Static EEF Editor Contribution'. - * - * - * @return a new object of class 'Static EEF Editor Contribution'. - * @generated - */ - StaticEEFEditorContribution createStaticEEFEditorContribution(); - - /** - * Returns a new object of class 'Dynamic EEF Editor Contribution'. - * - * - * @return a new object of class 'Dynamic EEF Editor Contribution'. - * @generated - */ - DynamicEEFEditorContribution createDynamicEEFEditorContribution(); - - /** - * Returns a new object of class 'Referenceable Object'. - * - * - * @return a new object of class 'Referenceable Object'. - * @generated - */ - ReferenceableObject createReferenceableObject(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - EditorPackage getEditorPackage(); - -} //EditorFactory diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EditorPackage.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EditorPackage.java deleted file mode 100644 index 7510e0106..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/EditorPackage.java +++ /dev/null @@ -1,1688 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.views.ViewsPackage; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.extended.editor.EditorFactory - * @model kind="package" - * @generated - */ -public interface EditorPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "editor"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/extended/editor/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-ext-edt"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - EditorPackage eINSTANCE = org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl.init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFEditorContributionImpl EEF Editor Contribution}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFEditorContributionImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFEditorContribution() - * @generated - */ - int EEF_EDITOR_CONTRIBUTION = 0; - - /** - * The feature id for the 'Input' containment reference. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_CONTRIBUTION__INPUT = 0; - - /** - * The number of structural features of the 'EEF Editor Contribution' class. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_CONTRIBUTION_FEATURE_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFPageImpl EEF Page}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFPageImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFPage() - * @generated - */ - int EEF_PAGE = 1; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int EEF_PAGE__DOCUMENTATION = ViewsPackage.VIEW__DOCUMENTATION; - - /** - * The feature id for the 'Representation' reference. - * - * - * @generated - * @ordered - */ - int EEF_PAGE__REPRESENTATION = ViewsPackage.VIEW__REPRESENTATION; - - /** - * The feature id for the 'Container' container reference. - * - * - * @generated - * @ordered - */ - int EEF_PAGE__CONTAINER = ViewsPackage.VIEW__CONTAINER; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int EEF_PAGE__NAME = ViewsPackage.VIEW__NAME; - - /** - * The feature id for the 'Qualified Identifier' attribute. - * - * - * @generated - * @ordered - */ - int EEF_PAGE__QUALIFIED_IDENTIFIER = ViewsPackage.VIEW__QUALIFIED_IDENTIFIER; - - /** - * The feature id for the 'Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int EEF_PAGE__ELEMENTS = ViewsPackage.VIEW__ELEMENTS; - - /** - * The feature id for the 'Repository' container reference. - * - * - * @generated - * @ordered - */ - int EEF_PAGE__REPOSITORY = ViewsPackage.VIEW__REPOSITORY; - - /** - * The feature id for the 'Explicit' attribute. - * - * - * @generated - * @ordered - */ - int EEF_PAGE__EXPLICIT = ViewsPackage.VIEW__EXPLICIT; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int EEF_PAGE__CATEGORY = ViewsPackage.VIEW__CATEGORY; - - /** - * The feature id for the 'Title' attribute. - * - * - * @generated - * @ordered - */ - int EEF_PAGE__TITLE = ViewsPackage.VIEW_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'EEF Page' class. - * - * - * @generated - * @ordered - */ - int EEF_PAGE_FEATURE_COUNT = ViewsPackage.VIEW_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.StandardFormPageImpl Standard Form Page}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.StandardFormPageImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getStandardFormPage() - * @generated - */ - int STANDARD_FORM_PAGE = 2; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE__DOCUMENTATION = EEF_PAGE__DOCUMENTATION; - - /** - * The feature id for the 'Representation' reference. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE__REPRESENTATION = EEF_PAGE__REPRESENTATION; - - /** - * The feature id for the 'Container' container reference. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE__CONTAINER = EEF_PAGE__CONTAINER; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE__NAME = EEF_PAGE__NAME; - - /** - * The feature id for the 'Qualified Identifier' attribute. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE__QUALIFIED_IDENTIFIER = EEF_PAGE__QUALIFIED_IDENTIFIER; - - /** - * The feature id for the 'Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE__ELEMENTS = EEF_PAGE__ELEMENTS; - - /** - * The feature id for the 'Repository' container reference. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE__REPOSITORY = EEF_PAGE__REPOSITORY; - - /** - * The feature id for the 'Explicit' attribute. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE__EXPLICIT = EEF_PAGE__EXPLICIT; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE__CATEGORY = EEF_PAGE__CATEGORY; - - /** - * The feature id for the 'Title' attribute. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE__TITLE = EEF_PAGE__TITLE; - - /** - * The number of structural features of the 'Standard Form Page' class. - * - * - * @generated - * @ordered - */ - int STANDARD_FORM_PAGE_FEATURE_COUNT = EEF_PAGE_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.MasterDetailsPageImpl Master Details Page}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.MasterDetailsPageImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getMasterDetailsPage() - * @generated - */ - int MASTER_DETAILS_PAGE = 3; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE__DOCUMENTATION = EEF_PAGE__DOCUMENTATION; - - /** - * The feature id for the 'Representation' reference. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE__REPRESENTATION = EEF_PAGE__REPRESENTATION; - - /** - * The feature id for the 'Container' container reference. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE__CONTAINER = EEF_PAGE__CONTAINER; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE__NAME = EEF_PAGE__NAME; - - /** - * The feature id for the 'Qualified Identifier' attribute. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE__QUALIFIED_IDENTIFIER = EEF_PAGE__QUALIFIED_IDENTIFIER; - - /** - * The feature id for the 'Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE__ELEMENTS = EEF_PAGE__ELEMENTS; - - /** - * The feature id for the 'Repository' container reference. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE__REPOSITORY = EEF_PAGE__REPOSITORY; - - /** - * The feature id for the 'Explicit' attribute. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE__EXPLICIT = EEF_PAGE__EXPLICIT; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE__CATEGORY = EEF_PAGE__CATEGORY; - - /** - * The feature id for the 'Title' attribute. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE__TITLE = EEF_PAGE__TITLE; - - /** - * The number of structural features of the 'Master Details Page' class. - * - * - * @generated - * @ordered - */ - int MASTER_DETAILS_PAGE_FEATURE_COUNT = EEF_PAGE_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFMasterPageImpl EEF Master Page}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFMasterPageImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFMasterPage() - * @generated - */ - int EEF_MASTER_PAGE = 4; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__DOCUMENTATION = MASTER_DETAILS_PAGE__DOCUMENTATION; - - /** - * The feature id for the 'Representation' reference. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__REPRESENTATION = MASTER_DETAILS_PAGE__REPRESENTATION; - - /** - * The feature id for the 'Container' container reference. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__CONTAINER = MASTER_DETAILS_PAGE__CONTAINER; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__NAME = MASTER_DETAILS_PAGE__NAME; - - /** - * The feature id for the 'Qualified Identifier' attribute. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__QUALIFIED_IDENTIFIER = MASTER_DETAILS_PAGE__QUALIFIED_IDENTIFIER; - - /** - * The feature id for the 'Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__ELEMENTS = MASTER_DETAILS_PAGE__ELEMENTS; - - /** - * The feature id for the 'Repository' container reference. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__REPOSITORY = MASTER_DETAILS_PAGE__REPOSITORY; - - /** - * The feature id for the 'Explicit' attribute. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__EXPLICIT = MASTER_DETAILS_PAGE__EXPLICIT; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__CATEGORY = MASTER_DETAILS_PAGE__CATEGORY; - - /** - * The feature id for the 'Title' attribute. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__TITLE = MASTER_DETAILS_PAGE__TITLE; - - /** - * The feature id for the 'Orientable' attribute. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__ORIENTABLE = MASTER_DETAILS_PAGE_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Show Validate Page' attribute. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE__SHOW_VALIDATE_PAGE = MASTER_DETAILS_PAGE_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'EEF Master Page' class. - * - * - * @generated - * @ordered - */ - int EEF_MASTER_PAGE_FEATURE_COUNT = MASTER_DETAILS_PAGE_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.TreeMasterPageImpl Tree Master Page}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.TreeMasterPageImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getTreeMasterPage() - * @generated - */ - int TREE_MASTER_PAGE = 5; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__DOCUMENTATION = MASTER_DETAILS_PAGE__DOCUMENTATION; - - /** - * The feature id for the 'Representation' reference. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__REPRESENTATION = MASTER_DETAILS_PAGE__REPRESENTATION; - - /** - * The feature id for the 'Container' container reference. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__CONTAINER = MASTER_DETAILS_PAGE__CONTAINER; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__NAME = MASTER_DETAILS_PAGE__NAME; - - /** - * The feature id for the 'Qualified Identifier' attribute. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__QUALIFIED_IDENTIFIER = MASTER_DETAILS_PAGE__QUALIFIED_IDENTIFIER; - - /** - * The feature id for the 'Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__ELEMENTS = MASTER_DETAILS_PAGE__ELEMENTS; - - /** - * The feature id for the 'Repository' container reference. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__REPOSITORY = MASTER_DETAILS_PAGE__REPOSITORY; - - /** - * The feature id for the 'Explicit' attribute. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__EXPLICIT = MASTER_DETAILS_PAGE__EXPLICIT; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__CATEGORY = MASTER_DETAILS_PAGE__CATEGORY; - - /** - * The feature id for the 'Title' attribute. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__TITLE = MASTER_DETAILS_PAGE__TITLE; - - /** - * The feature id for the 'Toolbar Visible' attribute. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE__TOOLBAR_VISIBLE = MASTER_DETAILS_PAGE_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Tree Master Page' class. - * - * - * @generated - * @ordered - */ - int TREE_MASTER_PAGE_FEATURE_COUNT = MASTER_DETAILS_PAGE_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFPageInputImpl EEF Page Input}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFPageInputImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFPageInput() - * @generated - */ - int EEF_PAGE_INPUT = 6; - - /** - * The feature id for the 'Query' containment reference. - * - * - * @generated - * @ordered - */ - int EEF_PAGE_INPUT__QUERY = 0; - - /** - * The number of structural features of the 'EEF Page Input' class. - * - * - * @generated - * @ordered - */ - int EEF_PAGE_INPUT_FEATURE_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.AllResourcesRootsRelativeInputImpl All Resources Roots Relative Input}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.AllResourcesRootsRelativeInputImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getAllResourcesRootsRelativeInput() - * @generated - */ - int ALL_RESOURCES_ROOTS_RELATIVE_INPUT = 7; - - /** - * The feature id for the 'Query' containment reference. - * - * - * @generated - * @ordered - */ - int ALL_RESOURCES_ROOTS_RELATIVE_INPUT__QUERY = EEF_PAGE_INPUT__QUERY; - - /** - * The number of structural features of the 'All Resources Roots Relative Input' class. - * - * - * @generated - * @ordered - */ - int ALL_RESOURCES_ROOTS_RELATIVE_INPUT_FEATURE_COUNT = EEF_PAGE_INPUT_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.FirstResourceRootRelativeInputImpl First Resource Root Relative Input}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.FirstResourceRootRelativeInputImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getFirstResourceRootRelativeInput() - * @generated - */ - int FIRST_RESOURCE_ROOT_RELATIVE_INPUT = 8; - - /** - * The feature id for the 'Query' containment reference. - * - * - * @generated - * @ordered - */ - int FIRST_RESOURCE_ROOT_RELATIVE_INPUT__QUERY = EEF_PAGE_INPUT__QUERY; - - /** - * The number of structural features of the 'First Resource Root Relative Input' class. - * - * - * @generated - * @ordered - */ - int FIRST_RESOURCE_ROOT_RELATIVE_INPUT_FEATURE_COUNT = EEF_PAGE_INPUT_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.PartFilterImpl Part Filter}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.PartFilterImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getPartFilter() - * @generated - */ - int PART_FILTER = 9; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int PART_FILTER__DOCUMENTATION = FiltersPackage.BINDING_FILTER__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int PART_FILTER__NAME = FiltersPackage.BINDING_FILTER__NAME; - - /** - * The feature id for the 'Mandatory' attribute. - * - * - * @generated - * @ordered - */ - int PART_FILTER__MANDATORY = FiltersPackage.BINDING_FILTER__MANDATORY; - - /** - * The feature id for the 'Filtered Part' reference. - * - * - * @generated - * @ordered - */ - int PART_FILTER__FILTERED_PART = FiltersPackage.BINDING_FILTER_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Contextual Component' reference. - * - * - * @generated - * @ordered - */ - int PART_FILTER__CONTEXTUAL_COMPONENT = FiltersPackage.BINDING_FILTER_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Part Filter' class. - * - * - * @generated - * @ordered - */ - int PART_FILTER_FEATURE_COUNT = FiltersPackage.BINDING_FILTER_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFEditorContributionsImpl EEF Editor Contributions}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFEditorContributionsImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFEditorContributions() - * @generated - */ - int EEF_EDITOR_CONTRIBUTIONS = 10; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_CONTRIBUTIONS__DOCUMENTATION = MappingPackage.CATEGORY__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_CONTRIBUTIONS__NAME = MappingPackage.CATEGORY__NAME; - - /** - * The feature id for the 'Bindings' containment reference list. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_CONTRIBUTIONS__BINDINGS = MappingPackage.CATEGORY__BINDINGS; - - /** - * The feature id for the 'Databinding' container reference. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_CONTRIBUTIONS__DATABINDING = MappingPackage.CATEGORY__DATABINDING; - - /** - * The feature id for the 'Categories' containment reference list. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_CONTRIBUTIONS__CATEGORIES = MappingPackage.CATEGORY__CATEGORIES; - - /** - * The number of structural features of the 'EEF Editor Contributions' class. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_CONTRIBUTIONS_FEATURE_COUNT = MappingPackage.CATEGORY_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFEditorPagesImpl EEF Editor Pages}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFEditorPagesImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFEditorPages() - * @generated - */ - int EEF_EDITOR_PAGES = 11; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_PAGES__DOCUMENTATION = ViewsPackage.CATEGORY__DOCUMENTATION; - - /** - * The feature id for the 'Views' containment reference list. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_PAGES__VIEWS = ViewsPackage.CATEGORY__VIEWS; - - /** - * The feature id for the 'Repository' container reference. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_PAGES__REPOSITORY = ViewsPackage.CATEGORY__REPOSITORY; - - /** - * The feature id for the 'Categories' containment reference list. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_PAGES__CATEGORIES = ViewsPackage.CATEGORY__CATEGORIES; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_PAGES__NAME = ViewsPackage.CATEGORY__NAME; - - /** - * The number of structural features of the 'EEF Editor Pages' class. - * - * - * @generated - * @ordered - */ - int EEF_EDITOR_PAGES_FEATURE_COUNT = ViewsPackage.CATEGORY_FEATURE_COUNT + 0; - - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.StaticEEFEditorContributionImpl Static EEF Editor Contribution}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.StaticEEFEditorContributionImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getStaticEEFEditorContribution() - * @generated - */ - int STATIC_EEF_EDITOR_CONTRIBUTION = 12; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__DOCUMENTATION = MappingPackage.ABSTRACT_ELEMENT_BINDING__DOCUMENTATION; - - /** - * The feature id for the 'Sub Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__SUB_ELEMENTS = MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS; - - /** - * The feature id for the 'Properties' containment reference list. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__PROPERTIES = MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES; - - /** - * The feature id for the 'Databinding' container reference. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__DATABINDING = MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING; - - /** - * The feature id for the 'Super Element' container reference. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__SUPER_ELEMENT = MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__NAME = MappingPackage.ABSTRACT_ELEMENT_BINDING__NAME; - - /** - * The feature id for the 'Referenced Binding' containment reference list. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__REFERENCED_BINDING = MappingPackage.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__VIEWS = MappingPackage.ABSTRACT_ELEMENT_BINDING__VIEWS; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__CATEGORY = MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__BINDING_FILTERS = MappingPackage.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS; - - /** - * The feature id for the 'Input' containment reference. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION__INPUT = MappingPackage.ABSTRACT_ELEMENT_BINDING_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Static EEF Editor Contribution' class. - * - * - * @generated - * @ordered - */ - int STATIC_EEF_EDITOR_CONTRIBUTION_FEATURE_COUNT = MappingPackage.ABSTRACT_ELEMENT_BINDING_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.DynamicEEFEditorContributionImpl Dynamic EEF Editor Contribution}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.DynamicEEFEditorContributionImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getDynamicEEFEditorContribution() - * @generated - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION = 13; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__DOCUMENTATION = MappingPackage.EMF_ELEMENT_BINDING__DOCUMENTATION; - - /** - * The feature id for the 'Sub Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__SUB_ELEMENTS = MappingPackage.EMF_ELEMENT_BINDING__SUB_ELEMENTS; - - /** - * The feature id for the 'Properties' containment reference list. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__PROPERTIES = MappingPackage.EMF_ELEMENT_BINDING__PROPERTIES; - - /** - * The feature id for the 'Databinding' container reference. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__DATABINDING = MappingPackage.EMF_ELEMENT_BINDING__DATABINDING; - - /** - * The feature id for the 'Super Element' container reference. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__SUPER_ELEMENT = MappingPackage.EMF_ELEMENT_BINDING__SUPER_ELEMENT; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__NAME = MappingPackage.EMF_ELEMENT_BINDING__NAME; - - /** - * The feature id for the 'Referenced Binding' containment reference list. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__REFERENCED_BINDING = MappingPackage.EMF_ELEMENT_BINDING__REFERENCED_BINDING; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__VIEWS = MappingPackage.EMF_ELEMENT_BINDING__VIEWS; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__CATEGORY = MappingPackage.EMF_ELEMENT_BINDING__CATEGORY; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__BINDING_FILTERS = MappingPackage.EMF_ELEMENT_BINDING__BINDING_FILTERS; - - /** - * The feature id for the 'Model' reference. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__MODEL = MappingPackage.EMF_ELEMENT_BINDING__MODEL; - - /** - * The feature id for the 'Input' containment reference. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT = MappingPackage.EMF_ELEMENT_BINDING_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Dynamic EEF Editor Contribution' class. - * - * - * @generated - * @ordered - */ - int DYNAMIC_EEF_EDITOR_CONTRIBUTION_FEATURE_COUNT = MappingPackage.EMF_ELEMENT_BINDING_FEATURE_COUNT + 1; - - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.editor.impl.ReferenceableObjectImpl Referenceable Object}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.ReferenceableObjectImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getReferenceableObject() - * @generated - */ - int REFERENCEABLE_OBJECT = 14; - - /** - * The number of structural features of the 'Referenceable Object' class. - * - * - * @generated - * @ordered - */ - int REFERENCEABLE_OBJECT_FEATURE_COUNT = 0; - - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.EEFEditorContribution EEF Editor Contribution}'. - * - * - * @return the meta object for class 'EEF Editor Contribution'. - * @see org.eclipse.emf.eef.extended.editor.EEFEditorContribution - * @generated - */ - EClass getEEFEditorContribution(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.extended.editor.EEFEditorContribution#getInput Input}'. - * - * - * @return the meta object for the containment reference 'Input'. - * @see org.eclipse.emf.eef.extended.editor.EEFEditorContribution#getInput() - * @see #getEEFEditorContribution() - * @generated - */ - EReference getEEFEditorContribution_Input(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.EEFPage EEF Page}'. - * - * - * @return the meta object for class 'EEF Page'. - * @see org.eclipse.emf.eef.extended.editor.EEFPage - * @generated - */ - EClass getEEFPage(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.extended.editor.EEFPage#getTitle Title}'. - * - * - * @return the meta object for the attribute 'Title'. - * @see org.eclipse.emf.eef.extended.editor.EEFPage#getTitle() - * @see #getEEFPage() - * @generated - */ - EAttribute getEEFPage_Title(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.StandardFormPage Standard Form Page}'. - * - * - * @return the meta object for class 'Standard Form Page'. - * @see org.eclipse.emf.eef.extended.editor.StandardFormPage - * @generated - */ - EClass getStandardFormPage(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.MasterDetailsPage Master Details Page}'. - * - * - * @return the meta object for class 'Master Details Page'. - * @see org.eclipse.emf.eef.extended.editor.MasterDetailsPage - * @generated - */ - EClass getMasterDetailsPage(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.EEFMasterPage EEF Master Page}'. - * - * - * @return the meta object for class 'EEF Master Page'. - * @see org.eclipse.emf.eef.extended.editor.EEFMasterPage - * @generated - */ - EClass getEEFMasterPage(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.extended.editor.EEFMasterPage#isOrientable Orientable}'. - * - * - * @return the meta object for the attribute 'Orientable'. - * @see org.eclipse.emf.eef.extended.editor.EEFMasterPage#isOrientable() - * @see #getEEFMasterPage() - * @generated - */ - EAttribute getEEFMasterPage_Orientable(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.extended.editor.EEFMasterPage#isShowValidatePage Show Validate Page}'. - * - * - * @return the meta object for the attribute 'Show Validate Page'. - * @see org.eclipse.emf.eef.extended.editor.EEFMasterPage#isShowValidatePage() - * @see #getEEFMasterPage() - * @generated - */ - EAttribute getEEFMasterPage_ShowValidatePage(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.TreeMasterPage Tree Master Page}'. - * - * - * @return the meta object for class 'Tree Master Page'. - * @see org.eclipse.emf.eef.extended.editor.TreeMasterPage - * @generated - */ - EClass getTreeMasterPage(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.extended.editor.TreeMasterPage#isToolbarVisible Toolbar Visible}'. - * - * - * @return the meta object for the attribute 'Toolbar Visible'. - * @see org.eclipse.emf.eef.extended.editor.TreeMasterPage#isToolbarVisible() - * @see #getTreeMasterPage() - * @generated - */ - EAttribute getTreeMasterPage_ToolbarVisible(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.EEFPageInput EEF Page Input}'. - * - * - * @return the meta object for class 'EEF Page Input'. - * @see org.eclipse.emf.eef.extended.editor.EEFPageInput - * @generated - */ - EClass getEEFPageInput(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.extended.editor.EEFPageInput#getQuery Query}'. - * - * - * @return the meta object for the containment reference 'Query'. - * @see org.eclipse.emf.eef.extended.editor.EEFPageInput#getQuery() - * @see #getEEFPageInput() - * @generated - */ - EReference getEEFPageInput_Query(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput All Resources Roots Relative Input}'. - * - * - * @return the meta object for class 'All Resources Roots Relative Input'. - * @see org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput - * @generated - */ - EClass getAllResourcesRootsRelativeInput(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput First Resource Root Relative Input}'. - * - * - * @return the meta object for class 'First Resource Root Relative Input'. - * @see org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput - * @generated - */ - EClass getFirstResourceRootRelativeInput(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.PartFilter Part Filter}'. - * - * - * @return the meta object for class 'Part Filter'. - * @see org.eclipse.emf.eef.extended.editor.PartFilter - * @generated - */ - EClass getPartFilter(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.extended.editor.PartFilter#getFilteredPart Filtered Part}'. - * - * - * @return the meta object for the reference 'Filtered Part'. - * @see org.eclipse.emf.eef.extended.editor.PartFilter#getFilteredPart() - * @see #getPartFilter() - * @generated - */ - EReference getPartFilter_FilteredPart(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.extended.editor.PartFilter#getContextualComponent Contextual Component}'. - * - * - * @return the meta object for the reference 'Contextual Component'. - * @see org.eclipse.emf.eef.extended.editor.PartFilter#getContextualComponent() - * @see #getPartFilter() - * @generated - */ - EReference getPartFilter_ContextualComponent(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.EEFEditorContributions EEF Editor Contributions}'. - * - * - * @return the meta object for class 'EEF Editor Contributions'. - * @see org.eclipse.emf.eef.extended.editor.EEFEditorContributions - * @generated - */ - EClass getEEFEditorContributions(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.EEFEditorPages EEF Editor Pages}'. - * - * - * @return the meta object for class 'EEF Editor Pages'. - * @see org.eclipse.emf.eef.extended.editor.EEFEditorPages - * @generated - */ - EClass getEEFEditorPages(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution Static EEF Editor Contribution}'. - * - * - * @return the meta object for class 'Static EEF Editor Contribution'. - * @see org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution - * @generated - */ - EClass getStaticEEFEditorContribution(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution Dynamic EEF Editor Contribution}'. - * - * - * @return the meta object for class 'Dynamic EEF Editor Contribution'. - * @see org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution - * @generated - */ - EClass getDynamicEEFEditorContribution(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.editor.ReferenceableObject Referenceable Object}'. - * - * - * @return the meta object for class 'Referenceable Object'. - * @see org.eclipse.emf.eef.extended.editor.ReferenceableObject - * @generated - */ - EClass getReferenceableObject(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - EditorFactory getEditorFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFEditorContributionImpl EEF Editor Contribution}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFEditorContributionImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFEditorContribution() - * @generated - */ - EClass EEF_EDITOR_CONTRIBUTION = eINSTANCE.getEEFEditorContribution(); - - /** - * The meta object literal for the 'Input' containment reference feature. - * - * - * @generated - */ - EReference EEF_EDITOR_CONTRIBUTION__INPUT = eINSTANCE.getEEFEditorContribution_Input(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFPageImpl EEF Page}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFPageImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFPage() - * @generated - */ - EClass EEF_PAGE = eINSTANCE.getEEFPage(); - - /** - * The meta object literal for the 'Title' attribute feature. - * - * - * @generated - */ - EAttribute EEF_PAGE__TITLE = eINSTANCE.getEEFPage_Title(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.StandardFormPageImpl Standard Form Page}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.StandardFormPageImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getStandardFormPage() - * @generated - */ - EClass STANDARD_FORM_PAGE = eINSTANCE.getStandardFormPage(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.MasterDetailsPageImpl Master Details Page}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.MasterDetailsPageImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getMasterDetailsPage() - * @generated - */ - EClass MASTER_DETAILS_PAGE = eINSTANCE.getMasterDetailsPage(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFMasterPageImpl EEF Master Page}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFMasterPageImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFMasterPage() - * @generated - */ - EClass EEF_MASTER_PAGE = eINSTANCE.getEEFMasterPage(); - - /** - * The meta object literal for the 'Orientable' attribute feature. - * - * - * @generated - */ - EAttribute EEF_MASTER_PAGE__ORIENTABLE = eINSTANCE.getEEFMasterPage_Orientable(); - - /** - * The meta object literal for the 'Show Validate Page' attribute feature. - * - * - * @generated - */ - EAttribute EEF_MASTER_PAGE__SHOW_VALIDATE_PAGE = eINSTANCE.getEEFMasterPage_ShowValidatePage(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.TreeMasterPageImpl Tree Master Page}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.TreeMasterPageImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getTreeMasterPage() - * @generated - */ - EClass TREE_MASTER_PAGE = eINSTANCE.getTreeMasterPage(); - - /** - * The meta object literal for the 'Toolbar Visible' attribute feature. - * - * - * @generated - */ - EAttribute TREE_MASTER_PAGE__TOOLBAR_VISIBLE = eINSTANCE.getTreeMasterPage_ToolbarVisible(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFPageInputImpl EEF Page Input}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFPageInputImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFPageInput() - * @generated - */ - EClass EEF_PAGE_INPUT = eINSTANCE.getEEFPageInput(); - - /** - * The meta object literal for the 'Query' containment reference feature. - * - * - * @generated - */ - EReference EEF_PAGE_INPUT__QUERY = eINSTANCE.getEEFPageInput_Query(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.AllResourcesRootsRelativeInputImpl All Resources Roots Relative Input}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.AllResourcesRootsRelativeInputImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getAllResourcesRootsRelativeInput() - * @generated - */ - EClass ALL_RESOURCES_ROOTS_RELATIVE_INPUT = eINSTANCE.getAllResourcesRootsRelativeInput(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.FirstResourceRootRelativeInputImpl First Resource Root Relative Input}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.FirstResourceRootRelativeInputImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getFirstResourceRootRelativeInput() - * @generated - */ - EClass FIRST_RESOURCE_ROOT_RELATIVE_INPUT = eINSTANCE.getFirstResourceRootRelativeInput(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.PartFilterImpl Part Filter}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.PartFilterImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getPartFilter() - * @generated - */ - EClass PART_FILTER = eINSTANCE.getPartFilter(); - - /** - * The meta object literal for the 'Filtered Part' reference feature. - * - * - * @generated - */ - EReference PART_FILTER__FILTERED_PART = eINSTANCE.getPartFilter_FilteredPart(); - - /** - * The meta object literal for the 'Contextual Component' reference feature. - * - * - * @generated - */ - EReference PART_FILTER__CONTEXTUAL_COMPONENT = eINSTANCE.getPartFilter_ContextualComponent(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFEditorContributionsImpl EEF Editor Contributions}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFEditorContributionsImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFEditorContributions() - * @generated - */ - EClass EEF_EDITOR_CONTRIBUTIONS = eINSTANCE.getEEFEditorContributions(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.EEFEditorPagesImpl EEF Editor Pages}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.EEFEditorPagesImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getEEFEditorPages() - * @generated - */ - EClass EEF_EDITOR_PAGES = eINSTANCE.getEEFEditorPages(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.StaticEEFEditorContributionImpl Static EEF Editor Contribution}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.StaticEEFEditorContributionImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getStaticEEFEditorContribution() - * @generated - */ - EClass STATIC_EEF_EDITOR_CONTRIBUTION = eINSTANCE.getStaticEEFEditorContribution(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.DynamicEEFEditorContributionImpl Dynamic EEF Editor Contribution}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.DynamicEEFEditorContributionImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getDynamicEEFEditorContribution() - * @generated - */ - EClass DYNAMIC_EEF_EDITOR_CONTRIBUTION = eINSTANCE.getDynamicEEFEditorContribution(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.editor.impl.ReferenceableObjectImpl Referenceable Object}' class. - * - * - * @see org.eclipse.emf.eef.extended.editor.impl.ReferenceableObjectImpl - * @see org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl#getReferenceableObject() - * @generated - */ - EClass REFERENCEABLE_OBJECT = eINSTANCE.getReferenceableObject(); - - } - -} //EditorPackage diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/FirstResourceRootRelativeInput.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/FirstResourceRootRelativeInput.java deleted file mode 100644 index ce5363734..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/FirstResourceRootRelativeInput.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - - -/** - * - * A representation of the model object 'First Resource Root Relative Input'. - * - * - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getFirstResourceRootRelativeInput() - * @model - * @generated - */ -public interface FirstResourceRootRelativeInput extends EEFPageInput { -} // FirstResourceRootRelativeInput diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/MasterDetailsPage.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/MasterDetailsPage.java deleted file mode 100644 index 2a50280ab..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/MasterDetailsPage.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - - -/** - * - * A representation of the model object 'Master Details Page'. - * - * - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getMasterDetailsPage() - * @model abstract="true" - * @generated - */ -public interface MasterDetailsPage extends EEFPage { -} // MasterDetailsPage diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/PartFilter.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/PartFilter.java deleted file mode 100644 index 88b4e03f4..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/PartFilter.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.views.View; - -/** - * - * A representation of the model object 'Part Filter'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.PartFilter#getFilteredPart Filtered Part}
  • - *
  • {@link org.eclipse.emf.eef.extended.editor.PartFilter#getContextualComponent Contextual Component}
  • - *
- *

- * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getPartFilter() - * @model - * @generated - */ -public interface PartFilter extends BindingFilter { - /** - * Returns the value of the 'Filtered Part' reference. - * - *

- * If the meaning of the 'Filtered Part' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Filtered Part' reference. - * @see #setFilteredPart(View) - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getPartFilter_FilteredPart() - * @model required="true" - * @generated - */ - View getFilteredPart(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.editor.PartFilter#getFilteredPart Filtered Part}' reference. - * - * - * @param value the new value of the 'Filtered Part' reference. - * @see #getFilteredPart() - * @generated - */ - void setFilteredPart(View value); - - /** - * Returns the value of the 'Contextual Component' reference. - * - *

- * If the meaning of the 'Contextual Component' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Contextual Component' reference. - * @see #setContextualComponent(PropertiesEditionComponent) - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getPartFilter_ContextualComponent() - * @model - * @generated - */ - PropertiesEditionComponent getContextualComponent(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.editor.PartFilter#getContextualComponent Contextual Component}' reference. - * - * - * @param value the new value of the 'Contextual Component' reference. - * @see #getContextualComponent() - * @generated - */ - void setContextualComponent(PropertiesEditionComponent value); - -} // PartFilter diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/ReferenceableObject.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/ReferenceableObject.java deleted file mode 100644 index ae9cb7ad2..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/ReferenceableObject.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Referenceable Object'. - * - * - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getReferenceableObject() - * @model - * @generated - */ -public interface ReferenceableObject extends EObject { -} // ReferenceableObject diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/StandardFormPage.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/StandardFormPage.java deleted file mode 100644 index 9dde5d779..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/StandardFormPage.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - - -/** - * - * A representation of the model object 'Standard Form Page'. - * - * - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getStandardFormPage() - * @model - * @generated - */ -public interface StandardFormPage extends EEFPage { -} // StandardFormPage diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/StaticEEFEditorContribution.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/StaticEEFEditorContribution.java deleted file mode 100644 index 5294cc64b..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/StaticEEFEditorContribution.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - -import org.eclipse.emf.eef.mapping.AbstractElementBinding; - -/** - * - * A representation of the model object 'Static EEF Editor Contribution'. - * - * - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getStaticEEFEditorContribution() - * @model - * @generated - */ -public interface StaticEEFEditorContribution extends AbstractElementBinding, EEFEditorContribution { -} // StaticEEFEditorContribution diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/TreeMasterPage.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/TreeMasterPage.java deleted file mode 100644 index 5d34723af..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/TreeMasterPage.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor; - - -/** - * - * A representation of the model object 'Tree Master Page'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.TreeMasterPage#isToolbarVisible Toolbar Visible}
  • - *
- *

- * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getTreeMasterPage() - * @model - * @generated - */ -public interface TreeMasterPage extends MasterDetailsPage { - /** - * Returns the value of the 'Toolbar Visible' attribute. - * - *

- * If the meaning of the 'Toolbar Visible' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Toolbar Visible' attribute. - * @see #setToolbarVisible(boolean) - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#getTreeMasterPage_ToolbarVisible() - * @model - * @generated - */ - boolean isToolbarVisible(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.editor.TreeMasterPage#isToolbarVisible Toolbar Visible}' attribute. - * - * - * @param value the new value of the 'Toolbar Visible' attribute. - * @see #isToolbarVisible() - * @generated - */ - void setToolbarVisible(boolean value); - -} // TreeMasterPage diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/DynamicEEFEditorContributionBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/DynamicEEFEditorContributionBasePropertiesEditionComponent.java deleted file mode 100644 index 7ef77d310..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/DynamicEEFEditorContributionBasePropertiesEditionComponent.java +++ /dev/null @@ -1,298 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class DynamicEEFEditorContributionBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for views ReferencesTable - */ - private ReferencesTableSettings viewsSettings; - - /** - * Settings for model EObjectFlatComboViewer - */ - private EObjectFlatComboSettings modelSettings; - - - /** - * Default constructor - * - */ - public DynamicEEFEditorContributionBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject dynamicEEFEditorContribution, String editing_mode) { - super(editingContext, dynamicEEFEditorContribution, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EditorViewsRepository.class; - partKey = EditorViewsRepository.DynamicEEFEditorContribution.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final DynamicEEFEditorContribution dynamicEEFEditorContribution = (DynamicEEFEditorContribution)elt; - final DynamicEEFEditorContributionPropertiesEditionPart basePart = (DynamicEEFEditorContributionPropertiesEditionPart)editingPart; - // init values - if (isAccessible(EditorViewsRepository.DynamicEEFEditorContribution.Naming.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, dynamicEEFEditorContribution.getName())); - - if (isAccessible(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views)) { - viewsSettings = new ReferencesTableSettings(dynamicEEFEditorContribution, MappingPackage.eINSTANCE.getAbstractElementBinding_Views()); - basePart.initViews(viewsSettings); - } - if (isAccessible(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model)) { - // init part - modelSettings = new EObjectFlatComboSettings(dynamicEEFEditorContribution, MappingPackage.eINSTANCE.getEMFElementBinding_Model()); - basePart.initModel(modelSettings); - // set the button mode - basePart.setModelButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - - if (isAccessible(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views)) { - basePart.addFilterToViews(new EObjectFilter(ViewsPackage.Literals.VIEW)); - // Start of user code for additional businessfilters for views - - // End of user code - } - if (isAccessible(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model)) { - basePart.addFilterToModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EClassifier); - } - - }); - // Start of user code for additional businessfilters for model - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EditorViewsRepository.DynamicEEFEditorContribution.Naming.name) { - return MappingPackage.eINSTANCE.getAbstractElementBinding_Name(); - } - if (editorKey == EditorViewsRepository.DynamicEEFEditorContribution.Binding.views) { - return MappingPackage.eINSTANCE.getAbstractElementBinding_Views(); - } - if (editorKey == EditorViewsRepository.DynamicEEFEditorContribution.Binding.model) { - return MappingPackage.eINSTANCE.getEMFElementBinding_Model(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - DynamicEEFEditorContribution dynamicEEFEditorContribution = (DynamicEEFEditorContribution)semanticObject; - if (EditorViewsRepository.DynamicEEFEditorContribution.Naming.name == event.getAffectedEditor()) { - dynamicEEFEditorContribution.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EditorViewsRepository.DynamicEEFEditorContribution.Binding.views == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof View) { - viewsSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - viewsSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - viewsSettings.move(event.getNewIndex(), (View) event.getNewValue()); - } - } - if (EditorViewsRepository.DynamicEEFEditorContribution.Binding.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - modelSettings.setToReference((EClassifier)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, modelSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - DynamicEEFEditorContributionPropertiesEditionPart basePart = (DynamicEEFEditorContributionPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getAbstractElementBinding_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.DynamicEEFEditorContribution.Naming.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (MappingPackage.eINSTANCE.getAbstractElementBinding_Views().equals(msg.getFeature()) && isAccessible(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views)) - basePart.updateViews(); - if (MappingPackage.eINSTANCE.getEMFElementBinding_Model().equals(msg.getFeature()) && basePart != null && isAccessible(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model)) - basePart.setModel((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getAbstractElementBinding_Name(), - MappingPackage.eINSTANCE.getAbstractElementBinding_Views(), - MappingPackage.eINSTANCE.getEMFElementBinding_Model() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EditorViewsRepository.DynamicEEFEditorContribution.Naming.name || key == EditorViewsRepository.DynamicEEFEditorContribution.Binding.views || key == EditorViewsRepository.DynamicEEFEditorContribution.Binding.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Naming.name) - return "The name of this element binding"; //$NON-NLS-1$ - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Binding.views) - return "The mapped views"; //$NON-NLS-1$ - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Binding.model) - return "The mapped classifier"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EditorViewsRepository.DynamicEEFEditorContribution.Naming.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getAbstractElementBinding_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getAbstractElementBinding_Name().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/DynamicEEFEditorContributionPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/DynamicEEFEditorContributionPropertiesEditionComponent.java deleted file mode 100644 index 393ca0883..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/DynamicEEFEditorContributionPropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.views.parts.ViewsViewsRepository; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class DynamicEEFEditorContributionPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private DynamicEEFEditorContributionPropertiesEditionPart basePart; - - /** - * The DynamicEEFEditorContributionBasePropertiesEditionComponent sub component - * - */ - protected DynamicEEFEditorContributionBasePropertiesEditionComponent dynamicEEFEditorContributionBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param dynamicEEFEditorContribution the EObject to edit - * - */ - public DynamicEEFEditorContributionPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject dynamicEEFEditorContribution, String editing_mode) { - super(editingContext, editing_mode); - if (dynamicEEFEditorContribution instanceof DynamicEEFEditorContribution) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(dynamicEEFEditorContribution, PropertiesEditingProvider.class); - dynamicEEFEditorContributionBasePropertiesEditionComponent = (DynamicEEFEditorContributionBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DynamicEEFEditorContributionBasePropertiesEditionComponent.BASE_PART, DynamicEEFEditorContributionBasePropertiesEditionComponent.class); - addSubComponent(dynamicEEFEditorContributionBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(dynamicEEFEditorContribution, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (DynamicEEFEditorContributionBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (DynamicEEFEditorContributionPropertiesEditionPart)dynamicEEFEditorContributionBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (EditorViewsRepository.DynamicEEFEditorContribution.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (DynamicEEFEditorContributionPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == EditorViewsRepository.DynamicEEFEditorContribution.class) { - super.initPart(key, kind, element, allResource); - } - if (key == ViewsViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorContributionsBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorContributionsBasePropertiesEditionComponent.java deleted file mode 100644 index 398284304..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorContributionsBasePropertiesEditionComponent.java +++ /dev/null @@ -1,185 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.extended.editor.EEFEditorContributions; -import org.eclipse.emf.eef.extended.editor.parts.EEFEditorContributionsPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFEditorContributionsBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public EEFEditorContributionsBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eEFEditorContributions, String editing_mode) { - super(editingContext, eEFEditorContributions, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EditorViewsRepository.class; - partKey = EditorViewsRepository.EEFEditorContributions.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final EEFEditorContributions eEFEditorContributions = (EEFEditorContributions)elt; - final EEFEditorContributionsPropertiesEditionPart basePart = (EEFEditorContributionsPropertiesEditionPart)editingPart; - // init values - if (isAccessible(EditorViewsRepository.EEFEditorContributions.Naming.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, eEFEditorContributions.getName())); - - // init filters - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EditorViewsRepository.EEFEditorContributions.Naming.name) { - return MappingPackage.eINSTANCE.getCategory_Name(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - EEFEditorContributions eEFEditorContributions = (EEFEditorContributions)semanticObject; - if (EditorViewsRepository.EEFEditorContributions.Naming.name == event.getAffectedEditor()) { - eEFEditorContributions.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - EEFEditorContributionsPropertiesEditionPart basePart = (EEFEditorContributionsPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getCategory_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.EEFEditorContributions.Naming.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getCategory_Name() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EditorViewsRepository.EEFEditorContributions.Naming.name; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EditorViewsRepository.EEFEditorContributions.Naming.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getCategory_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getCategory_Name().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorContributionsPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorContributionsPropertiesEditionComponent.java deleted file mode 100644 index 5b0090b40..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorContributionsPropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.extended.editor.EEFEditorContributions; -import org.eclipse.emf.eef.extended.editor.parts.EEFEditorContributionsPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.views.parts.ViewsViewsRepository; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFEditorContributionsPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private EEFEditorContributionsPropertiesEditionPart basePart; - - /** - * The EEFEditorContributionsBasePropertiesEditionComponent sub component - * - */ - protected EEFEditorContributionsBasePropertiesEditionComponent eEFEditorContributionsBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param eEFEditorContributions the EObject to edit - * - */ - public EEFEditorContributionsPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eEFEditorContributions, String editing_mode) { - super(editingContext, editing_mode); - if (eEFEditorContributions instanceof EEFEditorContributions) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eEFEditorContributions, PropertiesEditingProvider.class); - eEFEditorContributionsBasePropertiesEditionComponent = (EEFEditorContributionsBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, EEFEditorContributionsBasePropertiesEditionComponent.BASE_PART, EEFEditorContributionsBasePropertiesEditionComponent.class); - addSubComponent(eEFEditorContributionsBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eEFEditorContributions, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (EEFEditorContributionsBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (EEFEditorContributionsPropertiesEditionPart)eEFEditorContributionsBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (EditorViewsRepository.EEFEditorContributions.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (EEFEditorContributionsPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == EditorViewsRepository.EEFEditorContributions.class) { - super.initPart(key, kind, element, allResource); - } - if (key == ViewsViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorPagesBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorPagesBasePropertiesEditionComponent.java deleted file mode 100644 index 5aa231578..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorPagesBasePropertiesEditionComponent.java +++ /dev/null @@ -1,197 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.extended.editor.EEFEditorPages; -import org.eclipse.emf.eef.extended.editor.parts.EEFEditorPagesPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.views.ViewsPackage; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFEditorPagesBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public EEFEditorPagesBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eEFEditorPages, String editing_mode) { - super(editingContext, eEFEditorPages, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EditorViewsRepository.class; - partKey = EditorViewsRepository.EEFEditorPages.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final EEFEditorPages eEFEditorPages = (EEFEditorPages)elt; - final EEFEditorPagesPropertiesEditionPart basePart = (EEFEditorPagesPropertiesEditionPart)editingPart; - // init values - if (isAccessible(EditorViewsRepository.EEFEditorPages.Properties.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, eEFEditorPages.getName())); - - // init filters - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EditorViewsRepository.EEFEditorPages.Properties.name) { - return ViewsPackage.eINSTANCE.getCategory_Name(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - EEFEditorPages eEFEditorPages = (EEFEditorPages)semanticObject; - if (EditorViewsRepository.EEFEditorPages.Properties.name == event.getAffectedEditor()) { - eEFEditorPages.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - EEFEditorPagesPropertiesEditionPart basePart = (EEFEditorPagesPropertiesEditionPart)editingPart; - if (ViewsPackage.eINSTANCE.getCategory_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.EEFEditorPages.Properties.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - ViewsPackage.eINSTANCE.getCategory_Name() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EditorViewsRepository.EEFEditorPages.Properties.name; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == EditorViewsRepository.EEFEditorPages.Properties.name) - return "The category name"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EditorViewsRepository.EEFEditorPages.Properties.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(ViewsPackage.eINSTANCE.getCategory_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(ViewsPackage.eINSTANCE.getCategory_Name().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorPagesPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorPagesPropertiesEditionComponent.java deleted file mode 100644 index 4cc129a76..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFEditorPagesPropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.extended.editor.EEFEditorPages; -import org.eclipse.emf.eef.extended.editor.parts.EEFEditorPagesPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.views.parts.ViewsViewsRepository; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFEditorPagesPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private EEFEditorPagesPropertiesEditionPart basePart; - - /** - * The EEFEditorPagesBasePropertiesEditionComponent sub component - * - */ - protected EEFEditorPagesBasePropertiesEditionComponent eEFEditorPagesBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param eEFEditorPages the EObject to edit - * - */ - public EEFEditorPagesPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eEFEditorPages, String editing_mode) { - super(editingContext, editing_mode); - if (eEFEditorPages instanceof EEFEditorPages) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eEFEditorPages, PropertiesEditingProvider.class); - eEFEditorPagesBasePropertiesEditionComponent = (EEFEditorPagesBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, EEFEditorPagesBasePropertiesEditionComponent.BASE_PART, EEFEditorPagesBasePropertiesEditionComponent.class); - addSubComponent(eEFEditorPagesBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eEFEditorPages, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (EEFEditorPagesBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (EEFEditorPagesPropertiesEditionPart)eEFEditorPagesBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (EditorViewsRepository.EEFEditorPages.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (EEFEditorPagesPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == EditorViewsRepository.EEFEditorPages.class) { - super.initPart(key, kind, element, allResource); - } - if (key == ViewsViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFMasterPageBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFMasterPageBasePropertiesEditionComponent.java deleted file mode 100644 index 3873802ed..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFMasterPageBasePropertiesEditionComponent.java +++ /dev/null @@ -1,268 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.extended.editor.EEFMasterPage; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.views.ViewsPackage; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFMasterPageBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public EEFMasterPageBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eEFMasterPage, String editing_mode) { - super(editingContext, eEFMasterPage, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EditorViewsRepository.class; - partKey = EditorViewsRepository.EEFMasterPage.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final EEFMasterPage eEFMasterPage = (EEFMasterPage)elt; - final EEFMasterPagePropertiesEditionPart basePart = (EEFMasterPagePropertiesEditionPart)editingPart; - // init values - if (isAccessible(EditorViewsRepository.EEFMasterPage.Naming.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, eEFMasterPage.getName())); - - if (isAccessible(EditorViewsRepository.EEFMasterPage.Naming.title_)) - basePart.setTitle_(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, eEFMasterPage.getTitle())); - - if (isAccessible(EditorViewsRepository.EEFMasterPage.Settings.orientable)) { - basePart.setOrientable(eEFMasterPage.isOrientable()); - } - if (isAccessible(EditorViewsRepository.EEFMasterPage.Settings.showValidatePage)) { - basePart.setShowValidatePage(eEFMasterPage.isShowValidatePage()); - } - // init filters - - - - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EditorViewsRepository.EEFMasterPage.Naming.name) { - return ViewsPackage.eINSTANCE.getViewElement_Name(); - } - if (editorKey == EditorViewsRepository.EEFMasterPage.Naming.title_) { - return EditorPackage.eINSTANCE.getEEFPage_Title(); - } - if (editorKey == EditorViewsRepository.EEFMasterPage.Settings.orientable) { - return EditorPackage.eINSTANCE.getEEFMasterPage_Orientable(); - } - if (editorKey == EditorViewsRepository.EEFMasterPage.Settings.showValidatePage) { - return EditorPackage.eINSTANCE.getEEFMasterPage_ShowValidatePage(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - EEFMasterPage eEFMasterPage = (EEFMasterPage)semanticObject; - if (EditorViewsRepository.EEFMasterPage.Naming.name == event.getAffectedEditor()) { - eEFMasterPage.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EditorViewsRepository.EEFMasterPage.Naming.title_ == event.getAffectedEditor()) { - eEFMasterPage.setTitle((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EditorViewsRepository.EEFMasterPage.Settings.orientable == event.getAffectedEditor()) { - eEFMasterPage.setOrientable((Boolean)event.getNewValue()); - } - if (EditorViewsRepository.EEFMasterPage.Settings.showValidatePage == event.getAffectedEditor()) { - eEFMasterPage.setShowValidatePage((Boolean)event.getNewValue()); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - EEFMasterPagePropertiesEditionPart basePart = (EEFMasterPagePropertiesEditionPart)editingPart; - if (ViewsPackage.eINSTANCE.getViewElement_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.EEFMasterPage.Naming.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (EditorPackage.eINSTANCE.getEEFPage_Title().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.EEFMasterPage.Naming.title_)) { - if (msg.getNewValue() != null) { - basePart.setTitle_(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setTitle_(""); - } - } - if (EditorPackage.eINSTANCE.getEEFMasterPage_Orientable().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.EEFMasterPage.Settings.orientable)) - basePart.setOrientable((Boolean)msg.getNewValue()); - - if (EditorPackage.eINSTANCE.getEEFMasterPage_ShowValidatePage().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.EEFMasterPage.Settings.showValidatePage)) - basePart.setShowValidatePage((Boolean)msg.getNewValue()); - - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - ViewsPackage.eINSTANCE.getViewElement_Name(), - EditorPackage.eINSTANCE.getEEFPage_Title(), - EditorPackage.eINSTANCE.getEEFMasterPage_Orientable(), - EditorPackage.eINSTANCE.getEEFMasterPage_ShowValidatePage() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EditorViewsRepository.EEFMasterPage.Naming.name; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == EditorViewsRepository.EEFMasterPage.Naming.name) - return "The element name"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EditorViewsRepository.EEFMasterPage.Naming.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(ViewsPackage.eINSTANCE.getViewElement_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(ViewsPackage.eINSTANCE.getViewElement_Name().getEAttributeType(), newValue); - } - if (EditorViewsRepository.EEFMasterPage.Naming.title_ == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EditorPackage.eINSTANCE.getEEFPage_Title().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EditorPackage.eINSTANCE.getEEFPage_Title().getEAttributeType(), newValue); - } - if (EditorViewsRepository.EEFMasterPage.Settings.orientable == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EditorPackage.eINSTANCE.getEEFMasterPage_Orientable().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EditorPackage.eINSTANCE.getEEFMasterPage_Orientable().getEAttributeType(), newValue); - } - if (EditorViewsRepository.EEFMasterPage.Settings.showValidatePage == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EditorPackage.eINSTANCE.getEEFMasterPage_ShowValidatePage().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EditorPackage.eINSTANCE.getEEFMasterPage_ShowValidatePage().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFMasterPagePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFMasterPagePropertiesEditionComponent.java deleted file mode 100644 index 638b88c69..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/EEFMasterPagePropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.extended.editor.EEFMasterPage; -import org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.views.parts.ViewsViewsRepository; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFMasterPagePropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private EEFMasterPagePropertiesEditionPart basePart; - - /** - * The EEFMasterPageBasePropertiesEditionComponent sub component - * - */ - protected EEFMasterPageBasePropertiesEditionComponent eEFMasterPageBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param eEFMasterPage the EObject to edit - * - */ - public EEFMasterPagePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eEFMasterPage, String editing_mode) { - super(editingContext, editing_mode); - if (eEFMasterPage instanceof EEFMasterPage) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eEFMasterPage, PropertiesEditingProvider.class); - eEFMasterPageBasePropertiesEditionComponent = (EEFMasterPageBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, EEFMasterPageBasePropertiesEditionComponent.BASE_PART, EEFMasterPageBasePropertiesEditionComponent.class); - addSubComponent(eEFMasterPageBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eEFMasterPage, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (EEFMasterPageBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (EEFMasterPagePropertiesEditionPart)eEFMasterPageBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (EditorViewsRepository.EEFMasterPage.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (EEFMasterPagePropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == EditorViewsRepository.EEFMasterPage.class) { - super.initPart(key, kind, element, allResource); - } - if (key == ViewsViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/PartFilterBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/PartFilterBasePropertiesEditionComponent.java deleted file mode 100644 index 5330a0c4f..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/PartFilterBasePropertiesEditionComponent.java +++ /dev/null @@ -1,342 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; - -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; - -import org.eclipse.emf.eef.components.ComponentsFactory; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; - -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.PartFilter; - -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; - -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; - -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; - -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; - -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewsFactory; - -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class PartFilterBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for filteredPart EObjectFlatComboViewer - */ - private EObjectFlatComboSettings filteredPartSettings; - - /** - * Settings for contextualComponent EObjectFlatComboViewer - */ - private EObjectFlatComboSettings contextualComponentSettings; - - - /** - * Default constructor - * - */ - public PartFilterBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject partFilter, String editing_mode) { - super(editingContext, partFilter, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EditorViewsRepository.class; - partKey = EditorViewsRepository.PartFilter.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final PartFilter partFilter = (PartFilter)elt; - final PartFilterPropertiesEditionPart basePart = (PartFilterPropertiesEditionPart)editingPart; - // init values - if (isAccessible(EditorViewsRepository.PartFilter.Naming.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, partFilter.getName())); - - if (isAccessible(EditorViewsRepository.PartFilter.Settings.mandatory)) { - basePart.setMandatory(partFilter.isMandatory()); - } - if (isAccessible(EditorViewsRepository.PartFilter.Filter.filteredPart)) { - // init part - filteredPartSettings = new EObjectFlatComboSettings(partFilter, EditorPackage.eINSTANCE.getPartFilter_FilteredPart()); - basePart.initFilteredPart(filteredPartSettings); - // set the button mode - basePart.setFilteredPartButtonMode(ButtonsModeEnum.BROWSE); - } - if (isAccessible(EditorViewsRepository.PartFilter.Filter.contextualComponent)) { - // init part - contextualComponentSettings = new EObjectFlatComboSettings(partFilter, EditorPackage.eINSTANCE.getPartFilter_ContextualComponent()); - basePart.initContextualComponent(contextualComponentSettings); - // set the button mode - basePart.setContextualComponentButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - - - if (isAccessible(EditorViewsRepository.PartFilter.Filter.filteredPart)) { - basePart.addFilterToFilteredPart(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof View); - } - - }); - // Start of user code for additional businessfilters for filteredPart - // End of user code - } - if (isAccessible(EditorViewsRepository.PartFilter.Filter.contextualComponent)) { - basePart.addFilterToContextualComponent(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof String && element.equals("")) || (element instanceof PropertiesEditionComponent); //$NON-NLS-1$ - } - - }); - // Start of user code for additional businessfilters for contextualComponent - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EditorViewsRepository.PartFilter.Naming.name) { - return FiltersPackage.eINSTANCE.getBindingFilter_Name(); - } - if (editorKey == EditorViewsRepository.PartFilter.Settings.mandatory) { - return FiltersPackage.eINSTANCE.getBindingFilter_Mandatory(); - } - if (editorKey == EditorViewsRepository.PartFilter.Filter.filteredPart) { - return EditorPackage.eINSTANCE.getPartFilter_FilteredPart(); - } - if (editorKey == EditorViewsRepository.PartFilter.Filter.contextualComponent) { - return EditorPackage.eINSTANCE.getPartFilter_ContextualComponent(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - PartFilter partFilter = (PartFilter)semanticObject; - if (EditorViewsRepository.PartFilter.Naming.name == event.getAffectedEditor()) { - partFilter.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EditorViewsRepository.PartFilter.Settings.mandatory == event.getAffectedEditor()) { - partFilter.setMandatory((Boolean)event.getNewValue()); - } - if (EditorViewsRepository.PartFilter.Filter.filteredPart == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - filteredPartSettings.setToReference((View)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - View eObject = ViewsFactory.eINSTANCE.createView(); - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - filteredPartSettings.setToReference(eObject); - } - } - if (EditorViewsRepository.PartFilter.Filter.contextualComponent == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - contextualComponentSettings.setToReference((PropertiesEditionComponent)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - PropertiesEditionComponent eObject = ComponentsFactory.eINSTANCE.createPropertiesEditionComponent(); - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - contextualComponentSettings.setToReference(eObject); - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - PartFilterPropertiesEditionPart basePart = (PartFilterPropertiesEditionPart)editingPart; - if (FiltersPackage.eINSTANCE.getBindingFilter_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.PartFilter.Naming.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.PartFilter.Settings.mandatory)) - basePart.setMandatory((Boolean)msg.getNewValue()); - - if (EditorPackage.eINSTANCE.getPartFilter_FilteredPart().equals(msg.getFeature()) && basePart != null && isAccessible(EditorViewsRepository.PartFilter.Filter.filteredPart)) - basePart.setFilteredPart((EObject)msg.getNewValue()); - if (EditorPackage.eINSTANCE.getPartFilter_ContextualComponent().equals(msg.getFeature()) && basePart != null && isAccessible(EditorViewsRepository.PartFilter.Filter.contextualComponent)) - basePart.setContextualComponent((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - FiltersPackage.eINSTANCE.getBindingFilter_Name(), - FiltersPackage.eINSTANCE.getBindingFilter_Mandatory(), - EditorPackage.eINSTANCE.getPartFilter_FilteredPart(), - EditorPackage.eINSTANCE.getPartFilter_ContextualComponent() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EditorViewsRepository.PartFilter.Filter.filteredPart; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EditorViewsRepository.PartFilter.Naming.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), newValue); - } - if (EditorViewsRepository.PartFilter.Settings.mandatory == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/PartFilterPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/PartFilterPropertiesEditionComponent.java deleted file mode 100644 index 1d3009301..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/PartFilterPropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.extended.editor.PartFilter; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.views.parts.ViewsViewsRepository; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class PartFilterPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private PartFilterPropertiesEditionPart basePart; - - /** - * The PartFilterBasePropertiesEditionComponent sub component - * - */ - protected PartFilterBasePropertiesEditionComponent partFilterBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param partFilter the EObject to edit - * - */ - public PartFilterPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject partFilter, String editing_mode) { - super(editingContext, editing_mode); - if (partFilter instanceof PartFilter) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(partFilter, PropertiesEditingProvider.class); - partFilterBasePropertiesEditionComponent = (PartFilterBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, PartFilterBasePropertiesEditionComponent.BASE_PART, PartFilterBasePropertiesEditionComponent.class); - addSubComponent(partFilterBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(partFilter, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (PartFilterBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (PartFilterPropertiesEditionPart)partFilterBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (EditorViewsRepository.PartFilter.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (PartFilterPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == EditorViewsRepository.PartFilter.class) { - super.initPart(key, kind, element, allResource); - } - if (key == ViewsViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StandardFormPageBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StandardFormPageBasePropertiesEditionComponent.java deleted file mode 100644 index bf988a798..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StandardFormPageBasePropertiesEditionComponent.java +++ /dev/null @@ -1,224 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.StandardFormPage; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.views.ViewsPackage; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class StandardFormPageBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public StandardFormPageBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject standardFormPage, String editing_mode) { - super(editingContext, standardFormPage, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EditorViewsRepository.class; - partKey = EditorViewsRepository.StandardFormPage.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final StandardFormPage standardFormPage = (StandardFormPage)elt; - final StandardFormPagePropertiesEditionPart basePart = (StandardFormPagePropertiesEditionPart)editingPart; - // init values - if (isAccessible(EditorViewsRepository.StandardFormPage.Naming.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, standardFormPage.getName())); - - if (isAccessible(EditorViewsRepository.StandardFormPage.Naming.title_)) - basePart.setTitle_(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, standardFormPage.getTitle())); - - // init filters - - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EditorViewsRepository.StandardFormPage.Naming.name) { - return ViewsPackage.eINSTANCE.getViewElement_Name(); - } - if (editorKey == EditorViewsRepository.StandardFormPage.Naming.title_) { - return EditorPackage.eINSTANCE.getEEFPage_Title(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - StandardFormPage standardFormPage = (StandardFormPage)semanticObject; - if (EditorViewsRepository.StandardFormPage.Naming.name == event.getAffectedEditor()) { - standardFormPage.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EditorViewsRepository.StandardFormPage.Naming.title_ == event.getAffectedEditor()) { - standardFormPage.setTitle((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - StandardFormPagePropertiesEditionPart basePart = (StandardFormPagePropertiesEditionPart)editingPart; - if (ViewsPackage.eINSTANCE.getViewElement_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.StandardFormPage.Naming.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (EditorPackage.eINSTANCE.getEEFPage_Title().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.StandardFormPage.Naming.title_)) { - if (msg.getNewValue() != null) { - basePart.setTitle_(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setTitle_(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - ViewsPackage.eINSTANCE.getViewElement_Name(), - EditorPackage.eINSTANCE.getEEFPage_Title() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EditorViewsRepository.StandardFormPage.Naming.name; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == EditorViewsRepository.StandardFormPage.Naming.name) - return "The element name"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EditorViewsRepository.StandardFormPage.Naming.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(ViewsPackage.eINSTANCE.getViewElement_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(ViewsPackage.eINSTANCE.getViewElement_Name().getEAttributeType(), newValue); - } - if (EditorViewsRepository.StandardFormPage.Naming.title_ == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EditorPackage.eINSTANCE.getEEFPage_Title().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EditorPackage.eINSTANCE.getEEFPage_Title().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StandardFormPagePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StandardFormPagePropertiesEditionComponent.java deleted file mode 100644 index e207e1653..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StandardFormPagePropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.extended.editor.StandardFormPage; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.views.parts.ViewsViewsRepository; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class StandardFormPagePropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private StandardFormPagePropertiesEditionPart basePart; - - /** - * The StandardFormPageBasePropertiesEditionComponent sub component - * - */ - protected StandardFormPageBasePropertiesEditionComponent standardFormPageBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param standardFormPage the EObject to edit - * - */ - public StandardFormPagePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject standardFormPage, String editing_mode) { - super(editingContext, editing_mode); - if (standardFormPage instanceof StandardFormPage) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(standardFormPage, PropertiesEditingProvider.class); - standardFormPageBasePropertiesEditionComponent = (StandardFormPageBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, StandardFormPageBasePropertiesEditionComponent.BASE_PART, StandardFormPageBasePropertiesEditionComponent.class); - addSubComponent(standardFormPageBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(standardFormPage, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (StandardFormPageBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (StandardFormPagePropertiesEditionPart)standardFormPageBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (EditorViewsRepository.StandardFormPage.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (StandardFormPagePropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == EditorViewsRepository.StandardFormPage.class) { - super.initPart(key, kind, element, allResource); - } - if (key == ViewsViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StaticEEFEditorContributionBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StaticEEFEditorContributionBasePropertiesEditionComponent.java deleted file mode 100644 index 2a6c3e89e..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StaticEEFEditorContributionBasePropertiesEditionComponent.java +++ /dev/null @@ -1,236 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewsPackage; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class StaticEEFEditorContributionBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for views ReferencesTable - */ - private ReferencesTableSettings viewsSettings; - - - /** - * Default constructor - * - */ - public StaticEEFEditorContributionBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject staticEEFEditorContribution, String editing_mode) { - super(editingContext, staticEEFEditorContribution, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EditorViewsRepository.class; - partKey = EditorViewsRepository.StaticEEFEditorContribution.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final StaticEEFEditorContribution staticEEFEditorContribution = (StaticEEFEditorContribution)elt; - final StaticEEFEditorContributionPropertiesEditionPart basePart = (StaticEEFEditorContributionPropertiesEditionPart)editingPart; - // init values - if (isAccessible(EditorViewsRepository.StaticEEFEditorContribution.Naming.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, staticEEFEditorContribution.getName())); - - if (isAccessible(EditorViewsRepository.StaticEEFEditorContribution.Binding.views)) { - viewsSettings = new ReferencesTableSettings(staticEEFEditorContribution, MappingPackage.eINSTANCE.getAbstractElementBinding_Views()); - basePart.initViews(viewsSettings); - } - // init filters - - if (isAccessible(EditorViewsRepository.StaticEEFEditorContribution.Binding.views)) { - basePart.addFilterToViews(new EObjectFilter(ViewsPackage.Literals.VIEW)); - // Start of user code for additional businessfilters for views - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EditorViewsRepository.StaticEEFEditorContribution.Naming.name) { - return MappingPackage.eINSTANCE.getAbstractElementBinding_Name(); - } - if (editorKey == EditorViewsRepository.StaticEEFEditorContribution.Binding.views) { - return MappingPackage.eINSTANCE.getAbstractElementBinding_Views(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - StaticEEFEditorContribution staticEEFEditorContribution = (StaticEEFEditorContribution)semanticObject; - if (EditorViewsRepository.StaticEEFEditorContribution.Naming.name == event.getAffectedEditor()) { - staticEEFEditorContribution.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EditorViewsRepository.StaticEEFEditorContribution.Binding.views == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof View) { - viewsSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - viewsSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - viewsSettings.move(event.getNewIndex(), (View) event.getNewValue()); - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - StaticEEFEditorContributionPropertiesEditionPart basePart = (StaticEEFEditorContributionPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getAbstractElementBinding_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.StaticEEFEditorContribution.Naming.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (MappingPackage.eINSTANCE.getAbstractElementBinding_Views().equals(msg.getFeature()) && isAccessible(EditorViewsRepository.StaticEEFEditorContribution.Binding.views)) - basePart.updateViews(); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getAbstractElementBinding_Name(), - MappingPackage.eINSTANCE.getAbstractElementBinding_Views() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EditorViewsRepository.StaticEEFEditorContribution.Naming.name || key == EditorViewsRepository.StaticEEFEditorContribution.Binding.views; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == EditorViewsRepository.StaticEEFEditorContribution.Naming.name) - return "The name of this element binding"; //$NON-NLS-1$ - if (key == EditorViewsRepository.StaticEEFEditorContribution.Binding.views) - return "The mapped views"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EditorViewsRepository.StaticEEFEditorContribution.Naming.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getAbstractElementBinding_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getAbstractElementBinding_Name().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StaticEEFEditorContributionPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StaticEEFEditorContributionPropertiesEditionComponent.java deleted file mode 100644 index 45a12146c..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/StaticEEFEditorContributionPropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.views.parts.ViewsViewsRepository; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class StaticEEFEditorContributionPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private StaticEEFEditorContributionPropertiesEditionPart basePart; - - /** - * The StaticEEFEditorContributionBasePropertiesEditionComponent sub component - * - */ - protected StaticEEFEditorContributionBasePropertiesEditionComponent staticEEFEditorContributionBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param staticEEFEditorContribution the EObject to edit - * - */ - public StaticEEFEditorContributionPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject staticEEFEditorContribution, String editing_mode) { - super(editingContext, editing_mode); - if (staticEEFEditorContribution instanceof StaticEEFEditorContribution) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(staticEEFEditorContribution, PropertiesEditingProvider.class); - staticEEFEditorContributionBasePropertiesEditionComponent = (StaticEEFEditorContributionBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, StaticEEFEditorContributionBasePropertiesEditionComponent.BASE_PART, StaticEEFEditorContributionBasePropertiesEditionComponent.class); - addSubComponent(staticEEFEditorContributionBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(staticEEFEditorContribution, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (StaticEEFEditorContributionBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (StaticEEFEditorContributionPropertiesEditionPart)staticEEFEditorContributionBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (EditorViewsRepository.StaticEEFEditorContribution.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (StaticEEFEditorContributionPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == EditorViewsRepository.StaticEEFEditorContribution.class) { - super.initPart(key, kind, element, allResource); - } - if (key == ViewsViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/TreeMasterPageBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/TreeMasterPageBasePropertiesEditionComponent.java deleted file mode 100644 index 4de35d936..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/TreeMasterPageBasePropertiesEditionComponent.java +++ /dev/null @@ -1,246 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.TreeMasterPage; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.views.ViewsPackage; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class TreeMasterPageBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public TreeMasterPageBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject treeMasterPage, String editing_mode) { - super(editingContext, treeMasterPage, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EditorViewsRepository.class; - partKey = EditorViewsRepository.TreeMasterPage.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final TreeMasterPage treeMasterPage = (TreeMasterPage)elt; - final TreeMasterPagePropertiesEditionPart basePart = (TreeMasterPagePropertiesEditionPart)editingPart; - // init values - if (isAccessible(EditorViewsRepository.TreeMasterPage.Naming.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, treeMasterPage.getName())); - - if (isAccessible(EditorViewsRepository.TreeMasterPage.Naming.title_)) - basePart.setTitle_(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, treeMasterPage.getTitle())); - - if (isAccessible(EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible)) { - basePart.setToolbarVisible(treeMasterPage.isToolbarVisible()); - } - // init filters - - - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EditorViewsRepository.TreeMasterPage.Naming.name) { - return ViewsPackage.eINSTANCE.getViewElement_Name(); - } - if (editorKey == EditorViewsRepository.TreeMasterPage.Naming.title_) { - return EditorPackage.eINSTANCE.getEEFPage_Title(); - } - if (editorKey == EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible) { - return EditorPackage.eINSTANCE.getTreeMasterPage_ToolbarVisible(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - TreeMasterPage treeMasterPage = (TreeMasterPage)semanticObject; - if (EditorViewsRepository.TreeMasterPage.Naming.name == event.getAffectedEditor()) { - treeMasterPage.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EditorViewsRepository.TreeMasterPage.Naming.title_ == event.getAffectedEditor()) { - treeMasterPage.setTitle((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible == event.getAffectedEditor()) { - treeMasterPage.setToolbarVisible((Boolean)event.getNewValue()); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - TreeMasterPagePropertiesEditionPart basePart = (TreeMasterPagePropertiesEditionPart)editingPart; - if (ViewsPackage.eINSTANCE.getViewElement_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.TreeMasterPage.Naming.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (EditorPackage.eINSTANCE.getEEFPage_Title().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.TreeMasterPage.Naming.title_)) { - if (msg.getNewValue() != null) { - basePart.setTitle_(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setTitle_(""); - } - } - if (EditorPackage.eINSTANCE.getTreeMasterPage_ToolbarVisible().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible)) - basePart.setToolbarVisible((Boolean)msg.getNewValue()); - - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - ViewsPackage.eINSTANCE.getViewElement_Name(), - EditorPackage.eINSTANCE.getEEFPage_Title(), - EditorPackage.eINSTANCE.getTreeMasterPage_ToolbarVisible() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EditorViewsRepository.TreeMasterPage.Naming.name; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == EditorViewsRepository.TreeMasterPage.Naming.name) - return "The element name"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EditorViewsRepository.TreeMasterPage.Naming.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(ViewsPackage.eINSTANCE.getViewElement_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(ViewsPackage.eINSTANCE.getViewElement_Name().getEAttributeType(), newValue); - } - if (EditorViewsRepository.TreeMasterPage.Naming.title_ == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EditorPackage.eINSTANCE.getEEFPage_Title().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EditorPackage.eINSTANCE.getEEFPage_Title().getEAttributeType(), newValue); - } - if (EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EditorPackage.eINSTANCE.getTreeMasterPage_ToolbarVisible().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EditorPackage.eINSTANCE.getTreeMasterPage_ToolbarVisible().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/TreeMasterPagePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/TreeMasterPagePropertiesEditionComponent.java deleted file mode 100644 index fc289f573..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/components/TreeMasterPagePropertiesEditionComponent.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.extended.editor.TreeMasterPage; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.views.parts.ViewsViewsRepository; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class TreeMasterPagePropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private TreeMasterPagePropertiesEditionPart basePart; - - /** - * The TreeMasterPageBasePropertiesEditionComponent sub component - * - */ - protected TreeMasterPageBasePropertiesEditionComponent treeMasterPageBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param treeMasterPage the EObject to edit - * - */ - public TreeMasterPagePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject treeMasterPage, String editing_mode) { - super(editingContext, editing_mode); - if (treeMasterPage instanceof TreeMasterPage) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(treeMasterPage, PropertiesEditingProvider.class); - treeMasterPageBasePropertiesEditionComponent = (TreeMasterPageBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, TreeMasterPageBasePropertiesEditionComponent.BASE_PART, TreeMasterPageBasePropertiesEditionComponent.class); - addSubComponent(treeMasterPageBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(treeMasterPage, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (TreeMasterPageBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (TreeMasterPagePropertiesEditionPart)treeMasterPageBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (EditorViewsRepository.TreeMasterPage.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (TreeMasterPagePropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == EditorViewsRepository.TreeMasterPage.class) { - super.initPart(key, kind, element, allResource); - } - if (key == ViewsViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/AllResourcesRootsRelativeInputImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/AllResourcesRootsRelativeInputImpl.java deleted file mode 100644 index 2abaea329..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/AllResourcesRootsRelativeInputImpl.java +++ /dev/null @@ -1,46 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput; -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -/** - * - * An implementation of the model object 'All Resources Roots Relative Input'. - * - *

- *

- * - * @generated - */ -public class AllResourcesRootsRelativeInputImpl extends EEFPageInputImpl implements AllResourcesRootsRelativeInput { - /** - * - * - * @generated - */ - protected AllResourcesRootsRelativeInputImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.ALL_RESOURCES_ROOTS_RELATIVE_INPUT; - } - -} //AllResourcesRootsRelativeInputImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/DynamicEEFEditorContributionImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/DynamicEEFEditorContributionImpl.java deleted file mode 100644 index b903aa2fd..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/DynamicEEFEditorContributionImpl.java +++ /dev/null @@ -1,214 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFPageInput; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.mapping.impl.EMFElementBindingImpl; - -/** - * - * An implementation of the model object 'Dynamic EEF Editor Contribution'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.impl.DynamicEEFEditorContributionImpl#getInput Input}
  • - *
- *

- * - * @generated - */ -public class DynamicEEFEditorContributionImpl extends EMFElementBindingImpl implements DynamicEEFEditorContribution { - /** - * The cached value of the '{@link #getInput() Input}' containment reference. - * - * - * @see #getInput() - * @generated - * @ordered - */ - protected EEFPageInput input; - - /** - * - * - * @generated - */ - protected DynamicEEFEditorContributionImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.DYNAMIC_EEF_EDITOR_CONTRIBUTION; - } - - /** - * - * - * @generated - */ - public EEFPageInput getInput() { - return input; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetInput(EEFPageInput newInput, NotificationChain msgs) { - EEFPageInput oldInput = input; - input = newInput; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT, oldInput, newInput); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setInput(EEFPageInput newInput) { - if (newInput != input) { - NotificationChain msgs = null; - if (input != null) - msgs = ((InternalEObject)input).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT, null, msgs); - if (newInput != null) - msgs = ((InternalEObject)newInput).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT, null, msgs); - msgs = basicSetInput(newInput, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT, newInput, newInput)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT: - return basicSetInput(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT: - return getInput(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT: - setInput((EEFPageInput)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT: - setInput((EEFPageInput)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT: - return input != null; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class baseClass) { - if (baseClass == EEFEditorContribution.class) { - switch (derivedFeatureID) { - case EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT: return EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT; - default: return -1; - } - } - return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); - } - - /** - * - * - * @generated - */ - @Override - public int eDerivedStructuralFeatureID(int baseFeatureID, Class baseClass) { - if (baseClass == EEFEditorContribution.class) { - switch (baseFeatureID) { - case EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT: return EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT; - default: return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - -} //DynamicEEFEditorContributionImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorContributionImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorContributionImpl.java deleted file mode 100644 index 88c019d32..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorContributionImpl.java +++ /dev/null @@ -1,180 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.eef.extended.editor.EEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFPageInput; -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -/** - * - * An implementation of the model object 'EEF Editor Contribution'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.impl.EEFEditorContributionImpl#getInput Input}
  • - *
- *

- * - * @generated - */ -public abstract class EEFEditorContributionImpl extends EObjectImpl implements EEFEditorContribution { - /** - * The cached value of the '{@link #getInput() Input}' containment reference. - * - * - * @see #getInput() - * @generated - * @ordered - */ - protected EEFPageInput input; - /** - * - * - * @generated - */ - protected EEFEditorContributionImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.EEF_EDITOR_CONTRIBUTION; - } - - /** - * - * - * @generated - */ - public EEFPageInput getInput() { - return input; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetInput(EEFPageInput newInput, NotificationChain msgs) { - EEFPageInput oldInput = input; - input = newInput; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT, oldInput, newInput); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setInput(EEFPageInput newInput) { - if (newInput != input) { - NotificationChain msgs = null; - if (input != null) - msgs = ((InternalEObject)input).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT, null, msgs); - if (newInput != null) - msgs = ((InternalEObject)newInput).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT, null, msgs); - msgs = basicSetInput(newInput, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT, newInput, newInput)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT: - return basicSetInput(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT: - return getInput(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT: - setInput((EEFPageInput)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT: - setInput((EEFPageInput)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT: - return input != null; - } - return super.eIsSet(featureID); - } - -} //EEFEditorContributionImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorContributionsImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorContributionsImpl.java deleted file mode 100644 index 61138b148..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorContributionsImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.extended.editor.EEFEditorContributions; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.mapping.impl.CategoryImpl; - -/** - * - * An implementation of the model object 'EEF Editor Contributions'. - * - *

- *

- * - * @generated - */ -public class EEFEditorContributionsImpl extends CategoryImpl implements EEFEditorContributions { - /** - * - * - * @generated - */ - protected EEFEditorContributionsImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.EEF_EDITOR_CONTRIBUTIONS; - } - -} //EEFEditorContributionsImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorPagesImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorPagesImpl.java deleted file mode 100644 index a034f9ee2..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFEditorPagesImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.extended.editor.EEFEditorPages; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.views.impl.CategoryImpl; - -/** - * - * An implementation of the model object 'EEF Editor Pages'. - * - *

- *

- * - * @generated - */ -public class EEFEditorPagesImpl extends CategoryImpl implements EEFEditorPages { - /** - * - * - * @generated - */ - protected EEFEditorPagesImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.EEF_EDITOR_PAGES; - } - -} //EEFEditorPagesImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFMasterPageImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFMasterPageImpl.java deleted file mode 100644 index d8b04a52a..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFMasterPageImpl.java +++ /dev/null @@ -1,221 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.extended.editor.EEFMasterPage; -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -/** - * - * An implementation of the model object 'EEF Master Page'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.impl.EEFMasterPageImpl#isOrientable Orientable}
  • - *
  • {@link org.eclipse.emf.eef.extended.editor.impl.EEFMasterPageImpl#isShowValidatePage Show Validate Page}
  • - *
- *

- * - * @generated - */ -public class EEFMasterPageImpl extends MasterDetailsPageImpl implements EEFMasterPage { - /** - * The default value of the '{@link #isOrientable() Orientable}' attribute. - * - * - * @see #isOrientable() - * @generated - * @ordered - */ - protected static final boolean ORIENTABLE_EDEFAULT = false; - - /** - * The cached value of the '{@link #isOrientable() Orientable}' attribute. - * - * - * @see #isOrientable() - * @generated - * @ordered - */ - protected boolean orientable = ORIENTABLE_EDEFAULT; - - /** - * The default value of the '{@link #isShowValidatePage() Show Validate Page}' attribute. - * - * - * @see #isShowValidatePage() - * @generated - * @ordered - */ - protected static final boolean SHOW_VALIDATE_PAGE_EDEFAULT = false; - - /** - * The cached value of the '{@link #isShowValidatePage() Show Validate Page}' attribute. - * - * - * @see #isShowValidatePage() - * @generated - * @ordered - */ - protected boolean showValidatePage = SHOW_VALIDATE_PAGE_EDEFAULT; - - /** - * - * - * @generated - */ - protected EEFMasterPageImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.EEF_MASTER_PAGE; - } - - /** - * - * - * @generated - */ - public boolean isOrientable() { - return orientable; - } - - /** - * - * - * @generated - */ - public void setOrientable(boolean newOrientable) { - boolean oldOrientable = orientable; - orientable = newOrientable; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EditorPackage.EEF_MASTER_PAGE__ORIENTABLE, oldOrientable, orientable)); - } - - /** - * - * - * @generated - */ - public boolean isShowValidatePage() { - return showValidatePage; - } - - /** - * - * - * @generated - */ - public void setShowValidatePage(boolean newShowValidatePage) { - boolean oldShowValidatePage = showValidatePage; - showValidatePage = newShowValidatePage; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EditorPackage.EEF_MASTER_PAGE__SHOW_VALIDATE_PAGE, oldShowValidatePage, showValidatePage)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EditorPackage.EEF_MASTER_PAGE__ORIENTABLE: - return isOrientable(); - case EditorPackage.EEF_MASTER_PAGE__SHOW_VALIDATE_PAGE: - return isShowValidatePage(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EditorPackage.EEF_MASTER_PAGE__ORIENTABLE: - setOrientable((Boolean)newValue); - return; - case EditorPackage.EEF_MASTER_PAGE__SHOW_VALIDATE_PAGE: - setShowValidatePage((Boolean)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EditorPackage.EEF_MASTER_PAGE__ORIENTABLE: - setOrientable(ORIENTABLE_EDEFAULT); - return; - case EditorPackage.EEF_MASTER_PAGE__SHOW_VALIDATE_PAGE: - setShowValidatePage(SHOW_VALIDATE_PAGE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EditorPackage.EEF_MASTER_PAGE__ORIENTABLE: - return orientable != ORIENTABLE_EDEFAULT; - case EditorPackage.EEF_MASTER_PAGE__SHOW_VALIDATE_PAGE: - return showValidatePage != SHOW_VALIDATE_PAGE_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (orientable: "); - result.append(orientable); - result.append(", showValidatePage: "); - result.append(showValidatePage); - result.append(')'); - return result.toString(); - } - -} //EEFMasterPageImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFPageImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFPageImpl.java deleted file mode 100644 index 7d01db4c1..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFPageImpl.java +++ /dev/null @@ -1,168 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.extended.editor.EEFPage; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.views.impl.ViewImpl; - -/** - * - * An implementation of the model object 'EEF Page'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.impl.EEFPageImpl#getTitle Title}
  • - *
- *

- * - * @generated - */ -public abstract class EEFPageImpl extends ViewImpl implements EEFPage { - /** - * The default value of the '{@link #getTitle() Title}' attribute. - * - * - * @see #getTitle() - * @generated - * @ordered - */ - protected static final String TITLE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getTitle() Title}' attribute. - * - * - * @see #getTitle() - * @generated - * @ordered - */ - protected String title = TITLE_EDEFAULT; - - /** - * - * - * @generated - */ - protected EEFPageImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.EEF_PAGE; - } - - /** - * - * - * @generated - */ - public String getTitle() { - return title; - } - - /** - * - * - * @generated - */ - public void setTitle(String newTitle) { - String oldTitle = title; - title = newTitle; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EditorPackage.EEF_PAGE__TITLE, oldTitle, title)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EditorPackage.EEF_PAGE__TITLE: - return getTitle(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EditorPackage.EEF_PAGE__TITLE: - setTitle((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EditorPackage.EEF_PAGE__TITLE: - setTitle(TITLE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EditorPackage.EEF_PAGE__TITLE: - return TITLE_EDEFAULT == null ? title != null : !TITLE_EDEFAULT.equals(title); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (title: "); - result.append(title); - result.append(')'); - return result.toString(); - } - -} //EEFPageImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFPageInputImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFPageInputImpl.java deleted file mode 100644 index 734d4d7b9..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EEFPageInputImpl.java +++ /dev/null @@ -1,181 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.eef.extended.editor.EEFPageInput; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery; - -/** - * - * An implementation of the model object 'EEF Page Input'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.impl.EEFPageInputImpl#getQuery Query}
  • - *
- *

- * - * @generated - */ -public abstract class EEFPageInputImpl extends EObjectImpl implements EEFPageInput { - /** - * The cached value of the '{@link #getQuery() Query}' containment reference. - * - * - * @see #getQuery() - * @generated - * @ordered - */ - protected EEFUnderstandableQuery query; - - /** - * - * - * @generated - */ - protected EEFPageInputImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.EEF_PAGE_INPUT; - } - - /** - * - * - * @generated - */ - public EEFUnderstandableQuery getQuery() { - return query; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetQuery(EEFUnderstandableQuery newQuery, NotificationChain msgs) { - EEFUnderstandableQuery oldQuery = query; - query = newQuery; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EditorPackage.EEF_PAGE_INPUT__QUERY, oldQuery, newQuery); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setQuery(EEFUnderstandableQuery newQuery) { - if (newQuery != query) { - NotificationChain msgs = null; - if (query != null) - msgs = ((InternalEObject)query).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EditorPackage.EEF_PAGE_INPUT__QUERY, null, msgs); - if (newQuery != null) - msgs = ((InternalEObject)newQuery).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EditorPackage.EEF_PAGE_INPUT__QUERY, null, msgs); - msgs = basicSetQuery(newQuery, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EditorPackage.EEF_PAGE_INPUT__QUERY, newQuery, newQuery)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case EditorPackage.EEF_PAGE_INPUT__QUERY: - return basicSetQuery(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EditorPackage.EEF_PAGE_INPUT__QUERY: - return getQuery(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EditorPackage.EEF_PAGE_INPUT__QUERY: - setQuery((EEFUnderstandableQuery)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EditorPackage.EEF_PAGE_INPUT__QUERY: - setQuery((EEFUnderstandableQuery)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EditorPackage.EEF_PAGE_INPUT__QUERY: - return query != null; - } - return super.eIsSet(featureID); - } - -} //EEFPageInputImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EditorFactoryImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EditorFactoryImpl.java deleted file mode 100644 index 514cfca2c..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EditorFactoryImpl.java +++ /dev/null @@ -1,222 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.impl.EFactoryImpl; -import org.eclipse.emf.ecore.plugin.EcorePlugin; -import org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput; -import org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFEditorContributions; -import org.eclipse.emf.eef.extended.editor.EEFEditorPages; -import org.eclipse.emf.eef.extended.editor.EEFMasterPage; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput; -import org.eclipse.emf.eef.extended.editor.PartFilter; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.extended.editor.StandardFormPage; -import org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.TreeMasterPage; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class EditorFactoryImpl extends EFactoryImpl implements EditorFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static EditorFactory init() { - try { - EditorFactory theEditorFactory = (EditorFactory)EPackage.Registry.INSTANCE.getEFactory("http://www.eclipse.org/emf/eef/extended/editor/1.0.0"); - if (theEditorFactory != null) { - return theEditorFactory; - } - } - catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new EditorFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public EditorFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case EditorPackage.STANDARD_FORM_PAGE: return createStandardFormPage(); - case EditorPackage.EEF_MASTER_PAGE: return createEEFMasterPage(); - case EditorPackage.TREE_MASTER_PAGE: return createTreeMasterPage(); - case EditorPackage.ALL_RESOURCES_ROOTS_RELATIVE_INPUT: return createAllResourcesRootsRelativeInput(); - case EditorPackage.FIRST_RESOURCE_ROOT_RELATIVE_INPUT: return createFirstResourceRootRelativeInput(); - case EditorPackage.PART_FILTER: return createPartFilter(); - case EditorPackage.EEF_EDITOR_CONTRIBUTIONS: return createEEFEditorContributions(); - case EditorPackage.EEF_EDITOR_PAGES: return createEEFEditorPages(); - case EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION: return createStaticEEFEditorContribution(); - case EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION: return createDynamicEEFEditorContribution(); - case EditorPackage.REFERENCEABLE_OBJECT: return createReferenceableObject(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public StandardFormPage createStandardFormPage() { - StandardFormPageImpl standardFormPage = new StandardFormPageImpl(); - return standardFormPage; - } - - /** - * - * - * @generated - */ - public EEFMasterPage createEEFMasterPage() { - EEFMasterPageImpl eefMasterPage = new EEFMasterPageImpl(); - return eefMasterPage; - } - - /** - * - * - * @generated - */ - public TreeMasterPage createTreeMasterPage() { - TreeMasterPageImpl treeMasterPage = new TreeMasterPageImpl(); - return treeMasterPage; - } - - /** - * - * - * @generated - */ - public AllResourcesRootsRelativeInput createAllResourcesRootsRelativeInput() { - AllResourcesRootsRelativeInputImpl allResourcesRootsRelativeInput = new AllResourcesRootsRelativeInputImpl(); - return allResourcesRootsRelativeInput; - } - - /** - * - * - * @generated - */ - public FirstResourceRootRelativeInput createFirstResourceRootRelativeInput() { - FirstResourceRootRelativeInputImpl firstResourceRootRelativeInput = new FirstResourceRootRelativeInputImpl(); - return firstResourceRootRelativeInput; - } - - /** - * - * - * @generated - */ - public PartFilter createPartFilter() { - PartFilterImpl partFilter = new PartFilterImpl(); - return partFilter; - } - - /** - * - * - * @generated - */ - public EEFEditorContributions createEEFEditorContributions() { - EEFEditorContributionsImpl eefEditorContributions = new EEFEditorContributionsImpl(); - return eefEditorContributions; - } - - /** - * - * - * @generated - */ - public EEFEditorPages createEEFEditorPages() { - EEFEditorPagesImpl eefEditorPages = new EEFEditorPagesImpl(); - return eefEditorPages; - } - - /** - * - * - * @generated - */ - public StaticEEFEditorContribution createStaticEEFEditorContribution() { - StaticEEFEditorContributionImpl staticEEFEditorContribution = new StaticEEFEditorContributionImpl(); - return staticEEFEditorContribution; - } - - /** - * - * - * @generated - */ - public DynamicEEFEditorContribution createDynamicEEFEditorContribution() { - DynamicEEFEditorContributionImpl dynamicEEFEditorContribution = new DynamicEEFEditorContributionImpl(); - return dynamicEEFEditorContribution; - } - - /** - * - * - * @generated - */ - public ReferenceableObject createReferenceableObject() { - ReferenceableObjectImpl referenceableObject = new ReferenceableObjectImpl(); - return referenceableObject; - } - - /** - * - * - * @generated - */ - public EditorPackage getEditorPackage() { - return (EditorPackage)getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static EditorPackage getPackage() { - return EditorPackage.eINSTANCE; - } - -} //EditorFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EditorPackageImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EditorPackageImpl.java deleted file mode 100644 index 4ab2f546a..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/EditorPackageImpl.java +++ /dev/null @@ -1,592 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.impl.EPackageImpl; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput; -import org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFEditorContributions; -import org.eclipse.emf.eef.extended.editor.EEFEditorPages; -import org.eclipse.emf.eef.extended.editor.EEFMasterPage; -import org.eclipse.emf.eef.extended.editor.EEFPage; -import org.eclipse.emf.eef.extended.editor.EEFPageInput; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput; -import org.eclipse.emf.eef.extended.editor.MasterDetailsPage; -import org.eclipse.emf.eef.extended.editor.PartFilter; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.extended.editor.StandardFormPage; -import org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.TreeMasterPage; -import org.eclipse.emf.eef.extended.query.QueryPackage; -import org.eclipse.emf.eef.extended.query.impl.QueryPackageImpl; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.views.ViewsPackage; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class EditorPackageImpl extends EPackageImpl implements EditorPackage { - /** - * - * - * @generated - */ - private EClass eefEditorContributionEClass = null; - - /** - * - * - * @generated - */ - private EClass eefPageEClass = null; - - /** - * - * - * @generated - */ - private EClass standardFormPageEClass = null; - - /** - * - * - * @generated - */ - private EClass masterDetailsPageEClass = null; - - /** - * - * - * @generated - */ - private EClass eefMasterPageEClass = null; - - /** - * - * - * @generated - */ - private EClass treeMasterPageEClass = null; - - /** - * - * - * @generated - */ - private EClass eefPageInputEClass = null; - - /** - * - * - * @generated - */ - private EClass allResourcesRootsRelativeInputEClass = null; - - /** - * - * - * @generated - */ - private EClass firstResourceRootRelativeInputEClass = null; - - /** - * - * - * @generated - */ - private EClass partFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass eefEditorContributionsEClass = null; - - /** - * - * - * @generated - */ - private EClass eefEditorPagesEClass = null; - - /** - * - * - * @generated - */ - private EClass staticEEFEditorContributionEClass = null; - - /** - * - * - * @generated - */ - private EClass dynamicEEFEditorContributionEClass = null; - - /** - * - * - * @generated - */ - private EClass referenceableObjectEClass = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.extended.editor.EditorPackage#eNS_URI - * @see #init() - * @generated - */ - private EditorPackageImpl() { - super(eNS_URI, EditorFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link EditorPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static EditorPackage init() { - if (isInited) return (EditorPackage)EPackage.Registry.INSTANCE.getEPackage(EditorPackage.eNS_URI); - - // Obtain or create and register package - EditorPackageImpl theEditorPackage = (EditorPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof EditorPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new EditorPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - ComponentsPackage.eINSTANCE.eClass(); - - // Obtain or create and register interdependencies - QueryPackageImpl theQueryPackage = (QueryPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(QueryPackage.eNS_URI) instanceof QueryPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(QueryPackage.eNS_URI) : QueryPackage.eINSTANCE); - - // Create package meta-data objects - theEditorPackage.createPackageContents(); - theQueryPackage.createPackageContents(); - - // Initialize created meta-data - theEditorPackage.initializePackageContents(); - theQueryPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theEditorPackage.freeze(); - - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(EditorPackage.eNS_URI, theEditorPackage); - return theEditorPackage; - } - - /** - * - * - * @generated - */ - public EClass getEEFEditorContribution() { - return eefEditorContributionEClass; - } - - /** - * - * - * @generated - */ - public EReference getEEFEditorContribution_Input() { - return (EReference)eefEditorContributionEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getEEFPage() { - return eefPageEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getEEFPage_Title() { - return (EAttribute)eefPageEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getStandardFormPage() { - return standardFormPageEClass; - } - - /** - * - * - * @generated - */ - public EClass getMasterDetailsPage() { - return masterDetailsPageEClass; - } - - /** - * - * - * @generated - */ - public EClass getEEFMasterPage() { - return eefMasterPageEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getEEFMasterPage_Orientable() { - return (EAttribute)eefMasterPageEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EAttribute getEEFMasterPage_ShowValidatePage() { - return (EAttribute)eefMasterPageEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getTreeMasterPage() { - return treeMasterPageEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getTreeMasterPage_ToolbarVisible() { - return (EAttribute)treeMasterPageEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getEEFPageInput() { - return eefPageInputEClass; - } - - /** - * - * - * @generated - */ - public EReference getEEFPageInput_Query() { - return (EReference)eefPageInputEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getAllResourcesRootsRelativeInput() { - return allResourcesRootsRelativeInputEClass; - } - - /** - * - * - * @generated - */ - public EClass getFirstResourceRootRelativeInput() { - return firstResourceRootRelativeInputEClass; - } - - /** - * - * - * @generated - */ - public EClass getPartFilter() { - return partFilterEClass; - } - - /** - * - * - * @generated - */ - public EReference getPartFilter_FilteredPart() { - return (EReference)partFilterEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getPartFilter_ContextualComponent() { - return (EReference)partFilterEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getEEFEditorContributions() { - return eefEditorContributionsEClass; - } - - /** - * - * - * @generated - */ - public EClass getEEFEditorPages() { - return eefEditorPagesEClass; - } - - /** - * - * - * @generated - */ - public EClass getStaticEEFEditorContribution() { - return staticEEFEditorContributionEClass; - } - - /** - * - * - * @generated - */ - public EClass getDynamicEEFEditorContribution() { - return dynamicEEFEditorContributionEClass; - } - - /** - * - * - * @generated - */ - public EClass getReferenceableObject() { - return referenceableObjectEClass; - } - - /** - * - * - * @generated - */ - public EditorFactory getEditorFactory() { - return (EditorFactory)getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) return; - isCreated = true; - - // Create classes and their features - eefEditorContributionEClass = createEClass(EEF_EDITOR_CONTRIBUTION); - createEReference(eefEditorContributionEClass, EEF_EDITOR_CONTRIBUTION__INPUT); - - eefPageEClass = createEClass(EEF_PAGE); - createEAttribute(eefPageEClass, EEF_PAGE__TITLE); - - standardFormPageEClass = createEClass(STANDARD_FORM_PAGE); - - masterDetailsPageEClass = createEClass(MASTER_DETAILS_PAGE); - - eefMasterPageEClass = createEClass(EEF_MASTER_PAGE); - createEAttribute(eefMasterPageEClass, EEF_MASTER_PAGE__ORIENTABLE); - createEAttribute(eefMasterPageEClass, EEF_MASTER_PAGE__SHOW_VALIDATE_PAGE); - - treeMasterPageEClass = createEClass(TREE_MASTER_PAGE); - createEAttribute(treeMasterPageEClass, TREE_MASTER_PAGE__TOOLBAR_VISIBLE); - - eefPageInputEClass = createEClass(EEF_PAGE_INPUT); - createEReference(eefPageInputEClass, EEF_PAGE_INPUT__QUERY); - - allResourcesRootsRelativeInputEClass = createEClass(ALL_RESOURCES_ROOTS_RELATIVE_INPUT); - - firstResourceRootRelativeInputEClass = createEClass(FIRST_RESOURCE_ROOT_RELATIVE_INPUT); - - partFilterEClass = createEClass(PART_FILTER); - createEReference(partFilterEClass, PART_FILTER__FILTERED_PART); - createEReference(partFilterEClass, PART_FILTER__CONTEXTUAL_COMPONENT); - - eefEditorContributionsEClass = createEClass(EEF_EDITOR_CONTRIBUTIONS); - - eefEditorPagesEClass = createEClass(EEF_EDITOR_PAGES); - - staticEEFEditorContributionEClass = createEClass(STATIC_EEF_EDITOR_CONTRIBUTION); - - dynamicEEFEditorContributionEClass = createEClass(DYNAMIC_EEF_EDITOR_CONTRIBUTION); - - referenceableObjectEClass = createEClass(REFERENCEABLE_OBJECT); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - ViewsPackage theViewsPackage = (ViewsPackage)EPackage.Registry.INSTANCE.getEPackage(ViewsPackage.eNS_URI); - EcorePackage theEcorePackage = (EcorePackage)EPackage.Registry.INSTANCE.getEPackage(EcorePackage.eNS_URI); - QueryPackage theQueryPackage = (QueryPackage)EPackage.Registry.INSTANCE.getEPackage(QueryPackage.eNS_URI); - FiltersPackage theFiltersPackage = (FiltersPackage)EPackage.Registry.INSTANCE.getEPackage(FiltersPackage.eNS_URI); - ComponentsPackage theComponentsPackage = (ComponentsPackage)EPackage.Registry.INSTANCE.getEPackage(ComponentsPackage.eNS_URI); - MappingPackage theMappingPackage = (MappingPackage)EPackage.Registry.INSTANCE.getEPackage(MappingPackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - eefPageEClass.getESuperTypes().add(theViewsPackage.getView()); - standardFormPageEClass.getESuperTypes().add(this.getEEFPage()); - masterDetailsPageEClass.getESuperTypes().add(this.getEEFPage()); - eefMasterPageEClass.getESuperTypes().add(this.getMasterDetailsPage()); - treeMasterPageEClass.getESuperTypes().add(this.getMasterDetailsPage()); - allResourcesRootsRelativeInputEClass.getESuperTypes().add(this.getEEFPageInput()); - firstResourceRootRelativeInputEClass.getESuperTypes().add(this.getEEFPageInput()); - partFilterEClass.getESuperTypes().add(theFiltersPackage.getBindingFilter()); - eefEditorContributionsEClass.getESuperTypes().add(theMappingPackage.getCategory()); - eefEditorPagesEClass.getESuperTypes().add(theViewsPackage.getCategory()); - staticEEFEditorContributionEClass.getESuperTypes().add(theMappingPackage.getAbstractElementBinding()); - staticEEFEditorContributionEClass.getESuperTypes().add(this.getEEFEditorContribution()); - dynamicEEFEditorContributionEClass.getESuperTypes().add(theMappingPackage.getEMFElementBinding()); - dynamicEEFEditorContributionEClass.getESuperTypes().add(this.getEEFEditorContribution()); - - // Initialize classes and features; add operations and parameters - initEClass(eefEditorContributionEClass, EEFEditorContribution.class, "EEFEditorContribution", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getEEFEditorContribution_Input(), this.getEEFPageInput(), null, "input", null, 1, 1, EEFEditorContribution.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(eefPageEClass, EEFPage.class, "EEFPage", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getEEFPage_Title(), ecorePackage.getEString(), "title", null, 0, 1, EEFPage.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(standardFormPageEClass, StandardFormPage.class, "StandardFormPage", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(masterDetailsPageEClass, MasterDetailsPage.class, "MasterDetailsPage", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(eefMasterPageEClass, EEFMasterPage.class, "EEFMasterPage", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getEEFMasterPage_Orientable(), ecorePackage.getEBoolean(), "orientable", null, 0, 1, EEFMasterPage.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getEEFMasterPage_ShowValidatePage(), ecorePackage.getEBoolean(), "showValidatePage", null, 0, 1, EEFMasterPage.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(treeMasterPageEClass, TreeMasterPage.class, "TreeMasterPage", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getTreeMasterPage_ToolbarVisible(), theEcorePackage.getEBoolean(), "toolbarVisible", null, 0, 1, TreeMasterPage.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(eefPageInputEClass, EEFPageInput.class, "EEFPageInput", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getEEFPageInput_Query(), theQueryPackage.getEEFUnderstandableQuery(), null, "query", null, 0, 1, EEFPageInput.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(allResourcesRootsRelativeInputEClass, AllResourcesRootsRelativeInput.class, "AllResourcesRootsRelativeInput", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(firstResourceRootRelativeInputEClass, FirstResourceRootRelativeInput.class, "FirstResourceRootRelativeInput", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(partFilterEClass, PartFilter.class, "PartFilter", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getPartFilter_FilteredPart(), theViewsPackage.getView(), null, "filteredPart", null, 1, 1, PartFilter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getPartFilter_ContextualComponent(), theComponentsPackage.getPropertiesEditionComponent(), null, "contextualComponent", null, 0, 1, PartFilter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(eefEditorContributionsEClass, EEFEditorContributions.class, "EEFEditorContributions", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(eefEditorPagesEClass, EEFEditorPages.class, "EEFEditorPages", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(staticEEFEditorContributionEClass, StaticEEFEditorContribution.class, "StaticEEFEditorContribution", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(dynamicEEFEditorContributionEClass, DynamicEEFEditorContribution.class, "DynamicEEFEditorContribution", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(referenceableObjectEClass, ReferenceableObject.class, "ReferenceableObject", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - // Create resource - createResource(eNS_URI); - } - -} //EditorPackageImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/FirstResourceRootRelativeInputImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/FirstResourceRootRelativeInputImpl.java deleted file mode 100644 index 0dafa8396..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/FirstResourceRootRelativeInputImpl.java +++ /dev/null @@ -1,46 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput; - -/** - * - * An implementation of the model object 'First Resource Root Relative Input'. - * - *

- *

- * - * @generated - */ -public class FirstResourceRootRelativeInputImpl extends EEFPageInputImpl implements FirstResourceRootRelativeInput { - /** - * - * - * @generated - */ - protected FirstResourceRootRelativeInputImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.FIRST_RESOURCE_ROOT_RELATIVE_INPUT; - } - -} //FirstResourceRootRelativeInputImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/MasterDetailsPageImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/MasterDetailsPageImpl.java deleted file mode 100644 index 873ed9938..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/MasterDetailsPageImpl.java +++ /dev/null @@ -1,46 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.MasterDetailsPage; - -/** - * - * An implementation of the model object 'Master Details Page'. - * - *

- *

- * - * @generated - */ -public abstract class MasterDetailsPageImpl extends EEFPageImpl implements MasterDetailsPage { - /** - * - * - * @generated - */ - protected MasterDetailsPageImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.MASTER_DETAILS_PAGE; - } - -} //MasterDetailsPageImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/PartFilterImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/PartFilterImpl.java deleted file mode 100644 index 1782f0e05..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/PartFilterImpl.java +++ /dev/null @@ -1,223 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.PartFilter; -import org.eclipse.emf.eef.mapping.filters.impl.BindingFilterImpl; -import org.eclipse.emf.eef.views.View; - -/** - * - * An implementation of the model object 'Part Filter'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.impl.PartFilterImpl#getFilteredPart Filtered Part}
  • - *
  • {@link org.eclipse.emf.eef.extended.editor.impl.PartFilterImpl#getContextualComponent Contextual Component}
  • - *
- *

- * - * @generated - */ -public class PartFilterImpl extends BindingFilterImpl implements PartFilter { - /** - * The cached value of the '{@link #getFilteredPart() Filtered Part}' reference. - * - * - * @see #getFilteredPart() - * @generated - * @ordered - */ - protected View filteredPart; - - /** - * The cached value of the '{@link #getContextualComponent() Contextual Component}' reference. - * - * - * @see #getContextualComponent() - * @generated - * @ordered - */ - protected PropertiesEditionComponent contextualComponent; - - /** - * - * - * @generated - */ - protected PartFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.PART_FILTER; - } - - /** - * - * - * @generated - */ - public View getFilteredPart() { - if (filteredPart != null && filteredPart.eIsProxy()) { - InternalEObject oldFilteredPart = (InternalEObject)filteredPart; - filteredPart = (View)eResolveProxy(oldFilteredPart); - if (filteredPart != oldFilteredPart) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EditorPackage.PART_FILTER__FILTERED_PART, oldFilteredPart, filteredPart)); - } - } - return filteredPart; - } - - /** - * - * - * @generated - */ - public View basicGetFilteredPart() { - return filteredPart; - } - - /** - * - * - * @generated - */ - public void setFilteredPart(View newFilteredPart) { - View oldFilteredPart = filteredPart; - filteredPart = newFilteredPart; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EditorPackage.PART_FILTER__FILTERED_PART, oldFilteredPart, filteredPart)); - } - - /** - * - * - * @generated - */ - public PropertiesEditionComponent getContextualComponent() { - if (contextualComponent != null && contextualComponent.eIsProxy()) { - InternalEObject oldContextualComponent = (InternalEObject)contextualComponent; - contextualComponent = (PropertiesEditionComponent)eResolveProxy(oldContextualComponent); - if (contextualComponent != oldContextualComponent) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EditorPackage.PART_FILTER__CONTEXTUAL_COMPONENT, oldContextualComponent, contextualComponent)); - } - } - return contextualComponent; - } - - /** - * - * - * @generated - */ - public PropertiesEditionComponent basicGetContextualComponent() { - return contextualComponent; - } - - /** - * - * - * @generated - */ - public void setContextualComponent(PropertiesEditionComponent newContextualComponent) { - PropertiesEditionComponent oldContextualComponent = contextualComponent; - contextualComponent = newContextualComponent; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EditorPackage.PART_FILTER__CONTEXTUAL_COMPONENT, oldContextualComponent, contextualComponent)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EditorPackage.PART_FILTER__FILTERED_PART: - if (resolve) return getFilteredPart(); - return basicGetFilteredPart(); - case EditorPackage.PART_FILTER__CONTEXTUAL_COMPONENT: - if (resolve) return getContextualComponent(); - return basicGetContextualComponent(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EditorPackage.PART_FILTER__FILTERED_PART: - setFilteredPart((View)newValue); - return; - case EditorPackage.PART_FILTER__CONTEXTUAL_COMPONENT: - setContextualComponent((PropertiesEditionComponent)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EditorPackage.PART_FILTER__FILTERED_PART: - setFilteredPart((View)null); - return; - case EditorPackage.PART_FILTER__CONTEXTUAL_COMPONENT: - setContextualComponent((PropertiesEditionComponent)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EditorPackage.PART_FILTER__FILTERED_PART: - return filteredPart != null; - case EditorPackage.PART_FILTER__CONTEXTUAL_COMPONENT: - return contextualComponent != null; - } - return super.eIsSet(featureID); - } - -} //PartFilterImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/ReferenceableObjectImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/ReferenceableObjectImpl.java deleted file mode 100644 index aebe49b86..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/ReferenceableObjectImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; - -/** - * - * An implementation of the model object 'Referenceable Object'. - * - *

- *

- * - * @generated - */ -public class ReferenceableObjectImpl extends EObjectImpl implements ReferenceableObject { - /** - * - * - * @generated - */ - protected ReferenceableObjectImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.REFERENCEABLE_OBJECT; - } - -} //ReferenceableObjectImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/StandardFormPageImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/StandardFormPageImpl.java deleted file mode 100644 index 4a1e4410e..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/StandardFormPageImpl.java +++ /dev/null @@ -1,46 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.StandardFormPage; - -/** - * - * An implementation of the model object 'Standard Form Page'. - * - *

- *

- * - * @generated - */ -public class StandardFormPageImpl extends EEFPageImpl implements StandardFormPage { - /** - * - * - * @generated - */ - protected StandardFormPageImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.STANDARD_FORM_PAGE; - } - -} //StandardFormPageImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/StaticEEFEditorContributionImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/StaticEEFEditorContributionImpl.java deleted file mode 100644 index 51fbfd931..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/StaticEEFEditorContributionImpl.java +++ /dev/null @@ -1,214 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.extended.editor.EEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFPageInput; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution; -import org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl; - -/** - * - * An implementation of the model object 'Static EEF Editor Contribution'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.impl.StaticEEFEditorContributionImpl#getInput Input}
  • - *
- *

- * - * @generated - */ -public class StaticEEFEditorContributionImpl extends AbstractElementBindingImpl implements StaticEEFEditorContribution { - /** - * The cached value of the '{@link #getInput() Input}' containment reference. - * - * - * @see #getInput() - * @generated - * @ordered - */ - protected EEFPageInput input; - - /** - * - * - * @generated - */ - protected StaticEEFEditorContributionImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.STATIC_EEF_EDITOR_CONTRIBUTION; - } - - /** - * - * - * @generated - */ - public EEFPageInput getInput() { - return input; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetInput(EEFPageInput newInput, NotificationChain msgs) { - EEFPageInput oldInput = input; - input = newInput; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT, oldInput, newInput); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setInput(EEFPageInput newInput) { - if (newInput != input) { - NotificationChain msgs = null; - if (input != null) - msgs = ((InternalEObject)input).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT, null, msgs); - if (newInput != null) - msgs = ((InternalEObject)newInput).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT, null, msgs); - msgs = basicSetInput(newInput, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT, newInput, newInput)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT: - return basicSetInput(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT: - return getInput(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT: - setInput((EEFPageInput)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT: - setInput((EEFPageInput)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT: - return input != null; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class baseClass) { - if (baseClass == EEFEditorContribution.class) { - switch (derivedFeatureID) { - case EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT: return EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT; - default: return -1; - } - } - return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); - } - - /** - * - * - * @generated - */ - @Override - public int eDerivedStructuralFeatureID(int baseFeatureID, Class baseClass) { - if (baseClass == EEFEditorContribution.class) { - switch (baseFeatureID) { - case EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT: return EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT; - default: return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - -} //StaticEEFEditorContributionImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/TreeMasterPageImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/TreeMasterPageImpl.java deleted file mode 100644 index 9cfa2d9be..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/impl/TreeMasterPageImpl.java +++ /dev/null @@ -1,167 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.TreeMasterPage; - -/** - * - * An implementation of the model object 'Tree Master Page'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.extended.editor.impl.TreeMasterPageImpl#isToolbarVisible Toolbar Visible}
  • - *
- *

- * - * @generated - */ -public class TreeMasterPageImpl extends MasterDetailsPageImpl implements TreeMasterPage { - /** - * The default value of the '{@link #isToolbarVisible() Toolbar Visible}' attribute. - * - * - * @see #isToolbarVisible() - * @generated - * @ordered - */ - protected static final boolean TOOLBAR_VISIBLE_EDEFAULT = false; - - /** - * The cached value of the '{@link #isToolbarVisible() Toolbar Visible}' attribute. - * - * - * @see #isToolbarVisible() - * @generated - * @ordered - */ - protected boolean toolbarVisible = TOOLBAR_VISIBLE_EDEFAULT; - - /** - * - * - * @generated - */ - protected TreeMasterPageImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EditorPackage.Literals.TREE_MASTER_PAGE; - } - - /** - * - * - * @generated - */ - public boolean isToolbarVisible() { - return toolbarVisible; - } - - /** - * - * - * @generated - */ - public void setToolbarVisible(boolean newToolbarVisible) { - boolean oldToolbarVisible = toolbarVisible; - toolbarVisible = newToolbarVisible; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EditorPackage.TREE_MASTER_PAGE__TOOLBAR_VISIBLE, oldToolbarVisible, toolbarVisible)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EditorPackage.TREE_MASTER_PAGE__TOOLBAR_VISIBLE: - return isToolbarVisible(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EditorPackage.TREE_MASTER_PAGE__TOOLBAR_VISIBLE: - setToolbarVisible((Boolean)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EditorPackage.TREE_MASTER_PAGE__TOOLBAR_VISIBLE: - setToolbarVisible(TOOLBAR_VISIBLE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EditorPackage.TREE_MASTER_PAGE__TOOLBAR_VISIBLE: - return toolbarVisible != TOOLBAR_VISIBLE_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (toolbarVisible: "); - result.append(toolbarVisible); - result.append(')'); - return result.toString(); - } - -} //TreeMasterPageImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/DynamicEEFEditorContributionPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/DynamicEEFEditorContributionPropertiesEditionPart.java deleted file mode 100644 index cec2d1626..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/DynamicEEFEditorContributionPropertiesEditionPart.java +++ /dev/null @@ -1,148 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public interface DynamicEEFEditorContributionPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the model - * - */ - public EObject getModel(); - - /** - * Init the model - * @param settings the combo setting - */ - public void initModel(EObjectFlatComboSettings settings); - - /** - * Defines a new model - * @param newValue the new model to set - * - */ - public void setModel(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setModelButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - - - - /** - * Init the views - * @param settings settings for the views ReferencesTable - */ - public void initViews(ReferencesTableSettings settings); - - /** - * Update the views - * @param newValue the views to update - * - */ - public void updateViews(); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViews(ViewerFilter filter); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the views table - * - */ - public boolean isContainedInViewsTable(EObject element); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFEditorContributionsPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFEditorContributionsPropertiesEditionPart.java deleted file mode 100644 index ba097e85e..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFEditorContributionsPropertiesEditionPart.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts; - -// Start of user code for imports - - - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public interface EEFEditorContributionsPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFEditorPagesPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFEditorPagesPropertiesEditionPart.java deleted file mode 100644 index ff022ae90..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFEditorPagesPropertiesEditionPart.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts; - -// Start of user code for imports - - - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public interface EEFEditorPagesPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFMasterPagePropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFMasterPagePropertiesEditionPart.java deleted file mode 100644 index 5ab69bece..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EEFMasterPagePropertiesEditionPart.java +++ /dev/null @@ -1,97 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts; - -// Start of user code for imports - - - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public interface EEFMasterPagePropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the title - * - */ - public String getTitle_(); - - /** - * Defines a new title - * @param newValue the new title to set - * - */ - public void setTitle_(String newValue); - - - /** - * @return the orientable - * - */ - public Boolean getOrientable(); - - /** - * Defines a new orientable - * @param newValue the new orientable to set - * - */ - public void setOrientable(Boolean newValue); - - - /** - * @return the showValidatePage - * - */ - public Boolean getShowValidatePage(); - - /** - * Defines a new showValidatePage - * @param newValue the new showValidatePage to set - * - */ - public void setShowValidatePage(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EditorViewsRepository.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EditorViewsRepository.java deleted file mode 100644 index edf8a4e5c..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/EditorViewsRepository.java +++ /dev/null @@ -1,210 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts; - -/** - * @author Goulwen LeFur - * - */ -public class EditorViewsRepository { - - public static final int SWT_KIND = 0; - - public static final int FORM_KIND = 1; - - - /** - * StandardFormPage view descriptor - * - */ - public static class StandardFormPage { - public static class Naming { - - - public static String name = "editor::StandardFormPage::Naming::name"; - - - public static String title_ = "editor::StandardFormPage::Naming::title"; - - - } - - } - - /** - * EEFMasterPage view descriptor - * - */ - public static class EEFMasterPage { - public static class Naming { - - - public static String name = "editor::EEFMasterPage::Naming::name"; - - - public static String title_ = "editor::EEFMasterPage::Naming::title"; - - - } - - public static class Settings { - - - public static String orientable = "editor::EEFMasterPage::Settings::orientable"; - - - public static String showValidatePage = "editor::EEFMasterPage::Settings::showValidatePage"; - - - } - - } - - /** - * TreeMasterPage view descriptor - * - */ - public static class TreeMasterPage { - public static class Naming { - - - public static String name = "editor::TreeMasterPage::Naming::name"; - - - public static String title_ = "editor::TreeMasterPage::Naming::title"; - - - } - - public static class Settings { - - - public static String toolbarVisible = "editor::TreeMasterPage::Settings::toolbarVisible"; - - - } - - } - - /** - * PartFilter view descriptor - * - */ - public static class PartFilter { - public static class Naming { - - - public static String name = "editor::PartFilter::Naming::name"; - - - } - - public static class Filter { - - - public static String contextualComponent = "editor::PartFilter::Filter::contextualComponent"; - - - public static String filteredPart = "editor::PartFilter::Filter::filteredPart"; - - - } - - public static class Settings { - - - public static String mandatory = "editor::PartFilter::Settings::mandatory"; - - - } - - } - - /** - * EEFEditorContributions view descriptor - * - */ - public static class EEFEditorContributions { - public static class Naming { - - - public static String name = "editor::EEFEditorContributions::Naming::name"; - - - } - - } - - /** - * EEFEditorPages view descriptor - * - */ - public static class EEFEditorPages { - public static class Properties { - - - public static String name = "editor::EEFEditorPages::properties::name"; - - - } - - } - - /** - * StaticEEFEditorContribution view descriptor - * - */ - public static class StaticEEFEditorContribution { - public static class Naming { - - - public static String name = "editor::StaticEEFEditorContribution::Naming::name"; - - - } - - public static class Binding { - - - public static String views = "editor::StaticEEFEditorContribution::Binding::views"; - - - } - - } - - /** - * DynamicEEFEditorContribution view descriptor - * - */ - public static class DynamicEEFEditorContribution { - public static class Naming { - - - public static String name = "editor::DynamicEEFEditorContribution::Naming::name"; - - - } - - public static class Binding { - - - public static String model = "editor::DynamicEEFEditorContribution::Binding::model"; - - - public static String views = "editor::DynamicEEFEditorContribution::Binding::views"; - - - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/FilterPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/FilterPropertiesEditionPart.java deleted file mode 100644 index 2dea85a01..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/FilterPropertiesEditionPart.java +++ /dev/null @@ -1,138 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * - * - */ -public interface FilterPropertiesEditionPart { - - /** - * @return the filteredPart - * - */ - public EObject getFilteredPart(); - - /** - * Init the filteredPart - * @param settings the combo setting - */ - public void initFilteredPart(EObjectFlatComboSettings settings); - - /** - * Defines a new filteredPart - * @param newValue the new filteredPart to set - * - */ - public void setFilteredPart(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setFilteredPartButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the filteredPart edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToFilteredPart(ViewerFilter filter); - - /** - * Adds the given filter to the filteredPart edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToFilteredPart(ViewerFilter filter); - - - /** - * @return the contextualComponent - * - */ - public EObject getContextualComponent(); - - /** - * Init the contextualComponent - * @param settings the combo setting - */ - public void initContextualComponent(EObjectFlatComboSettings settings); - - /** - * Defines a new contextualComponent - * @param newValue the new contextualComponent to set - * - */ - public void setContextualComponent(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setContextualComponentButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the contextualComponent edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToContextualComponent(ViewerFilter filter); - - /** - * Adds the given filter to the contextualComponent edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToContextualComponent(ViewerFilter filter); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/PartFilterPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/PartFilterPropertiesEditionPart.java deleted file mode 100644 index 6d9e48a93..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/PartFilterPropertiesEditionPart.java +++ /dev/null @@ -1,166 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public interface PartFilterPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the contextualComponent - * - */ - public EObject getContextualComponent(); - - /** - * Init the contextualComponent - * @param settings the combo setting - */ - public void initContextualComponent(EObjectFlatComboSettings settings); - - /** - * Defines a new contextualComponent - * @param newValue the new contextualComponent to set - * - */ - public void setContextualComponent(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setContextualComponentButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the contextualComponent edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToContextualComponent(ViewerFilter filter); - - /** - * Adds the given filter to the contextualComponent edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToContextualComponent(ViewerFilter filter); - - - /** - * @return the filteredPart - * - */ - public EObject getFilteredPart(); - - /** - * Init the filteredPart - * @param settings the combo setting - */ - public void initFilteredPart(EObjectFlatComboSettings settings); - - /** - * Defines a new filteredPart - * @param newValue the new filteredPart to set - * - */ - public void setFilteredPart(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setFilteredPartButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the filteredPart edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToFilteredPart(ViewerFilter filter); - - /** - * Adds the given filter to the filteredPart edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToFilteredPart(ViewerFilter filter); - - - /** - * @return the mandatory - * - */ - public Boolean getMandatory(); - - /** - * Defines a new mandatory - * @param newValue the new mandatory to set - * - */ - public void setMandatory(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/StandardFormPagePropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/StandardFormPagePropertiesEditionPart.java deleted file mode 100644 index c4fa0c694..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/StandardFormPagePropertiesEditionPart.java +++ /dev/null @@ -1,69 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts; - -// Start of user code for imports - - - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public interface StandardFormPagePropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the title - * - */ - public String getTitle_(); - - /** - * Defines a new title - * @param newValue the new title to set - * - */ - public void setTitle_(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/StaticEEFEditorContributionPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/StaticEEFEditorContributionPropertiesEditionPart.java deleted file mode 100644 index 0a56bf7be..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/StaticEEFEditorContributionPropertiesEditionPart.java +++ /dev/null @@ -1,99 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public interface StaticEEFEditorContributionPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - - - /** - * Init the views - * @param settings settings for the views ReferencesTable - */ - public void initViews(ReferencesTableSettings settings); - - /** - * Update the views - * @param newValue the views to update - * - */ - public void updateViews(); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViews(ViewerFilter filter); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the views table - * - */ - public boolean isContainedInViewsTable(EObject element); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/TreeMasterPagePropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/TreeMasterPagePropertiesEditionPart.java deleted file mode 100644 index 7b939806d..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/TreeMasterPagePropertiesEditionPart.java +++ /dev/null @@ -1,82 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts; - -// Start of user code for imports - - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public interface TreeMasterPagePropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the title - * - */ - public String getTitle_(); - - /** - * Defines a new title - * @param newValue the new title to set - * - */ - public void setTitle_(String newValue); - - - /** - * @return the toolbarVisible - * - */ - public Boolean getToolbarVisible(); - - /** - * Defines a new toolbarVisible - * @param newValue the new toolbarVisible to set - * - */ - public void setToolbarVisible(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/DynamicEEFEditorContributionPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/DynamicEEFEditorContributionPropertiesEditionPartForm.java deleted file mode 100644 index c061dc0f6..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/DynamicEEFEditorContributionPropertiesEditionPartForm.java +++ /dev/null @@ -1,591 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.forms; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class DynamicEEFEditorContributionPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, DynamicEEFEditorContributionPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * For {@link ISection} use only. - */ - public DynamicEEFEditorContributionPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public DynamicEEFEditorContributionPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence dynamicEEFEditorContributionStep = new BindingCompositionSequence(propertiesEditionComponent); - dynamicEEFEditorContributionStep - .addStep(EditorViewsRepository.DynamicEEFEditorContribution.Naming.class) - .addStep(EditorViewsRepository.DynamicEEFEditorContribution.Naming.name); - - CompositionStep bindingStep = dynamicEEFEditorContributionStep.addStep(EditorViewsRepository.DynamicEEFEditorContribution.Binding.class); - bindingStep.addStep(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model); - bindingStep.addStep(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views); - - - composer = new PartComposer(dynamicEEFEditorContributionStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Naming.class) { - return createNamingGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Naming.name) { - return createNameText(widgetFactory, parent); - } - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Binding.model) { - return createModelFlatComboViewer(parent, widgetFactory); - } - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Binding.views) { - return createViewsReferencesTable(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createNamingGroup(FormToolkit widgetFactory, final Composite parent) { - Section namingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - namingSection.setText(EditorMessages.DynamicEEFEditorContributionPropertiesEditionPart_NamingGroupLabel); - GridData namingSectionData = new GridData(GridData.FILL_HORIZONTAL); - namingSectionData.horizontalSpan = 3; - namingSection.setLayoutData(namingSectionData); - Composite namingGroup = widgetFactory.createComposite(namingSection); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - namingSection.setClient(namingGroup); - return namingGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.DynamicEEFEditorContribution.Naming.name, EditorMessages.DynamicEEFEditorContributionPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - DynamicEEFEditorContributionPropertiesEditionPartForm.this, - EditorViewsRepository.DynamicEEFEditorContribution.Naming.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - DynamicEEFEditorContributionPropertiesEditionPartForm.this, - EditorViewsRepository.DynamicEEFEditorContribution.Naming.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - DynamicEEFEditorContributionPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.DynamicEEFEditorContribution.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, EditorViewsRepository.DynamicEEFEditorContribution.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.DynamicEEFEditorContribution.Naming.name, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(EditorMessages.DynamicEEFEditorContributionPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createModelFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, EditorViewsRepository.DynamicEEFEditorContribution.Binding.model, EditorMessages.DynamicEEFEditorContributionPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model, EditorViewsRepository.FORM_KIND)); - widgetFactory.adapt(model); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.DynamicEEFEditorContribution.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - model.setID(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.views = new ReferencesTable(getDescription(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, EditorMessages.DynamicEEFEditorContributionPropertiesEditionPart_ViewsLabel), new ReferencesTableListener () { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, EditorViewsRepository.FORM_KIND)); - this.views.createControls(parent, widgetFactory); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - // Start of user code for createViewsReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - -// End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.DynamicEEFEditorContribution.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.DynamicEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(EditorMessages.DynamicEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(EditorMessages.DynamicEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(EditorMessages.DynamicEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.DynamicEEFEditorContribution_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFEditorContributionsPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFEditorContributionsPropertiesEditionPartForm.java deleted file mode 100644 index 6dcd01807..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFEditorContributionsPropertiesEditionPartForm.java +++ /dev/null @@ -1,266 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.extended.editor.parts.EEFEditorContributionsPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFEditorContributionsPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, EEFEditorContributionsPropertiesEditionPart { - - protected Text name; - - - - /** - * For {@link ISection} use only. - */ - public EEFEditorContributionsPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EEFEditorContributionsPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence eEFEditorContributionsStep = new BindingCompositionSequence(propertiesEditionComponent); - eEFEditorContributionsStep - .addStep(EditorViewsRepository.EEFEditorContributions.Naming.class) - .addStep(EditorViewsRepository.EEFEditorContributions.Naming.name); - - - composer = new PartComposer(eEFEditorContributionsStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.EEFEditorContributions.Naming.class) { - return createNamingGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.EEFEditorContributions.Naming.name) { - return createNameText(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createNamingGroup(FormToolkit widgetFactory, final Composite parent) { - Section namingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - namingSection.setText(EditorMessages.EEFEditorContributionsPropertiesEditionPart_NamingGroupLabel); - GridData namingSectionData = new GridData(GridData.FILL_HORIZONTAL); - namingSectionData.horizontalSpan = 3; - namingSection.setLayoutData(namingSectionData); - Composite namingGroup = widgetFactory.createComposite(namingSection); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - namingSection.setClient(namingGroup); - return namingGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.EEFEditorContributions.Naming.name, EditorMessages.EEFEditorContributionsPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EEFEditorContributionsPropertiesEditionPartForm.this, - EditorViewsRepository.EEFEditorContributions.Naming.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFEditorContributionsPropertiesEditionPartForm.this, - EditorViewsRepository.EEFEditorContributions.Naming.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFEditorContributionsPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFEditorContributionsPropertiesEditionPartForm.this, EditorViewsRepository.EEFEditorContributions.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, EditorViewsRepository.EEFEditorContributions.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFEditorContributions.Naming.name, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFEditorContributionsPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFEditorContributionsPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFEditorContributions.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.EEFEditorContributions_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.EEFEditorContributions_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFEditorPagesPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFEditorPagesPropertiesEditionPartForm.java deleted file mode 100644 index 1ff970398..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFEditorPagesPropertiesEditionPartForm.java +++ /dev/null @@ -1,266 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.extended.editor.parts.EEFEditorPagesPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFEditorPagesPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, EEFEditorPagesPropertiesEditionPart { - - protected Text name; - - - - /** - * For {@link ISection} use only. - */ - public EEFEditorPagesPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EEFEditorPagesPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence eEFEditorPagesStep = new BindingCompositionSequence(propertiesEditionComponent); - eEFEditorPagesStep - .addStep(EditorViewsRepository.EEFEditorPages.Properties.class) - .addStep(EditorViewsRepository.EEFEditorPages.Properties.name); - - - composer = new PartComposer(eEFEditorPagesStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.EEFEditorPages.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.EEFEditorPages.Properties.name) { - return createNameText(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(EditorMessages.EEFEditorPagesPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.EEFEditorPages.Properties.name, EditorMessages.EEFEditorPagesPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EEFEditorPagesPropertiesEditionPartForm.this, - EditorViewsRepository.EEFEditorPages.Properties.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFEditorPagesPropertiesEditionPartForm.this, - EditorViewsRepository.EEFEditorPages.Properties.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFEditorPagesPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFEditorPagesPropertiesEditionPartForm.this, EditorViewsRepository.EEFEditorPages.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, EditorViewsRepository.EEFEditorPages.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFEditorPages.Properties.name, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFEditorPagesPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFEditorPagesPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFEditorPages.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.EEFEditorPages_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.EEFEditorPages_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFMasterPagePropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFMasterPagePropertiesEditionPartForm.java deleted file mode 100644 index 49fd062c0..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/EEFMasterPagePropertiesEditionPartForm.java +++ /dev/null @@ -1,528 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFMasterPagePropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, EEFMasterPagePropertiesEditionPart { - - protected Text name; - protected Text title_; - protected Button orientable; - protected Button showValidatePage; - - - - /** - * For {@link ISection} use only. - */ - public EEFMasterPagePropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EEFMasterPagePropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence eEFMasterPageStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep namingStep = eEFMasterPageStep.addStep(EditorViewsRepository.EEFMasterPage.Naming.class); - namingStep.addStep(EditorViewsRepository.EEFMasterPage.Naming.name); - namingStep.addStep(EditorViewsRepository.EEFMasterPage.Naming.title_); - - CompositionStep settingsStep = eEFMasterPageStep.addStep(EditorViewsRepository.EEFMasterPage.Settings.class); - settingsStep.addStep(EditorViewsRepository.EEFMasterPage.Settings.orientable); - settingsStep.addStep(EditorViewsRepository.EEFMasterPage.Settings.showValidatePage); - - - composer = new PartComposer(eEFMasterPageStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.EEFMasterPage.Naming.class) { - return createNamingGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.EEFMasterPage.Naming.name) { - return createNameText(widgetFactory, parent); - } - if (key == EditorViewsRepository.EEFMasterPage.Naming.title_) { - return createTitle_Text(widgetFactory, parent); - } - if (key == EditorViewsRepository.EEFMasterPage.Settings.class) { - return createSettingsGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.EEFMasterPage.Settings.orientable) { - return createOrientableCheckbox(widgetFactory, parent); - } - if (key == EditorViewsRepository.EEFMasterPage.Settings.showValidatePage) { - return createShowValidatePageCheckbox(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createNamingGroup(FormToolkit widgetFactory, final Composite parent) { - Section namingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - namingSection.setText(EditorMessages.EEFMasterPagePropertiesEditionPart_NamingGroupLabel); - GridData namingSectionData = new GridData(GridData.FILL_HORIZONTAL); - namingSectionData.horizontalSpan = 3; - namingSection.setLayoutData(namingSectionData); - Composite namingGroup = widgetFactory.createComposite(namingSection); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - namingSection.setClient(namingGroup); - return namingGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.EEFMasterPage.Naming.name, EditorMessages.EEFMasterPagePropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EEFMasterPagePropertiesEditionPartForm.this, - EditorViewsRepository.EEFMasterPage.Naming.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFMasterPagePropertiesEditionPartForm.this, - EditorViewsRepository.EEFMasterPage.Naming.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFMasterPagePropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFMasterPagePropertiesEditionPartForm.this, EditorViewsRepository.EEFMasterPage.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, EditorViewsRepository.EEFMasterPage.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFMasterPage.Naming.name, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createTitle_Text(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.EEFMasterPage.Naming.title_, EditorMessages.EEFMasterPagePropertiesEditionPart_Title_Label); - title_ = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - title_.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData title_Data = new GridData(GridData.FILL_HORIZONTAL); - title_.setLayoutData(title_Data); - title_.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EEFMasterPagePropertiesEditionPartForm.this, - EditorViewsRepository.EEFMasterPage.Naming.title_, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFMasterPagePropertiesEditionPartForm.this, - EditorViewsRepository.EEFMasterPage.Naming.title_, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, title_.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFMasterPagePropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - title_.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFMasterPagePropertiesEditionPartForm.this, EditorViewsRepository.EEFMasterPage.Naming.title_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - } - } - }); - EditingUtils.setID(title_, EditorViewsRepository.EEFMasterPage.Naming.title_); - EditingUtils.setEEFtype(title_, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFMasterPage.Naming.title_, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createTitle_Text - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createSettingsGroup(FormToolkit widgetFactory, final Composite parent) { - Section settingsSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - settingsSection.setText(EditorMessages.EEFMasterPagePropertiesEditionPart_SettingsGroupLabel); - GridData settingsSectionData = new GridData(GridData.FILL_HORIZONTAL); - settingsSectionData.horizontalSpan = 3; - settingsSection.setLayoutData(settingsSectionData); - Composite settingsGroup = widgetFactory.createComposite(settingsSection); - GridLayout settingsGroupLayout = new GridLayout(); - settingsGroupLayout.numColumns = 3; - settingsGroup.setLayout(settingsGroupLayout); - settingsSection.setClient(settingsGroup); - return settingsGroup; - } - - - protected Composite createOrientableCheckbox(FormToolkit widgetFactory, Composite parent) { - orientable = widgetFactory.createButton(parent, getDescription(EditorViewsRepository.EEFMasterPage.Settings.orientable, EditorMessages.EEFMasterPagePropertiesEditionPart_OrientableLabel), SWT.CHECK); - orientable.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFMasterPagePropertiesEditionPartForm.this, EditorViewsRepository.EEFMasterPage.Settings.orientable, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(orientable.getSelection()))); - } - - }); - GridData orientableData = new GridData(GridData.FILL_HORIZONTAL); - orientableData.horizontalSpan = 2; - orientable.setLayoutData(orientableData); - EditingUtils.setID(orientable, EditorViewsRepository.EEFMasterPage.Settings.orientable); - EditingUtils.setEEFtype(orientable, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFMasterPage.Settings.orientable, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createOrientableCheckbox - - // End of user code - return parent; - } - - - protected Composite createShowValidatePageCheckbox(FormToolkit widgetFactory, Composite parent) { - showValidatePage = widgetFactory.createButton(parent, getDescription(EditorViewsRepository.EEFMasterPage.Settings.showValidatePage, EditorMessages.EEFMasterPagePropertiesEditionPart_ShowValidatePageLabel), SWT.CHECK); - showValidatePage.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFMasterPagePropertiesEditionPartForm.this, EditorViewsRepository.EEFMasterPage.Settings.showValidatePage, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(showValidatePage.getSelection()))); - } - - }); - GridData showValidatePageData = new GridData(GridData.FILL_HORIZONTAL); - showValidatePageData.horizontalSpan = 2; - showValidatePage.setLayoutData(showValidatePageData); - EditingUtils.setID(showValidatePage, EditorViewsRepository.EEFMasterPage.Settings.showValidatePage); - EditingUtils.setEEFtype(showValidatePage, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFMasterPage.Settings.showValidatePage, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createShowValidatePageCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFMasterPage.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.EEFMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#getTitle_() - * - */ - public String getTitle_() { - return title_.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#setTitle_(String newValue) - * - */ - public void setTitle_(String newValue) { - if (newValue != null) { - title_.setText(newValue); - } else { - title_.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFMasterPage.Naming.title_); - if (eefElementEditorReadOnlyState && title_.isEnabled()) { - title_.setEnabled(false); - title_.setToolTipText(EditorMessages.EEFMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !title_.isEnabled()) { - title_.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#getOrientable() - * - */ - public Boolean getOrientable() { - return Boolean.valueOf(orientable.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#setOrientable(Boolean newValue) - * - */ - public void setOrientable(Boolean newValue) { - if (newValue != null) { - orientable.setSelection(newValue.booleanValue()); - } else { - orientable.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFMasterPage.Settings.orientable); - if (eefElementEditorReadOnlyState && orientable.isEnabled()) { - orientable.setEnabled(false); - orientable.setToolTipText(EditorMessages.EEFMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !orientable.isEnabled()) { - orientable.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#getShowValidatePage() - * - */ - public Boolean getShowValidatePage() { - return Boolean.valueOf(showValidatePage.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#setShowValidatePage(Boolean newValue) - * - */ - public void setShowValidatePage(Boolean newValue) { - if (newValue != null) { - showValidatePage.setSelection(newValue.booleanValue()); - } else { - showValidatePage.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFMasterPage.Settings.showValidatePage); - if (eefElementEditorReadOnlyState && showValidatePage.isEnabled()) { - showValidatePage.setEnabled(false); - showValidatePage.setToolTipText(EditorMessages.EEFMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !showValidatePage.isEnabled()) { - showValidatePage.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.EEFMasterPage_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/PartFilterPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/PartFilterPropertiesEditionPartForm.java deleted file mode 100644 index 6879ab0f5..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/PartFilterPropertiesEditionPartForm.java +++ /dev/null @@ -1,638 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class PartFilterPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, PartFilterPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer contextualComponent; - protected EObjectFlatComboViewer filteredPart; - protected Button mandatory; - - - - /** - * For {@link ISection} use only. - */ - public PartFilterPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public PartFilterPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence partFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - partFilterStep - .addStep(EditorViewsRepository.PartFilter.Naming.class) - .addStep(EditorViewsRepository.PartFilter.Naming.name); - - CompositionStep filterStep = partFilterStep.addStep(EditorViewsRepository.PartFilter.Filter.class); - filterStep.addStep(EditorViewsRepository.PartFilter.Filter.contextualComponent); - filterStep.addStep(EditorViewsRepository.PartFilter.Filter.filteredPart); - - partFilterStep - .addStep(EditorViewsRepository.PartFilter.Settings.class) - .addStep(EditorViewsRepository.PartFilter.Settings.mandatory); - - - composer = new PartComposer(partFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.PartFilter.Naming.class) { - return createNamingGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.PartFilter.Naming.name) { - return createNameText(widgetFactory, parent); - } - if (key == EditorViewsRepository.PartFilter.Filter.class) { - return createFilterGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.PartFilter.Filter.contextualComponent) { - return createContextualComponentFlatComboViewer(parent, widgetFactory); - } - if (key == EditorViewsRepository.PartFilter.Filter.filteredPart) { - return createFilteredPartFlatComboViewer(parent, widgetFactory); - } - if (key == EditorViewsRepository.PartFilter.Settings.class) { - return createSettingsGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.PartFilter.Settings.mandatory) { - return createMandatoryCheckbox(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createNamingGroup(FormToolkit widgetFactory, final Composite parent) { - Section namingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - namingSection.setText(EditorMessages.PartFilterPropertiesEditionPart_NamingGroupLabel); - GridData namingSectionData = new GridData(GridData.FILL_HORIZONTAL); - namingSectionData.horizontalSpan = 3; - namingSection.setLayoutData(namingSectionData); - Composite namingGroup = widgetFactory.createComposite(namingSection); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - namingSection.setClient(namingGroup); - return namingGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.PartFilter.Naming.name, EditorMessages.PartFilterPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - PartFilterPropertiesEditionPartForm.this, - EditorViewsRepository.PartFilter.Naming.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PartFilterPropertiesEditionPartForm.this, - EditorViewsRepository.PartFilter.Naming.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - PartFilterPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PartFilterPropertiesEditionPartForm.this, EditorViewsRepository.PartFilter.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, EditorViewsRepository.PartFilter.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.PartFilter.Naming.name, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createFilterGroup(FormToolkit widgetFactory, final Composite parent) { - Section filterSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - filterSection.setText(EditorMessages.PartFilterPropertiesEditionPart_FilterGroupLabel); - GridData filterSectionData = new GridData(GridData.FILL_HORIZONTAL); - filterSectionData.horizontalSpan = 3; - filterSection.setLayoutData(filterSectionData); - Composite filterGroup = widgetFactory.createComposite(filterSection); - GridLayout filterGroupLayout = new GridLayout(); - filterGroupLayout.numColumns = 3; - filterGroup.setLayout(filterGroupLayout); - filterSection.setClient(filterGroup); - return filterGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createContextualComponentFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, EditorViewsRepository.PartFilter.Filter.contextualComponent, EditorMessages.PartFilterPropertiesEditionPart_ContextualComponentLabel); - contextualComponent = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EditorViewsRepository.PartFilter.Filter.contextualComponent, EditorViewsRepository.FORM_KIND)); - widgetFactory.adapt(contextualComponent); - contextualComponent.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData contextualComponentData = new GridData(GridData.FILL_HORIZONTAL); - contextualComponent.setLayoutData(contextualComponentData); - contextualComponent.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PartFilterPropertiesEditionPartForm.this, EditorViewsRepository.PartFilter.Filter.contextualComponent, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getContextualComponent())); - } - - }); - contextualComponent.setID(EditorViewsRepository.PartFilter.Filter.contextualComponent); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.PartFilter.Filter.contextualComponent, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createContextualComponentFlatComboViewer - - // End of user code - return parent; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createFilteredPartFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, EditorViewsRepository.PartFilter.Filter.filteredPart, EditorMessages.PartFilterPropertiesEditionPart_FilteredPartLabel); - filteredPart = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EditorViewsRepository.PartFilter.Filter.filteredPart, EditorViewsRepository.FORM_KIND)); - widgetFactory.adapt(filteredPart); - filteredPart.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData filteredPartData = new GridData(GridData.FILL_HORIZONTAL); - filteredPart.setLayoutData(filteredPartData); - filteredPart.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PartFilterPropertiesEditionPartForm.this, EditorViewsRepository.PartFilter.Filter.filteredPart, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getFilteredPart())); - } - - }); - filteredPart.setID(EditorViewsRepository.PartFilter.Filter.filteredPart); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.PartFilter.Filter.filteredPart, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createFilteredPartFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createSettingsGroup(FormToolkit widgetFactory, final Composite parent) { - Section settingsSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - settingsSection.setText(EditorMessages.PartFilterPropertiesEditionPart_SettingsGroupLabel); - GridData settingsSectionData = new GridData(GridData.FILL_HORIZONTAL); - settingsSectionData.horizontalSpan = 3; - settingsSection.setLayoutData(settingsSectionData); - Composite settingsGroup = widgetFactory.createComposite(settingsSection); - GridLayout settingsGroupLayout = new GridLayout(); - settingsGroupLayout.numColumns = 3; - settingsGroup.setLayout(settingsGroupLayout); - settingsSection.setClient(settingsGroup); - return settingsGroup; - } - - - protected Composite createMandatoryCheckbox(FormToolkit widgetFactory, Composite parent) { - mandatory = widgetFactory.createButton(parent, getDescription(EditorViewsRepository.PartFilter.Settings.mandatory, EditorMessages.PartFilterPropertiesEditionPart_MandatoryLabel), SWT.CHECK); - mandatory.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PartFilterPropertiesEditionPartForm.this, EditorViewsRepository.PartFilter.Settings.mandatory, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(mandatory.getSelection()))); - } - - }); - GridData mandatoryData = new GridData(GridData.FILL_HORIZONTAL); - mandatoryData.horizontalSpan = 2; - mandatory.setLayoutData(mandatoryData); - EditingUtils.setID(mandatory, EditorViewsRepository.PartFilter.Settings.mandatory); - EditingUtils.setEEFtype(mandatory, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.PartFilter.Settings.mandatory, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createMandatoryCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#getContextualComponent() - * - */ - public EObject getContextualComponent() { - if (contextualComponent.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) contextualComponent.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#initContextualComponent(EObjectFlatComboSettings) - */ - public void initContextualComponent(EObjectFlatComboSettings settings) { - contextualComponent.setInput(settings); - if (current != null) { - contextualComponent.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Filter.contextualComponent); - if (eefElementEditorReadOnlyState && contextualComponent.isEnabled()) { - contextualComponent.setEnabled(false); - contextualComponent.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !contextualComponent.isEnabled()) { - contextualComponent.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setContextualComponent(EObject newValue) - * - */ - public void setContextualComponent(EObject newValue) { - if (newValue != null) { - contextualComponent.setSelection(new StructuredSelection(newValue)); - } else { - contextualComponent.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Filter.contextualComponent); - if (eefElementEditorReadOnlyState && contextualComponent.isEnabled()) { - contextualComponent.setEnabled(false); - contextualComponent.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !contextualComponent.isEnabled()) { - contextualComponent.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setContextualComponentButtonMode(ButtonsModeEnum newValue) - */ - public void setContextualComponentButtonMode(ButtonsModeEnum newValue) { - contextualComponent.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#addFilterContextualComponent(ViewerFilter filter) - * - */ - public void addFilterToContextualComponent(ViewerFilter filter) { - contextualComponent.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#addBusinessFilterContextualComponent(ViewerFilter filter) - * - */ - public void addBusinessFilterToContextualComponent(ViewerFilter filter) { - contextualComponent.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#getFilteredPart() - * - */ - public EObject getFilteredPart() { - if (filteredPart.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) filteredPart.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#initFilteredPart(EObjectFlatComboSettings) - */ - public void initFilteredPart(EObjectFlatComboSettings settings) { - filteredPart.setInput(settings); - if (current != null) { - filteredPart.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Filter.filteredPart); - if (eefElementEditorReadOnlyState && filteredPart.isEnabled()) { - filteredPart.setEnabled(false); - filteredPart.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !filteredPart.isEnabled()) { - filteredPart.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setFilteredPart(EObject newValue) - * - */ - public void setFilteredPart(EObject newValue) { - if (newValue != null) { - filteredPart.setSelection(new StructuredSelection(newValue)); - } else { - filteredPart.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Filter.filteredPart); - if (eefElementEditorReadOnlyState && filteredPart.isEnabled()) { - filteredPart.setEnabled(false); - filteredPart.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !filteredPart.isEnabled()) { - filteredPart.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setFilteredPartButtonMode(ButtonsModeEnum newValue) - */ - public void setFilteredPartButtonMode(ButtonsModeEnum newValue) { - filteredPart.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#addFilterFilteredPart(ViewerFilter filter) - * - */ - public void addFilterToFilteredPart(ViewerFilter filter) { - filteredPart.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#addBusinessFilterFilteredPart(ViewerFilter filter) - * - */ - public void addBusinessFilterToFilteredPart(ViewerFilter filter) { - filteredPart.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return Boolean.valueOf(mandatory.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - if (newValue != null) { - mandatory.setSelection(newValue.booleanValue()); - } else { - mandatory.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Settings.mandatory); - if (eefElementEditorReadOnlyState && mandatory.isEnabled()) { - mandatory.setEnabled(false); - mandatory.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !mandatory.isEnabled()) { - mandatory.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.PartFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/StandardFormPagePropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/StandardFormPagePropertiesEditionPartForm.java deleted file mode 100644 index 701c21f12..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/StandardFormPagePropertiesEditionPartForm.java +++ /dev/null @@ -1,371 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class StandardFormPagePropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, StandardFormPagePropertiesEditionPart { - - protected Text name; - protected Text title_; - - - - /** - * For {@link ISection} use only. - */ - public StandardFormPagePropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public StandardFormPagePropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence standardFormPageStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep namingStep = standardFormPageStep.addStep(EditorViewsRepository.StandardFormPage.Naming.class); - namingStep.addStep(EditorViewsRepository.StandardFormPage.Naming.name); - namingStep.addStep(EditorViewsRepository.StandardFormPage.Naming.title_); - - - composer = new PartComposer(standardFormPageStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.StandardFormPage.Naming.class) { - return createNamingGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.StandardFormPage.Naming.name) { - return createNameText(widgetFactory, parent); - } - if (key == EditorViewsRepository.StandardFormPage.Naming.title_) { - return createTitle_Text(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createNamingGroup(FormToolkit widgetFactory, final Composite parent) { - Section namingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - namingSection.setText(EditorMessages.StandardFormPagePropertiesEditionPart_NamingGroupLabel); - GridData namingSectionData = new GridData(GridData.FILL_HORIZONTAL); - namingSectionData.horizontalSpan = 3; - namingSection.setLayoutData(namingSectionData); - Composite namingGroup = widgetFactory.createComposite(namingSection); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - namingSection.setClient(namingGroup); - return namingGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.StandardFormPage.Naming.name, EditorMessages.StandardFormPagePropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - StandardFormPagePropertiesEditionPartForm.this, - EditorViewsRepository.StandardFormPage.Naming.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - StandardFormPagePropertiesEditionPartForm.this, - EditorViewsRepository.StandardFormPage.Naming.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - StandardFormPagePropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardFormPagePropertiesEditionPartForm.this, EditorViewsRepository.StandardFormPage.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, EditorViewsRepository.StandardFormPage.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.StandardFormPage.Naming.name, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createTitle_Text(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.StandardFormPage.Naming.title_, EditorMessages.StandardFormPagePropertiesEditionPart_Title_Label); - title_ = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - title_.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData title_Data = new GridData(GridData.FILL_HORIZONTAL); - title_.setLayoutData(title_Data); - title_.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - StandardFormPagePropertiesEditionPartForm.this, - EditorViewsRepository.StandardFormPage.Naming.title_, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - StandardFormPagePropertiesEditionPartForm.this, - EditorViewsRepository.StandardFormPage.Naming.title_, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, title_.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - StandardFormPagePropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - title_.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardFormPagePropertiesEditionPartForm.this, EditorViewsRepository.StandardFormPage.Naming.title_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - } - } - }); - EditingUtils.setID(title_, EditorViewsRepository.StandardFormPage.Naming.title_); - EditingUtils.setEEFtype(title_, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.StandardFormPage.Naming.title_, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createTitle_Text - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.StandardFormPage.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.StandardFormPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart#getTitle_() - * - */ - public String getTitle_() { - return title_.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart#setTitle_(String newValue) - * - */ - public void setTitle_(String newValue) { - if (newValue != null) { - title_.setText(newValue); - } else { - title_.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.StandardFormPage.Naming.title_); - if (eefElementEditorReadOnlyState && title_.isEnabled()) { - title_.setEnabled(false); - title_.setToolTipText(EditorMessages.StandardFormPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !title_.isEnabled()) { - title_.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.StandardFormPage_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/StaticEEFEditorContributionPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/StaticEEFEditorContributionPropertiesEditionPartForm.java deleted file mode 100644 index bf7078954..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/StaticEEFEditorContributionPropertiesEditionPartForm.java +++ /dev/null @@ -1,460 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.forms; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class StaticEEFEditorContributionPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, StaticEEFEditorContributionPropertiesEditionPart { - - protected Text name; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * For {@link ISection} use only. - */ - public StaticEEFEditorContributionPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public StaticEEFEditorContributionPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence staticEEFEditorContributionStep = new BindingCompositionSequence(propertiesEditionComponent); - staticEEFEditorContributionStep - .addStep(EditorViewsRepository.StaticEEFEditorContribution.Naming.class) - .addStep(EditorViewsRepository.StaticEEFEditorContribution.Naming.name); - - staticEEFEditorContributionStep - .addStep(EditorViewsRepository.StaticEEFEditorContribution.Binding.class) - .addStep(EditorViewsRepository.StaticEEFEditorContribution.Binding.views); - - - composer = new PartComposer(staticEEFEditorContributionStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.StaticEEFEditorContribution.Naming.class) { - return createNamingGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.StaticEEFEditorContribution.Naming.name) { - return createNameText(widgetFactory, parent); - } - if (key == EditorViewsRepository.StaticEEFEditorContribution.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.StaticEEFEditorContribution.Binding.views) { - return createViewsReferencesTable(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createNamingGroup(FormToolkit widgetFactory, final Composite parent) { - Section namingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - namingSection.setText(EditorMessages.StaticEEFEditorContributionPropertiesEditionPart_NamingGroupLabel); - GridData namingSectionData = new GridData(GridData.FILL_HORIZONTAL); - namingSectionData.horizontalSpan = 3; - namingSection.setLayoutData(namingSectionData); - Composite namingGroup = widgetFactory.createComposite(namingSection); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - namingSection.setClient(namingGroup); - return namingGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.StaticEEFEditorContribution.Naming.name, EditorMessages.StaticEEFEditorContributionPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - StaticEEFEditorContributionPropertiesEditionPartForm.this, - EditorViewsRepository.StaticEEFEditorContribution.Naming.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - StaticEEFEditorContributionPropertiesEditionPartForm.this, - EditorViewsRepository.StaticEEFEditorContribution.Naming.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - StaticEEFEditorContributionPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.StaticEEFEditorContribution.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, EditorViewsRepository.StaticEEFEditorContribution.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.StaticEEFEditorContribution.Naming.name, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(EditorMessages.StaticEEFEditorContributionPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * - */ - protected Composite createViewsReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.views = new ReferencesTable(getDescription(EditorViewsRepository.StaticEEFEditorContribution.Binding.views, EditorMessages.StaticEEFEditorContributionPropertiesEditionPart_ViewsLabel), new ReferencesTableListener () { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(EditorViewsRepository.StaticEEFEditorContribution.Binding.views, EditorViewsRepository.FORM_KIND)); - this.views.createControls(parent, widgetFactory); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.StaticEEFEditorContribution.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(EditorViewsRepository.StaticEEFEditorContribution.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - // Start of user code for createViewsReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.StaticEEFEditorContribution.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.StaticEEFEditorContribution.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartForm.this, EditorViewsRepository.StaticEEFEditorContribution.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.StaticEEFEditorContribution.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.StaticEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.StaticEEFEditorContribution.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(EditorMessages.StaticEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.StaticEEFEditorContribution_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/TreeMasterPagePropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/TreeMasterPagePropertiesEditionPartForm.java deleted file mode 100644 index f49e72436..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/forms/TreeMasterPagePropertiesEditionPartForm.java +++ /dev/null @@ -1,463 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class TreeMasterPagePropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, TreeMasterPagePropertiesEditionPart { - - protected Text name; - protected Text title_; - protected Button toolbarVisible; - - - - /** - * For {@link ISection} use only. - */ - public TreeMasterPagePropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public TreeMasterPagePropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence treeMasterPageStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep namingStep = treeMasterPageStep.addStep(EditorViewsRepository.TreeMasterPage.Naming.class); - namingStep.addStep(EditorViewsRepository.TreeMasterPage.Naming.name); - namingStep.addStep(EditorViewsRepository.TreeMasterPage.Naming.title_); - - treeMasterPageStep - .addStep(EditorViewsRepository.TreeMasterPage.Settings.class) - .addStep(EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible); - - - composer = new PartComposer(treeMasterPageStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.TreeMasterPage.Naming.class) { - return createNamingGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.TreeMasterPage.Naming.name) { - return createNameText(widgetFactory, parent); - } - if (key == EditorViewsRepository.TreeMasterPage.Naming.title_) { - return createTitle_Text(widgetFactory, parent); - } - if (key == EditorViewsRepository.TreeMasterPage.Settings.class) { - return createSettingsGroup(widgetFactory, parent); - } - if (key == EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible) { - return createToolbarVisibleCheckbox(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createNamingGroup(FormToolkit widgetFactory, final Composite parent) { - Section namingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - namingSection.setText(EditorMessages.TreeMasterPagePropertiesEditionPart_NamingGroupLabel); - GridData namingSectionData = new GridData(GridData.FILL_HORIZONTAL); - namingSectionData.horizontalSpan = 3; - namingSection.setLayoutData(namingSectionData); - Composite namingGroup = widgetFactory.createComposite(namingSection); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - namingSection.setClient(namingGroup); - return namingGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.TreeMasterPage.Naming.name, EditorMessages.TreeMasterPagePropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - TreeMasterPagePropertiesEditionPartForm.this, - EditorViewsRepository.TreeMasterPage.Naming.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - TreeMasterPagePropertiesEditionPartForm.this, - EditorViewsRepository.TreeMasterPage.Naming.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - TreeMasterPagePropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(TreeMasterPagePropertiesEditionPartForm.this, EditorViewsRepository.TreeMasterPage.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, EditorViewsRepository.TreeMasterPage.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.TreeMasterPage.Naming.name, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createTitle_Text(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EditorViewsRepository.TreeMasterPage.Naming.title_, EditorMessages.TreeMasterPagePropertiesEditionPart_Title_Label); - title_ = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - title_.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData title_Data = new GridData(GridData.FILL_HORIZONTAL); - title_.setLayoutData(title_Data); - title_.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - TreeMasterPagePropertiesEditionPartForm.this, - EditorViewsRepository.TreeMasterPage.Naming.title_, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - TreeMasterPagePropertiesEditionPartForm.this, - EditorViewsRepository.TreeMasterPage.Naming.title_, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, title_.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - TreeMasterPagePropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - title_.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(TreeMasterPagePropertiesEditionPartForm.this, EditorViewsRepository.TreeMasterPage.Naming.title_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - } - } - }); - EditingUtils.setID(title_, EditorViewsRepository.TreeMasterPage.Naming.title_); - EditingUtils.setEEFtype(title_, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.TreeMasterPage.Naming.title_, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createTitle_Text - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createSettingsGroup(FormToolkit widgetFactory, final Composite parent) { - Section settingsSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - settingsSection.setText(EditorMessages.TreeMasterPagePropertiesEditionPart_SettingsGroupLabel); - GridData settingsSectionData = new GridData(GridData.FILL_HORIZONTAL); - settingsSectionData.horizontalSpan = 3; - settingsSection.setLayoutData(settingsSectionData); - Composite settingsGroup = widgetFactory.createComposite(settingsSection); - GridLayout settingsGroupLayout = new GridLayout(); - settingsGroupLayout.numColumns = 3; - settingsGroup.setLayout(settingsGroupLayout); - settingsSection.setClient(settingsGroup); - return settingsGroup; - } - - - protected Composite createToolbarVisibleCheckbox(FormToolkit widgetFactory, Composite parent) { - toolbarVisible = widgetFactory.createButton(parent, getDescription(EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible, EditorMessages.TreeMasterPagePropertiesEditionPart_ToolbarVisibleLabel), SWT.CHECK); - toolbarVisible.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(TreeMasterPagePropertiesEditionPartForm.this, EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(toolbarVisible.getSelection()))); - } - - }); - GridData toolbarVisibleData = new GridData(GridData.FILL_HORIZONTAL); - toolbarVisibleData.horizontalSpan = 2; - toolbarVisible.setLayoutData(toolbarVisibleData); - EditingUtils.setID(toolbarVisible, EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible); - EditingUtils.setEEFtype(toolbarVisible, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible, EditorViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createToolbarVisibleCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.TreeMasterPage.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.TreeMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#getTitle_() - * - */ - public String getTitle_() { - return title_.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#setTitle_(String newValue) - * - */ - public void setTitle_(String newValue) { - if (newValue != null) { - title_.setText(newValue); - } else { - title_.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.TreeMasterPage.Naming.title_); - if (eefElementEditorReadOnlyState && title_.isEnabled()) { - title_.setEnabled(false); - title_.setToolTipText(EditorMessages.TreeMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !title_.isEnabled()) { - title_.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#getToolbarVisible() - * - */ - public Boolean getToolbarVisible() { - return Boolean.valueOf(toolbarVisible.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#setToolbarVisible(Boolean newValue) - * - */ - public void setToolbarVisible(Boolean newValue) { - if (newValue != null) { - toolbarVisible.setSelection(newValue.booleanValue()); - } else { - toolbarVisible.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible); - if (eefElementEditorReadOnlyState && toolbarVisible.isEnabled()) { - toolbarVisible.setEnabled(false); - toolbarVisible.setToolTipText(EditorMessages.TreeMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !toolbarVisible.isEnabled()) { - toolbarVisible.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.TreeMasterPage_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/DynamicEEFEditorContributionPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/DynamicEEFEditorContributionPropertiesEditionPartImpl.java deleted file mode 100644 index 1cf52f3ad..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/DynamicEEFEditorContributionPropertiesEditionPartImpl.java +++ /dev/null @@ -1,549 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.impl; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class DynamicEEFEditorContributionPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, DynamicEEFEditorContributionPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public DynamicEEFEditorContributionPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence dynamicEEFEditorContributionStep = new BindingCompositionSequence(propertiesEditionComponent); - dynamicEEFEditorContributionStep - .addStep(EditorViewsRepository.DynamicEEFEditorContribution.Naming.class) - .addStep(EditorViewsRepository.DynamicEEFEditorContribution.Naming.name); - - CompositionStep bindingStep = dynamicEEFEditorContributionStep.addStep(EditorViewsRepository.DynamicEEFEditorContribution.Binding.class); - bindingStep.addStep(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model); - bindingStep.addStep(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views); - - - composer = new PartComposer(dynamicEEFEditorContributionStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Naming.class) { - return createNamingGroup(parent); - } - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Naming.name) { - return createNameText(parent); - } - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Binding.class) { - return createBindingGroup(parent); - } - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Binding.model) { - return createModelFlatComboViewer(parent); - } - if (key == EditorViewsRepository.DynamicEEFEditorContribution.Binding.views) { - return createViewsAdvancedReferencesTable(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createNamingGroup(Composite parent) { - Group namingGroup = new Group(parent, SWT.NONE); - namingGroup.setText(EditorMessages.DynamicEEFEditorContributionPropertiesEditionPart_NamingGroupLabel); - GridData namingGroupData = new GridData(GridData.FILL_HORIZONTAL); - namingGroupData.horizontalSpan = 3; - namingGroup.setLayoutData(namingGroupData); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - return namingGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, EditorViewsRepository.DynamicEEFEditorContribution.Naming.name, EditorMessages.DynamicEEFEditorContributionPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.DynamicEEFEditorContribution.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.DynamicEEFEditorContribution.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, EditorViewsRepository.DynamicEEFEditorContribution.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.DynamicEEFEditorContribution.Naming.name, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(EditorMessages.DynamicEEFEditorContributionPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createModelFlatComboViewer(Composite parent) { - createDescription(parent, EditorViewsRepository.DynamicEEFEditorContribution.Binding.model, EditorMessages.DynamicEEFEditorContributionPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model, EditorViewsRepository.SWT_KIND)); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - model.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.DynamicEEFEditorContribution.Binding.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.setID(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsAdvancedReferencesTable(Composite parent) { - String label = getDescription(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, EditorMessages.DynamicEEFEditorContributionPropertiesEditionPart_ViewsLabel); - this.views = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, EditorViewsRepository.SWT_KIND)); - this.views.createControls(parent); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DynamicEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.DynamicEEFEditorContribution.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.DynamicEEFEditorContribution.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.DynamicEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(EditorMessages.DynamicEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.DynamicEEFEditorContribution.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(EditorMessages.DynamicEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.DynamicEEFEditorContribution.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(EditorMessages.DynamicEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.DynamicEEFEditorContributionPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.DynamicEEFEditorContribution_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFEditorContributionsPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFEditorContributionsPropertiesEditionPartImpl.java deleted file mode 100644 index 331b71aec..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFEditorContributionsPropertiesEditionPartImpl.java +++ /dev/null @@ -1,235 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.extended.editor.parts.EEFEditorContributionsPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFEditorContributionsPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, EEFEditorContributionsPropertiesEditionPart { - - protected Text name; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EEFEditorContributionsPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence eEFEditorContributionsStep = new BindingCompositionSequence(propertiesEditionComponent); - eEFEditorContributionsStep - .addStep(EditorViewsRepository.EEFEditorContributions.Naming.class) - .addStep(EditorViewsRepository.EEFEditorContributions.Naming.name); - - - composer = new PartComposer(eEFEditorContributionsStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.EEFEditorContributions.Naming.class) { - return createNamingGroup(parent); - } - if (key == EditorViewsRepository.EEFEditorContributions.Naming.name) { - return createNameText(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createNamingGroup(Composite parent) { - Group namingGroup = new Group(parent, SWT.NONE); - namingGroup.setText(EditorMessages.EEFEditorContributionsPropertiesEditionPart_NamingGroupLabel); - GridData namingGroupData = new GridData(GridData.FILL_HORIZONTAL); - namingGroupData.horizontalSpan = 3; - namingGroup.setLayoutData(namingGroupData); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - return namingGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, EditorViewsRepository.EEFEditorContributions.Naming.name, EditorMessages.EEFEditorContributionsPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFEditorContributionsPropertiesEditionPartImpl.this, EditorViewsRepository.EEFEditorContributions.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFEditorContributionsPropertiesEditionPartImpl.this, EditorViewsRepository.EEFEditorContributions.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, EditorViewsRepository.EEFEditorContributions.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFEditorContributions.Naming.name, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFEditorContributionsPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFEditorContributionsPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFEditorContributions.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.EEFEditorContributions_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.EEFEditorContributions_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFEditorPagesPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFEditorPagesPropertiesEditionPartImpl.java deleted file mode 100644 index 25802426f..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFEditorPagesPropertiesEditionPartImpl.java +++ /dev/null @@ -1,235 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.extended.editor.parts.EEFEditorPagesPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFEditorPagesPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, EEFEditorPagesPropertiesEditionPart { - - protected Text name; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EEFEditorPagesPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence eEFEditorPagesStep = new BindingCompositionSequence(propertiesEditionComponent); - eEFEditorPagesStep - .addStep(EditorViewsRepository.EEFEditorPages.Properties.class) - .addStep(EditorViewsRepository.EEFEditorPages.Properties.name); - - - composer = new PartComposer(eEFEditorPagesStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.EEFEditorPages.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == EditorViewsRepository.EEFEditorPages.Properties.name) { - return createNameText(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(EditorMessages.EEFEditorPagesPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, EditorViewsRepository.EEFEditorPages.Properties.name, EditorMessages.EEFEditorPagesPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFEditorPagesPropertiesEditionPartImpl.this, EditorViewsRepository.EEFEditorPages.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFEditorPagesPropertiesEditionPartImpl.this, EditorViewsRepository.EEFEditorPages.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, EditorViewsRepository.EEFEditorPages.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFEditorPages.Properties.name, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFEditorPagesPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFEditorPagesPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFEditorPages.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.EEFEditorPages_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.EEFEditorPages_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFMasterPagePropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFMasterPagePropertiesEditionPartImpl.java deleted file mode 100644 index 9968e4528..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/EEFMasterPagePropertiesEditionPartImpl.java +++ /dev/null @@ -1,478 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class EEFMasterPagePropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, EEFMasterPagePropertiesEditionPart { - - protected Text name; - protected Text title_; - protected Button orientable; - protected Button showValidatePage; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EEFMasterPagePropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence eEFMasterPageStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep namingStep = eEFMasterPageStep.addStep(EditorViewsRepository.EEFMasterPage.Naming.class); - namingStep.addStep(EditorViewsRepository.EEFMasterPage.Naming.name); - namingStep.addStep(EditorViewsRepository.EEFMasterPage.Naming.title_); - - CompositionStep settingsStep = eEFMasterPageStep.addStep(EditorViewsRepository.EEFMasterPage.Settings.class); - settingsStep.addStep(EditorViewsRepository.EEFMasterPage.Settings.orientable); - settingsStep.addStep(EditorViewsRepository.EEFMasterPage.Settings.showValidatePage); - - - composer = new PartComposer(eEFMasterPageStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.EEFMasterPage.Naming.class) { - return createNamingGroup(parent); - } - if (key == EditorViewsRepository.EEFMasterPage.Naming.name) { - return createNameText(parent); - } - if (key == EditorViewsRepository.EEFMasterPage.Naming.title_) { - return createTitle_Text(parent); - } - if (key == EditorViewsRepository.EEFMasterPage.Settings.class) { - return createSettingsGroup(parent); - } - if (key == EditorViewsRepository.EEFMasterPage.Settings.orientable) { - return createOrientableCheckbox(parent); - } - if (key == EditorViewsRepository.EEFMasterPage.Settings.showValidatePage) { - return createShowValidatePageCheckbox(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createNamingGroup(Composite parent) { - Group namingGroup = new Group(parent, SWT.NONE); - namingGroup.setText(EditorMessages.EEFMasterPagePropertiesEditionPart_NamingGroupLabel); - GridData namingGroupData = new GridData(GridData.FILL_HORIZONTAL); - namingGroupData.horizontalSpan = 3; - namingGroup.setLayoutData(namingGroupData); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - return namingGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, EditorViewsRepository.EEFMasterPage.Naming.name, EditorMessages.EEFMasterPagePropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.EEFMasterPage.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.EEFMasterPage.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, EditorViewsRepository.EEFMasterPage.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFMasterPage.Naming.name, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createTitle_Text(Composite parent) { - createDescription(parent, EditorViewsRepository.EEFMasterPage.Naming.title_, EditorMessages.EEFMasterPagePropertiesEditionPart_Title_Label); - title_ = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData title_Data = new GridData(GridData.FILL_HORIZONTAL); - title_.setLayoutData(title_Data); - title_.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.EEFMasterPage.Naming.title_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - } - - }); - title_.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.EEFMasterPage.Naming.title_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - } - } - - }); - EditingUtils.setID(title_, EditorViewsRepository.EEFMasterPage.Naming.title_); - EditingUtils.setEEFtype(title_, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFMasterPage.Naming.title_, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createTitle_Text - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createSettingsGroup(Composite parent) { - Group settingsGroup = new Group(parent, SWT.NONE); - settingsGroup.setText(EditorMessages.EEFMasterPagePropertiesEditionPart_SettingsGroupLabel); - GridData settingsGroupData = new GridData(GridData.FILL_HORIZONTAL); - settingsGroupData.horizontalSpan = 3; - settingsGroup.setLayoutData(settingsGroupData); - GridLayout settingsGroupLayout = new GridLayout(); - settingsGroupLayout.numColumns = 3; - settingsGroup.setLayout(settingsGroupLayout); - return settingsGroup; - } - - - protected Composite createOrientableCheckbox(Composite parent) { - orientable = new Button(parent, SWT.CHECK); - orientable.setText(getDescription(EditorViewsRepository.EEFMasterPage.Settings.orientable, EditorMessages.EEFMasterPagePropertiesEditionPart_OrientableLabel)); - orientable.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.EEFMasterPage.Settings.orientable, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(orientable.getSelection()))); - } - - }); - GridData orientableData = new GridData(GridData.FILL_HORIZONTAL); - orientableData.horizontalSpan = 2; - orientable.setLayoutData(orientableData); - EditingUtils.setID(orientable, EditorViewsRepository.EEFMasterPage.Settings.orientable); - EditingUtils.setEEFtype(orientable, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFMasterPage.Settings.orientable, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createOrientableCheckbox - - // End of user code - return parent; - } - - - protected Composite createShowValidatePageCheckbox(Composite parent) { - showValidatePage = new Button(parent, SWT.CHECK); - showValidatePage.setText(getDescription(EditorViewsRepository.EEFMasterPage.Settings.showValidatePage, EditorMessages.EEFMasterPagePropertiesEditionPart_ShowValidatePageLabel)); - showValidatePage.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.EEFMasterPage.Settings.showValidatePage, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(showValidatePage.getSelection()))); - } - - }); - GridData showValidatePageData = new GridData(GridData.FILL_HORIZONTAL); - showValidatePageData.horizontalSpan = 2; - showValidatePage.setLayoutData(showValidatePageData); - EditingUtils.setID(showValidatePage, EditorViewsRepository.EEFMasterPage.Settings.showValidatePage); - EditingUtils.setEEFtype(showValidatePage, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.EEFMasterPage.Settings.showValidatePage, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createShowValidatePageCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFMasterPage.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.EEFMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#getTitle_() - * - */ - public String getTitle_() { - return title_.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#setTitle_(String newValue) - * - */ - public void setTitle_(String newValue) { - if (newValue != null) { - title_.setText(newValue); - } else { - title_.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFMasterPage.Naming.title_); - if (eefElementEditorReadOnlyState && title_.isEnabled()) { - title_.setEnabled(false); - title_.setToolTipText(EditorMessages.EEFMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !title_.isEnabled()) { - title_.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#getOrientable() - * - */ - public Boolean getOrientable() { - return Boolean.valueOf(orientable.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#setOrientable(Boolean newValue) - * - */ - public void setOrientable(Boolean newValue) { - if (newValue != null) { - orientable.setSelection(newValue.booleanValue()); - } else { - orientable.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFMasterPage.Settings.orientable); - if (eefElementEditorReadOnlyState && orientable.isEnabled()) { - orientable.setEnabled(false); - orientable.setToolTipText(EditorMessages.EEFMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !orientable.isEnabled()) { - orientable.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#getShowValidatePage() - * - */ - public Boolean getShowValidatePage() { - return Boolean.valueOf(showValidatePage.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.EEFMasterPagePropertiesEditionPart#setShowValidatePage(Boolean newValue) - * - */ - public void setShowValidatePage(Boolean newValue) { - if (newValue != null) { - showValidatePage.setSelection(newValue.booleanValue()); - } else { - showValidatePage.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.EEFMasterPage.Settings.showValidatePage); - if (eefElementEditorReadOnlyState && showValidatePage.isEnabled()) { - showValidatePage.setEnabled(false); - showValidatePage.setToolTipText(EditorMessages.EEFMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !showValidatePage.isEnabled()) { - showValidatePage.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.EEFMasterPage_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/PartFilterPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/PartFilterPropertiesEditionPartImpl.java deleted file mode 100644 index 16640183e..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/PartFilterPropertiesEditionPartImpl.java +++ /dev/null @@ -1,590 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class PartFilterPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, PartFilterPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer contextualComponent; - protected EObjectFlatComboViewer filteredPart; - protected Button mandatory; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public PartFilterPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence partFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - partFilterStep - .addStep(EditorViewsRepository.PartFilter.Naming.class) - .addStep(EditorViewsRepository.PartFilter.Naming.name); - - CompositionStep filterStep = partFilterStep.addStep(EditorViewsRepository.PartFilter.Filter.class); - filterStep.addStep(EditorViewsRepository.PartFilter.Filter.contextualComponent); - filterStep.addStep(EditorViewsRepository.PartFilter.Filter.filteredPart); - - partFilterStep - .addStep(EditorViewsRepository.PartFilter.Settings.class) - .addStep(EditorViewsRepository.PartFilter.Settings.mandatory); - - - composer = new PartComposer(partFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.PartFilter.Naming.class) { - return createNamingGroup(parent); - } - if (key == EditorViewsRepository.PartFilter.Naming.name) { - return createNameText(parent); - } - if (key == EditorViewsRepository.PartFilter.Filter.class) { - return createFilterGroup(parent); - } - if (key == EditorViewsRepository.PartFilter.Filter.contextualComponent) { - return createContextualComponentFlatComboViewer(parent); - } - if (key == EditorViewsRepository.PartFilter.Filter.filteredPart) { - return createFilteredPartFlatComboViewer(parent); - } - if (key == EditorViewsRepository.PartFilter.Settings.class) { - return createSettingsGroup(parent); - } - if (key == EditorViewsRepository.PartFilter.Settings.mandatory) { - return createMandatoryCheckbox(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createNamingGroup(Composite parent) { - Group namingGroup = new Group(parent, SWT.NONE); - namingGroup.setText(EditorMessages.PartFilterPropertiesEditionPart_NamingGroupLabel); - GridData namingGroupData = new GridData(GridData.FILL_HORIZONTAL); - namingGroupData.horizontalSpan = 3; - namingGroup.setLayoutData(namingGroupData); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - return namingGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, EditorViewsRepository.PartFilter.Naming.name, EditorMessages.PartFilterPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PartFilterPropertiesEditionPartImpl.this, EditorViewsRepository.PartFilter.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PartFilterPropertiesEditionPartImpl.this, EditorViewsRepository.PartFilter.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, EditorViewsRepository.PartFilter.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.PartFilter.Naming.name, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createFilterGroup(Composite parent) { - Group filterGroup = new Group(parent, SWT.NONE); - filterGroup.setText(EditorMessages.PartFilterPropertiesEditionPart_FilterGroupLabel); - GridData filterGroupData = new GridData(GridData.FILL_HORIZONTAL); - filterGroupData.horizontalSpan = 3; - filterGroup.setLayoutData(filterGroupData); - GridLayout filterGroupLayout = new GridLayout(); - filterGroupLayout.numColumns = 3; - filterGroup.setLayout(filterGroupLayout); - return filterGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createContextualComponentFlatComboViewer(Composite parent) { - createDescription(parent, EditorViewsRepository.PartFilter.Filter.contextualComponent, EditorMessages.PartFilterPropertiesEditionPart_ContextualComponentLabel); - contextualComponent = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EditorViewsRepository.PartFilter.Filter.contextualComponent, EditorViewsRepository.SWT_KIND)); - contextualComponent.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - contextualComponent.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PartFilterPropertiesEditionPartImpl.this, EditorViewsRepository.PartFilter.Filter.contextualComponent, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getContextualComponent())); - } - - }); - GridData contextualComponentData = new GridData(GridData.FILL_HORIZONTAL); - contextualComponent.setLayoutData(contextualComponentData); - contextualComponent.setID(EditorViewsRepository.PartFilter.Filter.contextualComponent); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.PartFilter.Filter.contextualComponent, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createContextualComponentFlatComboViewer - - // End of user code - return parent; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createFilteredPartFlatComboViewer(Composite parent) { - createDescription(parent, EditorViewsRepository.PartFilter.Filter.filteredPart, EditorMessages.PartFilterPropertiesEditionPart_FilteredPartLabel); - filteredPart = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EditorViewsRepository.PartFilter.Filter.filteredPart, EditorViewsRepository.SWT_KIND)); - filteredPart.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - filteredPart.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PartFilterPropertiesEditionPartImpl.this, EditorViewsRepository.PartFilter.Filter.filteredPart, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getFilteredPart())); - } - - }); - GridData filteredPartData = new GridData(GridData.FILL_HORIZONTAL); - filteredPart.setLayoutData(filteredPartData); - filteredPart.setID(EditorViewsRepository.PartFilter.Filter.filteredPart); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.PartFilter.Filter.filteredPart, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createFilteredPartFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createSettingsGroup(Composite parent) { - Group settingsGroup = new Group(parent, SWT.NONE); - settingsGroup.setText(EditorMessages.PartFilterPropertiesEditionPart_SettingsGroupLabel); - GridData settingsGroupData = new GridData(GridData.FILL_HORIZONTAL); - settingsGroupData.horizontalSpan = 3; - settingsGroup.setLayoutData(settingsGroupData); - GridLayout settingsGroupLayout = new GridLayout(); - settingsGroupLayout.numColumns = 3; - settingsGroup.setLayout(settingsGroupLayout); - return settingsGroup; - } - - - protected Composite createMandatoryCheckbox(Composite parent) { - mandatory = new Button(parent, SWT.CHECK); - mandatory.setText(getDescription(EditorViewsRepository.PartFilter.Settings.mandatory, EditorMessages.PartFilterPropertiesEditionPart_MandatoryLabel)); - mandatory.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(PartFilterPropertiesEditionPartImpl.this, EditorViewsRepository.PartFilter.Settings.mandatory, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(mandatory.getSelection()))); - } - - }); - GridData mandatoryData = new GridData(GridData.FILL_HORIZONTAL); - mandatoryData.horizontalSpan = 2; - mandatory.setLayoutData(mandatoryData); - EditingUtils.setID(mandatory, EditorViewsRepository.PartFilter.Settings.mandatory); - EditingUtils.setEEFtype(mandatory, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.PartFilter.Settings.mandatory, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createMandatoryCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#getContextualComponent() - * - */ - public EObject getContextualComponent() { - if (contextualComponent.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) contextualComponent.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#initContextualComponent(EObjectFlatComboSettings) - */ - public void initContextualComponent(EObjectFlatComboSettings settings) { - contextualComponent.setInput(settings); - if (current != null) { - contextualComponent.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Filter.contextualComponent); - if (eefElementEditorReadOnlyState && contextualComponent.isEnabled()) { - contextualComponent.setEnabled(false); - contextualComponent.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !contextualComponent.isEnabled()) { - contextualComponent.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setContextualComponent(EObject newValue) - * - */ - public void setContextualComponent(EObject newValue) { - if (newValue != null) { - contextualComponent.setSelection(new StructuredSelection(newValue)); - } else { - contextualComponent.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Filter.contextualComponent); - if (eefElementEditorReadOnlyState && contextualComponent.isEnabled()) { - contextualComponent.setEnabled(false); - contextualComponent.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !contextualComponent.isEnabled()) { - contextualComponent.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setContextualComponentButtonMode(ButtonsModeEnum newValue) - */ - public void setContextualComponentButtonMode(ButtonsModeEnum newValue) { - contextualComponent.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#addFilterContextualComponent(ViewerFilter filter) - * - */ - public void addFilterToContextualComponent(ViewerFilter filter) { - contextualComponent.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#addBusinessFilterContextualComponent(ViewerFilter filter) - * - */ - public void addBusinessFilterToContextualComponent(ViewerFilter filter) { - contextualComponent.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#getFilteredPart() - * - */ - public EObject getFilteredPart() { - if (filteredPart.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) filteredPart.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#initFilteredPart(EObjectFlatComboSettings) - */ - public void initFilteredPart(EObjectFlatComboSettings settings) { - filteredPart.setInput(settings); - if (current != null) { - filteredPart.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Filter.filteredPart); - if (eefElementEditorReadOnlyState && filteredPart.isEnabled()) { - filteredPart.setEnabled(false); - filteredPart.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !filteredPart.isEnabled()) { - filteredPart.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setFilteredPart(EObject newValue) - * - */ - public void setFilteredPart(EObject newValue) { - if (newValue != null) { - filteredPart.setSelection(new StructuredSelection(newValue)); - } else { - filteredPart.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Filter.filteredPart); - if (eefElementEditorReadOnlyState && filteredPart.isEnabled()) { - filteredPart.setEnabled(false); - filteredPart.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !filteredPart.isEnabled()) { - filteredPart.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setFilteredPartButtonMode(ButtonsModeEnum newValue) - */ - public void setFilteredPartButtonMode(ButtonsModeEnum newValue) { - filteredPart.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#addFilterFilteredPart(ViewerFilter filter) - * - */ - public void addFilterToFilteredPart(ViewerFilter filter) { - filteredPart.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#addBusinessFilterFilteredPart(ViewerFilter filter) - * - */ - public void addBusinessFilterToFilteredPart(ViewerFilter filter) { - filteredPart.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return Boolean.valueOf(mandatory.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.PartFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - if (newValue != null) { - mandatory.setSelection(newValue.booleanValue()); - } else { - mandatory.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.PartFilter.Settings.mandatory); - if (eefElementEditorReadOnlyState && mandatory.isEnabled()) { - mandatory.setEnabled(false); - mandatory.setToolTipText(EditorMessages.PartFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !mandatory.isEnabled()) { - mandatory.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.PartFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/StandardFormPagePropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/StandardFormPagePropertiesEditionPartImpl.java deleted file mode 100644 index 096ea528c..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/StandardFormPagePropertiesEditionPartImpl.java +++ /dev/null @@ -1,321 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class StandardFormPagePropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, StandardFormPagePropertiesEditionPart { - - protected Text name; - protected Text title_; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public StandardFormPagePropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence standardFormPageStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep namingStep = standardFormPageStep.addStep(EditorViewsRepository.StandardFormPage.Naming.class); - namingStep.addStep(EditorViewsRepository.StandardFormPage.Naming.name); - namingStep.addStep(EditorViewsRepository.StandardFormPage.Naming.title_); - - - composer = new PartComposer(standardFormPageStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.StandardFormPage.Naming.class) { - return createNamingGroup(parent); - } - if (key == EditorViewsRepository.StandardFormPage.Naming.name) { - return createNameText(parent); - } - if (key == EditorViewsRepository.StandardFormPage.Naming.title_) { - return createTitle_Text(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createNamingGroup(Composite parent) { - Group namingGroup = new Group(parent, SWT.NONE); - namingGroup.setText(EditorMessages.StandardFormPagePropertiesEditionPart_NamingGroupLabel); - GridData namingGroupData = new GridData(GridData.FILL_HORIZONTAL); - namingGroupData.horizontalSpan = 3; - namingGroup.setLayoutData(namingGroupData); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - return namingGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, EditorViewsRepository.StandardFormPage.Naming.name, EditorMessages.StandardFormPagePropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardFormPagePropertiesEditionPartImpl.this, EditorViewsRepository.StandardFormPage.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardFormPagePropertiesEditionPartImpl.this, EditorViewsRepository.StandardFormPage.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, EditorViewsRepository.StandardFormPage.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.StandardFormPage.Naming.name, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createTitle_Text(Composite parent) { - createDescription(parent, EditorViewsRepository.StandardFormPage.Naming.title_, EditorMessages.StandardFormPagePropertiesEditionPart_Title_Label); - title_ = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData title_Data = new GridData(GridData.FILL_HORIZONTAL); - title_.setLayoutData(title_Data); - title_.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardFormPagePropertiesEditionPartImpl.this, EditorViewsRepository.StandardFormPage.Naming.title_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - } - - }); - title_.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardFormPagePropertiesEditionPartImpl.this, EditorViewsRepository.StandardFormPage.Naming.title_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - } - } - - }); - EditingUtils.setID(title_, EditorViewsRepository.StandardFormPage.Naming.title_); - EditingUtils.setEEFtype(title_, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.StandardFormPage.Naming.title_, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createTitle_Text - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.StandardFormPage.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.StandardFormPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart#getTitle_() - * - */ - public String getTitle_() { - return title_.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StandardFormPagePropertiesEditionPart#setTitle_(String newValue) - * - */ - public void setTitle_(String newValue) { - if (newValue != null) { - title_.setText(newValue); - } else { - title_.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.StandardFormPage.Naming.title_); - if (eefElementEditorReadOnlyState && title_.isEnabled()) { - title_.setEnabled(false); - title_.setToolTipText(EditorMessages.StandardFormPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !title_.isEnabled()) { - title_.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.StandardFormPage_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/StaticEEFEditorContributionPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/StaticEEFEditorContributionPropertiesEditionPartImpl.java deleted file mode 100644 index b121650ad..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/StaticEEFEditorContributionPropertiesEditionPartImpl.java +++ /dev/null @@ -1,425 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.impl; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class StaticEEFEditorContributionPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, StaticEEFEditorContributionPropertiesEditionPart { - - protected Text name; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public StaticEEFEditorContributionPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence staticEEFEditorContributionStep = new BindingCompositionSequence(propertiesEditionComponent); - staticEEFEditorContributionStep - .addStep(EditorViewsRepository.StaticEEFEditorContribution.Naming.class) - .addStep(EditorViewsRepository.StaticEEFEditorContribution.Naming.name); - - staticEEFEditorContributionStep - .addStep(EditorViewsRepository.StaticEEFEditorContribution.Binding.class) - .addStep(EditorViewsRepository.StaticEEFEditorContribution.Binding.views); - - - composer = new PartComposer(staticEEFEditorContributionStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.StaticEEFEditorContribution.Naming.class) { - return createNamingGroup(parent); - } - if (key == EditorViewsRepository.StaticEEFEditorContribution.Naming.name) { - return createNameText(parent); - } - if (key == EditorViewsRepository.StaticEEFEditorContribution.Binding.class) { - return createBindingGroup(parent); - } - if (key == EditorViewsRepository.StaticEEFEditorContribution.Binding.views) { - return createViewsAdvancedReferencesTable(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createNamingGroup(Composite parent) { - Group namingGroup = new Group(parent, SWT.NONE); - namingGroup.setText(EditorMessages.StaticEEFEditorContributionPropertiesEditionPart_NamingGroupLabel); - GridData namingGroupData = new GridData(GridData.FILL_HORIZONTAL); - namingGroupData.horizontalSpan = 3; - namingGroup.setLayoutData(namingGroupData); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - return namingGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, EditorViewsRepository.StaticEEFEditorContribution.Naming.name, EditorMessages.StaticEEFEditorContributionPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.StaticEEFEditorContribution.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.StaticEEFEditorContribution.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, EditorViewsRepository.StaticEEFEditorContribution.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.StaticEEFEditorContribution.Naming.name, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(EditorMessages.StaticEEFEditorContributionPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * - */ - protected Composite createViewsAdvancedReferencesTable(Composite parent) { - String label = getDescription(EditorViewsRepository.StaticEEFEditorContribution.Binding.views, EditorMessages.StaticEEFEditorContributionPropertiesEditionPart_ViewsLabel); - this.views = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(EditorViewsRepository.StaticEEFEditorContribution.Binding.views, EditorViewsRepository.SWT_KIND)); - this.views.createControls(parent); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.StaticEEFEditorContribution.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(EditorViewsRepository.StaticEEFEditorContribution.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.StaticEEFEditorContribution.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.StaticEEFEditorContribution.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StaticEEFEditorContributionPropertiesEditionPartImpl.this, EditorViewsRepository.StaticEEFEditorContribution.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.StaticEEFEditorContribution.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.StaticEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.StaticEEFEditorContribution.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(EditorMessages.StaticEEFEditorContribution_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.StaticEEFEditorContributionPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.StaticEEFEditorContribution_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/TreeMasterPagePropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/TreeMasterPagePropertiesEditionPartImpl.java deleted file mode 100644 index 71a4a9513..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/parts/impl/TreeMasterPagePropertiesEditionPartImpl.java +++ /dev/null @@ -1,412 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; -import org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart; -import org.eclipse.emf.eef.extended.editor.providers.EditorMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class TreeMasterPagePropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, TreeMasterPagePropertiesEditionPart { - - protected Text name; - protected Text title_; - protected Button toolbarVisible; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public TreeMasterPagePropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence treeMasterPageStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep namingStep = treeMasterPageStep.addStep(EditorViewsRepository.TreeMasterPage.Naming.class); - namingStep.addStep(EditorViewsRepository.TreeMasterPage.Naming.name); - namingStep.addStep(EditorViewsRepository.TreeMasterPage.Naming.title_); - - treeMasterPageStep - .addStep(EditorViewsRepository.TreeMasterPage.Settings.class) - .addStep(EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible); - - - composer = new PartComposer(treeMasterPageStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EditorViewsRepository.TreeMasterPage.Naming.class) { - return createNamingGroup(parent); - } - if (key == EditorViewsRepository.TreeMasterPage.Naming.name) { - return createNameText(parent); - } - if (key == EditorViewsRepository.TreeMasterPage.Naming.title_) { - return createTitle_Text(parent); - } - if (key == EditorViewsRepository.TreeMasterPage.Settings.class) { - return createSettingsGroup(parent); - } - if (key == EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible) { - return createToolbarVisibleCheckbox(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createNamingGroup(Composite parent) { - Group namingGroup = new Group(parent, SWT.NONE); - namingGroup.setText(EditorMessages.TreeMasterPagePropertiesEditionPart_NamingGroupLabel); - GridData namingGroupData = new GridData(GridData.FILL_HORIZONTAL); - namingGroupData.horizontalSpan = 3; - namingGroup.setLayoutData(namingGroupData); - GridLayout namingGroupLayout = new GridLayout(); - namingGroupLayout.numColumns = 3; - namingGroup.setLayout(namingGroupLayout); - return namingGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, EditorViewsRepository.TreeMasterPage.Naming.name, EditorMessages.TreeMasterPagePropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(TreeMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.TreeMasterPage.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(TreeMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.TreeMasterPage.Naming.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, EditorViewsRepository.TreeMasterPage.Naming.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.TreeMasterPage.Naming.name, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createTitle_Text(Composite parent) { - createDescription(parent, EditorViewsRepository.TreeMasterPage.Naming.title_, EditorMessages.TreeMasterPagePropertiesEditionPart_Title_Label); - title_ = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData title_Data = new GridData(GridData.FILL_HORIZONTAL); - title_.setLayoutData(title_Data); - title_.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(TreeMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.TreeMasterPage.Naming.title_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - } - - }); - title_.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(TreeMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.TreeMasterPage.Naming.title_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, title_.getText())); - } - } - - }); - EditingUtils.setID(title_, EditorViewsRepository.TreeMasterPage.Naming.title_); - EditingUtils.setEEFtype(title_, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.TreeMasterPage.Naming.title_, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createTitle_Text - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createSettingsGroup(Composite parent) { - Group settingsGroup = new Group(parent, SWT.NONE); - settingsGroup.setText(EditorMessages.TreeMasterPagePropertiesEditionPart_SettingsGroupLabel); - GridData settingsGroupData = new GridData(GridData.FILL_HORIZONTAL); - settingsGroupData.horizontalSpan = 3; - settingsGroup.setLayoutData(settingsGroupData); - GridLayout settingsGroupLayout = new GridLayout(); - settingsGroupLayout.numColumns = 3; - settingsGroup.setLayout(settingsGroupLayout); - return settingsGroup; - } - - - protected Composite createToolbarVisibleCheckbox(Composite parent) { - toolbarVisible = new Button(parent, SWT.CHECK); - toolbarVisible.setText(getDescription(EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible, EditorMessages.TreeMasterPagePropertiesEditionPart_ToolbarVisibleLabel)); - toolbarVisible.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(TreeMasterPagePropertiesEditionPartImpl.this, EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(toolbarVisible.getSelection()))); - } - - }); - GridData toolbarVisibleData = new GridData(GridData.FILL_HORIZONTAL); - toolbarVisibleData.horizontalSpan = 2; - toolbarVisible.setLayoutData(toolbarVisibleData); - EditingUtils.setID(toolbarVisible, EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible); - EditingUtils.setEEFtype(toolbarVisible, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible, EditorViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createToolbarVisibleCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.TreeMasterPage.Naming.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(EditorMessages.TreeMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#getTitle_() - * - */ - public String getTitle_() { - return title_.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#setTitle_(String newValue) - * - */ - public void setTitle_(String newValue) { - if (newValue != null) { - title_.setText(newValue); - } else { - title_.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.TreeMasterPage.Naming.title_); - if (eefElementEditorReadOnlyState && title_.isEnabled()) { - title_.setEnabled(false); - title_.setToolTipText(EditorMessages.TreeMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !title_.isEnabled()) { - title_.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#getToolbarVisible() - * - */ - public Boolean getToolbarVisible() { - return Boolean.valueOf(toolbarVisible.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.editor.parts.TreeMasterPagePropertiesEditionPart#setToolbarVisible(Boolean newValue) - * - */ - public void setToolbarVisible(Boolean newValue) { - if (newValue != null) { - toolbarVisible.setSelection(newValue.booleanValue()); - } else { - toolbarVisible.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EditorViewsRepository.TreeMasterPage.Settings.toolbarVisible); - if (eefElementEditorReadOnlyState && toolbarVisible.isEnabled()) { - toolbarVisible.setEnabled(false); - toolbarVisible.setToolTipText(EditorMessages.TreeMasterPage_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !toolbarVisible.isEnabled()) { - toolbarVisible.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EditorMessages.TreeMasterPage_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/AllResourcesRootsRelativeInputItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/AllResourcesRootsRelativeInputItemProvider.java deleted file mode 100644 index d85ce11b7..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/AllResourcesRootsRelativeInputItemProvider.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput} object. - * - * - * @generated - */ -public class AllResourcesRootsRelativeInputItemProvider - extends EEFPageInputItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public AllResourcesRootsRelativeInputItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns AllResourcesRootsRelativeInput.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/AllResourcesRootsRelativeInput")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_AllResourcesRootsRelativeInput_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/DynamicEEFEditorContributionItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/DynamicEEFEditorContributionItemProvider.java deleted file mode 100644 index e75bc3776..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/DynamicEEFEditorContributionItemProvider.java +++ /dev/null @@ -1,188 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.filters.FiltersFactory; -import org.eclipse.emf.eef.mapping.provider.EMFElementBindingItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution} object. - * - * - * @generated - */ -public class DynamicEEFEditorContributionItemProvider - extends EMFElementBindingItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public DynamicEEFEditorContributionItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures(Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures.add(EditorPackage.Literals.EEF_EDITOR_CONTRIBUTION__INPUT); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns DynamicEEFEditorContribution.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/DynamicEEFEditorContribution")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((DynamicEEFEditorContribution)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_DynamicEEFEditorContribution_type") : - getString("_UI_DynamicEEFEditorContribution_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(DynamicEEFEditorContribution.class)) { - case EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION__INPUT: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated NOT - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { -// super.collectNewChildDescriptors(newChildDescriptors, object); - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS, - EditorFactory.eINSTANCE.createPartFilter())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS, - FiltersFactory.eINSTANCE.createJavaDeclarationFilter())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS, - FiltersFactory.eINSTANCE.createJavaExpressionFilter())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS, - FiltersFactory.eINSTANCE.createOCLFilter())); - - newChildDescriptors.add - (createChildParameter - (EditorPackage.Literals.EEF_EDITOR_CONTRIBUTION__INPUT, - EditorFactory.eINSTANCE.createAllResourcesRootsRelativeInput())); - - newChildDescriptors.add - (createChildParameter - (EditorPackage.Literals.EEF_EDITOR_CONTRIBUTION__INPUT, - EditorFactory.eINSTANCE.createFirstResourceRootRelativeInput())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorContributionItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorContributionItemProvider.java deleted file mode 100644 index a8d25f162..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorContributionItemProvider.java +++ /dev/null @@ -1,182 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.extended.editor.EEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.EEFEditorContribution} object. - * - * - * @generated - */ -public class EEFEditorContributionItemProvider - extends ItemProviderAdapter - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFEditorContributionItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures(Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures.add(EditorPackage.Literals.EEF_EDITOR_CONTRIBUTION__INPUT); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns EEFEditorContribution.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/EEFEditorContribution")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_EEFEditorContribution_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(EEFEditorContribution.class)) { - case EditorPackage.EEF_EDITOR_CONTRIBUTION__INPUT: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated NOT - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - newChildDescriptors.add - (createChildParameter - (EditorPackage.Literals.EEF_EDITOR_CONTRIBUTION__INPUT, - EditorFactory.eINSTANCE.createAllResourcesRootsRelativeInput())); - - newChildDescriptors.add - (createChildParameter - (EditorPackage.Literals.EEF_EDITOR_CONTRIBUTION__INPUT, - EditorFactory.eINSTANCE.createFirstResourceRootRelativeInput())); - - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS, - EditorFactory.eINSTANCE.createPartFilter())); - - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender)adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorContributionsItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorContributionsItemProvider.java deleted file mode 100644 index 818a46d7f..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorContributionsItemProvider.java +++ /dev/null @@ -1,126 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.extended.editor.EEFEditorContributions; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.provider.CategoryItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.EEFEditorContributions} object. - * - * - * @generated - */ -public class EEFEditorContributionsItemProvider - extends CategoryItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFEditorContributionsItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns EEFEditorContributions.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/EEFEditorContributions")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EEFEditorContributions)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_EEFEditorContributions_type") : - getString("_UI_EEFEditorContributions_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated NOT - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.CATEGORY__BINDINGS, - EditorFactory.eINSTANCE.createStaticEEFEditorContribution())); - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.CATEGORY__BINDINGS, - EditorFactory.eINSTANCE.createDynamicEEFEditorContribution())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorPagesItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorPagesItemProvider.java deleted file mode 100644 index 33408b70a..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFEditorPagesItemProvider.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.extended.editor.EEFEditorPages; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.emf.eef.views.provider.CategoryItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.EEFEditorPages} object. - * - * - * @generated - */ -public class EEFEditorPagesItemProvider - extends CategoryItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFEditorPagesItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns EEFEditorPages.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/EEFEditorPages")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EEFEditorPages)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_EEFEditorPages_type") : - getString("_UI_EEFEditorPages_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated NOT - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CATEGORY__VIEWS, - EditorFactory.eINSTANCE.createStandardFormPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CATEGORY__VIEWS, - EditorFactory.eINSTANCE.createEEFMasterPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CATEGORY__VIEWS, - EditorFactory.eINSTANCE.createTreeMasterPage())); - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFMasterPageItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFMasterPageItemProvider.java deleted file mode 100644 index 800304502..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFMasterPageItemProvider.java +++ /dev/null @@ -1,173 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.extended.editor.EEFMasterPage; -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.EEFMasterPage} object. - * - * - * @generated - */ -public class EEFMasterPageItemProvider - extends MasterDetailsPageItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFMasterPageItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addOrientablePropertyDescriptor(object); - addShowValidatePagePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Orientable feature. - * - * - * @generated - */ - protected void addOrientablePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EEFMasterPage_orientable_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EEFMasterPage_orientable_feature", "_UI_EEFMasterPage_type"), - EditorPackage.Literals.EEF_MASTER_PAGE__ORIENTABLE, - true, - false, - false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Show Validate Page feature. - * - * - * @generated - */ - protected void addShowValidatePagePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EEFMasterPage_showValidatePage_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EEFMasterPage_showValidatePage_feature", "_UI_EEFMasterPage_type"), - EditorPackage.Literals.EEF_MASTER_PAGE__SHOW_VALIDATE_PAGE, - true, - false, - false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns EEFMasterPage.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/EEFMasterPage")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EEFMasterPage)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_EEFMasterPage_type") : - getString("_UI_EEFMasterPage_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(EEFMasterPage.class)) { - case EditorPackage.EEF_MASTER_PAGE__ORIENTABLE: - case EditorPackage.EEF_MASTER_PAGE__SHOW_VALIDATE_PAGE: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFPageInputItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFPageInputItemProvider.java deleted file mode 100644 index 75295a30b..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFPageInputItemProvider.java +++ /dev/null @@ -1,166 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.extended.editor.EEFPageInput; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.query.QueryFactory; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.EEFPageInput} object. - * - * - * @generated - */ -public class EEFPageInputItemProvider - extends ItemProviderAdapter - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFPageInputItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures(Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures.add(EditorPackage.Literals.EEF_PAGE_INPUT__QUERY); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_EEFPageInput_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(EEFPageInput.class)) { - case EditorPackage.EEF_PAGE_INPUT__QUERY: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add - (createChildParameter - (EditorPackage.Literals.EEF_PAGE_INPUT__QUERY, - QueryFactory.eINSTANCE.createOCLQuery())); - - newChildDescriptors.add - (createChildParameter - (EditorPackage.Literals.EEF_PAGE_INPUT__QUERY, - QueryFactory.eINSTANCE.createExplicitPathQuery())); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender)adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFPageItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFPageItemProvider.java deleted file mode 100644 index e062d3f77..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EEFPageItemProvider.java +++ /dev/null @@ -1,156 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.extended.editor.EEFPage; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.emf.eef.views.provider.ViewItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.EEFPage} object. - * - * - * @generated - */ -public class EEFPageItemProvider - extends ViewItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFPageItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addTitlePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Title feature. - * - * - * @generated - */ - protected void addTitlePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EEFPage_title_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EEFPage_title_feature", "_UI_EEFPage_type"), - EditorPackage.Literals.EEF_PAGE__TITLE, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EEFPage)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_EEFPage_type") : - getString("_UI_EEFPage_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(EEFPage.class)) { - case EditorPackage.EEF_PAGE__TITLE: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CONTAINER__ELEMENTS, - EditorFactory.eINSTANCE.createStandardFormPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CONTAINER__ELEMENTS, - EditorFactory.eINSTANCE.createEEFMasterPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CONTAINER__ELEMENTS, - EditorFactory.eINSTANCE.createTreeMasterPage())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EditorItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EditorItemProviderAdapterFactory.java deleted file mode 100644 index a7ab4d076..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/EditorItemProviderAdapterFactory.java +++ /dev/null @@ -1,818 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.command.CommandParameter; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ChildCreationExtenderManager; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.util.EditorAdapterFactory; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.AbstractPropertyBinding; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.util.MappingSwitch; -import org.eclipse.emf.eef.views.Container; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.emf.eef.views.ViewsRepository; -import org.eclipse.emf.eef.views.util.ViewsSwitch; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class EditorItemProviderAdapterFactory extends EditorAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable, IChildCreationExtender { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This helps manage the child creation extenders. - * - * - * @generated - */ - protected ChildCreationExtenderManager childCreationExtenderManager = new ChildCreationExtenderManager(ExtendedEditPlugin.INSTANCE, EditorPackage.eNS_URI); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public EditorItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.StandardFormPage} instances. - * - * - * @generated - */ - protected StandardFormPageItemProvider standardFormPageItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.StandardFormPage}. - * - * - * @generated - */ - @Override - public Adapter createStandardFormPageAdapter() { - if (standardFormPageItemProvider == null) { - standardFormPageItemProvider = new StandardFormPageItemProvider(this); - } - - return standardFormPageItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.EEFMasterPage} instances. - * - * - * @generated - */ - protected EEFMasterPageItemProvider eefMasterPageItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.EEFMasterPage}. - * - * - * @generated - */ - @Override - public Adapter createEEFMasterPageAdapter() { - if (eefMasterPageItemProvider == null) { - eefMasterPageItemProvider = new EEFMasterPageItemProvider(this); - } - - return eefMasterPageItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.TreeMasterPage} instances. - * - * - * @generated - */ - protected TreeMasterPageItemProvider treeMasterPageItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.TreeMasterPage}. - * - * - * @generated - */ - @Override - public Adapter createTreeMasterPageAdapter() { - if (treeMasterPageItemProvider == null) { - treeMasterPageItemProvider = new TreeMasterPageItemProvider(this); - } - - return treeMasterPageItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput} instances. - * - * - * @generated - */ - protected AllResourcesRootsRelativeInputItemProvider allResourcesRootsRelativeInputItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput}. - * - * - * @generated - */ - @Override - public Adapter createAllResourcesRootsRelativeInputAdapter() { - if (allResourcesRootsRelativeInputItemProvider == null) { - allResourcesRootsRelativeInputItemProvider = new AllResourcesRootsRelativeInputItemProvider(this); - } - - return allResourcesRootsRelativeInputItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput} instances. - * - * - * @generated - */ - protected FirstResourceRootRelativeInputItemProvider firstResourceRootRelativeInputItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput}. - * - * - * @generated - */ - @Override - public Adapter createFirstResourceRootRelativeInputAdapter() { - if (firstResourceRootRelativeInputItemProvider == null) { - firstResourceRootRelativeInputItemProvider = new FirstResourceRootRelativeInputItemProvider(this); - } - - return firstResourceRootRelativeInputItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.PartFilter} instances. - * - * - * @generated - */ - protected PartFilterItemProvider partFilterItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.PartFilter}. - * - * - * @generated - */ - @Override - public Adapter createPartFilterAdapter() { - if (partFilterItemProvider == null) { - partFilterItemProvider = new PartFilterItemProvider(this); - } - - return partFilterItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.EEFEditorContributions} instances. - * - * - * @generated - */ - protected EEFEditorContributionsItemProvider eefEditorContributionsItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.EEFEditorContributions}. - * - * - * @generated - */ - @Override - public Adapter createEEFEditorContributionsAdapter() { - if (eefEditorContributionsItemProvider == null) { - eefEditorContributionsItemProvider = new EEFEditorContributionsItemProvider(this); - } - - return eefEditorContributionsItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.EEFEditorPages} instances. - * - * - * @generated - */ - protected EEFEditorPagesItemProvider eefEditorPagesItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.EEFEditorPages}. - * - * - * @generated - */ - @Override - public Adapter createEEFEditorPagesAdapter() { - if (eefEditorPagesItemProvider == null) { - eefEditorPagesItemProvider = new EEFEditorPagesItemProvider(this); - } - - return eefEditorPagesItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution} instances. - * - * - * @generated - */ - protected StaticEEFEditorContributionItemProvider staticEEFEditorContributionItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution}. - * - * - * @generated - */ - @Override - public Adapter createStaticEEFEditorContributionAdapter() { - if (staticEEFEditorContributionItemProvider == null) { - staticEEFEditorContributionItemProvider = new StaticEEFEditorContributionItemProvider(this); - } - - return staticEEFEditorContributionItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution} instances. - * - * - * @generated - */ - protected DynamicEEFEditorContributionItemProvider dynamicEEFEditorContributionItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution}. - * - * - * @generated - */ - @Override - public Adapter createDynamicEEFEditorContributionAdapter() { - if (dynamicEEFEditorContributionItemProvider == null) { - dynamicEEFEditorContributionItemProvider = new DynamicEEFEditorContributionItemProvider(this); - } - - return dynamicEEFEditorContributionItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.editor.ReferenceableObject} instances. - * - * - * @generated - */ - protected ReferenceableObjectItemProvider referenceableObjectItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.editor.ReferenceableObject}. - * - * - * @generated - */ - @Override - public Adapter createReferenceableObjectAdapter() { - if (referenceableObjectItemProvider == null) { - referenceableObjectItemProvider = new ReferenceableObjectItemProvider(this); - } - - return referenceableObjectItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) || (((Class)type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * - * - * @generated - */ - public List getChildCreationExtenders() { - return childCreationExtenderManager.getChildCreationExtenders(); - } - - /** - * - * - * @generated - */ - public Collection getNewChildDescriptors(Object object, EditingDomain editingDomain) { - return childCreationExtenderManager.getNewChildDescriptors(object, editingDomain); - } - - /** - * - * - * @generated - */ - public ResourceLocator getResourceLocator() { - return childCreationExtenderManager; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (standardFormPageItemProvider != null) standardFormPageItemProvider.dispose(); - if (eefMasterPageItemProvider != null) eefMasterPageItemProvider.dispose(); - if (treeMasterPageItemProvider != null) treeMasterPageItemProvider.dispose(); - if (allResourcesRootsRelativeInputItemProvider != null) allResourcesRootsRelativeInputItemProvider.dispose(); - if (firstResourceRootRelativeInputItemProvider != null) firstResourceRootRelativeInputItemProvider.dispose(); - if (partFilterItemProvider != null) partFilterItemProvider.dispose(); - if (eefEditorContributionsItemProvider != null) eefEditorContributionsItemProvider.dispose(); - if (eefEditorPagesItemProvider != null) eefEditorPagesItemProvider.dispose(); - if (staticEEFEditorContributionItemProvider != null) staticEEFEditorContributionItemProvider.dispose(); - if (dynamicEEFEditorContributionItemProvider != null) dynamicEEFEditorContributionItemProvider.dispose(); - if (referenceableObjectItemProvider != null) referenceableObjectItemProvider.dispose(); - } - - /** - * A child creation extender for the {@link MappingPackage}. - * - * - * @generated - */ - public static class MappingChildCreationExtender implements IChildCreationExtender { - /** - * The switch for creating child descriptors specific to each extended class. - * - * - * @generated - */ - protected static class CreationSwitch extends MappingSwitch { - /** - * The child descriptors being populated. - * - * - * @generated - */ - protected List newChildDescriptors; - - /** - * The domain in which to create the children. - * - * - * @generated - */ - protected EditingDomain editingDomain; - - /** - * Creates the a switch for populating child descriptors in the given domain. - * - * - * @generated - */ - CreationSwitch(List newChildDescriptors, EditingDomain editingDomain) { - this.newChildDescriptors = newChildDescriptors; - this.editingDomain = editingDomain; - } - /** - * - * - * @generated - */ - @Override - public Object caseDatabinding(Databinding object) { - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.DATABINDING__BINDINGS, - EditorFactory.eINSTANCE.createStaticEEFEditorContribution())); - - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.DATABINDING__BINDINGS, - EditorFactory.eINSTANCE.createDynamicEEFEditorContribution())); - - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.DATABINDING__CATEGORIES, - EditorFactory.eINSTANCE.createEEFEditorContributions())); - - return null; - } - - /** - * - * - * @generated - */ - @Override - public Object caseAbstractElementBinding(AbstractElementBinding object) { - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS, - EditorFactory.eINSTANCE.createStaticEEFEditorContribution())); - - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS, - EditorFactory.eINSTANCE.createDynamicEEFEditorContribution())); - - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS, - EditorFactory.eINSTANCE.createPartFilter())); - - return null; - } - - /** - * - * - * @generated - */ - @Override - public Object caseAbstractPropertyBinding(AbstractPropertyBinding object) { - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS, - EditorFactory.eINSTANCE.createPartFilter())); - - return null; - } - - /** - * - * - * @generated - */ - @Override - public Object caseCategory(Category object) { - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.CATEGORY__BINDINGS, - EditorFactory.eINSTANCE.createStaticEEFEditorContribution())); - - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.CATEGORY__BINDINGS, - EditorFactory.eINSTANCE.createDynamicEEFEditorContribution())); - - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.CATEGORY__CATEGORIES, - EditorFactory.eINSTANCE.createEEFEditorContributions())); - - return null; - } - - /** - * - * - * @generated - */ - protected CommandParameter createChildParameter(Object feature, Object child) { - return new CommandParameter(null, feature, child); - } - - } - - /** - * - * - * @generated - */ - public Collection getNewChildDescriptors(Object object, EditingDomain editingDomain) { - ArrayList result = new ArrayList(); - new CreationSwitch(result, editingDomain).doSwitch((EObject)object); - return result; - } - - /** - * - * - * @generated - */ - public ResourceLocator getResourceLocator() { - return ExtendedEditPlugin.INSTANCE; - } - } - - /** - * A child creation extender for the {@link ViewsPackage}. - * - * - * @generated - */ - public static class ViewsChildCreationExtender implements IChildCreationExtender { - /** - * The switch for creating child descriptors specific to each extended class. - * - * - * @generated - */ - protected static class CreationSwitch extends ViewsSwitch { - /** - * The child descriptors being populated. - * - * - * @generated - */ - protected List newChildDescriptors; - - /** - * The domain in which to create the children. - * - * - * @generated - */ - protected EditingDomain editingDomain; - - /** - * Creates the a switch for populating child descriptors in the given domain. - * - * - * @generated - */ - CreationSwitch(List newChildDescriptors, EditingDomain editingDomain) { - this.newChildDescriptors = newChildDescriptors; - this.editingDomain = editingDomain; - } - /** - * - * - * @generated - */ - @Override - public Object caseViewsRepository(ViewsRepository object) { - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.VIEWS_REPOSITORY__VIEWS, - EditorFactory.eINSTANCE.createStandardFormPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.VIEWS_REPOSITORY__VIEWS, - EditorFactory.eINSTANCE.createEEFMasterPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.VIEWS_REPOSITORY__VIEWS, - EditorFactory.eINSTANCE.createTreeMasterPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.VIEWS_REPOSITORY__CATEGORIES, - EditorFactory.eINSTANCE.createEEFEditorPages())); - - return null; - } - - /** - * - * - * @generated - */ - @Override - public Object caseCategory(org.eclipse.emf.eef.views.Category object) { - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CATEGORY__VIEWS, - EditorFactory.eINSTANCE.createStandardFormPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CATEGORY__VIEWS, - EditorFactory.eINSTANCE.createEEFMasterPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CATEGORY__VIEWS, - EditorFactory.eINSTANCE.createTreeMasterPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CATEGORY__CATEGORIES, - EditorFactory.eINSTANCE.createEEFEditorPages())); - - return null; - } - - /** - * - * - * @generated - */ - @Override - public Object caseContainer(Container object) { - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CONTAINER__ELEMENTS, - EditorFactory.eINSTANCE.createStandardFormPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CONTAINER__ELEMENTS, - EditorFactory.eINSTANCE.createEEFMasterPage())); - - newChildDescriptors.add - (createChildParameter - (ViewsPackage.Literals.CONTAINER__ELEMENTS, - EditorFactory.eINSTANCE.createTreeMasterPage())); - - return null; - } - - /** - * - * - * @generated - */ - protected CommandParameter createChildParameter(Object feature, Object child) { - return new CommandParameter(null, feature, child); - } - - } - - /** - * - * - * @generated - */ - public Collection getNewChildDescriptors(Object object, EditingDomain editingDomain) { - ArrayList result = new ArrayList(); - new CreationSwitch(result, editingDomain).doSwitch((EObject)object); - return result; - } - - /** - * - * - * @generated - */ - public ResourceLocator getResourceLocator() { - return ExtendedEditPlugin.INSTANCE; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/ExtendedEditPlugin.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/ExtendedEditPlugin.java deleted file mode 100644 index 0c17e6397..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/ExtendedEditPlugin.java +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelEditPlugin; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.provider.EcoreEditPlugin; -import org.eclipse.emf.eef.components.provider.ComponentsEditPlugin; -import org.eclipse.emf.eef.mapping.provider.MappingEditPlugin; -import org.eclipse.emf.eef.views.provider.ViewsEditPlugin; - -/** - * This is the central singleton for the Extended edit plugin. - * - * - * @generated - */ -public final class ExtendedEditPlugin extends EMFPlugin { - /** - * Keep track of the singleton. - * - * - * @generated - */ - public static final ExtendedEditPlugin INSTANCE = new ExtendedEditPlugin(); - - /** - * Keep track of the singleton. - * - * - * @generated - */ - private static Implementation plugin; - - /** - * Create the instance. - * - * - * @generated - */ - public ExtendedEditPlugin() { - super - (new ResourceLocator [] { - ComponentsEditPlugin.INSTANCE, - EcoreEditPlugin.INSTANCE, - GenModelEditPlugin.INSTANCE, - MappingEditPlugin.INSTANCE, - ViewsEditPlugin.INSTANCE, - }); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - @Override - public ResourceLocator getPluginResourceLocator() { - return plugin; - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * - * @generated - */ - public static class Implementation extends EclipsePlugin { - /** - * Creates an instance. - * - * - * @generated - */ - public Implementation() { - super(); - - // Remember the static instance. - // - plugin = this; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/FirstResourceRootRelativeInputItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/FirstResourceRootRelativeInputItemProvider.java deleted file mode 100644 index ae46472f8..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/FirstResourceRootRelativeInputItemProvider.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput} object. - * - * - * @generated - */ -public class FirstResourceRootRelativeInputItemProvider - extends EEFPageInputItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public FirstResourceRootRelativeInputItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns FirstResourceRootRelativeInput.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/FirstResourceRootRelativeInput")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_FirstResourceRootRelativeInput_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/MasterDetailsPageItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/MasterDetailsPageItemProvider.java deleted file mode 100644 index 61ae860df..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/MasterDetailsPageItemProvider.java +++ /dev/null @@ -1,105 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.extended.editor.MasterDetailsPage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.MasterDetailsPage} object. - * - * - * @generated - */ -public class MasterDetailsPageItemProvider - extends EEFPageItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public MasterDetailsPageItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((MasterDetailsPage)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_MasterDetailsPage_type") : - getString("_UI_MasterDetailsPage_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/PartFilterItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/PartFilterItemProvider.java deleted file mode 100644 index cd8d67b35..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/PartFilterItemProvider.java +++ /dev/null @@ -1,165 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.PartFilter; -import org.eclipse.emf.eef.mapping.filters.provider.BindingFilterItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.PartFilter} object. - * - * - * @generated - */ -public class PartFilterItemProvider - extends BindingFilterItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public PartFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addFilteredPartPropertyDescriptor(object); - addContextualComponentPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Filtered Part feature. - * - * - * @generated - */ - protected void addFilteredPartPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_PartFilter_filteredPart_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_PartFilter_filteredPart_feature", "_UI_PartFilter_type"), - EditorPackage.Literals.PART_FILTER__FILTERED_PART, - true, - false, - true, - null, - null, - null)); - } - - /** - * This adds a property descriptor for the Contextual Component feature. - * - * - * @generated - */ - protected void addContextualComponentPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_PartFilter_contextualComponent_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_PartFilter_contextualComponent_feature", "_UI_PartFilter_type"), - EditorPackage.Literals.PART_FILTER__CONTEXTUAL_COMPONENT, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns PartFilter.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/PartFilter")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((PartFilter)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_PartFilter_type") : - getString("_UI_PartFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/ReferenceableObjectItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/ReferenceableObjectItemProvider.java deleted file mode 100644 index c92e0f3b8..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/ReferenceableObjectItemProvider.java +++ /dev/null @@ -1,126 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.ReferenceableObject} object. - * - * - * @generated - */ -public class ReferenceableObjectItemProvider - extends ItemProviderAdapter - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public ReferenceableObjectItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns ReferenceableObject.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/ReferenceableObject")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_ReferenceableObject_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender)adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/StandardFormPageItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/StandardFormPageItemProvider.java deleted file mode 100644 index 2bd81fad2..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/StandardFormPageItemProvider.java +++ /dev/null @@ -1,116 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.extended.editor.StandardFormPage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.StandardFormPage} object. - * - * - * @generated - */ -public class StandardFormPageItemProvider - extends EEFPageItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public StandardFormPageItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns StandardFormPage.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/StandardFormPage")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((StandardFormPage)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_StandardFormPage_type") : - getString("_UI_StandardFormPage_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/StaticEEFEditorContributionItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/StaticEEFEditorContributionItemProvider.java deleted file mode 100644 index 1f9eab0be..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/StaticEEFEditorContributionItemProvider.java +++ /dev/null @@ -1,188 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.extended.editor.EditorFactory; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.filters.FiltersFactory; -import org.eclipse.emf.eef.mapping.provider.AbstractElementBindingItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution} object. - * - * - * @generated - */ -public class StaticEEFEditorContributionItemProvider - extends AbstractElementBindingItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public StaticEEFEditorContributionItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures(Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures.add(EditorPackage.Literals.EEF_EDITOR_CONTRIBUTION__INPUT); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns StaticEEFEditorContribution.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/StaticEEFEditorContribution")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((StaticEEFEditorContribution)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_StaticEEFEditorContribution_type") : - getString("_UI_StaticEEFEditorContribution_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(StaticEEFEditorContribution.class)) { - case EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION__INPUT: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated NOT - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { -// super.collectNewChildDescriptors(newChildDescriptors, object); - newChildDescriptors.add - (createChildParameter - (MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS, - EditorFactory.eINSTANCE.createPartFilter())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS, - FiltersFactory.eINSTANCE.createJavaDeclarationFilter())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS, - FiltersFactory.eINSTANCE.createJavaExpressionFilter())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS, - FiltersFactory.eINSTANCE.createOCLFilter())); - - newChildDescriptors.add - (createChildParameter - (EditorPackage.Literals.EEF_EDITOR_CONTRIBUTION__INPUT, - EditorFactory.eINSTANCE.createAllResourcesRootsRelativeInput())); - - newChildDescriptors.add - (createChildParameter - (EditorPackage.Literals.EEF_EDITOR_CONTRIBUTION__INPUT, - EditorFactory.eINSTANCE.createFirstResourceRootRelativeInput())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/TreeMasterPageItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/TreeMasterPageItemProvider.java deleted file mode 100644 index ef624593a..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/provider/TreeMasterPageItemProvider.java +++ /dev/null @@ -1,149 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.TreeMasterPage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.editor.TreeMasterPage} object. - * - * - * @generated - */ -public class TreeMasterPageItemProvider - extends MasterDetailsPageItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public TreeMasterPageItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addToolbarVisiblePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Toolbar Visible feature. - * - * - * @generated - */ - protected void addToolbarVisiblePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_TreeMasterPage_toolbarVisible_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_TreeMasterPage_toolbarVisible_feature", "_UI_TreeMasterPage_type"), - EditorPackage.Literals.TREE_MASTER_PAGE__TOOLBAR_VISIBLE, - true, - false, - false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns TreeMasterPage.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/TreeMasterPage")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((TreeMasterPage)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_TreeMasterPage_type") : - getString("_UI_TreeMasterPage_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(TreeMasterPage.class)) { - case EditorPackage.TREE_MASTER_PAGE__TOOLBAR_VISIBLE: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/DynamicEEFEditorContributionPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/DynamicEEFEditorContributionPropertiesEditionProvider.java deleted file mode 100644 index 0267523a1..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/DynamicEEFEditorContributionPropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -import org.eclipse.emf.eef.extended.editor.components.DynamicEEFEditorContributionBasePropertiesEditionComponent; -import org.eclipse.emf.eef.extended.editor.components.DynamicEEFEditorContributionPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Goulwen LeFur - * - */ -public class DynamicEEFEditorContributionPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public DynamicEEFEditorContributionPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public DynamicEEFEditorContributionPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof DynamicEEFEditorContribution) - && (EditorPackage.Literals.DYNAMIC_EEF_EDITOR_CONTRIBUTION == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof DynamicEEFEditorContribution) && (DynamicEEFEditorContributionBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof DynamicEEFEditorContribution) && (refinement == DynamicEEFEditorContributionBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof DynamicEEFEditorContribution) && ((DynamicEEFEditorContributionBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == DynamicEEFEditorContributionBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof DynamicEEFEditorContribution) { - return new DynamicEEFEditorContributionPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof DynamicEEFEditorContribution) { - if (DynamicEEFEditorContributionBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new DynamicEEFEditorContributionBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof DynamicEEFEditorContribution) { - if (DynamicEEFEditorContributionBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == DynamicEEFEditorContributionBasePropertiesEditionComponent.class) - return new DynamicEEFEditorContributionBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EditorPackage.Literals.DYNAMIC_EEF_EDITOR_CONTRIBUTION == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFEditorContributionsPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFEditorContributionsPropertiesEditionProvider.java deleted file mode 100644 index e0adc2eee..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFEditorContributionsPropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.EEFEditorContributions; -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -import org.eclipse.emf.eef.extended.editor.components.EEFEditorContributionsBasePropertiesEditionComponent; -import org.eclipse.emf.eef.extended.editor.components.EEFEditorContributionsPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Goulwen LeFur - * - */ -public class EEFEditorContributionsPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public EEFEditorContributionsPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public EEFEditorContributionsPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof EEFEditorContributions) - && (EditorPackage.Literals.EEF_EDITOR_CONTRIBUTIONS == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof EEFEditorContributions) && (EEFEditorContributionsBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EEFEditorContributions) && (refinement == EEFEditorContributionsBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EEFEditorContributions) && ((EEFEditorContributionsBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == EEFEditorContributionsBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof EEFEditorContributions) { - return new EEFEditorContributionsPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof EEFEditorContributions) { - if (EEFEditorContributionsBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new EEFEditorContributionsBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof EEFEditorContributions) { - if (EEFEditorContributionsBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == EEFEditorContributionsBasePropertiesEditionComponent.class) - return new EEFEditorContributionsBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EditorPackage.Literals.EEF_EDITOR_CONTRIBUTIONS == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFEditorPagesPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFEditorPagesPropertiesEditionProvider.java deleted file mode 100644 index d7cb96cea..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFEditorPagesPropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.EEFEditorPages; -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -import org.eclipse.emf.eef.extended.editor.components.EEFEditorPagesBasePropertiesEditionComponent; -import org.eclipse.emf.eef.extended.editor.components.EEFEditorPagesPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Goulwen LeFur - * - */ -public class EEFEditorPagesPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public EEFEditorPagesPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public EEFEditorPagesPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof EEFEditorPages) - && (EditorPackage.Literals.EEF_EDITOR_PAGES == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof EEFEditorPages) && (EEFEditorPagesBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EEFEditorPages) && (refinement == EEFEditorPagesBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EEFEditorPages) && ((EEFEditorPagesBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == EEFEditorPagesBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof EEFEditorPages) { - return new EEFEditorPagesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof EEFEditorPages) { - if (EEFEditorPagesBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new EEFEditorPagesBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof EEFEditorPages) { - if (EEFEditorPagesBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == EEFEditorPagesBasePropertiesEditionComponent.class) - return new EEFEditorPagesBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EditorPackage.Literals.EEF_EDITOR_PAGES == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFMasterPagePropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFMasterPagePropertiesEditionProvider.java deleted file mode 100644 index 113d4f01b..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EEFMasterPagePropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.EEFMasterPage; -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -import org.eclipse.emf.eef.extended.editor.components.EEFMasterPageBasePropertiesEditionComponent; -import org.eclipse.emf.eef.extended.editor.components.EEFMasterPagePropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Goulwen LeFur - * - */ -public class EEFMasterPagePropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public EEFMasterPagePropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public EEFMasterPagePropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof EEFMasterPage) - && (EditorPackage.Literals.EEF_MASTER_PAGE == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof EEFMasterPage) && (EEFMasterPageBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EEFMasterPage) && (refinement == EEFMasterPageBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EEFMasterPage) && ((EEFMasterPageBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == EEFMasterPageBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof EEFMasterPage) { - return new EEFMasterPagePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof EEFMasterPage) { - if (EEFMasterPageBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new EEFMasterPageBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof EEFMasterPage) { - if (EEFMasterPageBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == EEFMasterPageBasePropertiesEditionComponent.class) - return new EEFMasterPageBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EditorPackage.Literals.EEF_MASTER_PAGE == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorEEFAdapterFactory.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorEEFAdapterFactory.java deleted file mode 100644 index 296bfa67d..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorEEFAdapterFactory.java +++ /dev/null @@ -1,109 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.notify.Adapter; - -import org.eclipse.emf.eef.extended.editor.util.EditorAdapterFactory; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -/** - * @author Goulwen LeFur - * - */ -public class EditorEEFAdapterFactory extends EditorAdapterFactory { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.extended.editor.util.EditorAdapterFactory#createStandardFormPageAdapter() - * - */ - public Adapter createStandardFormPageAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new StandardFormPagePropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.extended.editor.util.EditorAdapterFactory#createEEFMasterPageAdapter() - * - */ - public Adapter createEEFMasterPageAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new EEFMasterPagePropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.extended.editor.util.EditorAdapterFactory#createTreeMasterPageAdapter() - * - */ - public Adapter createTreeMasterPageAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new TreeMasterPagePropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.extended.editor.util.EditorAdapterFactory#createPartFilterAdapter() - * - */ - public Adapter createPartFilterAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new PartFilterPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.extended.editor.util.EditorAdapterFactory#createEEFEditorContributionsAdapter() - * - */ - public Adapter createEEFEditorContributionsAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new EEFEditorContributionsPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.extended.editor.util.EditorAdapterFactory#createEEFEditorPagesAdapter() - * - */ - public Adapter createEEFEditorPagesAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new EEFEditorPagesPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.extended.editor.util.EditorAdapterFactory#createStaticEEFEditorContributionAdapter() - * - */ - public Adapter createStaticEEFEditorContributionAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new StaticEEFEditorContributionPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.extended.editor.util.EditorAdapterFactory#createDynamicEEFEditorContributionAdapter() - * - */ - public Adapter createDynamicEEFEditorContributionAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new DynamicEEFEditorContributionPropertiesEditionProvider(providers); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorMessages.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorMessages.java deleted file mode 100644 index 0195df19d..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorMessages.java +++ /dev/null @@ -1,237 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import org.eclipse.osgi.util.NLS; - -/** - * @author Goulwen LeFur - * - */ -public class EditorMessages extends NLS { - - private static final String BUNDLE_NAME = "org.eclipse.emf.eef.extended.editor.providers.editorMessages"; //$NON-NLS-1$ - - - public static String StandardFormPagePropertiesEditionPart_NamingGroupLabel; - - - public static String EEFMasterPagePropertiesEditionPart_NamingGroupLabel; - - - public static String EEFMasterPagePropertiesEditionPart_SettingsGroupLabel; - - - public static String TreeMasterPagePropertiesEditionPart_NamingGroupLabel; - - - public static String TreeMasterPagePropertiesEditionPart_SettingsGroupLabel; - - - public static String PartFilterPropertiesEditionPart_NamingGroupLabel; - - - public static String PartFilterPropertiesEditionPart_FilterGroupLabel; - - - public static String PartFilterPropertiesEditionPart_SettingsGroupLabel; - - - public static String EEFEditorContributionsPropertiesEditionPart_NamingGroupLabel; - - - public static String EEFEditorPagesPropertiesEditionPart_PropertiesGroupLabel; - - - public static String StaticEEFEditorContributionPropertiesEditionPart_NamingGroupLabel; - - - public static String StaticEEFEditorContributionPropertiesEditionPart_BindingGroupLabel; - - - public static String DynamicEEFEditorContributionPropertiesEditionPart_NamingGroupLabel; - - - public static String DynamicEEFEditorContributionPropertiesEditionPart_BindingGroupLabel; - - - - public static String StandardFormPage_ReadOnly; - - - public static String StandardFormPage_Part_Title; - - - public static String EEFMasterPage_ReadOnly; - - - public static String EEFMasterPage_Part_Title; - - - public static String TreeMasterPage_ReadOnly; - - - public static String TreeMasterPage_Part_Title; - - - public static String PartFilter_ReadOnly; - - - public static String PartFilter_Part_Title; - - - public static String EEFEditorContributions_ReadOnly; - - - public static String EEFEditorContributions_Part_Title; - - - public static String EEFEditorPages_ReadOnly; - - - public static String EEFEditorPages_Part_Title; - - - public static String StaticEEFEditorContribution_ReadOnly; - - - public static String StaticEEFEditorContribution_Part_Title; - - - public static String DynamicEEFEditorContribution_ReadOnly; - - - public static String DynamicEEFEditorContribution_Part_Title; - - - - public static String StandardFormPagePropertiesEditionPart_NameLabel; - - - public static String StandardFormPagePropertiesEditionPart_Title_Label; - - - public static String EEFMasterPagePropertiesEditionPart_NameLabel; - - - public static String EEFMasterPagePropertiesEditionPart_Title_Label; - - - public static String EEFMasterPagePropertiesEditionPart_OrientableLabel; - - - public static String EEFMasterPagePropertiesEditionPart_ShowValidatePageLabel; - - - public static String TreeMasterPagePropertiesEditionPart_NameLabel; - - - public static String TreeMasterPagePropertiesEditionPart_Title_Label; - - - public static String TreeMasterPagePropertiesEditionPart_ToolbarVisibleLabel; - - - public static String PartFilterPropertiesEditionPart_NameLabel; - - - public static String PartFilterPropertiesEditionPart_ContextualComponentLabel; - - - public static String PartFilterPropertiesEditionPart_FilteredPartLabel; - - - public static String PartFilterPropertiesEditionPart_MandatoryLabel; - - - public static String EEFEditorContributionsPropertiesEditionPart_NameLabel; - - - public static String EEFEditorPagesPropertiesEditionPart_NameLabel; - - - public static String StaticEEFEditorContributionPropertiesEditionPart_NameLabel; - - - public static String StaticEEFEditorContributionPropertiesEditionPart_ViewsLabel; - - - public static String DynamicEEFEditorContributionPropertiesEditionPart_NameLabel; - - - public static String DynamicEEFEditorContributionPropertiesEditionPart_ModelLabel; - - - public static String DynamicEEFEditorContributionPropertiesEditionPart_ViewsLabel; - - - - public static String PropertiesEditionPart_DocumentationLabel; - - - public static String PropertiesEditionPart_IntegerValueMessage; - - - public static String PropertiesEditionPart_FloatValueMessage; - - - public static String PropertiesEditionPart_ShortValueMessage; - - - public static String PropertiesEditionPart_LongValueMessage; - - - public static String PropertiesEditionPart_ByteValueMessage; - - - public static String PropertiesEditionPart_BigIntegerValueMessage; - - - public static String PropertiesEditionPart_BigDecimalValueMessage; - - - public static String PropertiesEditionPart_DoubleValueMessage; - - - public static String PropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesEditionPart_RequiredFeatureMessage; - - - public static String PropertiesEditionPart_AddTableViewerLabel; - - - public static String PropertiesEditionPart_EditTableViewerLabel; - - - public static String PropertiesEditionPart_RemoveTableViewerLabel; - - - public static String PropertiesEditionPart_AddListViewerLabel; - - - public static String PropertiesEditionPart_RemoveListViewerLabel; - - // Start of user code for additionnal NLS Constants - -// End of user code - - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, EditorMessages.class); - } - - - private EditorMessages() { - //protect instanciation - } -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorPropertiesEditionPartProvider.java deleted file mode 100644 index 76de60834..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/EditorPropertiesEditionPartProvider.java +++ /dev/null @@ -1,111 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import org.eclipse.emf.eef.extended.editor.parts.EditorViewsRepository; - -import org.eclipse.emf.eef.extended.editor.parts.forms.DynamicEEFEditorContributionPropertiesEditionPartForm; -import org.eclipse.emf.eef.extended.editor.parts.forms.EEFEditorContributionsPropertiesEditionPartForm; -import org.eclipse.emf.eef.extended.editor.parts.forms.EEFEditorPagesPropertiesEditionPartForm; -import org.eclipse.emf.eef.extended.editor.parts.forms.EEFMasterPagePropertiesEditionPartForm; -import org.eclipse.emf.eef.extended.editor.parts.forms.PartFilterPropertiesEditionPartForm; -import org.eclipse.emf.eef.extended.editor.parts.forms.StandardFormPagePropertiesEditionPartForm; -import org.eclipse.emf.eef.extended.editor.parts.forms.StaticEEFEditorContributionPropertiesEditionPartForm; -import org.eclipse.emf.eef.extended.editor.parts.forms.TreeMasterPagePropertiesEditionPartForm; - -import org.eclipse.emf.eef.extended.editor.parts.impl.DynamicEEFEditorContributionPropertiesEditionPartImpl; -import org.eclipse.emf.eef.extended.editor.parts.impl.EEFEditorContributionsPropertiesEditionPartImpl; -import org.eclipse.emf.eef.extended.editor.parts.impl.EEFEditorPagesPropertiesEditionPartImpl; -import org.eclipse.emf.eef.extended.editor.parts.impl.EEFMasterPagePropertiesEditionPartImpl; -import org.eclipse.emf.eef.extended.editor.parts.impl.PartFilterPropertiesEditionPartImpl; -import org.eclipse.emf.eef.extended.editor.parts.impl.StandardFormPagePropertiesEditionPartImpl; -import org.eclipse.emf.eef.extended.editor.parts.impl.StaticEEFEditorContributionPropertiesEditionPartImpl; -import org.eclipse.emf.eef.extended.editor.parts.impl.TreeMasterPagePropertiesEditionPartImpl; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; - -/** - * @author Goulwen LeFur - * - */ -public class EditorPropertiesEditionPartProvider implements IPropertiesEditionPartProvider { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#provides(java.lang.Object) - * - */ - public boolean provides(Object key) { - return key == EditorViewsRepository.class; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#getPropertiesEditionPart(java.lang.Object, int, org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, IPropertiesEditionComponent component) { - if (key == EditorViewsRepository.StandardFormPage.class) { - if (kind == EditorViewsRepository.SWT_KIND) - return new StandardFormPagePropertiesEditionPartImpl(component); - if (kind == EditorViewsRepository.FORM_KIND) - return new StandardFormPagePropertiesEditionPartForm(component); - } - if (key == EditorViewsRepository.EEFMasterPage.class) { - if (kind == EditorViewsRepository.SWT_KIND) - return new EEFMasterPagePropertiesEditionPartImpl(component); - if (kind == EditorViewsRepository.FORM_KIND) - return new EEFMasterPagePropertiesEditionPartForm(component); - } - if (key == EditorViewsRepository.TreeMasterPage.class) { - if (kind == EditorViewsRepository.SWT_KIND) - return new TreeMasterPagePropertiesEditionPartImpl(component); - if (kind == EditorViewsRepository.FORM_KIND) - return new TreeMasterPagePropertiesEditionPartForm(component); - } - if (key == EditorViewsRepository.PartFilter.class) { - if (kind == EditorViewsRepository.SWT_KIND) - return new PartFilterPropertiesEditionPartImpl(component); - if (kind == EditorViewsRepository.FORM_KIND) - return new PartFilterPropertiesEditionPartForm(component); - } - if (key == EditorViewsRepository.EEFEditorContributions.class) { - if (kind == EditorViewsRepository.SWT_KIND) - return new EEFEditorContributionsPropertiesEditionPartImpl(component); - if (kind == EditorViewsRepository.FORM_KIND) - return new EEFEditorContributionsPropertiesEditionPartForm(component); - } - if (key == EditorViewsRepository.EEFEditorPages.class) { - if (kind == EditorViewsRepository.SWT_KIND) - return new EEFEditorPagesPropertiesEditionPartImpl(component); - if (kind == EditorViewsRepository.FORM_KIND) - return new EEFEditorPagesPropertiesEditionPartForm(component); - } - if (key == EditorViewsRepository.StaticEEFEditorContribution.class) { - if (kind == EditorViewsRepository.SWT_KIND) - return new StaticEEFEditorContributionPropertiesEditionPartImpl(component); - if (kind == EditorViewsRepository.FORM_KIND) - return new StaticEEFEditorContributionPropertiesEditionPartForm(component); - } - if (key == EditorViewsRepository.DynamicEEFEditorContribution.class) { - if (kind == EditorViewsRepository.SWT_KIND) - return new DynamicEEFEditorContributionPropertiesEditionPartImpl(component); - if (kind == EditorViewsRepository.FORM_KIND) - return new DynamicEEFEditorContributionPropertiesEditionPartForm(component); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/PartFilterPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/PartFilterPropertiesEditionProvider.java deleted file mode 100644 index 3371345d3..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/PartFilterPropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.PartFilter; - -import org.eclipse.emf.eef.extended.editor.components.PartFilterBasePropertiesEditionComponent; -import org.eclipse.emf.eef.extended.editor.components.PartFilterPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Goulwen LeFur - * - */ -public class PartFilterPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public PartFilterPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public PartFilterPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof PartFilter) - && (EditorPackage.Literals.PART_FILTER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof PartFilter) && (PartFilterBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof PartFilter) && (refinement == PartFilterBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof PartFilter) && ((PartFilterBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == PartFilterBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof PartFilter) { - return new PartFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof PartFilter) { - if (PartFilterBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new PartFilterBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof PartFilter) { - if (PartFilterBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == PartFilterBasePropertiesEditionComponent.class) - return new PartFilterBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EditorPackage.Literals.PART_FILTER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/StandardFormPagePropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/StandardFormPagePropertiesEditionProvider.java deleted file mode 100644 index 07f7067d9..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/StandardFormPagePropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.StandardFormPage; - -import org.eclipse.emf.eef.extended.editor.components.StandardFormPageBasePropertiesEditionComponent; -import org.eclipse.emf.eef.extended.editor.components.StandardFormPagePropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Goulwen LeFur - * - */ -public class StandardFormPagePropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public StandardFormPagePropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public StandardFormPagePropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof StandardFormPage) - && (EditorPackage.Literals.STANDARD_FORM_PAGE == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof StandardFormPage) && (StandardFormPageBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof StandardFormPage) && (refinement == StandardFormPageBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof StandardFormPage) && ((StandardFormPageBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == StandardFormPageBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof StandardFormPage) { - return new StandardFormPagePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof StandardFormPage) { - if (StandardFormPageBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new StandardFormPageBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof StandardFormPage) { - if (StandardFormPageBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == StandardFormPageBasePropertiesEditionComponent.class) - return new StandardFormPageBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EditorPackage.Literals.STANDARD_FORM_PAGE == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/StaticEEFEditorContributionPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/StaticEEFEditorContributionPropertiesEditionProvider.java deleted file mode 100644 index bc2fe1afc..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/StaticEEFEditorContributionPropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution; - -import org.eclipse.emf.eef.extended.editor.components.StaticEEFEditorContributionBasePropertiesEditionComponent; -import org.eclipse.emf.eef.extended.editor.components.StaticEEFEditorContributionPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Goulwen LeFur - * - */ -public class StaticEEFEditorContributionPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public StaticEEFEditorContributionPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public StaticEEFEditorContributionPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof StaticEEFEditorContribution) - && (EditorPackage.Literals.STATIC_EEF_EDITOR_CONTRIBUTION == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof StaticEEFEditorContribution) && (StaticEEFEditorContributionBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof StaticEEFEditorContribution) && (refinement == StaticEEFEditorContributionBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof StaticEEFEditorContribution) && ((StaticEEFEditorContributionBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == StaticEEFEditorContributionBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof StaticEEFEditorContribution) { - return new StaticEEFEditorContributionPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof StaticEEFEditorContribution) { - if (StaticEEFEditorContributionBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new StaticEEFEditorContributionBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof StaticEEFEditorContribution) { - if (StaticEEFEditorContributionBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == StaticEEFEditorContributionBasePropertiesEditionComponent.class) - return new StaticEEFEditorContributionBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EditorPackage.Literals.STATIC_EEF_EDITOR_CONTRIBUTION == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/TreeMasterPagePropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/TreeMasterPagePropertiesEditionProvider.java deleted file mode 100644 index fde51243f..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/TreeMasterPagePropertiesEditionProvider.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.TreeMasterPage; - -import org.eclipse.emf.eef.extended.editor.components.TreeMasterPageBasePropertiesEditionComponent; -import org.eclipse.emf.eef.extended.editor.components.TreeMasterPagePropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.emf.eef.views.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Goulwen LeFur - * - */ -public class TreeMasterPagePropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public TreeMasterPagePropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public TreeMasterPagePropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof TreeMasterPage) - && (EditorPackage.Literals.TREE_MASTER_PAGE == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof TreeMasterPage) && (TreeMasterPageBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof TreeMasterPage) && (refinement == TreeMasterPageBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof TreeMasterPage) && ((TreeMasterPageBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == TreeMasterPageBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof TreeMasterPage) { - return new TreeMasterPagePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof TreeMasterPage) { - if (TreeMasterPageBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new TreeMasterPageBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof TreeMasterPage) { - if (TreeMasterPageBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == TreeMasterPageBasePropertiesEditionComponent.class) - return new TreeMasterPageBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EditorPackage.Literals.TREE_MASTER_PAGE == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/editorMessages.properties b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/editorMessages.properties deleted file mode 100644 index 4612e1737..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/editorMessages.properties +++ /dev/null @@ -1,82 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -StandardFormPagePropertiesEditionPart_NamingGroupLabel=Naming -EEFMasterPagePropertiesEditionPart_NamingGroupLabel=Naming -EEFMasterPagePropertiesEditionPart_SettingsGroupLabel=Settings -TreeMasterPagePropertiesEditionPart_NamingGroupLabel=Naming -TreeMasterPagePropertiesEditionPart_SettingsGroupLabel=Settings -PartFilterPropertiesEditionPart_NamingGroupLabel=Naming -PartFilterPropertiesEditionPart_FilterGroupLabel=Filter -PartFilterPropertiesEditionPart_SettingsGroupLabel=Settings -EEFEditorContributionsPropertiesEditionPart_NamingGroupLabel=Naming -EEFEditorPagesPropertiesEditionPart_PropertiesGroupLabel=Properties -StaticEEFEditorContributionPropertiesEditionPart_NamingGroupLabel=Naming -StaticEEFEditorContributionPropertiesEditionPart_BindingGroupLabel=Binding -DynamicEEFEditorContributionPropertiesEditionPart_NamingGroupLabel=Naming -DynamicEEFEditorContributionPropertiesEditionPart_BindingGroupLabel=Binding -StandardFormPage_ReadOnly=This property is read only -StandardFormPage_Part_Title=StandardFormPage -EEFMasterPage_ReadOnly=This property is read only -EEFMasterPage_Part_Title=EEFMasterPage -TreeMasterPage_ReadOnly=This property is read only -TreeMasterPage_Part_Title=TreeMasterPage -PartFilter_ReadOnly=This property is read only -PartFilter_Part_Title=PartFilter -EEFEditorContributions_ReadOnly=This property is read only -EEFEditorContributions_Part_Title=EEFEditorContributions -EEFEditorPages_ReadOnly=This property is read only -EEFEditorPages_Part_Title=EEFEditorPages -StaticEEFEditorContribution_ReadOnly=This property is read only -StaticEEFEditorContribution_Part_Title=StaticEEFEditorContribution -DynamicEEFEditorContribution_ReadOnly=This property is read only -DynamicEEFEditorContribution_Part_Title=DynamicEEFEditorContribution -StandardFormPagePropertiesEditionPart_NameLabel=Name : -StandardFormPagePropertiesEditionPart_Title_Label=Title : -EEFMasterPagePropertiesEditionPart_NameLabel=Name : -EEFMasterPagePropertiesEditionPart_Title_Label=Title : -EEFMasterPagePropertiesEditionPart_OrientableLabel=Orientable -EEFMasterPagePropertiesEditionPart_ShowValidatePageLabel=ShowValidatePage -TreeMasterPagePropertiesEditionPart_NameLabel=Name : -TreeMasterPagePropertiesEditionPart_Title_Label=Title : -TreeMasterPagePropertiesEditionPart_ToolbarVisibleLabel=ToolbarVisible -PartFilterPropertiesEditionPart_NameLabel=Name : -PartFilterPropertiesEditionPart_ContextualComponentLabel=ContextualComponent : -PartFilterPropertiesEditionPart_FilteredPartLabel=FilteredPart : -PartFilterPropertiesEditionPart_MandatoryLabel=Mandatory -EEFEditorContributionsPropertiesEditionPart_NameLabel=Name : -EEFEditorPagesPropertiesEditionPart_NameLabel=Name : -StaticEEFEditorContributionPropertiesEditionPart_NameLabel=Name : -StaticEEFEditorContributionPropertiesEditionPart_ViewsLabel=Views : -DynamicEEFEditorContributionPropertiesEditionPart_NameLabel=Name : -DynamicEEFEditorContributionPropertiesEditionPart_ModelLabel=Model : -DynamicEEFEditorContributionPropertiesEditionPart_ViewsLabel=Views : -PropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionPart_EditTableViewerLabel=Edit -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=The property {0} of the object shall be filled -PropertiesEditionPart_RemoveTableViewerLabel=Delete -PropertiesEditionPart_RemoveListViewerLabel=Delete -PropertiesEditionPart_IntegerValueMessage=The property {0} shall be an integer -PropertiesEditionPart_FloatValueMessage=The property {0} shall be a float -PropertiesEditionPart_ShortValueMessage=The property {0} shall be a short -PropertiesEditionPart_DoubleValueMessage=The property {0} shall be a double -PropertiesEditionPart_ByteValueMessage=The property {0} shall be a byte -PropertiesEditionPart_LongValueMessage=The property {0} shall be a long -PropertiesEditionPart_BigIntegerValueMessage=The property {0} shall be a BigInteger -PropertiesEditionPart_BigDecimalValueMessage=The property {0} shall be a BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Add -PropertiesEditionPart_AddListViewerLabel=Add diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/editorMessages_fr.properties b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/editorMessages_fr.properties deleted file mode 100644 index bbd7775ce..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/providers/editorMessages_fr.properties +++ /dev/null @@ -1,82 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -StandardFormPagePropertiesEditionPart_NamingGroupLabel=Naming -EEFMasterPagePropertiesEditionPart_NamingGroupLabel=Naming -EEFMasterPagePropertiesEditionPart_SettingsGroupLabel=Settings -TreeMasterPagePropertiesEditionPart_NamingGroupLabel=Naming -TreeMasterPagePropertiesEditionPart_SettingsGroupLabel=Settings -PartFilterPropertiesEditionPart_NamingGroupLabel=Naming -PartFilterPropertiesEditionPart_FilterGroupLabel=Filter -PartFilterPropertiesEditionPart_SettingsGroupLabel=Settings -EEFEditorContributionsPropertiesEditionPart_NamingGroupLabel=Naming -EEFEditorPagesPropertiesEditionPart_PropertiesGroupLabel=Properties -StaticEEFEditorContributionPropertiesEditionPart_NamingGroupLabel=Naming -StaticEEFEditorContributionPropertiesEditionPart_BindingGroupLabel=Binding -DynamicEEFEditorContributionPropertiesEditionPart_NamingGroupLabel=Naming -DynamicEEFEditorContributionPropertiesEditionPart_BindingGroupLabel=Binding -StandardFormPage_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -StandardFormPage_Part_Title=StandardFormPage -EEFMasterPage_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -EEFMasterPage_Part_Title=EEFMasterPage -TreeMasterPage_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -TreeMasterPage_Part_Title=TreeMasterPage -PartFilter_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -PartFilter_Part_Title=PartFilter -EEFEditorContributions_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -EEFEditorContributions_Part_Title=EEFEditorContributions -EEFEditorPages_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -EEFEditorPages_Part_Title=EEFEditorPages -StaticEEFEditorContribution_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -StaticEEFEditorContribution_Part_Title=StaticEEFEditorContribution -DynamicEEFEditorContribution_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -DynamicEEFEditorContribution_Part_Title=DynamicEEFEditorContribution -StandardFormPagePropertiesEditionPart_NameLabel=Name : -StandardFormPagePropertiesEditionPart_Title_Label=Title : -EEFMasterPagePropertiesEditionPart_NameLabel=Name : -EEFMasterPagePropertiesEditionPart_Title_Label=Title : -EEFMasterPagePropertiesEditionPart_OrientableLabel=Orientable -EEFMasterPagePropertiesEditionPart_ShowValidatePageLabel=ShowValidatePage -TreeMasterPagePropertiesEditionPart_NameLabel=Name : -TreeMasterPagePropertiesEditionPart_Title_Label=Title : -TreeMasterPagePropertiesEditionPart_ToolbarVisibleLabel=ToolbarVisible -PartFilterPropertiesEditionPart_NameLabel=Name : -PartFilterPropertiesEditionPart_ContextualComponentLabel=ContextualComponent : -PartFilterPropertiesEditionPart_FilteredPartLabel=FilteredPart : -PartFilterPropertiesEditionPart_MandatoryLabel=Mandatory -EEFEditorContributionsPropertiesEditionPart_NameLabel=Name : -EEFEditorPagesPropertiesEditionPart_NameLabel=Name : -StaticEEFEditorContributionPropertiesEditionPart_NameLabel=Name : -StaticEEFEditorContributionPropertiesEditionPart_ViewsLabel=Views : -DynamicEEFEditorContributionPropertiesEditionPart_NameLabel=Name : -DynamicEEFEditorContributionPropertiesEditionPart_ModelLabel=Model : -DynamicEEFEditorContributionPropertiesEditionPart_ViewsLabel=Views : -PropertiesEditionPart_PropertiesGroupLabel=Propri\u00E9t\u00E9s -PropertiesEditionPart_EditTableViewerLabel=Editer -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=La propri\u00E9t\u00E9 {0} de l\u0027objet doit \u00EAtre renseign\u00E9e -PropertiesEditionPart_RemoveTableViewerLabel=Supprimer -PropertiesEditionPart_RemoveListViewerLabel=Supprimer -PropertiesEditionPart_IntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un entier -PropertiesEditionPart_FloatValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un flottant -PropertiesEditionPart_ShortValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un short -PropertiesEditionPart_DoubleValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un double -PropertiesEditionPart_ByteValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un byte -PropertiesEditionPart_LongValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un long -PropertiesEditionPart_BigIntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigInteger -PropertiesEditionPart_BigDecimalValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Ajouter -PropertiesEditionPart_AddListViewerLabel=Ajouter diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/util/EditorAdapterFactory.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/util/EditorAdapterFactory.java deleted file mode 100644 index 6877bf1a8..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/util/EditorAdapterFactory.java +++ /dev/null @@ -1,600 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.util; - - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput; -import org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFEditorContributions; -import org.eclipse.emf.eef.extended.editor.EEFEditorPages; -import org.eclipse.emf.eef.extended.editor.EEFMasterPage; -import org.eclipse.emf.eef.extended.editor.EEFPage; -import org.eclipse.emf.eef.extended.editor.EEFPageInput; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput; -import org.eclipse.emf.eef.extended.editor.MasterDetailsPage; -import org.eclipse.emf.eef.extended.editor.PartFilter; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.extended.editor.StandardFormPage; -import org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.TreeMasterPage; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.views.Container; -import org.eclipse.emf.eef.views.DocumentedElement; -import org.eclipse.emf.eef.views.IdentifiedElement; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewElement; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage - * @generated - */ -public class EditorAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static EditorPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public EditorAdapterFactory() { - if (modelPackage == null) { - modelPackage = EditorPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject)object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected EditorSwitch modelSwitch = - new EditorSwitch() { - @Override - public Adapter caseEEFEditorContribution(EEFEditorContribution object) { - return createEEFEditorContributionAdapter(); - } - @Override - public Adapter caseEEFPage(EEFPage object) { - return createEEFPageAdapter(); - } - @Override - public Adapter caseStandardFormPage(StandardFormPage object) { - return createStandardFormPageAdapter(); - } - @Override - public Adapter caseMasterDetailsPage(MasterDetailsPage object) { - return createMasterDetailsPageAdapter(); - } - @Override - public Adapter caseEEFMasterPage(EEFMasterPage object) { - return createEEFMasterPageAdapter(); - } - @Override - public Adapter caseTreeMasterPage(TreeMasterPage object) { - return createTreeMasterPageAdapter(); - } - @Override - public Adapter caseEEFPageInput(EEFPageInput object) { - return createEEFPageInputAdapter(); - } - @Override - public Adapter caseAllResourcesRootsRelativeInput(AllResourcesRootsRelativeInput object) { - return createAllResourcesRootsRelativeInputAdapter(); - } - @Override - public Adapter caseFirstResourceRootRelativeInput(FirstResourceRootRelativeInput object) { - return createFirstResourceRootRelativeInputAdapter(); - } - @Override - public Adapter casePartFilter(PartFilter object) { - return createPartFilterAdapter(); - } - @Override - public Adapter caseEEFEditorContributions(EEFEditorContributions object) { - return createEEFEditorContributionsAdapter(); - } - @Override - public Adapter caseEEFEditorPages(EEFEditorPages object) { - return createEEFEditorPagesAdapter(); - } - @Override - public Adapter caseStaticEEFEditorContribution(StaticEEFEditorContribution object) { - return createStaticEEFEditorContributionAdapter(); - } - @Override - public Adapter caseDynamicEEFEditorContribution(DynamicEEFEditorContribution object) { - return createDynamicEEFEditorContributionAdapter(); - } - @Override - public Adapter caseReferenceableObject(ReferenceableObject object) { - return createReferenceableObjectAdapter(); - } - @Override - public Adapter caseDocumentedElement(DocumentedElement object) { - return createDocumentedElementAdapter(); - } - @Override - public Adapter caseViewElement(ViewElement object) { - return createViewElementAdapter(); - } - @Override - public Adapter caseIdentifiedElement(IdentifiedElement object) { - return createIdentifiedElementAdapter(); - } - @Override - public Adapter caseContainer(Container object) { - return createContainerAdapter(); - } - @Override - public Adapter caseView(View object) { - return createViewAdapter(); - } - @Override - public Adapter caseMapping_DocumentedElement(org.eclipse.emf.eef.mapping.DocumentedElement object) { - return createMapping_DocumentedElementAdapter(); - } - @Override - public Adapter caseBindingFilter(BindingFilter object) { - return createBindingFilterAdapter(); - } - @Override - public Adapter caseCategory(Category object) { - return createCategoryAdapter(); - } - @Override - public Adapter caseViews_Category(org.eclipse.emf.eef.views.Category object) { - return createViews_CategoryAdapter(); - } - @Override - public Adapter caseAbstractElementBinding(AbstractElementBinding object) { - return createAbstractElementBindingAdapter(); - } - @Override - public Adapter caseEMFElementBinding(EMFElementBinding object) { - return createEMFElementBindingAdapter(); - } - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject)target); - } - - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.EEFEditorContribution EEF Editor Contribution}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.EEFEditorContribution - * @generated - */ - public Adapter createEEFEditorContributionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.EEFPage EEF Page}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.EEFPage - * @generated - */ - public Adapter createEEFPageAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.StandardFormPage Standard Form Page}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.StandardFormPage - * @generated - */ - public Adapter createStandardFormPageAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.MasterDetailsPage Master Details Page}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.MasterDetailsPage - * @generated - */ - public Adapter createMasterDetailsPageAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.EEFMasterPage EEF Master Page}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.EEFMasterPage - * @generated - */ - public Adapter createEEFMasterPageAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.TreeMasterPage Tree Master Page}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.TreeMasterPage - * @generated - */ - public Adapter createTreeMasterPageAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.EEFPageInput EEF Page Input}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.EEFPageInput - * @generated - */ - public Adapter createEEFPageInputAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput All Resources Roots Relative Input}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput - * @generated - */ - public Adapter createAllResourcesRootsRelativeInputAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput First Resource Root Relative Input}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput - * @generated - */ - public Adapter createFirstResourceRootRelativeInputAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.PartFilter Part Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.PartFilter - * @generated - */ - public Adapter createPartFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.EEFEditorContributions EEF Editor Contributions}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.EEFEditorContributions - * @generated - */ - public Adapter createEEFEditorContributionsAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.EEFEditorPages EEF Editor Pages}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.EEFEditorPages - * @generated - */ - public Adapter createEEFEditorPagesAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution Static EEF Editor Contribution}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution - * @generated - */ - public Adapter createStaticEEFEditorContributionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution Dynamic EEF Editor Contribution}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution - * @generated - */ - public Adapter createDynamicEEFEditorContributionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.ReferenceableObject Referenceable Object}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.ReferenceableObject - * @generated - */ - public Adapter createReferenceableObjectAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.views.DocumentedElement Documented Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.views.DocumentedElement - * @generated - */ - public Adapter createDocumentedElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.views.ViewElement View Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.views.ViewElement - * @generated - */ - public Adapter createViewElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.views.IdentifiedElement Identified Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.views.IdentifiedElement - * @generated - */ - public Adapter createIdentifiedElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.views.Container Container}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.views.Container - * @generated - */ - public Adapter createContainerAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.views.View View}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.views.View - * @generated - */ - public Adapter createViewAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.DocumentedElement Documented Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.DocumentedElement - * @generated - */ - public Adapter createMapping_DocumentedElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.BindingFilter Binding Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.BindingFilter - * @generated - */ - public Adapter createBindingFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.Category Category}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.Category - * @generated - */ - public Adapter createCategoryAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.views.Category Category}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.views.Category - * @generated - */ - public Adapter createViews_CategoryAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding Abstract Element Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding - * @generated - */ - public Adapter createAbstractElementBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.EMFElementBinding EMF Element Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.EMFElementBinding - * @generated - */ - public Adapter createEMFElementBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //EditorAdapterFactory \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/util/EditorSwitch.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/util/EditorSwitch.java deleted file mode 100644 index 4b8d4b5b5..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/editor/util/EditorSwitch.java +++ /dev/null @@ -1,662 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.editor.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.extended.editor.AllResourcesRootsRelativeInput; -import org.eclipse.emf.eef.extended.editor.DynamicEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.EEFEditorContributions; -import org.eclipse.emf.eef.extended.editor.EEFEditorPages; -import org.eclipse.emf.eef.extended.editor.EEFMasterPage; -import org.eclipse.emf.eef.extended.editor.EEFPage; -import org.eclipse.emf.eef.extended.editor.EEFPageInput; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.FirstResourceRootRelativeInput; -import org.eclipse.emf.eef.extended.editor.MasterDetailsPage; -import org.eclipse.emf.eef.extended.editor.PartFilter; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.extended.editor.StandardFormPage; -import org.eclipse.emf.eef.extended.editor.StaticEEFEditorContribution; -import org.eclipse.emf.eef.extended.editor.TreeMasterPage; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.views.Container; -import org.eclipse.emf.eef.views.DocumentedElement; -import org.eclipse.emf.eef.views.IdentifiedElement; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewElement; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.extended.editor.EditorPackage - * @generated - */ -public class EditorSwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static EditorPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public EditorSwitch() { - if (modelPackage == null) { - modelPackage = EditorPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } - else { - List eSuperTypes = theEClass.getESuperTypes(); - return - eSuperTypes.isEmpty() ? - defaultCase(theEObject) : - doSwitch(eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case EditorPackage.EEF_EDITOR_CONTRIBUTION: { - EEFEditorContribution eefEditorContribution = (EEFEditorContribution)theEObject; - T result = caseEEFEditorContribution(eefEditorContribution); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.EEF_PAGE: { - EEFPage eefPage = (EEFPage)theEObject; - T result = caseEEFPage(eefPage); - if (result == null) result = caseView(eefPage); - if (result == null) result = caseContainer(eefPage); - if (result == null) result = caseViewElement(eefPage); - if (result == null) result = caseIdentifiedElement(eefPage); - if (result == null) result = caseDocumentedElement(eefPage); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.STANDARD_FORM_PAGE: { - StandardFormPage standardFormPage = (StandardFormPage)theEObject; - T result = caseStandardFormPage(standardFormPage); - if (result == null) result = caseEEFPage(standardFormPage); - if (result == null) result = caseView(standardFormPage); - if (result == null) result = caseContainer(standardFormPage); - if (result == null) result = caseViewElement(standardFormPage); - if (result == null) result = caseIdentifiedElement(standardFormPage); - if (result == null) result = caseDocumentedElement(standardFormPage); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.MASTER_DETAILS_PAGE: { - MasterDetailsPage masterDetailsPage = (MasterDetailsPage)theEObject; - T result = caseMasterDetailsPage(masterDetailsPage); - if (result == null) result = caseEEFPage(masterDetailsPage); - if (result == null) result = caseView(masterDetailsPage); - if (result == null) result = caseContainer(masterDetailsPage); - if (result == null) result = caseViewElement(masterDetailsPage); - if (result == null) result = caseIdentifiedElement(masterDetailsPage); - if (result == null) result = caseDocumentedElement(masterDetailsPage); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.EEF_MASTER_PAGE: { - EEFMasterPage eefMasterPage = (EEFMasterPage)theEObject; - T result = caseEEFMasterPage(eefMasterPage); - if (result == null) result = caseMasterDetailsPage(eefMasterPage); - if (result == null) result = caseEEFPage(eefMasterPage); - if (result == null) result = caseView(eefMasterPage); - if (result == null) result = caseContainer(eefMasterPage); - if (result == null) result = caseViewElement(eefMasterPage); - if (result == null) result = caseIdentifiedElement(eefMasterPage); - if (result == null) result = caseDocumentedElement(eefMasterPage); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.TREE_MASTER_PAGE: { - TreeMasterPage treeMasterPage = (TreeMasterPage)theEObject; - T result = caseTreeMasterPage(treeMasterPage); - if (result == null) result = caseMasterDetailsPage(treeMasterPage); - if (result == null) result = caseEEFPage(treeMasterPage); - if (result == null) result = caseView(treeMasterPage); - if (result == null) result = caseContainer(treeMasterPage); - if (result == null) result = caseViewElement(treeMasterPage); - if (result == null) result = caseIdentifiedElement(treeMasterPage); - if (result == null) result = caseDocumentedElement(treeMasterPage); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.EEF_PAGE_INPUT: { - EEFPageInput eefPageInput = (EEFPageInput)theEObject; - T result = caseEEFPageInput(eefPageInput); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.ALL_RESOURCES_ROOTS_RELATIVE_INPUT: { - AllResourcesRootsRelativeInput allResourcesRootsRelativeInput = (AllResourcesRootsRelativeInput)theEObject; - T result = caseAllResourcesRootsRelativeInput(allResourcesRootsRelativeInput); - if (result == null) result = caseEEFPageInput(allResourcesRootsRelativeInput); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.FIRST_RESOURCE_ROOT_RELATIVE_INPUT: { - FirstResourceRootRelativeInput firstResourceRootRelativeInput = (FirstResourceRootRelativeInput)theEObject; - T result = caseFirstResourceRootRelativeInput(firstResourceRootRelativeInput); - if (result == null) result = caseEEFPageInput(firstResourceRootRelativeInput); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.PART_FILTER: { - PartFilter partFilter = (PartFilter)theEObject; - T result = casePartFilter(partFilter); - if (result == null) result = caseBindingFilter(partFilter); - if (result == null) result = caseMapping_DocumentedElement(partFilter); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.EEF_EDITOR_CONTRIBUTIONS: { - EEFEditorContributions eefEditorContributions = (EEFEditorContributions)theEObject; - T result = caseEEFEditorContributions(eefEditorContributions); - if (result == null) result = caseCategory(eefEditorContributions); - if (result == null) result = caseMapping_DocumentedElement(eefEditorContributions); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.EEF_EDITOR_PAGES: { - EEFEditorPages eefEditorPages = (EEFEditorPages)theEObject; - T result = caseEEFEditorPages(eefEditorPages); - if (result == null) result = caseViews_Category(eefEditorPages); - if (result == null) result = caseDocumentedElement(eefEditorPages); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.STATIC_EEF_EDITOR_CONTRIBUTION: { - StaticEEFEditorContribution staticEEFEditorContribution = (StaticEEFEditorContribution)theEObject; - T result = caseStaticEEFEditorContribution(staticEEFEditorContribution); - if (result == null) result = caseAbstractElementBinding(staticEEFEditorContribution); - if (result == null) result = caseEEFEditorContribution(staticEEFEditorContribution); - if (result == null) result = caseMapping_DocumentedElement(staticEEFEditorContribution); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.DYNAMIC_EEF_EDITOR_CONTRIBUTION: { - DynamicEEFEditorContribution dynamicEEFEditorContribution = (DynamicEEFEditorContribution)theEObject; - T result = caseDynamicEEFEditorContribution(dynamicEEFEditorContribution); - if (result == null) result = caseEMFElementBinding(dynamicEEFEditorContribution); - if (result == null) result = caseEEFEditorContribution(dynamicEEFEditorContribution); - if (result == null) result = caseAbstractElementBinding(dynamicEEFEditorContribution); - if (result == null) result = caseMapping_DocumentedElement(dynamicEEFEditorContribution); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EditorPackage.REFERENCEABLE_OBJECT: { - ReferenceableObject referenceableObject = (ReferenceableObject)theEObject; - T result = caseReferenceableObject(referenceableObject); - if (result == null) result = defaultCase(theEObject); - return result; - } - default: return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'EEF Editor Contribution'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EEF Editor Contribution'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFEditorContribution(EEFEditorContribution object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EEF Page'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EEF Page'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFPage(EEFPage object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Standard Form Page'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Standard Form Page'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseStandardFormPage(StandardFormPage object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Master Details Page'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Master Details Page'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseMasterDetailsPage(MasterDetailsPage object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EEF Master Page'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EEF Master Page'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFMasterPage(EEFMasterPage object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Tree Master Page'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Tree Master Page'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseTreeMasterPage(TreeMasterPage object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EEF Page Input'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EEF Page Input'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFPageInput(EEFPageInput object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'All Resources Roots Relative Input'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'All Resources Roots Relative Input'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAllResourcesRootsRelativeInput(AllResourcesRootsRelativeInput object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'First Resource Root Relative Input'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'First Resource Root Relative Input'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseFirstResourceRootRelativeInput(FirstResourceRootRelativeInput object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Part Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Part Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T casePartFilter(PartFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EEF Editor Contributions'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EEF Editor Contributions'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFEditorContributions(EEFEditorContributions object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EEF Editor Pages'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EEF Editor Pages'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFEditorPages(EEFEditorPages object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Static EEF Editor Contribution'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Static EEF Editor Contribution'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseStaticEEFEditorContribution(StaticEEFEditorContribution object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Dynamic EEF Editor Contribution'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Dynamic EEF Editor Contribution'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDynamicEEFEditorContribution(DynamicEEFEditorContribution object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Referenceable Object'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Referenceable Object'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseReferenceableObject(ReferenceableObject object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Documented Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Documented Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDocumentedElement(DocumentedElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'View Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'View Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseViewElement(ViewElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Identified Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Identified Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseIdentifiedElement(IdentifiedElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Container'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Container'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseContainer(Container object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'View'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'View'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseView(View object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Documented Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Documented Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseMapping_DocumentedElement(org.eclipse.emf.eef.mapping.DocumentedElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Binding Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Binding Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseBindingFilter(BindingFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Category'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Category'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCategory(Category object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Category'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Category'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseViews_Category(org.eclipse.emf.eef.views.Category object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Abstract Element Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Abstract Element Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAbstractElementBinding(AbstractElementBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EMF Element Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EMF Element Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEMFElementBinding(EMFElementBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //EditorSwitch diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/EEFUnderstandableQuery.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/EEFUnderstandableQuery.java deleted file mode 100644 index 793bf62d5..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/EEFUnderstandableQuery.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query; - -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; - -/** - * - * A representation of the model object 'EEF Understandable Query'. - * - * - * - * @see org.eclipse.emf.eef.extended.query.QueryPackage#getEEFUnderstandableQuery() - * @model abstract="true" - * @generated - */ -public interface EEFUnderstandableQuery extends ReferenceableObject { -} // EEFUnderstandableQuery diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/ExplicitPathQuery.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/ExplicitPathQuery.java deleted file mode 100644 index 140726633..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/ExplicitPathQuery.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query; - -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; - -/** - * - * A representation of the model object 'Explicit Path Query'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.extended.query.ExplicitPathQuery#getQuery Query}
  • - *
- *

- * - * @see org.eclipse.emf.eef.extended.query.QueryPackage#getExplicitPathQuery() - * @model - * @generated - */ -public interface ExplicitPathQuery extends EEFUnderstandableQuery { - /** - * Returns the value of the 'Query' reference. - * - *

- * If the meaning of the 'Query' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Query' reference. - * @see #setQuery(ModelNavigation) - * @see org.eclipse.emf.eef.extended.query.QueryPackage#getExplicitPathQuery_Query() - * @model required="true" - * @generated - */ - ModelNavigation getQuery(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.query.ExplicitPathQuery#getQuery Query}' reference. - * - * - * @param value the new value of the 'Query' reference. - * @see #getQuery() - * @generated - */ - void setQuery(ModelNavigation value); - -} // ExplicitPathQuery diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/OCLQuery.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/OCLQuery.java deleted file mode 100644 index 44b1d8526..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/OCLQuery.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query; - -import org.eclipse.emf.ecore.EClassifier; - -/** - * - * A representation of the model object 'OCL Query'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.extended.query.OCLQuery#getQuery Query}
  • - *
  • {@link org.eclipse.emf.eef.extended.query.OCLQuery#getContext Context}
  • - *
- *

- * - * @see org.eclipse.emf.eef.extended.query.QueryPackage#getOCLQuery() - * @model - * @generated - */ -public interface OCLQuery extends EEFUnderstandableQuery { - /** - * Returns the value of the 'Query' attribute. - * - *

- * If the meaning of the 'Query' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Query' attribute. - * @see #setQuery(String) - * @see org.eclipse.emf.eef.extended.query.QueryPackage#getOCLQuery_Query() - * @model required="true" - * @generated - */ - String getQuery(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.query.OCLQuery#getQuery Query}' attribute. - * - * - * @param value the new value of the 'Query' attribute. - * @see #getQuery() - * @generated - */ - void setQuery(String value); - - /** - * Returns the value of the 'Context' reference. - * - *

- * If the meaning of the 'Context' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Context' reference. - * @see #setContext(EClassifier) - * @see org.eclipse.emf.eef.extended.query.QueryPackage#getOCLQuery_Context() - * @model required="true" - * @generated - */ - EClassifier getContext(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.extended.query.OCLQuery#getContext Context}' reference. - * - * - * @param value the new value of the 'Context' reference. - * @see #getContext() - * @generated - */ - void setContext(EClassifier value); - -} // OCLQuery diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/QueryFactory.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/QueryFactory.java deleted file mode 100644 index 56a65ef88..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/QueryFactory.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.extended.query.QueryPackage - * @generated - */ -public interface QueryFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - QueryFactory eINSTANCE = org.eclipse.emf.eef.extended.query.impl.QueryFactoryImpl.init(); - - /** - * Returns a new object of class 'OCL Query'. - * - * - * @return a new object of class 'OCL Query'. - * @generated - */ - OCLQuery createOCLQuery(); - - /** - * Returns a new object of class 'Explicit Path Query'. - * - * - * @return a new object of class 'Explicit Path Query'. - * @generated - */ - ExplicitPathQuery createExplicitPathQuery(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - QueryPackage getQueryPackage(); - -} //QueryFactory diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/QueryPackage.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/QueryPackage.java deleted file mode 100644 index a43f5c960..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/QueryPackage.java +++ /dev/null @@ -1,293 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.extended.query.QueryFactory - * @model kind="package" - * @generated - */ -public interface QueryPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "query"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/extended/query/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-ext-qry"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - QueryPackage eINSTANCE = org.eclipse.emf.eef.extended.query.impl.QueryPackageImpl.init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.query.impl.EEFUnderstandableQueryImpl EEF Understandable Query}' class. - * - * - * @see org.eclipse.emf.eef.extended.query.impl.EEFUnderstandableQueryImpl - * @see org.eclipse.emf.eef.extended.query.impl.QueryPackageImpl#getEEFUnderstandableQuery() - * @generated - */ - int EEF_UNDERSTANDABLE_QUERY = 0; - - /** - * The number of structural features of the 'EEF Understandable Query' class. - * - * - * @generated - * @ordered - */ - int EEF_UNDERSTANDABLE_QUERY_FEATURE_COUNT = EditorPackage.REFERENCEABLE_OBJECT_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.query.impl.OCLQueryImpl OCL Query}' class. - * - * - * @see org.eclipse.emf.eef.extended.query.impl.OCLQueryImpl - * @see org.eclipse.emf.eef.extended.query.impl.QueryPackageImpl#getOCLQuery() - * @generated - */ - int OCL_QUERY = 1; - - /** - * The feature id for the 'Query' attribute. - * - * - * @generated - * @ordered - */ - int OCL_QUERY__QUERY = EEF_UNDERSTANDABLE_QUERY_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Context' reference. - * - * - * @generated - * @ordered - */ - int OCL_QUERY__CONTEXT = EEF_UNDERSTANDABLE_QUERY_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'OCL Query' class. - * - * - * @generated - * @ordered - */ - int OCL_QUERY_FEATURE_COUNT = EEF_UNDERSTANDABLE_QUERY_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.extended.query.impl.ExplicitPathQueryImpl Explicit Path Query}' class. - * - * - * @see org.eclipse.emf.eef.extended.query.impl.ExplicitPathQueryImpl - * @see org.eclipse.emf.eef.extended.query.impl.QueryPackageImpl#getExplicitPathQuery() - * @generated - */ - int EXPLICIT_PATH_QUERY = 2; - - /** - * The feature id for the 'Query' reference. - * - * - * @generated - * @ordered - */ - int EXPLICIT_PATH_QUERY__QUERY = EEF_UNDERSTANDABLE_QUERY_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Explicit Path Query' class. - * - * - * @generated - * @ordered - */ - int EXPLICIT_PATH_QUERY_FEATURE_COUNT = EEF_UNDERSTANDABLE_QUERY_FEATURE_COUNT + 1; - - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery EEF Understandable Query}'. - * - * - * @return the meta object for class 'EEF Understandable Query'. - * @see org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery - * @generated - */ - EClass getEEFUnderstandableQuery(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.query.OCLQuery OCL Query}'. - * - * - * @return the meta object for class 'OCL Query'. - * @see org.eclipse.emf.eef.extended.query.OCLQuery - * @generated - */ - EClass getOCLQuery(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.extended.query.OCLQuery#getQuery Query}'. - * - * - * @return the meta object for the attribute 'Query'. - * @see org.eclipse.emf.eef.extended.query.OCLQuery#getQuery() - * @see #getOCLQuery() - * @generated - */ - EAttribute getOCLQuery_Query(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.extended.query.OCLQuery#getContext Context}'. - * - * - * @return the meta object for the reference 'Context'. - * @see org.eclipse.emf.eef.extended.query.OCLQuery#getContext() - * @see #getOCLQuery() - * @generated - */ - EReference getOCLQuery_Context(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.extended.query.ExplicitPathQuery Explicit Path Query}'. - * - * - * @return the meta object for class 'Explicit Path Query'. - * @see org.eclipse.emf.eef.extended.query.ExplicitPathQuery - * @generated - */ - EClass getExplicitPathQuery(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.extended.query.ExplicitPathQuery#getQuery Query}'. - * - * - * @return the meta object for the reference 'Query'. - * @see org.eclipse.emf.eef.extended.query.ExplicitPathQuery#getQuery() - * @see #getExplicitPathQuery() - * @generated - */ - EReference getExplicitPathQuery_Query(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - QueryFactory getQueryFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.query.impl.EEFUnderstandableQueryImpl EEF Understandable Query}' class. - * - * - * @see org.eclipse.emf.eef.extended.query.impl.EEFUnderstandableQueryImpl - * @see org.eclipse.emf.eef.extended.query.impl.QueryPackageImpl#getEEFUnderstandableQuery() - * @generated - */ - EClass EEF_UNDERSTANDABLE_QUERY = eINSTANCE.getEEFUnderstandableQuery(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.query.impl.OCLQueryImpl OCL Query}' class. - * - * - * @see org.eclipse.emf.eef.extended.query.impl.OCLQueryImpl - * @see org.eclipse.emf.eef.extended.query.impl.QueryPackageImpl#getOCLQuery() - * @generated - */ - EClass OCL_QUERY = eINSTANCE.getOCLQuery(); - - /** - * The meta object literal for the 'Query' attribute feature. - * - * - * @generated - */ - EAttribute OCL_QUERY__QUERY = eINSTANCE.getOCLQuery_Query(); - - /** - * The meta object literal for the 'Context' reference feature. - * - * - * @generated - */ - EReference OCL_QUERY__CONTEXT = eINSTANCE.getOCLQuery_Context(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.extended.query.impl.ExplicitPathQueryImpl Explicit Path Query}' class. - * - * - * @see org.eclipse.emf.eef.extended.query.impl.ExplicitPathQueryImpl - * @see org.eclipse.emf.eef.extended.query.impl.QueryPackageImpl#getExplicitPathQuery() - * @generated - */ - EClass EXPLICIT_PATH_QUERY = eINSTANCE.getExplicitPathQuery(); - - /** - * The meta object literal for the 'Query' reference feature. - * - * - * @generated - */ - EReference EXPLICIT_PATH_QUERY__QUERY = eINSTANCE.getExplicitPathQuery_Query(); - - } - -} //QueryPackage diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/components/ExplicitPathQueryPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/components/ExplicitPathQueryPropertiesEditionComponent.java deleted file mode 100644 index 6234c2203..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/components/ExplicitPathQueryPropertiesEditionComponent.java +++ /dev/null @@ -1,215 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.extended.query.ExplicitPathQuery; -import org.eclipse.emf.eef.extended.query.QueryPackage; -import org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart; -import org.eclipse.emf.eef.extended.query.parts.QueryViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class ExplicitPathQueryPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for query EObjectFlatComboViewer - */ - private EObjectFlatComboSettings querySettings; - - - /** - * Default constructor - * - */ - public ExplicitPathQueryPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject explicitPathQuery, String editing_mode) { - super(editingContext, explicitPathQuery, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = QueryViewsRepository.class; - partKey = QueryViewsRepository.ExplicitPathQuery.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final ExplicitPathQuery explicitPathQuery = (ExplicitPathQuery)elt; - final ExplicitPathQueryPropertiesEditionPart basePart = (ExplicitPathQueryPropertiesEditionPart)editingPart; - // init values - if (isAccessible(QueryViewsRepository.ExplicitPathQuery.Properties.query_)) { - // init part - querySettings = new EObjectFlatComboSettings(explicitPathQuery, QueryPackage.eINSTANCE.getExplicitPathQuery_Query()); - basePart.initQuery(querySettings); - // set the button mode - basePart.setQueryButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - if (isAccessible(QueryViewsRepository.ExplicitPathQuery.Properties.query_)) { - basePart.addFilterToQuery(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof ModelNavigation); - } - - }); - // Start of user code for additional businessfilters for query - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == QueryViewsRepository.ExplicitPathQuery.Properties.query_) { - return QueryPackage.eINSTANCE.getExplicitPathQuery_Query(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - ExplicitPathQuery explicitPathQuery = (ExplicitPathQuery)semanticObject; - if (QueryViewsRepository.ExplicitPathQuery.Properties.query_ == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - querySettings.setToReference((ModelNavigation)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, querySettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - ExplicitPathQueryPropertiesEditionPart basePart = (ExplicitPathQueryPropertiesEditionPart)editingPart; - if (QueryPackage.eINSTANCE.getExplicitPathQuery_Query().equals(msg.getFeature()) && basePart != null && isAccessible(QueryViewsRepository.ExplicitPathQuery.Properties.query_)) - basePart.setQuery((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - QueryPackage.eINSTANCE.getExplicitPathQuery_Query() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == QueryViewsRepository.ExplicitPathQuery.Properties.query_; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/components/OCLQueryPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/components/OCLQueryPropertiesEditionComponent.java deleted file mode 100644 index 1cf3280e5..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/components/OCLQueryPropertiesEditionComponent.java +++ /dev/null @@ -1,245 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.extended.query.OCLQuery; -import org.eclipse.emf.eef.extended.query.QueryPackage; -import org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart; -import org.eclipse.emf.eef.extended.query.parts.QueryViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class OCLQueryPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for context EObjectFlatComboViewer - */ - private EObjectFlatComboSettings contextSettings; - - - /** - * Default constructor - * - */ - public OCLQueryPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject oCLQuery, String editing_mode) { - super(editingContext, oCLQuery, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = QueryViewsRepository.class; - partKey = QueryViewsRepository.OCLQuery.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final OCLQuery oCLQuery = (OCLQuery)elt; - final OCLQueryPropertiesEditionPart basePart = (OCLQueryPropertiesEditionPart)editingPart; - // init values - if (isAccessible(QueryViewsRepository.OCLQuery.Properties.query_)) - basePart.setQuery(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, oCLQuery.getQuery())); - - if (isAccessible(QueryViewsRepository.OCLQuery.Properties.context)) { - // init part - contextSettings = new EObjectFlatComboSettings(oCLQuery, QueryPackage.eINSTANCE.getOCLQuery_Context()); - basePart.initContext(contextSettings); - // set the button mode - basePart.setContextButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - - if (isAccessible(QueryViewsRepository.OCLQuery.Properties.context)) { - basePart.addFilterToContext(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EClassifier); - } - - }); - // Start of user code for additional businessfilters for context - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == QueryViewsRepository.OCLQuery.Properties.query_) { - return QueryPackage.eINSTANCE.getOCLQuery_Query(); - } - if (editorKey == QueryViewsRepository.OCLQuery.Properties.context) { - return QueryPackage.eINSTANCE.getOCLQuery_Context(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - OCLQuery oCLQuery = (OCLQuery)semanticObject; - if (QueryViewsRepository.OCLQuery.Properties.query_ == event.getAffectedEditor()) { - oCLQuery.setQuery((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (QueryViewsRepository.OCLQuery.Properties.context == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - contextSettings.setToReference((EClassifier)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, contextSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - OCLQueryPropertiesEditionPart basePart = (OCLQueryPropertiesEditionPart)editingPart; - if (QueryPackage.eINSTANCE.getOCLQuery_Query().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(QueryViewsRepository.OCLQuery.Properties.query_)) { - if (msg.getNewValue() != null) { - basePart.setQuery(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setQuery(""); - } - } - if (QueryPackage.eINSTANCE.getOCLQuery_Context().equals(msg.getFeature()) && basePart != null && isAccessible(QueryViewsRepository.OCLQuery.Properties.context)) - basePart.setContext((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - QueryPackage.eINSTANCE.getOCLQuery_Query(), - QueryPackage.eINSTANCE.getOCLQuery_Context() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == QueryViewsRepository.OCLQuery.Properties.query_ || key == QueryViewsRepository.OCLQuery.Properties.context; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (QueryViewsRepository.OCLQuery.Properties.query_ == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(QueryPackage.eINSTANCE.getOCLQuery_Query().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(QueryPackage.eINSTANCE.getOCLQuery_Query().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/EEFUnderstandableQueryImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/EEFUnderstandableQueryImpl.java deleted file mode 100644 index 9eb0a589f..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/EEFUnderstandableQueryImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.extended.editor.impl.ReferenceableObjectImpl; -import org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery; -import org.eclipse.emf.eef.extended.query.QueryPackage; - -/** - * - * An implementation of the model object 'EEF Understandable Query'. - * - *

- *

- * - * @generated - */ -public abstract class EEFUnderstandableQueryImpl extends ReferenceableObjectImpl implements EEFUnderstandableQuery { - /** - * - * - * @generated - */ - protected EEFUnderstandableQueryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return QueryPackage.Literals.EEF_UNDERSTANDABLE_QUERY; - } - -} //EEFUnderstandableQueryImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/ExplicitPathQueryImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/ExplicitPathQueryImpl.java deleted file mode 100644 index ee294428a..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/ExplicitPathQueryImpl.java +++ /dev/null @@ -1,161 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.extended.query.ExplicitPathQuery; -import org.eclipse.emf.eef.extended.query.QueryPackage; -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; - -/** - * - * An implementation of the model object 'Explicit Path Query'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.extended.query.impl.ExplicitPathQueryImpl#getQuery Query}
  • - *
- *

- * - * @generated - */ -public class ExplicitPathQueryImpl extends EEFUnderstandableQueryImpl implements ExplicitPathQuery { - /** - * The cached value of the '{@link #getQuery() Query}' reference. - * - * - * @see #getQuery() - * @generated - * @ordered - */ - protected ModelNavigation query; - - /** - * - * - * @generated - */ - protected ExplicitPathQueryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return QueryPackage.Literals.EXPLICIT_PATH_QUERY; - } - - /** - * - * - * @generated - */ - public ModelNavigation getQuery() { - if (query != null && query.eIsProxy()) { - InternalEObject oldQuery = (InternalEObject)query; - query = (ModelNavigation)eResolveProxy(oldQuery); - if (query != oldQuery) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, QueryPackage.EXPLICIT_PATH_QUERY__QUERY, oldQuery, query)); - } - } - return query; - } - - /** - * - * - * @generated - */ - public ModelNavigation basicGetQuery() { - return query; - } - - /** - * - * - * @generated - */ - public void setQuery(ModelNavigation newQuery) { - ModelNavigation oldQuery = query; - query = newQuery; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, QueryPackage.EXPLICIT_PATH_QUERY__QUERY, oldQuery, query)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case QueryPackage.EXPLICIT_PATH_QUERY__QUERY: - if (resolve) return getQuery(); - return basicGetQuery(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case QueryPackage.EXPLICIT_PATH_QUERY__QUERY: - setQuery((ModelNavigation)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case QueryPackage.EXPLICIT_PATH_QUERY__QUERY: - setQuery((ModelNavigation)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case QueryPackage.EXPLICIT_PATH_QUERY__QUERY: - return query != null; - } - return super.eIsSet(featureID); - } - -} //ExplicitPathQueryImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/OCLQueryImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/OCLQueryImpl.java deleted file mode 100644 index 5cd125b14..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/OCLQueryImpl.java +++ /dev/null @@ -1,229 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.extended.query.OCLQuery; -import org.eclipse.emf.eef.extended.query.QueryPackage; - -/** - * - * An implementation of the model object 'OCL Query'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.extended.query.impl.OCLQueryImpl#getQuery Query}
  • - *
  • {@link org.eclipse.emf.eef.extended.query.impl.OCLQueryImpl#getContext Context}
  • - *
- *

- * - * @generated - */ -public class OCLQueryImpl extends EEFUnderstandableQueryImpl implements OCLQuery { - /** - * The default value of the '{@link #getQuery() Query}' attribute. - * - * - * @see #getQuery() - * @generated - * @ordered - */ - protected static final String QUERY_EDEFAULT = null; - - /** - * The cached value of the '{@link #getQuery() Query}' attribute. - * - * - * @see #getQuery() - * @generated - * @ordered - */ - protected String query = QUERY_EDEFAULT; - - /** - * The cached value of the '{@link #getContext() Context}' reference. - * - * - * @see #getContext() - * @generated - * @ordered - */ - protected EClassifier context; - - /** - * - * - * @generated - */ - protected OCLQueryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return QueryPackage.Literals.OCL_QUERY; - } - - /** - * - * - * @generated - */ - public String getQuery() { - return query; - } - - /** - * - * - * @generated - */ - public void setQuery(String newQuery) { - String oldQuery = query; - query = newQuery; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, QueryPackage.OCL_QUERY__QUERY, oldQuery, query)); - } - - /** - * - * - * @generated - */ - public EClassifier getContext() { - if (context != null && context.eIsProxy()) { - InternalEObject oldContext = (InternalEObject)context; - context = (EClassifier)eResolveProxy(oldContext); - if (context != oldContext) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, QueryPackage.OCL_QUERY__CONTEXT, oldContext, context)); - } - } - return context; - } - - /** - * - * - * @generated - */ - public EClassifier basicGetContext() { - return context; - } - - /** - * - * - * @generated - */ - public void setContext(EClassifier newContext) { - EClassifier oldContext = context; - context = newContext; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, QueryPackage.OCL_QUERY__CONTEXT, oldContext, context)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case QueryPackage.OCL_QUERY__QUERY: - return getQuery(); - case QueryPackage.OCL_QUERY__CONTEXT: - if (resolve) return getContext(); - return basicGetContext(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case QueryPackage.OCL_QUERY__QUERY: - setQuery((String)newValue); - return; - case QueryPackage.OCL_QUERY__CONTEXT: - setContext((EClassifier)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case QueryPackage.OCL_QUERY__QUERY: - setQuery(QUERY_EDEFAULT); - return; - case QueryPackage.OCL_QUERY__CONTEXT: - setContext((EClassifier)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case QueryPackage.OCL_QUERY__QUERY: - return QUERY_EDEFAULT == null ? query != null : !QUERY_EDEFAULT.equals(query); - case QueryPackage.OCL_QUERY__CONTEXT: - return context != null; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (query: "); - result.append(query); - result.append(')'); - return result.toString(); - } - -} //OCLQueryImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/QueryFactoryImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/QueryFactoryImpl.java deleted file mode 100644 index 86117d758..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/QueryFactoryImpl.java +++ /dev/null @@ -1,114 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.impl.EFactoryImpl; -import org.eclipse.emf.ecore.plugin.EcorePlugin; -import org.eclipse.emf.eef.extended.query.ExplicitPathQuery; -import org.eclipse.emf.eef.extended.query.OCLQuery; -import org.eclipse.emf.eef.extended.query.QueryFactory; -import org.eclipse.emf.eef.extended.query.QueryPackage; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class QueryFactoryImpl extends EFactoryImpl implements QueryFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static QueryFactory init() { - try { - QueryFactory theQueryFactory = (QueryFactory)EPackage.Registry.INSTANCE.getEFactory("http://www.eclipse.org/emf/eef/extended/query/1.0.0"); - if (theQueryFactory != null) { - return theQueryFactory; - } - } - catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new QueryFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public QueryFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case QueryPackage.OCL_QUERY: return createOCLQuery(); - case QueryPackage.EXPLICIT_PATH_QUERY: return createExplicitPathQuery(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public OCLQuery createOCLQuery() { - OCLQueryImpl oclQuery = new OCLQueryImpl(); - return oclQuery; - } - - /** - * - * - * @generated - */ - public ExplicitPathQuery createExplicitPathQuery() { - ExplicitPathQueryImpl explicitPathQuery = new ExplicitPathQueryImpl(); - return explicitPathQuery; - } - - /** - * - * - * @generated - */ - public QueryPackage getQueryPackage() { - return (QueryPackage)getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static QueryPackage getPackage() { - return QueryPackage.eINSTANCE; - } - -} //QueryFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/QueryPackageImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/QueryPackageImpl.java deleted file mode 100644 index b10669b4e..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/impl/QueryPackageImpl.java +++ /dev/null @@ -1,267 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.impl; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.impl.EPackageImpl; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.editor.impl.EditorPackageImpl; -import org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery; -import org.eclipse.emf.eef.extended.query.ExplicitPathQuery; -import org.eclipse.emf.eef.extended.query.OCLQuery; -import org.eclipse.emf.eef.extended.query.QueryFactory; -import org.eclipse.emf.eef.extended.query.QueryPackage; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class QueryPackageImpl extends EPackageImpl implements QueryPackage { - /** - * - * - * @generated - */ - private EClass eefUnderstandableQueryEClass = null; - - /** - * - * - * @generated - */ - private EClass oclQueryEClass = null; - - /** - * - * - * @generated - */ - private EClass explicitPathQueryEClass = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.extended.query.QueryPackage#eNS_URI - * @see #init() - * @generated - */ - private QueryPackageImpl() { - super(eNS_URI, QueryFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link QueryPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static QueryPackage init() { - if (isInited) return (QueryPackage)EPackage.Registry.INSTANCE.getEPackage(QueryPackage.eNS_URI); - - // Obtain or create and register package - QueryPackageImpl theQueryPackage = (QueryPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof QueryPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new QueryPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - ComponentsPackage.eINSTANCE.eClass(); - - // Obtain or create and register interdependencies - EditorPackageImpl theEditorPackage = (EditorPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(EditorPackage.eNS_URI) instanceof EditorPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(EditorPackage.eNS_URI) : EditorPackage.eINSTANCE); - - // Create package meta-data objects - theQueryPackage.createPackageContents(); - theEditorPackage.createPackageContents(); - - // Initialize created meta-data - theQueryPackage.initializePackageContents(); - theEditorPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theQueryPackage.freeze(); - - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(QueryPackage.eNS_URI, theQueryPackage); - return theQueryPackage; - } - - /** - * - * - * @generated - */ - public EClass getEEFUnderstandableQuery() { - return eefUnderstandableQueryEClass; - } - - /** - * - * - * @generated - */ - public EClass getOCLQuery() { - return oclQueryEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getOCLQuery_Query() { - return (EAttribute)oclQueryEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getOCLQuery_Context() { - return (EReference)oclQueryEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getExplicitPathQuery() { - return explicitPathQueryEClass; - } - - /** - * - * - * @generated - */ - public EReference getExplicitPathQuery_Query() { - return (EReference)explicitPathQueryEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public QueryFactory getQueryFactory() { - return (QueryFactory)getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) return; - isCreated = true; - - // Create classes and their features - eefUnderstandableQueryEClass = createEClass(EEF_UNDERSTANDABLE_QUERY); - - oclQueryEClass = createEClass(OCL_QUERY); - createEAttribute(oclQueryEClass, OCL_QUERY__QUERY); - createEReference(oclQueryEClass, OCL_QUERY__CONTEXT); - - explicitPathQueryEClass = createEClass(EXPLICIT_PATH_QUERY); - createEReference(explicitPathQueryEClass, EXPLICIT_PATH_QUERY__QUERY); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - EditorPackage theEditorPackage = (EditorPackage)EPackage.Registry.INSTANCE.getEPackage(EditorPackage.eNS_URI); - NavigationPackage theNavigationPackage = (NavigationPackage)EPackage.Registry.INSTANCE.getEPackage(NavigationPackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - eefUnderstandableQueryEClass.getESuperTypes().add(theEditorPackage.getReferenceableObject()); - oclQueryEClass.getESuperTypes().add(this.getEEFUnderstandableQuery()); - explicitPathQueryEClass.getESuperTypes().add(this.getEEFUnderstandableQuery()); - - // Initialize classes and features; add operations and parameters - initEClass(eefUnderstandableQueryEClass, EEFUnderstandableQuery.class, "EEFUnderstandableQuery", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(oclQueryEClass, OCLQuery.class, "OCLQuery", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getOCLQuery_Query(), ecorePackage.getEString(), "query", null, 1, 1, OCLQuery.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getOCLQuery_Context(), ecorePackage.getEClassifier(), null, "context", null, 1, 1, OCLQuery.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(explicitPathQueryEClass, ExplicitPathQuery.class, "ExplicitPathQuery", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getExplicitPathQuery_Query(), theNavigationPackage.getModelNavigation(), null, "query", null, 1, 1, ExplicitPathQuery.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - // Create resource - createResource(eNS_URI); - } - -} //QueryPackageImpl diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/ExplicitPathQueryPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/ExplicitPathQueryPropertiesEditionPart.java deleted file mode 100644 index 4b73125cf..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/ExplicitPathQueryPropertiesEditionPart.java +++ /dev/null @@ -1,91 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public interface ExplicitPathQueryPropertiesEditionPart { - - /** - * @return the query - * - */ - public EObject getQuery(); - - /** - * Init the query - * @param settings the combo setting - */ - public void initQuery(EObjectFlatComboSettings settings); - - /** - * Defines a new query - * @param newValue the new query to set - * - */ - public void setQuery(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setQueryButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the query edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToQuery(ViewerFilter filter); - - /** - * Adds the given filter to the query edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToQuery(ViewerFilter filter); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/OCLQueryPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/OCLQueryPropertiesEditionPart.java deleted file mode 100644 index e5f572130..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/OCLQueryPropertiesEditionPart.java +++ /dev/null @@ -1,105 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public interface OCLQueryPropertiesEditionPart { - - /** - * @return the context - * - */ - public EObject getContext(); - - /** - * Init the context - * @param settings the combo setting - */ - public void initContext(EObjectFlatComboSettings settings); - - /** - * Defines a new context - * @param newValue the new context to set - * - */ - public void setContext(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setContextButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the context edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToContext(ViewerFilter filter); - - /** - * Adds the given filter to the context edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToContext(ViewerFilter filter); - - - /** - * @return the query - * - */ - public String getQuery(); - - /** - * Defines a new query - * @param newValue the new query to set - * - */ - public void setQuery(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - -// End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/QueryViewsRepository.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/QueryViewsRepository.java deleted file mode 100644 index 3ceece3b2..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/QueryViewsRepository.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.parts; - -/** - * @author Goulwen LeFur - * - */ -public class QueryViewsRepository { - - public static final int SWT_KIND = 0; - - public static final int FORM_KIND = 1; - - - /** - * OCLQuery view descriptor - * - */ - public static class OCLQuery { - public static class Properties { - - - public static String context = "query::OCLQuery::Properties::context"; - - - public static String query_ = "query::OCLQuery::Properties::query_"; - - - } - - } - - /** - * ExplicitPathQuery view descriptor - * - */ - public static class ExplicitPathQuery { - public static class Properties { - - - public static String query_ = "query::ExplicitPathQuery::Properties::query_"; - - - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/forms/ExplicitPathQueryPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/forms/ExplicitPathQueryPropertiesEditionPartForm.java deleted file mode 100644 index 5f174b418..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/forms/ExplicitPathQueryPropertiesEditionPartForm.java +++ /dev/null @@ -1,287 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart; -import org.eclipse.emf.eef.extended.query.parts.QueryViewsRepository; -import org.eclipse.emf.eef.extended.query.providers.QueryMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class ExplicitPathQueryPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, ExplicitPathQueryPropertiesEditionPart { - - protected EObjectFlatComboViewer query; - - - - /** - * For {@link ISection} use only. - */ - public ExplicitPathQueryPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public ExplicitPathQueryPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence explicitPathQueryStep = new BindingCompositionSequence(propertiesEditionComponent); - explicitPathQueryStep - .addStep(QueryViewsRepository.ExplicitPathQuery.Properties.class) - .addStep(QueryViewsRepository.ExplicitPathQuery.Properties.query_); - - - composer = new PartComposer(explicitPathQueryStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == QueryViewsRepository.ExplicitPathQuery.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == QueryViewsRepository.ExplicitPathQuery.Properties.query_) { - return createQueryFlatComboViewer(parent, widgetFactory); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(QueryMessages.ExplicitPathQueryPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createQueryFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, QueryViewsRepository.ExplicitPathQuery.Properties.query_, QueryMessages.ExplicitPathQueryPropertiesEditionPart_QueryLabel); - query = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(QueryViewsRepository.ExplicitPathQuery.Properties.query_, QueryViewsRepository.FORM_KIND)); - widgetFactory.adapt(query); - query.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData queryData = new GridData(GridData.FILL_HORIZONTAL); - query.setLayoutData(queryData); - query.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(ExplicitPathQueryPropertiesEditionPartForm.this, QueryViewsRepository.ExplicitPathQuery.Properties.query_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getQuery())); - } - - }); - query.setID(QueryViewsRepository.ExplicitPathQuery.Properties.query_); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(QueryViewsRepository.ExplicitPathQuery.Properties.query_, QueryViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createQueryFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#getQuery() - * - */ - public EObject getQuery() { - if (query.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) query.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#initQuery(EObjectFlatComboSettings) - */ - public void initQuery(EObjectFlatComboSettings settings) { - query.setInput(settings); - if (current != null) { - query.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(QueryViewsRepository.ExplicitPathQuery.Properties.query_); - if (eefElementEditorReadOnlyState && query.isEnabled()) { - query.setEnabled(false); - query.setToolTipText(QueryMessages.ExplicitPathQuery_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !query.isEnabled()) { - query.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#setQuery(EObject newValue) - * - */ - public void setQuery(EObject newValue) { - if (newValue != null) { - query.setSelection(new StructuredSelection(newValue)); - } else { - query.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(QueryViewsRepository.ExplicitPathQuery.Properties.query_); - if (eefElementEditorReadOnlyState && query.isEnabled()) { - query.setEnabled(false); - query.setToolTipText(QueryMessages.ExplicitPathQuery_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !query.isEnabled()) { - query.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#setQueryButtonMode(ButtonsModeEnum newValue) - */ - public void setQueryButtonMode(ButtonsModeEnum newValue) { - query.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#addFilterQuery(ViewerFilter filter) - * - */ - public void addFilterToQuery(ViewerFilter filter) { - query.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#addBusinessFilterQuery(ViewerFilter filter) - * - */ - public void addBusinessFilterToQuery(ViewerFilter filter) { - query.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return QueryMessages.ExplicitPathQuery_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/forms/OCLQueryPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/forms/OCLQueryPropertiesEditionPartForm.java deleted file mode 100644 index 198063fb9..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/forms/OCLQueryPropertiesEditionPartForm.java +++ /dev/null @@ -1,399 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart; -import org.eclipse.emf.eef.extended.query.parts.QueryViewsRepository; -import org.eclipse.emf.eef.extended.query.providers.QueryMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class OCLQueryPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, OCLQueryPropertiesEditionPart { - - protected EObjectFlatComboViewer context; - protected Text query; - - - - /** - * For {@link ISection} use only. - */ - public OCLQueryPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public OCLQueryPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence oCLQueryStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = oCLQueryStep.addStep(QueryViewsRepository.OCLQuery.Properties.class); - propertiesStep.addStep(QueryViewsRepository.OCLQuery.Properties.context); - propertiesStep.addStep(QueryViewsRepository.OCLQuery.Properties.query_); - - - composer = new PartComposer(oCLQueryStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == QueryViewsRepository.OCLQuery.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == QueryViewsRepository.OCLQuery.Properties.context) { - return createContextFlatComboViewer(parent, widgetFactory); - } - if (key == QueryViewsRepository.OCLQuery.Properties.query_) { - return createQueryText(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(QueryMessages.OCLQueryPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createContextFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, QueryViewsRepository.OCLQuery.Properties.context, QueryMessages.OCLQueryPropertiesEditionPart_ContextLabel); - context = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(QueryViewsRepository.OCLQuery.Properties.context, QueryViewsRepository.FORM_KIND)); - widgetFactory.adapt(context); - context.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData contextData = new GridData(GridData.FILL_HORIZONTAL); - context.setLayoutData(contextData); - context.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(OCLQueryPropertiesEditionPartForm.this, QueryViewsRepository.OCLQuery.Properties.context, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getContext())); - } - - }); - context.setID(QueryViewsRepository.OCLQuery.Properties.context); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(QueryViewsRepository.OCLQuery.Properties.context, QueryViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createContextFlatComboViewer - - // End of user code - return parent; - } - - - protected Composite createQueryText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, QueryViewsRepository.OCLQuery.Properties.query_, QueryMessages.OCLQueryPropertiesEditionPart_QueryLabel); - query = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - query.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData queryData = new GridData(GridData.FILL_HORIZONTAL); - query.setLayoutData(queryData); - query.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - OCLQueryPropertiesEditionPartForm.this, - QueryViewsRepository.OCLQuery.Properties.query_, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, query.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - OCLQueryPropertiesEditionPartForm.this, - QueryViewsRepository.OCLQuery.Properties.query_, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, query.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - OCLQueryPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - query.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(OCLQueryPropertiesEditionPartForm.this, QueryViewsRepository.OCLQuery.Properties.query_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, query.getText())); - } - } - }); - EditingUtils.setID(query, QueryViewsRepository.OCLQuery.Properties.query_); - EditingUtils.setEEFtype(query, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(QueryViewsRepository.OCLQuery.Properties.query_, QueryViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createQueryText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#getContext() - * - */ - public EObject getContext() { - if (context.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) context.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#initContext(EObjectFlatComboSettings) - */ - public void initContext(EObjectFlatComboSettings settings) { - context.setInput(settings); - if (current != null) { - context.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(QueryViewsRepository.OCLQuery.Properties.context); - if (eefElementEditorReadOnlyState && context.isEnabled()) { - context.setEnabled(false); - context.setToolTipText(QueryMessages.OCLQuery_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !context.isEnabled()) { - context.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#setContext(EObject newValue) - * - */ - public void setContext(EObject newValue) { - if (newValue != null) { - context.setSelection(new StructuredSelection(newValue)); - } else { - context.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(QueryViewsRepository.OCLQuery.Properties.context); - if (eefElementEditorReadOnlyState && context.isEnabled()) { - context.setEnabled(false); - context.setToolTipText(QueryMessages.OCLQuery_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !context.isEnabled()) { - context.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#setContextButtonMode(ButtonsModeEnum newValue) - */ - public void setContextButtonMode(ButtonsModeEnum newValue) { - context.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#addFilterContext(ViewerFilter filter) - * - */ - public void addFilterToContext(ViewerFilter filter) { - context.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#addBusinessFilterContext(ViewerFilter filter) - * - */ - public void addBusinessFilterToContext(ViewerFilter filter) { - context.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#getQuery() - * - */ - public String getQuery() { - return query.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#setQuery(String newValue) - * - */ - public void setQuery(String newValue) { - if (newValue != null) { - query.setText(newValue); - } else { - query.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(QueryViewsRepository.OCLQuery.Properties.query_); - if (eefElementEditorReadOnlyState && query.isEnabled()) { - query.setEnabled(false); - query.setToolTipText(QueryMessages.OCLQuery_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !query.isEnabled()) { - query.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return QueryMessages.OCLQuery_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/impl/ExplicitPathQueryPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/impl/ExplicitPathQueryPropertiesEditionPartImpl.java deleted file mode 100644 index fced3d2b4..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/impl/ExplicitPathQueryPropertiesEditionPartImpl.java +++ /dev/null @@ -1,269 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart; -import org.eclipse.emf.eef.extended.query.parts.QueryViewsRepository; -import org.eclipse.emf.eef.extended.query.providers.QueryMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class ExplicitPathQueryPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, ExplicitPathQueryPropertiesEditionPart { - - protected EObjectFlatComboViewer query; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public ExplicitPathQueryPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence explicitPathQueryStep = new BindingCompositionSequence(propertiesEditionComponent); - explicitPathQueryStep - .addStep(QueryViewsRepository.ExplicitPathQuery.Properties.class) - .addStep(QueryViewsRepository.ExplicitPathQuery.Properties.query_); - - - composer = new PartComposer(explicitPathQueryStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == QueryViewsRepository.ExplicitPathQuery.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == QueryViewsRepository.ExplicitPathQuery.Properties.query_) { - return createQueryFlatComboViewer(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(QueryMessages.ExplicitPathQueryPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createQueryFlatComboViewer(Composite parent) { - createDescription(parent, QueryViewsRepository.ExplicitPathQuery.Properties.query_, QueryMessages.ExplicitPathQueryPropertiesEditionPart_QueryLabel); - query = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(QueryViewsRepository.ExplicitPathQuery.Properties.query_, QueryViewsRepository.SWT_KIND)); - query.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - query.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(ExplicitPathQueryPropertiesEditionPartImpl.this, QueryViewsRepository.ExplicitPathQuery.Properties.query_, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getQuery())); - } - - }); - GridData queryData = new GridData(GridData.FILL_HORIZONTAL); - query.setLayoutData(queryData); - query.setID(QueryViewsRepository.ExplicitPathQuery.Properties.query_); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(QueryViewsRepository.ExplicitPathQuery.Properties.query_, QueryViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createQueryFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#getQuery() - * - */ - public EObject getQuery() { - if (query.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) query.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#initQuery(EObjectFlatComboSettings) - */ - public void initQuery(EObjectFlatComboSettings settings) { - query.setInput(settings); - if (current != null) { - query.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(QueryViewsRepository.ExplicitPathQuery.Properties.query_); - if (eefElementEditorReadOnlyState && query.isEnabled()) { - query.setEnabled(false); - query.setToolTipText(QueryMessages.ExplicitPathQuery_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !query.isEnabled()) { - query.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#setQuery(EObject newValue) - * - */ - public void setQuery(EObject newValue) { - if (newValue != null) { - query.setSelection(new StructuredSelection(newValue)); - } else { - query.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(QueryViewsRepository.ExplicitPathQuery.Properties.query_); - if (eefElementEditorReadOnlyState && query.isEnabled()) { - query.setEnabled(false); - query.setToolTipText(QueryMessages.ExplicitPathQuery_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !query.isEnabled()) { - query.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#setQueryButtonMode(ButtonsModeEnum newValue) - */ - public void setQueryButtonMode(ButtonsModeEnum newValue) { - query.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#addFilterQuery(ViewerFilter filter) - * - */ - public void addFilterToQuery(ViewerFilter filter) { - query.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.ExplicitPathQueryPropertiesEditionPart#addBusinessFilterQuery(ViewerFilter filter) - * - */ - public void addBusinessFilterToQuery(ViewerFilter filter) { - query.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return QueryMessages.ExplicitPathQuery_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/impl/OCLQueryPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/impl/OCLQueryPropertiesEditionPartImpl.java deleted file mode 100644 index ecbcaa263..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/parts/impl/OCLQueryPropertiesEditionPartImpl.java +++ /dev/null @@ -1,361 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart; -import org.eclipse.emf.eef.extended.query.parts.QueryViewsRepository; -import org.eclipse.emf.eef.extended.query.providers.QueryMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Goulwen LeFur - * - */ -public class OCLQueryPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, OCLQueryPropertiesEditionPart { - - protected EObjectFlatComboViewer context; - protected Text query; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public OCLQueryPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence oCLQueryStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = oCLQueryStep.addStep(QueryViewsRepository.OCLQuery.Properties.class); - propertiesStep.addStep(QueryViewsRepository.OCLQuery.Properties.context); - propertiesStep.addStep(QueryViewsRepository.OCLQuery.Properties.query_); - - - composer = new PartComposer(oCLQueryStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == QueryViewsRepository.OCLQuery.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == QueryViewsRepository.OCLQuery.Properties.context) { - return createContextFlatComboViewer(parent); - } - if (key == QueryViewsRepository.OCLQuery.Properties.query_) { - return createQueryText(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(QueryMessages.OCLQueryPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createContextFlatComboViewer(Composite parent) { - createDescription(parent, QueryViewsRepository.OCLQuery.Properties.context, QueryMessages.OCLQueryPropertiesEditionPart_ContextLabel); - context = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(QueryViewsRepository.OCLQuery.Properties.context, QueryViewsRepository.SWT_KIND)); - context.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - context.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(OCLQueryPropertiesEditionPartImpl.this, QueryViewsRepository.OCLQuery.Properties.context, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getContext())); - } - - }); - GridData contextData = new GridData(GridData.FILL_HORIZONTAL); - context.setLayoutData(contextData); - context.setID(QueryViewsRepository.OCLQuery.Properties.context); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(QueryViewsRepository.OCLQuery.Properties.context, QueryViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createContextFlatComboViewer - - // End of user code - return parent; - } - - - protected Composite createQueryText(Composite parent) { - createDescription(parent, QueryViewsRepository.OCLQuery.Properties.query_, QueryMessages.OCLQueryPropertiesEditionPart_QueryLabel); - query = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData queryData = new GridData(GridData.FILL_HORIZONTAL); - query.setLayoutData(queryData); - query.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(OCLQueryPropertiesEditionPartImpl.this, QueryViewsRepository.OCLQuery.Properties.query_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, query.getText())); - } - - }); - query.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(OCLQueryPropertiesEditionPartImpl.this, QueryViewsRepository.OCLQuery.Properties.query_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, query.getText())); - } - } - - }); - EditingUtils.setID(query, QueryViewsRepository.OCLQuery.Properties.query_); - EditingUtils.setEEFtype(query, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(QueryViewsRepository.OCLQuery.Properties.query_, QueryViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createQueryText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#getContext() - * - */ - public EObject getContext() { - if (context.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) context.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#initContext(EObjectFlatComboSettings) - */ - public void initContext(EObjectFlatComboSettings settings) { - context.setInput(settings); - if (current != null) { - context.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(QueryViewsRepository.OCLQuery.Properties.context); - if (eefElementEditorReadOnlyState && context.isEnabled()) { - context.setEnabled(false); - context.setToolTipText(QueryMessages.OCLQuery_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !context.isEnabled()) { - context.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#setContext(EObject newValue) - * - */ - public void setContext(EObject newValue) { - if (newValue != null) { - context.setSelection(new StructuredSelection(newValue)); - } else { - context.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(QueryViewsRepository.OCLQuery.Properties.context); - if (eefElementEditorReadOnlyState && context.isEnabled()) { - context.setEnabled(false); - context.setToolTipText(QueryMessages.OCLQuery_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !context.isEnabled()) { - context.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#setContextButtonMode(ButtonsModeEnum newValue) - */ - public void setContextButtonMode(ButtonsModeEnum newValue) { - context.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#addFilterContext(ViewerFilter filter) - * - */ - public void addFilterToContext(ViewerFilter filter) { - context.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#addBusinessFilterContext(ViewerFilter filter) - * - */ - public void addBusinessFilterToContext(ViewerFilter filter) { - context.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#getQuery() - * - */ - public String getQuery() { - return query.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.extended.query.parts.OCLQueryPropertiesEditionPart#setQuery(String newValue) - * - */ - public void setQuery(String newValue) { - if (newValue != null) { - query.setText(newValue); - } else { - query.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(QueryViewsRepository.OCLQuery.Properties.query_); - if (eefElementEditorReadOnlyState && query.isEnabled()) { - query.setEnabled(false); - query.setToolTipText(QueryMessages.OCLQuery_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !query.isEnabled()) { - query.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return QueryMessages.OCLQuery_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/EEFUnderstandableQueryItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/EEFUnderstandableQueryItemProvider.java deleted file mode 100644 index 383ebbdc1..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/EEFUnderstandableQueryItemProvider.java +++ /dev/null @@ -1,115 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.extended.editor.provider.ExtendedEditPlugin; -import org.eclipse.emf.eef.extended.editor.provider.ReferenceableObjectItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery} object. - * - * - * @generated - */ -public class EEFUnderstandableQueryItemProvider - extends ReferenceableObjectItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFUnderstandableQueryItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_EEFUnderstandableQuery_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ExtendedEditPlugin.INSTANCE; - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/ExplicitPathQueryItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/ExplicitPathQueryItemProvider.java deleted file mode 100644 index 26e39fca8..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/ExplicitPathQueryItemProvider.java +++ /dev/null @@ -1,137 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.extended.query.QueryPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.query.ExplicitPathQuery} object. - * - * - * @generated - */ -public class ExplicitPathQueryItemProvider - extends EEFUnderstandableQueryItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public ExplicitPathQueryItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addQueryPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Query feature. - * - * - * @generated - */ - protected void addQueryPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_ExplicitPathQuery_query_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_ExplicitPathQuery_query_feature", "_UI_ExplicitPathQuery_type"), - QueryPackage.Literals.EXPLICIT_PATH_QUERY__QUERY, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns ExplicitPathQuery.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/ExplicitPathQuery")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_ExplicitPathQuery_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/OCLQueryItemProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/OCLQueryItemProvider.java deleted file mode 100644 index 5fe5af837..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/OCLQueryItemProvider.java +++ /dev/null @@ -1,172 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.extended.query.OCLQuery; -import org.eclipse.emf.eef.extended.query.QueryPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.extended.query.OCLQuery} object. - * - * - * @generated - */ -public class OCLQueryItemProvider - extends EEFUnderstandableQueryItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public OCLQueryItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addQueryPropertyDescriptor(object); - addContextPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Query feature. - * - * - * @generated - */ - protected void addQueryPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_OCLQuery_query_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_OCLQuery_query_feature", "_UI_OCLQuery_type"), - QueryPackage.Literals.OCL_QUERY__QUERY, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Context feature. - * - * - * @generated - */ - protected void addContextPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_OCLQuery_context_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_OCLQuery_context_feature", "_UI_OCLQuery_type"), - QueryPackage.Literals.OCL_QUERY__CONTEXT, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns OCLQuery.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/OCLQuery")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((OCLQuery)object).getQuery(); - return label == null || label.length() == 0 ? - getString("_UI_OCLQuery_type") : - getString("_UI_OCLQuery_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(OCLQuery.class)) { - case QueryPackage.OCL_QUERY__QUERY: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/QueryItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/QueryItemProviderAdapterFactory.java deleted file mode 100644 index cb7cad082..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/provider/QueryItemProviderAdapterFactory.java +++ /dev/null @@ -1,229 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.provider; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.extended.query.util.QueryAdapterFactory; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class QueryItemProviderAdapterFactory extends QueryAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public QueryItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.query.OCLQuery} instances. - * - * - * @generated - */ - protected OCLQueryItemProvider oclQueryItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.query.OCLQuery}. - * - * - * @generated - */ - @Override - public Adapter createOCLQueryAdapter() { - if (oclQueryItemProvider == null) { - oclQueryItemProvider = new OCLQueryItemProvider(this); - } - - return oclQueryItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.extended.query.ExplicitPathQuery} instances. - * - * - * @generated - */ - protected ExplicitPathQueryItemProvider explicitPathQueryItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.extended.query.ExplicitPathQuery}. - * - * - * @generated - */ - @Override - public Adapter createExplicitPathQueryAdapter() { - if (explicitPathQueryItemProvider == null) { - explicitPathQueryItemProvider = new ExplicitPathQueryItemProvider(this); - } - - return explicitPathQueryItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) || (((Class)type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (oclQueryItemProvider != null) oclQueryItemProvider.dispose(); - if (explicitPathQueryItemProvider != null) explicitPathQueryItemProvider.dispose(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/ExplicitPathQueryPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/ExplicitPathQueryPropertiesEditionProvider.java deleted file mode 100644 index f7dae7147..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/ExplicitPathQueryPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.query.ExplicitPathQuery; -import org.eclipse.emf.eef.extended.query.QueryPackage; - -import org.eclipse.emf.eef.extended.query.components.ExplicitPathQueryPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Goulwen LeFur - * - */ -public class ExplicitPathQueryPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public ExplicitPathQueryPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public ExplicitPathQueryPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof ExplicitPathQuery) - && (QueryPackage.Literals.EXPLICIT_PATH_QUERY == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof ExplicitPathQuery) && (ExplicitPathQueryPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof ExplicitPathQuery) && (refinement == ExplicitPathQueryPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof ExplicitPathQuery) && ((ExplicitPathQueryPropertiesEditionComponent.BASE_PART.equals(part) && refinement == ExplicitPathQueryPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof ExplicitPathQuery) { - return new ExplicitPathQueryPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof ExplicitPathQuery) { - if (ExplicitPathQueryPropertiesEditionComponent.BASE_PART.equals(part)) - return new ExplicitPathQueryPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof ExplicitPathQuery) { - if (ExplicitPathQueryPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == ExplicitPathQueryPropertiesEditionComponent.class) - return new ExplicitPathQueryPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && QueryPackage.Literals.EXPLICIT_PATH_QUERY == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/OCLQueryPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/OCLQueryPropertiesEditionProvider.java deleted file mode 100644 index df8c77536..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/OCLQueryPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.query.OCLQuery; -import org.eclipse.emf.eef.extended.query.QueryPackage; - -import org.eclipse.emf.eef.extended.query.components.OCLQueryPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Goulwen LeFur - * - */ -public class OCLQueryPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public OCLQueryPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public OCLQueryPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof OCLQuery) - && (QueryPackage.Literals.OCL_QUERY == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof OCLQuery) && (OCLQueryPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof OCLQuery) && (refinement == OCLQueryPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof OCLQuery) && ((OCLQueryPropertiesEditionComponent.BASE_PART.equals(part) && refinement == OCLQueryPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof OCLQuery) { - return new OCLQueryPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof OCLQuery) { - if (OCLQueryPropertiesEditionComponent.BASE_PART.equals(part)) - return new OCLQueryPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof OCLQuery) { - if (OCLQueryPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == OCLQueryPropertiesEditionComponent.class) - return new OCLQueryPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && QueryPackage.Literals.OCL_QUERY == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryEEFAdapterFactory.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryEEFAdapterFactory.java deleted file mode 100644 index 96b63c12c..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryEEFAdapterFactory.java +++ /dev/null @@ -1,40 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.providers; - -import org.eclipse.emf.common.notify.Adapter; - -import org.eclipse.emf.eef.extended.query.util.QueryAdapterFactory; - -/** - * @author Goulwen LeFur - * - */ -public class QueryEEFAdapterFactory extends QueryAdapterFactory { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.extended.query.util.QueryAdapterFactory#createOCLQueryAdapter() - * - */ - public Adapter createOCLQueryAdapter() { - return new OCLQueryPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.extended.query.util.QueryAdapterFactory#createExplicitPathQueryAdapter() - * - */ - public Adapter createExplicitPathQueryAdapter() { - return new ExplicitPathQueryPropertiesEditionProvider(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryMessages.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryMessages.java deleted file mode 100644 index d69448c8c..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryMessages.java +++ /dev/null @@ -1,114 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.providers; - -import org.eclipse.osgi.util.NLS; - -/** - * @author Goulwen LeFur - * - */ -public class QueryMessages extends NLS { - - private static final String BUNDLE_NAME = "org.eclipse.emf.eef.extended.query.providers.queryMessages"; //$NON-NLS-1$ - - - public static String OCLQueryPropertiesEditionPart_PropertiesGroupLabel; - - - public static String ExplicitPathQueryPropertiesEditionPart_PropertiesGroupLabel; - - - - public static String OCLQuery_ReadOnly; - - - public static String OCLQuery_Part_Title; - - - public static String ExplicitPathQuery_ReadOnly; - - - public static String ExplicitPathQuery_Part_Title; - - - - public static String OCLQueryPropertiesEditionPart_ContextLabel; - - - public static String OCLQueryPropertiesEditionPart_QueryLabel; - - - public static String ExplicitPathQueryPropertiesEditionPart_QueryLabel; - - - - public static String PropertiesEditionPart_DocumentationLabel; - - - public static String PropertiesEditionPart_IntegerValueMessage; - - - public static String PropertiesEditionPart_FloatValueMessage; - - - public static String PropertiesEditionPart_ShortValueMessage; - - - public static String PropertiesEditionPart_LongValueMessage; - - - public static String PropertiesEditionPart_ByteValueMessage; - - - public static String PropertiesEditionPart_BigIntegerValueMessage; - - - public static String PropertiesEditionPart_BigDecimalValueMessage; - - - public static String PropertiesEditionPart_DoubleValueMessage; - - - public static String PropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesEditionPart_RequiredFeatureMessage; - - - public static String PropertiesEditionPart_AddTableViewerLabel; - - - public static String PropertiesEditionPart_EditTableViewerLabel; - - - public static String PropertiesEditionPart_RemoveTableViewerLabel; - - - public static String PropertiesEditionPart_AddListViewerLabel; - - - public static String PropertiesEditionPart_RemoveListViewerLabel; - - // Start of user code for additionnal NLS Constants - -// End of user code - - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, QueryMessages.class); - } - - - private QueryMessages() { - //protect instanciation - } -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryPropertiesEditionPartProvider.java deleted file mode 100644 index e045c5a74..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/QueryPropertiesEditionPartProvider.java +++ /dev/null @@ -1,63 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.providers; - -import org.eclipse.emf.eef.extended.query.parts.QueryViewsRepository; - -import org.eclipse.emf.eef.extended.query.parts.forms.ExplicitPathQueryPropertiesEditionPartForm; -import org.eclipse.emf.eef.extended.query.parts.forms.OCLQueryPropertiesEditionPartForm; - -import org.eclipse.emf.eef.extended.query.parts.impl.ExplicitPathQueryPropertiesEditionPartImpl; -import org.eclipse.emf.eef.extended.query.parts.impl.OCLQueryPropertiesEditionPartImpl; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; - -/** - * @author Goulwen LeFur - * - */ -public class QueryPropertiesEditionPartProvider implements IPropertiesEditionPartProvider { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#provides(java.lang.Object) - * - */ - public boolean provides(Object key) { - return key == QueryViewsRepository.class; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#getPropertiesEditionPart(java.lang.Object, int, org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, IPropertiesEditionComponent component) { - if (key == QueryViewsRepository.OCLQuery.class) { - if (kind == QueryViewsRepository.SWT_KIND) - return new OCLQueryPropertiesEditionPartImpl(component); - if (kind == QueryViewsRepository.FORM_KIND) - return new OCLQueryPropertiesEditionPartForm(component); - } - if (key == QueryViewsRepository.ExplicitPathQuery.class) { - if (kind == QueryViewsRepository.SWT_KIND) - return new ExplicitPathQueryPropertiesEditionPartImpl(component); - if (kind == QueryViewsRepository.FORM_KIND) - return new ExplicitPathQueryPropertiesEditionPartForm(component); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/queryMessages.properties b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/queryMessages.properties deleted file mode 100644 index a70ae4bb5..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/queryMessages.properties +++ /dev/null @@ -1,41 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -OCLQueryPropertiesEditionPart_PropertiesGroupLabel=Properties -ExplicitPathQueryPropertiesEditionPart_PropertiesGroupLabel=Properties -OCLQuery_ReadOnly=This property is read only -OCLQuery_Part_Title=OCLQuery -ExplicitPathQuery_ReadOnly=This property is read only -ExplicitPathQuery_Part_Title=ExplicitPathQuery -OCLQueryPropertiesEditionPart_ContextLabel=Context : -OCLQueryPropertiesEditionPart_QueryLabel=Query : -ExplicitPathQueryPropertiesEditionPart_QueryLabel=Query : -PropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionPart_EditTableViewerLabel=Edit -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=The property {0} of the object shall be filled -PropertiesEditionPart_RemoveTableViewerLabel=Delete -PropertiesEditionPart_RemoveListViewerLabel=Delete -PropertiesEditionPart_IntegerValueMessage=The property {0} shall be an integer -PropertiesEditionPart_FloatValueMessage=The property {0} shall be a float -PropertiesEditionPart_ShortValueMessage=The property {0} shall be a short -PropertiesEditionPart_DoubleValueMessage=The property {0} shall be a double -PropertiesEditionPart_ByteValueMessage=The property {0} shall be a byte -PropertiesEditionPart_LongValueMessage=The property {0} shall be a long -PropertiesEditionPart_BigIntegerValueMessage=The property {0} shall be a BigInteger -PropertiesEditionPart_BigDecimalValueMessage=The property {0} shall be a BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Add -PropertiesEditionPart_AddListViewerLabel=Add diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/queryMessages_fr.properties b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/queryMessages_fr.properties deleted file mode 100644 index 37f139a0d..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/providers/queryMessages_fr.properties +++ /dev/null @@ -1,41 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -OCLQueryPropertiesEditionPart_PropertiesGroupLabel=Properties -ExplicitPathQueryPropertiesEditionPart_PropertiesGroupLabel=Properties -OCLQuery_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -OCLQuery_Part_Title=OCLQuery -ExplicitPathQuery_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -ExplicitPathQuery_Part_Title=ExplicitPathQuery -OCLQueryPropertiesEditionPart_ContextLabel=Context : -OCLQueryPropertiesEditionPart_QueryLabel=Query : -ExplicitPathQueryPropertiesEditionPart_QueryLabel=Query : -PropertiesEditionPart_PropertiesGroupLabel=Propri\u00E9t\u00E9s -PropertiesEditionPart_EditTableViewerLabel=Editer -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=La propri\u00E9t\u00E9 {0} de l\u0027objet doit \u00EAtre renseign\u00E9e -PropertiesEditionPart_RemoveTableViewerLabel=Supprimer -PropertiesEditionPart_RemoveListViewerLabel=Supprimer -PropertiesEditionPart_IntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un entier -PropertiesEditionPart_FloatValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un flottant -PropertiesEditionPart_ShortValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un short -PropertiesEditionPart_DoubleValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un double -PropertiesEditionPart_ByteValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un byte -PropertiesEditionPart_LongValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un long -PropertiesEditionPart_BigIntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigInteger -PropertiesEditionPart_BigDecimalValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Ajouter -PropertiesEditionPart_AddListViewerLabel=Ajouter diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/util/QueryAdapterFactory.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/util/QueryAdapterFactory.java deleted file mode 100644 index 33a7f539d..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/util/QueryAdapterFactory.java +++ /dev/null @@ -1,183 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery; -import org.eclipse.emf.eef.extended.query.ExplicitPathQuery; -import org.eclipse.emf.eef.extended.query.OCLQuery; -import org.eclipse.emf.eef.extended.query.QueryPackage; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.extended.query.QueryPackage - * @generated - */ -public class QueryAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static QueryPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public QueryAdapterFactory() { - if (modelPackage == null) { - modelPackage = QueryPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject)object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected QuerySwitch modelSwitch = - new QuerySwitch() { - @Override - public Adapter caseEEFUnderstandableQuery(EEFUnderstandableQuery object) { - return createEEFUnderstandableQueryAdapter(); - } - @Override - public Adapter caseOCLQuery(OCLQuery object) { - return createOCLQueryAdapter(); - } - @Override - public Adapter caseExplicitPathQuery(ExplicitPathQuery object) { - return createExplicitPathQueryAdapter(); - } - @Override - public Adapter caseReferenceableObject(ReferenceableObject object) { - return createReferenceableObjectAdapter(); - } - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject)target); - } - - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery EEF Understandable Query}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery - * @generated - */ - public Adapter createEEFUnderstandableQueryAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.query.OCLQuery OCL Query}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.query.OCLQuery - * @generated - */ - public Adapter createOCLQueryAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.query.ExplicitPathQuery Explicit Path Query}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.query.ExplicitPathQuery - * @generated - */ - public Adapter createExplicitPathQueryAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.ReferenceableObject Referenceable Object}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.ReferenceableObject - * @generated - */ - public Adapter createReferenceableObjectAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //QueryAdapterFactory diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/util/QuerySwitch.java b/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/util/QuerySwitch.java deleted file mode 100644 index 833dcf07c..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/org/eclipse/emf/eef/extended/query/util/QuerySwitch.java +++ /dev/null @@ -1,199 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.extended.query.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.extended.query.EEFUnderstandableQuery; -import org.eclipse.emf.eef.extended.query.ExplicitPathQuery; -import org.eclipse.emf.eef.extended.query.OCLQuery; -import org.eclipse.emf.eef.extended.query.QueryPackage; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.extended.query.QueryPackage - * @generated - */ -public class QuerySwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static QueryPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public QuerySwitch() { - if (modelPackage == null) { - modelPackage = QueryPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } - else { - List eSuperTypes = theEClass.getESuperTypes(); - return - eSuperTypes.isEmpty() ? - defaultCase(theEObject) : - doSwitch(eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case QueryPackage.EEF_UNDERSTANDABLE_QUERY: { - EEFUnderstandableQuery eefUnderstandableQuery = (EEFUnderstandableQuery)theEObject; - T result = caseEEFUnderstandableQuery(eefUnderstandableQuery); - if (result == null) result = caseReferenceableObject(eefUnderstandableQuery); - if (result == null) result = defaultCase(theEObject); - return result; - } - case QueryPackage.OCL_QUERY: { - OCLQuery oclQuery = (OCLQuery)theEObject; - T result = caseOCLQuery(oclQuery); - if (result == null) result = caseEEFUnderstandableQuery(oclQuery); - if (result == null) result = caseReferenceableObject(oclQuery); - if (result == null) result = defaultCase(theEObject); - return result; - } - case QueryPackage.EXPLICIT_PATH_QUERY: { - ExplicitPathQuery explicitPathQuery = (ExplicitPathQuery)theEObject; - T result = caseExplicitPathQuery(explicitPathQuery); - if (result == null) result = caseEEFUnderstandableQuery(explicitPathQuery); - if (result == null) result = caseReferenceableObject(explicitPathQuery); - if (result == null) result = defaultCase(theEObject); - return result; - } - default: return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'EEF Understandable Query'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EEF Understandable Query'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFUnderstandableQuery(EEFUnderstandableQuery object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'OCL Query'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'OCL Query'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseOCLQuery(OCLQuery object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Explicit Path Query'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Explicit Path Query'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseExplicitPathQuery(ExplicitPathQuery object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Referenceable Object'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Referenceable Object'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseReferenceableObject(ReferenceableObject object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //QuerySwitch diff --git a/plugins/org.eclipse.emf.eef.editor.model/src-gen/query_properties.plugin.xml b/plugins/org.eclipse.emf.eef.editor.model/src-gen/query_properties.plugin.xml deleted file mode 100644 index 0f0d43368..000000000 --- a/plugins/org.eclipse.emf.eef.editor.model/src-gen/query_properties.plugin.xml +++ /dev/null @@ -1,73 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/.checkstyle b/plugins/org.eclipse.emf.eef.eefgen.edit/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/.classpath b/plugins/org.eclipse.emf.eef.eefgen.edit/.classpath deleted file mode 100644 index f9c46b584..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/.gitignore b/plugins/org.eclipse.emf.eef.eefgen.edit/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/.project b/plugins/org.eclipse.emf.eef.eefgen.edit/.project deleted file mode 100644 index a9bece6b4..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.eefgen.edit - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.eefgen.edit/META-INF/MANIFEST.MF deleted file mode 100644 index 8472dc1ff..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/META-INF/MANIFEST.MF +++ /dev/null @@ -1,25 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEFGen Edit Support -Bundle-SymbolicName: org.eclipse.emf.eef.eefgen.edit;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Activator: org.eclipse.emf.eef.EEFGen.provider.EEFGenEditPlugin$Implementation -Bundle-Vendor: Eclipse Modeling Project -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.EEFGen.provider -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.emf.edit;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.ecore;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.ecore.edit;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.codegen.ecore;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.codegen.ecore.ui;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.eef.components;visibility:=reexport, - org.eclipse.emf.eef.components.edit;visibility:=reexport, - org.eclipse.emf.eef.eefgen;visibility:=reexport, - org.eclipse.emf.eef.mapping;visibility:=reexport, - org.eclipse.emf.eef.mapping.edit;visibility:=reexport, - org.eclipse.emf.eef.views;visibility:=reexport, - org.eclipse.emf.eef.views.edit;visibility:=reexport -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/about.html b/plugins/org.eclipse.emf.eef.eefgen.edit/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/build.properties b/plugins/org.eclipse.emf.eef.eefgen.edit/build.properties deleted file mode 100644 index 1b789c93a..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/build.properties +++ /dev/null @@ -1,21 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -bin.includes = .,\ - icons/,\ - META-INF/,\ - plugin.xml,\ - plugin.properties,\ - about.html -jars.compile.order = . -source.. = src-gen/ -output.. = bin/ -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/ctool16/CreateEEFGenModel_editionContexts_GenEditionContext.gif b/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/ctool16/CreateEEFGenModel_editionContexts_GenEditionContext.gif deleted file mode 100644 index babb084892c4d14f28525b05b99b0ecd71c070ed..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?74GlAm)BgXDpC51k|Gqtt z`}^zfH%H&xpMU>S<)vNI)qrU0B;|Eo@=Kef=2eQ#ED`?q_dO8({d^vX{ybm&`))JP zGzd`q$-)R?>3|53oeZoo3JQHGk#=efGtVBLa$)PF{^q_(C7#BgO?s|nPtp`q@0Uu> zbPm**z5E2bNT1f6QzzZ57*B$#$lN32yQ?T54|RYMp+Wp3jg| O)0EoSl&z}BU=09RS!6~4 diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/ctool16/CreateEEFGenModel_references_EEFGenModelReference.gif b/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/ctool16/CreateEEFGenModel_references_EEFGenModelReference.gif deleted file mode 100644 index 027f1b702718a54abdad340f25abd1f6f0f8419f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@bX4;vCh6V=*hyVZM=f~Uszi$uZ z{{H&=&Cxga=ik3nd1=>lH6YqLNqJqD{L&_=d6i-_ON9UZeGf!`Kc5GpKhGEczS|5m z4FVK@vM_>JIv@gMCj)DYfrlb&nYlQhND`=ydI zodY#yFF(O9(x)}&)JZoh1|7Bg-YymbK@GECBz#zOvYlyRf}8w}mYUnSTBl#8=QHHg OG^I8+WvePOSOWn4T4T!q diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/ctool16/CreateEEFGenModel_viewsRepositories_GenViewsRepository.gif b/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/ctool16/CreateEEFGenModel_viewsRepositories_GenViewsRepository.gif deleted file mode 100644 index 4e1434e9ef7c82202d10ca73373532cba71d30fc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?84hI|@9RB~0pC51k|Gs@g zL&NW{zuz2vbASH*OO=;)O;-b=t&^13b;&PnlA2d3HnT+d-{1E@^!M|5Ao}xs@$b9M zK+_;V@h1x-h@}G}Kz1^)#waNCr9|4PG0Z%Bc*=#Xllq(cCY5*^e>Um4mOV*ROub(! zIny~%WA^eB>>_`9tp>its5na+V4 zvzMP>7wOZQbLym<6@!l2eQy^FfuM%jFA_d1I@!*&Fu_g!MoZ1@T&>eD)AJc}YMN3T Ko3d3E8LRz{Qmsy&$l0cax42|s#Yb` ztxap*IC1Img6iHE?|;4e@ax^@-)}$t`uy#8PS^I5+O8Mxf4=$j`{UQ&MH6C@x+p#N)yZZ0qQ;y#+vKquQ8JrKDCDTsQcuF24ayjKcw!BlA9Os!f-xkwA#cZ z<(oO{ss;3%bkxKf8WIJiwVkxoWVj?G*c2Kh1T~%1)g-vs*@YJ@me6ogRTJi7Wo2Y- xkY!hKQdVQ`2v1~TR(29qV_-UTsDX(?)QL~+@R>7wPMjAnUB2vg&Bc+y8UU-9s5t-t diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/obj16/EEFGenModelReference.gif b/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/obj16/EEFGenModelReference.gif deleted file mode 100644 index 25c66a1838d71db5fced12c0afb549a283a3b94f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 145 zcmZ?wbhEHb6krfw*v!CCHFGy-)C`4;xdufG9cz{ZwylWoTiv;GU*?px({>%4cj)lu zTgMN+KJ_0A7#J87f3h$#Fz_+x0NFqj1Q-}t>@J-2T)o#K`}(bEyiFAm*A-7zn7Z9I w>U8w;-FWB6BoSkGjROlFIlL%j^LX;mz@W*8so_9mCJR%D_w&PVtCSh60i=6AEC2ui diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/obj16/GenEditionContext.gif b/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/obj16/GenEditionContext.gif deleted file mode 100644 index 25cbe630cf14e86d8a5c7defb9264704ea44bacb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1072 zcmeH`-Ahw(7{^a07SVJID;En(3?h2bELvHDm1#v#U6h27i!P#zOs%aqb1&+SJKJn- zZc`LYy-+s?t{|os7ORxrEMHn(nRSt^%)RN(IltfU>GVHz*>m;f^M&ul2cE*CN921I zVoFRcQk1Qlwy0^V*3fvj-db(2Rv9cBrcrGi>i1bR<{|HZ&+7vM#@i;Q$~f3RWV~(m zc?Sj`JQ?slCI~PO1cUCDNv&+qs2cAo%^1NQ0A5;yN9v6jgCHqfk))bWm8@2bA#Po z-{dknT#UU}p=xF9-L%7FaP%@xSLv-b+TmuLJqAa2oQHa+i*|O$IA9TkSy;efChv4CTQMT94SL8t_G0M!5c*9JDSiAyNTOl|!;{P!oQ z2PuZAL5v5OEc#$m4mEp9?T4v3ji=U0s&bs5xTk>S18y?iDDXQ3A+^pO5 z%CY;PY>C7={WK#n>3iU*H%Xk9n=NZA`l^=b3Pdf#H!NDcY2N|ao3Rc>f^NC=?L>B@ z=0s}F&cjz`mv-ou<&?etrkN>hkY*%|wzImIqpS8`vJGo83XTQROS)3!;_2jd`&F$q z_qCZnBs-H*#iz5>DXa6e&XMK|e#?p-;-Zq$>Gl!P+HKlEQP(qxVY@7I*E#k5lP0-- zCR3_8l+i3nKU~u-)*orl*UcE?Uv8#|3h2#aSq~Lsw0uoM_MT8@VZJQ+>`Kx5e19TC On?JbDzsuV|<^BPG^vL4? diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/obj16/GenViewsRepository.gif b/plugins/org.eclipse.emf.eef.eefgen.edit/icons/full/obj16/GenViewsRepository.gif deleted file mode 100644 index 0a1fa96efc7b1f4157b37e0d6957b162c6b9eb2f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 606 zcmZ?wbhEHb6krfwc*el+`RnhHl;-gCwr@ZF{QUJNI=eGIzbB<+LdWD4YqlJE`0~fY zm)|ohr{vYmC~ls!ZQtpqZ+^Ud|MTsqU*+xd%iHJ8TDJY+s~-!L4|0RQ>v*=GkRHl^yfT+UGrZ_5JDFAMZZ@`uy#eX8sY)yhEBf`?Rul zX=ZHIO53QFvRXTFnO6KlZ6J!7traz0D|)(i^mMI=$y$+fBXCHr$7Jy&;Nfve*b*?|Gz){-)}#wxA^{i z`#fLOIT>Lg76$+S|7RFXK=CIFBLhPKgAT}1pg3V*-`x<<+A34-`&~a z>)}4t!*^n{zq_};w|lFtwZ;++d4Df2f6o=GI5`+MGHSMX&Gla8=jyV@g-I)5vd`h^ zERxR5lFY2y2YY<_ebq0kJ2J58w72* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - SWT - Form - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/model/EEFGen.eefgen b/plugins/org.eclipse.emf.eef.eefgen.edit/model/EEFGen.eefgen deleted file mode 100755 index e2d39a7a5..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/model/EEFGen.eefgen +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/plugin.properties b/plugins/org.eclipse.emf.eef.eefgen.edit/plugin.properties deleted file mode 100644 index 804827235..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/plugin.properties +++ /dev/null @@ -1,90 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -_UI_CreateChild_text = {0} -_UI_CreateChild_text2 = {1} {0} -_UI_CreateChild_text3 = {1} -_UI_CreateChild_tooltip = Create New {0} Under {1} Feature -_UI_CreateChild_description = Create a new child of type {0} for the {1} feature of the selected {2}. -_UI_CreateSibling_description = Create a new sibling of type {0} for the selected {2}, under the {1} feature of their parent. - -_UI_PropertyDescriptor_description = The {0} of the {1} - -_UI_GenEditionContext_type = Gen Edition Context -_UI_Unknown_type = Object - -_UI_Unknown_datatype= Value - -_UI_GenEditionContext_PropertiesEditionContext_feature = Properties Edition Context -_UI_GenEditionContext_basePackage_feature = Base Package -_UI_GenEditionContext_genDirectory_feature = Gen Directory -_UI_Unknown_feature = Unspecified - -_UI_GenEditionContext_PropertiesEditionContext_description = The PropertiesEditioContext to describe -_UI_GenEditionContext_basePackage_description = The base package for all the generated code -_UI_GenEditionContext_genDirectory_description = The target directory for the generated code -_UI_GenEditionContext_swtViews_feature = Swt Views -_UI_GenEditionContext_swtViews_description = Whether to include the SWT implementation of views -_UI_GenEditionContext_formViews_feature = Form Views -_UI_GenEditionContext_formViews_description = Whether to include the Eclipse Forms implementation of views -_UI_GenEditionContext_descriptorsGenericPropertiesViews_feature = Descriptors Generic Properties Views -_UI_GenEditionContext_descriptorsGenericPropertiesViews_description = Whether to include a sample configuration for plugin.xml to use a generic EEF properties view -_UI_GenEditionContext_gmfPropertiesViews_feature = Gmf Properties Views -_UI_GenEditionContext_gmfPropertiesViews_description = Whether to include a views implementation and a sample configuration for plugin.xml to use EEF on a GMF modeler -_UI_ParametersPropertyCategory = Parameters -_UI_ActivationPropertyCategory = Activation -_UI_ReferencesPropertyCategory = References -_UI_GenEditionContext_helpStrategy_feature = Help Strategy -_UI_GenEditionContext_helpStrategy_description = Defines where the generators have to search the help entries -_UI_GenEditionContext_descriptorsContributorID_feature = Descriptors Contributor ID -_UI_GenEditionContext_descriptorsContributorID_description = Override if necessary the contributorID to use for generic descriptors -_UI_HELP_STRATEGY_GENMODEL_literal = GENMODEL -_UI_HELP_STRATEGY_ECOREMODEL_literal = ECOREMODEL -_UI_GenEditionContext_author_feature = Author -_UI_GenEditionContext_author_description = The string that must be generated for the @author tag -_UI_GenEditionContext_license_feature = License -_UI_GenEditionContext_license_description = The license text of the generated code -_UI_GenEditionContextReference_type = Gen Edition Context Reference -_UI_GenEditionContext_viewsPackagePrefix_feature = Views Package Prefix -_UI_GenEditionContext_references_feature = References -_UI_GenEditionContextReference_referencedContext_feature = Referenced Context -_UI_EEFGenModelReference_type = Model Reference -_UI_EEFGenModel_type = Model -_UI_GenViewsRepository_type = Gen Views Repository -_UI_EEFGenModelReference_referencedContext_feature = Referenced Context -_UI_EEFGenModel_editionContexts_feature = Edition Contexts -_UI_EEFGenModel_genDirectory_feature = Gen Directory -_UI_EEFGenModel_author_feature = Author -_UI_EEFGenModel_license_feature = License -_UI_EEFGenModel_references_feature = References -_UI_GenViewsRepository_viewsRepository_feature = Views Repository -_UI_GenViewsRepository_basePackage_feature = Base Package -_UI_GenViewsRepository_swtViews_feature = Swt Views -_UI_GenViewsRepository_formViews_feature = Form Views -_UI_GenViewsRepository_descriptorsGenericPropertiesViews_feature = Descriptors Generic Properties Views -_UI_GenViewsRepository_gmfPropertiesViews_feature = Gmf Properties Views -_UI_GenViewsRepository_helpStrategy_feature = Help Strategy -_UI_GenViewsRepository_descriptorsContributorID_feature = Descriptors Contributor ID -_UI_GenEditionContext_eefGenModel_feature = Eef Gen Model -_UI_EEFGenModel_viewsRepositories_feature = Views Repositories -_UI_GenViewsRepository_eefGenModel_feature = Eef Gen Model -_UI_GenEditionContext_generateJunitTestCases_feature = Generate Junit Test Cases -_UI_EEFGenModel_testsGenDirectory_feature = Tests Gen Directory -_UI_GenEditionContext_useJMergeForUserCode_feature = Use JMerge For User Code -_UI_EEFGenModel_useJMergeForUserCode_feature = Use JMerge For User Code -_UI_GenEditionContext_leafComponentsSuperClass_feature = Leaf Components Super Class -_UI_GenEditionContext_propertiesEditingProvidersSuperClass_feature = Properties Editing Providers Super Class -_UI_GenViewsRepository_partsSuperClass_feature = Parts Super Class -_UI_GenEditionContext_leafComponentsSuperClass_description = The base from which implementations of leaf PropertiesEditingComponents extend -_UI_GenEditionContext_propertiesEditingProvidersSuperClass_description = The base from which implementations of leaf PropertiesEditingProviders extend -_UI_GenViewsRepository_partsSuperClass_description = The base from which implementations of leaf PropertiesEditingParts extend -_UI_implementationPropertyCategory = implementation -_UI_GenViewsRepository_formsSuperClass_feature = Forms Super Class diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/plugin.xml b/plugins/org.eclipse.emf.eef.eefgen.edit/plugin.xml deleted file mode 100644 index bfb346837..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/plugin.xml +++ /dev/null @@ -1,102 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/pom.xml b/plugins/org.eclipse.emf.eef.eefgen.edit/pom.xml deleted file mode 100644 index 3f4bd1372..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/pom.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.eefgen.edit - eclipse-plugin - - EEF EEFGen Edit Plug-in - diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/EEFGen_properties.plugin.xml b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/EEFGen_properties.plugin.xml deleted file mode 100644 index 0aed5b4a1..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/EEFGen_properties.plugin.xml +++ /dev/null @@ -1,79 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/EEFGenModelPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/EEFGenModelPropertiesEditionComponent.java deleted file mode 100644 index 7c165a16e..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/EEFGenModelPropertiesEditionComponent.java +++ /dev/null @@ -1,286 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenModelPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public EEFGenModelPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eEFGenModel, String editing_mode) { - super(editingContext, eEFGenModel, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EEFGenViewsRepository.class; - partKey = EEFGenViewsRepository.EEFGenModel.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final EEFGenModel eEFGenModel = (EEFGenModel)elt; - final EEFGenModelPropertiesEditionPart basePart = (EEFGenModelPropertiesEditionPart)editingPart; - // init values - if (isAccessible(EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory)) - basePart.setGenerationDirectory(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, eEFGenModel.getGenDirectory())); - - if (isAccessible(EEFGenViewsRepository.EEFGenModel.Legal.author)) - basePart.setAuthor(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, eEFGenModel.getAuthor())); - - if (isAccessible(EEFGenViewsRepository.EEFGenModel.Legal.license)) - basePart.setLicense(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, eEFGenModel.getLicense())); - if (isAccessible(EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory)) - basePart.setTestsGenerationDirectory(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, eEFGenModel.getTestsGenDirectory())); - - if (isAccessible(EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode)) { - basePart.setUseJMergeToManageUserCode(eEFGenModel.isUseJMergeForUserCode()); - } - // init filters - - - - - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory) { - return EEFGenPackage.eINSTANCE.getEEFGenModel_GenDirectory(); - } - if (editorKey == EEFGenViewsRepository.EEFGenModel.Legal.author) { - return EEFGenPackage.eINSTANCE.getEEFGenModel_Author(); - } - if (editorKey == EEFGenViewsRepository.EEFGenModel.Legal.license) { - return EEFGenPackage.eINSTANCE.getEEFGenModel_License(); - } - if (editorKey == EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory) { - return EEFGenPackage.eINSTANCE.getEEFGenModel_TestsGenDirectory(); - } - if (editorKey == EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode) { - return EEFGenPackage.eINSTANCE.getEEFGenModel_UseJMergeForUserCode(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - EEFGenModel eEFGenModel = (EEFGenModel)semanticObject; - if (EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory == event.getAffectedEditor()) { - eEFGenModel.setGenDirectory((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EEFGenViewsRepository.EEFGenModel.Legal.author == event.getAffectedEditor()) { - eEFGenModel.setAuthor((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EEFGenViewsRepository.EEFGenModel.Legal.license == event.getAffectedEditor()) { - eEFGenModel.setLicense((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory == event.getAffectedEditor()) { - eEFGenModel.setTestsGenDirectory((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode == event.getAffectedEditor()) { - eEFGenModel.setUseJMergeForUserCode((Boolean)event.getNewValue()); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - EEFGenModelPropertiesEditionPart basePart = (EEFGenModelPropertiesEditionPart)editingPart; - if (EEFGenPackage.eINSTANCE.getEEFGenModel_GenDirectory().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory)) { - if (msg.getNewValue() != null) { - basePart.setGenerationDirectory(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setGenerationDirectory(""); - } - } - if (EEFGenPackage.eINSTANCE.getEEFGenModel_Author().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.EEFGenModel.Legal.author)) { - if (msg.getNewValue() != null) { - basePart.setAuthor(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setAuthor(""); - } - } - if (EEFGenPackage.eINSTANCE.getEEFGenModel_License().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.EEFGenModel.Legal.license)){ - if (msg.getNewValue() != null) { - basePart.setLicense(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setLicense(""); - } - } - if (EEFGenPackage.eINSTANCE.getEEFGenModel_TestsGenDirectory().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory)) { - if (msg.getNewValue() != null) { - basePart.setTestsGenerationDirectory(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setTestsGenerationDirectory(""); - } - } - if (EEFGenPackage.eINSTANCE.getEEFGenModel_UseJMergeForUserCode().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode)) - basePart.setUseJMergeToManageUserCode((Boolean)msg.getNewValue()); - - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - EEFGenPackage.eINSTANCE.getEEFGenModel_GenDirectory(), - EEFGenPackage.eINSTANCE.getEEFGenModel_Author(), - EEFGenPackage.eINSTANCE.getEEFGenModel_License(), - EEFGenPackage.eINSTANCE.getEEFGenModel_TestsGenDirectory(), - EEFGenPackage.eINSTANCE.getEEFGenModel_UseJMergeForUserCode() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getEEFGenModel_GenDirectory().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getEEFGenModel_GenDirectory().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.EEFGenModel.Legal.author == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getEEFGenModel_Author().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getEEFGenModel_Author().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.EEFGenModel.Legal.license == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getEEFGenModel_License().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getEEFGenModel_License().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getEEFGenModel_TestsGenDirectory().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getEEFGenModel_TestsGenDirectory().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getEEFGenModel_UseJMergeForUserCode().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getEEFGenModel_UseJMergeForUserCode().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/EEFGenModelReferencePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/EEFGenModelReferencePropertiesEditionComponent.java deleted file mode 100644 index e23c524f7..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/EEFGenModelReferencePropertiesEditionComponent.java +++ /dev/null @@ -1,219 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.EEFGen.EEFGenFactory; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenModelReference; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenModelReferencePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for reference EObjectFlatComboViewer - */ - private EObjectFlatComboSettings referenceSettings; - - - /** - * Default constructor - * - */ - public EEFGenModelReferencePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eEFGenModelReference, String editing_mode) { - super(editingContext, eEFGenModelReference, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EEFGenViewsRepository.class; - partKey = EEFGenViewsRepository.EEFGenModelReference.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final EEFGenModelReference eEFGenModelReference = (EEFGenModelReference)elt; - final EEFGenModelReferencePropertiesEditionPart basePart = (EEFGenModelReferencePropertiesEditionPart)editingPart; - // init values - if (isAccessible(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel)) { - // init part - referenceSettings = new EObjectFlatComboSettings(eEFGenModelReference, EEFGenPackage.eINSTANCE.getEEFGenModelReference_ReferencedContext()); - basePart.initReferencedEEFGenModel(referenceSettings); - // set the button mode - basePart.setReferencedEEFGenModelButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - if (isAccessible(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel)) { - basePart.addFilterToReferencedEEFGenModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EEFGenModel); - } - - }); - // Start of user code for additional businessfilters for reference - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel) { - return EEFGenPackage.eINSTANCE.getEEFGenModelReference_ReferencedContext(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - EEFGenModelReference eEFGenModelReference = (EEFGenModelReference)semanticObject; - if (EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - referenceSettings.setToReference((EEFGenModel)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EEFGenModel eObject = EEFGenFactory.eINSTANCE.createEEFGenModel(); - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - referenceSettings.setToReference(eObject); - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - EEFGenModelReferencePropertiesEditionPart basePart = (EEFGenModelReferencePropertiesEditionPart)editingPart; - if (EEFGenPackage.eINSTANCE.getEEFGenModelReference_ReferencedContext().equals(msg.getFeature()) && basePart != null && isAccessible(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel)) - basePart.setReferencedEEFGenModel((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - EEFGenPackage.eINSTANCE.getEEFGenModelReference_ReferencedContext() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/GenEditionContextPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/GenEditionContextPropertiesEditionComponent.java deleted file mode 100644 index b3c840c12..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/GenEditionContextPropertiesEditionComponent.java +++ /dev/null @@ -1,411 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart; -import org.eclipse.emf.eef.components.ComponentsFactory; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class GenEditionContextPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for propertiesEditionContext EObjectFlatComboViewer - */ - private EObjectFlatComboSettings propertiesEditionContextSettings; - - - /** - * Default constructor - * - */ - public GenEditionContextPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject genEditionContext, String editing_mode) { - super(editingContext, genEditionContext, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EEFGenViewsRepository.class; - partKey = EEFGenViewsRepository.GenEditionContext.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final GenEditionContext genEditionContext = (GenEditionContext)elt; - final GenEditionContextPropertiesEditionPart basePart = (GenEditionContextPropertiesEditionPart)editingPart; - // init values - if (isAccessible(EEFGenViewsRepository.GenEditionContext.Parameters.basePackage)) - basePart.setBasePackage(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, genEditionContext.getBasePackage())); - - if (isAccessible(EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID)) - basePart.setDescriptorsContributorID(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, genEditionContext.getDescriptorsContributorID())); - - if (isAccessible(EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors)) { - basePart.setGenericPropertiesViewsDescriptors(genEditionContext.isDescriptorsGenericPropertiesViews()); - } - if (isAccessible(EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews)) { - basePart.setGMFSpecificPropertiesViews(genEditionContext.isGmfPropertiesViews()); - } - if (isAccessible(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext)) { - // init part - propertiesEditionContextSettings = new EObjectFlatComboSettings(genEditionContext, EEFGenPackage.eINSTANCE.getGenEditionContext_PropertiesEditionContext()); - basePart.initPropertiesEditionContext(propertiesEditionContextSettings); - // set the button mode - basePart.setPropertiesEditionContextButtonMode(ButtonsModeEnum.BROWSE); - } - if (isAccessible(EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases)) { - basePart.setJUnitTestCases(genEditionContext.isGenerateJunitTestCases()); - } - if (isAccessible(EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass)) - basePart.setLeafComponentsSuperClass(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, genEditionContext.getLeafComponentsSuperClass())); - - if (isAccessible(EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass)) - basePart.setPropertiesEditingProvidersSuperClass(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, genEditionContext.getPropertiesEditingProvidersSuperClass())); - - // init filters - - - - - if (isAccessible(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext)) { - basePart.addFilterToPropertiesEditionContext(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof PropertiesEditionContext); - } - - }); - // Start of user code for additional businessfilters for propertiesEditionContext - - // End of user code - } - - - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EEFGenViewsRepository.GenEditionContext.Parameters.basePackage) { - return EEFGenPackage.eINSTANCE.getGenEditionContext_BasePackage(); - } - if (editorKey == EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID) { - return EEFGenPackage.eINSTANCE.getGenEditionContext_DescriptorsContributorID(); - } - if (editorKey == EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors) { - return EEFGenPackage.eINSTANCE.getGenEditionContext_DescriptorsGenericPropertiesViews(); - } - if (editorKey == EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews) { - return EEFGenPackage.eINSTANCE.getGenEditionContext_GmfPropertiesViews(); - } - if (editorKey == EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext) { - return EEFGenPackage.eINSTANCE.getGenEditionContext_PropertiesEditionContext(); - } - if (editorKey == EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases) { - return EEFGenPackage.eINSTANCE.getGenEditionContext_GenerateJunitTestCases(); - } - if (editorKey == EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass) { - return EEFGenPackage.eINSTANCE.getGenEditionContext_LeafComponentsSuperClass(); - } - if (editorKey == EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass) { - return EEFGenPackage.eINSTANCE.getGenEditionContext_PropertiesEditingProvidersSuperClass(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - GenEditionContext genEditionContext = (GenEditionContext)semanticObject; - if (EEFGenViewsRepository.GenEditionContext.Parameters.basePackage == event.getAffectedEditor()) { - genEditionContext.setBasePackage((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID == event.getAffectedEditor()) { - genEditionContext.setDescriptorsContributorID((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors == event.getAffectedEditor()) { - genEditionContext.setDescriptorsGenericPropertiesViews((Boolean)event.getNewValue()); - } - if (EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews == event.getAffectedEditor()) { - genEditionContext.setGmfPropertiesViews((Boolean)event.getNewValue()); - } - if (EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - propertiesEditionContextSettings.setToReference((PropertiesEditionContext)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - PropertiesEditionContext eObject = ComponentsFactory.eINSTANCE.createPropertiesEditionContext(); - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - propertiesEditionContextSettings.setToReference(eObject); - } - } - if (EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases == event.getAffectedEditor()) { - genEditionContext.setGenerateJunitTestCases((Boolean)event.getNewValue()); - } - if (EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass == event.getAffectedEditor()) { - genEditionContext.setLeafComponentsSuperClass((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass == event.getAffectedEditor()) { - genEditionContext.setPropertiesEditingProvidersSuperClass((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - GenEditionContextPropertiesEditionPart basePart = (GenEditionContextPropertiesEditionPart)editingPart; - if (EEFGenPackage.eINSTANCE.getGenEditionContext_BasePackage().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenEditionContext.Parameters.basePackage)) { - if (msg.getNewValue() != null) { - basePart.setBasePackage(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setBasePackage(""); - } - } - if (EEFGenPackage.eINSTANCE.getGenEditionContext_DescriptorsContributorID().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID)) { - if (msg.getNewValue() != null) { - basePart.setDescriptorsContributorID(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setDescriptorsContributorID(""); - } - } - if (EEFGenPackage.eINSTANCE.getGenEditionContext_DescriptorsGenericPropertiesViews().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors)) - basePart.setGenericPropertiesViewsDescriptors((Boolean)msg.getNewValue()); - - if (EEFGenPackage.eINSTANCE.getGenEditionContext_GmfPropertiesViews().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews)) - basePart.setGMFSpecificPropertiesViews((Boolean)msg.getNewValue()); - - if (EEFGenPackage.eINSTANCE.getGenEditionContext_PropertiesEditionContext().equals(msg.getFeature()) && basePart != null && isAccessible(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext)) - basePart.setPropertiesEditionContext((EObject)msg.getNewValue()); - if (EEFGenPackage.eINSTANCE.getGenEditionContext_GenerateJunitTestCases().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases)) - basePart.setJUnitTestCases((Boolean)msg.getNewValue()); - - if (EEFGenPackage.eINSTANCE.getGenEditionContext_LeafComponentsSuperClass().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass)) { - if (msg.getNewValue() != null) { - basePart.setLeafComponentsSuperClass(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setLeafComponentsSuperClass(""); - } - } - if (EEFGenPackage.eINSTANCE.getGenEditionContext_PropertiesEditingProvidersSuperClass().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass)) { - if (msg.getNewValue() != null) { - basePart.setPropertiesEditingProvidersSuperClass(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setPropertiesEditingProvidersSuperClass(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - EEFGenPackage.eINSTANCE.getGenEditionContext_BasePackage(), - EEFGenPackage.eINSTANCE.getGenEditionContext_DescriptorsContributorID(), - EEFGenPackage.eINSTANCE.getGenEditionContext_DescriptorsGenericPropertiesViews(), - EEFGenPackage.eINSTANCE.getGenEditionContext_GmfPropertiesViews(), - EEFGenPackage.eINSTANCE.getGenEditionContext_PropertiesEditionContext(), - EEFGenPackage.eINSTANCE.getGenEditionContext_GenerateJunitTestCases(), - EEFGenPackage.eINSTANCE.getGenEditionContext_LeafComponentsSuperClass(), - EEFGenPackage.eINSTANCE.getGenEditionContext_PropertiesEditingProvidersSuperClass() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == EEFGenViewsRepository.GenEditionContext.Parameters.basePackage) - return "The base package for all the generated code"; //$NON-NLS-1$ - if (key == EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext) - return "The PropertiesEditioContext to describe"; //$NON-NLS-1$ - if (key == EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass) - return "The base from which implementations of leaf PropertiesEditingComponents extend"; //$NON-NLS-1$ - if (key == EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass) - return "The base from which implementations of leaf PropertiesEditingProviders extend"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EEFGenViewsRepository.GenEditionContext.Parameters.basePackage == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenEditionContext_BasePackage().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenEditionContext_BasePackage().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenEditionContext_DescriptorsContributorID().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenEditionContext_DescriptorsContributorID().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenEditionContext_DescriptorsGenericPropertiesViews().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenEditionContext_DescriptorsGenericPropertiesViews().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenEditionContext_GmfPropertiesViews().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenEditionContext_GmfPropertiesViews().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenEditionContext_GenerateJunitTestCases().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenEditionContext_GenerateJunitTestCases().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenEditionContext_LeafComponentsSuperClass().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenEditionContext_LeafComponentsSuperClass().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenEditionContext_PropertiesEditingProvidersSuperClass().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenEditionContext_PropertiesEditingProvidersSuperClass().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/GenViewsRepositoryPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/GenViewsRepositoryPropertiesEditionComponent.java deleted file mode 100644 index 3dd5cef2e..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/components/GenViewsRepositoryPropertiesEditionComponent.java +++ /dev/null @@ -1,383 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; -import org.eclipse.emf.eef.EEFGen.HELP_STRATEGY; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.views.ViewsFactory; -import org.eclipse.emf.eef.views.ViewsRepository; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class GenViewsRepositoryPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for viewsRepository EObjectFlatComboViewer - */ - private EObjectFlatComboSettings viewsRepositorySettings; - - - /** - * Default constructor - * - */ - public GenViewsRepositoryPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject genViewsRepository, String editing_mode) { - super(editingContext, genViewsRepository, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = EEFGenViewsRepository.class; - partKey = EEFGenViewsRepository.GenViewsRepository.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final GenViewsRepository genViewsRepository = (GenViewsRepository)elt; - final GenViewsRepositoryPropertiesEditionPart basePart = (GenViewsRepositoryPropertiesEditionPart)editingPart; - // init values - if (isAccessible(EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage)) - basePart.setBasePackage(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, genViewsRepository.getBasePackage())); - - if (isAccessible(EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews)) { - basePart.setSWTViews(genViewsRepository.isSwtViews()); - } - if (isAccessible(EEFGenViewsRepository.GenViewsRepository.Activation.formsViews)) { - basePart.setFormsViews(genViewsRepository.isFormViews()); - } - if (isAccessible(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy)) { - basePart.initHelpStrategy(EEFUtils.choiceOfValues(genViewsRepository, EEFGenPackage.eINSTANCE.getGenViewsRepository_HelpStrategy()), genViewsRepository.getHelpStrategy()); - } - if (isAccessible(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository)) { - // init part - viewsRepositorySettings = new EObjectFlatComboSettings(genViewsRepository, EEFGenPackage.eINSTANCE.getGenViewsRepository_ViewsRepository()); - basePart.initViewsRepository(viewsRepositorySettings); - // set the button mode - basePart.setViewsRepositoryButtonMode(ButtonsModeEnum.BROWSE); - } - if (isAccessible(EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass)) - basePart.setPartsSuperClass(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, genViewsRepository.getPartsSuperClass())); - - if (isAccessible(EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass)) - basePart.setFormsSuperClass(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, genViewsRepository.getFormsSuperClass())); - - // init filters - - - - - if (isAccessible(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository)) { - basePart.addFilterToViewsRepository(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof ViewsRepository); - } - - }); - // Start of user code for additional businessfilters for viewsRepository - - // End of user code - } - - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage) { - return EEFGenPackage.eINSTANCE.getGenViewsRepository_BasePackage(); - } - if (editorKey == EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews) { - return EEFGenPackage.eINSTANCE.getGenViewsRepository_SwtViews(); - } - if (editorKey == EEFGenViewsRepository.GenViewsRepository.Activation.formsViews) { - return EEFGenPackage.eINSTANCE.getGenViewsRepository_FormViews(); - } - if (editorKey == EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy) { - return EEFGenPackage.eINSTANCE.getGenViewsRepository_HelpStrategy(); - } - if (editorKey == EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository) { - return EEFGenPackage.eINSTANCE.getGenViewsRepository_ViewsRepository(); - } - if (editorKey == EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass) { - return EEFGenPackage.eINSTANCE.getGenViewsRepository_PartsSuperClass(); - } - if (editorKey == EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass) { - return EEFGenPackage.eINSTANCE.getGenViewsRepository_FormsSuperClass(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - GenViewsRepository genViewsRepository = (GenViewsRepository)semanticObject; - if (EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage == event.getAffectedEditor()) { - genViewsRepository.setBasePackage((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews == event.getAffectedEditor()) { - genViewsRepository.setSwtViews((Boolean)event.getNewValue()); - } - if (EEFGenViewsRepository.GenViewsRepository.Activation.formsViews == event.getAffectedEditor()) { - genViewsRepository.setFormViews((Boolean)event.getNewValue()); - } - if (EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy == event.getAffectedEditor()) { - genViewsRepository.setHelpStrategy((HELP_STRATEGY)event.getNewValue()); - } - if (EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - viewsRepositorySettings.setToReference((ViewsRepository)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - ViewsRepository eObject = ViewsFactory.eINSTANCE.createViewsRepository(); - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - viewsRepositorySettings.setToReference(eObject); - } - } - if (EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass == event.getAffectedEditor()) { - genViewsRepository.setPartsSuperClass((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass == event.getAffectedEditor()) { - genViewsRepository.setFormsSuperClass((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - GenViewsRepositoryPropertiesEditionPart basePart = (GenViewsRepositoryPropertiesEditionPart)editingPart; - if (EEFGenPackage.eINSTANCE.getGenViewsRepository_BasePackage().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage)) { - if (msg.getNewValue() != null) { - basePart.setBasePackage(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setBasePackage(""); - } - } - if (EEFGenPackage.eINSTANCE.getGenViewsRepository_SwtViews().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews)) - basePart.setSWTViews((Boolean)msg.getNewValue()); - - if (EEFGenPackage.eINSTANCE.getGenViewsRepository_FormViews().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenViewsRepository.Activation.formsViews)) - basePart.setFormsViews((Boolean)msg.getNewValue()); - - if (EEFGenPackage.eINSTANCE.getGenViewsRepository_HelpStrategy().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && isAccessible(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy)) - basePart.setHelpStrategy((HELP_STRATEGY)msg.getNewValue()); - - if (EEFGenPackage.eINSTANCE.getGenViewsRepository_ViewsRepository().equals(msg.getFeature()) && basePart != null && isAccessible(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository)) - basePart.setViewsRepository((EObject)msg.getNewValue()); - if (EEFGenPackage.eINSTANCE.getGenViewsRepository_PartsSuperClass().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass)) { - if (msg.getNewValue() != null) { - basePart.setPartsSuperClass(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setPartsSuperClass(""); - } - } - if (EEFGenPackage.eINSTANCE.getGenViewsRepository_FormsSuperClass().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass)) { - if (msg.getNewValue() != null) { - basePart.setFormsSuperClass(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setFormsSuperClass(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - EEFGenPackage.eINSTANCE.getGenViewsRepository_BasePackage(), - EEFGenPackage.eINSTANCE.getGenViewsRepository_SwtViews(), - EEFGenPackage.eINSTANCE.getGenViewsRepository_FormViews(), - EEFGenPackage.eINSTANCE.getGenViewsRepository_HelpStrategy(), - EEFGenPackage.eINSTANCE.getGenViewsRepository_ViewsRepository(), - EEFGenPackage.eINSTANCE.getGenViewsRepository_PartsSuperClass(), - EEFGenPackage.eINSTANCE.getGenViewsRepository_FormsSuperClass() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy || key == EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass) - return "The base class from which implementations of leaf PropertiesEditingParts extend"; //$NON-NLS-1$ - if (key == EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass) - return "The base class from which implementations of leaf PropertiesEditingParts extend"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenViewsRepository_BasePackage().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenViewsRepository_BasePackage().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenViewsRepository_SwtViews().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenViewsRepository_SwtViews().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenViewsRepository.Activation.formsViews == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenViewsRepository_FormViews().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenViewsRepository_FormViews().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenViewsRepository_HelpStrategy().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenViewsRepository_HelpStrategy().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenViewsRepository_PartsSuperClass().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenViewsRepository_PartsSuperClass().getEAttributeType(), newValue); - } - if (EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(EEFGenPackage.eINSTANCE.getGenViewsRepository_FormsSuperClass().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(EEFGenPackage.eINSTANCE.getGenViewsRepository_FormsSuperClass().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenModelPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenModelPropertiesEditionPart.java deleted file mode 100644 index d675cdc83..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenModelPropertiesEditionPart.java +++ /dev/null @@ -1,111 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts; - -// Start of user code for imports - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface EEFGenModelPropertiesEditionPart { - - /** - * @return the Generation directory - * - */ - public String getGenerationDirectory(); - - /** - * Defines a new Generation directory - * @param newValue the new Generation directory to set - * - */ - public void setGenerationDirectory(String newValue); - - - /** - * @return the Tests generation directory - * - */ - public String getTestsGenerationDirectory(); - - /** - * Defines a new Tests generation directory - * @param newValue the new Tests generation directory to set - * - */ - public void setTestsGenerationDirectory(String newValue); - - - /** - * @return the Use JMerge to manage user code - * - */ - public Boolean getUseJMergeToManageUserCode(); - - /** - * Defines a new Use JMerge to manage user code - * @param newValue the new Use JMerge to manage user code to set - * - */ - public void setUseJMergeToManageUserCode(Boolean newValue); - - - /** - * @return the author - * - */ - public String getAuthor(); - - /** - * Defines a new author - * @param newValue the new author to set - * - */ - public void setAuthor(String newValue); - - - /** - * @return the license - * - */ - public String getLicense(); - - /** - * Defines a new license - * @param newValue the new license to set - * - */ - public void setLicense(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenModelReferencePropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenModelReferencePropertiesEditionPart.java deleted file mode 100644 index 1e6349589..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenModelReferencePropertiesEditionPart.java +++ /dev/null @@ -1,91 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface EEFGenModelReferencePropertiesEditionPart { - - /** - * @return the Referenced EEFGenModel - * - */ - public EObject getReferencedEEFGenModel(); - - /** - * Init the Referenced EEFGenModel - * @param settings the combo setting - */ - public void initReferencedEEFGenModel(EObjectFlatComboSettings settings); - - /** - * Defines a new Referenced EEFGenModel - * @param newValue the new Referenced EEFGenModel to set - * - */ - public void setReferencedEEFGenModel(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setReferencedEEFGenModelButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the Referenced EEFGenModel edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToReferencedEEFGenModel(ViewerFilter filter); - - /** - * Adds the given filter to the Referenced EEFGenModel edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToReferencedEEFGenModel(ViewerFilter filter); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenViewsRepository.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenViewsRepository.java deleted file mode 100644 index 8d563003d..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/EEFGenViewsRepository.java +++ /dev/null @@ -1,170 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts; - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenViewsRepository { - - public static final int SWT_KIND = 0; - - public static final int FORM_KIND = 1; - - - /** - * GenEditionContext view descriptor - * - */ - public static class GenEditionContext { - public static class Reference { - - - public static String propertiesEditionContext = "EEFGen::GenEditionContext::Reference::properties Edition Context"; - - - } - - public static class Parameters { - - - public static String basePackage = "EEFGen::GenEditionContext::Parameters::Base package"; - - - public static String descriptorsContributorID = "EEFGen::GenEditionContext::Parameters::Descriptors contributorID"; - - - } - - public static class Activation { - - - public static String genericPropertiesViewsDescriptors = "EEFGen::GenEditionContext::Activation::Generic properties views descriptors"; - - - public static String gMFSpecificPropertiesViews = "EEFGen::GenEditionContext::Activation::GMF specific properties views"; - - - public static String jUnitTestCases = "EEFGen::GenEditionContext::Activation::JUnit test cases"; - - - } - - public static class Implementation { - - - public static String leafComponentsSuperClass = "EEFGen::GenEditionContext::Implementation::leafComponentsSuperClass"; - - - public static String propertiesEditingProvidersSuperClass = "EEFGen::GenEditionContext::Implementation::propertiesEditingProvidersSuperClass"; - - - } - - } - - /** - * EEFGenModelReference view descriptor - * - */ - public static class EEFGenModelReference { - public static class Reference { - - - public static String referencedEEFGenModel = "EEFGen::EEFGenModelReference::Reference::Referenced EEFGenModel"; - - - } - - } - - /** - * EEFGenModel view descriptor - * - */ - public static class EEFGenModel { - public static class Parameters { - - - public static String generationDirectory = "EEFGen::EEFGenModel::Parameters::Generation directory"; - - - public static String testsGenerationDirectory = "EEFGen::EEFGenModel::Parameters::Tests generation directory"; - - - public static String useJMergeToManageUserCode = "EEFGen::EEFGenModel::Parameters::Use JMerge to manage user code"; - - - } - - public static class Legal { - - - public static String author = "EEFGen::EEFGenModel::Legal::author"; - - - public static String license = "EEFGen::EEFGenModel::Legal::license"; - - - } - - } - - /** - * GenViewsRepository view descriptor - * - */ - public static class GenViewsRepository { - public static class Reference { - - - public static String viewsRepository = "EEFGen::GenViewsRepository::Reference::Views repository"; - - - } - - public static class Parameters { - - - public static String basePackage = "EEFGen::GenViewsRepository::Parameters::Base package"; - - - public static String helpStrategy = "EEFGen::GenViewsRepository::Parameters::Help strategy"; - - - } - - public static class Activation { - - - public static String sWTViews = "EEFGen::GenViewsRepository::Activation::SWT views"; - - - public static String formsViews = "EEFGen::GenViewsRepository::Activation::Forms views"; - - - } - - public static class Implementation { - - - public static String partsSuperClass = "EEFGen::GenViewsRepository::Implementation::partsSuperClass"; - - - public static String formsSuperClass = "EEFGen::GenViewsRepository::Implementation::formsSuperClass"; - - - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/GenEditionContextPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/GenEditionContextPropertiesEditionPart.java deleted file mode 100644 index c7f582520..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/GenEditionContextPropertiesEditionPart.java +++ /dev/null @@ -1,189 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface GenEditionContextPropertiesEditionPart { - - /** - * @return the properties Edition Context - * - */ - public EObject getPropertiesEditionContext(); - - /** - * Init the properties Edition Context - * @param settings the combo setting - */ - public void initPropertiesEditionContext(EObjectFlatComboSettings settings); - - /** - * Defines a new properties Edition Context - * @param newValue the new properties Edition Context to set - * - */ - public void setPropertiesEditionContext(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setPropertiesEditionContextButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the properties Edition Context edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToPropertiesEditionContext(ViewerFilter filter); - - /** - * Adds the given filter to the properties Edition Context edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToPropertiesEditionContext(ViewerFilter filter); - - - /** - * @return the Base package - * - */ - public String getBasePackage(); - - /** - * Defines a new Base package - * @param newValue the new Base package to set - * - */ - public void setBasePackage(String newValue); - - - /** - * @return the Descriptors contributorID - * - */ - public String getDescriptorsContributorID(); - - /** - * Defines a new Descriptors contributorID - * @param newValue the new Descriptors contributorID to set - * - */ - public void setDescriptorsContributorID(String newValue); - - - /** - * @return the Generic properties views descriptors - * - */ - public Boolean getGenericPropertiesViewsDescriptors(); - - /** - * Defines a new Generic properties views descriptors - * @param newValue the new Generic properties views descriptors to set - * - */ - public void setGenericPropertiesViewsDescriptors(Boolean newValue); - - - /** - * @return the GMF specific properties views - * - */ - public Boolean getGMFSpecificPropertiesViews(); - - /** - * Defines a new GMF specific properties views - * @param newValue the new GMF specific properties views to set - * - */ - public void setGMFSpecificPropertiesViews(Boolean newValue); - - - /** - * @return the JUnit test cases - * - */ - public Boolean getJUnitTestCases(); - - /** - * Defines a new JUnit test cases - * @param newValue the new JUnit test cases to set - * - */ - public void setJUnitTestCases(Boolean newValue); - - - /** - * @return the leafComponentsSuperClass - * - */ - public String getLeafComponentsSuperClass(); - - /** - * Defines a new leafComponentsSuperClass - * @param newValue the new leafComponentsSuperClass to set - * - */ - public void setLeafComponentsSuperClass(String newValue); - - - /** - * @return the propertiesEditingProvidersSuperClass - * - */ - public String getPropertiesEditingProvidersSuperClass(); - - /** - * Defines a new propertiesEditingProvidersSuperClass - * @param newValue the new propertiesEditingProvidersSuperClass to set - * - */ - public void setPropertiesEditingProvidersSuperClass(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/GenViewsRepositoryPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/GenViewsRepositoryPropertiesEditionPart.java deleted file mode 100644 index 5319fab41..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/GenViewsRepositoryPropertiesEditionPart.java +++ /dev/null @@ -1,183 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts; - -// Start of user code for imports -import org.eclipse.emf.common.util.Enumerator; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface GenViewsRepositoryPropertiesEditionPart { - - /** - * @return the Views repository - * - */ - public EObject getViewsRepository(); - - /** - * Init the Views repository - * @param settings the combo setting - */ - public void initViewsRepository(EObjectFlatComboSettings settings); - - /** - * Defines a new Views repository - * @param newValue the new Views repository to set - * - */ - public void setViewsRepository(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setViewsRepositoryButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the Views repository edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViewsRepository(ViewerFilter filter); - - /** - * Adds the given filter to the Views repository edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViewsRepository(ViewerFilter filter); - - - /** - * @return the Base package - * - */ - public String getBasePackage(); - - /** - * Defines a new Base package - * @param newValue the new Base package to set - * - */ - public void setBasePackage(String newValue); - - - /** - * @return the Help strategy - * - */ - public Enumerator getHelpStrategy(); - - /** - * Init the Help strategy - * @param input the viewer input - * @param current the current value - */ - public void initHelpStrategy(Object input, Enumerator current); - - /** - * Defines a new Help strategy - * @param newValue the new Help strategy to set - * - */ - public void setHelpStrategy(Enumerator newValue); - - - /** - * @return the SWT views - * - */ - public Boolean getSWTViews(); - - /** - * Defines a new SWT views - * @param newValue the new SWT views to set - * - */ - public void setSWTViews(Boolean newValue); - - - /** - * @return the Forms views - * - */ - public Boolean getFormsViews(); - - /** - * Defines a new Forms views - * @param newValue the new Forms views to set - * - */ - public void setFormsViews(Boolean newValue); - - - /** - * @return the partsSuperClass - * - */ - public String getPartsSuperClass(); - - /** - * Defines a new partsSuperClass - * @param newValue the new partsSuperClass to set - * - */ - public void setPartsSuperClass(String newValue); - - - /** - * @return the formsSuperClass - * - */ - public String getFormsSuperClass(); - - /** - * Defines a new formsSuperClass - * @param newValue the new formsSuperClass to set - * - */ - public void setFormsSuperClass(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/EEFGenModelPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/EEFGenModelPropertiesEditionPartForm.java deleted file mode 100644 index 1bec59628..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/EEFGenModelPropertiesEditionPartForm.java +++ /dev/null @@ -1,664 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.EEFGen.providers.EEFGenMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenModelPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, EEFGenModelPropertiesEditionPart { - - protected Text generationDirectory; - protected Text testsGenerationDirectory; - protected Button useJMergeToManageUserCode; - protected Text author; - protected Text license; - - - - /** - * For {@link ISection} use only. - */ - public EEFGenModelPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EEFGenModelPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence eEFGenModelStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep parametersStep = eEFGenModelStep.addStep(EEFGenViewsRepository.EEFGenModel.Parameters.class); - parametersStep.addStep(EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory); - parametersStep.addStep(EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory); - parametersStep.addStep(EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode); - - CompositionStep legalStep = eEFGenModelStep.addStep(EEFGenViewsRepository.EEFGenModel.Legal.class); - legalStep.addStep(EEFGenViewsRepository.EEFGenModel.Legal.author); - legalStep.addStep(EEFGenViewsRepository.EEFGenModel.Legal.license); - - - composer = new PartComposer(eEFGenModelStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EEFGenViewsRepository.EEFGenModel.Parameters.class) { - return createParametersGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory) { - return createGenerationDirectoryText(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory) { - return createTestsGenerationDirectoryText(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode) { - return createUseJMergeToManageUserCodeCheckbox(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Legal.class) { - return createLegalGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Legal.author) { - return createAuthorText(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Legal.license) { - return createLicenseTextarea(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createParametersGroup(FormToolkit widgetFactory, final Composite parent) { - Section parametersSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - parametersSection.setText(EEFGenMessages.EEFGenModelPropertiesEditionPart_ParametersGroupLabel); - GridData parametersSectionData = new GridData(GridData.FILL_HORIZONTAL); - parametersSectionData.horizontalSpan = 3; - parametersSection.setLayoutData(parametersSectionData); - Composite parametersGroup = widgetFactory.createComposite(parametersSection); - GridLayout parametersGroupLayout = new GridLayout(); - parametersGroupLayout.numColumns = 3; - parametersGroup.setLayout(parametersGroupLayout); - parametersSection.setClient(parametersGroup); - return parametersGroup; - } - - - protected Composite createGenerationDirectoryText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory, EEFGenMessages.EEFGenModelPropertiesEditionPart_GenerationDirectoryLabel); - generationDirectory = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - generationDirectory.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData generationDirectoryData = new GridData(GridData.FILL_HORIZONTAL); - generationDirectory.setLayoutData(generationDirectoryData); - generationDirectory.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, generationDirectory.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, generationDirectory.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - generationDirectory.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartForm.this, EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, generationDirectory.getText())); - } - } - }); - EditingUtils.setID(generationDirectory, EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory); - EditingUtils.setEEFtype(generationDirectory, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createGenerationDirectoryText - - // End of user code - return parent; - } - - - protected Composite createTestsGenerationDirectoryText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory, EEFGenMessages.EEFGenModelPropertiesEditionPart_TestsGenerationDirectoryLabel); - testsGenerationDirectory = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - testsGenerationDirectory.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData testsGenerationDirectoryData = new GridData(GridData.FILL_HORIZONTAL); - testsGenerationDirectory.setLayoutData(testsGenerationDirectoryData); - testsGenerationDirectory.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, testsGenerationDirectory.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, testsGenerationDirectory.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - testsGenerationDirectory.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartForm.this, EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, testsGenerationDirectory.getText())); - } - } - }); - EditingUtils.setID(testsGenerationDirectory, EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory); - EditingUtils.setEEFtype(testsGenerationDirectory, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createTestsGenerationDirectoryText - - // End of user code - return parent; - } - - - protected Composite createUseJMergeToManageUserCodeCheckbox(FormToolkit widgetFactory, Composite parent) { - useJMergeToManageUserCode = widgetFactory.createButton(parent, getDescription(EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode, EEFGenMessages.EEFGenModelPropertiesEditionPart_UseJMergeToManageUserCodeLabel), SWT.CHECK); - useJMergeToManageUserCode.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartForm.this, EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(useJMergeToManageUserCode.getSelection()))); - } - - }); - GridData useJMergeToManageUserCodeData = new GridData(GridData.FILL_HORIZONTAL); - useJMergeToManageUserCodeData.horizontalSpan = 2; - useJMergeToManageUserCode.setLayoutData(useJMergeToManageUserCodeData); - EditingUtils.setID(useJMergeToManageUserCode, EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode); - EditingUtils.setEEFtype(useJMergeToManageUserCode, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createUseJMergeToManageUserCodeCheckbox - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createLegalGroup(FormToolkit widgetFactory, final Composite parent) { - Section legalSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - legalSection.setText(EEFGenMessages.EEFGenModelPropertiesEditionPart_LegalGroupLabel); - GridData legalSectionData = new GridData(GridData.FILL_HORIZONTAL); - legalSectionData.horizontalSpan = 3; - legalSection.setLayoutData(legalSectionData); - Composite legalGroup = widgetFactory.createComposite(legalSection); - GridLayout legalGroupLayout = new GridLayout(); - legalGroupLayout.numColumns = 3; - legalGroup.setLayout(legalGroupLayout); - legalSection.setClient(legalGroup); - return legalGroup; - } - - - protected Composite createAuthorText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.EEFGenModel.Legal.author, EEFGenMessages.EEFGenModelPropertiesEditionPart_AuthorLabel); - author = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - author.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData authorData = new GridData(GridData.FILL_HORIZONTAL); - author.setLayoutData(authorData); - author.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - EEFGenViewsRepository.EEFGenModel.Legal.author, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, author.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - EEFGenViewsRepository.EEFGenModel.Legal.author, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, author.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - author.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartForm.this, EEFGenViewsRepository.EEFGenModel.Legal.author, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, author.getText())); - } - } - }); - EditingUtils.setID(author, EEFGenViewsRepository.EEFGenModel.Legal.author); - EditingUtils.setEEFtype(author, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModel.Legal.author, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createAuthorText - - // End of user code - return parent; - } - - - protected Composite createLicenseTextarea(FormToolkit widgetFactory, Composite parent) { - Label licenseLabel = createDescription(parent, EEFGenViewsRepository.EEFGenModel.Legal.license, EEFGenMessages.EEFGenModelPropertiesEditionPart_LicenseLabel); - GridData licenseLabelData = new GridData(GridData.FILL_HORIZONTAL); - licenseLabelData.horizontalSpan = 3; - licenseLabel.setLayoutData(licenseLabelData); - license = widgetFactory.createText(parent, "", SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); //$NON-NLS-1$ - GridData licenseData = new GridData(GridData.FILL_HORIZONTAL); - licenseData.horizontalSpan = 2; - licenseData.heightHint = 80; - licenseData.widthHint = 200; - license.setLayoutData(licenseData); - license.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - EEFGenViewsRepository.EEFGenModel.Legal.license, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, license.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - EEFGenViewsRepository.EEFGenModel.Legal.license, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, license.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EEFGenModelPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - EditingUtils.setID(license, EEFGenViewsRepository.EEFGenModel.Legal.license); - EditingUtils.setEEFtype(license, "eef::Textarea"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModel.Legal.license, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createLicenseTextArea - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#getGenerationDirectory() - * - */ - public String getGenerationDirectory() { - return generationDirectory.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#setGenerationDirectory(String newValue) - * - */ - public void setGenerationDirectory(String newValue) { - if (newValue != null) { - generationDirectory.setText(newValue); - } else { - generationDirectory.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory); - if (eefElementEditorReadOnlyState && generationDirectory.isEnabled()) { - generationDirectory.setEnabled(false); - generationDirectory.setToolTipText(EEFGenMessages.EEFGenModel_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !generationDirectory.isEnabled()) { - generationDirectory.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#getTestsGenerationDirectory() - * - */ - public String getTestsGenerationDirectory() { - return testsGenerationDirectory.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#setTestsGenerationDirectory(String newValue) - * - */ - public void setTestsGenerationDirectory(String newValue) { - if (newValue != null) { - testsGenerationDirectory.setText(newValue); - } else { - testsGenerationDirectory.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory); - if (eefElementEditorReadOnlyState && testsGenerationDirectory.isEnabled()) { - testsGenerationDirectory.setEnabled(false); - testsGenerationDirectory.setToolTipText(EEFGenMessages.EEFGenModel_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !testsGenerationDirectory.isEnabled()) { - testsGenerationDirectory.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#getUseJMergeToManageUserCode() - * - */ - public Boolean getUseJMergeToManageUserCode() { - return Boolean.valueOf(useJMergeToManageUserCode.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#setUseJMergeToManageUserCode(Boolean newValue) - * - */ - public void setUseJMergeToManageUserCode(Boolean newValue) { - if (newValue != null) { - useJMergeToManageUserCode.setSelection(newValue.booleanValue()); - } else { - useJMergeToManageUserCode.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode); - if (eefElementEditorReadOnlyState && useJMergeToManageUserCode.isEnabled()) { - useJMergeToManageUserCode.setEnabled(false); - useJMergeToManageUserCode.setToolTipText(EEFGenMessages.EEFGenModel_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !useJMergeToManageUserCode.isEnabled()) { - useJMergeToManageUserCode.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#getAuthor() - * - */ - public String getAuthor() { - return author.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#setAuthor(String newValue) - * - */ - public void setAuthor(String newValue) { - if (newValue != null) { - author.setText(newValue); - } else { - author.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModel.Legal.author); - if (eefElementEditorReadOnlyState && author.isEnabled()) { - author.setEnabled(false); - author.setToolTipText(EEFGenMessages.EEFGenModel_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !author.isEnabled()) { - author.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#getLicense() - * - */ - public String getLicense() { - return license.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#setLicense(String newValue) - * - */ - public void setLicense(String newValue) { - if (newValue != null) { - license.setText(newValue); - } else { - license.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModel.Legal.license); - if (eefElementEditorReadOnlyState && license.isEnabled()) { - license.setEnabled(false); - license.setBackground(license.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - license.setToolTipText(EEFGenMessages.EEFGenModel_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !license.isEnabled()) { - license.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EEFGenMessages.EEFGenModel_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/EEFGenModelReferencePropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/EEFGenModelReferencePropertiesEditionPartForm.java deleted file mode 100644 index 360a19c69..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/EEFGenModelReferencePropertiesEditionPartForm.java +++ /dev/null @@ -1,287 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.EEFGen.providers.EEFGenMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenModelReferencePropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, EEFGenModelReferencePropertiesEditionPart { - - protected EObjectFlatComboViewer referencedEEFGenModel; - - - - /** - * For {@link ISection} use only. - */ - public EEFGenModelReferencePropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EEFGenModelReferencePropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence eEFGenModelReferenceStep = new BindingCompositionSequence(propertiesEditionComponent); - eEFGenModelReferenceStep - .addStep(EEFGenViewsRepository.EEFGenModelReference.Reference.class) - .addStep(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel); - - - composer = new PartComposer(eEFGenModelReferenceStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EEFGenViewsRepository.EEFGenModelReference.Reference.class) { - return createReferenceGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel) { - return createReferencedEEFGenModelFlatComboViewer(parent, widgetFactory); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createReferenceGroup(FormToolkit widgetFactory, final Composite parent) { - Section referenceSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - referenceSection.setText(EEFGenMessages.EEFGenModelReferencePropertiesEditionPart_ReferenceGroupLabel); - GridData referenceSectionData = new GridData(GridData.FILL_HORIZONTAL); - referenceSectionData.horizontalSpan = 3; - referenceSection.setLayoutData(referenceSectionData); - Composite referenceGroup = widgetFactory.createComposite(referenceSection); - GridLayout referenceGroupLayout = new GridLayout(); - referenceGroupLayout.numColumns = 3; - referenceGroup.setLayout(referenceGroupLayout); - referenceSection.setClient(referenceGroup); - return referenceGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createReferencedEEFGenModelFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel, EEFGenMessages.EEFGenModelReferencePropertiesEditionPart_ReferencedEEFGenModelLabel); - referencedEEFGenModel = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel, EEFGenViewsRepository.FORM_KIND)); - widgetFactory.adapt(referencedEEFGenModel); - referencedEEFGenModel.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData referencedEEFGenModelData = new GridData(GridData.FILL_HORIZONTAL); - referencedEEFGenModel.setLayoutData(referencedEEFGenModelData); - referencedEEFGenModel.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelReferencePropertiesEditionPartForm.this, EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getReferencedEEFGenModel())); - } - - }); - referencedEEFGenModel.setID(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createReferencedEEFGenModelFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#getReferencedEEFGenModel() - * - */ - public EObject getReferencedEEFGenModel() { - if (referencedEEFGenModel.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) referencedEEFGenModel.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#initReferencedEEFGenModel(EObjectFlatComboSettings) - */ - public void initReferencedEEFGenModel(EObjectFlatComboSettings settings) { - referencedEEFGenModel.setInput(settings); - if (current != null) { - referencedEEFGenModel.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel); - if (eefElementEditorReadOnlyState && referencedEEFGenModel.isEnabled()) { - referencedEEFGenModel.setEnabled(false); - referencedEEFGenModel.setToolTipText(EEFGenMessages.EEFGenModelReference_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !referencedEEFGenModel.isEnabled()) { - referencedEEFGenModel.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#setReferencedEEFGenModel(EObject newValue) - * - */ - public void setReferencedEEFGenModel(EObject newValue) { - if (newValue != null) { - referencedEEFGenModel.setSelection(new StructuredSelection(newValue)); - } else { - referencedEEFGenModel.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel); - if (eefElementEditorReadOnlyState && referencedEEFGenModel.isEnabled()) { - referencedEEFGenModel.setEnabled(false); - referencedEEFGenModel.setToolTipText(EEFGenMessages.EEFGenModelReference_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !referencedEEFGenModel.isEnabled()) { - referencedEEFGenModel.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#setReferencedEEFGenModelButtonMode(ButtonsModeEnum newValue) - */ - public void setReferencedEEFGenModelButtonMode(ButtonsModeEnum newValue) { - referencedEEFGenModel.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#addFilterReferencedEEFGenModel(ViewerFilter filter) - * - */ - public void addFilterToReferencedEEFGenModel(ViewerFilter filter) { - referencedEEFGenModel.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#addBusinessFilterReferencedEEFGenModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToReferencedEEFGenModel(ViewerFilter filter) { - referencedEEFGenModel.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EEFGenMessages.EEFGenModelReference_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/GenEditionContextPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/GenEditionContextPropertiesEditionPartForm.java deleted file mode 100644 index 0ec09085c..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/GenEditionContextPropertiesEditionPartForm.java +++ /dev/null @@ -1,982 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart; -import org.eclipse.emf.eef.EEFGen.providers.EEFGenMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class GenEditionContextPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, GenEditionContextPropertiesEditionPart { - - protected EObjectFlatComboViewer propertiesEditionContext; - protected Text basePackage; - protected Text descriptorsContributorID; - protected Button genericPropertiesViewsDescriptors; - protected Button gMFSpecificPropertiesViews; - protected Button jUnitTestCases; - protected Text leafComponentsSuperClass; - protected Text propertiesEditingProvidersSuperClass; - - - - /** - * For {@link ISection} use only. - */ - public GenEditionContextPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public GenEditionContextPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence genEditionContextStep = new BindingCompositionSequence(propertiesEditionComponent); - genEditionContextStep - .addStep(EEFGenViewsRepository.GenEditionContext.Reference.class) - .addStep(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext); - - CompositionStep parametersStep = genEditionContextStep.addStep(EEFGenViewsRepository.GenEditionContext.Parameters.class); - parametersStep.addStep(EEFGenViewsRepository.GenEditionContext.Parameters.basePackage); - parametersStep.addStep(EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID); - - CompositionStep activationStep = genEditionContextStep.addStep(EEFGenViewsRepository.GenEditionContext.Activation.class); - activationStep.addStep(EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors); - activationStep.addStep(EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews); - activationStep.addStep(EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases); - - CompositionStep implementationStep = genEditionContextStep.addStep(EEFGenViewsRepository.GenEditionContext.Implementation.class); - implementationStep.addStep(EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass); - implementationStep.addStep(EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass); - - - composer = new PartComposer(genEditionContextStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EEFGenViewsRepository.GenEditionContext.Reference.class) { - return createReferenceGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext) { - return createPropertiesEditionContextFlatComboViewer(parent, widgetFactory); - } - if (key == EEFGenViewsRepository.GenEditionContext.Parameters.class) { - return createParametersGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Parameters.basePackage) { - return createBasePackageText(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID) { - return createDescriptorsContributorIDText(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Activation.class) { - return createActivationGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors) { - return createGenericPropertiesViewsDescriptorsCheckbox(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews) { - return createGMFSpecificPropertiesViewsCheckbox(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases) { - return createJUnitTestCasesCheckbox(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Implementation.class) { - return createImplementationGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass) { - return createLeafComponentsSuperClassText(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass) { - return createPropertiesEditingProvidersSuperClassText(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createReferenceGroup(FormToolkit widgetFactory, final Composite parent) { - Section referenceSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - referenceSection.setText(EEFGenMessages.GenEditionContextPropertiesEditionPart_ReferenceGroupLabel); - GridData referenceSectionData = new GridData(GridData.FILL_HORIZONTAL); - referenceSectionData.horizontalSpan = 3; - referenceSection.setLayoutData(referenceSectionData); - Composite referenceGroup = widgetFactory.createComposite(referenceSection); - GridLayout referenceGroupLayout = new GridLayout(); - referenceGroupLayout.numColumns = 3; - referenceGroup.setLayout(referenceGroupLayout); - referenceSection.setClient(referenceGroup); - return referenceGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createPropertiesEditionContextFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext, EEFGenMessages.GenEditionContextPropertiesEditionPart_PropertiesEditionContextLabel); - propertiesEditionContext = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext, EEFGenViewsRepository.FORM_KIND)); - widgetFactory.adapt(propertiesEditionContext); - propertiesEditionContext.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData propertiesEditionContextData = new GridData(GridData.FILL_HORIZONTAL); - propertiesEditionContext.setLayoutData(propertiesEditionContextData); - propertiesEditionContext.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartForm.this, EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getPropertiesEditionContext())); - } - - }); - propertiesEditionContext.setID(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createPropertiesEditionContextFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createParametersGroup(FormToolkit widgetFactory, final Composite parent) { - Section parametersSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - parametersSection.setText(EEFGenMessages.GenEditionContextPropertiesEditionPart_ParametersGroupLabel); - GridData parametersSectionData = new GridData(GridData.FILL_HORIZONTAL); - parametersSectionData.horizontalSpan = 3; - parametersSection.setLayoutData(parametersSectionData); - Composite parametersGroup = widgetFactory.createComposite(parametersSection); - GridLayout parametersGroupLayout = new GridLayout(); - parametersGroupLayout.numColumns = 3; - parametersGroup.setLayout(parametersGroupLayout); - parametersSection.setClient(parametersGroup); - return parametersGroup; - } - - - protected Composite createBasePackageText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenEditionContext.Parameters.basePackage, EEFGenMessages.GenEditionContextPropertiesEditionPart_BasePackageLabel); - basePackage = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - basePackage.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData basePackageData = new GridData(GridData.FILL_HORIZONTAL); - basePackage.setLayoutData(basePackageData); - basePackage.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenEditionContext.Parameters.basePackage, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, basePackage.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenEditionContext.Parameters.basePackage, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, basePackage.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - basePackage.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartForm.this, EEFGenViewsRepository.GenEditionContext.Parameters.basePackage, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, basePackage.getText())); - } - } - }); - EditingUtils.setID(basePackage, EEFGenViewsRepository.GenEditionContext.Parameters.basePackage); - EditingUtils.setEEFtype(basePackage, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Parameters.basePackage, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createBasePackageText - - // End of user code - return parent; - } - - - protected Composite createDescriptorsContributorIDText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID, EEFGenMessages.GenEditionContextPropertiesEditionPart_DescriptorsContributorIDLabel); - descriptorsContributorID = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - descriptorsContributorID.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData descriptorsContributorIDData = new GridData(GridData.FILL_HORIZONTAL); - descriptorsContributorID.setLayoutData(descriptorsContributorIDData); - descriptorsContributorID.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, descriptorsContributorID.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, descriptorsContributorID.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - descriptorsContributorID.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartForm.this, EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, descriptorsContributorID.getText())); - } - } - }); - EditingUtils.setID(descriptorsContributorID, EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID); - EditingUtils.setEEFtype(descriptorsContributorID, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createDescriptorsContributorIDText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createActivationGroup(FormToolkit widgetFactory, final Composite parent) { - Section activationSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - activationSection.setText(EEFGenMessages.GenEditionContextPropertiesEditionPart_ActivationGroupLabel); - GridData activationSectionData = new GridData(GridData.FILL_HORIZONTAL); - activationSectionData.horizontalSpan = 3; - activationSection.setLayoutData(activationSectionData); - Composite activationGroup = widgetFactory.createComposite(activationSection); - GridLayout activationGroupLayout = new GridLayout(); - activationGroupLayout.numColumns = 3; - activationGroup.setLayout(activationGroupLayout); - activationSection.setClient(activationGroup); - return activationGroup; - } - - - protected Composite createGenericPropertiesViewsDescriptorsCheckbox(FormToolkit widgetFactory, Composite parent) { - genericPropertiesViewsDescriptors = widgetFactory.createButton(parent, getDescription(EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors, EEFGenMessages.GenEditionContextPropertiesEditionPart_GenericPropertiesViewsDescriptorsLabel), SWT.CHECK); - genericPropertiesViewsDescriptors.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartForm.this, EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(genericPropertiesViewsDescriptors.getSelection()))); - } - - }); - GridData genericPropertiesViewsDescriptorsData = new GridData(GridData.FILL_HORIZONTAL); - genericPropertiesViewsDescriptorsData.horizontalSpan = 2; - genericPropertiesViewsDescriptors.setLayoutData(genericPropertiesViewsDescriptorsData); - EditingUtils.setID(genericPropertiesViewsDescriptors, EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors); - EditingUtils.setEEFtype(genericPropertiesViewsDescriptors, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createGenericPropertiesViewsDescriptorsCheckbox - - // End of user code - return parent; - } - - - protected Composite createGMFSpecificPropertiesViewsCheckbox(FormToolkit widgetFactory, Composite parent) { - gMFSpecificPropertiesViews = widgetFactory.createButton(parent, getDescription(EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews, EEFGenMessages.GenEditionContextPropertiesEditionPart_GMFSpecificPropertiesViewsLabel), SWT.CHECK); - gMFSpecificPropertiesViews.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartForm.this, EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(gMFSpecificPropertiesViews.getSelection()))); - } - - }); - GridData gMFSpecificPropertiesViewsData = new GridData(GridData.FILL_HORIZONTAL); - gMFSpecificPropertiesViewsData.horizontalSpan = 2; - gMFSpecificPropertiesViews.setLayoutData(gMFSpecificPropertiesViewsData); - EditingUtils.setID(gMFSpecificPropertiesViews, EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews); - EditingUtils.setEEFtype(gMFSpecificPropertiesViews, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createGMFSpecificPropertiesViewsCheckbox - - // End of user code - return parent; - } - - - protected Composite createJUnitTestCasesCheckbox(FormToolkit widgetFactory, Composite parent) { - jUnitTestCases = widgetFactory.createButton(parent, getDescription(EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases, EEFGenMessages.GenEditionContextPropertiesEditionPart_JUnitTestCasesLabel), SWT.CHECK); - jUnitTestCases.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartForm.this, EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(jUnitTestCases.getSelection()))); - } - - }); - GridData jUnitTestCasesData = new GridData(GridData.FILL_HORIZONTAL); - jUnitTestCasesData.horizontalSpan = 2; - jUnitTestCases.setLayoutData(jUnitTestCasesData); - EditingUtils.setID(jUnitTestCases, EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases); - EditingUtils.setEEFtype(jUnitTestCases, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createJUnitTestCasesCheckbox - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createImplementationGroup(FormToolkit widgetFactory, final Composite parent) { - Section implementationSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - implementationSection.setText(EEFGenMessages.GenEditionContextPropertiesEditionPart_ImplementationGroupLabel); - GridData implementationSectionData = new GridData(GridData.FILL_HORIZONTAL); - implementationSectionData.horizontalSpan = 3; - implementationSection.setLayoutData(implementationSectionData); - Composite implementationGroup = widgetFactory.createComposite(implementationSection); - GridLayout implementationGroupLayout = new GridLayout(); - implementationGroupLayout.numColumns = 3; - implementationGroup.setLayout(implementationGroupLayout); - implementationSection.setClient(implementationGroup); - return implementationGroup; - } - - - protected Composite createLeafComponentsSuperClassText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass, EEFGenMessages.GenEditionContextPropertiesEditionPart_LeafComponentsSuperClassLabel); - leafComponentsSuperClass = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - leafComponentsSuperClass.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData leafComponentsSuperClassData = new GridData(GridData.FILL_HORIZONTAL); - leafComponentsSuperClass.setLayoutData(leafComponentsSuperClassData); - leafComponentsSuperClass.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, leafComponentsSuperClass.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, leafComponentsSuperClass.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - leafComponentsSuperClass.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartForm.this, EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, leafComponentsSuperClass.getText())); - } - } - }); - EditingUtils.setID(leafComponentsSuperClass, EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass); - EditingUtils.setEEFtype(leafComponentsSuperClass, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createLeafComponentsSuperClassText - - // End of user code - return parent; - } - - - protected Composite createPropertiesEditingProvidersSuperClassText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass, EEFGenMessages.GenEditionContextPropertiesEditionPart_PropertiesEditingProvidersSuperClassLabel); - propertiesEditingProvidersSuperClass = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - propertiesEditingProvidersSuperClass.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData propertiesEditingProvidersSuperClassData = new GridData(GridData.FILL_HORIZONTAL); - propertiesEditingProvidersSuperClass.setLayoutData(propertiesEditingProvidersSuperClassData); - propertiesEditingProvidersSuperClass.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, propertiesEditingProvidersSuperClass.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, propertiesEditingProvidersSuperClass.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenEditionContextPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - propertiesEditingProvidersSuperClass.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartForm.this, EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, propertiesEditingProvidersSuperClass.getText())); - } - } - }); - EditingUtils.setID(propertiesEditingProvidersSuperClass, EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass); - EditingUtils.setEEFtype(propertiesEditingProvidersSuperClass, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createPropertiesEditingProvidersSuperClassText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getPropertiesEditionContext() - * - */ - public EObject getPropertiesEditionContext() { - if (propertiesEditionContext.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) propertiesEditionContext.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#initPropertiesEditionContext(EObjectFlatComboSettings) - */ - public void initPropertiesEditionContext(EObjectFlatComboSettings settings) { - propertiesEditionContext.setInput(settings); - if (current != null) { - propertiesEditionContext.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext); - if (eefElementEditorReadOnlyState && propertiesEditionContext.isEnabled()) { - propertiesEditionContext.setEnabled(false); - propertiesEditionContext.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !propertiesEditionContext.isEnabled()) { - propertiesEditionContext.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setPropertiesEditionContext(EObject newValue) - * - */ - public void setPropertiesEditionContext(EObject newValue) { - if (newValue != null) { - propertiesEditionContext.setSelection(new StructuredSelection(newValue)); - } else { - propertiesEditionContext.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext); - if (eefElementEditorReadOnlyState && propertiesEditionContext.isEnabled()) { - propertiesEditionContext.setEnabled(false); - propertiesEditionContext.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !propertiesEditionContext.isEnabled()) { - propertiesEditionContext.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setPropertiesEditionContextButtonMode(ButtonsModeEnum newValue) - */ - public void setPropertiesEditionContextButtonMode(ButtonsModeEnum newValue) { - propertiesEditionContext.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#addFilterPropertiesEditionContext(ViewerFilter filter) - * - */ - public void addFilterToPropertiesEditionContext(ViewerFilter filter) { - propertiesEditionContext.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#addBusinessFilterPropertiesEditionContext(ViewerFilter filter) - * - */ - public void addBusinessFilterToPropertiesEditionContext(ViewerFilter filter) { - propertiesEditionContext.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getBasePackage() - * - */ - public String getBasePackage() { - return basePackage.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setBasePackage(String newValue) - * - */ - public void setBasePackage(String newValue) { - if (newValue != null) { - basePackage.setText(newValue); - } else { - basePackage.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Parameters.basePackage); - if (eefElementEditorReadOnlyState && basePackage.isEnabled()) { - basePackage.setEnabled(false); - basePackage.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !basePackage.isEnabled()) { - basePackage.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getDescriptorsContributorID() - * - */ - public String getDescriptorsContributorID() { - return descriptorsContributorID.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setDescriptorsContributorID(String newValue) - * - */ - public void setDescriptorsContributorID(String newValue) { - if (newValue != null) { - descriptorsContributorID.setText(newValue); - } else { - descriptorsContributorID.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID); - if (eefElementEditorReadOnlyState && descriptorsContributorID.isEnabled()) { - descriptorsContributorID.setEnabled(false); - descriptorsContributorID.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !descriptorsContributorID.isEnabled()) { - descriptorsContributorID.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getGenericPropertiesViewsDescriptors() - * - */ - public Boolean getGenericPropertiesViewsDescriptors() { - return Boolean.valueOf(genericPropertiesViewsDescriptors.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setGenericPropertiesViewsDescriptors(Boolean newValue) - * - */ - public void setGenericPropertiesViewsDescriptors(Boolean newValue) { - if (newValue != null) { - genericPropertiesViewsDescriptors.setSelection(newValue.booleanValue()); - } else { - genericPropertiesViewsDescriptors.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors); - if (eefElementEditorReadOnlyState && genericPropertiesViewsDescriptors.isEnabled()) { - genericPropertiesViewsDescriptors.setEnabled(false); - genericPropertiesViewsDescriptors.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !genericPropertiesViewsDescriptors.isEnabled()) { - genericPropertiesViewsDescriptors.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getGMFSpecificPropertiesViews() - * - */ - public Boolean getGMFSpecificPropertiesViews() { - return Boolean.valueOf(gMFSpecificPropertiesViews.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setGMFSpecificPropertiesViews(Boolean newValue) - * - */ - public void setGMFSpecificPropertiesViews(Boolean newValue) { - if (newValue != null) { - gMFSpecificPropertiesViews.setSelection(newValue.booleanValue()); - } else { - gMFSpecificPropertiesViews.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews); - if (eefElementEditorReadOnlyState && gMFSpecificPropertiesViews.isEnabled()) { - gMFSpecificPropertiesViews.setEnabled(false); - gMFSpecificPropertiesViews.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !gMFSpecificPropertiesViews.isEnabled()) { - gMFSpecificPropertiesViews.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getJUnitTestCases() - * - */ - public Boolean getJUnitTestCases() { - return Boolean.valueOf(jUnitTestCases.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setJUnitTestCases(Boolean newValue) - * - */ - public void setJUnitTestCases(Boolean newValue) { - if (newValue != null) { - jUnitTestCases.setSelection(newValue.booleanValue()); - } else { - jUnitTestCases.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases); - if (eefElementEditorReadOnlyState && jUnitTestCases.isEnabled()) { - jUnitTestCases.setEnabled(false); - jUnitTestCases.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !jUnitTestCases.isEnabled()) { - jUnitTestCases.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getLeafComponentsSuperClass() - * - */ - public String getLeafComponentsSuperClass() { - return leafComponentsSuperClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setLeafComponentsSuperClass(String newValue) - * - */ - public void setLeafComponentsSuperClass(String newValue) { - if (newValue != null) { - leafComponentsSuperClass.setText(newValue); - } else { - leafComponentsSuperClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass); - if (eefElementEditorReadOnlyState && leafComponentsSuperClass.isEnabled()) { - leafComponentsSuperClass.setEnabled(false); - leafComponentsSuperClass.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !leafComponentsSuperClass.isEnabled()) { - leafComponentsSuperClass.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getPropertiesEditingProvidersSuperClass() - * - */ - public String getPropertiesEditingProvidersSuperClass() { - return propertiesEditingProvidersSuperClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setPropertiesEditingProvidersSuperClass(String newValue) - * - */ - public void setPropertiesEditingProvidersSuperClass(String newValue) { - if (newValue != null) { - propertiesEditingProvidersSuperClass.setText(newValue); - } else { - propertiesEditingProvidersSuperClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass); - if (eefElementEditorReadOnlyState && propertiesEditingProvidersSuperClass.isEnabled()) { - propertiesEditingProvidersSuperClass.setEnabled(false); - propertiesEditingProvidersSuperClass.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !propertiesEditingProvidersSuperClass.isEnabled()) { - propertiesEditingProvidersSuperClass.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EEFGenMessages.GenEditionContext_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/GenViewsRepositoryPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/GenViewsRepositoryPropertiesEditionPartForm.java deleted file mode 100644 index 49e11cf7c..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/forms/GenViewsRepositoryPropertiesEditionPartForm.java +++ /dev/null @@ -1,897 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.common.util.Enumerator; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart; -import org.eclipse.emf.eef.EEFGen.providers.EEFGenMessages; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ArrayContentProvider; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class GenViewsRepositoryPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, GenViewsRepositoryPropertiesEditionPart { - - protected EObjectFlatComboViewer viewsRepository; - protected Text basePackage; - protected EMFComboViewer helpStrategy; - protected Button sWTViews; - protected Button formsViews; - protected Text partsSuperClass; - protected Text formsSuperClass; - - - - /** - * For {@link ISection} use only. - */ - public GenViewsRepositoryPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public GenViewsRepositoryPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence genViewsRepositoryStep = new BindingCompositionSequence(propertiesEditionComponent); - genViewsRepositoryStep - .addStep(EEFGenViewsRepository.GenViewsRepository.Reference.class) - .addStep(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository); - - CompositionStep parametersStep = genViewsRepositoryStep.addStep(EEFGenViewsRepository.GenViewsRepository.Parameters.class); - parametersStep.addStep(EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage); - parametersStep.addStep(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy); - - CompositionStep activationStep = genViewsRepositoryStep.addStep(EEFGenViewsRepository.GenViewsRepository.Activation.class); - activationStep.addStep(EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews); - activationStep.addStep(EEFGenViewsRepository.GenViewsRepository.Activation.formsViews); - - CompositionStep implementationStep = genViewsRepositoryStep.addStep(EEFGenViewsRepository.GenViewsRepository.Implementation.class); - implementationStep.addStep(EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass); - implementationStep.addStep(EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass); - - - composer = new PartComposer(genViewsRepositoryStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EEFGenViewsRepository.GenViewsRepository.Reference.class) { - return createReferenceGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository) { - return createViewsRepositoryFlatComboViewer(parent, widgetFactory); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Parameters.class) { - return createParametersGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage) { - return createBasePackageText(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy) { - return createHelpStrategyEMFComboViewer(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Activation.class) { - return createActivationGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews) { - return createSWTViewsCheckbox(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Activation.formsViews) { - return createFormsViewsCheckbox(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Implementation.class) { - return createImplementationGroup(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass) { - return createPartsSuperClassText(widgetFactory, parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass) { - return createFormsSuperClassText(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createReferenceGroup(FormToolkit widgetFactory, final Composite parent) { - Section referenceSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - referenceSection.setText(EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_ReferenceGroupLabel); - GridData referenceSectionData = new GridData(GridData.FILL_HORIZONTAL); - referenceSectionData.horizontalSpan = 3; - referenceSection.setLayoutData(referenceSectionData); - Composite referenceGroup = widgetFactory.createComposite(referenceSection); - GridLayout referenceGroupLayout = new GridLayout(); - referenceGroupLayout.numColumns = 3; - referenceGroup.setLayout(referenceGroupLayout); - referenceSection.setClient(referenceGroup); - return referenceGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createViewsRepositoryFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_ViewsRepositoryLabel); - viewsRepository = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository, EEFGenViewsRepository.FORM_KIND)); - widgetFactory.adapt(viewsRepository); - viewsRepository.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData viewsRepositoryData = new GridData(GridData.FILL_HORIZONTAL); - viewsRepository.setLayoutData(viewsRepositoryData); - viewsRepository.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartForm.this, EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getViewsRepository())); - } - - }); - viewsRepository.setID(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createViewsRepositoryFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createParametersGroup(FormToolkit widgetFactory, final Composite parent) { - Section parametersSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - parametersSection.setText(EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_ParametersGroupLabel); - GridData parametersSectionData = new GridData(GridData.FILL_HORIZONTAL); - parametersSectionData.horizontalSpan = 3; - parametersSection.setLayoutData(parametersSectionData); - Composite parametersGroup = widgetFactory.createComposite(parametersSection); - GridLayout parametersGroupLayout = new GridLayout(); - parametersGroupLayout.numColumns = 3; - parametersGroup.setLayout(parametersGroupLayout); - parametersSection.setClient(parametersGroup); - return parametersGroup; - } - - - protected Composite createBasePackageText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_BasePackageLabel); - basePackage = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - basePackage.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData basePackageData = new GridData(GridData.FILL_HORIZONTAL); - basePackage.setLayoutData(basePackageData); - basePackage.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - GenViewsRepositoryPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, basePackage.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenViewsRepositoryPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, basePackage.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenViewsRepositoryPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - basePackage.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartForm.this, EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, basePackage.getText())); - } - } - }); - EditingUtils.setID(basePackage, EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage); - EditingUtils.setEEFtype(basePackage, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createBasePackageText - - // End of user code - return parent; - } - - - protected Composite createHelpStrategyEMFComboViewer(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_HelpStrategyLabel); - helpStrategy = new EMFComboViewer(parent); - helpStrategy.setContentProvider(new ArrayContentProvider()); - helpStrategy.setLabelProvider(new AdapterFactoryLabelProvider(EEFRuntimePlugin.getDefault().getAdapterFactory())); - GridData helpStrategyData = new GridData(GridData.FILL_HORIZONTAL); - helpStrategy.getCombo().setLayoutData(helpStrategyData); - helpStrategy.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - * - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartForm.this, EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getHelpStrategy())); - } - - }); - helpStrategy.setID(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createHelpStrategyEMFComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createActivationGroup(FormToolkit widgetFactory, final Composite parent) { - Section activationSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - activationSection.setText(EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_ActivationGroupLabel); - GridData activationSectionData = new GridData(GridData.FILL_HORIZONTAL); - activationSectionData.horizontalSpan = 3; - activationSection.setLayoutData(activationSectionData); - Composite activationGroup = widgetFactory.createComposite(activationSection); - GridLayout activationGroupLayout = new GridLayout(); - activationGroupLayout.numColumns = 3; - activationGroup.setLayout(activationGroupLayout); - activationSection.setClient(activationGroup); - return activationGroup; - } - - - protected Composite createSWTViewsCheckbox(FormToolkit widgetFactory, Composite parent) { - sWTViews = widgetFactory.createButton(parent, getDescription(EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_SWTViewsLabel), SWT.CHECK); - sWTViews.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartForm.this, EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(sWTViews.getSelection()))); - } - - }); - GridData sWTViewsData = new GridData(GridData.FILL_HORIZONTAL); - sWTViewsData.horizontalSpan = 2; - sWTViews.setLayoutData(sWTViewsData); - EditingUtils.setID(sWTViews, EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews); - EditingUtils.setEEFtype(sWTViews, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createSWTViewsCheckbox - - // End of user code - return parent; - } - - - protected Composite createFormsViewsCheckbox(FormToolkit widgetFactory, Composite parent) { - formsViews = widgetFactory.createButton(parent, getDescription(EEFGenViewsRepository.GenViewsRepository.Activation.formsViews, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_FormsViewsLabel), SWT.CHECK); - formsViews.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartForm.this, EEFGenViewsRepository.GenViewsRepository.Activation.formsViews, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(formsViews.getSelection()))); - } - - }); - GridData formsViewsData = new GridData(GridData.FILL_HORIZONTAL); - formsViewsData.horizontalSpan = 2; - formsViews.setLayoutData(formsViewsData); - EditingUtils.setID(formsViews, EEFGenViewsRepository.GenViewsRepository.Activation.formsViews); - EditingUtils.setEEFtype(formsViews, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Activation.formsViews, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createFormsViewsCheckbox - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createImplementationGroup(FormToolkit widgetFactory, final Composite parent) { - Section implementationSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - implementationSection.setText(EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_ImplementationGroupLabel); - GridData implementationSectionData = new GridData(GridData.FILL_HORIZONTAL); - implementationSectionData.horizontalSpan = 3; - implementationSection.setLayoutData(implementationSectionData); - Composite implementationGroup = widgetFactory.createComposite(implementationSection); - GridLayout implementationGroupLayout = new GridLayout(); - implementationGroupLayout.numColumns = 3; - implementationGroup.setLayout(implementationGroupLayout); - implementationSection.setClient(implementationGroup); - return implementationGroup; - } - - - protected Composite createPartsSuperClassText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_PartsSuperClassLabel); - partsSuperClass = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - partsSuperClass.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData partsSuperClassData = new GridData(GridData.FILL_HORIZONTAL); - partsSuperClass.setLayoutData(partsSuperClassData); - partsSuperClass.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - GenViewsRepositoryPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, partsSuperClass.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenViewsRepositoryPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, partsSuperClass.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenViewsRepositoryPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - partsSuperClass.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartForm.this, EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, partsSuperClass.getText())); - } - } - }); - EditingUtils.setID(partsSuperClass, EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass); - EditingUtils.setEEFtype(partsSuperClass, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createPartsSuperClassText - - // End of user code - return parent; - } - - - protected Composite createFormsSuperClassText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_FormsSuperClassLabel); - formsSuperClass = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - formsSuperClass.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData formsSuperClassData = new GridData(GridData.FILL_HORIZONTAL); - formsSuperClass.setLayoutData(formsSuperClassData); - formsSuperClass.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - GenViewsRepositoryPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, formsSuperClass.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenViewsRepositoryPropertiesEditionPartForm.this, - EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, formsSuperClass.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - GenViewsRepositoryPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - formsSuperClass.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartForm.this, EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, formsSuperClass.getText())); - } - } - }); - EditingUtils.setID(formsSuperClass, EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass); - EditingUtils.setEEFtype(formsSuperClass, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass, EEFGenViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createFormsSuperClassText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getViewsRepository() - * - */ - public EObject getViewsRepository() { - if (viewsRepository.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) viewsRepository.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#initViewsRepository(EObjectFlatComboSettings) - */ - public void initViewsRepository(EObjectFlatComboSettings settings) { - viewsRepository.setInput(settings); - if (current != null) { - viewsRepository.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository); - if (eefElementEditorReadOnlyState && viewsRepository.isEnabled()) { - viewsRepository.setEnabled(false); - viewsRepository.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !viewsRepository.isEnabled()) { - viewsRepository.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setViewsRepository(EObject newValue) - * - */ - public void setViewsRepository(EObject newValue) { - if (newValue != null) { - viewsRepository.setSelection(new StructuredSelection(newValue)); - } else { - viewsRepository.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository); - if (eefElementEditorReadOnlyState && viewsRepository.isEnabled()) { - viewsRepository.setEnabled(false); - viewsRepository.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !viewsRepository.isEnabled()) { - viewsRepository.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setViewsRepositoryButtonMode(ButtonsModeEnum newValue) - */ - public void setViewsRepositoryButtonMode(ButtonsModeEnum newValue) { - viewsRepository.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#addFilterViewsRepository(ViewerFilter filter) - * - */ - public void addFilterToViewsRepository(ViewerFilter filter) { - viewsRepository.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#addBusinessFilterViewsRepository(ViewerFilter filter) - * - */ - public void addBusinessFilterToViewsRepository(ViewerFilter filter) { - viewsRepository.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getBasePackage() - * - */ - public String getBasePackage() { - return basePackage.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setBasePackage(String newValue) - * - */ - public void setBasePackage(String newValue) { - if (newValue != null) { - basePackage.setText(newValue); - } else { - basePackage.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage); - if (eefElementEditorReadOnlyState && basePackage.isEnabled()) { - basePackage.setEnabled(false); - basePackage.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !basePackage.isEnabled()) { - basePackage.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getHelpStrategy() - * - */ - public Enumerator getHelpStrategy() { - Enumerator selection = (Enumerator) ((StructuredSelection) helpStrategy.getSelection()).getFirstElement(); - return selection; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#initHelpStrategy(Object input, Enumerator current) - */ - public void initHelpStrategy(Object input, Enumerator current) { - helpStrategy.setInput(input); - helpStrategy.modelUpdating(new StructuredSelection(current)); - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy); - if (eefElementEditorReadOnlyState && helpStrategy.isEnabled()) { - helpStrategy.setEnabled(false); - helpStrategy.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !helpStrategy.isEnabled()) { - helpStrategy.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setHelpStrategy(Enumerator newValue) - * - */ - public void setHelpStrategy(Enumerator newValue) { - helpStrategy.modelUpdating(new StructuredSelection(newValue)); - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy); - if (eefElementEditorReadOnlyState && helpStrategy.isEnabled()) { - helpStrategy.setEnabled(false); - helpStrategy.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !helpStrategy.isEnabled()) { - helpStrategy.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getSWTViews() - * - */ - public Boolean getSWTViews() { - return Boolean.valueOf(sWTViews.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setSWTViews(Boolean newValue) - * - */ - public void setSWTViews(Boolean newValue) { - if (newValue != null) { - sWTViews.setSelection(newValue.booleanValue()); - } else { - sWTViews.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews); - if (eefElementEditorReadOnlyState && sWTViews.isEnabled()) { - sWTViews.setEnabled(false); - sWTViews.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !sWTViews.isEnabled()) { - sWTViews.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getFormsViews() - * - */ - public Boolean getFormsViews() { - return Boolean.valueOf(formsViews.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setFormsViews(Boolean newValue) - * - */ - public void setFormsViews(Boolean newValue) { - if (newValue != null) { - formsViews.setSelection(newValue.booleanValue()); - } else { - formsViews.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Activation.formsViews); - if (eefElementEditorReadOnlyState && formsViews.isEnabled()) { - formsViews.setEnabled(false); - formsViews.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !formsViews.isEnabled()) { - formsViews.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getPartsSuperClass() - * - */ - public String getPartsSuperClass() { - return partsSuperClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setPartsSuperClass(String newValue) - * - */ - public void setPartsSuperClass(String newValue) { - if (newValue != null) { - partsSuperClass.setText(newValue); - } else { - partsSuperClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass); - if (eefElementEditorReadOnlyState && partsSuperClass.isEnabled()) { - partsSuperClass.setEnabled(false); - partsSuperClass.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !partsSuperClass.isEnabled()) { - partsSuperClass.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getFormsSuperClass() - * - */ - public String getFormsSuperClass() { - return formsSuperClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setFormsSuperClass(String newValue) - * - */ - public void setFormsSuperClass(String newValue) { - if (newValue != null) { - formsSuperClass.setText(newValue); - } else { - formsSuperClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass); - if (eefElementEditorReadOnlyState && formsSuperClass.isEnabled()) { - formsSuperClass.setEnabled(false); - formsSuperClass.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !formsSuperClass.isEnabled()) { - formsSuperClass.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EEFGenMessages.GenViewsRepository_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/EEFGenModelPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/EEFGenModelPropertiesEditionPartImpl.java deleted file mode 100644 index e2078e854..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/EEFGenModelPropertiesEditionPartImpl.java +++ /dev/null @@ -1,571 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.EEFGen.providers.EEFGenMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenModelPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, EEFGenModelPropertiesEditionPart { - - protected Text generationDirectory; - protected Text testsGenerationDirectory; - protected Button useJMergeToManageUserCode; - protected Text author; - protected Text license; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EEFGenModelPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence eEFGenModelStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep parametersStep = eEFGenModelStep.addStep(EEFGenViewsRepository.EEFGenModel.Parameters.class); - parametersStep.addStep(EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory); - parametersStep.addStep(EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory); - parametersStep.addStep(EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode); - - CompositionStep legalStep = eEFGenModelStep.addStep(EEFGenViewsRepository.EEFGenModel.Legal.class); - legalStep.addStep(EEFGenViewsRepository.EEFGenModel.Legal.author); - legalStep.addStep(EEFGenViewsRepository.EEFGenModel.Legal.license); - - - composer = new PartComposer(eEFGenModelStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EEFGenViewsRepository.EEFGenModel.Parameters.class) { - return createParametersGroup(parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory) { - return createGenerationDirectoryText(parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory) { - return createTestsGenerationDirectoryText(parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode) { - return createUseJMergeToManageUserCodeCheckbox(parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Legal.class) { - return createLegalGroup(parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Legal.author) { - return createAuthorText(parent); - } - if (key == EEFGenViewsRepository.EEFGenModel.Legal.license) { - return createLicenseTextarea(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createParametersGroup(Composite parent) { - Group parametersGroup = new Group(parent, SWT.NONE); - parametersGroup.setText(EEFGenMessages.EEFGenModelPropertiesEditionPart_ParametersGroupLabel); - GridData parametersGroupData = new GridData(GridData.FILL_HORIZONTAL); - parametersGroupData.horizontalSpan = 3; - parametersGroup.setLayoutData(parametersGroupData); - GridLayout parametersGroupLayout = new GridLayout(); - parametersGroupLayout.numColumns = 3; - parametersGroup.setLayout(parametersGroupLayout); - return parametersGroup; - } - - - protected Composite createGenerationDirectoryText(Composite parent) { - createDescription(parent, EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory, EEFGenMessages.EEFGenModelPropertiesEditionPart_GenerationDirectoryLabel); - generationDirectory = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData generationDirectoryData = new GridData(GridData.FILL_HORIZONTAL); - generationDirectory.setLayoutData(generationDirectoryData); - generationDirectory.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartImpl.this, EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, generationDirectory.getText())); - } - - }); - generationDirectory.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartImpl.this, EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, generationDirectory.getText())); - } - } - - }); - EditingUtils.setID(generationDirectory, EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory); - EditingUtils.setEEFtype(generationDirectory, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createGenerationDirectoryText - - // End of user code - return parent; - } - - - protected Composite createTestsGenerationDirectoryText(Composite parent) { - createDescription(parent, EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory, EEFGenMessages.EEFGenModelPropertiesEditionPart_TestsGenerationDirectoryLabel); - testsGenerationDirectory = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData testsGenerationDirectoryData = new GridData(GridData.FILL_HORIZONTAL); - testsGenerationDirectory.setLayoutData(testsGenerationDirectoryData); - testsGenerationDirectory.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartImpl.this, EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, testsGenerationDirectory.getText())); - } - - }); - testsGenerationDirectory.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartImpl.this, EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, testsGenerationDirectory.getText())); - } - } - - }); - EditingUtils.setID(testsGenerationDirectory, EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory); - EditingUtils.setEEFtype(testsGenerationDirectory, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createTestsGenerationDirectoryText - - // End of user code - return parent; - } - - - protected Composite createUseJMergeToManageUserCodeCheckbox(Composite parent) { - useJMergeToManageUserCode = new Button(parent, SWT.CHECK); - useJMergeToManageUserCode.setText(getDescription(EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode, EEFGenMessages.EEFGenModelPropertiesEditionPart_UseJMergeToManageUserCodeLabel)); - useJMergeToManageUserCode.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartImpl.this, EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(useJMergeToManageUserCode.getSelection()))); - } - - }); - GridData useJMergeToManageUserCodeData = new GridData(GridData.FILL_HORIZONTAL); - useJMergeToManageUserCodeData.horizontalSpan = 2; - useJMergeToManageUserCode.setLayoutData(useJMergeToManageUserCodeData); - EditingUtils.setID(useJMergeToManageUserCode, EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode); - EditingUtils.setEEFtype(useJMergeToManageUserCode, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createUseJMergeToManageUserCodeCheckbox - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createLegalGroup(Composite parent) { - Group legalGroup = new Group(parent, SWT.NONE); - legalGroup.setText(EEFGenMessages.EEFGenModelPropertiesEditionPart_LegalGroupLabel); - GridData legalGroupData = new GridData(GridData.FILL_HORIZONTAL); - legalGroupData.horizontalSpan = 3; - legalGroup.setLayoutData(legalGroupData); - GridLayout legalGroupLayout = new GridLayout(); - legalGroupLayout.numColumns = 3; - legalGroup.setLayout(legalGroupLayout); - return legalGroup; - } - - - protected Composite createAuthorText(Composite parent) { - createDescription(parent, EEFGenViewsRepository.EEFGenModel.Legal.author, EEFGenMessages.EEFGenModelPropertiesEditionPart_AuthorLabel); - author = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData authorData = new GridData(GridData.FILL_HORIZONTAL); - author.setLayoutData(authorData); - author.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartImpl.this, EEFGenViewsRepository.EEFGenModel.Legal.author, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, author.getText())); - } - - }); - author.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartImpl.this, EEFGenViewsRepository.EEFGenModel.Legal.author, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, author.getText())); - } - } - - }); - EditingUtils.setID(author, EEFGenViewsRepository.EEFGenModel.Legal.author); - EditingUtils.setEEFtype(author, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModel.Legal.author, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createAuthorText - - // End of user code - return parent; - } - - - protected Composite createLicenseTextarea(Composite parent) { - Label licenseLabel = createDescription(parent, EEFGenViewsRepository.EEFGenModel.Legal.license, EEFGenMessages.EEFGenModelPropertiesEditionPart_LicenseLabel); - GridData licenseLabelData = new GridData(GridData.FILL_HORIZONTAL); - licenseLabelData.horizontalSpan = 3; - licenseLabel.setLayoutData(licenseLabelData); - license = SWTUtils.createScrollableText(parent, SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); - GridData licenseData = new GridData(GridData.FILL_HORIZONTAL); - licenseData.horizontalSpan = 2; - licenseData.heightHint = 80; - licenseData.widthHint = 200; - license.setLayoutData(licenseData); - license.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelPropertiesEditionPartImpl.this, EEFGenViewsRepository.EEFGenModel.Legal.license, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, license.getText())); - } - - }); - EditingUtils.setID(license, EEFGenViewsRepository.EEFGenModel.Legal.license); - EditingUtils.setEEFtype(license, "eef::Textarea"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModel.Legal.license, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createLicenseTextArea - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#getGenerationDirectory() - * - */ - public String getGenerationDirectory() { - return generationDirectory.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#setGenerationDirectory(String newValue) - * - */ - public void setGenerationDirectory(String newValue) { - if (newValue != null) { - generationDirectory.setText(newValue); - } else { - generationDirectory.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModel.Parameters.generationDirectory); - if (eefElementEditorReadOnlyState && generationDirectory.isEnabled()) { - generationDirectory.setEnabled(false); - generationDirectory.setToolTipText(EEFGenMessages.EEFGenModel_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !generationDirectory.isEnabled()) { - generationDirectory.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#getTestsGenerationDirectory() - * - */ - public String getTestsGenerationDirectory() { - return testsGenerationDirectory.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#setTestsGenerationDirectory(String newValue) - * - */ - public void setTestsGenerationDirectory(String newValue) { - if (newValue != null) { - testsGenerationDirectory.setText(newValue); - } else { - testsGenerationDirectory.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModel.Parameters.testsGenerationDirectory); - if (eefElementEditorReadOnlyState && testsGenerationDirectory.isEnabled()) { - testsGenerationDirectory.setEnabled(false); - testsGenerationDirectory.setToolTipText(EEFGenMessages.EEFGenModel_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !testsGenerationDirectory.isEnabled()) { - testsGenerationDirectory.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#getUseJMergeToManageUserCode() - * - */ - public Boolean getUseJMergeToManageUserCode() { - return Boolean.valueOf(useJMergeToManageUserCode.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#setUseJMergeToManageUserCode(Boolean newValue) - * - */ - public void setUseJMergeToManageUserCode(Boolean newValue) { - if (newValue != null) { - useJMergeToManageUserCode.setSelection(newValue.booleanValue()); - } else { - useJMergeToManageUserCode.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModel.Parameters.useJMergeToManageUserCode); - if (eefElementEditorReadOnlyState && useJMergeToManageUserCode.isEnabled()) { - useJMergeToManageUserCode.setEnabled(false); - useJMergeToManageUserCode.setToolTipText(EEFGenMessages.EEFGenModel_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !useJMergeToManageUserCode.isEnabled()) { - useJMergeToManageUserCode.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#getAuthor() - * - */ - public String getAuthor() { - return author.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#setAuthor(String newValue) - * - */ - public void setAuthor(String newValue) { - if (newValue != null) { - author.setText(newValue); - } else { - author.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModel.Legal.author); - if (eefElementEditorReadOnlyState && author.isEnabled()) { - author.setEnabled(false); - author.setToolTipText(EEFGenMessages.EEFGenModel_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !author.isEnabled()) { - author.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#getLicense() - * - */ - public String getLicense() { - return license.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelPropertiesEditionPart#setLicense(String newValue) - * - */ - public void setLicense(String newValue) { - if (newValue != null) { - license.setText(newValue); - } else { - license.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModel.Legal.license); - if (eefElementEditorReadOnlyState && license.isEnabled()) { - license.setEnabled(false); - license.setBackground(license.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - license.setToolTipText(EEFGenMessages.EEFGenModel_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !license.isEnabled()) { - license.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EEFGenMessages.EEFGenModel_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/EEFGenModelReferencePropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/EEFGenModelReferencePropertiesEditionPartImpl.java deleted file mode 100644 index 3a05a2209..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/EEFGenModelReferencePropertiesEditionPartImpl.java +++ /dev/null @@ -1,269 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.EEFGen.providers.EEFGenMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenModelReferencePropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, EEFGenModelReferencePropertiesEditionPart { - - protected EObjectFlatComboViewer referencedEEFGenModel; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EEFGenModelReferencePropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence eEFGenModelReferenceStep = new BindingCompositionSequence(propertiesEditionComponent); - eEFGenModelReferenceStep - .addStep(EEFGenViewsRepository.EEFGenModelReference.Reference.class) - .addStep(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel); - - - composer = new PartComposer(eEFGenModelReferenceStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EEFGenViewsRepository.EEFGenModelReference.Reference.class) { - return createReferenceGroup(parent); - } - if (key == EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel) { - return createReferencedEEFGenModelFlatComboViewer(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createReferenceGroup(Composite parent) { - Group referenceGroup = new Group(parent, SWT.NONE); - referenceGroup.setText(EEFGenMessages.EEFGenModelReferencePropertiesEditionPart_ReferenceGroupLabel); - GridData referenceGroupData = new GridData(GridData.FILL_HORIZONTAL); - referenceGroupData.horizontalSpan = 3; - referenceGroup.setLayoutData(referenceGroupData); - GridLayout referenceGroupLayout = new GridLayout(); - referenceGroupLayout.numColumns = 3; - referenceGroup.setLayout(referenceGroupLayout); - return referenceGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createReferencedEEFGenModelFlatComboViewer(Composite parent) { - createDescription(parent, EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel, EEFGenMessages.EEFGenModelReferencePropertiesEditionPart_ReferencedEEFGenModelLabel); - referencedEEFGenModel = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel, EEFGenViewsRepository.SWT_KIND)); - referencedEEFGenModel.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - referencedEEFGenModel.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EEFGenModelReferencePropertiesEditionPartImpl.this, EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getReferencedEEFGenModel())); - } - - }); - GridData referencedEEFGenModelData = new GridData(GridData.FILL_HORIZONTAL); - referencedEEFGenModel.setLayoutData(referencedEEFGenModelData); - referencedEEFGenModel.setID(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createReferencedEEFGenModelFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#getReferencedEEFGenModel() - * - */ - public EObject getReferencedEEFGenModel() { - if (referencedEEFGenModel.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) referencedEEFGenModel.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#initReferencedEEFGenModel(EObjectFlatComboSettings) - */ - public void initReferencedEEFGenModel(EObjectFlatComboSettings settings) { - referencedEEFGenModel.setInput(settings); - if (current != null) { - referencedEEFGenModel.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel); - if (eefElementEditorReadOnlyState && referencedEEFGenModel.isEnabled()) { - referencedEEFGenModel.setEnabled(false); - referencedEEFGenModel.setToolTipText(EEFGenMessages.EEFGenModelReference_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !referencedEEFGenModel.isEnabled()) { - referencedEEFGenModel.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#setReferencedEEFGenModel(EObject newValue) - * - */ - public void setReferencedEEFGenModel(EObject newValue) { - if (newValue != null) { - referencedEEFGenModel.setSelection(new StructuredSelection(newValue)); - } else { - referencedEEFGenModel.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.EEFGenModelReference.Reference.referencedEEFGenModel); - if (eefElementEditorReadOnlyState && referencedEEFGenModel.isEnabled()) { - referencedEEFGenModel.setEnabled(false); - referencedEEFGenModel.setToolTipText(EEFGenMessages.EEFGenModelReference_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !referencedEEFGenModel.isEnabled()) { - referencedEEFGenModel.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#setReferencedEEFGenModelButtonMode(ButtonsModeEnum newValue) - */ - public void setReferencedEEFGenModelButtonMode(ButtonsModeEnum newValue) { - referencedEEFGenModel.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#addFilterReferencedEEFGenModel(ViewerFilter filter) - * - */ - public void addFilterToReferencedEEFGenModel(ViewerFilter filter) { - referencedEEFGenModel.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.EEFGenModelReferencePropertiesEditionPart#addBusinessFilterReferencedEEFGenModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToReferencedEEFGenModel(ViewerFilter filter) { - referencedEEFGenModel.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EEFGenMessages.EEFGenModelReference_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/GenEditionContextPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/GenEditionContextPropertiesEditionPartImpl.java deleted file mode 100644 index 6d88cc7c7..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/GenEditionContextPropertiesEditionPartImpl.java +++ /dev/null @@ -1,884 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart; -import org.eclipse.emf.eef.EEFGen.providers.EEFGenMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class GenEditionContextPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, GenEditionContextPropertiesEditionPart { - - protected EObjectFlatComboViewer propertiesEditionContext; - protected Text basePackage; - protected Text descriptorsContributorID; - protected Button genericPropertiesViewsDescriptors; - protected Button gMFSpecificPropertiesViews; - protected Button jUnitTestCases; - protected Text leafComponentsSuperClass; - protected Text propertiesEditingProvidersSuperClass; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public GenEditionContextPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence genEditionContextStep = new BindingCompositionSequence(propertiesEditionComponent); - genEditionContextStep - .addStep(EEFGenViewsRepository.GenEditionContext.Reference.class) - .addStep(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext); - - CompositionStep parametersStep = genEditionContextStep.addStep(EEFGenViewsRepository.GenEditionContext.Parameters.class); - parametersStep.addStep(EEFGenViewsRepository.GenEditionContext.Parameters.basePackage); - parametersStep.addStep(EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID); - - CompositionStep activationStep = genEditionContextStep.addStep(EEFGenViewsRepository.GenEditionContext.Activation.class); - activationStep.addStep(EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors); - activationStep.addStep(EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews); - activationStep.addStep(EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases); - - CompositionStep implementationStep = genEditionContextStep.addStep(EEFGenViewsRepository.GenEditionContext.Implementation.class); - implementationStep.addStep(EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass); - implementationStep.addStep(EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass); - - - composer = new PartComposer(genEditionContextStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EEFGenViewsRepository.GenEditionContext.Reference.class) { - return createReferenceGroup(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext) { - return createPropertiesEditionContextFlatComboViewer(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Parameters.class) { - return createParametersGroup(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Parameters.basePackage) { - return createBasePackageText(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID) { - return createDescriptorsContributorIDText(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Activation.class) { - return createActivationGroup(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors) { - return createGenericPropertiesViewsDescriptorsCheckbox(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews) { - return createGMFSpecificPropertiesViewsCheckbox(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases) { - return createJUnitTestCasesCheckbox(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Implementation.class) { - return createImplementationGroup(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass) { - return createLeafComponentsSuperClassText(parent); - } - if (key == EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass) { - return createPropertiesEditingProvidersSuperClassText(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createReferenceGroup(Composite parent) { - Group referenceGroup = new Group(parent, SWT.NONE); - referenceGroup.setText(EEFGenMessages.GenEditionContextPropertiesEditionPart_ReferenceGroupLabel); - GridData referenceGroupData = new GridData(GridData.FILL_HORIZONTAL); - referenceGroupData.horizontalSpan = 3; - referenceGroup.setLayoutData(referenceGroupData); - GridLayout referenceGroupLayout = new GridLayout(); - referenceGroupLayout.numColumns = 3; - referenceGroup.setLayout(referenceGroupLayout); - return referenceGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createPropertiesEditionContextFlatComboViewer(Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext, EEFGenMessages.GenEditionContextPropertiesEditionPart_PropertiesEditionContextLabel); - propertiesEditionContext = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext, EEFGenViewsRepository.SWT_KIND)); - propertiesEditionContext.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - propertiesEditionContext.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getPropertiesEditionContext())); - } - - }); - GridData propertiesEditionContextData = new GridData(GridData.FILL_HORIZONTAL); - propertiesEditionContext.setLayoutData(propertiesEditionContextData); - propertiesEditionContext.setID(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createPropertiesEditionContextFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createParametersGroup(Composite parent) { - Group parametersGroup = new Group(parent, SWT.NONE); - parametersGroup.setText(EEFGenMessages.GenEditionContextPropertiesEditionPart_ParametersGroupLabel); - GridData parametersGroupData = new GridData(GridData.FILL_HORIZONTAL); - parametersGroupData.horizontalSpan = 3; - parametersGroup.setLayoutData(parametersGroupData); - GridLayout parametersGroupLayout = new GridLayout(); - parametersGroupLayout.numColumns = 3; - parametersGroup.setLayout(parametersGroupLayout); - return parametersGroup; - } - - - protected Composite createBasePackageText(Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenEditionContext.Parameters.basePackage, EEFGenMessages.GenEditionContextPropertiesEditionPart_BasePackageLabel); - basePackage = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData basePackageData = new GridData(GridData.FILL_HORIZONTAL); - basePackage.setLayoutData(basePackageData); - basePackage.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Parameters.basePackage, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, basePackage.getText())); - } - - }); - basePackage.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Parameters.basePackage, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, basePackage.getText())); - } - } - - }); - EditingUtils.setID(basePackage, EEFGenViewsRepository.GenEditionContext.Parameters.basePackage); - EditingUtils.setEEFtype(basePackage, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Parameters.basePackage, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createBasePackageText - - // End of user code - return parent; - } - - - protected Composite createDescriptorsContributorIDText(Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID, EEFGenMessages.GenEditionContextPropertiesEditionPart_DescriptorsContributorIDLabel); - descriptorsContributorID = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData descriptorsContributorIDData = new GridData(GridData.FILL_HORIZONTAL); - descriptorsContributorID.setLayoutData(descriptorsContributorIDData); - descriptorsContributorID.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, descriptorsContributorID.getText())); - } - - }); - descriptorsContributorID.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, descriptorsContributorID.getText())); - } - } - - }); - EditingUtils.setID(descriptorsContributorID, EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID); - EditingUtils.setEEFtype(descriptorsContributorID, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createDescriptorsContributorIDText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createActivationGroup(Composite parent) { - Group activationGroup = new Group(parent, SWT.NONE); - activationGroup.setText(EEFGenMessages.GenEditionContextPropertiesEditionPart_ActivationGroupLabel); - GridData activationGroupData = new GridData(GridData.FILL_HORIZONTAL); - activationGroupData.horizontalSpan = 3; - activationGroup.setLayoutData(activationGroupData); - GridLayout activationGroupLayout = new GridLayout(); - activationGroupLayout.numColumns = 3; - activationGroup.setLayout(activationGroupLayout); - return activationGroup; - } - - - protected Composite createGenericPropertiesViewsDescriptorsCheckbox(Composite parent) { - genericPropertiesViewsDescriptors = new Button(parent, SWT.CHECK); - genericPropertiesViewsDescriptors.setText(getDescription(EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors, EEFGenMessages.GenEditionContextPropertiesEditionPart_GenericPropertiesViewsDescriptorsLabel)); - genericPropertiesViewsDescriptors.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(genericPropertiesViewsDescriptors.getSelection()))); - } - - }); - GridData genericPropertiesViewsDescriptorsData = new GridData(GridData.FILL_HORIZONTAL); - genericPropertiesViewsDescriptorsData.horizontalSpan = 2; - genericPropertiesViewsDescriptors.setLayoutData(genericPropertiesViewsDescriptorsData); - EditingUtils.setID(genericPropertiesViewsDescriptors, EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors); - EditingUtils.setEEFtype(genericPropertiesViewsDescriptors, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createGenericPropertiesViewsDescriptorsCheckbox - - // End of user code - return parent; - } - - - protected Composite createGMFSpecificPropertiesViewsCheckbox(Composite parent) { - gMFSpecificPropertiesViews = new Button(parent, SWT.CHECK); - gMFSpecificPropertiesViews.setText(getDescription(EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews, EEFGenMessages.GenEditionContextPropertiesEditionPart_GMFSpecificPropertiesViewsLabel)); - gMFSpecificPropertiesViews.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(gMFSpecificPropertiesViews.getSelection()))); - } - - }); - GridData gMFSpecificPropertiesViewsData = new GridData(GridData.FILL_HORIZONTAL); - gMFSpecificPropertiesViewsData.horizontalSpan = 2; - gMFSpecificPropertiesViews.setLayoutData(gMFSpecificPropertiesViewsData); - EditingUtils.setID(gMFSpecificPropertiesViews, EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews); - EditingUtils.setEEFtype(gMFSpecificPropertiesViews, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createGMFSpecificPropertiesViewsCheckbox - - // End of user code - return parent; - } - - - protected Composite createJUnitTestCasesCheckbox(Composite parent) { - jUnitTestCases = new Button(parent, SWT.CHECK); - jUnitTestCases.setText(getDescription(EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases, EEFGenMessages.GenEditionContextPropertiesEditionPart_JUnitTestCasesLabel)); - jUnitTestCases.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(jUnitTestCases.getSelection()))); - } - - }); - GridData jUnitTestCasesData = new GridData(GridData.FILL_HORIZONTAL); - jUnitTestCasesData.horizontalSpan = 2; - jUnitTestCases.setLayoutData(jUnitTestCasesData); - EditingUtils.setID(jUnitTestCases, EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases); - EditingUtils.setEEFtype(jUnitTestCases, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createJUnitTestCasesCheckbox - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createImplementationGroup(Composite parent) { - Group implementationGroup = new Group(parent, SWT.NONE); - implementationGroup.setText(EEFGenMessages.GenEditionContextPropertiesEditionPart_ImplementationGroupLabel); - GridData implementationGroupData = new GridData(GridData.FILL_HORIZONTAL); - implementationGroupData.horizontalSpan = 3; - implementationGroup.setLayoutData(implementationGroupData); - GridLayout implementationGroupLayout = new GridLayout(); - implementationGroupLayout.numColumns = 3; - implementationGroup.setLayout(implementationGroupLayout); - return implementationGroup; - } - - - protected Composite createLeafComponentsSuperClassText(Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass, EEFGenMessages.GenEditionContextPropertiesEditionPart_LeafComponentsSuperClassLabel); - leafComponentsSuperClass = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData leafComponentsSuperClassData = new GridData(GridData.FILL_HORIZONTAL); - leafComponentsSuperClass.setLayoutData(leafComponentsSuperClassData); - leafComponentsSuperClass.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, leafComponentsSuperClass.getText())); - } - - }); - leafComponentsSuperClass.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, leafComponentsSuperClass.getText())); - } - } - - }); - EditingUtils.setID(leafComponentsSuperClass, EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass); - EditingUtils.setEEFtype(leafComponentsSuperClass, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createLeafComponentsSuperClassText - - // End of user code - return parent; - } - - - protected Composite createPropertiesEditingProvidersSuperClassText(Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass, EEFGenMessages.GenEditionContextPropertiesEditionPart_PropertiesEditingProvidersSuperClassLabel); - propertiesEditingProvidersSuperClass = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData propertiesEditingProvidersSuperClassData = new GridData(GridData.FILL_HORIZONTAL); - propertiesEditingProvidersSuperClass.setLayoutData(propertiesEditingProvidersSuperClassData); - propertiesEditingProvidersSuperClass.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, propertiesEditingProvidersSuperClass.getText())); - } - - }); - propertiesEditingProvidersSuperClass.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenEditionContextPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, propertiesEditingProvidersSuperClass.getText())); - } - } - - }); - EditingUtils.setID(propertiesEditingProvidersSuperClass, EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass); - EditingUtils.setEEFtype(propertiesEditingProvidersSuperClass, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createPropertiesEditingProvidersSuperClassText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getPropertiesEditionContext() - * - */ - public EObject getPropertiesEditionContext() { - if (propertiesEditionContext.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) propertiesEditionContext.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#initPropertiesEditionContext(EObjectFlatComboSettings) - */ - public void initPropertiesEditionContext(EObjectFlatComboSettings settings) { - propertiesEditionContext.setInput(settings); - if (current != null) { - propertiesEditionContext.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext); - if (eefElementEditorReadOnlyState && propertiesEditionContext.isEnabled()) { - propertiesEditionContext.setEnabled(false); - propertiesEditionContext.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !propertiesEditionContext.isEnabled()) { - propertiesEditionContext.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setPropertiesEditionContext(EObject newValue) - * - */ - public void setPropertiesEditionContext(EObject newValue) { - if (newValue != null) { - propertiesEditionContext.setSelection(new StructuredSelection(newValue)); - } else { - propertiesEditionContext.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Reference.propertiesEditionContext); - if (eefElementEditorReadOnlyState && propertiesEditionContext.isEnabled()) { - propertiesEditionContext.setEnabled(false); - propertiesEditionContext.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !propertiesEditionContext.isEnabled()) { - propertiesEditionContext.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setPropertiesEditionContextButtonMode(ButtonsModeEnum newValue) - */ - public void setPropertiesEditionContextButtonMode(ButtonsModeEnum newValue) { - propertiesEditionContext.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#addFilterPropertiesEditionContext(ViewerFilter filter) - * - */ - public void addFilterToPropertiesEditionContext(ViewerFilter filter) { - propertiesEditionContext.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#addBusinessFilterPropertiesEditionContext(ViewerFilter filter) - * - */ - public void addBusinessFilterToPropertiesEditionContext(ViewerFilter filter) { - propertiesEditionContext.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getBasePackage() - * - */ - public String getBasePackage() { - return basePackage.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setBasePackage(String newValue) - * - */ - public void setBasePackage(String newValue) { - if (newValue != null) { - basePackage.setText(newValue); - } else { - basePackage.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Parameters.basePackage); - if (eefElementEditorReadOnlyState && basePackage.isEnabled()) { - basePackage.setEnabled(false); - basePackage.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !basePackage.isEnabled()) { - basePackage.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getDescriptorsContributorID() - * - */ - public String getDescriptorsContributorID() { - return descriptorsContributorID.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setDescriptorsContributorID(String newValue) - * - */ - public void setDescriptorsContributorID(String newValue) { - if (newValue != null) { - descriptorsContributorID.setText(newValue); - } else { - descriptorsContributorID.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Parameters.descriptorsContributorID); - if (eefElementEditorReadOnlyState && descriptorsContributorID.isEnabled()) { - descriptorsContributorID.setEnabled(false); - descriptorsContributorID.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !descriptorsContributorID.isEnabled()) { - descriptorsContributorID.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getGenericPropertiesViewsDescriptors() - * - */ - public Boolean getGenericPropertiesViewsDescriptors() { - return Boolean.valueOf(genericPropertiesViewsDescriptors.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setGenericPropertiesViewsDescriptors(Boolean newValue) - * - */ - public void setGenericPropertiesViewsDescriptors(Boolean newValue) { - if (newValue != null) { - genericPropertiesViewsDescriptors.setSelection(newValue.booleanValue()); - } else { - genericPropertiesViewsDescriptors.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Activation.genericPropertiesViewsDescriptors); - if (eefElementEditorReadOnlyState && genericPropertiesViewsDescriptors.isEnabled()) { - genericPropertiesViewsDescriptors.setEnabled(false); - genericPropertiesViewsDescriptors.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !genericPropertiesViewsDescriptors.isEnabled()) { - genericPropertiesViewsDescriptors.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getGMFSpecificPropertiesViews() - * - */ - public Boolean getGMFSpecificPropertiesViews() { - return Boolean.valueOf(gMFSpecificPropertiesViews.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setGMFSpecificPropertiesViews(Boolean newValue) - * - */ - public void setGMFSpecificPropertiesViews(Boolean newValue) { - if (newValue != null) { - gMFSpecificPropertiesViews.setSelection(newValue.booleanValue()); - } else { - gMFSpecificPropertiesViews.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Activation.gMFSpecificPropertiesViews); - if (eefElementEditorReadOnlyState && gMFSpecificPropertiesViews.isEnabled()) { - gMFSpecificPropertiesViews.setEnabled(false); - gMFSpecificPropertiesViews.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !gMFSpecificPropertiesViews.isEnabled()) { - gMFSpecificPropertiesViews.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getJUnitTestCases() - * - */ - public Boolean getJUnitTestCases() { - return Boolean.valueOf(jUnitTestCases.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setJUnitTestCases(Boolean newValue) - * - */ - public void setJUnitTestCases(Boolean newValue) { - if (newValue != null) { - jUnitTestCases.setSelection(newValue.booleanValue()); - } else { - jUnitTestCases.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Activation.jUnitTestCases); - if (eefElementEditorReadOnlyState && jUnitTestCases.isEnabled()) { - jUnitTestCases.setEnabled(false); - jUnitTestCases.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !jUnitTestCases.isEnabled()) { - jUnitTestCases.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getLeafComponentsSuperClass() - * - */ - public String getLeafComponentsSuperClass() { - return leafComponentsSuperClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setLeafComponentsSuperClass(String newValue) - * - */ - public void setLeafComponentsSuperClass(String newValue) { - if (newValue != null) { - leafComponentsSuperClass.setText(newValue); - } else { - leafComponentsSuperClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Implementation.leafComponentsSuperClass); - if (eefElementEditorReadOnlyState && leafComponentsSuperClass.isEnabled()) { - leafComponentsSuperClass.setEnabled(false); - leafComponentsSuperClass.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !leafComponentsSuperClass.isEnabled()) { - leafComponentsSuperClass.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#getPropertiesEditingProvidersSuperClass() - * - */ - public String getPropertiesEditingProvidersSuperClass() { - return propertiesEditingProvidersSuperClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenEditionContextPropertiesEditionPart#setPropertiesEditingProvidersSuperClass(String newValue) - * - */ - public void setPropertiesEditingProvidersSuperClass(String newValue) { - if (newValue != null) { - propertiesEditingProvidersSuperClass.setText(newValue); - } else { - propertiesEditingProvidersSuperClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenEditionContext.Implementation.propertiesEditingProvidersSuperClass); - if (eefElementEditorReadOnlyState && propertiesEditingProvidersSuperClass.isEnabled()) { - propertiesEditingProvidersSuperClass.setEnabled(false); - propertiesEditingProvidersSuperClass.setToolTipText(EEFGenMessages.GenEditionContext_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !propertiesEditingProvidersSuperClass.isEnabled()) { - propertiesEditingProvidersSuperClass.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EEFGenMessages.GenEditionContext_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/GenViewsRepositoryPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/GenViewsRepositoryPropertiesEditionPartImpl.java deleted file mode 100644 index c0d7a077d..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/parts/impl/GenViewsRepositoryPropertiesEditionPartImpl.java +++ /dev/null @@ -1,817 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.common.util.Enumerator; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; -import org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart; -import org.eclipse.emf.eef.EEFGen.providers.EEFGenMessages; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ArrayContentProvider; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class GenViewsRepositoryPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, GenViewsRepositoryPropertiesEditionPart { - - protected EObjectFlatComboViewer viewsRepository; - protected Text basePackage; - protected EMFComboViewer helpStrategy; - protected Button sWTViews; - protected Button formsViews; - protected Text partsSuperClass; - protected Text formsSuperClass; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public GenViewsRepositoryPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence genViewsRepositoryStep = new BindingCompositionSequence(propertiesEditionComponent); - genViewsRepositoryStep - .addStep(EEFGenViewsRepository.GenViewsRepository.Reference.class) - .addStep(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository); - - CompositionStep parametersStep = genViewsRepositoryStep.addStep(EEFGenViewsRepository.GenViewsRepository.Parameters.class); - parametersStep.addStep(EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage); - parametersStep.addStep(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy); - - CompositionStep activationStep = genViewsRepositoryStep.addStep(EEFGenViewsRepository.GenViewsRepository.Activation.class); - activationStep.addStep(EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews); - activationStep.addStep(EEFGenViewsRepository.GenViewsRepository.Activation.formsViews); - - CompositionStep implementationStep = genViewsRepositoryStep.addStep(EEFGenViewsRepository.GenViewsRepository.Implementation.class); - implementationStep.addStep(EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass); - implementationStep.addStep(EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass); - - - composer = new PartComposer(genViewsRepositoryStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == EEFGenViewsRepository.GenViewsRepository.Reference.class) { - return createReferenceGroup(parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository) { - return createViewsRepositoryFlatComboViewer(parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Parameters.class) { - return createParametersGroup(parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage) { - return createBasePackageText(parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy) { - return createHelpStrategyEMFComboViewer(parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Activation.class) { - return createActivationGroup(parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews) { - return createSWTViewsCheckbox(parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Activation.formsViews) { - return createFormsViewsCheckbox(parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Implementation.class) { - return createImplementationGroup(parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass) { - return createPartsSuperClassText(parent); - } - if (key == EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass) { - return createFormsSuperClassText(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createReferenceGroup(Composite parent) { - Group referenceGroup = new Group(parent, SWT.NONE); - referenceGroup.setText(EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_ReferenceGroupLabel); - GridData referenceGroupData = new GridData(GridData.FILL_HORIZONTAL); - referenceGroupData.horizontalSpan = 3; - referenceGroup.setLayoutData(referenceGroupData); - GridLayout referenceGroupLayout = new GridLayout(); - referenceGroupLayout.numColumns = 3; - referenceGroup.setLayout(referenceGroupLayout); - return referenceGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createViewsRepositoryFlatComboViewer(Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_ViewsRepositoryLabel); - viewsRepository = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository, EEFGenViewsRepository.SWT_KIND)); - viewsRepository.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - viewsRepository.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getViewsRepository())); - } - - }); - GridData viewsRepositoryData = new GridData(GridData.FILL_HORIZONTAL); - viewsRepository.setLayoutData(viewsRepositoryData); - viewsRepository.setID(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createViewsRepositoryFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createParametersGroup(Composite parent) { - Group parametersGroup = new Group(parent, SWT.NONE); - parametersGroup.setText(EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_ParametersGroupLabel); - GridData parametersGroupData = new GridData(GridData.FILL_HORIZONTAL); - parametersGroupData.horizontalSpan = 3; - parametersGroup.setLayoutData(parametersGroupData); - GridLayout parametersGroupLayout = new GridLayout(); - parametersGroupLayout.numColumns = 3; - parametersGroup.setLayout(parametersGroupLayout); - return parametersGroup; - } - - - protected Composite createBasePackageText(Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_BasePackageLabel); - basePackage = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData basePackageData = new GridData(GridData.FILL_HORIZONTAL); - basePackage.setLayoutData(basePackageData); - basePackage.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, basePackage.getText())); - } - - }); - basePackage.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, basePackage.getText())); - } - } - - }); - EditingUtils.setID(basePackage, EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage); - EditingUtils.setEEFtype(basePackage, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createBasePackageText - - // End of user code - return parent; - } - - - protected Composite createHelpStrategyEMFComboViewer(Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_HelpStrategyLabel); - helpStrategy = new EMFComboViewer(parent); - helpStrategy.setContentProvider(new ArrayContentProvider()); - helpStrategy.setLabelProvider(new AdapterFactoryLabelProvider(EEFRuntimePlugin.getDefault().getAdapterFactory())); - GridData helpStrategyData = new GridData(GridData.FILL_HORIZONTAL); - helpStrategy.getCombo().setLayoutData(helpStrategyData); - helpStrategy.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - * - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getHelpStrategy())); - } - - }); - helpStrategy.setID(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createHelpStrategyEMFComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createActivationGroup(Composite parent) { - Group activationGroup = new Group(parent, SWT.NONE); - activationGroup.setText(EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_ActivationGroupLabel); - GridData activationGroupData = new GridData(GridData.FILL_HORIZONTAL); - activationGroupData.horizontalSpan = 3; - activationGroup.setLayoutData(activationGroupData); - GridLayout activationGroupLayout = new GridLayout(); - activationGroupLayout.numColumns = 3; - activationGroup.setLayout(activationGroupLayout); - return activationGroup; - } - - - protected Composite createSWTViewsCheckbox(Composite parent) { - sWTViews = new Button(parent, SWT.CHECK); - sWTViews.setText(getDescription(EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_SWTViewsLabel)); - sWTViews.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(sWTViews.getSelection()))); - } - - }); - GridData sWTViewsData = new GridData(GridData.FILL_HORIZONTAL); - sWTViewsData.horizontalSpan = 2; - sWTViews.setLayoutData(sWTViewsData); - EditingUtils.setID(sWTViews, EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews); - EditingUtils.setEEFtype(sWTViews, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createSWTViewsCheckbox - - // End of user code - return parent; - } - - - protected Composite createFormsViewsCheckbox(Composite parent) { - formsViews = new Button(parent, SWT.CHECK); - formsViews.setText(getDescription(EEFGenViewsRepository.GenViewsRepository.Activation.formsViews, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_FormsViewsLabel)); - formsViews.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenViewsRepository.Activation.formsViews, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(formsViews.getSelection()))); - } - - }); - GridData formsViewsData = new GridData(GridData.FILL_HORIZONTAL); - formsViewsData.horizontalSpan = 2; - formsViews.setLayoutData(formsViewsData); - EditingUtils.setID(formsViews, EEFGenViewsRepository.GenViewsRepository.Activation.formsViews); - EditingUtils.setEEFtype(formsViews, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Activation.formsViews, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createFormsViewsCheckbox - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createImplementationGroup(Composite parent) { - Group implementationGroup = new Group(parent, SWT.NONE); - implementationGroup.setText(EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_ImplementationGroupLabel); - GridData implementationGroupData = new GridData(GridData.FILL_HORIZONTAL); - implementationGroupData.horizontalSpan = 3; - implementationGroup.setLayoutData(implementationGroupData); - GridLayout implementationGroupLayout = new GridLayout(); - implementationGroupLayout.numColumns = 3; - implementationGroup.setLayout(implementationGroupLayout); - return implementationGroup; - } - - - protected Composite createPartsSuperClassText(Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_PartsSuperClassLabel); - partsSuperClass = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData partsSuperClassData = new GridData(GridData.FILL_HORIZONTAL); - partsSuperClass.setLayoutData(partsSuperClassData); - partsSuperClass.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, partsSuperClass.getText())); - } - - }); - partsSuperClass.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, partsSuperClass.getText())); - } - } - - }); - EditingUtils.setID(partsSuperClass, EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass); - EditingUtils.setEEFtype(partsSuperClass, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createPartsSuperClassText - - // End of user code - return parent; - } - - - protected Composite createFormsSuperClassText(Composite parent) { - createDescription(parent, EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass, EEFGenMessages.GenViewsRepositoryPropertiesEditionPart_FormsSuperClassLabel); - formsSuperClass = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData formsSuperClassData = new GridData(GridData.FILL_HORIZONTAL); - formsSuperClass.setLayoutData(formsSuperClassData); - formsSuperClass.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, formsSuperClass.getText())); - } - - }); - formsSuperClass.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(GenViewsRepositoryPropertiesEditionPartImpl.this, EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, formsSuperClass.getText())); - } - } - - }); - EditingUtils.setID(formsSuperClass, EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass); - EditingUtils.setEEFtype(formsSuperClass, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass, EEFGenViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createFormsSuperClassText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getViewsRepository() - * - */ - public EObject getViewsRepository() { - if (viewsRepository.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) viewsRepository.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#initViewsRepository(EObjectFlatComboSettings) - */ - public void initViewsRepository(EObjectFlatComboSettings settings) { - viewsRepository.setInput(settings); - if (current != null) { - viewsRepository.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository); - if (eefElementEditorReadOnlyState && viewsRepository.isEnabled()) { - viewsRepository.setEnabled(false); - viewsRepository.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !viewsRepository.isEnabled()) { - viewsRepository.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setViewsRepository(EObject newValue) - * - */ - public void setViewsRepository(EObject newValue) { - if (newValue != null) { - viewsRepository.setSelection(new StructuredSelection(newValue)); - } else { - viewsRepository.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Reference.viewsRepository); - if (eefElementEditorReadOnlyState && viewsRepository.isEnabled()) { - viewsRepository.setEnabled(false); - viewsRepository.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !viewsRepository.isEnabled()) { - viewsRepository.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setViewsRepositoryButtonMode(ButtonsModeEnum newValue) - */ - public void setViewsRepositoryButtonMode(ButtonsModeEnum newValue) { - viewsRepository.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#addFilterViewsRepository(ViewerFilter filter) - * - */ - public void addFilterToViewsRepository(ViewerFilter filter) { - viewsRepository.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#addBusinessFilterViewsRepository(ViewerFilter filter) - * - */ - public void addBusinessFilterToViewsRepository(ViewerFilter filter) { - viewsRepository.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getBasePackage() - * - */ - public String getBasePackage() { - return basePackage.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setBasePackage(String newValue) - * - */ - public void setBasePackage(String newValue) { - if (newValue != null) { - basePackage.setText(newValue); - } else { - basePackage.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Parameters.basePackage); - if (eefElementEditorReadOnlyState && basePackage.isEnabled()) { - basePackage.setEnabled(false); - basePackage.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !basePackage.isEnabled()) { - basePackage.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getHelpStrategy() - * - */ - public Enumerator getHelpStrategy() { - Enumerator selection = (Enumerator) ((StructuredSelection) helpStrategy.getSelection()).getFirstElement(); - return selection; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#initHelpStrategy(Object input, Enumerator current) - */ - public void initHelpStrategy(Object input, Enumerator current) { - helpStrategy.setInput(input); - helpStrategy.modelUpdating(new StructuredSelection(current)); - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy); - if (eefElementEditorReadOnlyState && helpStrategy.isEnabled()) { - helpStrategy.setEnabled(false); - helpStrategy.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !helpStrategy.isEnabled()) { - helpStrategy.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setHelpStrategy(Enumerator newValue) - * - */ - public void setHelpStrategy(Enumerator newValue) { - helpStrategy.modelUpdating(new StructuredSelection(newValue)); - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Parameters.helpStrategy); - if (eefElementEditorReadOnlyState && helpStrategy.isEnabled()) { - helpStrategy.setEnabled(false); - helpStrategy.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !helpStrategy.isEnabled()) { - helpStrategy.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getSWTViews() - * - */ - public Boolean getSWTViews() { - return Boolean.valueOf(sWTViews.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setSWTViews(Boolean newValue) - * - */ - public void setSWTViews(Boolean newValue) { - if (newValue != null) { - sWTViews.setSelection(newValue.booleanValue()); - } else { - sWTViews.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Activation.sWTViews); - if (eefElementEditorReadOnlyState && sWTViews.isEnabled()) { - sWTViews.setEnabled(false); - sWTViews.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !sWTViews.isEnabled()) { - sWTViews.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getFormsViews() - * - */ - public Boolean getFormsViews() { - return Boolean.valueOf(formsViews.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setFormsViews(Boolean newValue) - * - */ - public void setFormsViews(Boolean newValue) { - if (newValue != null) { - formsViews.setSelection(newValue.booleanValue()); - } else { - formsViews.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Activation.formsViews); - if (eefElementEditorReadOnlyState && formsViews.isEnabled()) { - formsViews.setEnabled(false); - formsViews.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !formsViews.isEnabled()) { - formsViews.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getPartsSuperClass() - * - */ - public String getPartsSuperClass() { - return partsSuperClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setPartsSuperClass(String newValue) - * - */ - public void setPartsSuperClass(String newValue) { - if (newValue != null) { - partsSuperClass.setText(newValue); - } else { - partsSuperClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Implementation.partsSuperClass); - if (eefElementEditorReadOnlyState && partsSuperClass.isEnabled()) { - partsSuperClass.setEnabled(false); - partsSuperClass.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !partsSuperClass.isEnabled()) { - partsSuperClass.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#getFormsSuperClass() - * - */ - public String getFormsSuperClass() { - return formsSuperClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.EEFGen.parts.GenViewsRepositoryPropertiesEditionPart#setFormsSuperClass(String newValue) - * - */ - public void setFormsSuperClass(String newValue) { - if (newValue != null) { - formsSuperClass.setText(newValue); - } else { - formsSuperClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(EEFGenViewsRepository.GenViewsRepository.Implementation.formsSuperClass); - if (eefElementEditorReadOnlyState && formsSuperClass.isEnabled()) { - formsSuperClass.setEnabled(false); - formsSuperClass.setToolTipText(EEFGenMessages.GenViewsRepository_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !formsSuperClass.isEnabled()) { - formsSuperClass.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return EEFGenMessages.GenViewsRepository_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenEditPlugin.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenEditPlugin.java deleted file mode 100644 index 2b28ea2be..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenEditPlugin.java +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.provider; - -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelEditPlugin; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.provider.EcoreEditPlugin; -import org.eclipse.emf.eef.components.provider.ComponentsEditPlugin; -import org.eclipse.emf.eef.mapping.provider.MappingEditPlugin; -import org.eclipse.emf.eef.views.provider.ViewsEditPlugin; - -/** - * This is the central singleton for the EEFGen edit plugin. - * - * - * @generated - */ -public final class EEFGenEditPlugin extends EMFPlugin { - /** - * Keep track of the singleton. - * - * - * @generated - */ - public static final EEFGenEditPlugin INSTANCE = new EEFGenEditPlugin(); - - /** - * Keep track of the singleton. - * - * - * @generated - */ - private static Implementation plugin; - - /** - * Create the instance. - * - * - * @generated - */ - public EEFGenEditPlugin() { - super - (new ResourceLocator [] { - ComponentsEditPlugin.INSTANCE, - EcoreEditPlugin.INSTANCE, - GenModelEditPlugin.INSTANCE, - MappingEditPlugin.INSTANCE, - ViewsEditPlugin.INSTANCE, - }); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - @Override - public ResourceLocator getPluginResourceLocator() { - return plugin; - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * - * @generated NOT - */ - public static class Implementation extends EclipsePlugin { - /** - * Creates an instance. - * - * - * @generated - */ - public Implementation() { - super(); - - // Remember the static instance. - // - plugin = this; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenItemProviderAdapterFactory.java deleted file mode 100644 index 28189ed45..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenItemProviderAdapterFactory.java +++ /dev/null @@ -1,277 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.provider; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.EEFGen.util.EEFGenAdapterFactory; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class EEFGenItemProviderAdapterFactory extends EEFGenAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public EEFGenItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.EEFGen.GenEditionContext} instances. - * - * - * @generated - */ - protected GenEditionContextItemProvider genEditionContextItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.EEFGen.GenEditionContext}. - * - * - * @generated - */ - @Override - public Adapter createGenEditionContextAdapter() { - if (genEditionContextItemProvider == null) { - genEditionContextItemProvider = new GenEditionContextItemProvider(this); - } - - return genEditionContextItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.EEFGen.EEFGenModelReference} instances. - * - * - * @generated - */ - protected EEFGenModelReferenceItemProvider eefGenModelReferenceItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.EEFGen.EEFGenModelReference}. - * - * - * @generated - */ - @Override - public Adapter createEEFGenModelReferenceAdapter() { - if (eefGenModelReferenceItemProvider == null) { - eefGenModelReferenceItemProvider = new EEFGenModelReferenceItemProvider(this); - } - - return eefGenModelReferenceItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.EEFGen.EEFGenModel} instances. - * - * - * @generated - */ - protected EEFGenModelItemProvider eefGenModelItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.EEFGen.EEFGenModel}. - * - * - * @generated - */ - @Override - public Adapter createEEFGenModelAdapter() { - if (eefGenModelItemProvider == null) { - eefGenModelItemProvider = new EEFGenModelItemProvider(this); - } - - return eefGenModelItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository} instances. - * - * - * @generated - */ - protected GenViewsRepositoryItemProvider genViewsRepositoryItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository}. - * - * - * @generated - */ - @Override - public Adapter createGenViewsRepositoryAdapter() { - if (genViewsRepositoryItemProvider == null) { - genViewsRepositoryItemProvider = new GenViewsRepositoryItemProvider(this); - } - - return genViewsRepositoryItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) || (((Class)type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (genEditionContextItemProvider != null) genEditionContextItemProvider.dispose(); - if (eefGenModelReferenceItemProvider != null) eefGenModelReferenceItemProvider.dispose(); - if (eefGenModelItemProvider != null) eefGenModelItemProvider.dispose(); - if (genViewsRepositoryItemProvider != null) genViewsRepositoryItemProvider.dispose(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenModelItemProvider.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenModelItemProvider.java deleted file mode 100644 index 3317b0d90..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenModelItemProvider.java +++ /dev/null @@ -1,312 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.EEFGen.EEFGenFactory; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.EEFGen.EEFGenModel} object. - * - * - * @generated - */ -public class EEFGenModelItemProvider - extends ItemProviderAdapter - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFGenModelItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addGenDirectoryPropertyDescriptor(object); - addAuthorPropertyDescriptor(object); - addLicensePropertyDescriptor(object); - addTestsGenDirectoryPropertyDescriptor(object); - addUseJMergeForUserCodePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Gen Directory feature. - * - * - * @generated - */ - protected void addGenDirectoryPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EEFGenModel_genDirectory_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EEFGenModel_genDirectory_feature", "_UI_EEFGenModel_type"), - EEFGenPackage.Literals.EEF_GEN_MODEL__GEN_DIRECTORY, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Author feature. - * - * - * @generated - */ - protected void addAuthorPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EEFGenModel_author_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EEFGenModel_author_feature", "_UI_EEFGenModel_type"), - EEFGenPackage.Literals.EEF_GEN_MODEL__AUTHOR, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the License feature. - * - * - * @generated - */ - protected void addLicensePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EEFGenModel_license_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EEFGenModel_license_feature", "_UI_EEFGenModel_type"), - EEFGenPackage.Literals.EEF_GEN_MODEL__LICENSE, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Tests Gen Directory feature. - * - * - * @generated - */ - protected void addTestsGenDirectoryPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EEFGenModel_testsGenDirectory_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EEFGenModel_testsGenDirectory_feature", "_UI_EEFGenModel_type"), - EEFGenPackage.Literals.EEF_GEN_MODEL__TESTS_GEN_DIRECTORY, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Use JMerge For User Code feature. - * - * - * @generated - */ - protected void addUseJMergeForUserCodePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EEFGenModel_useJMergeForUserCode_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EEFGenModel_useJMergeForUserCode_feature", "_UI_EEFGenModel_type"), - EEFGenPackage.Literals.EEF_GEN_MODEL__USE_JMERGE_FOR_USER_CODE, - true, - false, - false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, - null, - null)); - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures(Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures.add(EEFGenPackage.Literals.EEF_GEN_MODEL__EDITION_CONTEXTS); - childrenFeatures.add(EEFGenPackage.Literals.EEF_GEN_MODEL__VIEWS_REPOSITORIES); - childrenFeatures.add(EEFGenPackage.Literals.EEF_GEN_MODEL__REFERENCES); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns EEFGenModel.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/EEFGenModel")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EEFGenModel)object).getGenDirectory(); - return label == null || label.length() == 0 ? - getString("_UI_EEFGenModel_type") : - getString("_UI_EEFGenModel_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(EEFGenModel.class)) { - case EEFGenPackage.EEF_GEN_MODEL__GEN_DIRECTORY: - case EEFGenPackage.EEF_GEN_MODEL__AUTHOR: - case EEFGenPackage.EEF_GEN_MODEL__LICENSE: - case EEFGenPackage.EEF_GEN_MODEL__TESTS_GEN_DIRECTORY: - case EEFGenPackage.EEF_GEN_MODEL__USE_JMERGE_FOR_USER_CODE: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - case EEFGenPackage.EEF_GEN_MODEL__EDITION_CONTEXTS: - case EEFGenPackage.EEF_GEN_MODEL__VIEWS_REPOSITORIES: - case EEFGenPackage.EEF_GEN_MODEL__REFERENCES: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add - (createChildParameter - (EEFGenPackage.Literals.EEF_GEN_MODEL__EDITION_CONTEXTS, - EEFGenFactory.eINSTANCE.createGenEditionContext())); - - newChildDescriptors.add - (createChildParameter - (EEFGenPackage.Literals.EEF_GEN_MODEL__VIEWS_REPOSITORIES, - EEFGenFactory.eINSTANCE.createGenViewsRepository())); - - newChildDescriptors.add - (createChildParameter - (EEFGenPackage.Literals.EEF_GEN_MODEL__REFERENCES, - EEFGenFactory.eINSTANCE.createEEFGenModelReference())); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return EEFGenEditPlugin.INSTANCE; - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenModelReferenceItemProvider.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenModelReferenceItemProvider.java deleted file mode 100644 index 53a766499..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/EEFGenModelReferenceItemProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.EEFGen.EEFGenModelReference} object. - * - * - * @generated - */ -public class EEFGenModelReferenceItemProvider - extends ItemProviderAdapter - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFGenModelReferenceItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addReferencedContextPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Referenced Context feature. - * - * - * @generated - */ - protected void addReferencedContextPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EEFGenModelReference_referencedContext_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EEFGenModelReference_referencedContext_feature", "_UI_EEFGenModelReference_type"), - EEFGenPackage.Literals.EEF_GEN_MODEL_REFERENCE__REFERENCED_CONTEXT, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns EEFGenModelReference.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/EEFGenModelReference")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_EEFGenModelReference_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return EEFGenEditPlugin.INSTANCE; - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/GenEditionContextItemProvider.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/GenEditionContextItemProvider.java deleted file mode 100644 index bf3626d7a..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/GenEditionContextItemProvider.java +++ /dev/null @@ -1,329 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.EEFGen.GenEditionContext} object. - * - * - * @generated - */ -public class GenEditionContextItemProvider - extends ItemProviderAdapter - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public GenEditionContextItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addPropertiesEditionContextPropertyDescriptor(object); - addBasePackagePropertyDescriptor(object); - addDescriptorsContributorIDPropertyDescriptor(object); - addDescriptorsGenericPropertiesViewsPropertyDescriptor(object); - addGmfPropertiesViewsPropertyDescriptor(object); - addGenerateJunitTestCasesPropertyDescriptor(object); - addLeafComponentsSuperClassPropertyDescriptor(object); - addPropertiesEditingProvidersSuperClassPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Properties Edition Context feature. - * - * - * @generated - */ - protected void addPropertiesEditionContextPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenEditionContext_PropertiesEditionContext_feature"), - getString("_UI_GenEditionContext_PropertiesEditionContext_description"), - EEFGenPackage.Literals.GEN_EDITION_CONTEXT__PROPERTIES_EDITION_CONTEXT, - true, - false, - true, - null, - getString("_UI_ReferencesPropertyCategory"), - null)); - } - - /** - * This adds a property descriptor for the Base Package feature. - * - * - * @generated - */ - protected void addBasePackagePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenEditionContext_basePackage_feature"), - getString("_UI_GenEditionContext_basePackage_description"), - EEFGenPackage.Literals.GEN_EDITION_CONTEXT__BASE_PACKAGE, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - getString("_UI_ParametersPropertyCategory"), - null)); - } - - /** - * This adds a property descriptor for the Descriptors Contributor ID feature. - * - * - * @generated - */ - protected void addDescriptorsContributorIDPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenEditionContext_descriptorsContributorID_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_GenEditionContext_descriptorsContributorID_feature", "_UI_GenEditionContext_type"), - EEFGenPackage.Literals.GEN_EDITION_CONTEXT__DESCRIPTORS_CONTRIBUTOR_ID, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Descriptors Generic Properties Views feature. - * - * - * @generated - */ - protected void addDescriptorsGenericPropertiesViewsPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenEditionContext_descriptorsGenericPropertiesViews_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_GenEditionContext_descriptorsGenericPropertiesViews_feature", "_UI_GenEditionContext_type"), - EEFGenPackage.Literals.GEN_EDITION_CONTEXT__DESCRIPTORS_GENERIC_PROPERTIES_VIEWS, - true, - false, - false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Gmf Properties Views feature. - * - * - * @generated - */ - protected void addGmfPropertiesViewsPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenEditionContext_gmfPropertiesViews_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_GenEditionContext_gmfPropertiesViews_feature", "_UI_GenEditionContext_type"), - EEFGenPackage.Literals.GEN_EDITION_CONTEXT__GMF_PROPERTIES_VIEWS, - true, - false, - false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Generate Junit Test Cases feature. - * - * - * @generated - */ - protected void addGenerateJunitTestCasesPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenEditionContext_generateJunitTestCases_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_GenEditionContext_generateJunitTestCases_feature", "_UI_GenEditionContext_type"), - EEFGenPackage.Literals.GEN_EDITION_CONTEXT__GENERATE_JUNIT_TEST_CASES, - true, - false, - false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Leaf Components Super Class feature. - * - * - * @generated - */ - protected void addLeafComponentsSuperClassPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenEditionContext_leafComponentsSuperClass_feature"), - getString("_UI_GenEditionContext_leafComponentsSuperClass_description"), - EEFGenPackage.Literals.GEN_EDITION_CONTEXT__LEAF_COMPONENTS_SUPER_CLASS, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - getString("_UI_implementationPropertyCategory"), - null)); - } - - /** - * This adds a property descriptor for the Properties Editing Providers Super Class feature. - * - * - * @generated - */ - protected void addPropertiesEditingProvidersSuperClassPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenEditionContext_propertiesEditingProvidersSuperClass_feature"), - getString("_UI_GenEditionContext_propertiesEditingProvidersSuperClass_description"), - EEFGenPackage.Literals.GEN_EDITION_CONTEXT__PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - getString("_UI_implementationPropertyCategory"), - null)); - } - - /** - * This returns GenEditionContext.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/GenEditionContext")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((GenEditionContext)object).getBasePackage(); - return label == null || label.length() == 0 ? - getString("_UI_GenEditionContext_type") : - getString("_UI_GenEditionContext_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(GenEditionContext.class)) { - case EEFGenPackage.GEN_EDITION_CONTEXT__BASE_PACKAGE: - case EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_CONTRIBUTOR_ID: - case EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_GENERIC_PROPERTIES_VIEWS: - case EEFGenPackage.GEN_EDITION_CONTEXT__GMF_PROPERTIES_VIEWS: - case EEFGenPackage.GEN_EDITION_CONTEXT__GENERATE_JUNIT_TEST_CASES: - case EEFGenPackage.GEN_EDITION_CONTEXT__LEAF_COMPONENTS_SUPER_CLASS: - case EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return EEFGenEditPlugin.INSTANCE; - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/GenViewsRepositoryItemProvider.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/GenViewsRepositoryItemProvider.java deleted file mode 100644 index b19483439..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/provider/GenViewsRepositoryItemProvider.java +++ /dev/null @@ -1,305 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository} object. - * - * - * @generated - */ -public class GenViewsRepositoryItemProvider - extends ItemProviderAdapter - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public GenViewsRepositoryItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addViewsRepositoryPropertyDescriptor(object); - addBasePackagePropertyDescriptor(object); - addSwtViewsPropertyDescriptor(object); - addFormViewsPropertyDescriptor(object); - addHelpStrategyPropertyDescriptor(object); - addPartsSuperClassPropertyDescriptor(object); - addFormsSuperClassPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Views Repository feature. - * - * - * @generated - */ - protected void addViewsRepositoryPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenViewsRepository_viewsRepository_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_GenViewsRepository_viewsRepository_feature", "_UI_GenViewsRepository_type"), - EEFGenPackage.Literals.GEN_VIEWS_REPOSITORY__VIEWS_REPOSITORY, - true, - false, - true, - null, - null, - null)); - } - - /** - * This adds a property descriptor for the Base Package feature. - * - * - * @generated - */ - protected void addBasePackagePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenViewsRepository_basePackage_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_GenViewsRepository_basePackage_feature", "_UI_GenViewsRepository_type"), - EEFGenPackage.Literals.GEN_VIEWS_REPOSITORY__BASE_PACKAGE, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Swt Views feature. - * - * - * @generated - */ - protected void addSwtViewsPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenViewsRepository_swtViews_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_GenViewsRepository_swtViews_feature", "_UI_GenViewsRepository_type"), - EEFGenPackage.Literals.GEN_VIEWS_REPOSITORY__SWT_VIEWS, - true, - false, - false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Form Views feature. - * - * - * @generated - */ - protected void addFormViewsPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenViewsRepository_formViews_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_GenViewsRepository_formViews_feature", "_UI_GenViewsRepository_type"), - EEFGenPackage.Literals.GEN_VIEWS_REPOSITORY__FORM_VIEWS, - true, - false, - false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Help Strategy feature. - * - * - * @generated - */ - protected void addHelpStrategyPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenViewsRepository_helpStrategy_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_GenViewsRepository_helpStrategy_feature", "_UI_GenViewsRepository_type"), - EEFGenPackage.Literals.GEN_VIEWS_REPOSITORY__HELP_STRATEGY, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Parts Super Class feature. - * - * - * @generated - */ - protected void addPartsSuperClassPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenViewsRepository_partsSuperClass_feature"), - getString("_UI_GenViewsRepository_partsSuperClass_description"), - EEFGenPackage.Literals.GEN_VIEWS_REPOSITORY__PARTS_SUPER_CLASS, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Forms Super Class feature. - * - * - * @generated - */ - protected void addFormsSuperClassPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_GenViewsRepository_formsSuperClass_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_GenViewsRepository_formsSuperClass_feature", "_UI_GenViewsRepository_type"), - EEFGenPackage.Literals.GEN_VIEWS_REPOSITORY__FORMS_SUPER_CLASS, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns GenViewsRepository.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/GenViewsRepository")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((GenViewsRepository)object).getBasePackage(); - return label == null || label.length() == 0 ? - getString("_UI_GenViewsRepository_type") : - getString("_UI_GenViewsRepository_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(GenViewsRepository.class)) { - case EEFGenPackage.GEN_VIEWS_REPOSITORY__BASE_PACKAGE: - case EEFGenPackage.GEN_VIEWS_REPOSITORY__SWT_VIEWS: - case EEFGenPackage.GEN_VIEWS_REPOSITORY__FORM_VIEWS: - case EEFGenPackage.GEN_VIEWS_REPOSITORY__HELP_STRATEGY: - case EEFGenPackage.GEN_VIEWS_REPOSITORY__PARTS_SUPER_CLASS: - case EEFGenPackage.GEN_VIEWS_REPOSITORY__FORMS_SUPER_CLASS: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return EEFGenEditPlugin.INSTANCE; - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenEEFAdapterFactory.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenEEFAdapterFactory.java deleted file mode 100644 index 6ae497f25..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenEEFAdapterFactory.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.providers; - -import org.eclipse.emf.common.notify.Adapter; - -import org.eclipse.emf.eef.EEFGen.util.EEFGenAdapterFactory; - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenEEFAdapterFactory extends EEFGenAdapterFactory { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.EEFGen.util.EEFGenAdapterFactory#createGenEditionContextAdapter() - * - */ - public Adapter createGenEditionContextAdapter() { - return new GenEditionContextPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.EEFGen.util.EEFGenAdapterFactory#createEEFGenModelReferenceAdapter() - * - */ - public Adapter createEEFGenModelReferenceAdapter() { - return new EEFGenModelReferencePropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.EEFGen.util.EEFGenAdapterFactory#createEEFGenModelAdapter() - * - */ - public Adapter createEEFGenModelAdapter() { - return new EEFGenModelPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.EEFGen.util.EEFGenAdapterFactory#createGenViewsRepositoryAdapter() - * - */ - public Adapter createGenViewsRepositoryAdapter() { - return new GenViewsRepositoryPropertiesEditionProvider(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenMessages.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenMessages.java deleted file mode 100644 index ab49ff095..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenMessages.java +++ /dev/null @@ -1,207 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.providers; - -import org.eclipse.osgi.util.NLS; - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenMessages extends NLS { - - private static final String BUNDLE_NAME = "org.eclipse.emf.eef.EEFGen.providers.eEFGenMessages"; //$NON-NLS-1$ - - - public static String GenEditionContextPropertiesEditionPart_ReferenceGroupLabel; - - - public static String GenEditionContextPropertiesEditionPart_ParametersGroupLabel; - - - public static String GenEditionContextPropertiesEditionPart_ActivationGroupLabel; - - - public static String GenEditionContextPropertiesEditionPart_ImplementationGroupLabel; - - - public static String EEFGenModelReferencePropertiesEditionPart_ReferenceGroupLabel; - - - public static String EEFGenModelPropertiesEditionPart_ParametersGroupLabel; - - - public static String EEFGenModelPropertiesEditionPart_LegalGroupLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_ReferenceGroupLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_ParametersGroupLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_ActivationGroupLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_ImplementationGroupLabel; - - - - public static String GenEditionContext_ReadOnly; - - - public static String GenEditionContext_Part_Title; - - - public static String EEFGenModelReference_ReadOnly; - - - public static String EEFGenModelReference_Part_Title; - - - public static String EEFGenModel_ReadOnly; - - - public static String EEFGenModel_Part_Title; - - - public static String GenViewsRepository_ReadOnly; - - - public static String GenViewsRepository_Part_Title; - - - - public static String GenEditionContextPropertiesEditionPart_PropertiesEditionContextLabel; - - - public static String GenEditionContextPropertiesEditionPart_BasePackageLabel; - - - public static String GenEditionContextPropertiesEditionPart_DescriptorsContributorIDLabel; - - - public static String GenEditionContextPropertiesEditionPart_GenericPropertiesViewsDescriptorsLabel; - - - public static String GenEditionContextPropertiesEditionPart_GMFSpecificPropertiesViewsLabel; - - - public static String GenEditionContextPropertiesEditionPart_JUnitTestCasesLabel; - - - public static String GenEditionContextPropertiesEditionPart_LeafComponentsSuperClassLabel; - - - public static String GenEditionContextPropertiesEditionPart_PropertiesEditingProvidersSuperClassLabel; - - - public static String EEFGenModelReferencePropertiesEditionPart_ReferencedEEFGenModelLabel; - - - public static String EEFGenModelPropertiesEditionPart_GenerationDirectoryLabel; - - - public static String EEFGenModelPropertiesEditionPart_TestsGenerationDirectoryLabel; - - - public static String EEFGenModelPropertiesEditionPart_UseJMergeToManageUserCodeLabel; - - - public static String EEFGenModelPropertiesEditionPart_AuthorLabel; - - - public static String EEFGenModelPropertiesEditionPart_LicenseLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_ViewsRepositoryLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_BasePackageLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_HelpStrategyLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_SWTViewsLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_FormsViewsLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_PartsSuperClassLabel; - - - public static String GenViewsRepositoryPropertiesEditionPart_FormsSuperClassLabel; - - - - public static String PropertiesEditionPart_DocumentationLabel; - - - public static String PropertiesEditionPart_IntegerValueMessage; - - - public static String PropertiesEditionPart_FloatValueMessage; - - - public static String PropertiesEditionPart_ShortValueMessage; - - - public static String PropertiesEditionPart_LongValueMessage; - - - public static String PropertiesEditionPart_ByteValueMessage; - - - public static String PropertiesEditionPart_BigIntegerValueMessage; - - - public static String PropertiesEditionPart_BigDecimalValueMessage; - - - public static String PropertiesEditionPart_DoubleValueMessage; - - - public static String PropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesEditionPart_RequiredFeatureMessage; - - - public static String PropertiesEditionPart_AddTableViewerLabel; - - - public static String PropertiesEditionPart_EditTableViewerLabel; - - - public static String PropertiesEditionPart_RemoveTableViewerLabel; - - - public static String PropertiesEditionPart_AddListViewerLabel; - - - public static String PropertiesEditionPart_RemoveListViewerLabel; - - // Start of user code for additionnal NLS Constants - - // End of user code - - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, EEFGenMessages.class); - } - - - private EEFGenMessages() { - //protect instanciation - } -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenModelPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenModelPropertiesEditionProvider.java deleted file mode 100644 index 1eb855a55..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenModelPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; - -import org.eclipse.emf.eef.EEFGen.components.EEFGenModelPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenModelPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public EEFGenModelPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public EEFGenModelPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof EEFGenModel) - && (EEFGenPackage.Literals.EEF_GEN_MODEL == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof EEFGenModel) && (EEFGenModelPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EEFGenModel) && (refinement == EEFGenModelPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EEFGenModel) && ((EEFGenModelPropertiesEditionComponent.BASE_PART.equals(part) && refinement == EEFGenModelPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof EEFGenModel) { - return new EEFGenModelPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof EEFGenModel) { - if (EEFGenModelPropertiesEditionComponent.BASE_PART.equals(part)) - return new EEFGenModelPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof EEFGenModel) { - if (EEFGenModelPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == EEFGenModelPropertiesEditionComponent.class) - return new EEFGenModelPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EEFGenPackage.Literals.EEF_GEN_MODEL == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenModelReferencePropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenModelReferencePropertiesEditionProvider.java deleted file mode 100644 index 649c373fb..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenModelReferencePropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.EEFGen.EEFGenModelReference; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; - -import org.eclipse.emf.eef.EEFGen.components.EEFGenModelReferencePropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenModelReferencePropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public EEFGenModelReferencePropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public EEFGenModelReferencePropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof EEFGenModelReference) - && (EEFGenPackage.Literals.EEF_GEN_MODEL_REFERENCE == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof EEFGenModelReference) && (EEFGenModelReferencePropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EEFGenModelReference) && (refinement == EEFGenModelReferencePropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EEFGenModelReference) && ((EEFGenModelReferencePropertiesEditionComponent.BASE_PART.equals(part) && refinement == EEFGenModelReferencePropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof EEFGenModelReference) { - return new EEFGenModelReferencePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof EEFGenModelReference) { - if (EEFGenModelReferencePropertiesEditionComponent.BASE_PART.equals(part)) - return new EEFGenModelReferencePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof EEFGenModelReference) { - if (EEFGenModelReferencePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == EEFGenModelReferencePropertiesEditionComponent.class) - return new EEFGenModelReferencePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EEFGenPackage.Literals.EEF_GEN_MODEL_REFERENCE == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenPropertiesEditionPartProvider.java deleted file mode 100644 index 49f458a76..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/EEFGenPropertiesEditionPartProvider.java +++ /dev/null @@ -1,79 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.providers; - -import org.eclipse.emf.eef.EEFGen.parts.EEFGenViewsRepository; - -import org.eclipse.emf.eef.EEFGen.parts.forms.EEFGenModelPropertiesEditionPartForm; -import org.eclipse.emf.eef.EEFGen.parts.forms.EEFGenModelReferencePropertiesEditionPartForm; -import org.eclipse.emf.eef.EEFGen.parts.forms.GenEditionContextPropertiesEditionPartForm; -import org.eclipse.emf.eef.EEFGen.parts.forms.GenViewsRepositoryPropertiesEditionPartForm; - -import org.eclipse.emf.eef.EEFGen.parts.impl.EEFGenModelPropertiesEditionPartImpl; -import org.eclipse.emf.eef.EEFGen.parts.impl.EEFGenModelReferencePropertiesEditionPartImpl; -import org.eclipse.emf.eef.EEFGen.parts.impl.GenEditionContextPropertiesEditionPartImpl; -import org.eclipse.emf.eef.EEFGen.parts.impl.GenViewsRepositoryPropertiesEditionPartImpl; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; - -/** - * @author Nathalie Lepine - * - */ -public class EEFGenPropertiesEditionPartProvider implements IPropertiesEditionPartProvider { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#provides(java.lang.Object) - * - */ - public boolean provides(Object key) { - return key == EEFGenViewsRepository.class; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#getPropertiesEditionPart(java.lang.Object, int, org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, IPropertiesEditionComponent component) { - if (key == EEFGenViewsRepository.GenEditionContext.class) { - if (kind == EEFGenViewsRepository.SWT_KIND) - return new GenEditionContextPropertiesEditionPartImpl(component); - if (kind == EEFGenViewsRepository.FORM_KIND) - return new GenEditionContextPropertiesEditionPartForm(component); - } - if (key == EEFGenViewsRepository.EEFGenModelReference.class) { - if (kind == EEFGenViewsRepository.SWT_KIND) - return new EEFGenModelReferencePropertiesEditionPartImpl(component); - if (kind == EEFGenViewsRepository.FORM_KIND) - return new EEFGenModelReferencePropertiesEditionPartForm(component); - } - if (key == EEFGenViewsRepository.EEFGenModel.class) { - if (kind == EEFGenViewsRepository.SWT_KIND) - return new EEFGenModelPropertiesEditionPartImpl(component); - if (kind == EEFGenViewsRepository.FORM_KIND) - return new EEFGenModelPropertiesEditionPartForm(component); - } - if (key == EEFGenViewsRepository.GenViewsRepository.class) { - if (kind == EEFGenViewsRepository.SWT_KIND) - return new GenViewsRepositoryPropertiesEditionPartImpl(component); - if (kind == EEFGenViewsRepository.FORM_KIND) - return new GenViewsRepositoryPropertiesEditionPartForm(component); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/GenEditionContextPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/GenEditionContextPropertiesEditionProvider.java deleted file mode 100644 index 984557bc3..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/GenEditionContextPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; - -import org.eclipse.emf.eef.EEFGen.components.GenEditionContextPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class GenEditionContextPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public GenEditionContextPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public GenEditionContextPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof GenEditionContext) - && (EEFGenPackage.Literals.GEN_EDITION_CONTEXT == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof GenEditionContext) && (GenEditionContextPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof GenEditionContext) && (refinement == GenEditionContextPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof GenEditionContext) && ((GenEditionContextPropertiesEditionComponent.BASE_PART.equals(part) && refinement == GenEditionContextPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof GenEditionContext) { - return new GenEditionContextPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof GenEditionContext) { - if (GenEditionContextPropertiesEditionComponent.BASE_PART.equals(part)) - return new GenEditionContextPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof GenEditionContext) { - if (GenEditionContextPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == GenEditionContextPropertiesEditionComponent.class) - return new GenEditionContextPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EEFGenPackage.Literals.GEN_EDITION_CONTEXT == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/GenViewsRepositoryPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/GenViewsRepositoryPropertiesEditionProvider.java deleted file mode 100644 index a7ade1e4f..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/GenViewsRepositoryPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; - -import org.eclipse.emf.eef.EEFGen.components.GenViewsRepositoryPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class GenViewsRepositoryPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public GenViewsRepositoryPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public GenViewsRepositoryPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof GenViewsRepository) - && (EEFGenPackage.Literals.GEN_VIEWS_REPOSITORY == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof GenViewsRepository) && (GenViewsRepositoryPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof GenViewsRepository) && (refinement == GenViewsRepositoryPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof GenViewsRepository) && ((GenViewsRepositoryPropertiesEditionComponent.BASE_PART.equals(part) && refinement == GenViewsRepositoryPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof GenViewsRepository) { - return new GenViewsRepositoryPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof GenViewsRepository) { - if (GenViewsRepositoryPropertiesEditionComponent.BASE_PART.equals(part)) - return new GenViewsRepositoryPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof GenViewsRepository) { - if (GenViewsRepositoryPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == GenViewsRepositoryPropertiesEditionComponent.class) - return new GenViewsRepositoryPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && EEFGenPackage.Literals.GEN_VIEWS_REPOSITORY == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/eEFGenMessages.properties b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/eEFGenMessages.properties deleted file mode 100644 index c75a372b4..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/eEFGenMessages.properties +++ /dev/null @@ -1,72 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -GenEditionContextPropertiesEditionPart_ReferenceGroupLabel=Reference -GenEditionContextPropertiesEditionPart_ParametersGroupLabel=Parameters -GenEditionContextPropertiesEditionPart_ActivationGroupLabel=Activation -GenEditionContextPropertiesEditionPart_ImplementationGroupLabel=Implementation -EEFGenModelReferencePropertiesEditionPart_ReferenceGroupLabel=Reference -EEFGenModelPropertiesEditionPart_ParametersGroupLabel=Parameters -EEFGenModelPropertiesEditionPart_LegalGroupLabel=Legal -GenViewsRepositoryPropertiesEditionPart_ReferenceGroupLabel=Reference -GenViewsRepositoryPropertiesEditionPart_ParametersGroupLabel=Parameters -GenViewsRepositoryPropertiesEditionPart_ActivationGroupLabel=Activation -GenViewsRepositoryPropertiesEditionPart_ImplementationGroupLabel=Implementation -GenEditionContext_ReadOnly=This property is read only -GenEditionContext_Part_Title=Base -EEFGenModelReference_ReadOnly=This property is read only -EEFGenModelReference_Part_Title=Base -EEFGenModel_ReadOnly=This property is read only -EEFGenModel_Part_Title=Base -GenViewsRepository_ReadOnly=This property is read only -GenViewsRepository_Part_Title=Base -GenEditionContextPropertiesEditionPart_PropertiesEditionContextLabel=Properties Edition Context : -GenEditionContextPropertiesEditionPart_BasePackageLabel=Base package : -GenEditionContextPropertiesEditionPart_DescriptorsContributorIDLabel=Descriptors contributorID : -GenEditionContextPropertiesEditionPart_GenericPropertiesViewsDescriptorsLabel=Generic properties views descriptors -GenEditionContextPropertiesEditionPart_GMFSpecificPropertiesViewsLabel=GMF specific properties views -GenEditionContextPropertiesEditionPart_JUnitTestCasesLabel=JUnit test cases -GenEditionContextPropertiesEditionPart_LeafComponentsSuperClassLabel=LeafComponentsSuperClass : -GenEditionContextPropertiesEditionPart_PropertiesEditingProvidersSuperClassLabel=PropertiesEditingProvidersSuperClass : -EEFGenModelReferencePropertiesEditionPart_ReferencedEEFGenModelLabel=Referenced EEFGenModel : -EEFGenModelPropertiesEditionPart_GenerationDirectoryLabel=Generation directory : -EEFGenModelPropertiesEditionPart_TestsGenerationDirectoryLabel=Tests generation directory : -EEFGenModelPropertiesEditionPart_UseJMergeToManageUserCodeLabel=Use JMerge to manage user code -EEFGenModelPropertiesEditionPart_AuthorLabel=Author : -EEFGenModelPropertiesEditionPart_LicenseLabel=License : -GenViewsRepositoryPropertiesEditionPart_ViewsRepositoryLabel=Views repository : -GenViewsRepositoryPropertiesEditionPart_BasePackageLabel=Base package : -GenViewsRepositoryPropertiesEditionPart_HelpStrategyLabel=Help strategy : -GenViewsRepositoryPropertiesEditionPart_SWTViewsLabel=SWT views -GenViewsRepositoryPropertiesEditionPart_FormsViewsLabel=Forms views -GenViewsRepositoryPropertiesEditionPart_PartsSuperClassLabel=PartsSuperClass : -GenViewsRepositoryPropertiesEditionPart_FormsSuperClassLabel=FormsSuperClass : -PropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionPart_EditTableViewerLabel=Edit -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=The property {0} of the object shall be filled -PropertiesEditionPart_RemoveTableViewerLabel=Delete -PropertiesEditionPart_RemoveListViewerLabel=Delete -PropertiesEditionPart_IntegerValueMessage=The property {0} shall be an integer -PropertiesEditionPart_FloatValueMessage=The property {0} shall be a float -PropertiesEditionPart_ShortValueMessage=The property {0} shall be a short -PropertiesEditionPart_DoubleValueMessage=The property {0} shall be a double -PropertiesEditionPart_ByteValueMessage=The property {0} shall be a byte -PropertiesEditionPart_LongValueMessage=The property {0} shall be a long -PropertiesEditionPart_BigIntegerValueMessage=The property {0} shall be a BigInteger -PropertiesEditionPart_BigDecimalValueMessage=The property {0} shall be a BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Add -PropertiesEditionPart_AddListViewerLabel=Add diff --git a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/eEFGenMessages_fr.properties b/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/eEFGenMessages_fr.properties deleted file mode 100644 index 402fd0032..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.edit/src-gen/org/eclipse/emf/eef/EEFGen/providers/eEFGenMessages_fr.properties +++ /dev/null @@ -1,72 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -GenEditionContextPropertiesEditionPart_ReferenceGroupLabel=Reference -GenEditionContextPropertiesEditionPart_ParametersGroupLabel=Parameters -GenEditionContextPropertiesEditionPart_ActivationGroupLabel=Activation -GenEditionContextPropertiesEditionPart_ImplementationGroupLabel=Implementation -EEFGenModelReferencePropertiesEditionPart_ReferenceGroupLabel=Reference -EEFGenModelPropertiesEditionPart_ParametersGroupLabel=Parameters -EEFGenModelPropertiesEditionPart_LegalGroupLabel=Legal -GenViewsRepositoryPropertiesEditionPart_ReferenceGroupLabel=Reference -GenViewsRepositoryPropertiesEditionPart_ParametersGroupLabel=Parameters -GenViewsRepositoryPropertiesEditionPart_ActivationGroupLabel=Activation -GenViewsRepositoryPropertiesEditionPart_ImplementationGroupLabel=Implementation -GenEditionContext_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -GenEditionContext_Part_Title=Base -EEFGenModelReference_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -EEFGenModelReference_Part_Title=Base -EEFGenModel_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -EEFGenModel_Part_Title=Base -GenViewsRepository_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -GenViewsRepository_Part_Title=Base -GenEditionContextPropertiesEditionPart_PropertiesEditionContextLabel=Properties Edition Context : -GenEditionContextPropertiesEditionPart_BasePackageLabel=Base package : -GenEditionContextPropertiesEditionPart_DescriptorsContributorIDLabel=Descriptors contributorID : -GenEditionContextPropertiesEditionPart_GenericPropertiesViewsDescriptorsLabel=Generic properties views descriptors -GenEditionContextPropertiesEditionPart_GMFSpecificPropertiesViewsLabel=GMF specific properties views -GenEditionContextPropertiesEditionPart_JUnitTestCasesLabel=JUnit test cases -GenEditionContextPropertiesEditionPart_LeafComponentsSuperClassLabel=LeafComponentsSuperClass : -GenEditionContextPropertiesEditionPart_PropertiesEditingProvidersSuperClassLabel=PropertiesEditingProvidersSuperClass : -EEFGenModelReferencePropertiesEditionPart_ReferencedEEFGenModelLabel=Referenced EEFGenModel : -EEFGenModelPropertiesEditionPart_GenerationDirectoryLabel=Generation directory : -EEFGenModelPropertiesEditionPart_TestsGenerationDirectoryLabel=Tests generation directory : -EEFGenModelPropertiesEditionPart_UseJMergeToManageUserCodeLabel=Use JMerge to manage user code -EEFGenModelPropertiesEditionPart_AuthorLabel=Author : -EEFGenModelPropertiesEditionPart_LicenseLabel=License : -GenViewsRepositoryPropertiesEditionPart_ViewsRepositoryLabel=Views repository : -GenViewsRepositoryPropertiesEditionPart_BasePackageLabel=Base package : -GenViewsRepositoryPropertiesEditionPart_HelpStrategyLabel=Help strategy : -GenViewsRepositoryPropertiesEditionPart_SWTViewsLabel=SWT views -GenViewsRepositoryPropertiesEditionPart_FormsViewsLabel=Forms views -GenViewsRepositoryPropertiesEditionPart_PartsSuperClassLabel=PartsSuperClass : -GenViewsRepositoryPropertiesEditionPart_FormsSuperClassLabel=FormsSuperClass : -PropertiesEditionPart_PropertiesGroupLabel=Propri\u00E9t\u00E9s -PropertiesEditionPart_EditTableViewerLabel=Editer -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=La propri\u00E9t\u00E9 {0} de l\u0027objet doit \u00EAtre renseign\u00E9e -PropertiesEditionPart_RemoveTableViewerLabel=Supprimer -PropertiesEditionPart_RemoveListViewerLabel=Supprimer -PropertiesEditionPart_IntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un entier -PropertiesEditionPart_FloatValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un flottant -PropertiesEditionPart_ShortValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un short -PropertiesEditionPart_DoubleValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un double -PropertiesEditionPart_ByteValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un byte -PropertiesEditionPart_LongValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un long -PropertiesEditionPart_BigIntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigInteger -PropertiesEditionPart_BigDecimalValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Ajouter -PropertiesEditionPart_AddListViewerLabel=Ajouter diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/.checkstyle b/plugins/org.eclipse.emf.eef.eefgen.editor/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/.classpath b/plugins/org.eclipse.emf.eef.eefgen.editor/.classpath deleted file mode 100644 index f9c46b584..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/.gitignore b/plugins/org.eclipse.emf.eef.eefgen.editor/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/.project b/plugins/org.eclipse.emf.eef.eefgen.editor/.project deleted file mode 100644 index 9800f5945..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.eefgen.editor - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.eefgen.editor/META-INF/MANIFEST.MF deleted file mode 100644 index c6333e001..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/META-INF/MANIFEST.MF +++ /dev/null @@ -1,23 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Generation Editor -Bundle-SymbolicName: org.eclipse.emf.eef.eefgen.editor;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Activator: org.eclipse.emf.eef.EEFGen.presentation.EEFGenEditorPlugin$Implementation -Bundle-Vendor: Eclipse Modeling Project -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.EEFGen.presentation -Require-Bundle: org.eclipse.ui.ide;bundle-version="3.4.0";visibility:=reexport, - org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.core.resources;bundle-version="3.4.0";visibility:=reexport, - org.eclipse.emf.ecore.xmi;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.edit.ui;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.ecore.edit;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.codegen.ecore.ui;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.eef.components.edit;visibility:=reexport, - org.eclipse.emf.eef.eefgen.edit;visibility:=reexport, - org.eclipse.emf.eef.mapping.edit;visibility:=reexport, - org.eclipse.emf.eef.views.edit;visibility:=reexport -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/about.html b/plugins/org.eclipse.emf.eef.eefgen.editor/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/build.properties b/plugins/org.eclipse.emf.eef.eefgen.editor/build.properties deleted file mode 100644 index 1b789c93a..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/build.properties +++ /dev/null @@ -1,21 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -bin.includes = .,\ - icons/,\ - META-INF/,\ - plugin.xml,\ - plugin.properties,\ - about.html -jars.compile.order = . -source.. = src-gen/ -output.. = bin/ -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/icons/full/obj16/EEFGenModelFile.gif b/plugins/org.eclipse.emf.eef.eefgen.editor/icons/full/obj16/EEFGenModelFile.gif deleted file mode 100644 index dd45f08fb1a2d6aa3d5491f88e2dae1c62a63147..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 351 zcmZ?wbhEHb6krfwxXQpFXggIeV%?v=|MgPW{r&e}CUucw#uBxhWqO4x^@>)Sm9Mp{ z*M=vLTQw!M2Qp;G?p$#XUw>N#eL6n-XFj7eCK?ht-XzzxvwMO8sH0HH#<8! zt7~6Z*S^qM6vBenaN}_2?PQHfwAL3jd;#|X@xkVD(BJmzEM30z~`*CI7@fAM1l*1EA0m+p? zDb=B=wc+W{Bhu@l|DZg|YDhpg{f=$<9n+jzL_-$QP$iw2C0!U26T8ccf~sCzZ6B_d zMX2vDZD5z}GC*$T*3pNlog*~XIK6M8mnUS8&hV!e$EFs>MN+~0rD@5kP`o@Z+mJ}t zF5b(!bU)kjUgl-5oXcL>SAEdd5B}W(W9y%1u zrk*#gFUL9u1U;O0FL}a&(V4+9@zA(rWO9CZLc*U~cq@{MB&$>6<(c`9(~^~C`RC#~ z7J>4r^xuJv16A!jO4kUjZ@h>5uJ83U`^^k@Y?d!v9GUzuJTW&uEtM>-ix=ffA3ray zY!1Ac8Jd{m3m4u_O9eAa@8>^?Br8*5nN0q9>Eoxxm5q-ZUsu<^%r9?9mev+mH&@ob zY*M{9rAHUn?E*jpK$nLGz@A>WKe5jxhYC-83NHU%h?qREy(ex1{H-mF`L8!K3p zpza0@;H)o+25I3`&yI*QN!!p>R(142aqu`TlI(}J)hD$nx`6M~0D4J@rU(Q&UG1bz zjblL&pW;G89RgxQ>_~we;u*Yqz>um%;$I-G)8f(CyjmB^v)B+1%6+uQug8we@H${o z$y?@|cX8y~Cr|f0`?UO_={MGn7W#BVz{`@@?ThY~Q~|?6W$8rNMcfCwR(QryHCgzU zXQu=zN;v*$emWL7L=(a58AmwDtyk;@A2;$&DEk!e3CIsKKKytlHb(PYX(afP8D3$? z$xatS5bLBeUL`WAUVI? zmb<5QJ!qvZ`8Zi6I;f5lpit3c@CQUP9FK*>>28G9>tGB}rxN-@WL-c@mE#XvZ)!s5 zAwTO3(j{E+hg@F0%)b+!18g9Uk9P#Mf2XO3M=~#rFkkgT)lC=<(~6GJ{wtmuLWZr}3Qx0XkMy`PBV%+m5R|rt>GZi)PWzst^Q}?ZVZEt}g-JiHg$wQ=?2YD3Q zWGHk;j!kH)r|==+rwMIcR#Sh*qSgB9Tc;EGLOS~4epis`t%F|8oU3}%v7+zKbO-R_ zt@be{NuE5!htL6QGokz7keo}`0z;&g_~Z*qc@`t?XUkf%7pB|>R^!Fj)xZfK8M5JR z+H*C9emwpieRjpL!a=h!e-(bI}J_fLSh%@>0=s-u=%+DwR|CASk#$?gH|+{Ytha*@ z^d8Moan>ULsA_piodmMdq+We;sM_wj!G#k*^y9w$?eteRfon+4v8O8DUmGIRRuIR6 zD{hRLf&8pb03)*I_G3+KjiN@C;v{0=nWwp4J`wOH^}}?*SfNqv*_7TZ-)ZBU*m~z! znA}hs(<~E?z1A$&_NMOOKC!K_0XinlgQR6CD71E1&#!^$8)o`&V0YwqfYR#&e;)xj zH*wOBK_xd}wOlVEwg4?8u^!+YnftlnByFXGaU6hm#eqXZh$?WlTnT(nc4x)(sqrHD zxU)e^`dnt3i3T$(z=T9tfGwC0#dBfnKm^K){d1(bgW-9dY;L0ge=K z2H`rSqM>RyFaDfgnT;e03olJJwN`2y7!C{c^c+*utbs>Ue%LYM_T(T; zi|(% - - - - - - - - - - %_UI_EEFGenModelWizard_description - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/pom.xml b/plugins/org.eclipse.emf.eef.eefgen.editor/pom.xml deleted file mode 100644 index 7f99ba205..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/pom.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.eefgen.editor - eclipse-plugin - - EEF EEFGen Editor Plug-in - diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenActionBarContributor.java b/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenActionBarContributor.java deleted file mode 100644 index 466af5430..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenActionBarContributor.java +++ /dev/null @@ -1,426 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.presentation; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.ui.viewer.IViewerProvider; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; -import org.eclipse.emf.edit.ui.action.ControlAction; -import org.eclipse.emf.edit.ui.action.CreateChildAction; -import org.eclipse.emf.edit.ui.action.CreateSiblingAction; -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; -import org.eclipse.emf.edit.ui.action.LoadResourceAction; -import org.eclipse.emf.edit.ui.action.ValidateAction; -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.ActionContributionItem; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.action.IContributionItem; -import org.eclipse.jface.action.IContributionManager; -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.action.SubContributionItem; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.PartInitException; - -/** - * This is the action bar contributor for the EEFGen model editor. - * - * - * @generated - */ -public class EEFGenActionBarContributor - extends EditingDomainActionBarContributor - implements ISelectionChangedListener { - /** - * This keeps track of the active editor. - * - * - * @generated - */ - protected IEditorPart activeEditorPart; - - /** - * This keeps track of the current selection provider. - * - * - * @generated - */ - protected ISelectionProvider selectionProvider; - - /** - * This action opens the Properties view. - * - * - * @generated - */ - protected IAction showPropertiesViewAction = - new Action(EEFGenEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) { - @Override - public void run() { - try { - getPage().showView("org.eclipse.ui.views.PropertySheet"); - } - catch (PartInitException exception) { - EEFGenEditorPlugin.INSTANCE.log(exception); - } - } - }; - - /** - * This action refreshes the viewer of the current editor if the editor - * implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}. - * - * - * @generated - */ - protected IAction refreshViewerAction = - new Action(EEFGenEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) { - @Override - public boolean isEnabled() { - return activeEditorPart instanceof IViewerProvider; - } - - @Override - public void run() { - if (activeEditorPart instanceof IViewerProvider) { - Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer(); - if (viewer != null) { - viewer.refresh(); - } - } - } - }; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected Collection createChildActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateChild actions. - * - * - * @generated - */ - protected IMenuManager createChildMenuManager; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected Collection createSiblingActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateSibling actions. - * - * - * @generated - */ - protected IMenuManager createSiblingMenuManager; - - /** - * This creates an instance of the contributor. - * - * - * @generated - */ - public EEFGenActionBarContributor() { - super(ADDITIONS_LAST_STYLE); - loadResourceAction = new LoadResourceAction(); - validateAction = new ValidateAction(); - controlAction = new ControlAction(); - } - - /** - * This adds Separators for editor additions to the tool bar. - * - * - * @generated - */ - @Override - public void contributeToToolBar(IToolBarManager toolBarManager) { - toolBarManager.add(new Separator("eefgen-settings")); - toolBarManager.add(new Separator("eefgen-additions")); - } - - /** - * This adds to the menu bar a menu and some separators for editor additions, - * as well as the sub-menus for object creation items. - * - * - * @generated - */ - @Override - public void contributeToMenu(IMenuManager menuManager) { - super.contributeToMenu(menuManager); - - IMenuManager submenuManager = new MenuManager(EEFGenEditorPlugin.INSTANCE.getString("_UI_EEFGenEditor_menu"), "org.eclipse.emf.eef.EEFGenMenuID"); - menuManager.insertAfter("additions", submenuManager); - submenuManager.add(new Separator("settings")); - submenuManager.add(new Separator("actions")); - submenuManager.add(new Separator("additions")); - submenuManager.add(new Separator("additions-end")); - - // Prepare for CreateChild item addition or removal. - // - createChildMenuManager = new MenuManager(EEFGenEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); - submenuManager.insertBefore("additions", createChildMenuManager); - - // Prepare for CreateSibling item addition or removal. - // - createSiblingMenuManager = new MenuManager(EEFGenEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); - submenuManager.insertBefore("additions", createSiblingMenuManager); - - // Force an update because Eclipse hides empty menus now. - // - submenuManager.addMenuListener - (new IMenuListener() { - public void menuAboutToShow(IMenuManager menuManager) { - menuManager.updateAll(true); - } - }); - - addGlobalActions(submenuManager); - } - - /** - * When the active editor changes, this remembers the change and registers with it as a selection provider. - * - * - * @generated - */ - @Override - public void setActiveEditor(IEditorPart part) { - super.setActiveEditor(part); - activeEditorPart = part; - - // Switch to the new selection provider. - // - if (selectionProvider != null) { - selectionProvider.removeSelectionChangedListener(this); - } - if (part == null) { - selectionProvider = null; - } - else { - selectionProvider = part.getSite().getSelectionProvider(); - selectionProvider.addSelectionChangedListener(this); - - // Fake a selection changed event to update the menus. - // - if (selectionProvider.getSelection() != null) { - selectionChanged(new SelectionChangedEvent(selectionProvider, selectionProvider.getSelection())); - } - } - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionChangedListener}, - * handling {@link org.eclipse.jface.viewers.SelectionChangedEvent}s by querying for the children and siblings - * that can be added to the selected object and updating the menus accordingly. - * - * - * @generated - */ - public void selectionChanged(SelectionChangedEvent event) { - // Remove any menu items for old selection. - // - if (createChildMenuManager != null) { - depopulateManager(createChildMenuManager, createChildActions); - } - if (createSiblingMenuManager != null) { - depopulateManager(createSiblingMenuManager, createSiblingActions); - } - - // Query the new selection for appropriate new child/sibling descriptors - // - Collection newChildDescriptors = null; - Collection newSiblingDescriptors = null; - - ISelection selection = event.getSelection(); - if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) { - Object object = ((IStructuredSelection)selection).getFirstElement(); - - EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain(); - - newChildDescriptors = domain.getNewChildDescriptors(object, null); - newSiblingDescriptors = domain.getNewChildDescriptors(null, object); - } - - // Generate actions for selection; populate and redraw the menus. - // - createChildActions = generateCreateChildActions(newChildDescriptors, selection); - createSiblingActions = generateCreateSiblingActions(newSiblingDescriptors, selection); - - if (createChildMenuManager != null) { - populateManager(createChildMenuManager, createChildActions, null); - createChildMenuManager.update(true); - } - if (createSiblingMenuManager != null) { - populateManager(createSiblingMenuManager, createSiblingActions, null); - createSiblingMenuManager.update(true); - } - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateChildAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected Collection generateCreateChildActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateChildAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected Collection generateCreateSiblingActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateSiblingAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This populates the specified manager with {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection, - * by inserting them before the specified contribution item contributionID. - * If contributionID is null, they are simply added. - * - * - * @generated - */ - protected void populateManager(IContributionManager manager, Collection actions, String contributionID) { - if (actions != null) { - for (IAction action : actions) { - if (contributionID != null) { - manager.insertBefore(contributionID, action); - } - else { - manager.add(action); - } - } - } - } - - /** - * This removes from the specified manager all {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection. - * - * - * @generated - */ - protected void depopulateManager(IContributionManager manager, Collection actions) { - if (actions != null) { - IContributionItem[] items = manager.getItems(); - for (int i = 0; i < items.length; i++) { - // Look into SubContributionItems - // - IContributionItem contributionItem = items[i]; - while (contributionItem instanceof SubContributionItem) { - contributionItem = ((SubContributionItem)contributionItem).getInnerItem(); - } - - // Delete the ActionContributionItems with matching action. - // - if (contributionItem instanceof ActionContributionItem) { - IAction action = ((ActionContributionItem)contributionItem).getAction(); - if (actions.contains(action)) { - manager.remove(contributionItem); - } - } - } - } - } - - /** - * This populates the pop-up menu before it appears. - * - * - * @generated - */ - @Override - public void menuAboutToShow(IMenuManager menuManager) { - super.menuAboutToShow(menuManager); - MenuManager submenuManager = null; - - submenuManager = new MenuManager(EEFGenEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); - populateManager(submenuManager, createChildActions, null); - menuManager.insertBefore("edit", submenuManager); - - submenuManager = new MenuManager(EEFGenEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); - populateManager(submenuManager, createSiblingActions, null); - menuManager.insertBefore("edit", submenuManager); - } - - /** - * This inserts global actions before the "additions-end" separator. - * - * - * @generated - */ - @Override - protected void addGlobalActions(IMenuManager menuManager) { - menuManager.insertAfter("additions-end", new Separator("ui-actions")); - menuManager.insertAfter("ui-actions", showPropertiesViewAction); - - refreshViewerAction.setEnabled(refreshViewerAction.isEnabled()); - menuManager.insertAfter("ui-actions", refreshViewerAction); - - super.addGlobalActions(menuManager); - } - - /** - * This ensures that a delete action will clean up all references to deleted objects. - * - * - * @generated - */ - @Override - protected boolean removeAllReferencesOnDelete() { - return true; - } - -} \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenEditor.java b/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenEditor.java deleted file mode 100644 index 5be9b0f12..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenEditor.java +++ /dev/null @@ -1,1540 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.presentation; - - -import java.io.IOException; -import java.io.InputStream; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.EventObject; -import java.util.HashMap; -import java.util.Iterator; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IMarker; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.IResourceChangeEvent; -import org.eclipse.core.resources.IResourceChangeListener; -import org.eclipse.core.resources.IResourceDelta; -import org.eclipse.core.resources.IResourceDeltaVisitor; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelItemProviderAdapterFactory; -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.command.CommandStack; -import org.eclipse.emf.common.command.CommandStackListener; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.ui.MarkerHelper; -import org.eclipse.emf.common.ui.editor.ProblemEditorPart; -import org.eclipse.emf.common.ui.viewer.IViewerProvider; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EValidator; -import org.eclipse.emf.ecore.provider.EcoreItemProviderAdapterFactory; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.EContentAdapter; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; -import org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory; -import org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory; -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; -import org.eclipse.emf.edit.ui.celleditor.AdapterFactoryTreeEditor; -import org.eclipse.emf.edit.ui.dnd.EditingDomainViewerDropAdapter; -import org.eclipse.emf.edit.ui.dnd.LocalTransfer; -import org.eclipse.emf.edit.ui.dnd.ViewerDragAdapter; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.edit.ui.provider.UnwrappingSelectionProvider; -import org.eclipse.emf.edit.ui.util.EditUIMarkerHelper; -import org.eclipse.emf.edit.ui.util.EditUIUtil; -import org.eclipse.emf.eef.EEFGen.provider.EEFGenItemProviderAdapterFactory; -import org.eclipse.emf.eef.components.provider.ComponentsItemProviderAdapterFactory; -import org.eclipse.emf.eef.mapping.navigation.provider.NavigationItemProviderAdapterFactory; -import org.eclipse.emf.eef.mapping.provider.MappingCustomItemProviderAdapterFactory; -import org.eclipse.emf.eef.runtime.ui.notify.OpenWizardOnDoubleClick; -import org.eclipse.emf.eef.toolkits.provider.ToolkitsItemProviderAdapterFactory; -import org.eclipse.emf.eef.views.provider.ViewsItemProviderAdapterFactory; -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IStatusLineManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.dialogs.MessageDialog; -import org.eclipse.jface.dialogs.ProgressMonitorDialog; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.jface.viewers.TreeViewer; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.swt.SWT; -import org.eclipse.swt.custom.CTabFolder; -import org.eclipse.swt.dnd.DND; -import org.eclipse.swt.dnd.Transfer; -import org.eclipse.swt.events.ControlAdapter; -import org.eclipse.swt.events.ControlEvent; -import org.eclipse.swt.graphics.Point; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Menu; -import org.eclipse.swt.widgets.Tree; -import org.eclipse.ui.IActionBars; -import org.eclipse.ui.IEditorInput; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IEditorSite; -import org.eclipse.ui.IPartListener; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.PartInitException; -import org.eclipse.ui.actions.WorkspaceModifyOperation; -import org.eclipse.ui.dialogs.SaveAsDialog; -import org.eclipse.ui.ide.IGotoMarker; -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.MultiPageEditorPart; -import org.eclipse.ui.views.contentoutline.ContentOutline; -import org.eclipse.ui.views.contentoutline.ContentOutlinePage; -import org.eclipse.ui.views.contentoutline.IContentOutlinePage; -import org.eclipse.ui.views.properties.IPropertySheetPage; -import org.eclipse.ui.views.properties.PropertySheet; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; - - -/** - * This is an example of a EEFGen model editor. - * - * - * @generated NOT - */ -public class EEFGenEditor - extends MultiPageEditorPart - implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker, org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor { - /** - * This keeps track of the editing domain that is used to track all changes to the model. - * - * - * @generated - */ - protected AdapterFactoryEditingDomain editingDomain; - - /** - * This is the one adapter factory used for providing views of the model. - * - * - * @generated - */ - protected ComposedAdapterFactory adapterFactory; - - /** - * This is the content outline page. - * - * - * @generated - */ - protected IContentOutlinePage contentOutlinePage; - - /** - * This is a kludge... - * - * - * @generated - */ - protected IStatusLineManager contentOutlineStatusLineManager; - - /** - * This is the content outline page's viewer. - * - * - * @generated - */ - protected TreeViewer contentOutlineViewer; - - /** - * This is the property sheet page. - * - * - * @generated NOT - */ - protected TabbedPropertySheetPage propertySheetPage; - - /** - * This is the viewer that shadows the selection in the content outline. - * The parent relation must be correctly defined for this to work. - * - * - * @generated - */ - protected TreeViewer selectionViewer; - - /** - * @generated NOT - */ - public static final String PROPERTIES_CONTRIBUTOR = "org.eclipse.emf.eef.properties"; - - /** - * This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer. - * - * - * @generated - */ - protected Viewer currentViewer; - - /** - * This listens to which ever viewer is active. - * - * - * @generated - */ - protected ISelectionChangedListener selectionChangedListener; - - /** - * This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor. - * - * - * @generated - */ - protected Collection selectionChangedListeners = new ArrayList(); - - /** - * This keeps track of the selection of the editor as a whole. - * - * - * @generated - */ - protected ISelection editorSelection = StructuredSelection.EMPTY; - - /** - * The MarkerHelper is responsible for creating workspace resource markers presented - * in Eclipse's Problems View. - * - * - * @generated - */ - protected MarkerHelper markerHelper = new EditUIMarkerHelper(); - - /** - * This listens for when the outline becomes active - * - * - * @generated - */ - protected IPartListener partListener = - new IPartListener() { - public void partActivated(IWorkbenchPart p) { - if (p instanceof ContentOutline) { - if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) { - getActionBarContributor().setActiveEditor(EEFGenEditor.this); - - setCurrentViewer(contentOutlineViewer); - } - } - else if (p instanceof PropertySheet) { - if (((PropertySheet)p).getCurrentPage() == propertySheetPage) { - getActionBarContributor().setActiveEditor(EEFGenEditor.this); - handleActivate(); - } - } - else if (p == EEFGenEditor.this) { - handleActivate(); - } - } - public void partBroughtToTop(IWorkbenchPart p) { - // Ignore. - } - public void partClosed(IWorkbenchPart p) { - // Ignore. - } - public void partDeactivated(IWorkbenchPart p) { - // Ignore. - } - public void partOpened(IWorkbenchPart p) { - // Ignore. - } - }; - - /** - * Resources that have been removed since last activation. - * - * - * @generated - */ - protected Collection removedResources = new ArrayList(); - - /** - * Resources that have been changed since last activation. - * - * - * @generated - */ - protected Collection changedResources = new ArrayList(); - - /** - * Resources that have been saved. - * - * - * @generated - */ - protected Collection savedResources = new ArrayList(); - - /** - * Map to store the diagnostic associated with a resource. - * - * - * @generated - */ - protected Map resourceToDiagnosticMap = new LinkedHashMap(); - - /** - * Controls whether the problem indication should be updated. - * - * - * @generated - */ - protected boolean updateProblemIndication = true; - - /** - * Adapter used to update the problem indication when resources are demanded loaded. - * - * - * @generated - */ - protected EContentAdapter problemIndicationAdapter = - new EContentAdapter() { - @Override - public void notifyChanged(Notification notification) { - if (notification.getNotifier() instanceof Resource) { - switch (notification.getFeatureID(Resource.class)) { - case Resource.RESOURCE__IS_LOADED: - case Resource.RESOURCE__ERRORS: - case Resource.RESOURCE__WARNINGS: { - Resource resource = (Resource)notification.getNotifier(); - Diagnostic diagnostic = analyzeResourceProblems(resource, null); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, diagnostic); - } - else { - resourceToDiagnosticMap.remove(resource); - } - - if (updateProblemIndication) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - break; - } - } - } - else { - super.notifyChanged(notification); - } - } - - @Override - protected void setTarget(Resource target) { - basicSetTarget(target); - } - - @Override - protected void unsetTarget(Resource target) { - basicUnsetTarget(target); - } - }; - - /** - * This listens for workspace changes. - * - * - * @generated - */ - protected IResourceChangeListener resourceChangeListener = - new IResourceChangeListener() { - public void resourceChanged(IResourceChangeEvent event) { - IResourceDelta delta = event.getDelta(); - try { - class ResourceDeltaVisitor implements IResourceDeltaVisitor { - protected ResourceSet resourceSet = editingDomain.getResourceSet(); - protected Collection changedResources = new ArrayList(); - protected Collection removedResources = new ArrayList(); - - public boolean visit(IResourceDelta delta) { - if (delta.getResource().getType() == IResource.FILE) { - if (delta.getKind() == IResourceDelta.REMOVED || - delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) { - Resource resource = resourceSet.getResource(URI.createURI(delta.getFullPath().toString()), false); - if (resource != null) { - if (delta.getKind() == IResourceDelta.REMOVED) { - removedResources.add(resource); - } - else if (!savedResources.remove(resource)) { - changedResources.add(resource); - } - } - } - } - - return true; - } - - public Collection getChangedResources() { - return changedResources; - } - - public Collection getRemovedResources() { - return removedResources; - } - } - - ResourceDeltaVisitor visitor = new ResourceDeltaVisitor(); - delta.accept(visitor); - - if (!visitor.getRemovedResources().isEmpty()) { - removedResources.addAll(visitor.getRemovedResources()); - if (!isDirty()) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - getSite().getPage().closeEditor(EEFGenEditor.this, false); - } - }); - } - } - - if (!visitor.getChangedResources().isEmpty()) { - changedResources.addAll(visitor.getChangedResources()); - if (getSite().getPage().getActiveEditor() == EEFGenEditor.this) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - handleActivate(); - } - }); - } - } - } - catch (CoreException exception) { - EEFGenEditorPlugin.INSTANCE.log(exception); - } - } - }; - - /** - * Handles activation of the editor or it's associated views. - * - * - * @generated - */ - protected void handleActivate() { - // Recompute the read only state. - // - if (editingDomain.getResourceToReadOnlyMap() != null) { - editingDomain.getResourceToReadOnlyMap().clear(); - - // Refresh any actions that may become enabled or disabled. - // - setSelection(getSelection()); - } - - if (!removedResources.isEmpty()) { - if (handleDirtyConflict()) { - getSite().getPage().closeEditor(EEFGenEditor.this, false); - } - else { - removedResources.clear(); - changedResources.clear(); - savedResources.clear(); - } - } - else if (!changedResources.isEmpty()) { - changedResources.removeAll(savedResources); - handleChangedResources(); - changedResources.clear(); - savedResources.clear(); - } - } - - /** - * Handles what to do with changed resources on activation. - * - * - * @generated - */ - protected void handleChangedResources() { - if (!changedResources.isEmpty() && (!isDirty() || handleDirtyConflict())) { - if (isDirty()) { - changedResources.addAll(editingDomain.getResourceSet().getResources()); - } - editingDomain.getCommandStack().flush(); - - updateProblemIndication = false; - for (Resource resource : changedResources) { - if (resource.isLoaded()) { - resource.unload(); - try { - resource.load(Collections.EMPTY_MAP); - } - catch (IOException exception) { - if (!resourceToDiagnosticMap.containsKey(resource)) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - } - } - } - - if (AdapterFactoryEditingDomain.isStale(editorSelection)) { - setSelection(StructuredSelection.EMPTY); - } - - updateProblemIndication = true; - updateProblemIndication(); - } - } - - /** - * Updates the problems indication with the information described in the specified diagnostic. - * - * - * @generated - */ - protected void updateProblemIndication() { - if (updateProblemIndication) { - BasicDiagnostic diagnostic = - new BasicDiagnostic - (Diagnostic.OK, - "org.eclipse.emf.eef.eefgen.editor", - 0, - null, - new Object [] { editingDomain.getResourceSet() }); - for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) { - if (childDiagnostic.getSeverity() != Diagnostic.OK) { - diagnostic.add(childDiagnostic); - } - } - - int lastEditorPage = getPageCount() - 1; - if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) { - ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic); - if (diagnostic.getSeverity() != Diagnostic.OK) { - setActivePage(lastEditorPage); - } - } - else if (diagnostic.getSeverity() != Diagnostic.OK) { - ProblemEditorPart problemEditorPart = new ProblemEditorPart(); - problemEditorPart.setDiagnostic(diagnostic); - problemEditorPart.setMarkerHelper(markerHelper); - try { - addPage(++lastEditorPage, problemEditorPart, getEditorInput()); - setPageText(lastEditorPage, problemEditorPart.getPartName()); - setActivePage(lastEditorPage); - showTabs(); - } - catch (PartInitException exception) { - EEFGenEditorPlugin.INSTANCE.log(exception); - } - } - - if (markerHelper.hasMarkers(editingDomain.getResourceSet())) { - markerHelper.deleteMarkers(editingDomain.getResourceSet()); - if (diagnostic.getSeverity() != Diagnostic.OK) { - try { - markerHelper.createMarkers(diagnostic); - } - catch (CoreException exception) { - EEFGenEditorPlugin.INSTANCE.log(exception); - } - } - } - } - } - - /** - * Shows a dialog that asks if conflicting changes should be discarded. - * - * - * @generated - */ - protected boolean handleDirtyConflict() { - return - MessageDialog.openQuestion - (getSite().getShell(), - getString("_UI_FileConflict_label"), - getString("_WARN_FileConflict")); - } - - /** - * This creates a model editor. - * - * - * @generated - */ - public EEFGenEditor() { - super(); - initializeEditingDomain(); - } - - /** - * This sets up the editing domain for the model editor. - * - * - * @generated NOT - */ - protected void initializeEditingDomain() { - // Create an adapter factory that yields item providers. - // - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - - adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EEFGenItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ComponentsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new GenModelItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new MappingCustomItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new NavigationItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ViewsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ToolkitsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory()); - - // Create the command stack that will notify this editor as commands are executed. - // - BasicCommandStack commandStack = new BasicCommandStack(); - - // Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus. - // - commandStack.addCommandStackListener(new CommandStackListener() { - public void commandStackChanged(final EventObject event) { - getContainer().getDisplay().asyncExec(new Runnable() { - public void run() { - firePropertyChange(IEditorPart.PROP_DIRTY); - - // Try to select the affected objects. - // - Command mostRecentCommand = ((CommandStack) event - .getSource()).getMostRecentCommand(); - if (mostRecentCommand != null) { - Collection affectedObjects = mostRecentCommand - .getAffectedObjects(); - if (affectedObjects.size() > 0) { - List selectedList = new ArrayList(); - selectedList.add(affectedObjects.toArray()[0]); - setSelectionToViewer(selectedList); - } - else - setSelectionToViewer(affectedObjects); - } - if (propertySheetPage != null - && !propertySheetPage.getControl().isDisposed()) { - propertySheetPage.refresh(); - } - } - }); - } - }); - - // Create the editing domain with a special command stack. - // - editingDomain = new AdapterFactoryEditingDomain(adapterFactory, commandStack, new HashMap()); - } - - /** - * This is here for the listener to be able to call it. - * - * - * @generated - */ - @Override - protected void firePropertyChange(int action) { - super.firePropertyChange(action); - } - - /** - * This sets the selection into whichever viewer is active. - * - * - * @generated - */ - public void setSelectionToViewer(Collection collection) { - final Collection theSelection = collection; - // Make sure it's okay. - // - if (theSelection != null && !theSelection.isEmpty()) { - // I don't know if this should be run this deferred - // because we might have to give the editor a chance to process the viewer update events - // and hence to update the views first. - // - // - Runnable runnable = - new Runnable() { - public void run() { - // Try to select the items in the current content viewer of the editor. - // - if (currentViewer != null) { - currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true); - } - } - }; - runnable.run(); - } - } - - /** - * This returns the editing domain as required by the {@link IEditingDomainProvider} interface. - * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} - * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}. - * - * - * @generated - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * - * - * @generated - */ - public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider { - /** - * - * - * @generated - */ - public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * - * - * @generated - */ - @Override - public Object [] getElements(Object object) { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ - @Override - public Object [] getChildren(Object object) { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ - @Override - public boolean hasChildren(Object object) { - Object parent = super.getParent(object); - return parent != null; - } - - /** - * - * - * @generated - */ - @Override - public Object getParent(Object object) { - return null; - } - } - - /** - * This makes sure that one content viewer, either for the current page or the outline view, if it has focus, - * is the current one. - * - * - * @generated - */ - public void setCurrentViewer(Viewer viewer) { - // If it is changing... - // - if (currentViewer != viewer) { - if (selectionChangedListener == null) { - // Create the listener on demand. - // - selectionChangedListener = - new ISelectionChangedListener() { - // This just notifies those things that are affected by the section. - // - public void selectionChanged(SelectionChangedEvent selectionChangedEvent) { - setSelection(selectionChangedEvent.getSelection()); - } - }; - } - - // Stop listening to the old one. - // - if (currentViewer != null) { - currentViewer.removeSelectionChangedListener(selectionChangedListener); - } - - // Start listening to the new one. - // - if (viewer != null) { - viewer.addSelectionChangedListener(selectionChangedListener); - } - - // Remember it. - // - currentViewer = viewer; - - // Set the editors selection based on the current viewer's selection. - // - setSelection(currentViewer == null ? StructuredSelection.EMPTY : currentViewer.getSelection()); - } - } - - /** - * This returns the viewer as required by the {@link IViewerProvider} interface. - * - * - * @generated - */ - public Viewer getViewer() { - return currentViewer; - } - - /** - * This creates a context menu for the viewer and adds a listener as well registering the menu for extension. - * - * - * @generated - */ - protected void createContextMenuFor(StructuredViewer viewer) { - MenuManager contextMenu = new MenuManager("#PopUp"); - contextMenu.add(new Separator("additions")); - contextMenu.setRemoveAllWhenShown(true); - contextMenu.addMenuListener(this); - Menu menu= contextMenu.createContextMenu(viewer.getControl()); - viewer.getControl().setMenu(menu); - getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer)); - - int dndOperations = DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK; - Transfer[] transfers = new Transfer[] { LocalTransfer.getInstance() }; - viewer.addDragSupport(dndOperations, transfers, new ViewerDragAdapter(viewer)); - viewer.addDropSupport(dndOperations, transfers, new EditingDomainViewerDropAdapter(editingDomain, viewer)); - } - - /** - * This is the method called to load a resource into the editing domain's resource set based on the editor's input. - * - * - * @generated - */ - public void createModel() { - URI resourceURI = EditUIUtil.getURI(getEditorInput()); - Exception exception = null; - Resource resource = null; - try { - // Load the resource through the editing domain. - // - resource = editingDomain.getResourceSet().getResource(resourceURI, true); - } - catch (Exception e) { - exception = e; - resource = editingDomain.getResourceSet().getResource(resourceURI, false); - } - - Diagnostic diagnostic = analyzeResourceProblems(resource, exception); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter); - } - - /** - * Returns a diagnostic describing the errors and warnings listed in the resource - * and the specified exception (if any). - * - * - * @generated - */ - public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) { - if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) { - BasicDiagnostic basicDiagnostic = - new BasicDiagnostic - (Diagnostic.ERROR, - "org.eclipse.emf.eef.eefgen.editor", - 0, - getString("_UI_CreateModelError_message", resource.getURI()), - new Object [] { exception == null ? (Object)resource : exception }); - basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true)); - return basicDiagnostic; - } - else if (exception != null) { - return - new BasicDiagnostic - (Diagnostic.ERROR, - "org.eclipse.emf.eef.eefgen.editor", - 0, - getString("_UI_CreateModelError_message", resource.getURI()), - new Object[] { exception }); - } - else { - return Diagnostic.OK_INSTANCE; - } - } - - /** - * This is the method used by the framework to install your own controls. - * - * - * @generated - */ - @Override - public void createPages() { - // Creates the model from the editor input - // - createModel(); - - // Only creates the other pages if there is something that can be edited - // - if (!getEditingDomain().getResourceSet().getResources().isEmpty()) { - // Create a page for the selection tree view. - // - Tree tree = new Tree(getContainer(), SWT.MULTI); - selectionViewer = new TreeViewer(tree); - setCurrentViewer(selectionViewer); - - selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - selectionViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - selectionViewer.setInput(editingDomain.getResourceSet()); - selectionViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - selectionViewer.addDoubleClickListener(new OpenWizardOnDoubleClick(editingDomain, adapterFactory)); - - new AdapterFactoryTreeEditor(selectionViewer.getTree(), adapterFactory); - - createContextMenuFor(selectionViewer); - int pageIndex = addPage(tree); - setPageText(pageIndex, getString("_UI_SelectionPage_label")); - - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - setActivePage(0); - } - }); - } - - // Ensures that this editor will only display the page's tab - // area if there are more than one page - // - getContainer().addControlListener - (new ControlAdapter() { - boolean guard = false; - @Override - public void controlResized(ControlEvent event) { - if (!guard) { - guard = true; - hideTabs(); - guard = false; - } - } - }); - - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - - /** - * If there is just one page in the multi-page editor part, - * this hides the single tab at the bottom. - * - * - * @generated - */ - protected void hideTabs() { - if (getPageCount() <= 1) { - setPageText(0, ""); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(1); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y + 6); - } - } - } - - /** - * If there is more than one page in the multi-page editor part, - * this shows the tabs at the bottom. - * - * - * @generated - */ - protected void showTabs() { - if (getPageCount() > 1) { - setPageText(0, getString("_UI_SelectionPage_label")); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y - 6); - } - } - } - - /** - * This is used to track the active viewer. - * - * - * @generated - */ - @Override - protected void pageChange(int pageIndex) { - super.pageChange(pageIndex); - - if (contentOutlinePage != null) { - handleContentOutlineSelection(contentOutlinePage.getSelection()); - } - } - - /** - * This is how the framework determines which interfaces we implement. - * - * - * @generated - */ - @Override - public Object getAdapter(Class key) { - if (key.equals(IContentOutlinePage.class)) { - return showOutlineView() ? getContentOutlinePage() : null; - } - else if (key.equals(IPropertySheetPage.class)) { - return getPropertySheetPage(); - } - else if (key.equals(IGotoMarker.class)) { - return this; - } - else { - return super.getAdapter(key); - } - } - - /** - * This accesses a cached version of the content outliner. - * - * - * @generated - */ - public IContentOutlinePage getContentOutlinePage() { - if (contentOutlinePage == null) { - // The content outline is just a tree. - // - class MyContentOutlinePage extends ContentOutlinePage { - @Override - public void createControl(Composite parent) { - super.createControl(parent); - contentOutlineViewer = getTreeViewer(); - contentOutlineViewer.addSelectionChangedListener(this); - - // Set up the tree viewer. - // - contentOutlineViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - contentOutlineViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - contentOutlineViewer.setInput(editingDomain.getResourceSet()); - - // Make sure our popups work. - // - createContextMenuFor(contentOutlineViewer); - - if (!editingDomain.getResourceSet().getResources().isEmpty()) { - // Select the root object in the view. - // - contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - } - } - - @Override - public void makeContributions(IMenuManager menuManager, IToolBarManager toolBarManager, IStatusLineManager statusLineManager) { - super.makeContributions(menuManager, toolBarManager, statusLineManager); - contentOutlineStatusLineManager = statusLineManager; - } - - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - } - - contentOutlinePage = new MyContentOutlinePage(); - - // Listen to selection so that we can handle it is a special way. - // - contentOutlinePage.addSelectionChangedListener - (new ISelectionChangedListener() { - // This ensures that we handle selections correctly. - // - public void selectionChanged(SelectionChangedEvent event) { - handleContentOutlineSelection(event.getSelection()); - } - }); - } - - return contentOutlinePage; - } - - /** - * This accesses a cached version of the property sheet. - * - * - * @generated NOT - */ - public IPropertySheetPage getPropertySheetPage() { - if (propertySheetPage == null || propertySheetPage.getControl().isDisposed()) { - propertySheetPage = - new TabbedPropertySheetPage(EEFGenEditor.this) { - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - }; - } - - return propertySheetPage; - } - - /** - * This deals with how we want selection in the outliner to affect the other views. - * - * - * @generated - */ - public void handleContentOutlineSelection(ISelection selection) { - if (selectionViewer != null && !selection.isEmpty() && selection instanceof IStructuredSelection) { - Iterator selectedElements = ((IStructuredSelection)selection).iterator(); - if (selectedElements.hasNext()) { - // Get the first selected element. - // - Object selectedElement = selectedElements.next(); - - ArrayList selectionList = new ArrayList(); - selectionList.add(selectedElement); - while (selectedElements.hasNext()) { - selectionList.add(selectedElements.next()); - } - - // Set the selection to the widget. - // - selectionViewer.setSelection(new StructuredSelection(selectionList)); - } - } - } - - /** - * This is for implementing {@link IEditorPart} and simply tests the command stack. - * - * - * @generated - */ - @Override - public boolean isDirty() { - return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded(); - } - - /** - * This is for implementing {@link IEditorPart} and simply saves the model file. - * - * - * @generated - */ - @Override - public void doSave(IProgressMonitor progressMonitor) { - // Save only resources that have actually changed. - // - final Map saveOptions = new HashMap(); - saveOptions.put(Resource.OPTION_SAVE_ONLY_IF_CHANGED, Resource.OPTION_SAVE_ONLY_IF_CHANGED_MEMORY_BUFFER); - - // Do the work within an operation because this is a long running activity that modifies the workbench. - // - WorkspaceModifyOperation operation = - new WorkspaceModifyOperation() { - // This is the method that gets invoked when the operation runs. - // - @Override - public void execute(IProgressMonitor monitor) { - // Save the resources to the file system. - // - boolean first = true; - for (Resource resource : editingDomain.getResourceSet().getResources()) { - if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) { - try { - long timeStamp = resource.getTimeStamp(); - resource.save(saveOptions); - if (resource.getTimeStamp() != timeStamp) { - savedResources.add(resource); - } - } - catch (Exception exception) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - first = false; - } - } - } - }; - - updateProblemIndication = false; - try { - // This runs the options, and shows progress. - // - new ProgressMonitorDialog(getSite().getShell()).run(true, false, operation); - - // Refresh the necessary state. - // - ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone(); - firePropertyChange(IEditorPart.PROP_DIRTY); - } - catch (Exception exception) { - // Something went wrong that shouldn't. - // - EEFGenEditorPlugin.INSTANCE.log(exception); - } - updateProblemIndication = true; - updateProblemIndication(); - } - - /** - * This returns whether something has been persisted to the URI of the specified resource. - * The implementation uses the URI converter from the editor's resource set to try to open an input stream. - * - * - * @generated - */ - protected boolean isPersisted(Resource resource) { - boolean result = false; - try { - InputStream stream = editingDomain.getResourceSet().getURIConverter().createInputStream(resource.getURI()); - if (stream != null) { - result = true; - stream.close(); - } - } - catch (IOException e) { - // Ignore - } - return result; - } - - /** - * This always returns true because it is not currently supported. - * - * - * @generated - */ - @Override - public boolean isSaveAsAllowed() { - return true; - } - - /** - * This also changes the editor's input. - * - * - * @generated - */ - @Override - public void doSaveAs() { - SaveAsDialog saveAsDialog = new SaveAsDialog(getSite().getShell()); - saveAsDialog.open(); - IPath path = saveAsDialog.getResult(); - if (path != null) { - IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path); - if (file != null) { - doSaveAs(URI.createPlatformResourceURI(file.getFullPath().toString(), true), new FileEditorInput(file)); - } - } - } - - /** - * - * - * @generated - */ - protected void doSaveAs(URI uri, IEditorInput editorInput) { - (editingDomain.getResourceSet().getResources().get(0)).setURI(uri); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - IProgressMonitor progressMonitor = - getActionBars().getStatusLineManager() != null ? - getActionBars().getStatusLineManager().getProgressMonitor() : - new NullProgressMonitor(); - doSave(progressMonitor); - } - - /** - * - * - * @generated - */ - public void gotoMarker(IMarker marker) { - try { - if (marker.getType().equals(EValidator.MARKER)) { - String uriAttribute = marker.getAttribute(EValidator.URI_ATTRIBUTE, null); - if (uriAttribute != null) { - URI uri = URI.createURI(uriAttribute); - EObject eObject = editingDomain.getResourceSet().getEObject(uri, true); - if (eObject != null) { - setSelectionToViewer(Collections.singleton(editingDomain.getWrapper(eObject))); - } - } - } - } - catch (CoreException exception) { - EEFGenEditorPlugin.INSTANCE.log(exception); - } - } - - /** - * This is called during startup. - * - * - * @generated - */ - @Override - public void init(IEditorSite site, IEditorInput editorInput) { - setSite(site); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - site.setSelectionProvider(this); - site.getPage().addPartListener(partListener); - ResourcesPlugin.getWorkspace().addResourceChangeListener(resourceChangeListener, IResourceChangeEvent.POST_CHANGE); - } - - /** - * - * - * @generated - */ - @Override - public void setFocus() { - getControl(getActivePage()).setFocus(); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void addSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.add(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void removeSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.remove(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection. - * - * - * @generated - */ - public ISelection getSelection() { - return editorSelection; - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to set this editor's overall selection. - * Calling this result will notify the listeners. - * - * - * @generated - */ - public void setSelection(ISelection selection) { - editorSelection = selection; - - for (ISelectionChangedListener listener : selectionChangedListeners) { - listener.selectionChanged(new SelectionChangedEvent(this, selection)); - } - setStatusLineManager(selection); - } - - /** - * - * - * @generated - */ - public void setStatusLineManager(ISelection selection) { - IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ? - contentOutlineStatusLineManager : getActionBars().getStatusLineManager(); - - if (statusLineManager != null) { - if (selection instanceof IStructuredSelection) { - Collection collection = ((IStructuredSelection)selection).toList(); - switch (collection.size()) { - case 0: { - statusLineManager.setMessage(getString("_UI_NoObjectSelected")); - break; - } - case 1: { - String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next()); - statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text)); - break; - } - default: { - statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size()))); - break; - } - } - } - else { - statusLineManager.setMessage(""); - } - } - } - - /** - * This looks up a string in the plugin's plugin.properties file. - * - * - * @generated - */ - private static String getString(String key) { - return EEFGenEditorPlugin.INSTANCE.getString(key); - } - - /** - * This looks up a string in plugin.properties, making a substitution. - * - * - * @generated - */ - private static String getString(String key, Object s1) { - return EEFGenEditorPlugin.INSTANCE.getString(key, new Object [] { s1 }); - } - - /** - * This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu. - * - * - * @generated - */ - public void menuAboutToShow(IMenuManager menuManager) { - ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager); - } - - /** - * - * - * @generated - */ - public EditingDomainActionBarContributor getActionBarContributor() { - return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor(); - } - - /** - * - * - * @generated - */ - public IActionBars getActionBars() { - return getActionBarContributor().getActionBars(); - } - - /** - * - * - * @generated - */ - public AdapterFactory getAdapterFactory() { - return adapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public void dispose() { - updateProblemIndication = false; - - ResourcesPlugin.getWorkspace().removeResourceChangeListener(resourceChangeListener); - - getSite().getPage().removePartListener(partListener); - - adapterFactory.dispose(); - - if (getActionBarContributor().getActiveEditor() == this) { - getActionBarContributor().setActiveEditor(null); - } - - if (propertySheetPage != null) { - propertySheetPage.dispose(); - } - - if (contentOutlinePage != null) { - contentOutlinePage.dispose(); - } - - super.dispose(); - } - - /** - * Returns whether the outline view should be presented to the user. - * - * - * @generated - */ - protected boolean showOutlineView() { - return false; - } - - /** (non-Javadoc) - * @see org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor#getContributorId() - * @generated NOT - */ - public String getContributorId() { - return PROPERTIES_CONTRIBUTOR; - } -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenEditorPlugin.java b/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenEditorPlugin.java deleted file mode 100644 index be29792dc..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenEditorPlugin.java +++ /dev/null @@ -1,107 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.presentation; - -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelEditPlugin; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.ui.EclipseUIPlugin; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.provider.EcoreEditPlugin; -import org.eclipse.emf.eef.components.provider.ComponentsEditPlugin; -import org.eclipse.emf.eef.mapping.provider.MappingEditPlugin; -import org.eclipse.emf.eef.views.provider.ViewsEditPlugin; - -/** - * This is the central singleton for the EEFGen editor plugin. - * - * - * @generated - */ -public final class EEFGenEditorPlugin extends EMFPlugin { - /** - * Keep track of the singleton. - * - * - * @generated - */ - public static final EEFGenEditorPlugin INSTANCE = new EEFGenEditorPlugin(); - - /** - * Keep track of the singleton. - * - * - * @generated - */ - private static Implementation plugin; - - /** - * Create the instance. - * - * - * @generated - */ - public EEFGenEditorPlugin() { - super - (new ResourceLocator [] { - ComponentsEditPlugin.INSTANCE, - EcoreEditPlugin.INSTANCE, - GenModelEditPlugin.INSTANCE, - MappingEditPlugin.INSTANCE, - ViewsEditPlugin.INSTANCE, - }); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - @Override - public ResourceLocator getPluginResourceLocator() { - return plugin; - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * - * @generated - */ - public static class Implementation extends EclipseUIPlugin { - /** - * Creates an instance. - * - * - * @generated - */ - public Implementation() { - super(); - - // Remember the static instance. - // - plugin = this; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenModelWizard.java b/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenModelWizard.java deleted file mode 100644 index a7381744e..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen.editor/src-gen/org/eclipse/emf/eef/EEFGen/presentation/EEFGenModelWizard.java +++ /dev/null @@ -1,610 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.presentation; - - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.MissingResourceException; -import java.util.StringTokenizer; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.CommonPlugin; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.ecore.xmi.XMLResource; -import org.eclipse.emf.edit.ui.provider.ExtendedImageRegistry; -import org.eclipse.emf.eef.EEFGen.EEFGenFactory; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.provider.EEFGenEditPlugin; -import org.eclipse.jface.dialogs.MessageDialog; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.wizard.Wizard; -import org.eclipse.jface.wizard.WizardPage; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.ModifyEvent; -import org.eclipse.swt.events.ModifyListener; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Combo; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; -import org.eclipse.ui.INewWizard; -import org.eclipse.ui.IWorkbench; -import org.eclipse.ui.IWorkbenchPage; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.IWorkbenchWindow; -import org.eclipse.ui.PartInitException; -import org.eclipse.ui.actions.WorkspaceModifyOperation; -import org.eclipse.ui.dialogs.WizardNewFileCreationPage; -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.ISetSelectionTarget; - - -/** - * This is a simple wizard for creating a new model file. - * - * - * @generated - */ -public class EEFGenModelWizard extends Wizard implements INewWizard { - /** - * The supported extensions for created files. - * - * - * @generated - */ - public static final List FILE_EXTENSIONS = - Collections.unmodifiableList(Arrays.asList(EEFGenEditorPlugin.INSTANCE.getString("_UI_EEFGenEditorFilenameExtensions").split("\\s*,\\s*"))); - - /** - * A formatted list of supported file extensions, suitable for display. - * - * - * @generated - */ - public static final String FORMATTED_FILE_EXTENSIONS = - EEFGenEditorPlugin.INSTANCE.getString("_UI_EEFGenEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", "); - - /** - * This caches an instance of the model package. - * - * - * @generated - */ - protected EEFGenPackage eefGenPackage = EEFGenPackage.eINSTANCE; - - /** - * This caches an instance of the model factory. - * - * - * @generated - */ - protected EEFGenFactory eefGenFactory = eefGenPackage.getEEFGenFactory(); - - /** - * This is the file creation page. - * - * - * @generated - */ - protected EEFGenModelWizardNewFileCreationPage newFileCreationPage; - - /** - * This is the initial object creation page. - * - * - * @generated - */ - protected EEFGenModelWizardInitialObjectCreationPage initialObjectCreationPage; - - /** - * Remember the selection during initialization for populating the default container. - * - * - * @generated - */ - protected IStructuredSelection selection; - - /** - * Remember the workbench during initialization. - * - * - * @generated - */ - protected IWorkbench workbench; - - /** - * Caches the names of the types that can be created as the root object. - * - * - * @generated - */ - protected List initialObjectNames; - - /** - * This just records the information. - * - * - * @generated - */ - public void init(IWorkbench workbench, IStructuredSelection selection) { - this.workbench = workbench; - this.selection = selection; - setWindowTitle(EEFGenEditorPlugin.INSTANCE.getString("_UI_Wizard_label")); - setDefaultPageImageDescriptor(ExtendedImageRegistry.INSTANCE.getImageDescriptor(EEFGenEditorPlugin.INSTANCE.getImage("full/wizban/NewEEFGen"))); - } - - /** - * Returns the names of the types that can be created as the root object. - * - * - * @generated - */ - protected Collection getInitialObjectNames() { - if (initialObjectNames == null) { - initialObjectNames = new ArrayList(); - for (EClassifier eClassifier : eefGenPackage.getEClassifiers()) { - if (eClassifier instanceof EClass) { - EClass eClass = (EClass)eClassifier; - if (!eClass.isAbstract()) { - initialObjectNames.add(eClass.getName()); - } - } - } - Collections.sort(initialObjectNames, CommonPlugin.INSTANCE.getComparator()); - } - return initialObjectNames; - } - - /** - * Create a new model. - * - * - * @generated - */ - protected EObject createInitialModel() { - EClass eClass = (EClass)eefGenPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName()); - EObject rootObject = eefGenFactory.create(eClass); - return rootObject; - } - - /** - * Do the work after everything is specified. - * - * - * @generated - */ - @Override - public boolean performFinish() { - try { - // Remember the file. - // - final IFile modelFile = getModelFile(); - - // Do the work within an operation. - // - WorkspaceModifyOperation operation = - new WorkspaceModifyOperation() { - @Override - protected void execute(IProgressMonitor progressMonitor) { - try { - // Create a resource set - // - ResourceSet resourceSet = new ResourceSetImpl(); - - // Get the URI of the model file. - // - URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true); - - // Create a resource for this file. - // - Resource resource = resourceSet.createResource(fileURI); - - // Add the initial model object to the contents. - // - EObject rootObject = createInitialModel(); - if (rootObject != null) { - resource.getContents().add(rootObject); - } - - // Save the contents of the resource to the file system. - // - Map options = new HashMap(); - options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding()); - resource.save(options); - } - catch (Exception exception) { - EEFGenEditorPlugin.INSTANCE.log(exception); - } - finally { - progressMonitor.done(); - } - } - }; - - getContainer().run(false, false, operation); - - // Select the new file resource in the current view. - // - IWorkbenchWindow workbenchWindow = workbench.getActiveWorkbenchWindow(); - IWorkbenchPage page = workbenchWindow.getActivePage(); - final IWorkbenchPart activePart = page.getActivePart(); - if (activePart instanceof ISetSelectionTarget) { - final ISelection targetSelection = new StructuredSelection(modelFile); - getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - ((ISetSelectionTarget)activePart).selectReveal(targetSelection); - } - }); - } - - // Open an editor on the new file. - // - try { - page.openEditor - (new FileEditorInput(modelFile), - workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId()); - } - catch (PartInitException exception) { - MessageDialog.openError(workbenchWindow.getShell(), EEFGenEditorPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage()); - return false; - } - - return true; - } - catch (Exception exception) { - EEFGenEditorPlugin.INSTANCE.log(exception); - return false; - } - } - - /** - * This is the one page of the wizard. - * - * - * @generated - */ - public class EEFGenModelWizardNewFileCreationPage extends WizardNewFileCreationPage { - /** - * Pass in the selection. - * - * - * @generated - */ - public EEFGenModelWizardNewFileCreationPage(String pageId, IStructuredSelection selection) { - super(pageId, selection); - } - - /** - * The framework calls this to see if the file is correct. - * - * - * @generated - */ - @Override - protected boolean validatePage() { - if (super.validatePage()) { - String extension = new Path(getFileName()).getFileExtension(); - if (extension == null || !FILE_EXTENSIONS.contains(extension)) { - String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension"; - setErrorMessage(EEFGenEditorPlugin.INSTANCE.getString(key, new Object [] { FORMATTED_FILE_EXTENSIONS })); - return false; - } - return true; - } - return false; - } - - /** - * - * - * @generated - */ - public IFile getModelFile() { - return ResourcesPlugin.getWorkspace().getRoot().getFile(getContainerFullPath().append(getFileName())); - } - } - - /** - * This is the page where the type of object to create is selected. - * - * - * @generated - */ - public class EEFGenModelWizardInitialObjectCreationPage extends WizardPage { - /** - * - * - * @generated - */ - protected Combo initialObjectField; - - /** - * @generated - * - * - */ - protected List encodings; - - /** - * - * - * @generated - */ - protected Combo encodingField; - - /** - * Pass in the selection. - * - * - * @generated - */ - public EEFGenModelWizardInitialObjectCreationPage(String pageId) { - super(pageId); - } - - /** - * - * - * @generated - */ - public void createControl(Composite parent) { - Composite composite = new Composite(parent, SWT.NONE); { - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - layout.verticalSpacing = 12; - composite.setLayout(layout); - - GridData data = new GridData(); - data.verticalAlignment = GridData.FILL; - data.grabExcessVerticalSpace = true; - data.horizontalAlignment = GridData.FILL; - composite.setLayoutData(data); - } - - Label containerLabel = new Label(composite, SWT.LEFT); - { - containerLabel.setText(EEFGenEditorPlugin.INSTANCE.getString("_UI_ModelObject")); - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - containerLabel.setLayoutData(data); - } - - initialObjectField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - initialObjectField.setLayoutData(data); - } - - for (String objectName : getInitialObjectNames()) { - initialObjectField.add(getLabel(objectName)); - } - - if (initialObjectField.getItemCount() == 1) { - initialObjectField.select(0); - } - initialObjectField.addModifyListener(validator); - - Label encodingLabel = new Label(composite, SWT.LEFT); - { - encodingLabel.setText(EEFGenEditorPlugin.INSTANCE.getString("_UI_XMLEncoding")); - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - encodingLabel.setLayoutData(data); - } - encodingField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - encodingField.setLayoutData(data); - } - - for (String encoding : getEncodings()) { - encodingField.add(encoding); - } - - encodingField.select(0); - encodingField.addModifyListener(validator); - - setPageComplete(validatePage()); - setControl(composite); - } - - /** - * - * - * @generated - */ - protected ModifyListener validator = - new ModifyListener() { - public void modifyText(ModifyEvent e) { - setPageComplete(validatePage()); - } - }; - - /** - * - * - * @generated - */ - protected boolean validatePage() { - return getInitialObjectName() != null && getEncodings().contains(encodingField.getText()); - } - - /** - * - * - * @generated - */ - @Override - public void setVisible(boolean visible) { - super.setVisible(visible); - if (visible) { - if (initialObjectField.getItemCount() == 1) { - initialObjectField.clearSelection(); - encodingField.setFocus(); - } - else { - encodingField.clearSelection(); - initialObjectField.setFocus(); - } - } - } - - /** - * - * - * @generated - */ - public String getInitialObjectName() { - String label = initialObjectField.getText(); - - for (String name : getInitialObjectNames()) { - if (getLabel(name).equals(label)) { - return name; - } - } - return null; - } - - /** - * - * - * @generated - */ - public String getEncoding() { - return encodingField.getText(); - } - - /** - * Returns the label for the specified type name. - * - * - * @generated - */ - protected String getLabel(String typeName) { - try { - return EEFGenEditPlugin.INSTANCE.getString("_UI_" + typeName + "_type"); - } - catch(MissingResourceException mre) { - EEFGenEditorPlugin.INSTANCE.log(mre); - } - return typeName; - } - - /** - * - * - * @generated - */ - protected Collection getEncodings() { - if (encodings == null) { - encodings = new ArrayList(); - for (StringTokenizer stringTokenizer = new StringTokenizer(EEFGenEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens(); ) { - encodings.add(stringTokenizer.nextToken()); - } - } - return encodings; - } - } - - /** - * The framework calls this to create the contents of the wizard. - * - * - * @generated - */ - @Override - public void addPages() { - // Create a page, set the title, and the initial model file name. - // - newFileCreationPage = new EEFGenModelWizardNewFileCreationPage("Whatever", selection); - newFileCreationPage.setTitle(EEFGenEditorPlugin.INSTANCE.getString("_UI_EEFGenModelWizard_label")); - newFileCreationPage.setDescription(EEFGenEditorPlugin.INSTANCE.getString("_UI_EEFGenModelWizard_description")); - newFileCreationPage.setFileName(EEFGenEditorPlugin.INSTANCE.getString("_UI_EEFGenEditorFilenameDefaultBase") + "." + FILE_EXTENSIONS.get(0)); - addPage(newFileCreationPage); - - // Try and get the resource selection to determine a current directory for the file dialog. - // - if (selection != null && !selection.isEmpty()) { - // Get the resource... - // - Object selectedElement = selection.iterator().next(); - if (selectedElement instanceof IResource) { - // Get the resource parent, if its a file. - // - IResource selectedResource = (IResource)selectedElement; - if (selectedResource.getType() == IResource.FILE) { - selectedResource = selectedResource.getParent(); - } - - // This gives us a directory... - // - if (selectedResource instanceof IFolder || selectedResource instanceof IProject) { - // Set this for the container. - // - newFileCreationPage.setContainerFullPath(selectedResource.getFullPath()); - - // Make up a unique new name here. - // - String defaultModelBaseFilename = EEFGenEditorPlugin.INSTANCE.getString("_UI_EEFGenEditorFilenameDefaultBase"); - String defaultModelFilenameExtension = FILE_EXTENSIONS.get(0); - String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension; - for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) { - modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension; - } - newFileCreationPage.setFileName(modelFilename); - } - } - } - initialObjectCreationPage = new EEFGenModelWizardInitialObjectCreationPage("Whatever2"); - initialObjectCreationPage.setTitle(EEFGenEditorPlugin.INSTANCE.getString("_UI_EEFGenModelWizard_label")); - initialObjectCreationPage.setDescription(EEFGenEditorPlugin.INSTANCE.getString("_UI_Wizard_initial_object_description")); - addPage(initialObjectCreationPage); - } - - /** - * Get the file from the page. - * - * - * @generated - */ - public IFile getModelFile() { - return newFileCreationPage.getModelFile(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.eefgen/.checkstyle b/plugins/org.eclipse.emf.eef.eefgen/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen/.classpath b/plugins/org.eclipse.emf.eef.eefgen/.classpath deleted file mode 100644 index f9c46b584..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen/.gitignore b/plugins/org.eclipse.emf.eef.eefgen/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.eefgen/.project b/plugins/org.eclipse.emf.eef.eefgen/.project deleted file mode 100644 index b217f94aa..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.eefgen - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.eefgen/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.eefgen/META-INF/MANIFEST.MF deleted file mode 100644 index 3775e08a7..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/META-INF/MANIFEST.MF +++ /dev/null @@ -1,18 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEFGen Model -Bundle-SymbolicName: org.eclipse.emf.eef.eefgen;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Vendor: Eclipse Modeling Project -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.EEFGen, - org.eclipse.emf.eef.EEFGen.impl, - org.eclipse.emf.eef.EEFGen.util -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.emf.codegen.ecore;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.ecore;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.eef.components;visibility:=reexport, - org.eclipse.emf.eef.mapping;visibility:=reexport, - org.eclipse.emf.eef.views;visibility:=reexport -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.eefgen/about.html b/plugins/org.eclipse.emf.eef.eefgen/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.eefgen/build.properties b/plugins/org.eclipse.emf.eef.eefgen/build.properties deleted file mode 100644 index 14e4c2cba..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -bin.includes = .,\ - model/,\ - META-INF/,\ - plugin.xml,\ - about.html -jars.compile.order = . -source.. = src-gen/ -output.. = bin/ -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.eefgen/model/EEFGen.ecore b/plugins/org.eclipse.emf.eef.eefgen/model/EEFGen.ecore deleted file mode 100644 index 0f383a740..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/model/EEFGen.ecore +++ /dev/null @@ -1,60 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen/model/EEFGen.genmodel b/plugins/org.eclipse.emf.eef.eefgen/model/EEFGen.genmodel deleted file mode 100644 index 26b272161..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/model/EEFGen.genmodel +++ /dev/null @@ -1,58 +0,0 @@ - - - EEFGen.ecore - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen/plugin.xml b/plugins/org.eclipse.emf.eef.eefgen/plugin.xml deleted file mode 100644 index 2a7ea3a00..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/plugin.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.eefgen/pom.xml b/plugins/org.eclipse.emf.eef.eefgen/pom.xml deleted file mode 100644 index 92b28081b..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/pom.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.eefgen - eclipse-plugin - - EEF EEFGEn Model Plug-in - diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenFactory.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenFactory.java deleted file mode 100644 index 5bd68d509..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenFactory.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage - * @generated - */ -public interface EEFGenFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - EEFGenFactory eINSTANCE = org.eclipse.emf.eef.EEFGen.impl.EEFGenFactoryImpl.init(); - - /** - * Returns a new object of class 'Gen Edition Context'. - * - * - * @return a new object of class 'Gen Edition Context'. - * @generated - */ - GenEditionContext createGenEditionContext(); - - /** - * Returns a new object of class 'Model Reference'. - * - * - * @return a new object of class 'Model Reference'. - * @generated - */ - EEFGenModelReference createEEFGenModelReference(); - - /** - * Returns a new object of class 'Model'. - * - * - * @return a new object of class 'Model'. - * @generated - */ - EEFGenModel createEEFGenModel(); - - /** - * Returns a new object of class 'Gen Views Repository'. - * - * - * @return a new object of class 'Gen Views Repository'. - * @generated - */ - GenViewsRepository createGenViewsRepository(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - EEFGenPackage getEEFGenPackage(); - -} //EEFGenFactory diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenModel.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenModel.java deleted file mode 100644 index 7c44b831d..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenModel.java +++ /dev/null @@ -1,223 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Model'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getEditionContexts Edition Contexts}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getViewsRepositories Views Repositories}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getGenDirectory Gen Directory}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getAuthor Author}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getLicense License}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getReferences References}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getTestsGenDirectory Tests Gen Directory}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.EEFGenModel#isUseJMergeForUserCode Use JMerge For User Code}
  • - *
- *

- * - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModel() - * @model - * @generated - */ -public interface EEFGenModel extends EObject { - /** - * Returns the value of the 'Edition Contexts' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.EEFGen.GenEditionContext}. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getEefGenModel Eef Gen Model}'. - * - *

- * If the meaning of the 'Edition Contexts' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Edition Contexts' containment reference list. - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModel_EditionContexts() - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext#getEefGenModel - * @model opposite="eefGenModel" containment="true" - * @generated - */ - EList getEditionContexts(); - - /** - * Returns the value of the 'Views Repositories' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository}. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getEefGenModel Eef Gen Model}'. - * - *

- * If the meaning of the 'Views Repositories' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Views Repositories' containment reference list. - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModel_ViewsRepositories() - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository#getEefGenModel - * @model opposite="eefGenModel" containment="true" - * @generated - */ - EList getViewsRepositories(); - - /** - * Returns the value of the 'Gen Directory' attribute. - * - *

- * If the meaning of the 'Gen Directory' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Gen Directory' attribute. - * @see #setGenDirectory(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModel_GenDirectory() - * @model required="true" - * @generated - */ - String getGenDirectory(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getGenDirectory Gen Directory}' attribute. - * - * - * @param value the new value of the 'Gen Directory' attribute. - * @see #getGenDirectory() - * @generated - */ - void setGenDirectory(String value); - - /** - * Returns the value of the 'Author' attribute. - * - *

- * If the meaning of the 'Author' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Author' attribute. - * @see #setAuthor(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModel_Author() - * @model - * @generated - */ - String getAuthor(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getAuthor Author}' attribute. - * - * - * @param value the new value of the 'Author' attribute. - * @see #getAuthor() - * @generated - */ - void setAuthor(String value); - - /** - * Returns the value of the 'License' attribute. - * - *

- * If the meaning of the 'License' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'License' attribute. - * @see #setLicense(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModel_License() - * @model - * @generated - */ - String getLicense(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getLicense License}' attribute. - * - * - * @param value the new value of the 'License' attribute. - * @see #getLicense() - * @generated - */ - void setLicense(String value); - - /** - * Returns the value of the 'References' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.EEFGen.EEFGenModelReference}. - * - *

- * If the meaning of the 'References' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'References' containment reference list. - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModel_References() - * @model containment="true" - * @generated - */ - EList getReferences(); - - /** - * Returns the value of the 'Tests Gen Directory' attribute. - * - *

- * If the meaning of the 'Tests Gen Directory' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Tests Gen Directory' attribute. - * @see #setTestsGenDirectory(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModel_TestsGenDirectory() - * @model - * @generated - */ - String getTestsGenDirectory(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getTestsGenDirectory Tests Gen Directory}' attribute. - * - * - * @param value the new value of the 'Tests Gen Directory' attribute. - * @see #getTestsGenDirectory() - * @generated - */ - void setTestsGenDirectory(String value); - - /** - * Returns the value of the 'Use JMerge For User Code' attribute. - * The default value is "false". - * - *

- * If the meaning of the 'Use JMerge For User Code' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Use JMerge For User Code' attribute. - * @see #setUseJMergeForUserCode(boolean) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModel_UseJMergeForUserCode() - * @model default="false" - * @generated - */ - boolean isUseJMergeForUserCode(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#isUseJMergeForUserCode Use JMerge For User Code}' attribute. - * - * - * @param value the new value of the 'Use JMerge For User Code' attribute. - * @see #isUseJMergeForUserCode() - * @generated - */ - void setUseJMergeForUserCode(boolean value); - -} // EEFGenModel diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenModelReference.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenModelReference.java deleted file mode 100644 index 5a08fead7..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenModelReference.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Model Reference'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.EEFGen.EEFGenModelReference#getReferencedContext Referenced Context}
  • - *
- *

- * - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModelReference() - * @model - * @generated - */ -public interface EEFGenModelReference extends EObject { - /** - * Returns the value of the 'Referenced Context' reference. - * - *

- * If the meaning of the 'Referenced Context' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Referenced Context' reference. - * @see #setReferencedContext(EEFGenModel) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getEEFGenModelReference_ReferencedContext() - * @model required="true" - * @generated - */ - EEFGenModel getReferencedContext(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.EEFGenModelReference#getReferencedContext Referenced Context}' reference. - * - * - * @param value the new value of the 'Referenced Context' reference. - * @see #getReferencedContext() - * @generated - */ - void setReferencedContext(EEFGenModel value); - -} // EEFGenModelReference diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenPackage.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenPackage.java deleted file mode 100644 index 2ea8b7afc..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/EEFGenPackage.java +++ /dev/null @@ -1,1006 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EEnum; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.EEFGen.EEFGenFactory - * @model kind="package" - * @generated - */ -public interface EEFGenPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "EEFGen"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/generation/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-gen"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - EEFGenPackage eINSTANCE = org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl.init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl Gen Edition Context}' class. - * - * - * @see org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl#getGenEditionContext() - * @generated - */ - int GEN_EDITION_CONTEXT = 0; - - /** - * The feature id for the 'Properties Edition Context' reference. - * - * - * @generated - * @ordered - */ - int GEN_EDITION_CONTEXT__PROPERTIES_EDITION_CONTEXT = 0; - - /** - * The feature id for the 'Base Package' attribute. - * - * - * @generated - * @ordered - */ - int GEN_EDITION_CONTEXT__BASE_PACKAGE = 1; - - /** - * The feature id for the 'Eef Gen Model' container reference. - * - * - * @generated - * @ordered - */ - int GEN_EDITION_CONTEXT__EEF_GEN_MODEL = 2; - - /** - * The feature id for the 'Descriptors Contributor ID' attribute. - * - * - * @generated - * @ordered - */ - int GEN_EDITION_CONTEXT__DESCRIPTORS_CONTRIBUTOR_ID = 3; - - /** - * The feature id for the 'Descriptors Generic Properties Views' attribute. - * - * - * @generated - * @ordered - */ - int GEN_EDITION_CONTEXT__DESCRIPTORS_GENERIC_PROPERTIES_VIEWS = 4; - - /** - * The feature id for the 'Gmf Properties Views' attribute. - * - * - * @generated - * @ordered - */ - int GEN_EDITION_CONTEXT__GMF_PROPERTIES_VIEWS = 5; - - /** - * The feature id for the 'Generate Junit Test Cases' attribute. - * - * - * @generated - * @ordered - */ - int GEN_EDITION_CONTEXT__GENERATE_JUNIT_TEST_CASES = 6; - - /** - * The feature id for the 'Leaf Components Super Class' attribute. - * - * - * @generated - * @ordered - */ - int GEN_EDITION_CONTEXT__LEAF_COMPONENTS_SUPER_CLASS = 7; - - /** - * The feature id for the 'Properties Editing Providers Super Class' attribute. - * - * - * @generated - * @ordered - */ - int GEN_EDITION_CONTEXT__PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS = 8; - - /** - * The number of structural features of the 'Gen Edition Context' class. - * - * - * @generated - * @ordered - */ - int GEN_EDITION_CONTEXT_FEATURE_COUNT = 9; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelReferenceImpl Model Reference}' class. - * - * - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenModelReferenceImpl - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl#getEEFGenModelReference() - * @generated - */ - int EEF_GEN_MODEL_REFERENCE = 1; - - /** - * The feature id for the 'Referenced Context' reference. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL_REFERENCE__REFERENCED_CONTEXT = 0; - - /** - * The number of structural features of the 'Model Reference' class. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL_REFERENCE_FEATURE_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl Model}' class. - * - * - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl#getEEFGenModel() - * @generated - */ - int EEF_GEN_MODEL = 2; - - /** - * The feature id for the 'Edition Contexts' containment reference list. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL__EDITION_CONTEXTS = 0; - - /** - * The feature id for the 'Views Repositories' containment reference list. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL__VIEWS_REPOSITORIES = 1; - - /** - * The feature id for the 'Gen Directory' attribute. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL__GEN_DIRECTORY = 2; - - /** - * The feature id for the 'Author' attribute. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL__AUTHOR = 3; - - /** - * The feature id for the 'License' attribute. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL__LICENSE = 4; - - /** - * The feature id for the 'References' containment reference list. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL__REFERENCES = 5; - - /** - * The feature id for the 'Tests Gen Directory' attribute. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL__TESTS_GEN_DIRECTORY = 6; - - /** - * The feature id for the 'Use JMerge For User Code' attribute. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL__USE_JMERGE_FOR_USER_CODE = 7; - - /** - * The number of structural features of the 'Model' class. - * - * - * @generated - * @ordered - */ - int EEF_GEN_MODEL_FEATURE_COUNT = 8; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl Gen Views Repository}' class. - * - * - * @see org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl#getGenViewsRepository() - * @generated - */ - int GEN_VIEWS_REPOSITORY = 3; - - /** - * The feature id for the 'Views Repository' reference. - * - * - * @generated - * @ordered - */ - int GEN_VIEWS_REPOSITORY__VIEWS_REPOSITORY = 0; - - /** - * The feature id for the 'Base Package' attribute. - * - * - * @generated - * @ordered - */ - int GEN_VIEWS_REPOSITORY__BASE_PACKAGE = 1; - - /** - * The feature id for the 'Swt Views' attribute. - * - * - * @generated - * @ordered - */ - int GEN_VIEWS_REPOSITORY__SWT_VIEWS = 2; - - /** - * The feature id for the 'Form Views' attribute. - * - * - * @generated - * @ordered - */ - int GEN_VIEWS_REPOSITORY__FORM_VIEWS = 3; - - /** - * The feature id for the 'Help Strategy' attribute. - * - * - * @generated - * @ordered - */ - int GEN_VIEWS_REPOSITORY__HELP_STRATEGY = 4; - - /** - * The feature id for the 'Eef Gen Model' container reference. - * - * - * @generated - * @ordered - */ - int GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL = 5; - - /** - * The feature id for the 'Parts Super Class' attribute. - * - * - * @generated - * @ordered - */ - int GEN_VIEWS_REPOSITORY__PARTS_SUPER_CLASS = 6; - - /** - * The feature id for the 'Forms Super Class' attribute. - * - * - * @generated - * @ordered - */ - int GEN_VIEWS_REPOSITORY__FORMS_SUPER_CLASS = 7; - - /** - * The number of structural features of the 'Gen Views Repository' class. - * - * - * @generated - * @ordered - */ - int GEN_VIEWS_REPOSITORY_FEATURE_COUNT = 8; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.EEFGen.HELP_STRATEGY HELP STRATEGY}' enum. - * - * - * @see org.eclipse.emf.eef.EEFGen.HELP_STRATEGY - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl#getHELP_STRATEGY() - * @generated - */ - int HELP_STRATEGY = 4; - - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext Gen Edition Context}'. - * - * - * @return the meta object for class 'Gen Edition Context'. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext - * @generated - */ - EClass getGenEditionContext(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getPropertiesEditionContext Properties Edition Context}'. - * - * - * @return the meta object for the reference 'Properties Edition Context'. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext#getPropertiesEditionContext() - * @see #getGenEditionContext() - * @generated - */ - EReference getGenEditionContext_PropertiesEditionContext(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getBasePackage Base Package}'. - * - * - * @return the meta object for the attribute 'Base Package'. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext#getBasePackage() - * @see #getGenEditionContext() - * @generated - */ - EAttribute getGenEditionContext_BasePackage(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getEefGenModel Eef Gen Model}'. - * - * - * @return the meta object for the container reference 'Eef Gen Model'. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext#getEefGenModel() - * @see #getGenEditionContext() - * @generated - */ - EReference getGenEditionContext_EefGenModel(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getDescriptorsContributorID Descriptors Contributor ID}'. - * - * - * @return the meta object for the attribute 'Descriptors Contributor ID'. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext#getDescriptorsContributorID() - * @see #getGenEditionContext() - * @generated - */ - EAttribute getGenEditionContext_DescriptorsContributorID(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#isDescriptorsGenericPropertiesViews Descriptors Generic Properties Views}'. - * - * - * @return the meta object for the attribute 'Descriptors Generic Properties Views'. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext#isDescriptorsGenericPropertiesViews() - * @see #getGenEditionContext() - * @generated - */ - EAttribute getGenEditionContext_DescriptorsGenericPropertiesViews(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#isGmfPropertiesViews Gmf Properties Views}'. - * - * - * @return the meta object for the attribute 'Gmf Properties Views'. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext#isGmfPropertiesViews() - * @see #getGenEditionContext() - * @generated - */ - EAttribute getGenEditionContext_GmfPropertiesViews(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#isGenerateJunitTestCases Generate Junit Test Cases}'. - * - * - * @return the meta object for the attribute 'Generate Junit Test Cases'. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext#isGenerateJunitTestCases() - * @see #getGenEditionContext() - * @generated - */ - EAttribute getGenEditionContext_GenerateJunitTestCases(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getLeafComponentsSuperClass Leaf Components Super Class}'. - * - * - * @return the meta object for the attribute 'Leaf Components Super Class'. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext#getLeafComponentsSuperClass() - * @see #getGenEditionContext() - * @generated - */ - EAttribute getGenEditionContext_LeafComponentsSuperClass(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getPropertiesEditingProvidersSuperClass Properties Editing Providers Super Class}'. - * - * - * @return the meta object for the attribute 'Properties Editing Providers Super Class'. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext#getPropertiesEditingProvidersSuperClass() - * @see #getGenEditionContext() - * @generated - */ - EAttribute getGenEditionContext_PropertiesEditingProvidersSuperClass(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.EEFGen.EEFGenModelReference Model Reference}'. - * - * - * @return the meta object for class 'Model Reference'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModelReference - * @generated - */ - EClass getEEFGenModelReference(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.EEFGen.EEFGenModelReference#getReferencedContext Referenced Context}'. - * - * - * @return the meta object for the reference 'Referenced Context'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModelReference#getReferencedContext() - * @see #getEEFGenModelReference() - * @generated - */ - EReference getEEFGenModelReference_ReferencedContext(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel Model}'. - * - * - * @return the meta object for class 'Model'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel - * @generated - */ - EClass getEEFGenModel(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getEditionContexts Edition Contexts}'. - * - * - * @return the meta object for the containment reference list 'Edition Contexts'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel#getEditionContexts() - * @see #getEEFGenModel() - * @generated - */ - EReference getEEFGenModel_EditionContexts(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getViewsRepositories Views Repositories}'. - * - * - * @return the meta object for the containment reference list 'Views Repositories'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel#getViewsRepositories() - * @see #getEEFGenModel() - * @generated - */ - EReference getEEFGenModel_ViewsRepositories(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getGenDirectory Gen Directory}'. - * - * - * @return the meta object for the attribute 'Gen Directory'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel#getGenDirectory() - * @see #getEEFGenModel() - * @generated - */ - EAttribute getEEFGenModel_GenDirectory(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getAuthor Author}'. - * - * - * @return the meta object for the attribute 'Author'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel#getAuthor() - * @see #getEEFGenModel() - * @generated - */ - EAttribute getEEFGenModel_Author(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getLicense License}'. - * - * - * @return the meta object for the attribute 'License'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel#getLicense() - * @see #getEEFGenModel() - * @generated - */ - EAttribute getEEFGenModel_License(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getReferences References}'. - * - * - * @return the meta object for the containment reference list 'References'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel#getReferences() - * @see #getEEFGenModel() - * @generated - */ - EReference getEEFGenModel_References(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getTestsGenDirectory Tests Gen Directory}'. - * - * - * @return the meta object for the attribute 'Tests Gen Directory'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel#getTestsGenDirectory() - * @see #getEEFGenModel() - * @generated - */ - EAttribute getEEFGenModel_TestsGenDirectory(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#isUseJMergeForUserCode Use JMerge For User Code}'. - * - * - * @return the meta object for the attribute 'Use JMerge For User Code'. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel#isUseJMergeForUserCode() - * @see #getEEFGenModel() - * @generated - */ - EAttribute getEEFGenModel_UseJMergeForUserCode(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository Gen Views Repository}'. - * - * - * @return the meta object for class 'Gen Views Repository'. - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository - * @generated - */ - EClass getGenViewsRepository(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getViewsRepository Views Repository}'. - * - * - * @return the meta object for the reference 'Views Repository'. - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository#getViewsRepository() - * @see #getGenViewsRepository() - * @generated - */ - EReference getGenViewsRepository_ViewsRepository(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getBasePackage Base Package}'. - * - * - * @return the meta object for the attribute 'Base Package'. - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository#getBasePackage() - * @see #getGenViewsRepository() - * @generated - */ - EAttribute getGenViewsRepository_BasePackage(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#isSwtViews Swt Views}'. - * - * - * @return the meta object for the attribute 'Swt Views'. - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository#isSwtViews() - * @see #getGenViewsRepository() - * @generated - */ - EAttribute getGenViewsRepository_SwtViews(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#isFormViews Form Views}'. - * - * - * @return the meta object for the attribute 'Form Views'. - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository#isFormViews() - * @see #getGenViewsRepository() - * @generated - */ - EAttribute getGenViewsRepository_FormViews(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getHelpStrategy Help Strategy}'. - * - * - * @return the meta object for the attribute 'Help Strategy'. - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository#getHelpStrategy() - * @see #getGenViewsRepository() - * @generated - */ - EAttribute getGenViewsRepository_HelpStrategy(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getEefGenModel Eef Gen Model}'. - * - * - * @return the meta object for the container reference 'Eef Gen Model'. - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository#getEefGenModel() - * @see #getGenViewsRepository() - * @generated - */ - EReference getGenViewsRepository_EefGenModel(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getPartsSuperClass Parts Super Class}'. - * - * - * @return the meta object for the attribute 'Parts Super Class'. - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository#getPartsSuperClass() - * @see #getGenViewsRepository() - * @generated - */ - EAttribute getGenViewsRepository_PartsSuperClass(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getFormsSuperClass Forms Super Class}'. - * - * - * @return the meta object for the attribute 'Forms Super Class'. - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository#getFormsSuperClass() - * @see #getGenViewsRepository() - * @generated - */ - EAttribute getGenViewsRepository_FormsSuperClass(); - - /** - * Returns the meta object for enum '{@link org.eclipse.emf.eef.EEFGen.HELP_STRATEGY HELP STRATEGY}'. - * - * - * @return the meta object for enum 'HELP STRATEGY'. - * @see org.eclipse.emf.eef.EEFGen.HELP_STRATEGY - * @generated - */ - EEnum getHELP_STRATEGY(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - EEFGenFactory getEEFGenFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl Gen Edition Context}' class. - * - * - * @see org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl#getGenEditionContext() - * @generated - */ - EClass GEN_EDITION_CONTEXT = eINSTANCE.getGenEditionContext(); - - /** - * The meta object literal for the 'Properties Edition Context' reference feature. - * - * - * @generated - */ - EReference GEN_EDITION_CONTEXT__PROPERTIES_EDITION_CONTEXT = eINSTANCE.getGenEditionContext_PropertiesEditionContext(); - - /** - * The meta object literal for the 'Base Package' attribute feature. - * - * - * @generated - */ - EAttribute GEN_EDITION_CONTEXT__BASE_PACKAGE = eINSTANCE.getGenEditionContext_BasePackage(); - - /** - * The meta object literal for the 'Eef Gen Model' container reference feature. - * - * - * @generated - */ - EReference GEN_EDITION_CONTEXT__EEF_GEN_MODEL = eINSTANCE.getGenEditionContext_EefGenModel(); - - /** - * The meta object literal for the 'Descriptors Contributor ID' attribute feature. - * - * - * @generated - */ - EAttribute GEN_EDITION_CONTEXT__DESCRIPTORS_CONTRIBUTOR_ID = eINSTANCE.getGenEditionContext_DescriptorsContributorID(); - - /** - * The meta object literal for the 'Descriptors Generic Properties Views' attribute feature. - * - * - * @generated - */ - EAttribute GEN_EDITION_CONTEXT__DESCRIPTORS_GENERIC_PROPERTIES_VIEWS = eINSTANCE.getGenEditionContext_DescriptorsGenericPropertiesViews(); - - /** - * The meta object literal for the 'Gmf Properties Views' attribute feature. - * - * - * @generated - */ - EAttribute GEN_EDITION_CONTEXT__GMF_PROPERTIES_VIEWS = eINSTANCE.getGenEditionContext_GmfPropertiesViews(); - - /** - * The meta object literal for the 'Generate Junit Test Cases' attribute feature. - * - * - * @generated - */ - EAttribute GEN_EDITION_CONTEXT__GENERATE_JUNIT_TEST_CASES = eINSTANCE.getGenEditionContext_GenerateJunitTestCases(); - - /** - * The meta object literal for the 'Leaf Components Super Class' attribute feature. - * - * - * @generated - */ - EAttribute GEN_EDITION_CONTEXT__LEAF_COMPONENTS_SUPER_CLASS = eINSTANCE.getGenEditionContext_LeafComponentsSuperClass(); - - /** - * The meta object literal for the 'Properties Editing Providers Super Class' attribute feature. - * - * - * @generated - */ - EAttribute GEN_EDITION_CONTEXT__PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS = eINSTANCE.getGenEditionContext_PropertiesEditingProvidersSuperClass(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelReferenceImpl Model Reference}' class. - * - * - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenModelReferenceImpl - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl#getEEFGenModelReference() - * @generated - */ - EClass EEF_GEN_MODEL_REFERENCE = eINSTANCE.getEEFGenModelReference(); - - /** - * The meta object literal for the 'Referenced Context' reference feature. - * - * - * @generated - */ - EReference EEF_GEN_MODEL_REFERENCE__REFERENCED_CONTEXT = eINSTANCE.getEEFGenModelReference_ReferencedContext(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl Model}' class. - * - * - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl#getEEFGenModel() - * @generated - */ - EClass EEF_GEN_MODEL = eINSTANCE.getEEFGenModel(); - - /** - * The meta object literal for the 'Edition Contexts' containment reference list feature. - * - * - * @generated - */ - EReference EEF_GEN_MODEL__EDITION_CONTEXTS = eINSTANCE.getEEFGenModel_EditionContexts(); - - /** - * The meta object literal for the 'Views Repositories' containment reference list feature. - * - * - * @generated - */ - EReference EEF_GEN_MODEL__VIEWS_REPOSITORIES = eINSTANCE.getEEFGenModel_ViewsRepositories(); - - /** - * The meta object literal for the 'Gen Directory' attribute feature. - * - * - * @generated - */ - EAttribute EEF_GEN_MODEL__GEN_DIRECTORY = eINSTANCE.getEEFGenModel_GenDirectory(); - - /** - * The meta object literal for the 'Author' attribute feature. - * - * - * @generated - */ - EAttribute EEF_GEN_MODEL__AUTHOR = eINSTANCE.getEEFGenModel_Author(); - - /** - * The meta object literal for the 'License' attribute feature. - * - * - * @generated - */ - EAttribute EEF_GEN_MODEL__LICENSE = eINSTANCE.getEEFGenModel_License(); - - /** - * The meta object literal for the 'References' containment reference list feature. - * - * - * @generated - */ - EReference EEF_GEN_MODEL__REFERENCES = eINSTANCE.getEEFGenModel_References(); - - /** - * The meta object literal for the 'Tests Gen Directory' attribute feature. - * - * - * @generated - */ - EAttribute EEF_GEN_MODEL__TESTS_GEN_DIRECTORY = eINSTANCE.getEEFGenModel_TestsGenDirectory(); - - /** - * The meta object literal for the 'Use JMerge For User Code' attribute feature. - * - * - * @generated - */ - EAttribute EEF_GEN_MODEL__USE_JMERGE_FOR_USER_CODE = eINSTANCE.getEEFGenModel_UseJMergeForUserCode(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl Gen Views Repository}' class. - * - * - * @see org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl#getGenViewsRepository() - * @generated - */ - EClass GEN_VIEWS_REPOSITORY = eINSTANCE.getGenViewsRepository(); - - /** - * The meta object literal for the 'Views Repository' reference feature. - * - * - * @generated - */ - EReference GEN_VIEWS_REPOSITORY__VIEWS_REPOSITORY = eINSTANCE.getGenViewsRepository_ViewsRepository(); - - /** - * The meta object literal for the 'Base Package' attribute feature. - * - * - * @generated - */ - EAttribute GEN_VIEWS_REPOSITORY__BASE_PACKAGE = eINSTANCE.getGenViewsRepository_BasePackage(); - - /** - * The meta object literal for the 'Swt Views' attribute feature. - * - * - * @generated - */ - EAttribute GEN_VIEWS_REPOSITORY__SWT_VIEWS = eINSTANCE.getGenViewsRepository_SwtViews(); - - /** - * The meta object literal for the 'Form Views' attribute feature. - * - * - * @generated - */ - EAttribute GEN_VIEWS_REPOSITORY__FORM_VIEWS = eINSTANCE.getGenViewsRepository_FormViews(); - - /** - * The meta object literal for the 'Help Strategy' attribute feature. - * - * - * @generated - */ - EAttribute GEN_VIEWS_REPOSITORY__HELP_STRATEGY = eINSTANCE.getGenViewsRepository_HelpStrategy(); - - /** - * The meta object literal for the 'Eef Gen Model' container reference feature. - * - * - * @generated - */ - EReference GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL = eINSTANCE.getGenViewsRepository_EefGenModel(); - - /** - * The meta object literal for the 'Parts Super Class' attribute feature. - * - * - * @generated - */ - EAttribute GEN_VIEWS_REPOSITORY__PARTS_SUPER_CLASS = eINSTANCE.getGenViewsRepository_PartsSuperClass(); - - /** - * The meta object literal for the 'Forms Super Class' attribute feature. - * - * - * @generated - */ - EAttribute GEN_VIEWS_REPOSITORY__FORMS_SUPER_CLASS = eINSTANCE.getGenViewsRepository_FormsSuperClass(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.EEFGen.HELP_STRATEGY HELP STRATEGY}' enum. - * - * - * @see org.eclipse.emf.eef.EEFGen.HELP_STRATEGY - * @see org.eclipse.emf.eef.EEFGen.impl.EEFGenPackageImpl#getHELP_STRATEGY() - * @generated - */ - EEnum HELP_STRATEGY = eINSTANCE.getHELP_STRATEGY(); - - } - -} //EEFGenPackage diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/GenEditionContext.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/GenEditionContext.java deleted file mode 100644 index 81dd33c4d..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/GenEditionContext.java +++ /dev/null @@ -1,277 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.components.PropertiesEditionContext; - -/** - * - * A representation of the model object 'Gen Edition Context'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getPropertiesEditionContext Properties Edition Context}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getBasePackage Base Package}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getEefGenModel Eef Gen Model}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getDescriptorsContributorID Descriptors Contributor ID}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenEditionContext#isDescriptorsGenericPropertiesViews Descriptors Generic Properties Views}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenEditionContext#isGmfPropertiesViews Gmf Properties Views}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenEditionContext#isGenerateJunitTestCases Generate Junit Test Cases}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getLeafComponentsSuperClass Leaf Components Super Class}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getPropertiesEditingProvidersSuperClass Properties Editing Providers Super Class}
  • - *
- *

- * - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenEditionContext() - * @model - * @generated - */ -public interface GenEditionContext extends EObject { - /** - * Returns the value of the 'Properties Edition Context' reference. - * - *

- * If the meaning of the 'Properties Edition Context' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Properties Edition Context' reference. - * @see #setPropertiesEditionContext(PropertiesEditionContext) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenEditionContext_PropertiesEditionContext() - * @model required="true" - * @generated - */ - PropertiesEditionContext getPropertiesEditionContext(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getPropertiesEditionContext Properties Edition Context}' reference. - * - * - * @param value the new value of the 'Properties Edition Context' reference. - * @see #getPropertiesEditionContext() - * @generated - */ - void setPropertiesEditionContext(PropertiesEditionContext value); - - /** - * Returns the value of the 'Base Package' attribute. - * - *

- * If the meaning of the 'Base Package' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Base Package' attribute. - * @see #setBasePackage(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenEditionContext_BasePackage() - * @model - * @generated - */ - String getBasePackage(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getBasePackage Base Package}' attribute. - * - * - * @param value the new value of the 'Base Package' attribute. - * @see #getBasePackage() - * @generated - */ - void setBasePackage(String value); - - /** - * Returns the value of the 'Eef Gen Model' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getEditionContexts Edition Contexts}'. - * - *

- * If the meaning of the 'Eef Gen Model' container reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Eef Gen Model' container reference. - * @see #setEefGenModel(EEFGenModel) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenEditionContext_EefGenModel() - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel#getEditionContexts - * @model opposite="editionContexts" required="true" transient="false" - * @generated - */ - EEFGenModel getEefGenModel(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getEefGenModel Eef Gen Model}' container reference. - * - * - * @param value the new value of the 'Eef Gen Model' container reference. - * @see #getEefGenModel() - * @generated - */ - void setEefGenModel(EEFGenModel value); - - /** - * Returns the value of the 'Descriptors Contributor ID' attribute. - * - *

- * If the meaning of the 'Descriptors Contributor ID' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Descriptors Contributor ID' attribute. - * @see #setDescriptorsContributorID(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenEditionContext_DescriptorsContributorID() - * @model - * @generated - */ - String getDescriptorsContributorID(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getDescriptorsContributorID Descriptors Contributor ID}' attribute. - * - * - * @param value the new value of the 'Descriptors Contributor ID' attribute. - * @see #getDescriptorsContributorID() - * @generated - */ - void setDescriptorsContributorID(String value); - - /** - * Returns the value of the 'Descriptors Generic Properties Views' attribute. - * - *

- * If the meaning of the 'Descriptors Generic Properties Views' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Descriptors Generic Properties Views' attribute. - * @see #setDescriptorsGenericPropertiesViews(boolean) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenEditionContext_DescriptorsGenericPropertiesViews() - * @model - * @generated - */ - boolean isDescriptorsGenericPropertiesViews(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#isDescriptorsGenericPropertiesViews Descriptors Generic Properties Views}' attribute. - * - * - * @param value the new value of the 'Descriptors Generic Properties Views' attribute. - * @see #isDescriptorsGenericPropertiesViews() - * @generated - */ - void setDescriptorsGenericPropertiesViews(boolean value); - - /** - * Returns the value of the 'Gmf Properties Views' attribute. - * - *

- * If the meaning of the 'Gmf Properties Views' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Gmf Properties Views' attribute. - * @see #setGmfPropertiesViews(boolean) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenEditionContext_GmfPropertiesViews() - * @model - * @generated - */ - boolean isGmfPropertiesViews(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#isGmfPropertiesViews Gmf Properties Views}' attribute. - * - * - * @param value the new value of the 'Gmf Properties Views' attribute. - * @see #isGmfPropertiesViews() - * @generated - */ - void setGmfPropertiesViews(boolean value); - - /** - * Returns the value of the 'Generate Junit Test Cases' attribute. - * - *

- * If the meaning of the 'Generate Junit Test Cases' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Generate Junit Test Cases' attribute. - * @see #setGenerateJunitTestCases(boolean) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenEditionContext_GenerateJunitTestCases() - * @model - * @generated - */ - boolean isGenerateJunitTestCases(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#isGenerateJunitTestCases Generate Junit Test Cases}' attribute. - * - * - * @param value the new value of the 'Generate Junit Test Cases' attribute. - * @see #isGenerateJunitTestCases() - * @generated - */ - void setGenerateJunitTestCases(boolean value); - - /** - * Returns the value of the 'Leaf Components Super Class' attribute. - * - *

- * If the meaning of the 'Leaf Components Super Class' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Leaf Components Super Class' attribute. - * @see #setLeafComponentsSuperClass(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenEditionContext_LeafComponentsSuperClass() - * @model - * @generated - */ - String getLeafComponentsSuperClass(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getLeafComponentsSuperClass Leaf Components Super Class}' attribute. - * - * - * @param value the new value of the 'Leaf Components Super Class' attribute. - * @see #getLeafComponentsSuperClass() - * @generated - */ - void setLeafComponentsSuperClass(String value); - - /** - * Returns the value of the 'Properties Editing Providers Super Class' attribute. - * - *

- * If the meaning of the 'Properties Editing Providers Super Class' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Properties Editing Providers Super Class' attribute. - * @see #setPropertiesEditingProvidersSuperClass(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenEditionContext_PropertiesEditingProvidersSuperClass() - * @model - * @generated - */ - String getPropertiesEditingProvidersSuperClass(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext#getPropertiesEditingProvidersSuperClass Properties Editing Providers Super Class}' attribute. - * - * - * @param value the new value of the 'Properties Editing Providers Super Class' attribute. - * @see #getPropertiesEditingProvidersSuperClass() - * @generated - */ - void setPropertiesEditingProvidersSuperClass(String value); - -} // GenEditionContext diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/GenViewsRepository.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/GenViewsRepository.java deleted file mode 100644 index 7b6ec23dc..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/GenViewsRepository.java +++ /dev/null @@ -1,253 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.views.ViewsRepository; - -/** - * - * A representation of the model object 'Gen Views Repository'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getViewsRepository Views Repository}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getBasePackage Base Package}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#isSwtViews Swt Views}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#isFormViews Form Views}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getHelpStrategy Help Strategy}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getEefGenModel Eef Gen Model}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getPartsSuperClass Parts Super Class}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getFormsSuperClass Forms Super Class}
  • - *
- *

- * - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenViewsRepository() - * @model - * @generated - */ -public interface GenViewsRepository extends EObject { - /** - * Returns the value of the 'Views Repository' reference. - * - *

- * If the meaning of the 'Views Repository' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Views Repository' reference. - * @see #setViewsRepository(ViewsRepository) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenViewsRepository_ViewsRepository() - * @model required="true" - * @generated - */ - ViewsRepository getViewsRepository(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getViewsRepository Views Repository}' reference. - * - * - * @param value the new value of the 'Views Repository' reference. - * @see #getViewsRepository() - * @generated - */ - void setViewsRepository(ViewsRepository value); - - /** - * Returns the value of the 'Base Package' attribute. - * - *

- * If the meaning of the 'Base Package' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Base Package' attribute. - * @see #setBasePackage(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenViewsRepository_BasePackage() - * @model - * @generated - */ - String getBasePackage(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getBasePackage Base Package}' attribute. - * - * - * @param value the new value of the 'Base Package' attribute. - * @see #getBasePackage() - * @generated - */ - void setBasePackage(String value); - - /** - * Returns the value of the 'Swt Views' attribute. - * - *

- * If the meaning of the 'Swt Views' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Swt Views' attribute. - * @see #setSwtViews(boolean) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenViewsRepository_SwtViews() - * @model - * @generated - */ - boolean isSwtViews(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#isSwtViews Swt Views}' attribute. - * - * - * @param value the new value of the 'Swt Views' attribute. - * @see #isSwtViews() - * @generated - */ - void setSwtViews(boolean value); - - /** - * Returns the value of the 'Form Views' attribute. - * - *

- * If the meaning of the 'Form Views' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Form Views' attribute. - * @see #setFormViews(boolean) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenViewsRepository_FormViews() - * @model - * @generated - */ - boolean isFormViews(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#isFormViews Form Views}' attribute. - * - * - * @param value the new value of the 'Form Views' attribute. - * @see #isFormViews() - * @generated - */ - void setFormViews(boolean value); - - /** - * Returns the value of the 'Help Strategy' attribute. - * The literals are from the enumeration {@link org.eclipse.emf.eef.EEFGen.HELP_STRATEGY}. - * - *

- * If the meaning of the 'Help Strategy' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Help Strategy' attribute. - * @see org.eclipse.emf.eef.EEFGen.HELP_STRATEGY - * @see #setHelpStrategy(HELP_STRATEGY) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenViewsRepository_HelpStrategy() - * @model required="true" - * @generated - */ - HELP_STRATEGY getHelpStrategy(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getHelpStrategy Help Strategy}' attribute. - * - * - * @param value the new value of the 'Help Strategy' attribute. - * @see org.eclipse.emf.eef.EEFGen.HELP_STRATEGY - * @see #getHelpStrategy() - * @generated - */ - void setHelpStrategy(HELP_STRATEGY value); - - /** - * Returns the value of the 'Eef Gen Model' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel#getViewsRepositories Views Repositories}'. - * - *

- * If the meaning of the 'Eef Gen Model' container reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Eef Gen Model' container reference. - * @see #setEefGenModel(EEFGenModel) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenViewsRepository_EefGenModel() - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel#getViewsRepositories - * @model opposite="viewsRepositories" required="true" transient="false" - * @generated - */ - EEFGenModel getEefGenModel(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getEefGenModel Eef Gen Model}' container reference. - * - * - * @param value the new value of the 'Eef Gen Model' container reference. - * @see #getEefGenModel() - * @generated - */ - void setEefGenModel(EEFGenModel value); - - /** - * Returns the value of the 'Parts Super Class' attribute. - * - *

- * If the meaning of the 'Parts Super Class' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Parts Super Class' attribute. - * @see #setPartsSuperClass(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenViewsRepository_PartsSuperClass() - * @model - * @generated - */ - String getPartsSuperClass(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getPartsSuperClass Parts Super Class}' attribute. - * - * - * @param value the new value of the 'Parts Super Class' attribute. - * @see #getPartsSuperClass() - * @generated - */ - void setPartsSuperClass(String value); - - /** - * Returns the value of the 'Forms Super Class' attribute. - * - *

- * If the meaning of the 'Forms Super Class' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Forms Super Class' attribute. - * @see #setFormsSuperClass(String) - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getGenViewsRepository_FormsSuperClass() - * @model - * @generated - */ - String getFormsSuperClass(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository#getFormsSuperClass Forms Super Class}' attribute. - * - * - * @param value the new value of the 'Forms Super Class' attribute. - * @see #getFormsSuperClass() - * @generated - */ - void setFormsSuperClass(String value); - -} // GenViewsRepository diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/HELP_STRATEGY.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/HELP_STRATEGY.java deleted file mode 100644 index b85f59947..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/HELP_STRATEGY.java +++ /dev/null @@ -1,216 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; - -import org.eclipse.emf.common.util.Enumerator; - -/** - * - * A representation of the literals of the enumeration 'HELP STRATEGY', - * and utility methods for working with them. - * - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#getHELP_STRATEGY() - * @model - * @generated - */ -public enum HELP_STRATEGY implements Enumerator { - /** - * The 'GENMODEL' literal object. - * - * - * @see #GENMODEL_VALUE - * @generated - * @ordered - */ - GENMODEL(0, "GENMODEL", "GENMODEL"), - - /** - * The 'ECOREMODEL' literal object. - * - * - * @see #ECOREMODEL_VALUE - * @generated - * @ordered - */ - ECOREMODEL(1, "ECOREMODEL", "ECOREMODEL"); - - /** - * The 'GENMODEL' literal value. - * - *

- * If the meaning of 'GENMODEL' literal object isn't clear, - * there really should be more of a description here... - *

- * - * @see #GENMODEL - * @model - * @generated - * @ordered - */ - public static final int GENMODEL_VALUE = 0; - - /** - * The 'ECOREMODEL' literal value. - * - *

- * If the meaning of 'ECOREMODEL' literal object isn't clear, - * there really should be more of a description here... - *

- * - * @see #ECOREMODEL - * @model - * @generated - * @ordered - */ - public static final int ECOREMODEL_VALUE = 1; - - /** - * An array of all the 'HELP STRATEGY' enumerators. - * - * - * @generated - */ - private static final HELP_STRATEGY[] VALUES_ARRAY = - new HELP_STRATEGY[] { - GENMODEL, - ECOREMODEL, - }; - - /** - * A public read-only list of all the 'HELP STRATEGY' enumerators. - * - * - * @generated - */ - public static final List VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the 'HELP STRATEGY' literal with the specified literal value. - * - * - * @generated - */ - public static HELP_STRATEGY get(String literal) { - for (int i = 0; i < VALUES_ARRAY.length; ++i) { - HELP_STRATEGY result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) { - return result; - } - } - return null; - } - - /** - * Returns the 'HELP STRATEGY' literal with the specified name. - * - * - * @generated - */ - public static HELP_STRATEGY getByName(String name) { - for (int i = 0; i < VALUES_ARRAY.length; ++i) { - HELP_STRATEGY result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) { - return result; - } - } - return null; - } - - /** - * Returns the 'HELP STRATEGY' literal with the specified integer value. - * - * - * @generated - */ - public static HELP_STRATEGY get(int value) { - switch (value) { - case GENMODEL_VALUE: return GENMODEL; - case ECOREMODEL_VALUE: return ECOREMODEL; - } - return null; - } - - /** - * - * - * @generated - */ - private final int value; - - /** - * - * - * @generated - */ - private final String name; - - /** - * - * - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * - * - * @generated - */ - private HELP_STRATEGY(int value, String name, String literal) { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * - * - * @generated - */ - public int getValue() { - return value; - } - - /** - * - * - * @generated - */ - public String getName() { - return name; - } - - /** - * - * - * @generated - */ - public String getLiteral() { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * - * - * @generated - */ - @Override - public String toString() { - return literal; - } - -} //HELP_STRATEGY diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenFactoryImpl.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenFactoryImpl.java deleted file mode 100644 index 9644bc30f..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenFactoryImpl.java +++ /dev/null @@ -1,191 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EDataType; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.impl.EFactoryImpl; -import org.eclipse.emf.ecore.plugin.EcorePlugin; -import org.eclipse.emf.eef.EEFGen.EEFGenFactory; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenModelReference; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; -import org.eclipse.emf.eef.EEFGen.HELP_STRATEGY; - - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class EEFGenFactoryImpl extends EFactoryImpl implements EEFGenFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static EEFGenFactory init() { - try { - EEFGenFactory theEEFGenFactory = (EEFGenFactory)EPackage.Registry.INSTANCE.getEFactory("http://www.eclipse.org/emf/eef/generation/1.0.0"); - if (theEEFGenFactory != null) { - return theEEFGenFactory; - } - } - catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new EEFGenFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public EEFGenFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case EEFGenPackage.GEN_EDITION_CONTEXT: return createGenEditionContext(); - case EEFGenPackage.EEF_GEN_MODEL_REFERENCE: return createEEFGenModelReference(); - case EEFGenPackage.EEF_GEN_MODEL: return createEEFGenModel(); - case EEFGenPackage.GEN_VIEWS_REPOSITORY: return createGenViewsRepository(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - @Override - public Object createFromString(EDataType eDataType, String initialValue) { - switch (eDataType.getClassifierID()) { - case EEFGenPackage.HELP_STRATEGY: - return createHELP_STRATEGYFromString(eDataType, initialValue); - default: - throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - @Override - public String convertToString(EDataType eDataType, Object instanceValue) { - switch (eDataType.getClassifierID()) { - case EEFGenPackage.HELP_STRATEGY: - return convertHELP_STRATEGYToString(eDataType, instanceValue); - default: - throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public GenEditionContext createGenEditionContext() { - GenEditionContextImpl genEditionContext = new GenEditionContextImpl(); - return genEditionContext; - } - - /** - * - * - * @generated - */ - public EEFGenModelReference createEEFGenModelReference() { - EEFGenModelReferenceImpl eefGenModelReference = new EEFGenModelReferenceImpl(); - return eefGenModelReference; - } - - /** - * - * - * @generated - */ - public EEFGenModel createEEFGenModel() { - EEFGenModelImpl eefGenModel = new EEFGenModelImpl(); - return eefGenModel; - } - - /** - * - * - * @generated - */ - public GenViewsRepository createGenViewsRepository() { - GenViewsRepositoryImpl genViewsRepository = new GenViewsRepositoryImpl(); - return genViewsRepository; - } - - /** - * - * - * @generated - */ - public HELP_STRATEGY createHELP_STRATEGYFromString(EDataType eDataType, String initialValue) { - HELP_STRATEGY result = HELP_STRATEGY.get(initialValue); - if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - return result; - } - - /** - * - * - * @generated - */ - public String convertHELP_STRATEGYToString(EDataType eDataType, Object instanceValue) { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * - * - * @generated - */ - public EEFGenPackage getEEFGenPackage() { - return (EEFGenPackage)getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static EEFGenPackage getPackage() { - return EEFGenPackage.eINSTANCE; - } - -} //EEFGenFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenModelImpl.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenModelImpl.java deleted file mode 100644 index d8c178b48..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenModelImpl.java +++ /dev/null @@ -1,533 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; -import org.eclipse.emf.ecore.util.InternalEList; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenModelReference; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; - -/** - * - * An implementation of the model object 'Model'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl#getEditionContexts Edition Contexts}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl#getViewsRepositories Views Repositories}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl#getGenDirectory Gen Directory}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl#getAuthor Author}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl#getLicense License}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl#getReferences References}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl#getTestsGenDirectory Tests Gen Directory}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelImpl#isUseJMergeForUserCode Use JMerge For User Code}
  • - *
- *

- * - * @generated - */ -public class EEFGenModelImpl extends EObjectImpl implements EEFGenModel { - /** - * The cached value of the '{@link #getEditionContexts() Edition Contexts}' containment reference list. - * - * - * @see #getEditionContexts() - * @generated - * @ordered - */ - protected EList editionContexts; - - /** - * The cached value of the '{@link #getViewsRepositories() Views Repositories}' containment reference list. - * - * - * @see #getViewsRepositories() - * @generated - * @ordered - */ - protected EList viewsRepositories; - - /** - * The default value of the '{@link #getGenDirectory() Gen Directory}' attribute. - * - * - * @see #getGenDirectory() - * @generated - * @ordered - */ - protected static final String GEN_DIRECTORY_EDEFAULT = null; - - /** - * The cached value of the '{@link #getGenDirectory() Gen Directory}' attribute. - * - * - * @see #getGenDirectory() - * @generated - * @ordered - */ - protected String genDirectory = GEN_DIRECTORY_EDEFAULT; - - /** - * The default value of the '{@link #getAuthor() Author}' attribute. - * - * - * @see #getAuthor() - * @generated - * @ordered - */ - protected static final String AUTHOR_EDEFAULT = null; - - /** - * The cached value of the '{@link #getAuthor() Author}' attribute. - * - * - * @see #getAuthor() - * @generated - * @ordered - */ - protected String author = AUTHOR_EDEFAULT; - - /** - * The default value of the '{@link #getLicense() License}' attribute. - * - * - * @see #getLicense() - * @generated - * @ordered - */ - protected static final String LICENSE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getLicense() License}' attribute. - * - * - * @see #getLicense() - * @generated - * @ordered - */ - protected String license = LICENSE_EDEFAULT; - - /** - * The cached value of the '{@link #getReferences() References}' containment reference list. - * - * - * @see #getReferences() - * @generated - * @ordered - */ - protected EList references; - - /** - * The default value of the '{@link #getTestsGenDirectory() Tests Gen Directory}' attribute. - * - * - * @see #getTestsGenDirectory() - * @generated - * @ordered - */ - protected static final String TESTS_GEN_DIRECTORY_EDEFAULT = null; - - /** - * The cached value of the '{@link #getTestsGenDirectory() Tests Gen Directory}' attribute. - * - * - * @see #getTestsGenDirectory() - * @generated - * @ordered - */ - protected String testsGenDirectory = TESTS_GEN_DIRECTORY_EDEFAULT; - - /** - * The default value of the '{@link #isUseJMergeForUserCode() Use JMerge For User Code}' attribute. - * - * - * @see #isUseJMergeForUserCode() - * @generated - * @ordered - */ - protected static final boolean USE_JMERGE_FOR_USER_CODE_EDEFAULT = false; - - /** - * The cached value of the '{@link #isUseJMergeForUserCode() Use JMerge For User Code}' attribute. - * - * - * @see #isUseJMergeForUserCode() - * @generated - * @ordered - */ - protected boolean useJMergeForUserCode = USE_JMERGE_FOR_USER_CODE_EDEFAULT; - - /** - * - * - * @generated - */ - protected EEFGenModelImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFGenPackage.Literals.EEF_GEN_MODEL; - } - - /** - * - * - * @generated - */ - public EList getEditionContexts() { - if (editionContexts == null) { - editionContexts = new EObjectContainmentWithInverseEList(GenEditionContext.class, this, EEFGenPackage.EEF_GEN_MODEL__EDITION_CONTEXTS, EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL); - } - return editionContexts; - } - - /** - * - * - * @generated - */ - public EList getViewsRepositories() { - if (viewsRepositories == null) { - viewsRepositories = new EObjectContainmentWithInverseEList(GenViewsRepository.class, this, EEFGenPackage.EEF_GEN_MODEL__VIEWS_REPOSITORIES, EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL); - } - return viewsRepositories; - } - - /** - * - * - * @generated - */ - public String getGenDirectory() { - return genDirectory; - } - - /** - * - * - * @generated - */ - public void setGenDirectory(String newGenDirectory) { - String oldGenDirectory = genDirectory; - genDirectory = newGenDirectory; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.EEF_GEN_MODEL__GEN_DIRECTORY, oldGenDirectory, genDirectory)); - } - - /** - * - * - * @generated - */ - public String getAuthor() { - return author; - } - - /** - * - * - * @generated - */ - public void setAuthor(String newAuthor) { - String oldAuthor = author; - author = newAuthor; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.EEF_GEN_MODEL__AUTHOR, oldAuthor, author)); - } - - /** - * - * - * @generated - */ - public String getLicense() { - return license; - } - - /** - * - * - * @generated - */ - public void setLicense(String newLicense) { - String oldLicense = license; - license = newLicense; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.EEF_GEN_MODEL__LICENSE, oldLicense, license)); - } - - /** - * - * - * @generated - */ - public EList getReferences() { - if (references == null) { - references = new EObjectContainmentEList(EEFGenModelReference.class, this, EEFGenPackage.EEF_GEN_MODEL__REFERENCES); - } - return references; - } - - /** - * - * - * @generated - */ - public String getTestsGenDirectory() { - return testsGenDirectory; - } - - /** - * - * - * @generated - */ - public void setTestsGenDirectory(String newTestsGenDirectory) { - String oldTestsGenDirectory = testsGenDirectory; - testsGenDirectory = newTestsGenDirectory; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.EEF_GEN_MODEL__TESTS_GEN_DIRECTORY, oldTestsGenDirectory, testsGenDirectory)); - } - - /** - * - * - * @generated - */ - public boolean isUseJMergeForUserCode() { - return useJMergeForUserCode; - } - - /** - * - * - * @generated - */ - public void setUseJMergeForUserCode(boolean newUseJMergeForUserCode) { - boolean oldUseJMergeForUserCode = useJMergeForUserCode; - useJMergeForUserCode = newUseJMergeForUserCode; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.EEF_GEN_MODEL__USE_JMERGE_FOR_USER_CODE, oldUseJMergeForUserCode, useJMergeForUserCode)); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case EEFGenPackage.EEF_GEN_MODEL__EDITION_CONTEXTS: - return ((InternalEList)(InternalEList)getEditionContexts()).basicAdd(otherEnd, msgs); - case EEFGenPackage.EEF_GEN_MODEL__VIEWS_REPOSITORIES: - return ((InternalEList)(InternalEList)getViewsRepositories()).basicAdd(otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case EEFGenPackage.EEF_GEN_MODEL__EDITION_CONTEXTS: - return ((InternalEList)getEditionContexts()).basicRemove(otherEnd, msgs); - case EEFGenPackage.EEF_GEN_MODEL__VIEWS_REPOSITORIES: - return ((InternalEList)getViewsRepositories()).basicRemove(otherEnd, msgs); - case EEFGenPackage.EEF_GEN_MODEL__REFERENCES: - return ((InternalEList)getReferences()).basicRemove(otherEnd, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFGenPackage.EEF_GEN_MODEL__EDITION_CONTEXTS: - return getEditionContexts(); - case EEFGenPackage.EEF_GEN_MODEL__VIEWS_REPOSITORIES: - return getViewsRepositories(); - case EEFGenPackage.EEF_GEN_MODEL__GEN_DIRECTORY: - return getGenDirectory(); - case EEFGenPackage.EEF_GEN_MODEL__AUTHOR: - return getAuthor(); - case EEFGenPackage.EEF_GEN_MODEL__LICENSE: - return getLicense(); - case EEFGenPackage.EEF_GEN_MODEL__REFERENCES: - return getReferences(); - case EEFGenPackage.EEF_GEN_MODEL__TESTS_GEN_DIRECTORY: - return getTestsGenDirectory(); - case EEFGenPackage.EEF_GEN_MODEL__USE_JMERGE_FOR_USER_CODE: - return isUseJMergeForUserCode(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFGenPackage.EEF_GEN_MODEL__EDITION_CONTEXTS: - getEditionContexts().clear(); - getEditionContexts().addAll((Collection)newValue); - return; - case EEFGenPackage.EEF_GEN_MODEL__VIEWS_REPOSITORIES: - getViewsRepositories().clear(); - getViewsRepositories().addAll((Collection)newValue); - return; - case EEFGenPackage.EEF_GEN_MODEL__GEN_DIRECTORY: - setGenDirectory((String)newValue); - return; - case EEFGenPackage.EEF_GEN_MODEL__AUTHOR: - setAuthor((String)newValue); - return; - case EEFGenPackage.EEF_GEN_MODEL__LICENSE: - setLicense((String)newValue); - return; - case EEFGenPackage.EEF_GEN_MODEL__REFERENCES: - getReferences().clear(); - getReferences().addAll((Collection)newValue); - return; - case EEFGenPackage.EEF_GEN_MODEL__TESTS_GEN_DIRECTORY: - setTestsGenDirectory((String)newValue); - return; - case EEFGenPackage.EEF_GEN_MODEL__USE_JMERGE_FOR_USER_CODE: - setUseJMergeForUserCode((Boolean)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFGenPackage.EEF_GEN_MODEL__EDITION_CONTEXTS: - getEditionContexts().clear(); - return; - case EEFGenPackage.EEF_GEN_MODEL__VIEWS_REPOSITORIES: - getViewsRepositories().clear(); - return; - case EEFGenPackage.EEF_GEN_MODEL__GEN_DIRECTORY: - setGenDirectory(GEN_DIRECTORY_EDEFAULT); - return; - case EEFGenPackage.EEF_GEN_MODEL__AUTHOR: - setAuthor(AUTHOR_EDEFAULT); - return; - case EEFGenPackage.EEF_GEN_MODEL__LICENSE: - setLicense(LICENSE_EDEFAULT); - return; - case EEFGenPackage.EEF_GEN_MODEL__REFERENCES: - getReferences().clear(); - return; - case EEFGenPackage.EEF_GEN_MODEL__TESTS_GEN_DIRECTORY: - setTestsGenDirectory(TESTS_GEN_DIRECTORY_EDEFAULT); - return; - case EEFGenPackage.EEF_GEN_MODEL__USE_JMERGE_FOR_USER_CODE: - setUseJMergeForUserCode(USE_JMERGE_FOR_USER_CODE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFGenPackage.EEF_GEN_MODEL__EDITION_CONTEXTS: - return editionContexts != null && !editionContexts.isEmpty(); - case EEFGenPackage.EEF_GEN_MODEL__VIEWS_REPOSITORIES: - return viewsRepositories != null && !viewsRepositories.isEmpty(); - case EEFGenPackage.EEF_GEN_MODEL__GEN_DIRECTORY: - return GEN_DIRECTORY_EDEFAULT == null ? genDirectory != null : !GEN_DIRECTORY_EDEFAULT.equals(genDirectory); - case EEFGenPackage.EEF_GEN_MODEL__AUTHOR: - return AUTHOR_EDEFAULT == null ? author != null : !AUTHOR_EDEFAULT.equals(author); - case EEFGenPackage.EEF_GEN_MODEL__LICENSE: - return LICENSE_EDEFAULT == null ? license != null : !LICENSE_EDEFAULT.equals(license); - case EEFGenPackage.EEF_GEN_MODEL__REFERENCES: - return references != null && !references.isEmpty(); - case EEFGenPackage.EEF_GEN_MODEL__TESTS_GEN_DIRECTORY: - return TESTS_GEN_DIRECTORY_EDEFAULT == null ? testsGenDirectory != null : !TESTS_GEN_DIRECTORY_EDEFAULT.equals(testsGenDirectory); - case EEFGenPackage.EEF_GEN_MODEL__USE_JMERGE_FOR_USER_CODE: - return useJMergeForUserCode != USE_JMERGE_FOR_USER_CODE_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (genDirectory: "); - result.append(genDirectory); - result.append(", author: "); - result.append(author); - result.append(", license: "); - result.append(license); - result.append(", testsGenDirectory: "); - result.append(testsGenDirectory); - result.append(", useJMergeForUserCode: "); - result.append(useJMergeForUserCode); - result.append(')'); - return result.toString(); - } - -} //EEFGenModelImpl diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenModelReferenceImpl.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenModelReferenceImpl.java deleted file mode 100644 index 0d20762d0..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenModelReferenceImpl.java +++ /dev/null @@ -1,162 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenModelReference; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; - -/** - * - * An implementation of the model object 'Model Reference'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.EEFGenModelReferenceImpl#getReferencedContext Referenced Context}
  • - *
- *

- * - * @generated - */ -public class EEFGenModelReferenceImpl extends EObjectImpl implements EEFGenModelReference { - /** - * The cached value of the '{@link #getReferencedContext() Referenced Context}' reference. - * - * - * @see #getReferencedContext() - * @generated - * @ordered - */ - protected EEFGenModel referencedContext; - - /** - * - * - * @generated - */ - protected EEFGenModelReferenceImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFGenPackage.Literals.EEF_GEN_MODEL_REFERENCE; - } - - /** - * - * - * @generated - */ - public EEFGenModel getReferencedContext() { - if (referencedContext != null && referencedContext.eIsProxy()) { - InternalEObject oldReferencedContext = (InternalEObject)referencedContext; - referencedContext = (EEFGenModel)eResolveProxy(oldReferencedContext); - if (referencedContext != oldReferencedContext) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFGenPackage.EEF_GEN_MODEL_REFERENCE__REFERENCED_CONTEXT, oldReferencedContext, referencedContext)); - } - } - return referencedContext; - } - - /** - * - * - * @generated - */ - public EEFGenModel basicGetReferencedContext() { - return referencedContext; - } - - /** - * - * - * @generated - */ - public void setReferencedContext(EEFGenModel newReferencedContext) { - EEFGenModel oldReferencedContext = referencedContext; - referencedContext = newReferencedContext; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.EEF_GEN_MODEL_REFERENCE__REFERENCED_CONTEXT, oldReferencedContext, referencedContext)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFGenPackage.EEF_GEN_MODEL_REFERENCE__REFERENCED_CONTEXT: - if (resolve) return getReferencedContext(); - return basicGetReferencedContext(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFGenPackage.EEF_GEN_MODEL_REFERENCE__REFERENCED_CONTEXT: - setReferencedContext((EEFGenModel)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFGenPackage.EEF_GEN_MODEL_REFERENCE__REFERENCED_CONTEXT: - setReferencedContext((EEFGenModel)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFGenPackage.EEF_GEN_MODEL_REFERENCE__REFERENCED_CONTEXT: - return referencedContext != null; - } - return super.eIsSet(featureID); - } - -} //EEFGenModelReferenceImpl diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenPackageImpl.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenPackageImpl.java deleted file mode 100644 index cc8b2f4dd..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/EEFGenPackageImpl.java +++ /dev/null @@ -1,556 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.impl; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EEnum; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.impl.EPackageImpl; -import org.eclipse.emf.eef.EEFGen.EEFGenFactory; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenModelReference; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.views.ViewsPackage; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class EEFGenPackageImpl extends EPackageImpl implements EEFGenPackage { - /** - * - * - * @generated - */ - private EClass genEditionContextEClass = null; - - /** - * - * - * @generated - */ - private EClass eefGenModelReferenceEClass = null; - - /** - * - * - * @generated - */ - private EClass eefGenModelEClass = null; - - /** - * - * - * @generated - */ - private EClass genViewsRepositoryEClass = null; - - /** - * - * - * @generated - */ - private EEnum helP_STRATEGYEEnum = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage#eNS_URI - * @see #init() - * @generated - */ - private EEFGenPackageImpl() { - super(eNS_URI, EEFGenFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link EEFGenPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static EEFGenPackage init() { - if (isInited) return (EEFGenPackage)EPackage.Registry.INSTANCE.getEPackage(EEFGenPackage.eNS_URI); - - // Obtain or create and register package - EEFGenPackageImpl theEEFGenPackage = (EEFGenPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof EEFGenPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new EEFGenPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - ComponentsPackage.eINSTANCE.eClass(); - - // Create package meta-data objects - theEEFGenPackage.createPackageContents(); - - // Initialize created meta-data - theEEFGenPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theEEFGenPackage.freeze(); - - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(EEFGenPackage.eNS_URI, theEEFGenPackage); - return theEEFGenPackage; - } - - /** - * - * - * @generated - */ - public EClass getGenEditionContext() { - return genEditionContextEClass; - } - - /** - * - * - * @generated - */ - public EReference getGenEditionContext_PropertiesEditionContext() { - return (EReference)genEditionContextEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EAttribute getGenEditionContext_BasePackage() { - return (EAttribute)genEditionContextEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EReference getGenEditionContext_EefGenModel() { - return (EReference)genEditionContextEClass.getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EAttribute getGenEditionContext_DescriptorsContributorID() { - return (EAttribute)genEditionContextEClass.getEStructuralFeatures().get(3); - } - - /** - * - * - * @generated - */ - public EAttribute getGenEditionContext_DescriptorsGenericPropertiesViews() { - return (EAttribute)genEditionContextEClass.getEStructuralFeatures().get(4); - } - - /** - * - * - * @generated - */ - public EAttribute getGenEditionContext_GmfPropertiesViews() { - return (EAttribute)genEditionContextEClass.getEStructuralFeatures().get(5); - } - - /** - * - * - * @generated - */ - public EAttribute getGenEditionContext_GenerateJunitTestCases() { - return (EAttribute)genEditionContextEClass.getEStructuralFeatures().get(6); - } - - /** - * - * - * @generated - */ - public EAttribute getGenEditionContext_LeafComponentsSuperClass() { - return (EAttribute)genEditionContextEClass.getEStructuralFeatures().get(7); - } - - /** - * - * - * @generated - */ - public EAttribute getGenEditionContext_PropertiesEditingProvidersSuperClass() { - return (EAttribute)genEditionContextEClass.getEStructuralFeatures().get(8); - } - - /** - * - * - * @generated - */ - public EClass getEEFGenModelReference() { - return eefGenModelReferenceEClass; - } - - /** - * - * - * @generated - */ - public EReference getEEFGenModelReference_ReferencedContext() { - return (EReference)eefGenModelReferenceEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getEEFGenModel() { - return eefGenModelEClass; - } - - /** - * - * - * @generated - */ - public EReference getEEFGenModel_EditionContexts() { - return (EReference)eefGenModelEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getEEFGenModel_ViewsRepositories() { - return (EReference)eefGenModelEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EAttribute getEEFGenModel_GenDirectory() { - return (EAttribute)eefGenModelEClass.getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EAttribute getEEFGenModel_Author() { - return (EAttribute)eefGenModelEClass.getEStructuralFeatures().get(3); - } - - /** - * - * - * @generated - */ - public EAttribute getEEFGenModel_License() { - return (EAttribute)eefGenModelEClass.getEStructuralFeatures().get(4); - } - - /** - * - * - * @generated - */ - public EReference getEEFGenModel_References() { - return (EReference)eefGenModelEClass.getEStructuralFeatures().get(5); - } - - /** - * - * - * @generated - */ - public EAttribute getEEFGenModel_TestsGenDirectory() { - return (EAttribute)eefGenModelEClass.getEStructuralFeatures().get(6); - } - - /** - * - * - * @generated - */ - public EAttribute getEEFGenModel_UseJMergeForUserCode() { - return (EAttribute)eefGenModelEClass.getEStructuralFeatures().get(7); - } - - /** - * - * - * @generated - */ - public EClass getGenViewsRepository() { - return genViewsRepositoryEClass; - } - - /** - * - * - * @generated - */ - public EReference getGenViewsRepository_ViewsRepository() { - return (EReference)genViewsRepositoryEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EAttribute getGenViewsRepository_BasePackage() { - return (EAttribute)genViewsRepositoryEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EAttribute getGenViewsRepository_SwtViews() { - return (EAttribute)genViewsRepositoryEClass.getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EAttribute getGenViewsRepository_FormViews() { - return (EAttribute)genViewsRepositoryEClass.getEStructuralFeatures().get(3); - } - - /** - * - * - * @generated - */ - public EAttribute getGenViewsRepository_HelpStrategy() { - return (EAttribute)genViewsRepositoryEClass.getEStructuralFeatures().get(4); - } - - /** - * - * - * @generated - */ - public EReference getGenViewsRepository_EefGenModel() { - return (EReference)genViewsRepositoryEClass.getEStructuralFeatures().get(5); - } - - /** - * - * - * @generated - */ - public EAttribute getGenViewsRepository_PartsSuperClass() { - return (EAttribute)genViewsRepositoryEClass.getEStructuralFeatures().get(6); - } - - /** - * - * - * @generated - */ - public EAttribute getGenViewsRepository_FormsSuperClass() { - return (EAttribute)genViewsRepositoryEClass.getEStructuralFeatures().get(7); - } - - /** - * - * - * @generated - */ - public EEnum getHELP_STRATEGY() { - return helP_STRATEGYEEnum; - } - - /** - * - * - * @generated - */ - public EEFGenFactory getEEFGenFactory() { - return (EEFGenFactory)getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) return; - isCreated = true; - - // Create classes and their features - genEditionContextEClass = createEClass(GEN_EDITION_CONTEXT); - createEReference(genEditionContextEClass, GEN_EDITION_CONTEXT__PROPERTIES_EDITION_CONTEXT); - createEAttribute(genEditionContextEClass, GEN_EDITION_CONTEXT__BASE_PACKAGE); - createEReference(genEditionContextEClass, GEN_EDITION_CONTEXT__EEF_GEN_MODEL); - createEAttribute(genEditionContextEClass, GEN_EDITION_CONTEXT__DESCRIPTORS_CONTRIBUTOR_ID); - createEAttribute(genEditionContextEClass, GEN_EDITION_CONTEXT__DESCRIPTORS_GENERIC_PROPERTIES_VIEWS); - createEAttribute(genEditionContextEClass, GEN_EDITION_CONTEXT__GMF_PROPERTIES_VIEWS); - createEAttribute(genEditionContextEClass, GEN_EDITION_CONTEXT__GENERATE_JUNIT_TEST_CASES); - createEAttribute(genEditionContextEClass, GEN_EDITION_CONTEXT__LEAF_COMPONENTS_SUPER_CLASS); - createEAttribute(genEditionContextEClass, GEN_EDITION_CONTEXT__PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS); - - eefGenModelReferenceEClass = createEClass(EEF_GEN_MODEL_REFERENCE); - createEReference(eefGenModelReferenceEClass, EEF_GEN_MODEL_REFERENCE__REFERENCED_CONTEXT); - - eefGenModelEClass = createEClass(EEF_GEN_MODEL); - createEReference(eefGenModelEClass, EEF_GEN_MODEL__EDITION_CONTEXTS); - createEReference(eefGenModelEClass, EEF_GEN_MODEL__VIEWS_REPOSITORIES); - createEAttribute(eefGenModelEClass, EEF_GEN_MODEL__GEN_DIRECTORY); - createEAttribute(eefGenModelEClass, EEF_GEN_MODEL__AUTHOR); - createEAttribute(eefGenModelEClass, EEF_GEN_MODEL__LICENSE); - createEReference(eefGenModelEClass, EEF_GEN_MODEL__REFERENCES); - createEAttribute(eefGenModelEClass, EEF_GEN_MODEL__TESTS_GEN_DIRECTORY); - createEAttribute(eefGenModelEClass, EEF_GEN_MODEL__USE_JMERGE_FOR_USER_CODE); - - genViewsRepositoryEClass = createEClass(GEN_VIEWS_REPOSITORY); - createEReference(genViewsRepositoryEClass, GEN_VIEWS_REPOSITORY__VIEWS_REPOSITORY); - createEAttribute(genViewsRepositoryEClass, GEN_VIEWS_REPOSITORY__BASE_PACKAGE); - createEAttribute(genViewsRepositoryEClass, GEN_VIEWS_REPOSITORY__SWT_VIEWS); - createEAttribute(genViewsRepositoryEClass, GEN_VIEWS_REPOSITORY__FORM_VIEWS); - createEAttribute(genViewsRepositoryEClass, GEN_VIEWS_REPOSITORY__HELP_STRATEGY); - createEReference(genViewsRepositoryEClass, GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL); - createEAttribute(genViewsRepositoryEClass, GEN_VIEWS_REPOSITORY__PARTS_SUPER_CLASS); - createEAttribute(genViewsRepositoryEClass, GEN_VIEWS_REPOSITORY__FORMS_SUPER_CLASS); - - // Create enums - helP_STRATEGYEEnum = createEEnum(HELP_STRATEGY); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - ComponentsPackage theComponentsPackage = (ComponentsPackage)EPackage.Registry.INSTANCE.getEPackage(ComponentsPackage.eNS_URI); - ViewsPackage theViewsPackage = (ViewsPackage)EPackage.Registry.INSTANCE.getEPackage(ViewsPackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - - // Initialize classes and features; add operations and parameters - initEClass(genEditionContextEClass, GenEditionContext.class, "GenEditionContext", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getGenEditionContext_PropertiesEditionContext(), theComponentsPackage.getPropertiesEditionContext(), null, "PropertiesEditionContext", null, 1, 1, GenEditionContext.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenEditionContext_BasePackage(), ecorePackage.getEString(), "basePackage", null, 0, 1, GenEditionContext.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getGenEditionContext_EefGenModel(), this.getEEFGenModel(), this.getEEFGenModel_EditionContexts(), "eefGenModel", null, 1, 1, GenEditionContext.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenEditionContext_DescriptorsContributorID(), ecorePackage.getEString(), "descriptorsContributorID", null, 0, 1, GenEditionContext.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenEditionContext_DescriptorsGenericPropertiesViews(), ecorePackage.getEBoolean(), "descriptorsGenericPropertiesViews", null, 0, 1, GenEditionContext.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenEditionContext_GmfPropertiesViews(), ecorePackage.getEBoolean(), "gmfPropertiesViews", null, 0, 1, GenEditionContext.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenEditionContext_GenerateJunitTestCases(), ecorePackage.getEBoolean(), "generateJunitTestCases", null, 0, 1, GenEditionContext.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenEditionContext_LeafComponentsSuperClass(), ecorePackage.getEString(), "leafComponentsSuperClass", null, 0, 1, GenEditionContext.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenEditionContext_PropertiesEditingProvidersSuperClass(), ecorePackage.getEString(), "propertiesEditingProvidersSuperClass", null, 0, 1, GenEditionContext.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(eefGenModelReferenceEClass, EEFGenModelReference.class, "EEFGenModelReference", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getEEFGenModelReference_ReferencedContext(), this.getEEFGenModel(), null, "referencedContext", null, 1, 1, EEFGenModelReference.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(eefGenModelEClass, EEFGenModel.class, "EEFGenModel", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getEEFGenModel_EditionContexts(), this.getGenEditionContext(), this.getGenEditionContext_EefGenModel(), "editionContexts", null, 0, -1, EEFGenModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getEEFGenModel_ViewsRepositories(), this.getGenViewsRepository(), this.getGenViewsRepository_EefGenModel(), "viewsRepositories", null, 0, -1, EEFGenModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getEEFGenModel_GenDirectory(), ecorePackage.getEString(), "genDirectory", null, 1, 1, EEFGenModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getEEFGenModel_Author(), ecorePackage.getEString(), "author", null, 0, 1, EEFGenModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getEEFGenModel_License(), ecorePackage.getEString(), "license", null, 0, 1, EEFGenModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getEEFGenModel_References(), this.getEEFGenModelReference(), null, "references", null, 0, -1, EEFGenModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getEEFGenModel_TestsGenDirectory(), ecorePackage.getEString(), "testsGenDirectory", null, 0, 1, EEFGenModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getEEFGenModel_UseJMergeForUserCode(), ecorePackage.getEBoolean(), "useJMergeForUserCode", "false", 0, 1, EEFGenModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(genViewsRepositoryEClass, GenViewsRepository.class, "GenViewsRepository", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getGenViewsRepository_ViewsRepository(), theViewsPackage.getViewsRepository(), null, "viewsRepository", null, 1, 1, GenViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenViewsRepository_BasePackage(), ecorePackage.getEString(), "basePackage", null, 0, 1, GenViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenViewsRepository_SwtViews(), ecorePackage.getEBoolean(), "swtViews", null, 0, 1, GenViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenViewsRepository_FormViews(), ecorePackage.getEBoolean(), "formViews", null, 0, 1, GenViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenViewsRepository_HelpStrategy(), this.getHELP_STRATEGY(), "helpStrategy", null, 1, 1, GenViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getGenViewsRepository_EefGenModel(), this.getEEFGenModel(), this.getEEFGenModel_ViewsRepositories(), "eefGenModel", null, 1, 1, GenViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenViewsRepository_PartsSuperClass(), ecorePackage.getEString(), "partsSuperClass", null, 0, 1, GenViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getGenViewsRepository_FormsSuperClass(), ecorePackage.getEString(), "formsSuperClass", null, 0, 1, GenViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - // Initialize enums and add enum literals - initEEnum(helP_STRATEGYEEnum, org.eclipse.emf.eef.EEFGen.HELP_STRATEGY.class, "HELP_STRATEGY"); - addEEnumLiteral(helP_STRATEGYEEnum, org.eclipse.emf.eef.EEFGen.HELP_STRATEGY.GENMODEL); - addEEnumLiteral(helP_STRATEGYEEnum, org.eclipse.emf.eef.EEFGen.HELP_STRATEGY.ECOREMODEL); - - // Create resource - createResource(eNS_URI); - } - -} //EEFGenPackageImpl diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/GenEditionContextImpl.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/GenEditionContextImpl.java deleted file mode 100644 index 54644f93c..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/GenEditionContextImpl.java +++ /dev/null @@ -1,653 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.components.PropertiesEditionContext; - -/** - * - * An implementation of the model object 'Gen Edition Context'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl#getPropertiesEditionContext Properties Edition Context}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl#getBasePackage Base Package}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl#getEefGenModel Eef Gen Model}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl#getDescriptorsContributorID Descriptors Contributor ID}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl#isDescriptorsGenericPropertiesViews Descriptors Generic Properties Views}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl#isGmfPropertiesViews Gmf Properties Views}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl#isGenerateJunitTestCases Generate Junit Test Cases}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl#getLeafComponentsSuperClass Leaf Components Super Class}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenEditionContextImpl#getPropertiesEditingProvidersSuperClass Properties Editing Providers Super Class}
  • - *
- *

- * - * @generated - */ -public class GenEditionContextImpl extends EObjectImpl implements GenEditionContext { - /** - * The cached value of the '{@link #getPropertiesEditionContext() Properties Edition Context}' reference. - * - * - * @see #getPropertiesEditionContext() - * @generated - * @ordered - */ - protected PropertiesEditionContext propertiesEditionContext; - - /** - * The default value of the '{@link #getBasePackage() Base Package}' attribute. - * - * - * @see #getBasePackage() - * @generated - * @ordered - */ - protected static final String BASE_PACKAGE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getBasePackage() Base Package}' attribute. - * - * - * @see #getBasePackage() - * @generated - * @ordered - */ - protected String basePackage = BASE_PACKAGE_EDEFAULT; - - /** - * The default value of the '{@link #getDescriptorsContributorID() Descriptors Contributor ID}' attribute. - * - * - * @see #getDescriptorsContributorID() - * @generated - * @ordered - */ - protected static final String DESCRIPTORS_CONTRIBUTOR_ID_EDEFAULT = null; - - /** - * The cached value of the '{@link #getDescriptorsContributorID() Descriptors Contributor ID}' attribute. - * - * - * @see #getDescriptorsContributorID() - * @generated - * @ordered - */ - protected String descriptorsContributorID = DESCRIPTORS_CONTRIBUTOR_ID_EDEFAULT; - - /** - * The default value of the '{@link #isDescriptorsGenericPropertiesViews() Descriptors Generic Properties Views}' attribute. - * - * - * @see #isDescriptorsGenericPropertiesViews() - * @generated - * @ordered - */ - protected static final boolean DESCRIPTORS_GENERIC_PROPERTIES_VIEWS_EDEFAULT = false; - - /** - * The cached value of the '{@link #isDescriptorsGenericPropertiesViews() Descriptors Generic Properties Views}' attribute. - * - * - * @see #isDescriptorsGenericPropertiesViews() - * @generated - * @ordered - */ - protected boolean descriptorsGenericPropertiesViews = DESCRIPTORS_GENERIC_PROPERTIES_VIEWS_EDEFAULT; - - /** - * The default value of the '{@link #isGmfPropertiesViews() Gmf Properties Views}' attribute. - * - * - * @see #isGmfPropertiesViews() - * @generated - * @ordered - */ - protected static final boolean GMF_PROPERTIES_VIEWS_EDEFAULT = false; - - /** - * The cached value of the '{@link #isGmfPropertiesViews() Gmf Properties Views}' attribute. - * - * - * @see #isGmfPropertiesViews() - * @generated - * @ordered - */ - protected boolean gmfPropertiesViews = GMF_PROPERTIES_VIEWS_EDEFAULT; - - /** - * The default value of the '{@link #isGenerateJunitTestCases() Generate Junit Test Cases}' attribute. - * - * - * @see #isGenerateJunitTestCases() - * @generated - * @ordered - */ - protected static final boolean GENERATE_JUNIT_TEST_CASES_EDEFAULT = false; - - /** - * The cached value of the '{@link #isGenerateJunitTestCases() Generate Junit Test Cases}' attribute. - * - * - * @see #isGenerateJunitTestCases() - * @generated - * @ordered - */ - protected boolean generateJunitTestCases = GENERATE_JUNIT_TEST_CASES_EDEFAULT; - - /** - * The default value of the '{@link #getLeafComponentsSuperClass() Leaf Components Super Class}' attribute. - * - * - * @see #getLeafComponentsSuperClass() - * @generated - * @ordered - */ - protected static final String LEAF_COMPONENTS_SUPER_CLASS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getLeafComponentsSuperClass() Leaf Components Super Class}' attribute. - * - * - * @see #getLeafComponentsSuperClass() - * @generated - * @ordered - */ - protected String leafComponentsSuperClass = LEAF_COMPONENTS_SUPER_CLASS_EDEFAULT; - - /** - * The default value of the '{@link #getPropertiesEditingProvidersSuperClass() Properties Editing Providers Super Class}' attribute. - * - * - * @see #getPropertiesEditingProvidersSuperClass() - * @generated - * @ordered - */ - protected static final String PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getPropertiesEditingProvidersSuperClass() Properties Editing Providers Super Class}' attribute. - * - * - * @see #getPropertiesEditingProvidersSuperClass() - * @generated - * @ordered - */ - protected String propertiesEditingProvidersSuperClass = PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS_EDEFAULT; - - /** - * - * - * @generated - */ - protected GenEditionContextImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFGenPackage.Literals.GEN_EDITION_CONTEXT; - } - - /** - * - * - * @generated - */ - public PropertiesEditionContext getPropertiesEditionContext() { - if (propertiesEditionContext != null && propertiesEditionContext.eIsProxy()) { - InternalEObject oldPropertiesEditionContext = (InternalEObject)propertiesEditionContext; - propertiesEditionContext = (PropertiesEditionContext)eResolveProxy(oldPropertiesEditionContext); - if (propertiesEditionContext != oldPropertiesEditionContext) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITION_CONTEXT, oldPropertiesEditionContext, propertiesEditionContext)); - } - } - return propertiesEditionContext; - } - - /** - * - * - * @generated - */ - public PropertiesEditionContext basicGetPropertiesEditionContext() { - return propertiesEditionContext; - } - - /** - * - * - * @generated - */ - public void setPropertiesEditionContext(PropertiesEditionContext newPropertiesEditionContext) { - PropertiesEditionContext oldPropertiesEditionContext = propertiesEditionContext; - propertiesEditionContext = newPropertiesEditionContext; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITION_CONTEXT, oldPropertiesEditionContext, propertiesEditionContext)); - } - - /** - * - * - * @generated - */ - public String getBasePackage() { - return basePackage; - } - - /** - * - * - * @generated - */ - public void setBasePackage(String newBasePackage) { - String oldBasePackage = basePackage; - basePackage = newBasePackage; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_EDITION_CONTEXT__BASE_PACKAGE, oldBasePackage, basePackage)); - } - - /** - * - * - * @generated - */ - public EEFGenModel getEefGenModel() { - if (eContainerFeatureID() != EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL) return null; - return (EEFGenModel)eContainer(); - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetEefGenModel(EEFGenModel newEefGenModel, NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject)newEefGenModel, EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL, msgs); - return msgs; - } - - /** - * - * - * @generated - */ - public void setEefGenModel(EEFGenModel newEefGenModel) { - if (newEefGenModel != eInternalContainer() || (eContainerFeatureID() != EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL && newEefGenModel != null)) { - if (EcoreUtil.isAncestor(this, newEefGenModel)) - throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); - NotificationChain msgs = null; - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - if (newEefGenModel != null) - msgs = ((InternalEObject)newEefGenModel).eInverseAdd(this, EEFGenPackage.EEF_GEN_MODEL__EDITION_CONTEXTS, EEFGenModel.class, msgs); - msgs = basicSetEefGenModel(newEefGenModel, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL, newEefGenModel, newEefGenModel)); - } - - /** - * - * - * @generated - */ - public String getDescriptorsContributorID() { - return descriptorsContributorID; - } - - /** - * - * - * @generated - */ - public void setDescriptorsContributorID(String newDescriptorsContributorID) { - String oldDescriptorsContributorID = descriptorsContributorID; - descriptorsContributorID = newDescriptorsContributorID; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_CONTRIBUTOR_ID, oldDescriptorsContributorID, descriptorsContributorID)); - } - - /** - * - * - * @generated - */ - public boolean isDescriptorsGenericPropertiesViews() { - return descriptorsGenericPropertiesViews; - } - - /** - * - * - * @generated - */ - public void setDescriptorsGenericPropertiesViews(boolean newDescriptorsGenericPropertiesViews) { - boolean oldDescriptorsGenericPropertiesViews = descriptorsGenericPropertiesViews; - descriptorsGenericPropertiesViews = newDescriptorsGenericPropertiesViews; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_GENERIC_PROPERTIES_VIEWS, oldDescriptorsGenericPropertiesViews, descriptorsGenericPropertiesViews)); - } - - /** - * - * - * @generated - */ - public boolean isGmfPropertiesViews() { - return gmfPropertiesViews; - } - - /** - * - * - * @generated - */ - public void setGmfPropertiesViews(boolean newGmfPropertiesViews) { - boolean oldGmfPropertiesViews = gmfPropertiesViews; - gmfPropertiesViews = newGmfPropertiesViews; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_EDITION_CONTEXT__GMF_PROPERTIES_VIEWS, oldGmfPropertiesViews, gmfPropertiesViews)); - } - - /** - * - * - * @generated - */ - public boolean isGenerateJunitTestCases() { - return generateJunitTestCases; - } - - /** - * - * - * @generated - */ - public void setGenerateJunitTestCases(boolean newGenerateJunitTestCases) { - boolean oldGenerateJunitTestCases = generateJunitTestCases; - generateJunitTestCases = newGenerateJunitTestCases; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_EDITION_CONTEXT__GENERATE_JUNIT_TEST_CASES, oldGenerateJunitTestCases, generateJunitTestCases)); - } - - /** - * - * - * @generated - */ - public String getLeafComponentsSuperClass() { - return leafComponentsSuperClass; - } - - /** - * - * - * @generated - */ - public void setLeafComponentsSuperClass(String newLeafComponentsSuperClass) { - String oldLeafComponentsSuperClass = leafComponentsSuperClass; - leafComponentsSuperClass = newLeafComponentsSuperClass; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_EDITION_CONTEXT__LEAF_COMPONENTS_SUPER_CLASS, oldLeafComponentsSuperClass, leafComponentsSuperClass)); - } - - /** - * - * - * @generated - */ - public String getPropertiesEditingProvidersSuperClass() { - return propertiesEditingProvidersSuperClass; - } - - /** - * - * - * @generated - */ - public void setPropertiesEditingProvidersSuperClass(String newPropertiesEditingProvidersSuperClass) { - String oldPropertiesEditingProvidersSuperClass = propertiesEditingProvidersSuperClass; - propertiesEditingProvidersSuperClass = newPropertiesEditingProvidersSuperClass; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS, oldPropertiesEditingProvidersSuperClass, propertiesEditingProvidersSuperClass)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL: - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - return basicSetEefGenModel((EEFGenModel)otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL: - return basicSetEefGenModel(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { - switch (eContainerFeatureID()) { - case EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL: - return eInternalContainer().eInverseRemove(this, EEFGenPackage.EEF_GEN_MODEL__EDITION_CONTEXTS, EEFGenModel.class, msgs); - } - return super.eBasicRemoveFromContainerFeature(msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITION_CONTEXT: - if (resolve) return getPropertiesEditionContext(); - return basicGetPropertiesEditionContext(); - case EEFGenPackage.GEN_EDITION_CONTEXT__BASE_PACKAGE: - return getBasePackage(); - case EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL: - return getEefGenModel(); - case EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_CONTRIBUTOR_ID: - return getDescriptorsContributorID(); - case EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_GENERIC_PROPERTIES_VIEWS: - return isDescriptorsGenericPropertiesViews(); - case EEFGenPackage.GEN_EDITION_CONTEXT__GMF_PROPERTIES_VIEWS: - return isGmfPropertiesViews(); - case EEFGenPackage.GEN_EDITION_CONTEXT__GENERATE_JUNIT_TEST_CASES: - return isGenerateJunitTestCases(); - case EEFGenPackage.GEN_EDITION_CONTEXT__LEAF_COMPONENTS_SUPER_CLASS: - return getLeafComponentsSuperClass(); - case EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS: - return getPropertiesEditingProvidersSuperClass(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITION_CONTEXT: - setPropertiesEditionContext((PropertiesEditionContext)newValue); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__BASE_PACKAGE: - setBasePackage((String)newValue); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL: - setEefGenModel((EEFGenModel)newValue); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_CONTRIBUTOR_ID: - setDescriptorsContributorID((String)newValue); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_GENERIC_PROPERTIES_VIEWS: - setDescriptorsGenericPropertiesViews((Boolean)newValue); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__GMF_PROPERTIES_VIEWS: - setGmfPropertiesViews((Boolean)newValue); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__GENERATE_JUNIT_TEST_CASES: - setGenerateJunitTestCases((Boolean)newValue); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__LEAF_COMPONENTS_SUPER_CLASS: - setLeafComponentsSuperClass((String)newValue); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS: - setPropertiesEditingProvidersSuperClass((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITION_CONTEXT: - setPropertiesEditionContext((PropertiesEditionContext)null); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__BASE_PACKAGE: - setBasePackage(BASE_PACKAGE_EDEFAULT); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL: - setEefGenModel((EEFGenModel)null); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_CONTRIBUTOR_ID: - setDescriptorsContributorID(DESCRIPTORS_CONTRIBUTOR_ID_EDEFAULT); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_GENERIC_PROPERTIES_VIEWS: - setDescriptorsGenericPropertiesViews(DESCRIPTORS_GENERIC_PROPERTIES_VIEWS_EDEFAULT); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__GMF_PROPERTIES_VIEWS: - setGmfPropertiesViews(GMF_PROPERTIES_VIEWS_EDEFAULT); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__GENERATE_JUNIT_TEST_CASES: - setGenerateJunitTestCases(GENERATE_JUNIT_TEST_CASES_EDEFAULT); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__LEAF_COMPONENTS_SUPER_CLASS: - setLeafComponentsSuperClass(LEAF_COMPONENTS_SUPER_CLASS_EDEFAULT); - return; - case EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS: - setPropertiesEditingProvidersSuperClass(PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITION_CONTEXT: - return propertiesEditionContext != null; - case EEFGenPackage.GEN_EDITION_CONTEXT__BASE_PACKAGE: - return BASE_PACKAGE_EDEFAULT == null ? basePackage != null : !BASE_PACKAGE_EDEFAULT.equals(basePackage); - case EEFGenPackage.GEN_EDITION_CONTEXT__EEF_GEN_MODEL: - return getEefGenModel() != null; - case EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_CONTRIBUTOR_ID: - return DESCRIPTORS_CONTRIBUTOR_ID_EDEFAULT == null ? descriptorsContributorID != null : !DESCRIPTORS_CONTRIBUTOR_ID_EDEFAULT.equals(descriptorsContributorID); - case EEFGenPackage.GEN_EDITION_CONTEXT__DESCRIPTORS_GENERIC_PROPERTIES_VIEWS: - return descriptorsGenericPropertiesViews != DESCRIPTORS_GENERIC_PROPERTIES_VIEWS_EDEFAULT; - case EEFGenPackage.GEN_EDITION_CONTEXT__GMF_PROPERTIES_VIEWS: - return gmfPropertiesViews != GMF_PROPERTIES_VIEWS_EDEFAULT; - case EEFGenPackage.GEN_EDITION_CONTEXT__GENERATE_JUNIT_TEST_CASES: - return generateJunitTestCases != GENERATE_JUNIT_TEST_CASES_EDEFAULT; - case EEFGenPackage.GEN_EDITION_CONTEXT__LEAF_COMPONENTS_SUPER_CLASS: - return LEAF_COMPONENTS_SUPER_CLASS_EDEFAULT == null ? leafComponentsSuperClass != null : !LEAF_COMPONENTS_SUPER_CLASS_EDEFAULT.equals(leafComponentsSuperClass); - case EEFGenPackage.GEN_EDITION_CONTEXT__PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS: - return PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS_EDEFAULT == null ? propertiesEditingProvidersSuperClass != null : !PROPERTIES_EDITING_PROVIDERS_SUPER_CLASS_EDEFAULT.equals(propertiesEditingProvidersSuperClass); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (basePackage: "); - result.append(basePackage); - result.append(", descriptorsContributorID: "); - result.append(descriptorsContributorID); - result.append(", descriptorsGenericPropertiesViews: "); - result.append(descriptorsGenericPropertiesViews); - result.append(", gmfPropertiesViews: "); - result.append(gmfPropertiesViews); - result.append(", generateJunitTestCases: "); - result.append(generateJunitTestCases); - result.append(", leafComponentsSuperClass: "); - result.append(leafComponentsSuperClass); - result.append(", propertiesEditingProvidersSuperClass: "); - result.append(propertiesEditingProvidersSuperClass); - result.append(')'); - return result.toString(); - } - -} //GenEditionContextImpl diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/GenViewsRepositoryImpl.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/GenViewsRepositoryImpl.java deleted file mode 100644 index 0679f5508..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/impl/GenViewsRepositoryImpl.java +++ /dev/null @@ -1,600 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; -import org.eclipse.emf.eef.EEFGen.HELP_STRATEGY; -import org.eclipse.emf.eef.views.ViewsRepository; - -/** - * - * An implementation of the model object 'Gen Views Repository'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl#getViewsRepository Views Repository}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl#getBasePackage Base Package}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl#isSwtViews Swt Views}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl#isFormViews Form Views}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl#getHelpStrategy Help Strategy}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl#getEefGenModel Eef Gen Model}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl#getPartsSuperClass Parts Super Class}
  • - *
  • {@link org.eclipse.emf.eef.EEFGen.impl.GenViewsRepositoryImpl#getFormsSuperClass Forms Super Class}
  • - *
- *

- * - * @generated - */ -public class GenViewsRepositoryImpl extends EObjectImpl implements GenViewsRepository { - /** - * The cached value of the '{@link #getViewsRepository() Views Repository}' reference. - * - * - * @see #getViewsRepository() - * @generated - * @ordered - */ - protected ViewsRepository viewsRepository; - - /** - * The default value of the '{@link #getBasePackage() Base Package}' attribute. - * - * - * @see #getBasePackage() - * @generated - * @ordered - */ - protected static final String BASE_PACKAGE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getBasePackage() Base Package}' attribute. - * - * - * @see #getBasePackage() - * @generated - * @ordered - */ - protected String basePackage = BASE_PACKAGE_EDEFAULT; - - /** - * The default value of the '{@link #isSwtViews() Swt Views}' attribute. - * - * - * @see #isSwtViews() - * @generated - * @ordered - */ - protected static final boolean SWT_VIEWS_EDEFAULT = false; - - /** - * The cached value of the '{@link #isSwtViews() Swt Views}' attribute. - * - * - * @see #isSwtViews() - * @generated - * @ordered - */ - protected boolean swtViews = SWT_VIEWS_EDEFAULT; - - /** - * The default value of the '{@link #isFormViews() Form Views}' attribute. - * - * - * @see #isFormViews() - * @generated - * @ordered - */ - protected static final boolean FORM_VIEWS_EDEFAULT = false; - - /** - * The cached value of the '{@link #isFormViews() Form Views}' attribute. - * - * - * @see #isFormViews() - * @generated - * @ordered - */ - protected boolean formViews = FORM_VIEWS_EDEFAULT; - - /** - * The default value of the '{@link #getHelpStrategy() Help Strategy}' attribute. - * - * - * @see #getHelpStrategy() - * @generated - * @ordered - */ - protected static final HELP_STRATEGY HELP_STRATEGY_EDEFAULT = HELP_STRATEGY.GENMODEL; - - /** - * The cached value of the '{@link #getHelpStrategy() Help Strategy}' attribute. - * - * - * @see #getHelpStrategy() - * @generated - * @ordered - */ - protected HELP_STRATEGY helpStrategy = HELP_STRATEGY_EDEFAULT; - - /** - * The default value of the '{@link #getPartsSuperClass() Parts Super Class}' attribute. - * - * - * @see #getPartsSuperClass() - * @generated - * @ordered - */ - protected static final String PARTS_SUPER_CLASS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getPartsSuperClass() Parts Super Class}' attribute. - * - * - * @see #getPartsSuperClass() - * @generated - * @ordered - */ - protected String partsSuperClass = PARTS_SUPER_CLASS_EDEFAULT; - - /** - * The default value of the '{@link #getFormsSuperClass() Forms Super Class}' attribute. - * - * - * @see #getFormsSuperClass() - * @generated - * @ordered - */ - protected static final String FORMS_SUPER_CLASS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getFormsSuperClass() Forms Super Class}' attribute. - * - * - * @see #getFormsSuperClass() - * @generated - * @ordered - */ - protected String formsSuperClass = FORMS_SUPER_CLASS_EDEFAULT; - - /** - * - * - * @generated - */ - protected GenViewsRepositoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFGenPackage.Literals.GEN_VIEWS_REPOSITORY; - } - - /** - * - * - * @generated - */ - public ViewsRepository getViewsRepository() { - if (viewsRepository != null && viewsRepository.eIsProxy()) { - InternalEObject oldViewsRepository = (InternalEObject)viewsRepository; - viewsRepository = (ViewsRepository)eResolveProxy(oldViewsRepository); - if (viewsRepository != oldViewsRepository) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFGenPackage.GEN_VIEWS_REPOSITORY__VIEWS_REPOSITORY, oldViewsRepository, viewsRepository)); - } - } - return viewsRepository; - } - - /** - * - * - * @generated - */ - public ViewsRepository basicGetViewsRepository() { - return viewsRepository; - } - - /** - * - * - * @generated - */ - public void setViewsRepository(ViewsRepository newViewsRepository) { - ViewsRepository oldViewsRepository = viewsRepository; - viewsRepository = newViewsRepository; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_VIEWS_REPOSITORY__VIEWS_REPOSITORY, oldViewsRepository, viewsRepository)); - } - - /** - * - * - * @generated - */ - public String getBasePackage() { - return basePackage; - } - - /** - * - * - * @generated - */ - public void setBasePackage(String newBasePackage) { - String oldBasePackage = basePackage; - basePackage = newBasePackage; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_VIEWS_REPOSITORY__BASE_PACKAGE, oldBasePackage, basePackage)); - } - - /** - * - * - * @generated - */ - public boolean isSwtViews() { - return swtViews; - } - - /** - * - * - * @generated - */ - public void setSwtViews(boolean newSwtViews) { - boolean oldSwtViews = swtViews; - swtViews = newSwtViews; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_VIEWS_REPOSITORY__SWT_VIEWS, oldSwtViews, swtViews)); - } - - /** - * - * - * @generated - */ - public boolean isFormViews() { - return formViews; - } - - /** - * - * - * @generated - */ - public void setFormViews(boolean newFormViews) { - boolean oldFormViews = formViews; - formViews = newFormViews; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_VIEWS_REPOSITORY__FORM_VIEWS, oldFormViews, formViews)); - } - - /** - * - * - * @generated - */ - public HELP_STRATEGY getHelpStrategy() { - return helpStrategy; - } - - /** - * - * - * @generated - */ - public void setHelpStrategy(HELP_STRATEGY newHelpStrategy) { - HELP_STRATEGY oldHelpStrategy = helpStrategy; - helpStrategy = newHelpStrategy == null ? HELP_STRATEGY_EDEFAULT : newHelpStrategy; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_VIEWS_REPOSITORY__HELP_STRATEGY, oldHelpStrategy, helpStrategy)); - } - - /** - * - * - * @generated - */ - public EEFGenModel getEefGenModel() { - if (eContainerFeatureID() != EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL) return null; - return (EEFGenModel)eContainer(); - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetEefGenModel(EEFGenModel newEefGenModel, NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject)newEefGenModel, EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL, msgs); - return msgs; - } - - /** - * - * - * @generated - */ - public void setEefGenModel(EEFGenModel newEefGenModel) { - if (newEefGenModel != eInternalContainer() || (eContainerFeatureID() != EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL && newEefGenModel != null)) { - if (EcoreUtil.isAncestor(this, newEefGenModel)) - throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); - NotificationChain msgs = null; - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - if (newEefGenModel != null) - msgs = ((InternalEObject)newEefGenModel).eInverseAdd(this, EEFGenPackage.EEF_GEN_MODEL__VIEWS_REPOSITORIES, EEFGenModel.class, msgs); - msgs = basicSetEefGenModel(newEefGenModel, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL, newEefGenModel, newEefGenModel)); - } - - /** - * - * - * @generated - */ - public String getPartsSuperClass() { - return partsSuperClass; - } - - /** - * - * - * @generated - */ - public void setPartsSuperClass(String newPartsSuperClass) { - String oldPartsSuperClass = partsSuperClass; - partsSuperClass = newPartsSuperClass; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_VIEWS_REPOSITORY__PARTS_SUPER_CLASS, oldPartsSuperClass, partsSuperClass)); - } - - /** - * - * - * @generated - */ - public String getFormsSuperClass() { - return formsSuperClass; - } - - /** - * - * - * @generated - */ - public void setFormsSuperClass(String newFormsSuperClass) { - String oldFormsSuperClass = formsSuperClass; - formsSuperClass = newFormsSuperClass; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFGenPackage.GEN_VIEWS_REPOSITORY__FORMS_SUPER_CLASS, oldFormsSuperClass, formsSuperClass)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL: - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - return basicSetEefGenModel((EEFGenModel)otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL: - return basicSetEefGenModel(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { - switch (eContainerFeatureID()) { - case EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL: - return eInternalContainer().eInverseRemove(this, EEFGenPackage.EEF_GEN_MODEL__VIEWS_REPOSITORIES, EEFGenModel.class, msgs); - } - return super.eBasicRemoveFromContainerFeature(msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFGenPackage.GEN_VIEWS_REPOSITORY__VIEWS_REPOSITORY: - if (resolve) return getViewsRepository(); - return basicGetViewsRepository(); - case EEFGenPackage.GEN_VIEWS_REPOSITORY__BASE_PACKAGE: - return getBasePackage(); - case EEFGenPackage.GEN_VIEWS_REPOSITORY__SWT_VIEWS: - return isSwtViews(); - case EEFGenPackage.GEN_VIEWS_REPOSITORY__FORM_VIEWS: - return isFormViews(); - case EEFGenPackage.GEN_VIEWS_REPOSITORY__HELP_STRATEGY: - return getHelpStrategy(); - case EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL: - return getEefGenModel(); - case EEFGenPackage.GEN_VIEWS_REPOSITORY__PARTS_SUPER_CLASS: - return getPartsSuperClass(); - case EEFGenPackage.GEN_VIEWS_REPOSITORY__FORMS_SUPER_CLASS: - return getFormsSuperClass(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFGenPackage.GEN_VIEWS_REPOSITORY__VIEWS_REPOSITORY: - setViewsRepository((ViewsRepository)newValue); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__BASE_PACKAGE: - setBasePackage((String)newValue); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__SWT_VIEWS: - setSwtViews((Boolean)newValue); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__FORM_VIEWS: - setFormViews((Boolean)newValue); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__HELP_STRATEGY: - setHelpStrategy((HELP_STRATEGY)newValue); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL: - setEefGenModel((EEFGenModel)newValue); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__PARTS_SUPER_CLASS: - setPartsSuperClass((String)newValue); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__FORMS_SUPER_CLASS: - setFormsSuperClass((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFGenPackage.GEN_VIEWS_REPOSITORY__VIEWS_REPOSITORY: - setViewsRepository((ViewsRepository)null); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__BASE_PACKAGE: - setBasePackage(BASE_PACKAGE_EDEFAULT); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__SWT_VIEWS: - setSwtViews(SWT_VIEWS_EDEFAULT); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__FORM_VIEWS: - setFormViews(FORM_VIEWS_EDEFAULT); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__HELP_STRATEGY: - setHelpStrategy(HELP_STRATEGY_EDEFAULT); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL: - setEefGenModel((EEFGenModel)null); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__PARTS_SUPER_CLASS: - setPartsSuperClass(PARTS_SUPER_CLASS_EDEFAULT); - return; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__FORMS_SUPER_CLASS: - setFormsSuperClass(FORMS_SUPER_CLASS_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFGenPackage.GEN_VIEWS_REPOSITORY__VIEWS_REPOSITORY: - return viewsRepository != null; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__BASE_PACKAGE: - return BASE_PACKAGE_EDEFAULT == null ? basePackage != null : !BASE_PACKAGE_EDEFAULT.equals(basePackage); - case EEFGenPackage.GEN_VIEWS_REPOSITORY__SWT_VIEWS: - return swtViews != SWT_VIEWS_EDEFAULT; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__FORM_VIEWS: - return formViews != FORM_VIEWS_EDEFAULT; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__HELP_STRATEGY: - return helpStrategy != HELP_STRATEGY_EDEFAULT; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__EEF_GEN_MODEL: - return getEefGenModel() != null; - case EEFGenPackage.GEN_VIEWS_REPOSITORY__PARTS_SUPER_CLASS: - return PARTS_SUPER_CLASS_EDEFAULT == null ? partsSuperClass != null : !PARTS_SUPER_CLASS_EDEFAULT.equals(partsSuperClass); - case EEFGenPackage.GEN_VIEWS_REPOSITORY__FORMS_SUPER_CLASS: - return FORMS_SUPER_CLASS_EDEFAULT == null ? formsSuperClass != null : !FORMS_SUPER_CLASS_EDEFAULT.equals(formsSuperClass); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (basePackage: "); - result.append(basePackage); - result.append(", swtViews: "); - result.append(swtViews); - result.append(", formViews: "); - result.append(formViews); - result.append(", helpStrategy: "); - result.append(helpStrategy); - result.append(", partsSuperClass: "); - result.append(partsSuperClass); - result.append(", formsSuperClass: "); - result.append(formsSuperClass); - result.append(')'); - return result.toString(); - } - -} //GenViewsRepositoryImpl diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/util/EEFGenAdapterFactory.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/util/EEFGenAdapterFactory.java deleted file mode 100644 index d6cfba71c..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/util/EEFGenAdapterFactory.java +++ /dev/null @@ -1,183 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenModelReference; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage - * @generated - */ -public class EEFGenAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static EEFGenPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public EEFGenAdapterFactory() { - if (modelPackage == null) { - modelPackage = EEFGenPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject)object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected EEFGenSwitch modelSwitch = - new EEFGenSwitch() { - @Override - public Adapter caseGenEditionContext(GenEditionContext object) { - return createGenEditionContextAdapter(); - } - @Override - public Adapter caseEEFGenModelReference(EEFGenModelReference object) { - return createEEFGenModelReferenceAdapter(); - } - @Override - public Adapter caseEEFGenModel(EEFGenModel object) { - return createEEFGenModelAdapter(); - } - @Override - public Adapter caseGenViewsRepository(GenViewsRepository object) { - return createGenViewsRepositoryAdapter(); - } - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject)target); - } - - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.EEFGen.GenEditionContext Gen Edition Context}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.EEFGen.GenEditionContext - * @generated - */ - public Adapter createGenEditionContextAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.EEFGen.EEFGenModelReference Model Reference}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModelReference - * @generated - */ - public Adapter createEEFGenModelReferenceAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.EEFGen.EEFGenModel Model}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.EEFGen.EEFGenModel - * @generated - */ - public Adapter createEEFGenModelAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.EEFGen.GenViewsRepository Gen Views Repository}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.EEFGen.GenViewsRepository - * @generated - */ - public Adapter createGenViewsRepositoryAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //EEFGenAdapterFactory diff --git a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/util/EEFGenSwitch.java b/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/util/EEFGenSwitch.java deleted file mode 100644 index 8d2ae159e..000000000 --- a/plugins/org.eclipse.emf.eef.eefgen/src-gen/org/eclipse/emf/eef/EEFGen/util/EEFGenSwitch.java +++ /dev/null @@ -1,200 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.EEFGen.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.EEFGen.EEFGenModel; -import org.eclipse.emf.eef.EEFGen.EEFGenModelReference; -import org.eclipse.emf.eef.EEFGen.EEFGenPackage; -import org.eclipse.emf.eef.EEFGen.GenEditionContext; -import org.eclipse.emf.eef.EEFGen.GenViewsRepository; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.EEFGen.EEFGenPackage - * @generated - */ -public class EEFGenSwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static EEFGenPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public EEFGenSwitch() { - if (modelPackage == null) { - modelPackage = EEFGenPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } - else { - List eSuperTypes = theEClass.getESuperTypes(); - return - eSuperTypes.isEmpty() ? - defaultCase(theEObject) : - doSwitch(eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case EEFGenPackage.GEN_EDITION_CONTEXT: { - GenEditionContext genEditionContext = (GenEditionContext)theEObject; - T result = caseGenEditionContext(genEditionContext); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFGenPackage.EEF_GEN_MODEL_REFERENCE: { - EEFGenModelReference eefGenModelReference = (EEFGenModelReference)theEObject; - T result = caseEEFGenModelReference(eefGenModelReference); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFGenPackage.EEF_GEN_MODEL: { - EEFGenModel eefGenModel = (EEFGenModel)theEObject; - T result = caseEEFGenModel(eefGenModel); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFGenPackage.GEN_VIEWS_REPOSITORY: { - GenViewsRepository genViewsRepository = (GenViewsRepository)theEObject; - T result = caseGenViewsRepository(genViewsRepository); - if (result == null) result = defaultCase(theEObject); - return result; - } - default: return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'Gen Edition Context'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Gen Edition Context'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseGenEditionContext(GenEditionContext object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Model Reference'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Model Reference'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFGenModelReference(EEFGenModelReference object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Model'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Model'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFGenModel(EEFGenModel object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Gen Views Repository'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Gen Views Repository'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseGenViewsRepository(GenViewsRepository object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //EEFGenSwitch diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.classpath b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.classpath deleted file mode 100644 index 304e86186..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.gitignore b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.project b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.project deleted file mode 100644 index f265ae388..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.project +++ /dev/null @@ -1,34 +0,0 @@ - - - org.eclipse.emf.eef.extended.widgets.richtext - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - org.eclipse.pde.api.tools.apiAnalysisBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - org.eclipse.pde.api.tools.apiAnalysisNature - - diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index 416f4fb69..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,11 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.debug.lineNumber=generate -org.eclipse.jdt.core.compiler.debug.localVariable=generate -org.eclipse.jdt.core.compiler.debug.sourceFile=generate -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/META-INF/MANIFEST.MF deleted file mode 100644 index 85f4b527c..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/META-INF/MANIFEST.MF +++ /dev/null @@ -1,12 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Richtext widget -Bundle-SymbolicName: org.eclipse.emf.eef.extended.widgets.richtext -Bundle-Version: 1.5.2.qualifier -Bundle-Vendor: Eclipse Modeling Project -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Require-Bundle: org.eclipse.epf.common;bundle-version="1.5.0";resolution:=optional, - org.eclipse.epf.richtext;bundle-version="1.5.0";resolution:=optional;visibility:=reexport, - org.eclipse.epf.common.html;bundle-version="1.5.0";resolution:=optional -Export-Package: org.eclipse.emf.eef.runtime.ui.widgets.richtext.actions -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/about.html b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/about.html deleted file mode 100755 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/build.properties b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/build.properties deleted file mode 100644 index 4080e4f4c..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/build.properties +++ /dev/null @@ -1,16 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - about.html -src.includes = about.html \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/pom.xml b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/pom.xml deleted file mode 100644 index 264edcbe7..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/pom.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.extended.widgets.richtext - eclipse-plugin - - EEF RichText Widget Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontNameAction.java b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontNameAction.java deleted file mode 100644 index f5dc0c4d9..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontNameAction.java +++ /dev/null @@ -1,72 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.richtext.actions; - -import java.util.Iterator; - -import org.eclipse.epf.richtext.IRichText; -import org.eclipse.epf.richtext.RichTextResources; -import org.eclipse.epf.richtext.actions.FontNameAction; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; - -/** - * @author Goulwen Le Fur - */ -public class EEFFontNameAction extends FontNameAction { - - /** - * @param richText - * @since 1.1 - */ - public EEFFontNameAction(IRichText richText) { - super(richText); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.epf.ui.actions.CComboContributionItem#createControl(org.eclipse.swt.widgets.Composite) - */ - protected Control createControl(Composite parent) { - Control createControl = super.createControl(parent); - selectFontName(); - return createControl; - } - - protected void selectFontName() { - String fontName = richText.getSelected().getFontName(); - if (fontName.equals(RichTextResources.fontNameAction_CSS_Default) - || fontName.equals(RichTextResources.fontNameAction_CSS_Default_Mozilla) - || fontName.equals("default")) { //$NON-NLS-1$ - fontName = RichTextResources.fontNameAction_DefaultFontName; - } - int index = findFontNameInItems(fontName); - if (index == -1) { - index = 0; - } - setNotifyListeners(false); - getCCombo().select(index); - setNotifyListeners(true); - } - - private int findFontNameInItems(String fontName) { - int index = -1; - for (Iterator iter = input.iterator(); iter.hasNext();) { - String font = iter.next(); - index++; - if (font.equalsIgnoreCase(fontName)) { - return index; - } - } - return -1; - } -} diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontSizeAction.java b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontSizeAction.java deleted file mode 100644 index 059a3214f..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontSizeAction.java +++ /dev/null @@ -1,64 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.richtext.actions; - -import org.eclipse.epf.richtext.IRichText; -import org.eclipse.epf.richtext.actions.FontSizeAction; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; - -/** - * @author glefur - */ -public class EEFFontSizeAction extends FontSizeAction { - - /** - * @since 1.1 - */ - public EEFFontSizeAction(IRichText richText) { - super(richText); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.epf.ui.actions.CComboContributionItem#createControl(org.eclipse.swt.widgets.Composite) - */ - protected Control createControl(Composite parent) { - Control createControl = super.createControl(parent); - selectFontSize(); - return createControl; - } - - /** - * - */ - protected void selectFontSize() { - String fontSize = richText.getSelected().getFontSize(); - int index = -1; - if (fontSize.equals("default")) { //$NON-NLS-1$ - index = 0; - } else { - try { - index = Integer.parseInt(fontSize); - } catch (NumberFormatException e) { - // leave index at -1 so nothing is selected - } - } - if (index == -1) { - index = 0; - } - setNotifyListeners(false); - getCCombo().select(index); - setNotifyListeners(true); - } - -} diff --git a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontStyleAction.java b/plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontStyleAction.java deleted file mode 100644 index 56928d921..000000000 --- a/plugins/org.eclipse.emf.eef.extended.widgets.richtext/src/org/eclipse/emf/eef/runtime/ui/widgets/richtext/actions/EEFFontStyleAction.java +++ /dev/null @@ -1,62 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.richtext.actions; - -import java.util.List; - -import org.eclipse.epf.richtext.IRichText; -import org.eclipse.epf.richtext.actions.FontStyleAction; -import org.eclipse.epf.richtext.html.FontStyle; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; - -/** - * @author Goulwen Le Fur - */ -public class EEFFontStyleAction extends FontStyleAction { - - /** - * @param richText - * @since 1.1 - */ - public EEFFontStyleAction(IRichText richText) { - super(richText); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.epf.ui.actions.CComboContributionItem#createControl(org.eclipse.swt.widgets.Composite) - */ - protected Control createControl(Composite parent) { - Control createControl = super.createControl(parent); - selectFontStyle(); - return createControl; - } - - /** - * - */ - protected void selectFontStyle() { - String blockStyle = richText.getSelected().getBlockStyle(); - String name = FontStyle.getFontStyleName(blockStyle); - - int index = ((List)input).indexOf(name); - if (index == -1) { - index = 0; - } - setNotifyListeners(false); - getCCombo().select(index); - setNotifyListeners(true); - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/.checkstyle b/plugins/org.eclipse.emf.eef.mapping.edit/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/.classpath b/plugins/org.eclipse.emf.eef.mapping.edit/.classpath deleted file mode 100644 index 756f42890..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/.classpath +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/.gitignore b/plugins/org.eclipse.emf.eef.mapping.edit/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/.project b/plugins/org.eclipse.emf.eef.mapping.edit/.project deleted file mode 100644 index 8391aab53..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.mapping.edit - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.mapping.edit/META-INF/MANIFEST.MF deleted file mode 100644 index 11114bbd5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/META-INF/MANIFEST.MF +++ /dev/null @@ -1,27 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Mapping Edit Support -Bundle-SymbolicName: org.eclipse.emf.eef.mapping.edit;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Activator: org.eclipse.emf.eef.mapping.provider.MappingEditPlugin$Implementation -Bundle-Vendor: Eclipse Modeling Project -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.mapping.components, - org.eclipse.emf.eef.mapping.filters.provider, - org.eclipse.emf.eef.mapping.navigation.provider, - org.eclipse.emf.eef.mapping.parts, - org.eclipse.emf.eef.mapping.parts.forms, - org.eclipse.emf.eef.mapping.parts.impl, - org.eclipse.emf.eef.mapping.provider, - org.eclipse.emf.eef.mapping.providers -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.emf.edit;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.ecore;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.ecore.edit;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.eef.mapping;visibility:=reexport, - org.eclipse.emf.eef.views;visibility:=reexport, - org.eclipse.emf.eef.views.edit;visibility:=reexport, - org.eclipse.emf.eef.runtime -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/about.html b/plugins/org.eclipse.emf.eef.mapping.edit/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/build.properties b/plugins/org.eclipse.emf.eef.mapping.edit/build.properties deleted file mode 100644 index c88139c8a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/build.properties +++ /dev/null @@ -1,22 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -bin.includes = .,\ - icons/,\ - META-INF/,\ - plugin.xml,\ - plugin.properties,\ - about.html -jars.compile.order = . -source.. = src-gen/,\ - src/ -output.. = bin/ -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_JavaDeclarationFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_JavaDeclarationFilter.gif deleted file mode 100644 index 72c70855b1b64731a0346393a64331a6ff4bb344..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU@wm6seG9RB~0pC51k|Gs@g zLqpS=Yr#FoEQ{CZM7Hgkt_DO~Cn>M%l3&^+HLp@^W{L2>zwd$Q@8|PC^ym5F-*=mV zra^$>PZmZHO9w=N>||h#QBdehiL_H=n0fZ_lnYxY^*8rTD)BV_Y|?Wrdy=M@dcRb1 zrgNai?ByreMf$YnoI2@d#h{~h-`mAPAgE#Xi-Zr0PPQ{GOmLIG(Nc3eSL^i4^n8Y# Onx@porfgM325SJCdSD^| diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_JavaExpressionFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_JavaExpressionFilter.gif deleted file mode 100644 index f810f8a30ff99549bef95db987ab9cfe5b3e0e57..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6eEt3V=$kk5@87Sybm{;9`1$en|L@y3 zG&D4=xfa}W%(8fmPGsAz>1sf1OPi$TRf^3l5&rl0JrMo)AYJYW3#ZZps{ z2vGdV!U$sNfC!MC46HE<3VkV&c4`bW&mNv~Ve6#+=DtZKp2nX|dah+p(iBtgmrBlb z4%C>v`~M%l3&^+HLp@^W{L2>zwd$Q@8|PC^ym5F-*=mV zra^$>PZmZHO9w=N>||h#QBdehiL_H=n0fZ_lnYxY^*8rTD)BV_Y|?Wrdy=M@dcRb1 zrgNai?ByreMf$YnoI2@d#h{~h-`mAPAgE#Xi-Zr0PPQ{GOmLIG(Nc3eSL^i4^n8Y# Onx@porfgM325SH}*I%9h diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_StrictTypingFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_bindingFilters_StrictTypingFilter.gif deleted file mode 100644 index 08d7d5221061a7dfe11b142270f8685878e8b04c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{Qmm;&Cxga=ik3ndFlWE`1$en|L@y3 zG&D4=xfa}W%(8fmPGsAz>1sf1OPi$TRf^3l5&rl0JrMo)AYJYW3#ZZps{ z2vGdV!U$sNfC!MC46HE<3VkV&c4`bW&mNv~Ve6#+=DtZKp2nX|dah+p(iBtgmrBlb z4%C>v`~1OPi$TRf^3l5&rl0JrMo)AYJYW3#ZZps{ z2vGdV!U$sNfC!MC46HE<3VkV&c4`bW&mNv~Ve6#+=DtZKp2nX|dah+p(iBtgmrBlb z4%C>v`~3|53oeZoo3JQHGk#=efGtVBLa$)PF{^q_(C7#BgO?s|nPtp`q@0Uu> zbPm**z5E2bNT1f6QzzZ57*B$#$lN32yQ?T54|RYMp+Wp3jg| O)0EoSl&z}BU=08+zh9OB diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_referencedBinding_ElementBindingReference.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_referencedBinding_ElementBindingReference.gif deleted file mode 100644 index 4583981b80f6ec9f238fbc659b91a589ebd1ff33..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6tZBN|6MU@La!sU8+yDRZ^W*LR-?wjQ zXlPn3|53oeZoo3JQHGk#=efGtVBLa$)PF{^q_(C7#BgO?s|nPtp`q@0Uu> zbPm**z5E2bNT1f6QzzZ57*B$#$lN32yQ?T54|RYMp+Wp3jg| O)0EoSl&z}BU=08+zh9OB diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_subElements_EMFElementBinding.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_subElements_EMFElementBinding.gif deleted file mode 100644 index 51262522fca6a67ffe2fe5d8de13a03bbb9d2f3e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?74GqVFd;b5ApC51k|Gqtt z+qC9daL+Nz;x#&vZM&wc0nye;%Imu1mo`bws}!4ABK+^~dm#Gz`8*K)dA|7f-DaR^ z5TN*zg%QNk0TCcO8CYW!6#7yk?bH}%o;^I}!q!Rs&3%(fJdHn_^jyoHq$#G}FO{6> z9H=pS`3ZKBKCL;YPP$n!=&0TIcCio$YMA{Z;lrYn?Mw?3+~jYx)ZEV1I{h*|pCPBF NDYdaFTUC+48UPTCV8Z|a diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_subElements_StandardElementBinding.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractElementBinding_subElements_StandardElementBinding.gif deleted file mode 100644 index baaa3be79d895999bd43f5cde2e4627257e5cc8e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6Tx+^^EcnYLM_VN?#B7ItOPMvhKV$e~$@9knC5Y#aHMZ$+gC)=48Cb-GpXsNlKt9ANidOkx= OO;c)PQ?{xigEauhVqjnZ diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_JavaDeclarationFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_JavaDeclarationFilter.gif deleted file mode 100644 index 2c9fb7ddc57c4d51e05c5ed7dc435ec28cdac8ff..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU@wm6seG9RB~0pC51k|Gs@g zLqpTGYr)5kS*}^5)7G|Yx*8B|ous_3OMYpS)VxZunI*#i{=NsIzn{+o(Vypwf8T8e zng#)iKUo+-EFBO5vXg-|MnR!3CDKlfVdmMxQ!Z?s)Zg4Usl?Oxvq{gj>`9tp>its5 zna+V4vzMP>7wOZQbLym<6@!l2eQy^FfuM%jFA_d1I@!*&Fu_g!MoZ1@T&>eD)AJc} OYMN3To3d3E8LR;xa$xKL diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_JavaExpressionFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_JavaExpressionFilter.gif deleted file mode 100644 index a259b8fb4f254c6c429ed9e0055ec1798ca554c1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6eEt3V=$kk5@87Sybm{;9`1$en|L@y3 zG&D3_yB2)xnB|%^I&E#crmF$b)=A3iy5yHONzJPin^_|K@9%pc`uq7j5dC?+`1jpr zplJ}G_>+YZ#L@u~AUhdYV-ytnQX=it7-pV5JmtdHN&U@zlS({|Kb!Pi%buhurrs}= zoar2>F?;z5c9A}8}5D03R{UYJRqLb}R3lrSrZ?x3h&eb~oGCiLm Pr=}^ju_;?sk--`Ot$$=z diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_OCLFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_OCLFilter.gif deleted file mode 100644 index 9f92d6f95da5afa4a32a709407a858cfa358dd7a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?74GqO=KL7v6&yTnNf8QR+ zZMt?X_}DSaHEVR*+ICG>1EQ^yl-G61FKv>VS1C5LMEKv|_dxXb^LZfp^L+8|yUjq; zAVBda3nPf710q0nGO)%dDDA99YNmER{Un)7% zIZ$Kv@)PVLeOhx)opiHe&{4bZ?P4Ji)G+%+!iPmC+nE+7xXIsWskxo2b^2v`K0{7T NQ)**VwyGk7H2?@=V9fvk diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_OnlyReferenceTypeFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_OnlyReferenceTypeFilter.gif deleted file mode 100644 index 621468ed1da3b25b9620cafd3cef65753fec8b2e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?84hI|@9RB~0pC51k|Gs@g zLqpTGYr)5kS*}^5)7G|Yx*8B|ous_3OMYpS)VxZunI*#i{=NsIzn{+o(Vypwf8T8e zng#)iKUo+-EFBO5vXg-|MnR!3CDKlfVdmMxQ!Z?s)Zg4Usl?Oxvq{gj>`9tp>its5 zna+V4vzMP>7wOZQbLym<6@!l2eQy^FfuM%jFA_d1I@!*&Fu_g!MoZ1@T&>eD)AJc} OYMN3To3d3E8LR=kz+h+q diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_StrictTypingFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateAbstractPropertyBinding_bindingFilters_StrictTypingFilter.gif deleted file mode 100644 index e9ccde5dc5be294dcd96c79612c9c1b746597f3b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{Qmm;&Cxga=ik3ndFlWE`1$en|L@y3 zG&D3_yB2)xnB|%^I&E#crmF$b)=A3iy5yHONzJPin^_|K@9%pc`uq7j5dC?+`1jpr zplJ}G_>+YZ#L@u~AUhdYV-ytnQX=it7-pV5JmtdHN&U@zlS({|Kb!Pi%buhurrs}= zoar2>F?;z5c9A}8}5D03R{UYJRqLb}R3lrSrZ?x3h&eb~oGCiLm Pr=}^ju_;?sk--`Ou0>>4 diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateCategory_bindings_EMFElementBinding.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateCategory_bindings_EMFElementBinding.gif deleted file mode 100644 index 3b0b7d5d5bb9a5d403b8d9a23756ff0368e77768..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?74GqVFd;b5ApC51k|Gqtt z`}^zfH%H&xpMU>S<)vNI)qrU0B;|Eo@=Kef=2eQ#ED`?q_dO8({d^vX{ybm&`))JP zGzd`q$-)R?>3|53oeZoo3JQHGk#=efGtVBLa$)PF{^q_(C7#BgO?s|nPtp`q@0Uu> zbPm**z5E2bNT1f6QzzZ57*B$#$lN32yQ?T54|RYMp+Wp3jg| O)0EoSl&z}BU=0AQ)MU8; diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateCategory_bindings_StandardElementBinding.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateCategory_bindings_StandardElementBinding.gif deleted file mode 100644 index 9a34a69f517d2ccdc3dfd03ccbd9f184f4701e20..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6Tx+^^Ecn+YZ#L@u~AUhdYV-ytnQX=it7-pV5JmtdHN&U@zlS({|Kb!Pi%buhurrs}= zoar2>F?;z5c9A}8}5D03R{UYJRqLb}R3lrSrZ?x3h&eb~oGCiLm Pr=}^ju_;?sk--`OW4UBj diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateCategory_categories_Category.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateCategory_categories_Category.gif deleted file mode 100644 index d08a6f84a0349c6c6d745bd33039a9674db30fdb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{Qmm;&Cxga=ik3ndFlWE`1$en|L@y3 zG&CTK@0zX#L|Z2*uj`Uu+9WlvQfy|4@V~$Bf#~n&^FZ|H`QqPqn}Mc5fZ|UUMi5H} zM1bsMV2x2w=u3&TQ)8HU_VAPoTPO85_f0DCH2!STb1i$4rkHxaRC1$ zwC0>T>1M^Cqjulh#X=ycVfKrJ4~tH=Gc8PTlfThYb30e-^vm>ohMbzF)W)W4RYeAC E0L7$df&c&j diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_current_ChainedModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_current_ChainedModelNavigation.gif deleted file mode 100644 index ebfad0fb2c9aa1c7c9076e77014c238f6f215ebf..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?74GqD^j{W~1KR@37|9yKP z7g>DQbTuH_I!Sq5m;BNusd<%RGfRa3{e2Hae?OlGqCd|U|GwJ{Gz|h2f3h%wSUMmA zWG4e_jDkX6N~E0{!_2dXr(D=NslT~zQi-SWXOo_5*^@NI)cd89Go1r9W-mX%F4Ctp z=hR6zD+V34``#`V0znP4UnG23bh4dkVS=0djh33*xmu@Rrsp%{)HJ0wHf5_SGFSru DB~fBz diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_current_SimpleModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_current_SimpleModelNavigation.gif deleted file mode 100644 index 92d4c01d843bc9f36d47996f5c915bc9fbf8e18c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6?0K=L=VnjZnKXw34*&nh&yTnNf8V~L zq2a)R19Rrg0WyM*9oscs4T!c*QeM|3zqCneUZvQ~65)S;-viO#&*y>Y&-2B!EQ}zQ4u}BR$-o+;pwO2RX{W|8^X%a%7q(97Z|<8^;%WTZq~}`pBuz2(eyQY4 z=Rl3w%TKV2^l8mGb<)j>K}YSrw~K{9P{ZsO2_F`nY-d`S;3j{grRH|7*6Ek&`3yNV NO{tAd*{X^R)&TKyVj2Jd diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_current_StructuredModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_current_StructuredModelNavigation.gif deleted file mode 100644 index 3d60257cc2ddd6ab3999ac10266cd247ad9d65bb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?14mbe8|Nrsx6>ylsEBsH&6Y-Wk@zrXK+=DQbTuH_I!Sq5m;BNusd<%RGfRa3{e2Hae?OlGqCd|U|GwJ{Gz|h2f3h%wSUMmA zWG4e_jDkX6N~E0{!_2dXr(D=NslT~zQi-SWXOo_5*^@NI)cd89Go1r9W-mX%F4Ctp z=hR6zD+V34``#`V0znP4UnG23bh4dkVS=0djh33*xmu@Rrsp%{)HJ0wHf5_SGFSru DB~fBz diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_next_SimpleModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_next_SimpleModelNavigation.gif deleted file mode 100644 index 92d4c01d843bc9f36d47996f5c915bc9fbf8e18c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6?0K=L=VnjZnKXw34*&nh&yTnNf8V~L zq2a)R19Rrg0WyM*9oscs4T!c*QeM|3zqCneUZvQ~65)S;-viO#&*y>Y&-2B!EQ}zQ4u}BR$-o+;pwO2RX{W|8^X%a%7q(97Z|<8^;%WTZq~}`pBuz2(eyQY4 z=Rl3w%TKV2^l8mGb<)j>K}YSrw~K{9P{ZsO2_F`nY-d`S;3j{grRH|7*6Ek&`3yNV NO{tAd*{X^R)&TKyVj2Jd diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_next_StructuredModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateChainedModelNavigation_next_StructuredModelNavigation.gif deleted file mode 100644 index 3d60257cc2ddd6ab3999ac10266cd247ad9d65bb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?14mbe8|Nrsx6>ylsEBsH&6Y-Wk@zrXK+=$>EZHc8E^6q{Kh{O|93Ao~0HJP`ePzWDduW}s;hp!k!85ya8~ z5g+&ksNMH=u@DGqnEfK*!=jVzObZj-{#%cHI{8{I{*L2&yTnNf8V~L zq2a}gJvVRmoH>(r;DE!f>1sf$>EZHc8E^6q{Kh{O|93Ao~0HJP`ePzWDduW}s;hp!k!85ya8~ z5g+&ksNMH=u@DGqnEfK*!=jVzObZj-{#%cHI{8{I{*L2&yTnNf8V~L zq2a}gJvVRmoH>(r;DE!f>1sfS<)vNI)qrU0B;|Eo@=Kef=2eQ#ED`?q_dO8({d^vX{ybm&`))JP zGzd`q$-)R?>3|53oeZoo3JQHGk#=efGtVBLa$)PF{^q_(C7#BgO?s|nPtp`q@0Uu> zbPm**z5E2bNT1f6QzzZ57*B$#$lN32yQ?T54|RYMp+Wp3jg| O)0EoSl&z}BU=0AQ)MU8; diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateDatabinding_bindings_StandardElementBinding.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateDatabinding_bindings_StandardElementBinding.gif deleted file mode 100644 index 9a34a69f517d2ccdc3dfd03ccbd9f184f4701e20..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6Tx+^^Ecn+YZ#L@u~AUhdYV-ytnQX=it7-pV5JmtdHN&U@zlS({|Kb!Pi%buhurrs}= zoar2>F?;z5c9A}8}5D03R{UYJRqLb}R3lrSrZ?x3h&eb~oGCiLm Pr=}^ju_;?sk--`OW4UBj diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateDatabinding_categories_Category.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateDatabinding_categories_Category.gif deleted file mode 100644 index d08a6f84a0349c6c6d745bd33039a9674db30fdb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6{Qmm;&Cxga=ik3ndFlWE`1$en|L@y3 zG&CTK@0zX#L|Z2*uj`Uu+9WlvQfy|4@V~$Bf#~n&^FZ|H`QqPqn}Mc5fZ|UUMi5H} zM1bsMV2x2w=u3&TQ)8HU_VAPoTPO85_f0DCH2!STb1i$4rkHxaRC1$ zwC0>T>1M^Cqjulh#X=ycVfKrJ4~tH=Gc8PTlfThYb30e-^vm>ohMbzF)W)W4RYeAC E0L7$df&c&j diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFMultiPropertiesBinding_navigation_ChainedModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFMultiPropertiesBinding_navigation_ChainedModelNavigation.gif deleted file mode 100644 index e0f28471cd709ce69b49c8f28e95dae1ed37d594..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z695`@b&YU?74GqD^j{W~1KR@37|9yKP z7cO3`=CfC>8X>ZF?$gO1vLZx;)JpoZBm5Y&-2B!EQ}zQ z4u}BR$-o+;pwO2RX{W|8^X%a%7q(97Z|<8^;%WTZq~}`pBuz2(eyQY4=Rl3w%TKV2 z^l8mGb<)j>K}YSrw~K{9P{ZsO2_F`nY-d`S;3j{grRH|7*6Ek&`3yNVO{tAd*{X^R F)&K`iV7&kU diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFMultiPropertiesBinding_navigation_SimpleModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFMultiPropertiesBinding_navigation_SimpleModelNavigation.gif deleted file mode 100644 index 053b43458eb01fa3ec27e10eb7d91333e7002075..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6?0K=L=VnjZnKXw34*&nh&yTnNf8V~L zq2a)R19Rrg0Wyl!e0EJ&1EQ^yl-G61FKv>VS1C5LMEKv|_dxXb^LZfp^L+8|yUjq; zAVBda3nPf710q0nGO)%dDDA99YNmER{Un)7% zIZ$Kv@)PVLeOhx)opiHe&{4bZ?P4Ji)G+%+!iPmC+nE+7xXIsWskxo2b^2v`K0{7T NQ)**VwyGk7H2_iNVITki diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFMultiPropertiesBinding_navigation_SmartModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFMultiPropertiesBinding_navigation_SmartModelNavigation.gif deleted file mode 100644 index 0c070475d5d3eb93f7c7217f8f3e985d1ef83077..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6yx8;NX3xztX=e^N9Qgk~etx|D|NHh0 z4Gjkl9GEj_4vC>8X>ZF?$gO1vLZx;)JpoZBm5C>8X>ZF?$gO1vLZx;)JpoZBm5`9tp>its5na+V4 zvzMP>7wOZQbLym<6@!l2eQy^FfuM%jFA_d1I@!*&Fu_g!MoZ1@T&>eD)AJc}YMN3T Ko3d3E8LR{#%cHI{8{I{*L2&yTnNf8V~L zq2a)R1NZ0O2QnNS9Cl4t1EQ^yl-G61FKv>VS1C5LMEKv|_dxXb^LZfp^L+8|yUjq; zAVBda3nPf710q0nGO)%dDDA99YNmER{Un)7% zIZ$Kv@)PVLeOhx)opiHe&{4bZ?P4Ji)G+%+!iPmC+nE+7xXIsWskxo2b^2v`K0{7T NQ)**VwyGk7H2_y(VKD#z diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_SimpleModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_SimpleModelNavigation.gif deleted file mode 100644 index 289c14d61a32a03f6fa02df27e9ef1186803bbd5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6?0K=L=VnjZnKXw34*&nh&yTnNf8V~L zq2a)R1NZ0O2QnNS9Cl4t1EQ^yl-G61FKv>VS1C5LMEKv|_dxXb^LZfp^L+8|yUjq; zAVBda3nPf710q0nGO)%dDDA99YNmER{Un)7% zIZ$Kv@)PVLeOhx)opiHe&{4bZ?P4Ji)G+%+!iPmC+nE+7xXIsWskxo2b^2v`K0{7T NQ)**VwyGk7H2{?aVT1qx diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_SmartModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEMFPropertyBinding_navigation_SmartModelNavigation.gif deleted file mode 100644 index 962e19f0f1c23bd01e87959bfc09a1a0561d0026..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6yx8;NX3xztX=e^N9Qgk~etx|D|NHh0 z4Gjkl9JoLKK9J$y;IM1D8W3%rq`a<6erc1`yh^c|CBpyyz6YYepU(r)pXZBz-)#n( z1_6pcSr|bq9S{MslYuoxL7^`t(oT(G=GntjE^M9D-`qE;#MAh*Nzb+HNt$Bn{Zh%9 z&Vd@Um!Du4>C>8X>ZF?$gO1vLZx;)JpoZBm5#Iitn1P21HvYDX;62U)m%!uTpGgiSWO_?}6y==kq}H=lSB_cbkExL4e{< z7Df3tK1kH}_2{@ihKy(sM0)lBSq?zf^LjbD+lT zg4sA2Ytgb#~OwlghEaFf5$Qgb_3>-5X?e1@Ewrqsr! JY*j@DYXBy~VDA6` diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEReferenceViewerSettings_filter_JavaBodyStepFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateEReferenceViewerSettings_filter_JavaBodyStepFilter.gif deleted file mode 100644 index 1390ab70de2f30b61e33cb9402c1c5511c510a5a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6T-x(uQ_szrX=fT74*dTgKR@37|9$(0 zhK2(N4$PS|$D!eXgM-7a>1sfUm4mOV*ROub(! zIny~%WA^eB>>_{ejmN@X8!*BmCG*enyv;!TPG>6>ylsEBsH&6Y-Wk@zrXK+==5r0%RuxYm9q!{Ee2H+qqh&U#90X Q=5r0%RuxYm9q!{Ee2H+qqh&U#90X Q;@%I1k+cz{c zeEsqJ=#4k?_usEvc4^miH6YqLNqJqD{L&_=d6i-_ON9UZeGf!`Kc5GpKhGEczS|5m z4FVK@vM_>JIv@gMCj)DYfrlb&nYlQhND`=ydI zodY#yFF(O9(x)}&)JZoh1|7Bg-YymbK@GECBz#zOvYlyRf}8w}mYUnSTBl#8=QHHg OG^I8+WvePOSOWmVx?^zw diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateNavigationStep_subStep_DeclarativeNavigationStep.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateNavigationStep_subStep_DeclarativeNavigationStep.gif deleted file mode 100644 index 17408b8fb4f54f428501fc7c7512484d8224b907..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6G+k>7J{D}b#!{zE=l}os`SJGu@7p&t zG<^N>`{<1~^Y`DcTy|;KbTuH_I!Sq5m;BNusd<%RGfRa3{e2Hae?OlGqCd|U|GwJ{ zGz|h2f3h%wSUMmAWG4e_jDkX6N~E0{!_2dXr(D=NslT~zQi-SWXOo_5*^@NI)cd89 zGo1r9W-mX%F4Ctp=hR6zD+V34``#`V0znP4UnG23bh4dkVS=0djh33*xmu@Rrsp%{ P)HJ0wHf5_SGFSru^2cId diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateSmartModelNavigation_step_DeclarativeNavigationStep.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/ctool16/CreateSmartModelNavigation_step_DeclarativeNavigationStep.gif deleted file mode 100644 index 3d308aaade0a38a2da85419e6f08845935aa95ba..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 223 zcmZ?wbhEHb6krfwIKsg2|NsB{_xIb|$1^Z6G+k>7J{D}b#!{zE=l}os`SJGu@7p&t zG`!gJ;%3jyGihfII2_nDT@8q~PEuaiCBL*uYF?$-%o5>$f8PVq-_PfP=+E=Tzwb5! zO@jc%pDc_ZmJWyj*~!2fqoB~25^1N#F!Su;DHpa*>Tm9wRN`s;*`()M_9RU)^?s@3 zOy@w2*~?F`i}Y#DId#&_ia|&1zPF2oKv2W%7YQF0oor`XnBXRVqow9{uGZ<7>G=#f OHBG6FP1&l74AuZU7GX#L diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/AbstractElementBinding.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/AbstractElementBinding.gif deleted file mode 100644 index b3643da048a40135b62eed5100cac5afe1ecef3c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 129 zcmZ?wbhEHb6krfw*vtS14M4Jip`qcxfddT<4GjN*-2XuK|Nmgt|Nl*Et_AlTvn*bt z6WONtlZBCifs;W8q!VNY1B;%)Nzc`LEna{5ro#WQ&~>{h>#dXouLTRg+UR|prgqh= Vyl15*zwUCzPPZcyg@hRytO0?AFBSj* diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/AbstractPropertyBinding.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/AbstractPropertyBinding.gif deleted file mode 100644 index d3dc5a9ad8159548d5ada4a1cd545ec1d4de029c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 129 zcmZ?wbhEHb6krfw*vtS14M4Jip`qcxfddT<4GjN*-2XuK|Nmgt|Nl+bt_2@EX1QjK zPFtJePZmZ722KVYkWP>p3@myECp}m1wRrvIn+pHKLf7r4thZ7UycR6{YNPjYn%Y&f W@}8BN{JP5-JKc^<6cT1+um%9ULNDL| diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/Category.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/Category.gif deleted file mode 100644 index 8505f9d3c6330234d3e58d66a287e62818c66296..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 589 zcmZ?wbhEHb6krfwc*ekB+pul>#b+7?D>MsNY89^3DPFBpyh^Wht$x{Bql$G#mFrBa zH(Jzfv8dZ@S-07uc7sjhR@=sH4lO(E8#g<*?{aD1?b5!>y=$*~_g?Sb{eBY;`As+& zH2Lu6bB{NkdARk$(=F$pY&rL6_mvkC84F~x7Rh8UQp#JZl($5)c%?zb8uQxqc1@di zTzkN3mqSBO!)C&#*YUJzP&mB=kv`UH#&Y?sQ3XC zywI?x)#z}y*_L{v=NH#6%~4rfq`jx!=y0pq+8mX6Y3gf>^zR*6J}+LjKS=UF7%&W0 zp!k!8k%7U7K?meOP@FKZuWImVYEo`(ZE0(6VPaxtZQ|w=RPORoWny7vZ{igYQkkm8 z%*MglG*3jm+0H?Om4l1BNk~jwqsi5Km$ygPR!L1C7d<@_b1iNj1|d-iNhy9GTm35r z!jra$OG?XV`#2juG*Xn4Rgh=Y(N$9Pu{Zl*;r{u{S05+qpYEoA{{As`pTTl+;$x13 p&FqX^UW*=c^tTJhYl$p*($Uu~q3Ylwnc-;*5%sak5{rYj{_Jl$O*^M7q=&E?f<_kF;~U0v$N#=`C0h7*JJ+I>x@gj-IEbef%L+aKk*Aj5TPqVN2yz$N*i ziwc6~^`}^hm|9?JwxKjM*#r)rQtAE~W{dK?N+qsydGZcTGi~Dst{`Z-rEp;M$ zTg7%XiEXUlUtKJ;qh4ftjmZ9H(OnIq`&z_yH;Sz-f-dVSKlpKpKsd;IPHk$3;MKYm}D=iOW8^#A{V22`N< zlZBCiL5e{KBn+~Xfi-r4THoRYI>#DSmYnD~sO)2)>|nFUJDj}wbA=HP3@{#dCy8s Se%zwqA zYXNI+=j?yUF!2gQ&pF;{SLJ43Gg@?`>B5(Pf8YQ8a{lk<^IIn>Z=IyPYr5K>=Zoi6 ziY;rDTGk}Bv`K1Rm;CR$%`;1c=axw>C>38&E!J~z4Vi$RgYZ%vcr;Ea>scyjD0)=Hm{$c!o$ly@kC;ySeKg{ zvjD4bfs>k+sv8pvFFV5o4LyBLH%1;-XKh1m^)6R77H1t@gUM4}8J&%cXKRNp*4?n$ I#gV}p01fVS82|tP diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/EMFMultiPropertiesBinding.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/EMFMultiPropertiesBinding.gif deleted file mode 100644 index 90d10f9470787d1465c462197b85d1d3621f84e4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 129 zcmZ?wbhEHb6krfw*vtS14M4Jip`qcxfddT<4GjN*-2XuK|Nmgte-L}loH;Seg|6F8S#PBzcr94?)kg2*G_|W{X&dtt|nVl^^J5_#mn!=1^#hLL6 zQ({&B|NqYb28usf7#SF38FWBAkev*y<_YS3DVg&!R;^p??4-GP!o(6iSLdLsA#$t^ kN)9{`a#OuK0~{t8Og)pCppa>%$=G@LRn`6n`5X+^0BQb3bpQYW diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/EReferenceViewerSettings.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/EReferenceViewerSettings.gif deleted file mode 100644 index 351c8cedf32250a68220992b749867b26710b647..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 186 zcmZ?wbhEHb6krfwIKseCTGC{1U+?VIo?q5cSl*mh)|_9~kXzoIQPr2&Fh8@pFS2c2 zRNK15#`*q{NnxE^{G($0qoe=-|Ia`iQ2fcl$iN`PpaW74vXg<;e1S?|iX~UZtXVnQ zt2Vqk_tENp5HEX0KeJ8(r%?j0g39rQ3p{k>de{~f6iiTJo2Hngv|*235C?-b02d)N Ae*gdg diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/ElementBindingReference.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/ElementBindingReference.gif deleted file mode 100644 index 71ad510b4186659d597f116e893875c43ce942f6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 583 zcmZ?wbhEHb6krfwc*ekR@Yu~CKmVlHu56vWu5I$VmD?|U`uh9Zk3V0(|Ni;wPj2(t z@}4cNQ`WamS=TmY-NTpPUw`=d^8L?GUw`$^So!ePj|VTmKYIP+$(tW9-v504@z;kh zzrO$c^X|Hicwe}CG!b92w{cN_L^>)5lU^Y_!~ zdt1b|)rf4X6Cc|Nj|=EKvN(!pOkj$e;uA0Vqxw*q1aoHZ`}jwpny^ zc3HG?_VrKbX<=k!m^Ph3dQ!8swTzAoJNrU*%T{Y6YmRA(Ys?(yZZulSrpczRE@W(N zuy@~HYbmY6QYJR0Cr+L)x8>$y(lE5Qx^nf3oxou&Nqt9$`}eOnNT^8&KGAD+uyRmk zWqrpgulveDTv=R2TwFn1yH!kQkMxgoO&w06S|t?^8k^d=Seg|6F8S#PBzcr94?)kg2*G_|W{(Y?!&Aw5w|Ng%J`{~%WbLPKw)$;B Og`P}9k*1m=gEav5gIBTu diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaBodyStepInitializer.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaBodyStepInitializer.gif deleted file mode 100644 index 87e57e3c93491040457b7c65f59da28682384ad4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 355 zcmZ?wbhEHb6krfwxXQq=dGpbWcivRb*ln6V*QIEQd&#oI_RVEecht{2)Vla+3+mW@$YVHWKXXI4>XP-F;}WuD&Vq{yz=5zN5D&NF46 qlLCVRlfu%8^6K(j@=H48rZC7!$jxI=^Hh^m+w7%!=eqFLbWC+`aC~^~WFYz4-j(%~#jjExye=yz4jn zHSh3k*b>;b+plqJP}{EH_T9m4J7fFyCrmsP-+v%!(&5C3hf*dVPMdNhZOY-i*(dU5 z9WPsWrh3V_x@G5Tm!54}alT{CrHPxbP2O^S+P3S{w_TsL^VW)kw^tszz52-AjVB)L zx%lkPvky<-e)VhG;@`YAsAE@X*PhVM-C ziTj&QJ-Gk!)3PJ?j^BFq9}F0VEKvN(!pOkj$e;uA0Vqxw*ylGmHZ`}jw%Id_3X3t@ zw>7B{zbF;P&no2RB=GNYN5S5{YcA8~nQiP2+Kfug;-*>- z4z?n;2d&M-n+15(9r$z{bod<9x%l@QXgKKW>)g4bcd|*zSkpo9#R~^3Bh_X$4oh3h zFJElTIo3BTb27;P|6g!KA~E9#6OW`&QiQ{Yi~RyZ2_6a$UQ9gNEz!)v#9$2o?Si&i diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaDeclarationStepFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaDeclarationStepFilter.gif deleted file mode 100644 index 245c72ed3f5e4a64a7cfb01d19f461ae9149a7b4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 209 zcmZ?wbhEHb6krfwIKseiFE;!2j71p@>*6X`r`D~_Y~Ebdy{ou$)9NipJ7(=%wDH95 zshWQt&;R@W_}}*@{{4EtsY~_myW@Y~omg3?@c;jR20}pbCkrD3g9w8TNFm5h239`> z)xMO>c`GWHs5&XU(cocPD#5x_C&}nf=jBHSg?W8;-)+tiVVpO`YCM%nX`$Z{m&|yGGCB#wJUjE=ztf!%mcm!5RQ3iV)NpqHl@pKOP4v6FRz)mr(w~)mZb+fRvhVGeXMWY35L*V%;D2n!l!dY&ESlj z$rn3|KX#UA;vCV0*)pl~WK)4=&Y!U1YHY n!c|sOwoFBe(Un0;OxlG(!d*gHGF^Py^cmAygXg$9GFSruzMxW0 diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaExpressionFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/JavaExpressionFilter.gif deleted file mode 100644 index 870df5c473a5a04c8c019ca86d621a28c2236c0f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 909 zcmZ8gT}V@57=HG1bdE6H+!z&gj9rYX) zbRi+mi-_)$5|VCO{y^kSH^I6{D@-LLOkufItoQwNYQ1p2_vd-u@4V0Vol{+V(o=TP zjy(JX(&_Z<>`Ss}G^%M@AP^`o4;W$8K?jM_y4_k3f*WmUN9$&}5M`2G;am{Wd>>95 zEQlD)Fl;awAN*y(=v)?Wis15}oAbKeP$(WgaUS3GX4!8Xv*W5ETXr!~?^zI$;zcoY zJ0S{Wb!#a~THr#?W}%Mqj%+J_%&iH)DiO}(16DW*V;f0Z@Ni#Jc;iVyy3=_n3v#Oy zf_Y(z*)-{`sH8ZI>uC1b$eZ->al6EM$@Ke)+fkPgHHsDe6t9uSj9u8+Z%7ZRExvRP z4!2Fhthbt?OpPdT5WoHSqBy0_h)IfzClVrdEhXIKy^)kyo?L%_&zCjfAza(BrPWFO zoU^f}cl8P3p;@+T{Y~}Etb7k9;_?{`Q~ki}WqD@Y&+p0H6X!lO!H)*=XQd9eoE*4J zeGcrBXIk}qRk+@)$}{DA8#Md=*+-?Cf90s_)=EtGzb6PoypVmQg9wH@I)hzZ?VPuS z+-)jtSWZv>!39x6nx47VXEnhH2i1Aj$DK7y$DygMJ2Kv@lzF7YCTBTJ*b?zrGjp{K zyf8_hI?O2IBL5R!QwX*_>aZ5mDW?3rjRPZ}x_ixvsVP3Pe_WSclG}Xetyc+o?|X7ATIq*waVT4{}OdtD3xpukNe$cI|zaI(66Go%j|Wou4!uQ9fT8 SJM*=%&;KO!;YF#6V}AkPPywv~ diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/OCLFilter.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/OCLFilter.gif deleted file mode 100644 index 90d10f9470787d1465c462197b85d1d3621f84e4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 129 zcmZ?wbhEHb6krfw*vtS14M4Jip`qcxfddT<4GjN*-2XuK|Nmgte-L}loH;Seg|6F8S#PBzcr94?)kg2*G_|W{pBI1py!QRawX7ujqBPqBJLcEs zSWc}l>?$%ny?6H98vXzO|1*#R6o0ZXG61d80cir+$-ru&pwgF;IWJ??x}4c|1w76T rCq*jWU2wVigtajNC||Ys=);5zDUm%vOpa^SGS;mrJ1yGEz+epkb(c1h diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/SimpleModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/SimpleModelNavigation.gif deleted file mode 100644 index baff0ee6eba7d37f6a8ae262679c7c26f1bb5b19..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 336 zcmZ?wbhEHb6krfwxXQrr-+D&KYsuD|NlP&m4M<;7DfgJ zbp{=fc_2SAu;m_@T;TCX!v2VgVM>VBOrPhUgsl{ps%w<32yL=@upy%6kOT%5~S@~l{;5WQjJCMQP*YXGwmhG75z diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/SmartModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/SmartModelNavigation.gif deleted file mode 100644 index a22959cac01bd1bf8825c5447c99f2a4bdc9b70d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 356 zcmZ?wbhEHb6krfwxXQrLFlkd^+w!8ehMqi%jh z&+5~c@4F^62WIsKX7vadL|BDayC$|MIj3uQ?ccvY|G|KP5K#Qd!pOj2!k`0E2=WsHTcg9Q0uLQ7 z^%F~qg68PV3(%Mx5qTmhLg#dYW|Y{fr4bsDbLL!pab=@HX#Bb#udhb=@N-`*XMOoS zvCN5+TPjtPg{4lT(S(s(JV$j>oobJX0BeP!ia>{e@-!BnX4$#&3Ig)eociWUOUkgw dt#%S%$n+0(VPR(C;^5~M6xro=%*2tw8UPm9rHcRn diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/StandardElementBinding.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/StandardElementBinding.gif deleted file mode 100644 index 351c8cedf32250a68220992b749867b26710b647..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 186 zcmZ?wbhEHb6krfwIKseCTGC{1U+?VIo?q5cSl*mh)|_9~kXzoIQPr2&Fh8@pFS2c2 zRNK15#`*q{NnxE^{G($0qoe=-|Ia`iQ2fcl$iN`PpaW74vXg<;e1S?|iX~UZtXVnQ zt2Vqk_tENp5HEX0KeJ8(r%?j0g39rQ3p{k>de{~f6iiTJo2Hngv|*235C?-b02d)N Ae*gdg diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/StandardPropertyBinding.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/StandardPropertyBinding.gif deleted file mode 100644 index bff5e73c63fc1784dc65b9145ed23f97c4d30c09..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 298 zcmZ?wbhEHb6krfwxXQp#TGC{1U+?7J>g3VpW&R~g{fn3Qmn_LGZ_cRd3vO5&(y%V1ab04={LJdUu=dT7ZR?`i)+IL1 z_m4~p?bs65xh1S)vwu{Ke{}T!|Nj|i02F_+FfuSGGw6WK2KkAB&Hcc{0uLRj{u4`z zJT+A0#Q0ALIZALeE+|z`)6%1JVgHgMmfQ;H2m3y%w*(d{g0nSm?Ull=W6hg4cqDUv2b0PE)&T WR^GExlV5i^W2f7Zi9*7R4AuatYBLM~ diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/StructuredModelNavigation.gif b/plugins/org.eclipse.emf.eef.mapping.edit/icons/full/obj16/StructuredModelNavigation.gif deleted file mode 100644 index da71215cd0e05d4a9be34226112736d0c8be7147..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 191 zcmZ?wbhEHb6krfwIKsei=k>Gmk8fK|i%D2lo3ySjbz@`U_HM(8!Fuh!rc=T#Cq+8V zPPFZh@?4PNIyKREepcX;{Ln=OL345gW@JULs)%1x9kZk?a%Ms9mUj2KDgXcfXFvst zKUo+V7^E0>n)u~(`w#i%_= e$Eg2=Ylo18E9cXobSD{+zLO;ty0d*18LR=(=0M8; diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/model/mapping.components b/plugins/org.eclipse.emf.eef.mapping.edit/model/mapping.components deleted file mode 100644 index 31ad2cff5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/model/mapping.components +++ /dev/null @@ -1,505 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - SWT - Form - - - SWT - Form - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - SWT - Form - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - SWT - Form - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - SWT - Form - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/model/mapping.eefgen b/plugins/org.eclipse.emf.eef.mapping.edit/model/mapping.eefgen deleted file mode 100755 index 1d01588a5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/model/mapping.eefgen +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/plugin.properties b/plugins/org.eclipse.emf.eef.mapping.edit/plugin.properties deleted file mode 100644 index c8efa04c4..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/plugin.properties +++ /dev/null @@ -1,171 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -_UI_CreateChild_text = {0} -_UI_CreateChild_text2 = {1} {0} -_UI_CreateChild_text3 = {1} -_UI_CreateChild_tooltip = Create New {0} Under {1} Feature -_UI_CreateChild_description = Create a new child of type {0} for the {1} feature of the selected {2}. -_UI_CreateSibling_description = Create a new sibling of type {0} for the selected {2}, under the {1} feature of their parent. - -_UI_PropertyDescriptor_description = The {0} of the {1} - -_UI_Databinding_type = Databinding -_UI_ModelElement_type = Model Element -_UI_AbstractElementBinding_type = Abstract Element Binding -_UI_ModelProperty_type = Model Property -_UI_AbstractPropertyBinding_type = Abstract Property Binding -_UI_EMFElementBinding_type = EMF Element Binding -_UI_EMFPropertyBinding_type = EMF Property Binding -_UI_StandardElementBinding_type = Standard Element Binding -_UI_StandardPropertyBinding_type = Standard Property Binding -_UI_Category_type = Category -_UI_ElementBindingReference_type = Element Binding Reference -_UI_Unknown_type = Object - -_UI_Unknown_datatype= Value - -_UI_Databinding_bindings_feature = Bindings -_UI_Databinding_categories_feature = Categories -_UI_ModelElement_properties_feature = Properties -_UI_ModelElement_subElements_feature = Sub Elements -_UI_ModelElement_binding_feature = Binding -_UI_ModelElement_superElement_feature = Super Element -_UI_AbstractElementBinding_subElements_feature = Sub Elements -_UI_AbstractElementBinding_properties_feature = Properties -_UI_AbstractElementBinding_databinding_feature = Databinding -_UI_AbstractElementBinding_superElement_feature = Super Element -_UI_AbstractElementBinding_name_feature = Name -_UI_AbstractElementBinding_referencedBinding_feature = Referenced Binding -_UI_AbstractElementBinding_views_feature = Views -_UI_AbstractElementBinding_category_feature = Category -_UI_ModelProperty_binding_feature = Binding -_UI_ModelProperty_EReference0_feature = EReference0 -_UI_AbstractPropertyBinding_name_feature = Name -_UI_AbstractPropertyBinding_views_feature = Views -_UI_AbstractPropertyBinding_element_feature = Element -_UI_EMFElementBinding_model_feature = Model -_UI_EMFPropertyBinding_model_feature = Model -_UI_StandardElementBinding_model_feature = Model -_UI_StandardPropertyBinding_model_feature = Model -_UI_Category_name_feature = Name -_UI_Category_bindings_feature = Bindings -_UI_Category_databinding_feature = Databinding -_UI_ElementBindingReference_binding_feature = Binding -_UI_Unknown_feature = Unspecified - -_UI_MetamodelNavigation_type = Metamodel Navigation -_UI_SimpleMetamodelNavigation_type = Simple Metamodel Navigation -_UI_EMFPropertyBinding_navigation_feature = Navigation -_UI_SimpleMetamodelNavigation_feature_feature = Feature -_UI_ChainedNavigation_type = Chained Navigation -_UI_ChainedNavigation_current_feature = Current -_UI_ChainedNavigation_next_feature = Next -_UI_ModelNavigation_type = Model Navigation -_UI_SimpleModelNavigation_type = Simple Model Navigation -_UI_ChainedModelNavigation_type = Chained Model Navigation -_UI_SimpleModelNavigation_feature_feature = Feature -_UI_ChainedModelNavigation_current_feature = Current -_UI_ChainedModelNavigation_next_feature = Next -_UI_SimpleModelNavigation_index_feature = Index -_UI_SimpleModelNavigation_discriminatorType_feature = Discriminator Type -_UI_StructuredModelNavigation_type = Structured Model Navigation -_UI_CustomModelNavigation_type = Custom Model Navigation -_UI_DocumentedElement_type = Documented Element -_UI_DocumentedElement_documentation_feature = Documentation -_UI_EMFMultiPropertiesBinding_type = EMF Multi Properties Binding -_UI_EMFMultiPropertiesBinding_model_feature = Model -_UI_EMFMultiPropertiesBinding_navigation_feature = Navigation -_UI_Category_categories_feature = Categories -_UI_Databinding_bindings_description = The bindings defined in this context -_UI_Databinding_categories_description = The categories of the context -_UI_ModelElement_properties_description = The mapped properties of the current element -_UI_ModelElement_subElements_description = The mapped sub-elements -_UI_ModelElement_binding_description = The binding that manage this element -_UI_ModelElement_superElement_description = The container of this element -_UI_AbstractElementBinding_subElements_description = The sub-binding of the element -_UI_AbstractElementBinding_properties_description = The nested properties binding -_UI_AbstractElementBinding_databinding_description = The owning databinding -_UI_AbstractElementBinding_superElement_description = The containing element binding -_UI_AbstractElementBinding_name_description = The name of this element binding -_UI_AbstractElementBinding_referencedBinding_description = The owned binding references -_UI_AbstractElementBinding_views_description = The mapped views -_UI_AbstractElementBinding_category_description = The owning category -_UI_ModelProperty_binding_description = The binding that manage this property -_UI_ModelProperty_modelElement_feature = Model Element -_UI_ModelProperty_modelElement_description = The owning element -_UI_AbstractPropertyBinding_name_description = The name of this property binding -_UI_AbstractPropertyBinding_views_description = The mapped views -_UI_AbstractPropertyBinding_element_description = The owning element binding -_UI_EMFElementBinding_model_description = The mapped classifier -_UI_EMFPropertyBinding_model_description = The mapped structural feature -_UI_EMFPropertyBinding_navigation_description = The model navigation description -_UI_StandardElementBinding_model_description = The mapped model element -_UI_StandardPropertyBinding_model_description = The mapped model property -_UI_Category_bindings_description = The bindings defined in this category -_UI_Category_databinding_description = The owning Databinding -_UI_Category_categories_description = The owned categories -_UI_ElementBindingReference_binding_description = The referenced element binding -_UI_DocumentedElement_documentation_description = The documentation of the element -_UI_EMFMultiPropertiesBinding_model_description = The mapped properties -_UI_EMFMultiPropertiesBinding_navigation_description = The model navigation description -_UI_BindingFilter_type = Binding Filter -_UI_OCLFilter_type = OCL Filter -_UI_JavaFilter_type = Java Filter -_UI_JavaDeclarationFilter_type = Java Declaration Filter -_UI_JavaExpressionFilter_type = Java Expression Filter -_UI_BusinessFilter_type = Business Filter -_UI_OnlyReferenceTypeFilter_type = Only Reference Type Filter -_UI_AbstractPropertyBinding_bindingFilters_feature = Binding Filters -_UI_BindingFilter_name_feature = Name -_UI_OCLFilter_body_feature = Body -_UI_JavaDeclarationFilter_methodName_feature = Method Name -_UI_JavaExpressionFilter_body_feature = Body -_UI_OnlyReferenceTypeFilter_reference_feature = Reference -_UI_BindingFilter_mandatory_feature = Mandatory -_UI_OCLFilter_oclBody_feature = Ocl Body -_UI_JavaExpressionFilter_javaBody_feature = Java Body -_UI_OCLFilter_OCLBody_feature = OCL Body -_UI_AbstractElementBinding_bindingFilters_feature = Binding Filters -_UI_StrictTypingFilter_type = Strict Typing Filter -_UI_StrictTypingFilter_type_feature = Type -pluginName = Mapping Edit Support -providerName = www.example.org - _UI_SmartModelNavigation_type = Smart Model Navigation -_UI_NavigationStep_type = Step -_UI_DeclarativeNavigationStep_type = Declarative Navigation Step -_UI_StepInitializer_type = Step Initializer -_UI_JavaStepInitializer_type = Java Step Initializer -_UI_JavaDeclarationExpression_type = Java Declaration Expression -_UI_JavaBodyExpression_type = Java Body Expression -_UI_JavaDeclarationStepInitializer_type = Java Declaration Step Initializer -_UI_JavaBodyStepInitializer_type = Java Body Step Initializer -_UI_StepFilter_type = Step Filter -_UI_JavaStepFilter_type = Java Step Filter -_UI_JavaBodyStepFilter_type = Java Body Step Filter -_UI_JavaDeclarationStepFilter_type = Java Declaration Step Filter -_UI_SmartModelNavigation_step_feature = Step -_UI_NavigationStep_subStep_feature = Sub Step -_UI_NavigationStep_initializer_feature = Initializer -_UI_NavigationStep_filters_feature = Filters -_UI_DeclarativeNavigationStep_index_feature = Index -_UI_DeclarativeNavigationStep_feature_feature = Feature -_UI_DeclarativeNavigationStep_discriminatorType_feature = Discriminator Type -_UI_JavaDeclarationExpression_qualifiedClass_feature = Qualified Class -_UI_JavaDeclarationExpression_methodFilter_feature = Method Filter -_UI_JavaDeclarationExpression_staticMethod_feature = Static Method -_UI_JavaBodyExpression_body_feature = Body -_UI_JavaDeclarationExpression_methodName_feature = Method Name -_UI_EditorSettings_type = Editor Settings -_UI_EMFPropertyBinding_editorSetting_feature = Editor Setting -_UI_EReferenceViewerSettings_type = EReference Viewer Settings -_UI_EReferenceViewerSettings_model_feature = Model -_UI_EReferenceViewerSettings_filter_feature = Filter diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/plugin.xml b/plugins/org.eclipse.emf.eef.mapping.edit/plugin.xml deleted file mode 100644 index fb331f511..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/plugin.xml +++ /dev/null @@ -1,565 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/pom.xml b/plugins/org.eclipse.emf.eef.mapping.edit/pom.xml deleted file mode 100644 index a3cb98a7e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/pom.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.mapping.edit - eclipse-plugin - - EEF Mapping Edit Plug-in - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/filters_properties.plugin.xml b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/filters_properties.plugin.xml deleted file mode 100644 index 20b0b2285..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/filters_properties.plugin.xml +++ /dev/null @@ -1,195 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/mapping_properties.plugin.xml b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/mapping_properties.plugin.xml deleted file mode 100644 index a5ed9fad7..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/mapping_properties.plugin.xml +++ /dev/null @@ -1,169 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/navigation_properties.plugin.xml b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/navigation_properties.plugin.xml deleted file mode 100644 index 1696b403d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/navigation_properties.plugin.xml +++ /dev/null @@ -1,97 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaBodyStepFilterPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaBodyStepFilterPropertiesEditionComponent.java deleted file mode 100644 index 43f02c89f..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaBodyStepFilterPropertiesEditionComponent.java +++ /dev/null @@ -1,197 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; - -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; - -import org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter; - -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaBodyStepFilterPropertiesEditionPart; - -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaBodyStepFilterPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public JavaBodyStepFilterPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject javaBodyStepFilter, String editing_mode) { - super(editingContext, javaBodyStepFilter, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = FiltersViewsRepository.class; - partKey = FiltersViewsRepository.JavaBodyStepFilter.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final JavaBodyStepFilter javaBodyStepFilter = (JavaBodyStepFilter)elt; - final JavaBodyStepFilterPropertiesEditionPart basePart = (JavaBodyStepFilterPropertiesEditionPart)editingPart; - // init values - if (isAccessible(FiltersViewsRepository.JavaBodyStepFilter.Properties.body)) - basePart.setBody(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, javaBodyStepFilter.getBody())); - // init filters - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == FiltersViewsRepository.JavaBodyStepFilter.Properties.body) { - return NavigationPackage.eINSTANCE.getJavaBodyExpression_Body(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - JavaBodyStepFilter javaBodyStepFilter = (JavaBodyStepFilter)semanticObject; - if (FiltersViewsRepository.JavaBodyStepFilter.Properties.body == event.getAffectedEditor()) { - javaBodyStepFilter.setBody((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - JavaBodyStepFilterPropertiesEditionPart basePart = (JavaBodyStepFilterPropertiesEditionPart)editingPart; - if (NavigationPackage.eINSTANCE.getJavaBodyExpression_Body().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(FiltersViewsRepository.JavaBodyStepFilter.Properties.body)){ - if (msg.getNewValue() != null) { - basePart.setBody(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setBody(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - NavigationPackage.eINSTANCE.getJavaBodyExpression_Body() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == FiltersViewsRepository.JavaBodyStepFilter.Properties.body; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (FiltersViewsRepository.JavaBodyStepFilter.Properties.body == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(NavigationPackage.eINSTANCE.getJavaBodyExpression_Body().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(NavigationPackage.eINSTANCE.getJavaBodyExpression_Body().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationFilterBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationFilterBasePropertiesEditionComponent.java deleted file mode 100644 index fec510185..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationFilterBasePropertiesEditionComponent.java +++ /dev/null @@ -1,199 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaDeclarationFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationFilterBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public JavaDeclarationFilterBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject javaDeclarationFilter, String editing_mode) { - super(editingContext, javaDeclarationFilter, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = FiltersViewsRepository.class; - partKey = FiltersViewsRepository.JavaDeclarationFilter.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final JavaDeclarationFilter javaDeclarationFilter = (JavaDeclarationFilter)elt; - final JavaDeclarationFilterPropertiesEditionPart basePart = (JavaDeclarationFilterPropertiesEditionPart)editingPart; - // init values - if (isAccessible(FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName)) - basePart.setMethodName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, javaDeclarationFilter.getMethodName())); - - // init filters - - // init values for referenced views - basePart.getFilterPropertiesReferencedView().setContext(elt, allResource); - - // init filters for referenced views - - - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName) { - return FiltersPackage.eINSTANCE.getJavaDeclarationFilter_MethodName(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - JavaDeclarationFilter javaDeclarationFilter = (JavaDeclarationFilter)semanticObject; - if (FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName == event.getAffectedEditor()) { - javaDeclarationFilter.setMethodName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - JavaDeclarationFilterPropertiesEditionPart basePart = (JavaDeclarationFilterPropertiesEditionPart)editingPart; - if (FiltersPackage.eINSTANCE.getJavaDeclarationFilter_MethodName().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName)) { - if (msg.getNewValue() != null) { - basePart.setMethodName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setMethodName(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - FiltersPackage.eINSTANCE.getBindingFilter_Name(), - FiltersPackage.eINSTANCE.getBindingFilter_Mandatory(), - FiltersPackage.eINSTANCE.getJavaDeclarationFilter_MethodName() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getJavaDeclarationFilter_MethodName().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getJavaDeclarationFilter_MethodName().getEAttributeType(), newValue); - } - if (MappingViewsRepository.FilterProperties.FilterProperties_.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), newValue); - } - if (MappingViewsRepository.FilterProperties.FilterProperties_.mandatory == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationFilterPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationFilterPropertiesEditionComponent.java deleted file mode 100644 index 60ee2ee36..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationFilterPropertiesEditionComponent.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaDeclarationFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationFilterPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private JavaDeclarationFilterPropertiesEditionPart basePart; - - /** - * The JavaDeclarationFilterBasePropertiesEditionComponent sub component - * - */ - protected JavaDeclarationFilterBasePropertiesEditionComponent javaDeclarationFilterBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * The FilterPropertiesPropertiesEditionComponent sub component - * - */ - protected FilterPropertiesPropertiesEditionComponent filterPropertiesPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param javaDeclarationFilter the EObject to edit - * - */ - public JavaDeclarationFilterPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject javaDeclarationFilter, String editing_mode) { - super(editingContext, editing_mode); - if (javaDeclarationFilter instanceof JavaDeclarationFilter) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(javaDeclarationFilter, PropertiesEditingProvider.class); - javaDeclarationFilterBasePropertiesEditionComponent = (JavaDeclarationFilterBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, JavaDeclarationFilterBasePropertiesEditionComponent.BASE_PART, JavaDeclarationFilterBasePropertiesEditionComponent.class); - addSubComponent(javaDeclarationFilterBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(javaDeclarationFilter, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(javaDeclarationFilter, PropertiesEditingProvider.class); - filterPropertiesPropertiesEditionComponent = (FilterPropertiesPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART, FilterPropertiesPropertiesEditionComponent.class); - addSubComponent(filterPropertiesPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (JavaDeclarationFilterBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (JavaDeclarationFilterPropertiesEditionPart)javaDeclarationFilterBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (FiltersViewsRepository.JavaDeclarationFilter.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (JavaDeclarationFilterPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == FiltersViewsRepository.JavaDeclarationFilter.class) { - super.initPart(key, kind, element, allResource); - filterPropertiesPropertiesEditionComponent.setPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, kind, basePart.getFilterPropertiesReferencedView()); - filterPropertiesPropertiesEditionComponent.initPart(MappingViewsRepository.FilterProperties.class, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.FilterProperties.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationStepFilterPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationStepFilterPropertiesEditionComponent.java deleted file mode 100644 index c655258e1..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaDeclarationStepFilterPropertiesEditionComponent.java +++ /dev/null @@ -1,246 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; - -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; - -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter; - -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart; - -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationStepFilterPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public JavaDeclarationStepFilterPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject javaDeclarationStepFilter, String editing_mode) { - super(editingContext, javaDeclarationStepFilter, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = FiltersViewsRepository.class; - partKey = FiltersViewsRepository.JavaDeclarationStepFilter.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final JavaDeclarationStepFilter javaDeclarationStepFilter = (JavaDeclarationStepFilter)elt; - final JavaDeclarationStepFilterPropertiesEditionPart basePart = (JavaDeclarationStepFilterPropertiesEditionPart)editingPart; - // init values - if (isAccessible(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass)) - basePart.setQualifiedClass(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, javaDeclarationStepFilter.getQualifiedClass())); - - if (isAccessible(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter)) - basePart.setMethodFilter(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, javaDeclarationStepFilter.getMethodName())); - - if (isAccessible(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod)) { - basePart.setStaticMethod(javaDeclarationStepFilter.isStaticMethod()); - } - // init filters - - - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass) { - return NavigationPackage.eINSTANCE.getJavaDeclarationExpression_QualifiedClass(); - } - if (editorKey == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter) { - return NavigationPackage.eINSTANCE.getJavaDeclarationExpression_MethodName(); - } - if (editorKey == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod) { - return NavigationPackage.eINSTANCE.getJavaDeclarationExpression_StaticMethod(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - JavaDeclarationStepFilter javaDeclarationStepFilter = (JavaDeclarationStepFilter)semanticObject; - if (FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass == event.getAffectedEditor()) { - javaDeclarationStepFilter.setQualifiedClass((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter == event.getAffectedEditor()) { - javaDeclarationStepFilter.setMethodName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod == event.getAffectedEditor()) { - javaDeclarationStepFilter.setStaticMethod((Boolean)event.getNewValue()); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - JavaDeclarationStepFilterPropertiesEditionPart basePart = (JavaDeclarationStepFilterPropertiesEditionPart)editingPart; - if (NavigationPackage.eINSTANCE.getJavaDeclarationExpression_QualifiedClass().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass)) { - if (msg.getNewValue() != null) { - basePart.setQualifiedClass(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setQualifiedClass(""); - } - } - if (NavigationPackage.eINSTANCE.getJavaDeclarationExpression_MethodName().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter)) { - if (msg.getNewValue() != null) { - basePart.setMethodFilter(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setMethodFilter(""); - } - } - if (NavigationPackage.eINSTANCE.getJavaDeclarationExpression_StaticMethod().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod)) - basePart.setStaticMethod((Boolean)msg.getNewValue()); - - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - NavigationPackage.eINSTANCE.getJavaDeclarationExpression_QualifiedClass(), - NavigationPackage.eINSTANCE.getJavaDeclarationExpression_MethodName(), - NavigationPackage.eINSTANCE.getJavaDeclarationExpression_StaticMethod() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass || key == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_QualifiedClass().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_QualifiedClass().getEAttributeType(), newValue); - } - if (FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_MethodName().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_MethodName().getEAttributeType(), newValue); - } - if (FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_StaticMethod().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_StaticMethod().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaExpressionFilterBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaExpressionFilterBasePropertiesEditionComponent.java deleted file mode 100644 index 2b8855281..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaExpressionFilterBasePropertiesEditionComponent.java +++ /dev/null @@ -1,198 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaExpressionFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaExpressionFilterBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public JavaExpressionFilterBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject javaExpressionFilter, String editing_mode) { - super(editingContext, javaExpressionFilter, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = FiltersViewsRepository.class; - partKey = FiltersViewsRepository.JavaExpressionFilter.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final JavaExpressionFilter javaExpressionFilter = (JavaExpressionFilter)elt; - final JavaExpressionFilterPropertiesEditionPart basePart = (JavaExpressionFilterPropertiesEditionPart)editingPart; - // init values - if (isAccessible(FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody)) - basePart.setJavaExpressionBody(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, javaExpressionFilter.getJavaBody())); - // init filters - - // init values for referenced views - basePart.getFilterPropertiesReferencedView().setContext(elt, allResource); - - // init filters for referenced views - - - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody) { - return FiltersPackage.eINSTANCE.getJavaExpressionFilter_JavaBody(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - JavaExpressionFilter javaExpressionFilter = (JavaExpressionFilter)semanticObject; - if (FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody == event.getAffectedEditor()) { - javaExpressionFilter.setJavaBody((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - JavaExpressionFilterPropertiesEditionPart basePart = (JavaExpressionFilterPropertiesEditionPart)editingPart; - if (FiltersPackage.eINSTANCE.getJavaExpressionFilter_JavaBody().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody)){ - if (msg.getNewValue() != null) { - basePart.setJavaExpressionBody(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setJavaExpressionBody(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - FiltersPackage.eINSTANCE.getBindingFilter_Name(), - FiltersPackage.eINSTANCE.getBindingFilter_Mandatory(), - FiltersPackage.eINSTANCE.getJavaExpressionFilter_JavaBody() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getJavaExpressionFilter_JavaBody().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getJavaExpressionFilter_JavaBody().getEAttributeType(), newValue); - } - if (MappingViewsRepository.FilterProperties.FilterProperties_.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), newValue); - } - if (MappingViewsRepository.FilterProperties.FilterProperties_.mandatory == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaExpressionFilterPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaExpressionFilterPropertiesEditionComponent.java deleted file mode 100644 index d7af9f33a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/JavaExpressionFilterPropertiesEditionComponent.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaExpressionFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaExpressionFilterPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private JavaExpressionFilterPropertiesEditionPart basePart; - - /** - * The JavaExpressionFilterBasePropertiesEditionComponent sub component - * - */ - protected JavaExpressionFilterBasePropertiesEditionComponent javaExpressionFilterBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * The FilterPropertiesPropertiesEditionComponent sub component - * - */ - protected FilterPropertiesPropertiesEditionComponent filterPropertiesPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param javaExpressionFilter the EObject to edit - * - */ - public JavaExpressionFilterPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject javaExpressionFilter, String editing_mode) { - super(editingContext, editing_mode); - if (javaExpressionFilter instanceof JavaExpressionFilter) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(javaExpressionFilter, PropertiesEditingProvider.class); - javaExpressionFilterBasePropertiesEditionComponent = (JavaExpressionFilterBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, JavaExpressionFilterBasePropertiesEditionComponent.BASE_PART, JavaExpressionFilterBasePropertiesEditionComponent.class); - addSubComponent(javaExpressionFilterBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(javaExpressionFilter, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(javaExpressionFilter, PropertiesEditingProvider.class); - filterPropertiesPropertiesEditionComponent = (FilterPropertiesPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART, FilterPropertiesPropertiesEditionComponent.class); - addSubComponent(filterPropertiesPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (JavaExpressionFilterBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (JavaExpressionFilterPropertiesEditionPart)javaExpressionFilterBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (FiltersViewsRepository.JavaExpressionFilter.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (JavaExpressionFilterPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == FiltersViewsRepository.JavaExpressionFilter.class) { - super.initPart(key, kind, element, allResource); - filterPropertiesPropertiesEditionComponent.setPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, kind, basePart.getFilterPropertiesReferencedView()); - filterPropertiesPropertiesEditionComponent.initPart(MappingViewsRepository.FilterProperties.class, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.FilterProperties.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OCLFilterBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OCLFilterBasePropertiesEditionComponent.java deleted file mode 100644 index 34e14c5a7..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OCLFilterBasePropertiesEditionComponent.java +++ /dev/null @@ -1,198 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.OCLFilter; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.OCLFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class OCLFilterBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public OCLFilterBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject oCLFilter, String editing_mode) { - super(editingContext, oCLFilter, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = FiltersViewsRepository.class; - partKey = FiltersViewsRepository.OCLFilter.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final OCLFilter oCLFilter = (OCLFilter)elt; - final OCLFilterPropertiesEditionPart basePart = (OCLFilterPropertiesEditionPart)editingPart; - // init values - if (isAccessible(FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody)) - basePart.setOCLExpressionBody(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, oCLFilter.getOCLBody())); - // init filters - - // init values for referenced views - basePart.getFilterPropertiesReferencedView().setContext(elt, allResource); - - // init filters for referenced views - - - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody) { - return FiltersPackage.eINSTANCE.getOCLFilter_OCLBody(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - OCLFilter oCLFilter = (OCLFilter)semanticObject; - if (FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody == event.getAffectedEditor()) { - oCLFilter.setOCLBody((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - OCLFilterPropertiesEditionPart basePart = (OCLFilterPropertiesEditionPart)editingPart; - if (FiltersPackage.eINSTANCE.getOCLFilter_OCLBody().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody)){ - if (msg.getNewValue() != null) { - basePart.setOCLExpressionBody(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setOCLExpressionBody(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - FiltersPackage.eINSTANCE.getBindingFilter_Name(), - FiltersPackage.eINSTANCE.getBindingFilter_Mandatory(), - FiltersPackage.eINSTANCE.getOCLFilter_OCLBody() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getOCLFilter_OCLBody().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getOCLFilter_OCLBody().getEAttributeType(), newValue); - } - if (MappingViewsRepository.FilterProperties.FilterProperties_.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), newValue); - } - if (MappingViewsRepository.FilterProperties.FilterProperties_.mandatory == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OCLFilterPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OCLFilterPropertiesEditionComponent.java deleted file mode 100644 index 1973f0824..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OCLFilterPropertiesEditionComponent.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.filters.OCLFilter; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.OCLFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class OCLFilterPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private OCLFilterPropertiesEditionPart basePart; - - /** - * The OCLFilterBasePropertiesEditionComponent sub component - * - */ - protected OCLFilterBasePropertiesEditionComponent oCLFilterBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * The FilterPropertiesPropertiesEditionComponent sub component - * - */ - protected FilterPropertiesPropertiesEditionComponent filterPropertiesPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param oCLFilter the EObject to edit - * - */ - public OCLFilterPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject oCLFilter, String editing_mode) { - super(editingContext, editing_mode); - if (oCLFilter instanceof OCLFilter) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(oCLFilter, PropertiesEditingProvider.class); - oCLFilterBasePropertiesEditionComponent = (OCLFilterBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, OCLFilterBasePropertiesEditionComponent.BASE_PART, OCLFilterBasePropertiesEditionComponent.class); - addSubComponent(oCLFilterBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(oCLFilter, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(oCLFilter, PropertiesEditingProvider.class); - filterPropertiesPropertiesEditionComponent = (FilterPropertiesPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART, FilterPropertiesPropertiesEditionComponent.class); - addSubComponent(filterPropertiesPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (OCLFilterBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (OCLFilterPropertiesEditionPart)oCLFilterBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (FiltersViewsRepository.OCLFilter.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (OCLFilterPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == FiltersViewsRepository.OCLFilter.class) { - super.initPart(key, kind, element, allResource); - filterPropertiesPropertiesEditionComponent.setPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, kind, basePart.getFilterPropertiesReferencedView()); - filterPropertiesPropertiesEditionComponent.initPart(MappingViewsRepository.FilterProperties.class, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.FilterProperties.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OnlyReferenceTypeFilterBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OnlyReferenceTypeFilterBasePropertiesEditionComponent.java deleted file mode 100644 index d180adff3..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OnlyReferenceTypeFilterBasePropertiesEditionComponent.java +++ /dev/null @@ -1,233 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcoreFactory; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class OnlyReferenceTypeFilterBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for referencedFeature EObjectFlatComboViewer - */ - private EObjectFlatComboSettings referencedFeatureSettings; - - - /** - * Default constructor - * - */ - public OnlyReferenceTypeFilterBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject onlyReferenceTypeFilter, String editing_mode) { - super(editingContext, onlyReferenceTypeFilter, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = FiltersViewsRepository.class; - partKey = FiltersViewsRepository.OnlyReferenceTypeFilter.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final OnlyReferenceTypeFilter onlyReferenceTypeFilter = (OnlyReferenceTypeFilter)elt; - final OnlyReferenceTypeFilterPropertiesEditionPart basePart = (OnlyReferenceTypeFilterPropertiesEditionPart)editingPart; - // init values - if (isAccessible(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_)) { - // init part - referencedFeatureSettings = new EObjectFlatComboSettings(onlyReferenceTypeFilter, FiltersPackage.eINSTANCE.getOnlyReferenceTypeFilter_Reference()); - basePart.initReferencedFeature(referencedFeatureSettings); - // set the button mode - basePart.setReferencedFeatureButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - if (isAccessible(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_)) { - basePart.addFilterToReferencedFeature(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof String && element.equals("")) || (element instanceof EReference); //$NON-NLS-1$ - } - - }); - // Start of user code for additional businessfilters for referencedFeature - - // End of user code - } - // init values for referenced views - basePart.getFilterPropertiesReferencedView().setContext(elt, allResource); - - // init filters for referenced views - - - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_) { - return FiltersPackage.eINSTANCE.getOnlyReferenceTypeFilter_Reference(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - OnlyReferenceTypeFilter onlyReferenceTypeFilter = (OnlyReferenceTypeFilter)semanticObject; - if (FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_ == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - referencedFeatureSettings.setToReference((EReference)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReference eObject = EcoreFactory.eINSTANCE.createEReference(); - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - referencedFeatureSettings.setToReference(eObject); - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - OnlyReferenceTypeFilterPropertiesEditionPart basePart = (OnlyReferenceTypeFilterPropertiesEditionPart)editingPart; - if (FiltersPackage.eINSTANCE.getOnlyReferenceTypeFilter_Reference().equals(msg.getFeature()) && basePart != null && isAccessible(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_)) - basePart.setReferencedFeature((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - FiltersPackage.eINSTANCE.getBindingFilter_Name(), - FiltersPackage.eINSTANCE.getBindingFilter_Mandatory(), - FiltersPackage.eINSTANCE.getOnlyReferenceTypeFilter_Reference() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (MappingViewsRepository.FilterProperties.FilterProperties_.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), newValue); - } - if (MappingViewsRepository.FilterProperties.FilterProperties_.mandatory == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OnlyReferenceTypeFilterPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OnlyReferenceTypeFilterPropertiesEditionComponent.java deleted file mode 100644 index 76c57148e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/OnlyReferenceTypeFilterPropertiesEditionComponent.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class OnlyReferenceTypeFilterPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private OnlyReferenceTypeFilterPropertiesEditionPart basePart; - - /** - * The OnlyReferenceTypeFilterBasePropertiesEditionComponent sub component - * - */ - protected OnlyReferenceTypeFilterBasePropertiesEditionComponent onlyReferenceTypeFilterBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * The FilterPropertiesPropertiesEditionComponent sub component - * - */ - protected FilterPropertiesPropertiesEditionComponent filterPropertiesPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param onlyReferenceTypeFilter the EObject to edit - * - */ - public OnlyReferenceTypeFilterPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject onlyReferenceTypeFilter, String editing_mode) { - super(editingContext, editing_mode); - if (onlyReferenceTypeFilter instanceof OnlyReferenceTypeFilter) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(onlyReferenceTypeFilter, PropertiesEditingProvider.class); - onlyReferenceTypeFilterBasePropertiesEditionComponent = (OnlyReferenceTypeFilterBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, OnlyReferenceTypeFilterBasePropertiesEditionComponent.BASE_PART, OnlyReferenceTypeFilterBasePropertiesEditionComponent.class); - addSubComponent(onlyReferenceTypeFilterBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(onlyReferenceTypeFilter, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(onlyReferenceTypeFilter, PropertiesEditingProvider.class); - filterPropertiesPropertiesEditionComponent = (FilterPropertiesPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART, FilterPropertiesPropertiesEditionComponent.class); - addSubComponent(filterPropertiesPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (OnlyReferenceTypeFilterBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (OnlyReferenceTypeFilterPropertiesEditionPart)onlyReferenceTypeFilterBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (FiltersViewsRepository.OnlyReferenceTypeFilter.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (OnlyReferenceTypeFilterPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == FiltersViewsRepository.OnlyReferenceTypeFilter.class) { - super.initPart(key, kind, element, allResource); - filterPropertiesPropertiesEditionComponent.setPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, kind, basePart.getFilterPropertiesReferencedView()); - filterPropertiesPropertiesEditionComponent.initPart(MappingViewsRepository.FilterProperties.class, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.FilterProperties.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/StrictTypingFilterFilterPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/StrictTypingFilterFilterPropertiesEditionComponent.java deleted file mode 100644 index 5f188053e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/StrictTypingFilterFilterPropertiesEditionComponent.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.filters.StrictTypingFilter; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.StrictTypingFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StrictTypingFilterFilterPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The StrictTypingFilter part - * - */ - private StrictTypingFilterPropertiesEditionPart strictTypingFilterPart; - - /** - * The StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent sub component - * - */ - protected StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent strictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * The FilterPropertiesPropertiesEditionComponent sub component - * - */ - protected FilterPropertiesPropertiesEditionComponent filterPropertiesPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param strictTypingFilter the EObject to edit - * - */ - public StrictTypingFilterFilterPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject strictTypingFilter, String editing_mode) { - super(editingContext, editing_mode); - if (strictTypingFilter instanceof StrictTypingFilter) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(strictTypingFilter, PropertiesEditingProvider.class); - strictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent = (StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.STRICTTYPINGFILTER_PART, StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.class); - addSubComponent(strictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(strictTypingFilter, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(strictTypingFilter, PropertiesEditingProvider.class); - filterPropertiesPropertiesEditionComponent = (FilterPropertiesPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART, FilterPropertiesPropertiesEditionComponent.class); - addSubComponent(filterPropertiesPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.STRICTTYPINGFILTER_PART.equals(key)) { - strictTypingFilterPart = (StrictTypingFilterPropertiesEditionPart)strictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)strictTypingFilterPart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (FiltersViewsRepository.StrictTypingFilter.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - strictTypingFilterPart = (StrictTypingFilterPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == FiltersViewsRepository.StrictTypingFilter.class) { - super.initPart(key, kind, element, allResource); - filterPropertiesPropertiesEditionComponent.setPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, kind, strictTypingFilterPart.getFilterPropertiesReferencedView()); - filterPropertiesPropertiesEditionComponent.initPart(MappingViewsRepository.FilterProperties.class, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.FilterProperties.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.java deleted file mode 100644 index 612ecc822..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/components/StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.java +++ /dev/null @@ -1,241 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.StrictTypingFilter; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.StrictTypingFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String STRICTTYPINGFILTER_PART = "StrictTypingFilter"; //$NON-NLS-1$ - - - /** - * Settings for type EObjectFlatComboViewer - */ - private EObjectFlatComboSettings typeSettings; - - - /** - * Default constructor - * - */ - public StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject strictTypingFilter, String editing_mode) { - super(editingContext, strictTypingFilter, editing_mode); - parts = new String[] { STRICTTYPINGFILTER_PART }; - repositoryKey = FiltersViewsRepository.class; - partKey = FiltersViewsRepository.StrictTypingFilter.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final StrictTypingFilter strictTypingFilter = (StrictTypingFilter)elt; - final StrictTypingFilterPropertiesEditionPart strictTypingFilterPart = (StrictTypingFilterPropertiesEditionPart)editingPart; - // init values - if (isAccessible(FiltersViewsRepository.StrictTypingFilter.Type.restriction)) { - // init part - typeSettings = new EObjectFlatComboSettings(strictTypingFilter, FiltersPackage.eINSTANCE.getStrictTypingFilter_Type()); - strictTypingFilterPart.initRestriction(typeSettings); - // set the button mode - strictTypingFilterPart.setRestrictionButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - if (isAccessible(FiltersViewsRepository.StrictTypingFilter.Type.restriction)) { - strictTypingFilterPart.addFilterToRestriction(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EClassifier); - } - - }); - // Start of user code for additional businessfilters for type - - // End of user code - } - // init values for referenced views - strictTypingFilterPart.getFilterPropertiesReferencedView().setContext(elt, allResource); - - // init filters for referenced views - - - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == FiltersViewsRepository.StrictTypingFilter.Type.restriction) { - return FiltersPackage.eINSTANCE.getStrictTypingFilter_Type(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - StrictTypingFilter strictTypingFilter = (StrictTypingFilter)semanticObject; - if (FiltersViewsRepository.StrictTypingFilter.Type.restriction == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - typeSettings.setToReference((EClassifier)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, typeSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - StrictTypingFilterPropertiesEditionPart strictTypingFilterPart = (StrictTypingFilterPropertiesEditionPart)editingPart; - if (FiltersPackage.eINSTANCE.getStrictTypingFilter_Type().equals(msg.getFeature()) && strictTypingFilterPart != null && isAccessible(FiltersViewsRepository.StrictTypingFilter.Type.restriction)) - strictTypingFilterPart.setRestriction((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - FiltersPackage.eINSTANCE.getBindingFilter_Name(), - FiltersPackage.eINSTANCE.getBindingFilter_Mandatory(), - FiltersPackage.eINSTANCE.getStrictTypingFilter_Type() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == FiltersViewsRepository.StrictTypingFilter.Type.restriction; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (MappingViewsRepository.FilterProperties.FilterProperties_.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), newValue); - } - if (MappingViewsRepository.FilterProperties.FilterProperties_.mandatory == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/FiltersEEFAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/FiltersEEFAdapterFactory.java deleted file mode 100644 index 7c8fd5505..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/FiltersEEFAdapterFactory.java +++ /dev/null @@ -1,119 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.providers; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.notify.Adapter; - -import org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory; - -import org.eclipse.emf.eef.mapping.providers.DocumentedElementPropertiesEditionProvider; -import org.eclipse.emf.eef.mapping.providers.FilterPropertiesPropertiesEditionProvider; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -/** - * @author Nathalie Lepine - * - */ -public class FiltersEEFAdapterFactory extends FiltersAdapterFactory { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory#createDocumentedElementAdapter() - * - */ - public Adapter createDocumentedElementAdapter() { - return new DocumentedElementPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory#createBindingFilterAdapter() - * - */ - public Adapter createBindingFilterAdapter() { - return new FilterPropertiesPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory#createOCLFilterAdapter() - * - */ - public Adapter createOCLFilterAdapter() { - List providers = new ArrayList(2); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - providers.add((PropertiesEditingProvider)createBindingFilterAdapter()); - return new OCLFilterPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory#createJavaDeclarationFilterAdapter() - * - */ - public Adapter createJavaDeclarationFilterAdapter() { - List providers = new ArrayList(2); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - providers.add((PropertiesEditingProvider)createBindingFilterAdapter()); - return new JavaDeclarationFilterPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory#createJavaExpressionFilterAdapter() - * - */ - public Adapter createJavaExpressionFilterAdapter() { - List providers = new ArrayList(2); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - providers.add((PropertiesEditingProvider)createBindingFilterAdapter()); - return new JavaExpressionFilterPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory#createOnlyReferenceTypeFilterAdapter() - * - */ - public Adapter createOnlyReferenceTypeFilterAdapter() { - List providers = new ArrayList(2); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - providers.add((PropertiesEditingProvider)createBindingFilterAdapter()); - return new OnlyReferenceTypeFilterPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory#createStrictTypingFilterAdapter() - * - */ - public Adapter createStrictTypingFilterAdapter() { - List providers = new ArrayList(2); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - providers.add((PropertiesEditingProvider)createBindingFilterAdapter()); - return new StrictTypingFilterFilterPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory#createJavaBodyStepFilterAdapter() - * - */ - public Adapter createJavaBodyStepFilterAdapter() { - return new JavaBodyStepFilterPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory#createJavaDeclarationStepFilterAdapter() - * - */ - public Adapter createJavaDeclarationStepFilterAdapter() { - return new JavaDeclarationStepFilterPropertiesEditionProvider(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaBodyStepFilterPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaBodyStepFilterPropertiesEditionProvider.java deleted file mode 100644 index 17f70513b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaBodyStepFilterPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.filters.components.JavaBodyStepFilterPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class JavaBodyStepFilterPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public JavaBodyStepFilterPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public JavaBodyStepFilterPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof JavaBodyStepFilter) - && (FiltersPackage.Literals.JAVA_BODY_STEP_FILTER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof JavaBodyStepFilter) && (JavaBodyStepFilterPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaBodyStepFilter) && (refinement == JavaBodyStepFilterPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaBodyStepFilter) && ((JavaBodyStepFilterPropertiesEditionComponent.BASE_PART.equals(part) && refinement == JavaBodyStepFilterPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof JavaBodyStepFilter) { - return new JavaBodyStepFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof JavaBodyStepFilter) { - if (JavaBodyStepFilterPropertiesEditionComponent.BASE_PART.equals(part)) - return new JavaBodyStepFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof JavaBodyStepFilter) { - if (JavaBodyStepFilterPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == JavaBodyStepFilterPropertiesEditionComponent.class) - return new JavaBodyStepFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && FiltersPackage.Literals.JAVA_BODY_STEP_FILTER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaDeclarationFilterPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaDeclarationFilterPropertiesEditionProvider.java deleted file mode 100644 index 1da88b3b9..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaDeclarationFilterPropertiesEditionProvider.java +++ /dev/null @@ -1,164 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.filters.components.JavaDeclarationFilterBasePropertiesEditionComponent; -import org.eclipse.emf.eef.filters.components.JavaDeclarationFilterPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationFilterPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public JavaDeclarationFilterPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public JavaDeclarationFilterPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof JavaDeclarationFilter) - && (FiltersPackage.Literals.JAVA_DECLARATION_FILTER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof JavaDeclarationFilter) && (JavaDeclarationFilterBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) || FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaDeclarationFilter) && (refinement == JavaDeclarationFilterBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class || refinement == FilterPropertiesPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaDeclarationFilter) && ((JavaDeclarationFilterBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == JavaDeclarationFilterBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class) || (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) && refinement == FilterPropertiesPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof JavaDeclarationFilter) { - return new JavaDeclarationFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof JavaDeclarationFilter) { - if (JavaDeclarationFilterBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new JavaDeclarationFilterBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof JavaDeclarationFilter) { - if (JavaDeclarationFilterBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == JavaDeclarationFilterBasePropertiesEditionComponent.class) - return new JavaDeclarationFilterBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) - && refinement == FilterPropertiesPropertiesEditionComponent.class) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && FiltersPackage.Literals.JAVA_DECLARATION_FILTER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaDeclarationStepFilterPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaDeclarationStepFilterPropertiesEditionProvider.java deleted file mode 100644 index e5ac8fe52..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaDeclarationStepFilterPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.filters.components.JavaDeclarationStepFilterPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationStepFilterPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public JavaDeclarationStepFilterPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public JavaDeclarationStepFilterPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof JavaDeclarationStepFilter) - && (FiltersPackage.Literals.JAVA_DECLARATION_STEP_FILTER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof JavaDeclarationStepFilter) && (JavaDeclarationStepFilterPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaDeclarationStepFilter) && (refinement == JavaDeclarationStepFilterPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaDeclarationStepFilter) && ((JavaDeclarationStepFilterPropertiesEditionComponent.BASE_PART.equals(part) && refinement == JavaDeclarationStepFilterPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof JavaDeclarationStepFilter) { - return new JavaDeclarationStepFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof JavaDeclarationStepFilter) { - if (JavaDeclarationStepFilterPropertiesEditionComponent.BASE_PART.equals(part)) - return new JavaDeclarationStepFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof JavaDeclarationStepFilter) { - if (JavaDeclarationStepFilterPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == JavaDeclarationStepFilterPropertiesEditionComponent.class) - return new JavaDeclarationStepFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && FiltersPackage.Literals.JAVA_DECLARATION_STEP_FILTER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaExpressionFilterPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaExpressionFilterPropertiesEditionProvider.java deleted file mode 100644 index ff4ca2912..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/JavaExpressionFilterPropertiesEditionProvider.java +++ /dev/null @@ -1,164 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.filters.components.JavaExpressionFilterBasePropertiesEditionComponent; -import org.eclipse.emf.eef.filters.components.JavaExpressionFilterPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class JavaExpressionFilterPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public JavaExpressionFilterPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public JavaExpressionFilterPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof JavaExpressionFilter) - && (FiltersPackage.Literals.JAVA_EXPRESSION_FILTER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof JavaExpressionFilter) && (JavaExpressionFilterBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) || FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaExpressionFilter) && (refinement == JavaExpressionFilterBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class || refinement == FilterPropertiesPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaExpressionFilter) && ((JavaExpressionFilterBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == JavaExpressionFilterBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class) || (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) && refinement == FilterPropertiesPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof JavaExpressionFilter) { - return new JavaExpressionFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof JavaExpressionFilter) { - if (JavaExpressionFilterBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new JavaExpressionFilterBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof JavaExpressionFilter) { - if (JavaExpressionFilterBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == JavaExpressionFilterBasePropertiesEditionComponent.class) - return new JavaExpressionFilterBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) - && refinement == FilterPropertiesPropertiesEditionComponent.class) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && FiltersPackage.Literals.JAVA_EXPRESSION_FILTER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/OCLFilterPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/OCLFilterPropertiesEditionProvider.java deleted file mode 100644 index ad4b8304a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/OCLFilterPropertiesEditionProvider.java +++ /dev/null @@ -1,164 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.filters.components.OCLFilterBasePropertiesEditionComponent; -import org.eclipse.emf.eef.filters.components.OCLFilterPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.OCLFilter; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class OCLFilterPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public OCLFilterPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public OCLFilterPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof OCLFilter) - && (FiltersPackage.Literals.OCL_FILTER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof OCLFilter) && (OCLFilterBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) || FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof OCLFilter) && (refinement == OCLFilterBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class || refinement == FilterPropertiesPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof OCLFilter) && ((OCLFilterBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == OCLFilterBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class) || (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) && refinement == FilterPropertiesPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof OCLFilter) { - return new OCLFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof OCLFilter) { - if (OCLFilterBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new OCLFilterBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof OCLFilter) { - if (OCLFilterBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == OCLFilterBasePropertiesEditionComponent.class) - return new OCLFilterBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) - && refinement == FilterPropertiesPropertiesEditionComponent.class) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && FiltersPackage.Literals.OCL_FILTER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/OnlyReferenceTypeFilterPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/OnlyReferenceTypeFilterPropertiesEditionProvider.java deleted file mode 100644 index 5d167f7e9..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/OnlyReferenceTypeFilterPropertiesEditionProvider.java +++ /dev/null @@ -1,164 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.filters.components.OnlyReferenceTypeFilterBasePropertiesEditionComponent; -import org.eclipse.emf.eef.filters.components.OnlyReferenceTypeFilterPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class OnlyReferenceTypeFilterPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public OnlyReferenceTypeFilterPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public OnlyReferenceTypeFilterPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof OnlyReferenceTypeFilter) - && (FiltersPackage.Literals.ONLY_REFERENCE_TYPE_FILTER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof OnlyReferenceTypeFilter) && (OnlyReferenceTypeFilterBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) || FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof OnlyReferenceTypeFilter) && (refinement == OnlyReferenceTypeFilterBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class || refinement == FilterPropertiesPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof OnlyReferenceTypeFilter) && ((OnlyReferenceTypeFilterBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == OnlyReferenceTypeFilterBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class) || (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) && refinement == FilterPropertiesPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof OnlyReferenceTypeFilter) { - return new OnlyReferenceTypeFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof OnlyReferenceTypeFilter) { - if (OnlyReferenceTypeFilterBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new OnlyReferenceTypeFilterBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof OnlyReferenceTypeFilter) { - if (OnlyReferenceTypeFilterBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == OnlyReferenceTypeFilterBasePropertiesEditionComponent.class) - return new OnlyReferenceTypeFilterBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) - && refinement == FilterPropertiesPropertiesEditionComponent.class) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && FiltersPackage.Literals.ONLY_REFERENCE_TYPE_FILTER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/StrictTypingFilterFilterPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/StrictTypingFilterFilterPropertiesEditionProvider.java deleted file mode 100644 index 7906f8a4d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/filters/providers/StrictTypingFilterFilterPropertiesEditionProvider.java +++ /dev/null @@ -1,164 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.filters.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.filters.components.StrictTypingFilterFilterPropertiesEditionComponent; -import org.eclipse.emf.eef.filters.components.StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.StrictTypingFilter; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class StrictTypingFilterFilterPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public StrictTypingFilterFilterPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public StrictTypingFilterFilterPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof StrictTypingFilter) - && (FiltersPackage.Literals.STRICT_TYPING_FILTER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof StrictTypingFilter) && (StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.STRICTTYPINGFILTER_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) || FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof StrictTypingFilter) && (refinement == StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class || refinement == FilterPropertiesPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof StrictTypingFilter) && ((StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.STRICTTYPINGFILTER_PART.equals(part) && refinement == StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class) || (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) && refinement == FilterPropertiesPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof StrictTypingFilter) { - return new StrictTypingFilterFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof StrictTypingFilter) { - if (StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.STRICTTYPINGFILTER_PART.equals(part)) - return new StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof StrictTypingFilter) { - if (StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.STRICTTYPINGFILTER_PART.equals(part) - && refinement == StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent.class) - return new StrictTypingFilterFilterStrictTypingFilterPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) - && refinement == FilterPropertiesPropertiesEditionComponent.class) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && FiltersPackage.Literals.STRICT_TYPING_FILTER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/CategoryBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/CategoryBasePropertiesEditionComponent.java deleted file mode 100644 index 055b4c39f..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/CategoryBasePropertiesEditionComponent.java +++ /dev/null @@ -1,187 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.parts.CategoryPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class CategoryBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public CategoryBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject category, String editing_mode) { - super(editingContext, category, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = MappingViewsRepository.class; - partKey = MappingViewsRepository.Category.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final Category category = (Category)elt; - final CategoryPropertiesEditionPart basePart = (CategoryPropertiesEditionPart)editingPart; - // init values - if (isAccessible(MappingViewsRepository.Category.Properties.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, category.getName())); - - // init filters - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == MappingViewsRepository.Category.Properties.name) { - return MappingPackage.eINSTANCE.getCategory_Name(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - Category category = (Category)semanticObject; - if (MappingViewsRepository.Category.Properties.name == event.getAffectedEditor()) { - category.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - CategoryPropertiesEditionPart basePart = (CategoryPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getCategory_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(MappingViewsRepository.Category.Properties.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getCategory_Name() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == MappingViewsRepository.Category.Properties.name; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (MappingViewsRepository.Category.Properties.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getCategory_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getCategory_Name().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/CategoryPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/CategoryPropertiesEditionComponent.java deleted file mode 100644 index efa96aaaf..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/CategoryPropertiesEditionComponent.java +++ /dev/null @@ -1,116 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.parts.CategoryPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class CategoryPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private CategoryPropertiesEditionPart basePart; - - /** - * The CategoryBasePropertiesEditionComponent sub component - * - */ - protected CategoryBasePropertiesEditionComponent categoryBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param category the EObject to edit - * - */ - public CategoryPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject category, String editing_mode) { - super(editingContext, editing_mode); - if (category instanceof Category) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(category, PropertiesEditingProvider.class); - categoryBasePropertiesEditionComponent = (CategoryBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, CategoryBasePropertiesEditionComponent.BASE_PART, CategoryBasePropertiesEditionComponent.class); - addSubComponent(categoryBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(category, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (CategoryBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (CategoryPropertiesEditionPart)categoryBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (MappingViewsRepository.Category.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (CategoryPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == MappingViewsRepository.Category.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/DocumentedElementPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/DocumentedElementPropertiesEditionComponent.java deleted file mode 100644 index 73c859630..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/DocumentedElementPropertiesEditionComponent.java +++ /dev/null @@ -1,188 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.parts.DocumentationPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class DocumentedElementPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String DOCUMENTATION_PART = "Documentation"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public DocumentedElementPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject documentedElement, String editing_mode) { - super(editingContext, documentedElement, editing_mode); - parts = new String[] { DOCUMENTATION_PART }; - repositoryKey = MappingViewsRepository.class; - partKey = MappingViewsRepository.Documentation.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final DocumentedElement documentedElement = (DocumentedElement)elt; - final DocumentationPropertiesEditionPart documentationPart = (DocumentationPropertiesEditionPart)editingPart; - // init values - if (isAccessible(MappingViewsRepository.Documentation.Documentation_.documentation__)) - documentationPart.setDocumentation(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, documentedElement.getDocumentation())); - // init filters - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == MappingViewsRepository.Documentation.Documentation_.documentation__) { - return MappingPackage.eINSTANCE.getDocumentedElement_Documentation(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - DocumentedElement documentedElement = (DocumentedElement)semanticObject; - if (MappingViewsRepository.Documentation.Documentation_.documentation__ == event.getAffectedEditor()) { - documentedElement.setDocumentation((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - DocumentationPropertiesEditionPart documentationPart = (DocumentationPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getDocumentedElement_Documentation().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && documentationPart != null && isAccessible(MappingViewsRepository.Documentation.Documentation_.documentation__)){ - if (msg.getNewValue() != null) { - documentationPart.setDocumentation(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - documentationPart.setDocumentation(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getDocumentedElement_Documentation() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == MappingViewsRepository.Documentation.Documentation_.documentation__) - return "The documentation of the element"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (MappingViewsRepository.Documentation.Documentation_.documentation__ == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getDocumentedElement_Documentation().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getDocumentedElement_Documentation().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFElementBindingBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFElementBindingBasePropertiesEditionComponent.java deleted file mode 100644 index 7c2667d3e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFElementBindingBasePropertiesEditionComponent.java +++ /dev/null @@ -1,301 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFElementBindingBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for views ReferencesTable - */ - private ReferencesTableSettings viewsSettings; - - /** - * Settings for model EObjectFlatComboViewer - */ - private EObjectFlatComboSettings modelSettings; - - - /** - * Default constructor - * - */ - public EMFElementBindingBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eMFElementBinding, String editing_mode) { - super(editingContext, eMFElementBinding, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = MappingViewsRepository.class; - partKey = MappingViewsRepository.EMFElementBinding.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final EMFElementBinding eMFElementBinding = (EMFElementBinding)elt; - final EMFElementBindingPropertiesEditionPart basePart = (EMFElementBindingPropertiesEditionPart)editingPart; - // init values - if (isAccessible(MappingViewsRepository.EMFElementBinding.Properties.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, eMFElementBinding.getName())); - - if (isAccessible(MappingViewsRepository.EMFElementBinding.Binding.views)) { - viewsSettings = new ReferencesTableSettings(eMFElementBinding, MappingPackage.eINSTANCE.getAbstractElementBinding_Views()); - basePart.initViews(viewsSettings); - } - if (isAccessible(MappingViewsRepository.EMFElementBinding.Binding.model)) { - // init part - modelSettings = new EObjectFlatComboSettings(eMFElementBinding, MappingPackage.eINSTANCE.getEMFElementBinding_Model()); - basePart.initModel(modelSettings); - // set the button mode - basePart.setModelButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - - if (isAccessible(MappingViewsRepository.EMFElementBinding.Binding.views)) { - basePart.addFilterToViews(new EObjectFilter(ViewsPackage.Literals.VIEW)); - // Start of user code for additional businessfilters for views - - // End of user code - } - if (isAccessible(MappingViewsRepository.EMFElementBinding.Binding.model)) { - basePart.addFilterToModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EClassifier); - } - - }); - // Start of user code for additional businessfilters for model - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == MappingViewsRepository.EMFElementBinding.Properties.name) { - return MappingPackage.eINSTANCE.getAbstractElementBinding_Name(); - } - if (editorKey == MappingViewsRepository.EMFElementBinding.Binding.views) { - return MappingPackage.eINSTANCE.getAbstractElementBinding_Views(); - } - if (editorKey == MappingViewsRepository.EMFElementBinding.Binding.model) { - return MappingPackage.eINSTANCE.getEMFElementBinding_Model(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - EMFElementBinding eMFElementBinding = (EMFElementBinding)semanticObject; - if (MappingViewsRepository.EMFElementBinding.Properties.name == event.getAffectedEditor()) { - eMFElementBinding.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (MappingViewsRepository.EMFElementBinding.Binding.views == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof View) { - viewsSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - viewsSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - viewsSettings.move(event.getNewIndex(), (View) event.getNewValue()); - } - } - if (MappingViewsRepository.EMFElementBinding.Binding.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - modelSettings.setToReference((EClassifier)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, modelSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - EMFElementBindingPropertiesEditionPart basePart = (EMFElementBindingPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getAbstractElementBinding_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(MappingViewsRepository.EMFElementBinding.Properties.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (MappingPackage.eINSTANCE.getAbstractElementBinding_Views().equals(msg.getFeature()) && isAccessible(MappingViewsRepository.EMFElementBinding.Binding.views)) - basePart.updateViews(); - if (MappingPackage.eINSTANCE.getEMFElementBinding_Model().equals(msg.getFeature()) && basePart != null && isAccessible(MappingViewsRepository.EMFElementBinding.Binding.model)) - basePart.setModel((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getAbstractElementBinding_Name(), - MappingPackage.eINSTANCE.getAbstractElementBinding_Views(), - MappingPackage.eINSTANCE.getEMFElementBinding_Model() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == MappingViewsRepository.EMFElementBinding.Properties.name || key == MappingViewsRepository.EMFElementBinding.Binding.views || key == MappingViewsRepository.EMFElementBinding.Binding.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == MappingViewsRepository.EMFElementBinding.Properties.name) - return "The name of this element binding"; //$NON-NLS-1$ - if (key == MappingViewsRepository.EMFElementBinding.Binding.views) - return "The mapped views"; //$NON-NLS-1$ - if (key == MappingViewsRepository.EMFElementBinding.Binding.model) - return "The mapped classifier"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (MappingViewsRepository.EMFElementBinding.Properties.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getAbstractElementBinding_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getAbstractElementBinding_Name().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFElementBindingPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFElementBindingPropertiesEditionComponent.java deleted file mode 100644 index 256e6c2dd..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFElementBindingPropertiesEditionComponent.java +++ /dev/null @@ -1,116 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFElementBindingPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private EMFElementBindingPropertiesEditionPart basePart; - - /** - * The EMFElementBindingBasePropertiesEditionComponent sub component - * - */ - protected EMFElementBindingBasePropertiesEditionComponent eMFElementBindingBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param eMFElementBinding the EObject to edit - * - */ - public EMFElementBindingPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eMFElementBinding, String editing_mode) { - super(editingContext, editing_mode); - if (eMFElementBinding instanceof EMFElementBinding) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eMFElementBinding, PropertiesEditingProvider.class); - eMFElementBindingBasePropertiesEditionComponent = (EMFElementBindingBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, EMFElementBindingBasePropertiesEditionComponent.BASE_PART, EMFElementBindingBasePropertiesEditionComponent.class); - addSubComponent(eMFElementBindingBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eMFElementBinding, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (EMFElementBindingBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (EMFElementBindingPropertiesEditionPart)eMFElementBindingBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (MappingViewsRepository.EMFElementBinding.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (EMFElementBindingPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == MappingViewsRepository.EMFElementBinding.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFMultiPropertiesBindingBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFMultiPropertiesBindingBasePropertiesEditionComponent.java deleted file mode 100644 index c5c87ae49..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFMultiPropertiesBindingBasePropertiesEditionComponent.java +++ /dev/null @@ -1,277 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFMultiPropertiesBindingBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for views ReferencesTable - */ - private ReferencesTableSettings viewsSettings; - - /** - * Settings for model ReferencesTable - */ - private ReferencesTableSettings modelSettings; - - - /** - * Default constructor - * - */ - public EMFMultiPropertiesBindingBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eMFMultiPropertiesBinding, String editing_mode) { - super(editingContext, eMFMultiPropertiesBinding, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = MappingViewsRepository.class; - partKey = MappingViewsRepository.EMFMultiPropertiesBinding.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final EMFMultiPropertiesBinding eMFMultiPropertiesBinding = (EMFMultiPropertiesBinding)elt; - final EMFMultiPropertiesBindingPropertiesEditionPart basePart = (EMFMultiPropertiesBindingPropertiesEditionPart)editingPart; - // init values - if (isAccessible(MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, eMFMultiPropertiesBinding.getName())); - - if (isAccessible(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views)) { - viewsSettings = new ReferencesTableSettings(eMFMultiPropertiesBinding, MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views()); - basePart.initViews(viewsSettings); - } - if (isAccessible(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model)) { - modelSettings = new ReferencesTableSettings(eMFMultiPropertiesBinding, MappingPackage.eINSTANCE.getEMFMultiPropertiesBinding_Model()); - basePart.initModel(modelSettings); - } - // init filters - - if (isAccessible(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views)) { - basePart.addFilterToViews(new EObjectFilter(ViewsPackage.Literals.ELEMENT_EDITOR)); - // Start of user code for additional businessfilters for views - - // End of user code - } - if (isAccessible(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model)) { - basePart.addFilterToModel(new EObjectFilter(EcorePackage.Literals.ESTRUCTURAL_FEATURE)); - // Start of user code for additional businessfilters for model - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name) { - return MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name(); - } - if (editorKey == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views) { - return MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views(); - } - if (editorKey == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model) { - return MappingPackage.eINSTANCE.getEMFMultiPropertiesBinding_Model(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - EMFMultiPropertiesBinding eMFMultiPropertiesBinding = (EMFMultiPropertiesBinding)semanticObject; - if (MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name == event.getAffectedEditor()) { - eMFMultiPropertiesBinding.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof ElementEditor) { - viewsSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - viewsSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - viewsSettings.move(event.getNewIndex(), (ElementEditor) event.getNewValue()); - } - } - if (MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof EStructuralFeature) { - modelSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - modelSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - modelSettings.move(event.getNewIndex(), (EStructuralFeature) event.getNewValue()); - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - EMFMultiPropertiesBindingPropertiesEditionPart basePart = (EMFMultiPropertiesBindingPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views().equals(msg.getFeature()) && isAccessible(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views)) - basePart.updateViews(); - if (MappingPackage.eINSTANCE.getEMFMultiPropertiesBinding_Model().equals(msg.getFeature()) && isAccessible(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model)) - basePart.updateModel(); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name(), - MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views(), - MappingPackage.eINSTANCE.getEMFMultiPropertiesBinding_Model() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name || key == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views || key == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name) - return "The name of this property binding"; //$NON-NLS-1$ - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views) - return "The mapped views"; //$NON-NLS-1$ - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model) - return "The mapped properties"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFMultiPropertiesBindingPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFMultiPropertiesBindingPropertiesEditionComponent.java deleted file mode 100644 index bf63a1f6f..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFMultiPropertiesBindingPropertiesEditionComponent.java +++ /dev/null @@ -1,116 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFMultiPropertiesBindingPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private EMFMultiPropertiesBindingPropertiesEditionPart basePart; - - /** - * The EMFMultiPropertiesBindingBasePropertiesEditionComponent sub component - * - */ - protected EMFMultiPropertiesBindingBasePropertiesEditionComponent eMFMultiPropertiesBindingBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param eMFMultiPropertiesBinding the EObject to edit - * - */ - public EMFMultiPropertiesBindingPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eMFMultiPropertiesBinding, String editing_mode) { - super(editingContext, editing_mode); - if (eMFMultiPropertiesBinding instanceof EMFMultiPropertiesBinding) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eMFMultiPropertiesBinding, PropertiesEditingProvider.class); - eMFMultiPropertiesBindingBasePropertiesEditionComponent = (EMFMultiPropertiesBindingBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, EMFMultiPropertiesBindingBasePropertiesEditionComponent.BASE_PART, EMFMultiPropertiesBindingBasePropertiesEditionComponent.class); - addSubComponent(eMFMultiPropertiesBindingBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eMFMultiPropertiesBinding, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (EMFMultiPropertiesBindingBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (EMFMultiPropertiesBindingPropertiesEditionPart)eMFMultiPropertiesBindingBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (MappingViewsRepository.EMFMultiPropertiesBinding.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (EMFMultiPropertiesBindingPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFPropertyBindingBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFPropertyBindingBasePropertiesEditionComponent.java deleted file mode 100644 index 156804055..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFPropertyBindingBasePropertiesEditionComponent.java +++ /dev/null @@ -1,300 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFPropertyBindingBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for views ReferencesTable - */ - private ReferencesTableSettings viewsSettings; - - /** - * Settings for model EObjectFlatComboViewer - */ - private EObjectFlatComboSettings modelSettings; - - - /** - * Default constructor - * - */ - public EMFPropertyBindingBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eMFPropertyBinding, String editing_mode) { - super(editingContext, eMFPropertyBinding, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = MappingViewsRepository.class; - partKey = MappingViewsRepository.EMFPropertyBinding.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final EMFPropertyBinding eMFPropertyBinding = (EMFPropertyBinding)elt; - final EMFPropertyBindingPropertiesEditionPart basePart = (EMFPropertyBindingPropertiesEditionPart)editingPart; - // init values - if (isAccessible(MappingViewsRepository.EMFPropertyBinding.Properties.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, eMFPropertyBinding.getName())); - - if (isAccessible(MappingViewsRepository.EMFPropertyBinding.Binding.views)) { - viewsSettings = new ReferencesTableSettings(eMFPropertyBinding, MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views()); - basePart.initViews(viewsSettings); - } - if (isAccessible(MappingViewsRepository.EMFPropertyBinding.Binding.model)) { - // init part - modelSettings = new EObjectFlatComboSettings(eMFPropertyBinding, MappingPackage.eINSTANCE.getEMFPropertyBinding_Model()); - basePart.initModel(modelSettings); - // set the button mode - basePart.setModelButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - - if (isAccessible(MappingViewsRepository.EMFPropertyBinding.Binding.views)) { - basePart.addFilterToViews(new EObjectFilter(ViewsPackage.Literals.ELEMENT_EDITOR)); - // Start of user code for additional businessfilters for views - - // End of user code - } - if (isAccessible(MappingViewsRepository.EMFPropertyBinding.Binding.model)) { - basePart.addFilterToModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EStructuralFeature); - } - - }); - // Start of user code for additional businessfilters for model - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == MappingViewsRepository.EMFPropertyBinding.Properties.name) { - return MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name(); - } - if (editorKey == MappingViewsRepository.EMFPropertyBinding.Binding.views) { - return MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views(); - } - if (editorKey == MappingViewsRepository.EMFPropertyBinding.Binding.model) { - return MappingPackage.eINSTANCE.getEMFPropertyBinding_Model(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - EMFPropertyBinding eMFPropertyBinding = (EMFPropertyBinding)semanticObject; - if (MappingViewsRepository.EMFPropertyBinding.Properties.name == event.getAffectedEditor()) { - eMFPropertyBinding.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (MappingViewsRepository.EMFPropertyBinding.Binding.views == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof ElementEditor) { - viewsSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - viewsSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - viewsSettings.move(event.getNewIndex(), (ElementEditor) event.getNewValue()); - } - } - if (MappingViewsRepository.EMFPropertyBinding.Binding.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - modelSettings.setToReference((EStructuralFeature)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, modelSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - EMFPropertyBindingPropertiesEditionPart basePart = (EMFPropertyBindingPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(MappingViewsRepository.EMFPropertyBinding.Properties.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views().equals(msg.getFeature()) && isAccessible(MappingViewsRepository.EMFPropertyBinding.Binding.views)) - basePart.updateViews(); - if (MappingPackage.eINSTANCE.getEMFPropertyBinding_Model().equals(msg.getFeature()) && basePart != null && isAccessible(MappingViewsRepository.EMFPropertyBinding.Binding.model)) - basePart.setModel((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name(), - MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views(), - MappingPackage.eINSTANCE.getEMFPropertyBinding_Model() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == MappingViewsRepository.EMFPropertyBinding.Properties.name || key == MappingViewsRepository.EMFPropertyBinding.Binding.views || key == MappingViewsRepository.EMFPropertyBinding.Binding.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == MappingViewsRepository.EMFPropertyBinding.Properties.name) - return "The name of this property binding"; //$NON-NLS-1$ - if (key == MappingViewsRepository.EMFPropertyBinding.Binding.views) - return "The mapped views"; //$NON-NLS-1$ - if (key == MappingViewsRepository.EMFPropertyBinding.Binding.model) - return "The mapped structural feature"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (MappingViewsRepository.EMFPropertyBinding.Properties.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFPropertyBindingPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFPropertyBindingPropertiesEditionComponent.java deleted file mode 100644 index a27922959..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/EMFPropertyBindingPropertiesEditionComponent.java +++ /dev/null @@ -1,116 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFPropertyBindingPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private EMFPropertyBindingPropertiesEditionPart basePart; - - /** - * The EMFPropertyBindingBasePropertiesEditionComponent sub component - * - */ - protected EMFPropertyBindingBasePropertiesEditionComponent eMFPropertyBindingBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param eMFPropertyBinding the EObject to edit - * - */ - public EMFPropertyBindingPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eMFPropertyBinding, String editing_mode) { - super(editingContext, editing_mode); - if (eMFPropertyBinding instanceof EMFPropertyBinding) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eMFPropertyBinding, PropertiesEditingProvider.class); - eMFPropertyBindingBasePropertiesEditionComponent = (EMFPropertyBindingBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, EMFPropertyBindingBasePropertiesEditionComponent.BASE_PART, EMFPropertyBindingBasePropertiesEditionComponent.class); - addSubComponent(eMFPropertyBindingBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eMFPropertyBinding, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (EMFPropertyBindingBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (EMFPropertyBindingPropertiesEditionPart)eMFPropertyBindingBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (MappingViewsRepository.EMFPropertyBinding.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (EMFPropertyBindingPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == MappingViewsRepository.EMFPropertyBinding.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/ElementBindingReferenceBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/ElementBindingReferenceBasePropertiesEditionComponent.java deleted file mode 100644 index 6dcb261bb..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/ElementBindingReferenceBasePropertiesEditionComponent.java +++ /dev/null @@ -1,229 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class ElementBindingReferenceBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for binding EObjectFlatComboViewer - */ - private EObjectFlatComboSettings bindingSettings; - - - /** - * Default constructor - * - */ - public ElementBindingReferenceBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject elementBindingReference, String editing_mode) { - super(editingContext, elementBindingReference, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = MappingViewsRepository.class; - partKey = MappingViewsRepository.ElementBindingReference.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final ElementBindingReference elementBindingReference = (ElementBindingReference)elt; - final ElementBindingReferencePropertiesEditionPart basePart = (ElementBindingReferencePropertiesEditionPart)editingPart; - // init values - if (isAccessible(MappingViewsRepository.ElementBindingReference.Reference.binding)) { - // init part - bindingSettings = new EObjectFlatComboSettings(elementBindingReference, MappingPackage.eINSTANCE.getElementBindingReference_Binding()); - basePart.initBinding(bindingSettings); - // set the button mode - basePart.setBindingButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - if (isAccessible(MappingViewsRepository.ElementBindingReference.Reference.binding)) { - basePart.addFilterToBinding(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof AbstractElementBinding); - } - - }); - // Start of user code for additional businessfilters for binding - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == MappingViewsRepository.ElementBindingReference.Reference.binding) { - return MappingPackage.eINSTANCE.getElementBindingReference_Binding(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - ElementBindingReference elementBindingReference = (ElementBindingReference)semanticObject; - if (MappingViewsRepository.ElementBindingReference.Reference.binding == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - bindingSettings.setToReference((AbstractElementBinding)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, bindingSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - ElementBindingReferencePropertiesEditionPart basePart = (ElementBindingReferencePropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getElementBindingReference_Binding().equals(msg.getFeature()) && basePart != null && isAccessible(MappingViewsRepository.ElementBindingReference.Reference.binding)) - basePart.setBinding((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getElementBindingReference_Binding() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == MappingViewsRepository.ElementBindingReference.Reference.binding; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == MappingViewsRepository.ElementBindingReference.Reference.binding) - return "The referenced element binding"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/ElementBindingReferencePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/ElementBindingReferencePropertiesEditionComponent.java deleted file mode 100644 index 9da474381..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/ElementBindingReferencePropertiesEditionComponent.java +++ /dev/null @@ -1,116 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class ElementBindingReferencePropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private ElementBindingReferencePropertiesEditionPart basePart; - - /** - * The ElementBindingReferenceBasePropertiesEditionComponent sub component - * - */ - protected ElementBindingReferenceBasePropertiesEditionComponent elementBindingReferenceBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param elementBindingReference the EObject to edit - * - */ - public ElementBindingReferencePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject elementBindingReference, String editing_mode) { - super(editingContext, editing_mode); - if (elementBindingReference instanceof ElementBindingReference) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(elementBindingReference, PropertiesEditingProvider.class); - elementBindingReferenceBasePropertiesEditionComponent = (ElementBindingReferenceBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, ElementBindingReferenceBasePropertiesEditionComponent.BASE_PART, ElementBindingReferenceBasePropertiesEditionComponent.class); - addSubComponent(elementBindingReferenceBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(elementBindingReference, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (ElementBindingReferenceBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (ElementBindingReferencePropertiesEditionPart)elementBindingReferenceBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (MappingViewsRepository.ElementBindingReference.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (ElementBindingReferencePropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == MappingViewsRepository.ElementBindingReference.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/FilterPropertiesPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/FilterPropertiesPropertiesEditionComponent.java deleted file mode 100644 index b571e8d87..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/FilterPropertiesPropertiesEditionComponent.java +++ /dev/null @@ -1,199 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class FilterPropertiesPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String FILTERPROPERTIES_PART = "Filter properties"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public FilterPropertiesPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject bindingFilter, String editing_mode) { - super(editingContext, bindingFilter, editing_mode); - parts = new String[] { FILTERPROPERTIES_PART }; - repositoryKey = MappingViewsRepository.class; - partKey = MappingViewsRepository.FilterProperties.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final BindingFilter bindingFilter = (BindingFilter)elt; - final FilterPropertiesPropertiesEditionPart filterPropertiesPart = (FilterPropertiesPropertiesEditionPart)editingPart; - // init values - if (isAccessible(MappingViewsRepository.FilterProperties.FilterProperties_.name)) - filterPropertiesPart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, bindingFilter.getName())); - - if (isAccessible(MappingViewsRepository.FilterProperties.FilterProperties_.mandatory)) { - filterPropertiesPart.setMandatory(bindingFilter.isMandatory()); - } - // init filters - - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == MappingViewsRepository.FilterProperties.FilterProperties_.name) { - return FiltersPackage.eINSTANCE.getBindingFilter_Name(); - } - if (editorKey == MappingViewsRepository.FilterProperties.FilterProperties_.mandatory) { - return FiltersPackage.eINSTANCE.getBindingFilter_Mandatory(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - BindingFilter bindingFilter = (BindingFilter)semanticObject; - if (MappingViewsRepository.FilterProperties.FilterProperties_.name == event.getAffectedEditor()) { - bindingFilter.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (MappingViewsRepository.FilterProperties.FilterProperties_.mandatory == event.getAffectedEditor()) { - bindingFilter.setMandatory((Boolean)event.getNewValue()); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - FilterPropertiesPropertiesEditionPart filterPropertiesPart = (FilterPropertiesPropertiesEditionPart)editingPart; - if (FiltersPackage.eINSTANCE.getBindingFilter_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && filterPropertiesPart != null && isAccessible(MappingViewsRepository.FilterProperties.FilterProperties_.name)) { - if (msg.getNewValue() != null) { - filterPropertiesPart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - filterPropertiesPart.setName(""); - } - } - if (FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && filterPropertiesPart != null && isAccessible(MappingViewsRepository.FilterProperties.FilterProperties_.mandatory)) - filterPropertiesPart.setMandatory((Boolean)msg.getNewValue()); - - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - FiltersPackage.eINSTANCE.getBindingFilter_Name(), - FiltersPackage.eINSTANCE.getBindingFilter_Mandatory() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (MappingViewsRepository.FilterProperties.FilterProperties_.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Name().getEAttributeType(), newValue); - } - if (MappingViewsRepository.FilterProperties.FilterProperties_.mandatory == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(FiltersPackage.eINSTANCE.getBindingFilter_Mandatory().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardElementBindingBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardElementBindingBasePropertiesEditionComponent.java deleted file mode 100644 index c384d3115..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardElementBindingBasePropertiesEditionComponent.java +++ /dev/null @@ -1,301 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelElement; -import org.eclipse.emf.eef.mapping.StandardElementBinding; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StandardElementBindingBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for views ReferencesTable - */ - private ReferencesTableSettings viewsSettings; - - /** - * Settings for model EObjectFlatComboViewer - */ - private EObjectFlatComboSettings modelSettings; - - - /** - * Default constructor - * - */ - public StandardElementBindingBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject standardElementBinding, String editing_mode) { - super(editingContext, standardElementBinding, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = MappingViewsRepository.class; - partKey = MappingViewsRepository.StandardElementBinding.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final StandardElementBinding standardElementBinding = (StandardElementBinding)elt; - final StandardElementBindingPropertiesEditionPart basePart = (StandardElementBindingPropertiesEditionPart)editingPart; - // init values - if (isAccessible(MappingViewsRepository.StandardElementBinding.Properties.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, standardElementBinding.getName())); - - if (isAccessible(MappingViewsRepository.StandardElementBinding.Binding.views)) { - viewsSettings = new ReferencesTableSettings(standardElementBinding, MappingPackage.eINSTANCE.getAbstractElementBinding_Views()); - basePart.initViews(viewsSettings); - } - if (isAccessible(MappingViewsRepository.StandardElementBinding.Binding.model)) { - // init part - modelSettings = new EObjectFlatComboSettings(standardElementBinding, MappingPackage.eINSTANCE.getStandardElementBinding_Model()); - basePart.initModel(modelSettings); - // set the button mode - basePart.setModelButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - - if (isAccessible(MappingViewsRepository.StandardElementBinding.Binding.views)) { - basePart.addFilterToViews(new EObjectFilter(ViewsPackage.Literals.VIEW)); - // Start of user code for additional businessfilters for views - - // End of user code - } - if (isAccessible(MappingViewsRepository.StandardElementBinding.Binding.model)) { - basePart.addFilterToModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof ModelElement); - } - - }); - // Start of user code for additional businessfilters for model - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == MappingViewsRepository.StandardElementBinding.Properties.name) { - return MappingPackage.eINSTANCE.getAbstractElementBinding_Name(); - } - if (editorKey == MappingViewsRepository.StandardElementBinding.Binding.views) { - return MappingPackage.eINSTANCE.getAbstractElementBinding_Views(); - } - if (editorKey == MappingViewsRepository.StandardElementBinding.Binding.model) { - return MappingPackage.eINSTANCE.getStandardElementBinding_Model(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - StandardElementBinding standardElementBinding = (StandardElementBinding)semanticObject; - if (MappingViewsRepository.StandardElementBinding.Properties.name == event.getAffectedEditor()) { - standardElementBinding.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (MappingViewsRepository.StandardElementBinding.Binding.views == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof View) { - viewsSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - viewsSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - viewsSettings.move(event.getNewIndex(), (View) event.getNewValue()); - } - } - if (MappingViewsRepository.StandardElementBinding.Binding.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - modelSettings.setToReference((ModelElement)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, modelSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - StandardElementBindingPropertiesEditionPart basePart = (StandardElementBindingPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getAbstractElementBinding_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(MappingViewsRepository.StandardElementBinding.Properties.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (MappingPackage.eINSTANCE.getAbstractElementBinding_Views().equals(msg.getFeature()) && isAccessible(MappingViewsRepository.StandardElementBinding.Binding.views)) - basePart.updateViews(); - if (MappingPackage.eINSTANCE.getStandardElementBinding_Model().equals(msg.getFeature()) && basePart != null && isAccessible(MappingViewsRepository.StandardElementBinding.Binding.model)) - basePart.setModel((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getAbstractElementBinding_Name(), - MappingPackage.eINSTANCE.getAbstractElementBinding_Views(), - MappingPackage.eINSTANCE.getStandardElementBinding_Model() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == MappingViewsRepository.StandardElementBinding.Properties.name || key == MappingViewsRepository.StandardElementBinding.Binding.views || key == MappingViewsRepository.StandardElementBinding.Binding.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == MappingViewsRepository.StandardElementBinding.Properties.name) - return "The name of this element binding"; //$NON-NLS-1$ - if (key == MappingViewsRepository.StandardElementBinding.Binding.views) - return "The mapped views"; //$NON-NLS-1$ - if (key == MappingViewsRepository.StandardElementBinding.Binding.model) - return "The mapped model element"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (MappingViewsRepository.StandardElementBinding.Properties.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getAbstractElementBinding_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getAbstractElementBinding_Name().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardElementBindingPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardElementBindingPropertiesEditionComponent.java deleted file mode 100644 index cce209f6c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardElementBindingPropertiesEditionComponent.java +++ /dev/null @@ -1,116 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.StandardElementBinding; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StandardElementBindingPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private StandardElementBindingPropertiesEditionPart basePart; - - /** - * The StandardElementBindingBasePropertiesEditionComponent sub component - * - */ - protected StandardElementBindingBasePropertiesEditionComponent standardElementBindingBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param standardElementBinding the EObject to edit - * - */ - public StandardElementBindingPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject standardElementBinding, String editing_mode) { - super(editingContext, editing_mode); - if (standardElementBinding instanceof StandardElementBinding) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(standardElementBinding, PropertiesEditingProvider.class); - standardElementBindingBasePropertiesEditionComponent = (StandardElementBindingBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, StandardElementBindingBasePropertiesEditionComponent.BASE_PART, StandardElementBindingBasePropertiesEditionComponent.class); - addSubComponent(standardElementBindingBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(standardElementBinding, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (StandardElementBindingBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (StandardElementBindingPropertiesEditionPart)standardElementBindingBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (MappingViewsRepository.StandardElementBinding.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (StandardElementBindingPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == MappingViewsRepository.StandardElementBinding.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardPropertyBindingBasePropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardPropertyBindingBasePropertiesEditionComponent.java deleted file mode 100644 index e842c3bf5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardPropertyBindingBasePropertiesEditionComponent.java +++ /dev/null @@ -1,301 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelProperty; -import org.eclipse.emf.eef.mapping.StandardPropertyBinding; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.ViewsPackage; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StandardPropertyBindingBasePropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for views ReferencesTable - */ - private ReferencesTableSettings viewsSettings; - - /** - * Settings for model EObjectFlatComboViewer - */ - private EObjectFlatComboSettings modelSettings; - - - /** - * Default constructor - * - */ - public StandardPropertyBindingBasePropertiesEditionComponent(PropertiesEditingContext editingContext, EObject standardPropertyBinding, String editing_mode) { - super(editingContext, standardPropertyBinding, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = MappingViewsRepository.class; - partKey = MappingViewsRepository.StandardPropertyBinding.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final StandardPropertyBinding standardPropertyBinding = (StandardPropertyBinding)elt; - final StandardPropertyBindingPropertiesEditionPart basePart = (StandardPropertyBindingPropertiesEditionPart)editingPart; - // init values - if (isAccessible(MappingViewsRepository.StandardPropertyBinding.Properties.name)) - basePart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, standardPropertyBinding.getName())); - - if (isAccessible(MappingViewsRepository.StandardPropertyBinding.Binding.views)) { - viewsSettings = new ReferencesTableSettings(standardPropertyBinding, MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views()); - basePart.initViews(viewsSettings); - } - if (isAccessible(MappingViewsRepository.StandardPropertyBinding.Binding.model)) { - // init part - modelSettings = new EObjectFlatComboSettings(standardPropertyBinding, MappingPackage.eINSTANCE.getStandardPropertyBinding_Model()); - basePart.initModel(modelSettings); - // set the button mode - basePart.setModelButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - - if (isAccessible(MappingViewsRepository.StandardPropertyBinding.Binding.views)) { - basePart.addFilterToViews(new EObjectFilter(ViewsPackage.Literals.ELEMENT_EDITOR)); - // Start of user code for additional businessfilters for views - - // End of user code - } - if (isAccessible(MappingViewsRepository.StandardPropertyBinding.Binding.model)) { - basePart.addFilterToModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof ModelProperty); - } - - }); - // Start of user code for additional businessfilters for model - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == MappingViewsRepository.StandardPropertyBinding.Properties.name) { - return MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name(); - } - if (editorKey == MappingViewsRepository.StandardPropertyBinding.Binding.views) { - return MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views(); - } - if (editorKey == MappingViewsRepository.StandardPropertyBinding.Binding.model) { - return MappingPackage.eINSTANCE.getStandardPropertyBinding_Model(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - StandardPropertyBinding standardPropertyBinding = (StandardPropertyBinding)semanticObject; - if (MappingViewsRepository.StandardPropertyBinding.Properties.name == event.getAffectedEditor()) { - standardPropertyBinding.setName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (MappingViewsRepository.StandardPropertyBinding.Binding.views == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.ADD) { - if (event.getNewValue() instanceof ElementEditor) { - viewsSettings.addToReference((EObject) event.getNewValue()); - } - } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { - viewsSettings.removeFromReference((EObject) event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.MOVE) { - viewsSettings.move(event.getNewIndex(), (ElementEditor) event.getNewValue()); - } - } - if (MappingViewsRepository.StandardPropertyBinding.Binding.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - modelSettings.setToReference((ModelProperty)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, modelSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - StandardPropertyBindingPropertiesEditionPart basePart = (StandardPropertyBindingPropertiesEditionPart)editingPart; - if (MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(MappingViewsRepository.StandardPropertyBinding.Properties.name)) { - if (msg.getNewValue() != null) { - basePart.setName(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setName(""); - } - } - if (MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views().equals(msg.getFeature()) && isAccessible(MappingViewsRepository.StandardPropertyBinding.Binding.views)) - basePart.updateViews(); - if (MappingPackage.eINSTANCE.getStandardPropertyBinding_Model().equals(msg.getFeature()) && basePart != null && isAccessible(MappingViewsRepository.StandardPropertyBinding.Binding.model)) - basePart.setModel((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name(), - MappingPackage.eINSTANCE.getAbstractPropertyBinding_Views(), - MappingPackage.eINSTANCE.getStandardPropertyBinding_Model() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == MappingViewsRepository.StandardPropertyBinding.Properties.name || key == MappingViewsRepository.StandardPropertyBinding.Binding.views || key == MappingViewsRepository.StandardPropertyBinding.Binding.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getHelpContent(java.lang.Object, int) - * - */ - public String getHelpContent(Object key, int kind) { - if (key == MappingViewsRepository.StandardPropertyBinding.Properties.name) - return "The name of this property binding"; //$NON-NLS-1$ - if (key == MappingViewsRepository.StandardPropertyBinding.Binding.views) - return "The mapped views"; //$NON-NLS-1$ - if (key == MappingViewsRepository.StandardPropertyBinding.Binding.model) - return "The mapped model property"; //$NON-NLS-1$ - return super.getHelpContent(key, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (MappingViewsRepository.StandardPropertyBinding.Properties.name == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(MappingPackage.eINSTANCE.getAbstractPropertyBinding_Name().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardPropertyBindingPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardPropertyBindingPropertiesEditionComponent.java deleted file mode 100644 index 8e4eefa13..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/components/StandardPropertyBindingPropertiesEditionComponent.java +++ /dev/null @@ -1,116 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.components; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.mapping.StandardPropertyBinding; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StandardPropertyBindingPropertiesEditionComponent extends ComposedPropertiesEditionComponent { - - /** - * The Base part - * - */ - private StandardPropertyBindingPropertiesEditionPart basePart; - - /** - * The StandardPropertyBindingBasePropertiesEditionComponent sub component - * - */ - protected StandardPropertyBindingBasePropertiesEditionComponent standardPropertyBindingBasePropertiesEditionComponent; - - /** - * The DocumentedElementPropertiesEditionComponent sub component - * - */ - protected DocumentedElementPropertiesEditionComponent documentedElementPropertiesEditionComponent; - - /** - * Parameterized constructor - * - * @param standardPropertyBinding the EObject to edit - * - */ - public StandardPropertyBindingPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject standardPropertyBinding, String editing_mode) { - super(editingContext, editing_mode); - if (standardPropertyBinding instanceof StandardPropertyBinding) { - PropertiesEditingProvider provider = null; - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(standardPropertyBinding, PropertiesEditingProvider.class); - standardPropertyBindingBasePropertiesEditionComponent = (StandardPropertyBindingBasePropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, StandardPropertyBindingBasePropertiesEditionComponent.BASE_PART, StandardPropertyBindingBasePropertiesEditionComponent.class); - addSubComponent(standardPropertyBindingBasePropertiesEditionComponent); - provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(standardPropertyBinding, PropertiesEditingProvider.class); - documentedElementPropertiesEditionComponent = (DocumentedElementPropertiesEditionComponent)provider.getPropertiesEditingComponent(editingContext, editing_mode, DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART, DocumentedElementPropertiesEditionComponent.class); - addSubComponent(documentedElementPropertiesEditionComponent); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * getPropertiesEditionPart(int, java.lang.String) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (StandardPropertyBindingBasePropertiesEditionComponent.BASE_PART.equals(key)) { - basePart = (StandardPropertyBindingPropertiesEditionPart)standardPropertyBindingBasePropertiesEditionComponent.getPropertiesEditionPart(kind, key); - return (IPropertiesEditionPart)basePart; - } - return super.getPropertiesEditionPart(kind, key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - * - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - if (MappingViewsRepository.StandardPropertyBinding.class == key) { - super.setPropertiesEditionPart(key, kind, propertiesEditionPart); - basePart = (StandardPropertyBindingPropertiesEditionPart)propertiesEditionPart; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.ComposedPropertiesEditionComponent# - * initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(java.lang.Object key, int kind, EObject element, ResourceSet allResource) { - if (key == MappingViewsRepository.StandardPropertyBinding.class) { - super.initPart(key, kind, element, allResource); - } - if (key == MappingViewsRepository.Documentation.class) { - super.initPart(key, kind, element, allResource); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/FiltersViewsRepository.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/FiltersViewsRepository.java deleted file mode 100644 index bc6272a88..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/FiltersViewsRepository.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts; - -/** - * @author Nathalie Lepine - * - */ -public class FiltersViewsRepository { - - public static final int SWT_KIND = 0; - - public static final int FORM_KIND = 1; - - - /** - * OnlyReferenceTypeFilter view descriptor - * - */ - public static class OnlyReferenceTypeFilter { - public static class ReferencedFeature { - - - public static String referencedFeature_ = "filters::OnlyReferenceTypeFilter::Referenced feature::referencedFeature_"; - - - } - - - public static String filterProperties = "filters::OnlyReferenceTypeFilter::filter properties"; - - } - - /** - * OCLFilter view descriptor - * - */ - public static class OCLFilter { - public static class FilterExpression { - - - public static String oCLExpressionBody = "filters::OCLFilter::Filter expression::OCLExpressionBody"; - - - } - - - public static String filterProperties = "filters::OCLFilter::filter properties"; - - } - - /** - * JavaExpressionFilter view descriptor - * - */ - public static class JavaExpressionFilter { - public static class FilterExpression { - - - public static String javaExpressionBody = "filters::JavaExpressionFilter::Filter expression::javaExpressionBody"; - - - } - - - public static String filterProperties = "filters::JavaExpressionFilter::filter properties"; - - } - - /** - * JavaDeclarationFilter view descriptor - * - */ - public static class JavaDeclarationFilter { - public static class FilterExpression { - - - public static String methodName = "filters::JavaDeclarationFilter::Filter expression::methodName"; - - - } - - - public static String filterProperties = "filters::JavaDeclarationFilter::filter properties"; - - } - - /** - * StrictTypingFilter view descriptor - * - */ - public static class StrictTypingFilter { - public static class Type { - - - public static String restriction = "filters::StrictTypingFilter::Type::Restriction"; - - - } - - - public static String filterProperties = "filters::StrictTypingFilter::filter properties"; - - } - - /** - * JavaDeclarationStepFilter view descriptor - * - */ - public static class JavaDeclarationStepFilter { - public static class Properties { - - - public static String qualifiedClass = "filters::JavaDeclarationStepFilter::Properties::qualifiedClass"; - - - public static String methodFilter = "filters::JavaDeclarationStepFilter::Properties::methodFilter"; - - - public static String staticMethod = "filters::JavaDeclarationStepFilter::Properties::staticMethod"; - - - } - - } - - /** - * JavaBodyStepFilter view descriptor - * - */ - public static class JavaBodyStepFilter { - public static class Properties { - - - public static String body = "filters::JavaBodyStepFilter::Properties::body"; - - - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaBodyStepFilterPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaBodyStepFilterPropertiesEditionPart.java deleted file mode 100644 index 9c6ef96f9..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaBodyStepFilterPropertiesEditionPart.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts; - -// Start of user code for imports - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface JavaBodyStepFilterPropertiesEditionPart { - - /** - * @return the body - * - */ - public String getBody(); - - /** - * Defines a new body - * @param newValue the new body to set - * - */ - public void setBody(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaDeclarationFilterPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaDeclarationFilterPropertiesEditionPart.java deleted file mode 100644 index d16085856..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaDeclarationFilterPropertiesEditionPart.java +++ /dev/null @@ -1,88 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts; - -// Start of user code for imports -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface JavaDeclarationFilterPropertiesEditionPart { - - /** - * @return the methodName - * - */ - public String getMethodName(); - - /** - * Defines a new methodName - * @param newValue the new methodName to set - * - */ - public void setMethodName(String newValue); - - - /** - * @return the Filter properties referenced view - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView(); - /** - * @return the Name - * - */ - public String getName(); - - /** - * Defines a new Name - * @param newValue the new Name to set - * - */ - public void setName(String newValue); - - /** - * @return the Mandatory - * - */ - public Boolean getMandatory(); - - /** - * Defines a new Mandatory - * @param newValue the new Mandatory to set - * - */ - public void setMandatory(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaDeclarationStepFilterPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaDeclarationStepFilterPropertiesEditionPart.java deleted file mode 100644 index 63e74d79e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaDeclarationStepFilterPropertiesEditionPart.java +++ /dev/null @@ -1,82 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts; - -// Start of user code for imports - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface JavaDeclarationStepFilterPropertiesEditionPart { - - /** - * @return the qualifiedClass - * - */ - public String getQualifiedClass(); - - /** - * Defines a new qualifiedClass - * @param newValue the new qualifiedClass to set - * - */ - public void setQualifiedClass(String newValue); - - - /** - * @return the methodFilter - * - */ - public String getMethodFilter(); - - /** - * Defines a new methodFilter - * @param newValue the new methodFilter to set - * - */ - public void setMethodFilter(String newValue); - - - /** - * @return the staticMethod - * - */ - public Boolean getStaticMethod(); - - /** - * Defines a new staticMethod - * @param newValue the new staticMethod to set - * - */ - public void setStaticMethod(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaExpressionFilterPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaExpressionFilterPropertiesEditionPart.java deleted file mode 100644 index 5a28d52dc..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/JavaExpressionFilterPropertiesEditionPart.java +++ /dev/null @@ -1,88 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts; - -// Start of user code for imports -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface JavaExpressionFilterPropertiesEditionPart { - - /** - * @return the javaExpressionBody - * - */ - public String getJavaExpressionBody(); - - /** - * Defines a new javaExpressionBody - * @param newValue the new javaExpressionBody to set - * - */ - public void setJavaExpressionBody(String newValue); - - - /** - * @return the Filter properties referenced view - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView(); - /** - * @return the Name - * - */ - public String getName(); - - /** - * Defines a new Name - * @param newValue the new Name to set - * - */ - public void setName(String newValue); - - /** - * @return the Mandatory - * - */ - public Boolean getMandatory(); - - /** - * Defines a new Mandatory - * @param newValue the new Mandatory to set - * - */ - public void setMandatory(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/OCLFilterPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/OCLFilterPropertiesEditionPart.java deleted file mode 100644 index 6bde6cedc..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/OCLFilterPropertiesEditionPart.java +++ /dev/null @@ -1,88 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts; - -// Start of user code for imports -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface OCLFilterPropertiesEditionPart { - - /** - * @return the OCLExpressionBody - * - */ - public String getOCLExpressionBody(); - - /** - * Defines a new OCLExpressionBody - * @param newValue the new OCLExpressionBody to set - * - */ - public void setOCLExpressionBody(String newValue); - - - /** - * @return the Filter properties referenced view - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView(); - /** - * @return the Name - * - */ - public String getName(); - - /** - * Defines a new Name - * @param newValue the new Name to set - * - */ - public void setName(String newValue); - - /** - * @return the Mandatory - * - */ - public Boolean getMandatory(); - - /** - * Defines a new Mandatory - * @param newValue the new Mandatory to set - * - */ - public void setMandatory(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/OnlyReferenceTypeFilterPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/OnlyReferenceTypeFilterPropertiesEditionPart.java deleted file mode 100644 index ea50568bd..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/OnlyReferenceTypeFilterPropertiesEditionPart.java +++ /dev/null @@ -1,125 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface OnlyReferenceTypeFilterPropertiesEditionPart { - - /** - * @return the referencedFeature - * - */ - public EObject getReferencedFeature(); - - /** - * Init the referencedFeature - * @param settings the combo setting - */ - public void initReferencedFeature(EObjectFlatComboSettings settings); - - /** - * Defines a new referencedFeature - * @param newValue the new referencedFeature to set - * - */ - public void setReferencedFeature(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setReferencedFeatureButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the referencedFeature edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToReferencedFeature(ViewerFilter filter); - - /** - * Adds the given filter to the referencedFeature edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToReferencedFeature(ViewerFilter filter); - - - /** - * @return the Filter properties referenced view - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView(); - /** - * @return the Name - * - */ - public String getName(); - - /** - * Defines a new Name - * @param newValue the new Name to set - * - */ - public void setName(String newValue); - - /** - * @return the Mandatory - * - */ - public Boolean getMandatory(); - - /** - * Defines a new Mandatory - * @param newValue the new Mandatory to set - * - */ - public void setMandatory(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/StrictTypingFilterPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/StrictTypingFilterPropertiesEditionPart.java deleted file mode 100644 index 9fcd1ebe0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/StrictTypingFilterPropertiesEditionPart.java +++ /dev/null @@ -1,125 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface StrictTypingFilterPropertiesEditionPart { - - /** - * @return the Restriction - * - */ - public EObject getRestriction(); - - /** - * Init the Restriction - * @param settings the combo setting - */ - public void initRestriction(EObjectFlatComboSettings settings); - - /** - * Defines a new Restriction - * @param newValue the new Restriction to set - * - */ - public void setRestriction(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setRestrictionButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the Restriction edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToRestriction(ViewerFilter filter); - - /** - * Adds the given filter to the Restriction edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToRestriction(ViewerFilter filter); - - - /** - * @return the Filter properties referenced view - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView(); - /** - * @return the Name - * - */ - public String getName(); - - /** - * Defines a new Name - * @param newValue the new Name to set - * - */ - public void setName(String newValue); - - /** - * @return the Mandatory - * - */ - public Boolean getMandatory(); - - /** - * Defines a new Mandatory - * @param newValue the new Mandatory to set - * - */ - public void setMandatory(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaBodyStepFilterPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaBodyStepFilterPropertiesEditionPartForm.java deleted file mode 100644 index 431dc8e34..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaBodyStepFilterPropertiesEditionPartForm.java +++ /dev/null @@ -1,270 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaBodyStepFilterPropertiesEditionPart; - -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; - -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaBodyStepFilterPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, JavaBodyStepFilterPropertiesEditionPart { - - protected Text body; - - - - /** - * For {@link ISection} use only. - */ - public JavaBodyStepFilterPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaBodyStepFilterPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence javaBodyStepFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - javaBodyStepFilterStep - .addStep(FiltersViewsRepository.JavaBodyStepFilter.Properties.class) - .addStep(FiltersViewsRepository.JavaBodyStepFilter.Properties.body); - - - composer = new PartComposer(javaBodyStepFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.JavaBodyStepFilter.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == FiltersViewsRepository.JavaBodyStepFilter.Properties.body) { - return createBodyTextarea(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(FiltersMessages.JavaBodyStepFilterPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createBodyTextarea(FormToolkit widgetFactory, Composite parent) { - Label bodyLabel = createDescription(parent, FiltersViewsRepository.JavaBodyStepFilter.Properties.body, FiltersMessages.JavaBodyStepFilterPropertiesEditionPart_BodyLabel); - GridData bodyLabelData = new GridData(GridData.FILL_HORIZONTAL); - bodyLabelData.horizontalSpan = 3; - bodyLabel.setLayoutData(bodyLabelData); - body = widgetFactory.createText(parent, "", SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); //$NON-NLS-1$ - GridData bodyData = new GridData(GridData.FILL_HORIZONTAL); - bodyData.horizontalSpan = 2; - bodyData.heightHint = 80; - bodyData.widthHint = 200; - body.setLayoutData(bodyData); - body.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - JavaBodyStepFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.JavaBodyStepFilter.Properties.body, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, body.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaBodyStepFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.JavaBodyStepFilter.Properties.body, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, body.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaBodyStepFilterPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - EditingUtils.setID(body, FiltersViewsRepository.JavaBodyStepFilter.Properties.body); - EditingUtils.setEEFtype(body, "eef::Textarea"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaBodyStepFilter.Properties.body, FiltersViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createBodyTextArea - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaBodyStepFilterPropertiesEditionPart#getBody() - * - */ - public String getBody() { - return body.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaBodyStepFilterPropertiesEditionPart#setBody(String newValue) - * - */ - public void setBody(String newValue) { - if (newValue != null) { - body.setText(newValue); - } else { - body.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaBodyStepFilter.Properties.body); - if (eefElementEditorReadOnlyState && body.isEnabled()) { - body.setEnabled(false); - body.setBackground(body.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - body.setToolTipText(FiltersMessages.JavaBodyStepFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !body.isEnabled()) { - body.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.JavaBodyStepFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaDeclarationFilterPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaDeclarationFilterPropertiesEditionPartForm.java deleted file mode 100644 index 1ac05574c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaDeclarationFilterPropertiesEditionPartForm.java +++ /dev/null @@ -1,336 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaDeclarationFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationFilterPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, JavaDeclarationFilterPropertiesEditionPart { - - protected Text methodName; - private FilterPropertiesPropertiesEditionPart filterPropertiesPropertiesEditionPart; - - - - /** - * For {@link ISection} use only. - */ - public JavaDeclarationFilterPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaDeclarationFilterPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence javaDeclarationFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - javaDeclarationFilterStep - .addStep(FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.class) - .addStep(FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName); - - javaDeclarationFilterStep.addStep(FiltersViewsRepository.JavaDeclarationFilter.filterProperties); - - composer = new PartComposer(javaDeclarationFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.class) { - return createFilterExpressionGroup(widgetFactory, parent); - } - if (key == FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName) { - return createMethodNameText(widgetFactory, parent); - } - if (key == FiltersViewsRepository.JavaDeclarationFilter.filterProperties) { - return createFilterProperties(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createFilterExpressionGroup(FormToolkit widgetFactory, final Composite parent) { - Section filterExpressionSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - filterExpressionSection.setText(FiltersMessages.JavaDeclarationFilterPropertiesEditionPart_FilterExpressionGroupLabel); - GridData filterExpressionSectionData = new GridData(GridData.FILL_HORIZONTAL); - filterExpressionSectionData.horizontalSpan = 3; - filterExpressionSection.setLayoutData(filterExpressionSectionData); - Composite filterExpressionGroup = widgetFactory.createComposite(filterExpressionSection); - GridLayout filterExpressionGroupLayout = new GridLayout(); - filterExpressionGroupLayout.numColumns = 3; - filterExpressionGroup.setLayout(filterExpressionGroupLayout); - filterExpressionSection.setClient(filterExpressionGroup); - return filterExpressionGroup; - } - - - protected Composite createMethodNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName, FiltersMessages.JavaDeclarationFilterPropertiesEditionPart_MethodNameLabel); - methodName = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - methodName.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData methodNameData = new GridData(GridData.FILL_HORIZONTAL); - methodName.setLayoutData(methodNameData); - methodName.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodName.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, methodName.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationFilterPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - methodName.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationFilterPropertiesEditionPartForm.this, FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodName.getText())); - } - } - }); - EditingUtils.setID(methodName, FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName); - EditingUtils.setEEFtype(methodName, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName, FiltersViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createMethodNameText - - // End of user code - return parent; - } - - protected Composite createFilterProperties(FormToolkit widgetFactory, Composite container) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider(MappingViewsRepository.class); - filterPropertiesPropertiesEditionPart = (FilterPropertiesPropertiesEditionPart)provider.getPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, MappingViewsRepository.FORM_KIND, propertiesEditionComponent); - ((IFormPropertiesEditionPart)filterPropertiesPropertiesEditionPart).createControls(widgetFactory, container); - return container; - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#getMethodName() - * - */ - public String getMethodName() { - return methodName.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#setMethodName(String newValue) - * - */ - public void setMethodName(String newValue) { - if (newValue != null) { - methodName.setText(newValue); - } else { - methodName.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName); - if (eefElementEditorReadOnlyState && methodName.isEnabled()) { - methodName.setEnabled(false); - methodName.setToolTipText(FiltersMessages.JavaDeclarationFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !methodName.isEnabled()) { - methodName.setEnabled(true); - } - - } - - -/** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#getFilterPropertiesReferencedView() - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView() { - return (IPropertiesEditionPart) filterPropertiesPropertiesEditionPart; - } - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return filterPropertiesPropertiesEditionPart.getName(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - filterPropertiesPropertiesEditionPart.setName(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return filterPropertiesPropertiesEditionPart.getMandatory(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - filterPropertiesPropertiesEditionPart.setMandatory(newValue); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.JavaDeclarationFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaDeclarationStepFilterPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaDeclarationStepFilterPropertiesEditionPartForm.java deleted file mode 100644 index 9ebdf5c22..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaDeclarationStepFilterPropertiesEditionPartForm.java +++ /dev/null @@ -1,453 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart; - -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; - -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationStepFilterPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, JavaDeclarationStepFilterPropertiesEditionPart { - - protected Text qualifiedClass; - protected Text methodFilter; - protected Button staticMethod; - - - - /** - * For {@link ISection} use only. - */ - public JavaDeclarationStepFilterPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaDeclarationStepFilterPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence javaDeclarationStepFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = javaDeclarationStepFilterStep.addStep(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.class); - propertiesStep.addStep(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass); - propertiesStep.addStep(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter); - propertiesStep.addStep(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod); - - - composer = new PartComposer(javaDeclarationStepFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass) { - return createQualifiedClassText(widgetFactory, parent); - } - if (key == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter) { - return createMethodFilterText(widgetFactory, parent); - } - if (key == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod) { - return createStaticMethodCheckbox(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(FiltersMessages.JavaDeclarationStepFilterPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createQualifiedClassText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass, FiltersMessages.JavaDeclarationStepFilterPropertiesEditionPart_QualifiedClassLabel); - qualifiedClass = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - qualifiedClass.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData qualifiedClassData = new GridData(GridData.FILL_HORIZONTAL); - qualifiedClass.setLayoutData(qualifiedClassData); - qualifiedClass.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, qualifiedClass.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, qualifiedClass.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepFilterPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - qualifiedClass.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepFilterPropertiesEditionPartForm.this, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, qualifiedClass.getText())); - } - } - }); - EditingUtils.setID(qualifiedClass, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass); - EditingUtils.setEEFtype(qualifiedClass, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass, FiltersViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createQualifiedClassText - - // End of user code - return parent; - } - - - protected Composite createMethodFilterText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter, FiltersMessages.JavaDeclarationStepFilterPropertiesEditionPart_MethodFilterLabel); - methodFilter = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - methodFilter.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData methodFilterData = new GridData(GridData.FILL_HORIZONTAL); - methodFilter.setLayoutData(methodFilterData); - methodFilter.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodFilter.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, methodFilter.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepFilterPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - methodFilter.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepFilterPropertiesEditionPartForm.this, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodFilter.getText())); - } - } - }); - EditingUtils.setID(methodFilter, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter); - EditingUtils.setEEFtype(methodFilter, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter, FiltersViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createMethodFilterText - - // End of user code - return parent; - } - - - protected Composite createStaticMethodCheckbox(FormToolkit widgetFactory, Composite parent) { - staticMethod = widgetFactory.createButton(parent, getDescription(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod, FiltersMessages.JavaDeclarationStepFilterPropertiesEditionPart_StaticMethodLabel), SWT.CHECK); - staticMethod.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepFilterPropertiesEditionPartForm.this, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(staticMethod.getSelection()))); - } - - }); - GridData staticMethodData = new GridData(GridData.FILL_HORIZONTAL); - staticMethodData.horizontalSpan = 2; - staticMethod.setLayoutData(staticMethodData); - EditingUtils.setID(staticMethod, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod); - EditingUtils.setEEFtype(staticMethod, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod, FiltersViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createStaticMethodCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#getQualifiedClass() - * - */ - public String getQualifiedClass() { - return qualifiedClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#setQualifiedClass(String newValue) - * - */ - public void setQualifiedClass(String newValue) { - if (newValue != null) { - qualifiedClass.setText(newValue); - } else { - qualifiedClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass); - if (eefElementEditorReadOnlyState && qualifiedClass.isEnabled()) { - qualifiedClass.setEnabled(false); - qualifiedClass.setToolTipText(FiltersMessages.JavaDeclarationStepFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !qualifiedClass.isEnabled()) { - qualifiedClass.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#getMethodFilter() - * - */ - public String getMethodFilter() { - return methodFilter.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#setMethodFilter(String newValue) - * - */ - public void setMethodFilter(String newValue) { - if (newValue != null) { - methodFilter.setText(newValue); - } else { - methodFilter.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter); - if (eefElementEditorReadOnlyState && methodFilter.isEnabled()) { - methodFilter.setEnabled(false); - methodFilter.setToolTipText(FiltersMessages.JavaDeclarationStepFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !methodFilter.isEnabled()) { - methodFilter.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#getStaticMethod() - * - */ - public Boolean getStaticMethod() { - return Boolean.valueOf(staticMethod.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#setStaticMethod(Boolean newValue) - * - */ - public void setStaticMethod(Boolean newValue) { - if (newValue != null) { - staticMethod.setSelection(newValue.booleanValue()); - } else { - staticMethod.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod); - if (eefElementEditorReadOnlyState && staticMethod.isEnabled()) { - staticMethod.setEnabled(false); - staticMethod.setToolTipText(FiltersMessages.JavaDeclarationStepFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !staticMethod.isEnabled()) { - staticMethod.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.JavaDeclarationStepFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaExpressionFilterPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaExpressionFilterPropertiesEditionPartForm.java deleted file mode 100644 index ddac49612..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/JavaExpressionFilterPropertiesEditionPartForm.java +++ /dev/null @@ -1,327 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaExpressionFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaExpressionFilterPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, JavaExpressionFilterPropertiesEditionPart { - - protected Text javaExpressionBody; - private FilterPropertiesPropertiesEditionPart filterPropertiesPropertiesEditionPart; - - - - /** - * For {@link ISection} use only. - */ - public JavaExpressionFilterPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaExpressionFilterPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence javaExpressionFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - javaExpressionFilterStep - .addStep(FiltersViewsRepository.JavaExpressionFilter.FilterExpression.class) - .addStep(FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody); - - javaExpressionFilterStep.addStep(FiltersViewsRepository.JavaExpressionFilter.filterProperties); - - composer = new PartComposer(javaExpressionFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.JavaExpressionFilter.FilterExpression.class) { - return createFilterExpressionGroup(widgetFactory, parent); - } - if (key == FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody) { - return createJavaExpressionBodyTextarea(widgetFactory, parent); - } - if (key == FiltersViewsRepository.JavaExpressionFilter.filterProperties) { - return createFilterProperties(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createFilterExpressionGroup(FormToolkit widgetFactory, final Composite parent) { - Section filterExpressionSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - filterExpressionSection.setText(FiltersMessages.JavaExpressionFilterPropertiesEditionPart_FilterExpressionGroupLabel); - GridData filterExpressionSectionData = new GridData(GridData.FILL_HORIZONTAL); - filterExpressionSectionData.horizontalSpan = 3; - filterExpressionSection.setLayoutData(filterExpressionSectionData); - Composite filterExpressionGroup = widgetFactory.createComposite(filterExpressionSection); - GridLayout filterExpressionGroupLayout = new GridLayout(); - filterExpressionGroupLayout.numColumns = 3; - filterExpressionGroup.setLayout(filterExpressionGroupLayout); - filterExpressionSection.setClient(filterExpressionGroup); - return filterExpressionGroup; - } - - - protected Composite createJavaExpressionBodyTextarea(FormToolkit widgetFactory, Composite parent) { - Label javaExpressionBodyLabel = createDescription(parent, FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody, FiltersMessages.JavaExpressionFilterPropertiesEditionPart_JavaExpressionBodyLabel); - GridData javaExpressionBodyLabelData = new GridData(GridData.FILL_HORIZONTAL); - javaExpressionBodyLabelData.horizontalSpan = 3; - javaExpressionBodyLabel.setLayoutData(javaExpressionBodyLabelData); - javaExpressionBody = widgetFactory.createText(parent, "", SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); //$NON-NLS-1$ - GridData javaExpressionBodyData = new GridData(GridData.FILL_HORIZONTAL); - javaExpressionBodyData.horizontalSpan = 2; - javaExpressionBodyData.heightHint = 80; - javaExpressionBodyData.widthHint = 200; - javaExpressionBody.setLayoutData(javaExpressionBodyData); - javaExpressionBody.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - JavaExpressionFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, javaExpressionBody.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaExpressionFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, javaExpressionBody.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaExpressionFilterPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - EditingUtils.setID(javaExpressionBody, FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody); - EditingUtils.setEEFtype(javaExpressionBody, "eef::Textarea"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody, FiltersViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createJavaExpressionBodyTextArea - - // End of user code - return parent; - } - - protected Composite createFilterProperties(FormToolkit widgetFactory, Composite container) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider(MappingViewsRepository.class); - filterPropertiesPropertiesEditionPart = (FilterPropertiesPropertiesEditionPart)provider.getPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, MappingViewsRepository.FORM_KIND, propertiesEditionComponent); - ((IFormPropertiesEditionPart)filterPropertiesPropertiesEditionPart).createControls(widgetFactory, container); - return container; - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#getJavaExpressionBody() - * - */ - public String getJavaExpressionBody() { - return javaExpressionBody.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#setJavaExpressionBody(String newValue) - * - */ - public void setJavaExpressionBody(String newValue) { - if (newValue != null) { - javaExpressionBody.setText(newValue); - } else { - javaExpressionBody.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody); - if (eefElementEditorReadOnlyState && javaExpressionBody.isEnabled()) { - javaExpressionBody.setEnabled(false); - javaExpressionBody.setBackground(javaExpressionBody.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - javaExpressionBody.setToolTipText(FiltersMessages.JavaExpressionFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !javaExpressionBody.isEnabled()) { - javaExpressionBody.setEnabled(true); - } - - } - - -/** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#getFilterPropertiesReferencedView() - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView() { - return (IPropertiesEditionPart) filterPropertiesPropertiesEditionPart; - } - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return filterPropertiesPropertiesEditionPart.getName(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - filterPropertiesPropertiesEditionPart.setName(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return filterPropertiesPropertiesEditionPart.getMandatory(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - filterPropertiesPropertiesEditionPart.setMandatory(newValue); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.JavaExpressionFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/OCLFilterPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/OCLFilterPropertiesEditionPartForm.java deleted file mode 100644 index ca0d718e4..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/OCLFilterPropertiesEditionPartForm.java +++ /dev/null @@ -1,327 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.OCLFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class OCLFilterPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, OCLFilterPropertiesEditionPart { - - protected Text oCLExpressionBody; - private FilterPropertiesPropertiesEditionPart filterPropertiesPropertiesEditionPart; - - - - /** - * For {@link ISection} use only. - */ - public OCLFilterPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public OCLFilterPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence oCLFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - oCLFilterStep - .addStep(FiltersViewsRepository.OCLFilter.FilterExpression.class) - .addStep(FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody); - - oCLFilterStep.addStep(FiltersViewsRepository.OCLFilter.filterProperties); - - composer = new PartComposer(oCLFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.OCLFilter.FilterExpression.class) { - return createFilterExpressionGroup(widgetFactory, parent); - } - if (key == FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody) { - return createOCLExpressionBodyTextarea(widgetFactory, parent); - } - if (key == FiltersViewsRepository.OCLFilter.filterProperties) { - return createFilterProperties(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createFilterExpressionGroup(FormToolkit widgetFactory, final Composite parent) { - Section filterExpressionSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - filterExpressionSection.setText(FiltersMessages.OCLFilterPropertiesEditionPart_FilterExpressionGroupLabel); - GridData filterExpressionSectionData = new GridData(GridData.FILL_HORIZONTAL); - filterExpressionSectionData.horizontalSpan = 3; - filterExpressionSection.setLayoutData(filterExpressionSectionData); - Composite filterExpressionGroup = widgetFactory.createComposite(filterExpressionSection); - GridLayout filterExpressionGroupLayout = new GridLayout(); - filterExpressionGroupLayout.numColumns = 3; - filterExpressionGroup.setLayout(filterExpressionGroupLayout); - filterExpressionSection.setClient(filterExpressionGroup); - return filterExpressionGroup; - } - - - protected Composite createOCLExpressionBodyTextarea(FormToolkit widgetFactory, Composite parent) { - Label oCLExpressionBodyLabel = createDescription(parent, FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody, FiltersMessages.OCLFilterPropertiesEditionPart_OCLExpressionBodyLabel); - GridData oCLExpressionBodyLabelData = new GridData(GridData.FILL_HORIZONTAL); - oCLExpressionBodyLabelData.horizontalSpan = 3; - oCLExpressionBodyLabel.setLayoutData(oCLExpressionBodyLabelData); - oCLExpressionBody = widgetFactory.createText(parent, "", SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); //$NON-NLS-1$ - GridData oCLExpressionBodyData = new GridData(GridData.FILL_HORIZONTAL); - oCLExpressionBodyData.horizontalSpan = 2; - oCLExpressionBodyData.heightHint = 80; - oCLExpressionBodyData.widthHint = 200; - oCLExpressionBody.setLayoutData(oCLExpressionBodyData); - oCLExpressionBody.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - OCLFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, oCLExpressionBody.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - OCLFilterPropertiesEditionPartForm.this, - FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, oCLExpressionBody.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - OCLFilterPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - EditingUtils.setID(oCLExpressionBody, FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody); - EditingUtils.setEEFtype(oCLExpressionBody, "eef::Textarea"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody, FiltersViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createOCLExpressionBodyTextArea - - // End of user code - return parent; - } - - protected Composite createFilterProperties(FormToolkit widgetFactory, Composite container) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider(MappingViewsRepository.class); - filterPropertiesPropertiesEditionPart = (FilterPropertiesPropertiesEditionPart)provider.getPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, MappingViewsRepository.FORM_KIND, propertiesEditionComponent); - ((IFormPropertiesEditionPart)filterPropertiesPropertiesEditionPart).createControls(widgetFactory, container); - return container; - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#getOCLExpressionBody() - * - */ - public String getOCLExpressionBody() { - return oCLExpressionBody.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#setOCLExpressionBody(String newValue) - * - */ - public void setOCLExpressionBody(String newValue) { - if (newValue != null) { - oCLExpressionBody.setText(newValue); - } else { - oCLExpressionBody.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody); - if (eefElementEditorReadOnlyState && oCLExpressionBody.isEnabled()) { - oCLExpressionBody.setEnabled(false); - oCLExpressionBody.setBackground(oCLExpressionBody.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - oCLExpressionBody.setToolTipText(FiltersMessages.OCLFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !oCLExpressionBody.isEnabled()) { - oCLExpressionBody.setEnabled(true); - } - - } - - -/** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#getFilterPropertiesReferencedView() - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView() { - return (IPropertiesEditionPart) filterPropertiesPropertiesEditionPart; - } - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return filterPropertiesPropertiesEditionPart.getName(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - filterPropertiesPropertiesEditionPart.setName(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return filterPropertiesPropertiesEditionPart.getMandatory(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - filterPropertiesPropertiesEditionPart.setMandatory(newValue); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.OCLFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/OnlyReferenceTypeFilterPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/OnlyReferenceTypeFilterPropertiesEditionPartForm.java deleted file mode 100644 index 7e6048198..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/OnlyReferenceTypeFilterPropertiesEditionPartForm.java +++ /dev/null @@ -1,357 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class OnlyReferenceTypeFilterPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, OnlyReferenceTypeFilterPropertiesEditionPart { - - protected EObjectFlatComboViewer referencedFeature; - private FilterPropertiesPropertiesEditionPart filterPropertiesPropertiesEditionPart; - - - - /** - * For {@link ISection} use only. - */ - public OnlyReferenceTypeFilterPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public OnlyReferenceTypeFilterPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence onlyReferenceTypeFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - onlyReferenceTypeFilterStep - .addStep(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.class) - .addStep(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_); - - onlyReferenceTypeFilterStep.addStep(FiltersViewsRepository.OnlyReferenceTypeFilter.filterProperties); - - composer = new PartComposer(onlyReferenceTypeFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.class) { - return createReferencedFeatureGroup(widgetFactory, parent); - } - if (key == FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_) { - return createReferencedFeatureFlatComboViewer(parent, widgetFactory); - } - if (key == FiltersViewsRepository.OnlyReferenceTypeFilter.filterProperties) { - return createFilterProperties(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createReferencedFeatureGroup(FormToolkit widgetFactory, final Composite parent) { - Section referencedFeatureSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - referencedFeatureSection.setText(FiltersMessages.OnlyReferenceTypeFilterPropertiesEditionPart_ReferencedFeatureGroupLabel); - GridData referencedFeatureSectionData = new GridData(GridData.FILL_HORIZONTAL); - referencedFeatureSectionData.horizontalSpan = 3; - referencedFeatureSection.setLayoutData(referencedFeatureSectionData); - Composite referencedFeatureGroup = widgetFactory.createComposite(referencedFeatureSection); - GridLayout referencedFeatureGroupLayout = new GridLayout(); - referencedFeatureGroupLayout.numColumns = 3; - referencedFeatureGroup.setLayout(referencedFeatureGroupLayout); - referencedFeatureSection.setClient(referencedFeatureGroup); - return referencedFeatureGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createReferencedFeatureFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_, FiltersMessages.OnlyReferenceTypeFilterPropertiesEditionPart_ReferencedFeatureLabel); - referencedFeature = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_, FiltersViewsRepository.FORM_KIND)); - widgetFactory.adapt(referencedFeature); - referencedFeature.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData referencedFeatureData = new GridData(GridData.FILL_HORIZONTAL); - referencedFeature.setLayoutData(referencedFeatureData); - referencedFeature.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(OnlyReferenceTypeFilterPropertiesEditionPartForm.this, FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getReferencedFeature())); - } - - }); - referencedFeature.setID(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_, FiltersViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createReferencedFeatureFlatComboViewer - - // End of user code - return parent; - } - - protected Composite createFilterProperties(FormToolkit widgetFactory, Composite container) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider(MappingViewsRepository.class); - filterPropertiesPropertiesEditionPart = (FilterPropertiesPropertiesEditionPart)provider.getPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, MappingViewsRepository.FORM_KIND, propertiesEditionComponent); - ((IFormPropertiesEditionPart)filterPropertiesPropertiesEditionPart).createControls(widgetFactory, container); - return container; - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#getReferencedFeature() - * - */ - public EObject getReferencedFeature() { - if (referencedFeature.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) referencedFeature.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#initReferencedFeature(EObjectFlatComboSettings) - */ - public void initReferencedFeature(EObjectFlatComboSettings settings) { - referencedFeature.setInput(settings); - if (current != null) { - referencedFeature.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_); - if (eefElementEditorReadOnlyState && referencedFeature.isEnabled()) { - referencedFeature.setEnabled(false); - referencedFeature.setToolTipText(FiltersMessages.OnlyReferenceTypeFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !referencedFeature.isEnabled()) { - referencedFeature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#setReferencedFeature(EObject newValue) - * - */ - public void setReferencedFeature(EObject newValue) { - if (newValue != null) { - referencedFeature.setSelection(new StructuredSelection(newValue)); - } else { - referencedFeature.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_); - if (eefElementEditorReadOnlyState && referencedFeature.isEnabled()) { - referencedFeature.setEnabled(false); - referencedFeature.setToolTipText(FiltersMessages.OnlyReferenceTypeFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !referencedFeature.isEnabled()) { - referencedFeature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#setReferencedFeatureButtonMode(ButtonsModeEnum newValue) - */ - public void setReferencedFeatureButtonMode(ButtonsModeEnum newValue) { - referencedFeature.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#addFilterReferencedFeature(ViewerFilter filter) - * - */ - public void addFilterToReferencedFeature(ViewerFilter filter) { - referencedFeature.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#addBusinessFilterReferencedFeature(ViewerFilter filter) - * - */ - public void addBusinessFilterToReferencedFeature(ViewerFilter filter) { - referencedFeature.addBusinessRuleFilter(filter); - } - - -/** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#getFilterPropertiesReferencedView() - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView() { - return (IPropertiesEditionPart) filterPropertiesPropertiesEditionPart; - } - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return filterPropertiesPropertiesEditionPart.getName(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - filterPropertiesPropertiesEditionPart.setName(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return filterPropertiesPropertiesEditionPart.getMandatory(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - filterPropertiesPropertiesEditionPart.setMandatory(newValue); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.OnlyReferenceTypeFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/StrictTypingFilterPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/StrictTypingFilterPropertiesEditionPartForm.java deleted file mode 100644 index 36e3ee438..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/forms/StrictTypingFilterPropertiesEditionPartForm.java +++ /dev/null @@ -1,357 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.StrictTypingFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StrictTypingFilterPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, StrictTypingFilterPropertiesEditionPart { - - protected EObjectFlatComboViewer restriction; - private FilterPropertiesPropertiesEditionPart filterPropertiesPropertiesEditionPart; - - - - /** - * For {@link ISection} use only. - */ - public StrictTypingFilterPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public StrictTypingFilterPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence strictTypingFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - strictTypingFilterStep - .addStep(FiltersViewsRepository.StrictTypingFilter.Type.class) - .addStep(FiltersViewsRepository.StrictTypingFilter.Type.restriction); - - strictTypingFilterStep.addStep(FiltersViewsRepository.StrictTypingFilter.filterProperties); - - composer = new PartComposer(strictTypingFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.StrictTypingFilter.Type.class) { - return createTypeGroup(widgetFactory, parent); - } - if (key == FiltersViewsRepository.StrictTypingFilter.Type.restriction) { - return createRestrictionFlatComboViewer(parent, widgetFactory); - } - if (key == FiltersViewsRepository.StrictTypingFilter.filterProperties) { - return createFilterProperties(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createTypeGroup(FormToolkit widgetFactory, final Composite parent) { - Section typeSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - typeSection.setText(FiltersMessages.StrictTypingFilterPropertiesEditionPart_TypeGroupLabel); - GridData typeSectionData = new GridData(GridData.FILL_HORIZONTAL); - typeSectionData.horizontalSpan = 3; - typeSection.setLayoutData(typeSectionData); - Composite typeGroup = widgetFactory.createComposite(typeSection); - GridLayout typeGroupLayout = new GridLayout(); - typeGroupLayout.numColumns = 3; - typeGroup.setLayout(typeGroupLayout); - typeSection.setClient(typeGroup); - return typeGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createRestrictionFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, FiltersViewsRepository.StrictTypingFilter.Type.restriction, FiltersMessages.StrictTypingFilterPropertiesEditionPart_RestrictionLabel); - restriction = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(FiltersViewsRepository.StrictTypingFilter.Type.restriction, FiltersViewsRepository.FORM_KIND)); - widgetFactory.adapt(restriction); - restriction.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData restrictionData = new GridData(GridData.FILL_HORIZONTAL); - restriction.setLayoutData(restrictionData); - restriction.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StrictTypingFilterPropertiesEditionPartForm.this, FiltersViewsRepository.StrictTypingFilter.Type.restriction, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getRestriction())); - } - - }); - restriction.setID(FiltersViewsRepository.StrictTypingFilter.Type.restriction); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.StrictTypingFilter.Type.restriction, FiltersViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createRestrictionFlatComboViewer - - // End of user code - return parent; - } - - protected Composite createFilterProperties(FormToolkit widgetFactory, Composite container) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider(MappingViewsRepository.class); - filterPropertiesPropertiesEditionPart = (FilterPropertiesPropertiesEditionPart)provider.getPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, MappingViewsRepository.FORM_KIND, propertiesEditionComponent); - ((IFormPropertiesEditionPart)filterPropertiesPropertiesEditionPart).createControls(widgetFactory, container); - return container; - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#getRestriction() - * - */ - public EObject getRestriction() { - if (restriction.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) restriction.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#initRestriction(EObjectFlatComboSettings) - */ - public void initRestriction(EObjectFlatComboSettings settings) { - restriction.setInput(settings); - if (current != null) { - restriction.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.StrictTypingFilter.Type.restriction); - if (eefElementEditorReadOnlyState && restriction.isEnabled()) { - restriction.setEnabled(false); - restriction.setToolTipText(FiltersMessages.StrictTypingFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !restriction.isEnabled()) { - restriction.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#setRestriction(EObject newValue) - * - */ - public void setRestriction(EObject newValue) { - if (newValue != null) { - restriction.setSelection(new StructuredSelection(newValue)); - } else { - restriction.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.StrictTypingFilter.Type.restriction); - if (eefElementEditorReadOnlyState && restriction.isEnabled()) { - restriction.setEnabled(false); - restriction.setToolTipText(FiltersMessages.StrictTypingFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !restriction.isEnabled()) { - restriction.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#setRestrictionButtonMode(ButtonsModeEnum newValue) - */ - public void setRestrictionButtonMode(ButtonsModeEnum newValue) { - restriction.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#addFilterRestriction(ViewerFilter filter) - * - */ - public void addFilterToRestriction(ViewerFilter filter) { - restriction.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#addBusinessFilterRestriction(ViewerFilter filter) - * - */ - public void addBusinessFilterToRestriction(ViewerFilter filter) { - restriction.addBusinessRuleFilter(filter); - } - - -/** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#getFilterPropertiesReferencedView() - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView() { - return (IPropertiesEditionPart) filterPropertiesPropertiesEditionPart; - } - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return filterPropertiesPropertiesEditionPart.getName(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - filterPropertiesPropertiesEditionPart.setName(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return filterPropertiesPropertiesEditionPart.getMandatory(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - filterPropertiesPropertiesEditionPart.setMandatory(newValue); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.StrictTypingFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaBodyStepFilterPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaBodyStepFilterPropertiesEditionPartImpl.java deleted file mode 100644 index e9d33d792..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaBodyStepFilterPropertiesEditionPartImpl.java +++ /dev/null @@ -1,234 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaBodyStepFilterPropertiesEditionPart; - -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaBodyStepFilterPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, JavaBodyStepFilterPropertiesEditionPart { - - protected Text body; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaBodyStepFilterPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence javaBodyStepFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - javaBodyStepFilterStep - .addStep(FiltersViewsRepository.JavaBodyStepFilter.Properties.class) - .addStep(FiltersViewsRepository.JavaBodyStepFilter.Properties.body); - - - composer = new PartComposer(javaBodyStepFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.JavaBodyStepFilter.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == FiltersViewsRepository.JavaBodyStepFilter.Properties.body) { - return createBodyTextarea(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(FiltersMessages.JavaBodyStepFilterPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createBodyTextarea(Composite parent) { - Label bodyLabel = createDescription(parent, FiltersViewsRepository.JavaBodyStepFilter.Properties.body, FiltersMessages.JavaBodyStepFilterPropertiesEditionPart_BodyLabel); - GridData bodyLabelData = new GridData(GridData.FILL_HORIZONTAL); - bodyLabelData.horizontalSpan = 3; - bodyLabel.setLayoutData(bodyLabelData); - body = SWTUtils.createScrollableText(parent, SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); - GridData bodyData = new GridData(GridData.FILL_HORIZONTAL); - bodyData.horizontalSpan = 2; - bodyData.heightHint = 80; - bodyData.widthHint = 200; - body.setLayoutData(bodyData); - body.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaBodyStepFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.JavaBodyStepFilter.Properties.body, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, body.getText())); - } - - }); - EditingUtils.setID(body, FiltersViewsRepository.JavaBodyStepFilter.Properties.body); - EditingUtils.setEEFtype(body, "eef::Textarea"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaBodyStepFilter.Properties.body, FiltersViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createBodyTextArea - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaBodyStepFilterPropertiesEditionPart#getBody() - * - */ - public String getBody() { - return body.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaBodyStepFilterPropertiesEditionPart#setBody(String newValue) - * - */ - public void setBody(String newValue) { - if (newValue != null) { - body.setText(newValue); - } else { - body.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaBodyStepFilter.Properties.body); - if (eefElementEditorReadOnlyState && body.isEnabled()) { - body.setEnabled(false); - body.setBackground(body.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - body.setToolTipText(FiltersMessages.JavaBodyStepFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !body.isEnabled()) { - body.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.JavaBodyStepFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaDeclarationFilterPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaDeclarationFilterPropertiesEditionPartImpl.java deleted file mode 100644 index 727d034ce..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaDeclarationFilterPropertiesEditionPartImpl.java +++ /dev/null @@ -1,304 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaDeclarationFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationFilterPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, JavaDeclarationFilterPropertiesEditionPart { - - protected Text methodName; - private FilterPropertiesPropertiesEditionPart filterPropertiesPropertiesEditionPart; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaDeclarationFilterPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence javaDeclarationFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - javaDeclarationFilterStep - .addStep(FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.class) - .addStep(FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName); - - javaDeclarationFilterStep.addStep(FiltersViewsRepository.JavaDeclarationFilter.filterProperties); - - composer = new PartComposer(javaDeclarationFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.class) { - return createFilterExpressionGroup(parent); - } - if (key == FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName) { - return createMethodNameText(parent); - } - if (key == FiltersViewsRepository.JavaDeclarationFilter.filterProperties) { - return createFilterProperties(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createFilterExpressionGroup(Composite parent) { - Group filterExpressionGroup = new Group(parent, SWT.NONE); - filterExpressionGroup.setText(FiltersMessages.JavaDeclarationFilterPropertiesEditionPart_FilterExpressionGroupLabel); - GridData filterExpressionGroupData = new GridData(GridData.FILL_HORIZONTAL); - filterExpressionGroupData.horizontalSpan = 3; - filterExpressionGroup.setLayoutData(filterExpressionGroupData); - GridLayout filterExpressionGroupLayout = new GridLayout(); - filterExpressionGroupLayout.numColumns = 3; - filterExpressionGroup.setLayout(filterExpressionGroupLayout); - return filterExpressionGroup; - } - - - protected Composite createMethodNameText(Composite parent) { - createDescription(parent, FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName, FiltersMessages.JavaDeclarationFilterPropertiesEditionPart_MethodNameLabel); - methodName = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData methodNameData = new GridData(GridData.FILL_HORIZONTAL); - methodName.setLayoutData(methodNameData); - methodName.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodName.getText())); - } - - }); - methodName.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodName.getText())); - } - } - - }); - EditingUtils.setID(methodName, FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName); - EditingUtils.setEEFtype(methodName, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName, FiltersViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createMethodNameText - - // End of user code - return parent; - } - - protected Composite createFilterProperties(Composite container) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider(MappingViewsRepository.class); - filterPropertiesPropertiesEditionPart = (FilterPropertiesPropertiesEditionPart)provider.getPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, MappingViewsRepository.SWT_KIND, propertiesEditionComponent); - ((ISWTPropertiesEditionPart)filterPropertiesPropertiesEditionPart).createControls(container); - return container; - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#getMethodName() - * - */ - public String getMethodName() { - return methodName.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#setMethodName(String newValue) - * - */ - public void setMethodName(String newValue) { - if (newValue != null) { - methodName.setText(newValue); - } else { - methodName.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaDeclarationFilter.FilterExpression.methodName); - if (eefElementEditorReadOnlyState && methodName.isEnabled()) { - methodName.setEnabled(false); - methodName.setToolTipText(FiltersMessages.JavaDeclarationFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !methodName.isEnabled()) { - methodName.setEnabled(true); - } - - } - - -/** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#getFilterPropertiesReferencedView() - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView() { - return (IPropertiesEditionPart) filterPropertiesPropertiesEditionPart; - } - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return filterPropertiesPropertiesEditionPart.getName(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - filterPropertiesPropertiesEditionPart.setName(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return filterPropertiesPropertiesEditionPart.getMandatory(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - filterPropertiesPropertiesEditionPart.setMandatory(newValue); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.JavaDeclarationFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaDeclarationStepFilterPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaDeclarationStepFilterPropertiesEditionPartImpl.java deleted file mode 100644 index bd1cf30d6..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaDeclarationStepFilterPropertiesEditionPartImpl.java +++ /dev/null @@ -1,404 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart; - -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationStepFilterPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, JavaDeclarationStepFilterPropertiesEditionPart { - - protected Text qualifiedClass; - protected Text methodFilter; - protected Button staticMethod; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaDeclarationStepFilterPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence javaDeclarationStepFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = javaDeclarationStepFilterStep.addStep(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.class); - propertiesStep.addStep(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass); - propertiesStep.addStep(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter); - propertiesStep.addStep(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod); - - - composer = new PartComposer(javaDeclarationStepFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass) { - return createQualifiedClassText(parent); - } - if (key == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter) { - return createMethodFilterText(parent); - } - if (key == FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod) { - return createStaticMethodCheckbox(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(FiltersMessages.JavaDeclarationStepFilterPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createQualifiedClassText(Composite parent) { - createDescription(parent, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass, FiltersMessages.JavaDeclarationStepFilterPropertiesEditionPart_QualifiedClassLabel); - qualifiedClass = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData qualifiedClassData = new GridData(GridData.FILL_HORIZONTAL); - qualifiedClass.setLayoutData(qualifiedClassData); - qualifiedClass.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, qualifiedClass.getText())); - } - - }); - qualifiedClass.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, qualifiedClass.getText())); - } - } - - }); - EditingUtils.setID(qualifiedClass, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass); - EditingUtils.setEEFtype(qualifiedClass, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass, FiltersViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createQualifiedClassText - - // End of user code - return parent; - } - - - protected Composite createMethodFilterText(Composite parent) { - createDescription(parent, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter, FiltersMessages.JavaDeclarationStepFilterPropertiesEditionPart_MethodFilterLabel); - methodFilter = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData methodFilterData = new GridData(GridData.FILL_HORIZONTAL); - methodFilter.setLayoutData(methodFilterData); - methodFilter.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodFilter.getText())); - } - - }); - methodFilter.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodFilter.getText())); - } - } - - }); - EditingUtils.setID(methodFilter, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter); - EditingUtils.setEEFtype(methodFilter, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter, FiltersViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createMethodFilterText - - // End of user code - return parent; - } - - - protected Composite createStaticMethodCheckbox(Composite parent) { - staticMethod = new Button(parent, SWT.CHECK); - staticMethod.setText(getDescription(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod, FiltersMessages.JavaDeclarationStepFilterPropertiesEditionPart_StaticMethodLabel)); - staticMethod.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(staticMethod.getSelection()))); - } - - }); - GridData staticMethodData = new GridData(GridData.FILL_HORIZONTAL); - staticMethodData.horizontalSpan = 2; - staticMethod.setLayoutData(staticMethodData); - EditingUtils.setID(staticMethod, FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod); - EditingUtils.setEEFtype(staticMethod, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod, FiltersViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createStaticMethodCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#getQualifiedClass() - * - */ - public String getQualifiedClass() { - return qualifiedClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#setQualifiedClass(String newValue) - * - */ - public void setQualifiedClass(String newValue) { - if (newValue != null) { - qualifiedClass.setText(newValue); - } else { - qualifiedClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.qualifiedClass); - if (eefElementEditorReadOnlyState && qualifiedClass.isEnabled()) { - qualifiedClass.setEnabled(false); - qualifiedClass.setToolTipText(FiltersMessages.JavaDeclarationStepFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !qualifiedClass.isEnabled()) { - qualifiedClass.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#getMethodFilter() - * - */ - public String getMethodFilter() { - return methodFilter.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#setMethodFilter(String newValue) - * - */ - public void setMethodFilter(String newValue) { - if (newValue != null) { - methodFilter.setText(newValue); - } else { - methodFilter.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.methodFilter); - if (eefElementEditorReadOnlyState && methodFilter.isEnabled()) { - methodFilter.setEnabled(false); - methodFilter.setToolTipText(FiltersMessages.JavaDeclarationStepFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !methodFilter.isEnabled()) { - methodFilter.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#getStaticMethod() - * - */ - public Boolean getStaticMethod() { - return Boolean.valueOf(staticMethod.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaDeclarationStepFilterPropertiesEditionPart#setStaticMethod(Boolean newValue) - * - */ - public void setStaticMethod(Boolean newValue) { - if (newValue != null) { - staticMethod.setSelection(newValue.booleanValue()); - } else { - staticMethod.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaDeclarationStepFilter.Properties.staticMethod); - if (eefElementEditorReadOnlyState && staticMethod.isEnabled()) { - staticMethod.setEnabled(false); - staticMethod.setToolTipText(FiltersMessages.JavaDeclarationStepFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !staticMethod.isEnabled()) { - staticMethod.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.JavaDeclarationStepFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaExpressionFilterPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaExpressionFilterPropertiesEditionPartImpl.java deleted file mode 100644 index 6b41da2bb..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/JavaExpressionFilterPropertiesEditionPartImpl.java +++ /dev/null @@ -1,290 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.JavaExpressionFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaExpressionFilterPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, JavaExpressionFilterPropertiesEditionPart { - - protected Text javaExpressionBody; - private FilterPropertiesPropertiesEditionPart filterPropertiesPropertiesEditionPart; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaExpressionFilterPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence javaExpressionFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - javaExpressionFilterStep - .addStep(FiltersViewsRepository.JavaExpressionFilter.FilterExpression.class) - .addStep(FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody); - - javaExpressionFilterStep.addStep(FiltersViewsRepository.JavaExpressionFilter.filterProperties); - - composer = new PartComposer(javaExpressionFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.JavaExpressionFilter.FilterExpression.class) { - return createFilterExpressionGroup(parent); - } - if (key == FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody) { - return createJavaExpressionBodyTextarea(parent); - } - if (key == FiltersViewsRepository.JavaExpressionFilter.filterProperties) { - return createFilterProperties(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createFilterExpressionGroup(Composite parent) { - Group filterExpressionGroup = new Group(parent, SWT.NONE); - filterExpressionGroup.setText(FiltersMessages.JavaExpressionFilterPropertiesEditionPart_FilterExpressionGroupLabel); - GridData filterExpressionGroupData = new GridData(GridData.FILL_HORIZONTAL); - filterExpressionGroupData.horizontalSpan = 3; - filterExpressionGroup.setLayoutData(filterExpressionGroupData); - GridLayout filterExpressionGroupLayout = new GridLayout(); - filterExpressionGroupLayout.numColumns = 3; - filterExpressionGroup.setLayout(filterExpressionGroupLayout); - return filterExpressionGroup; - } - - - protected Composite createJavaExpressionBodyTextarea(Composite parent) { - Label javaExpressionBodyLabel = createDescription(parent, FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody, FiltersMessages.JavaExpressionFilterPropertiesEditionPart_JavaExpressionBodyLabel); - GridData javaExpressionBodyLabelData = new GridData(GridData.FILL_HORIZONTAL); - javaExpressionBodyLabelData.horizontalSpan = 3; - javaExpressionBodyLabel.setLayoutData(javaExpressionBodyLabelData); - javaExpressionBody = SWTUtils.createScrollableText(parent, SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); - GridData javaExpressionBodyData = new GridData(GridData.FILL_HORIZONTAL); - javaExpressionBodyData.horizontalSpan = 2; - javaExpressionBodyData.heightHint = 80; - javaExpressionBodyData.widthHint = 200; - javaExpressionBody.setLayoutData(javaExpressionBodyData); - javaExpressionBody.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaExpressionFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, javaExpressionBody.getText())); - } - - }); - EditingUtils.setID(javaExpressionBody, FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody); - EditingUtils.setEEFtype(javaExpressionBody, "eef::Textarea"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody, FiltersViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createJavaExpressionBodyTextArea - - // End of user code - return parent; - } - - protected Composite createFilterProperties(Composite container) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider(MappingViewsRepository.class); - filterPropertiesPropertiesEditionPart = (FilterPropertiesPropertiesEditionPart)provider.getPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, MappingViewsRepository.SWT_KIND, propertiesEditionComponent); - ((ISWTPropertiesEditionPart)filterPropertiesPropertiesEditionPart).createControls(container); - return container; - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#getJavaExpressionBody() - * - */ - public String getJavaExpressionBody() { - return javaExpressionBody.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#setJavaExpressionBody(String newValue) - * - */ - public void setJavaExpressionBody(String newValue) { - if (newValue != null) { - javaExpressionBody.setText(newValue); - } else { - javaExpressionBody.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.JavaExpressionFilter.FilterExpression.javaExpressionBody); - if (eefElementEditorReadOnlyState && javaExpressionBody.isEnabled()) { - javaExpressionBody.setEnabled(false); - javaExpressionBody.setBackground(javaExpressionBody.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - javaExpressionBody.setToolTipText(FiltersMessages.JavaExpressionFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !javaExpressionBody.isEnabled()) { - javaExpressionBody.setEnabled(true); - } - - } - - -/** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#getFilterPropertiesReferencedView() - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView() { - return (IPropertiesEditionPart) filterPropertiesPropertiesEditionPart; - } - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return filterPropertiesPropertiesEditionPart.getName(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - filterPropertiesPropertiesEditionPart.setName(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return filterPropertiesPropertiesEditionPart.getMandatory(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.JavaExpressionFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - filterPropertiesPropertiesEditionPart.setMandatory(newValue); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.JavaExpressionFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/OCLFilterPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/OCLFilterPropertiesEditionPartImpl.java deleted file mode 100644 index a86cf0cf3..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/OCLFilterPropertiesEditionPartImpl.java +++ /dev/null @@ -1,290 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.OCLFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class OCLFilterPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, OCLFilterPropertiesEditionPart { - - protected Text oCLExpressionBody; - private FilterPropertiesPropertiesEditionPart filterPropertiesPropertiesEditionPart; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public OCLFilterPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence oCLFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - oCLFilterStep - .addStep(FiltersViewsRepository.OCLFilter.FilterExpression.class) - .addStep(FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody); - - oCLFilterStep.addStep(FiltersViewsRepository.OCLFilter.filterProperties); - - composer = new PartComposer(oCLFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.OCLFilter.FilterExpression.class) { - return createFilterExpressionGroup(parent); - } - if (key == FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody) { - return createOCLExpressionBodyTextarea(parent); - } - if (key == FiltersViewsRepository.OCLFilter.filterProperties) { - return createFilterProperties(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createFilterExpressionGroup(Composite parent) { - Group filterExpressionGroup = new Group(parent, SWT.NONE); - filterExpressionGroup.setText(FiltersMessages.OCLFilterPropertiesEditionPart_FilterExpressionGroupLabel); - GridData filterExpressionGroupData = new GridData(GridData.FILL_HORIZONTAL); - filterExpressionGroupData.horizontalSpan = 3; - filterExpressionGroup.setLayoutData(filterExpressionGroupData); - GridLayout filterExpressionGroupLayout = new GridLayout(); - filterExpressionGroupLayout.numColumns = 3; - filterExpressionGroup.setLayout(filterExpressionGroupLayout); - return filterExpressionGroup; - } - - - protected Composite createOCLExpressionBodyTextarea(Composite parent) { - Label oCLExpressionBodyLabel = createDescription(parent, FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody, FiltersMessages.OCLFilterPropertiesEditionPart_OCLExpressionBodyLabel); - GridData oCLExpressionBodyLabelData = new GridData(GridData.FILL_HORIZONTAL); - oCLExpressionBodyLabelData.horizontalSpan = 3; - oCLExpressionBodyLabel.setLayoutData(oCLExpressionBodyLabelData); - oCLExpressionBody = SWTUtils.createScrollableText(parent, SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); - GridData oCLExpressionBodyData = new GridData(GridData.FILL_HORIZONTAL); - oCLExpressionBodyData.horizontalSpan = 2; - oCLExpressionBodyData.heightHint = 80; - oCLExpressionBodyData.widthHint = 200; - oCLExpressionBody.setLayoutData(oCLExpressionBodyData); - oCLExpressionBody.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(OCLFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, oCLExpressionBody.getText())); - } - - }); - EditingUtils.setID(oCLExpressionBody, FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody); - EditingUtils.setEEFtype(oCLExpressionBody, "eef::Textarea"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody, FiltersViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createOCLExpressionBodyTextArea - - // End of user code - return parent; - } - - protected Composite createFilterProperties(Composite container) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider(MappingViewsRepository.class); - filterPropertiesPropertiesEditionPart = (FilterPropertiesPropertiesEditionPart)provider.getPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, MappingViewsRepository.SWT_KIND, propertiesEditionComponent); - ((ISWTPropertiesEditionPart)filterPropertiesPropertiesEditionPart).createControls(container); - return container; - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#getOCLExpressionBody() - * - */ - public String getOCLExpressionBody() { - return oCLExpressionBody.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#setOCLExpressionBody(String newValue) - * - */ - public void setOCLExpressionBody(String newValue) { - if (newValue != null) { - oCLExpressionBody.setText(newValue); - } else { - oCLExpressionBody.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.OCLFilter.FilterExpression.oCLExpressionBody); - if (eefElementEditorReadOnlyState && oCLExpressionBody.isEnabled()) { - oCLExpressionBody.setEnabled(false); - oCLExpressionBody.setBackground(oCLExpressionBody.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - oCLExpressionBody.setToolTipText(FiltersMessages.OCLFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !oCLExpressionBody.isEnabled()) { - oCLExpressionBody.setEnabled(true); - } - - } - - -/** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#getFilterPropertiesReferencedView() - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView() { - return (IPropertiesEditionPart) filterPropertiesPropertiesEditionPart; - } - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return filterPropertiesPropertiesEditionPart.getName(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - filterPropertiesPropertiesEditionPart.setName(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return filterPropertiesPropertiesEditionPart.getMandatory(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OCLFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - filterPropertiesPropertiesEditionPart.setMandatory(newValue); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.OCLFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/OnlyReferenceTypeFilterPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/OnlyReferenceTypeFilterPropertiesEditionPartImpl.java deleted file mode 100644 index 93461e972..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/OnlyReferenceTypeFilterPropertiesEditionPartImpl.java +++ /dev/null @@ -1,338 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class OnlyReferenceTypeFilterPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, OnlyReferenceTypeFilterPropertiesEditionPart { - - protected EObjectFlatComboViewer referencedFeature; - private FilterPropertiesPropertiesEditionPart filterPropertiesPropertiesEditionPart; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public OnlyReferenceTypeFilterPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence onlyReferenceTypeFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - onlyReferenceTypeFilterStep - .addStep(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.class) - .addStep(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_); - - onlyReferenceTypeFilterStep.addStep(FiltersViewsRepository.OnlyReferenceTypeFilter.filterProperties); - - composer = new PartComposer(onlyReferenceTypeFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.class) { - return createReferencedFeatureGroup(parent); - } - if (key == FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_) { - return createReferencedFeatureFlatComboViewer(parent); - } - if (key == FiltersViewsRepository.OnlyReferenceTypeFilter.filterProperties) { - return createFilterProperties(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createReferencedFeatureGroup(Composite parent) { - Group referencedFeatureGroup = new Group(parent, SWT.NONE); - referencedFeatureGroup.setText(FiltersMessages.OnlyReferenceTypeFilterPropertiesEditionPart_ReferencedFeatureGroupLabel); - GridData referencedFeatureGroupData = new GridData(GridData.FILL_HORIZONTAL); - referencedFeatureGroupData.horizontalSpan = 3; - referencedFeatureGroup.setLayoutData(referencedFeatureGroupData); - GridLayout referencedFeatureGroupLayout = new GridLayout(); - referencedFeatureGroupLayout.numColumns = 3; - referencedFeatureGroup.setLayout(referencedFeatureGroupLayout); - return referencedFeatureGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createReferencedFeatureFlatComboViewer(Composite parent) { - createDescription(parent, FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_, FiltersMessages.OnlyReferenceTypeFilterPropertiesEditionPart_ReferencedFeatureLabel); - referencedFeature = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_, FiltersViewsRepository.SWT_KIND)); - referencedFeature.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - referencedFeature.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(OnlyReferenceTypeFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getReferencedFeature())); - } - - }); - GridData referencedFeatureData = new GridData(GridData.FILL_HORIZONTAL); - referencedFeature.setLayoutData(referencedFeatureData); - referencedFeature.setID(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_, FiltersViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createReferencedFeatureFlatComboViewer - - // End of user code - return parent; - } - - protected Composite createFilterProperties(Composite container) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider(MappingViewsRepository.class); - filterPropertiesPropertiesEditionPart = (FilterPropertiesPropertiesEditionPart)provider.getPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, MappingViewsRepository.SWT_KIND, propertiesEditionComponent); - ((ISWTPropertiesEditionPart)filterPropertiesPropertiesEditionPart).createControls(container); - return container; - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#getReferencedFeature() - * - */ - public EObject getReferencedFeature() { - if (referencedFeature.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) referencedFeature.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#initReferencedFeature(EObjectFlatComboSettings) - */ - public void initReferencedFeature(EObjectFlatComboSettings settings) { - referencedFeature.setInput(settings); - if (current != null) { - referencedFeature.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_); - if (eefElementEditorReadOnlyState && referencedFeature.isEnabled()) { - referencedFeature.setEnabled(false); - referencedFeature.setToolTipText(FiltersMessages.OnlyReferenceTypeFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !referencedFeature.isEnabled()) { - referencedFeature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#setReferencedFeature(EObject newValue) - * - */ - public void setReferencedFeature(EObject newValue) { - if (newValue != null) { - referencedFeature.setSelection(new StructuredSelection(newValue)); - } else { - referencedFeature.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.OnlyReferenceTypeFilter.ReferencedFeature.referencedFeature_); - if (eefElementEditorReadOnlyState && referencedFeature.isEnabled()) { - referencedFeature.setEnabled(false); - referencedFeature.setToolTipText(FiltersMessages.OnlyReferenceTypeFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !referencedFeature.isEnabled()) { - referencedFeature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#setReferencedFeatureButtonMode(ButtonsModeEnum newValue) - */ - public void setReferencedFeatureButtonMode(ButtonsModeEnum newValue) { - referencedFeature.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#addFilterReferencedFeature(ViewerFilter filter) - * - */ - public void addFilterToReferencedFeature(ViewerFilter filter) { - referencedFeature.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#addBusinessFilterReferencedFeature(ViewerFilter filter) - * - */ - public void addBusinessFilterToReferencedFeature(ViewerFilter filter) { - referencedFeature.addBusinessRuleFilter(filter); - } - - -/** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#getFilterPropertiesReferencedView() - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView() { - return (IPropertiesEditionPart) filterPropertiesPropertiesEditionPart; - } - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return filterPropertiesPropertiesEditionPart.getName(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - filterPropertiesPropertiesEditionPart.setName(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return filterPropertiesPropertiesEditionPart.getMandatory(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.OnlyReferenceTypeFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - filterPropertiesPropertiesEditionPart.setMandatory(newValue); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.OnlyReferenceTypeFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/StrictTypingFilterPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/StrictTypingFilterPropertiesEditionPartImpl.java deleted file mode 100644 index 5bc700538..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/parts/impl/StrictTypingFilterPropertiesEditionPartImpl.java +++ /dev/null @@ -1,338 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; -import org.eclipse.emf.eef.mapping.filters.parts.StrictTypingFilterPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.filters.providers.FiltersMessages; -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StrictTypingFilterPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, StrictTypingFilterPropertiesEditionPart { - - protected EObjectFlatComboViewer restriction; - private FilterPropertiesPropertiesEditionPart filterPropertiesPropertiesEditionPart; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public StrictTypingFilterPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence strictTypingFilterStep = new BindingCompositionSequence(propertiesEditionComponent); - strictTypingFilterStep - .addStep(FiltersViewsRepository.StrictTypingFilter.Type.class) - .addStep(FiltersViewsRepository.StrictTypingFilter.Type.restriction); - - strictTypingFilterStep.addStep(FiltersViewsRepository.StrictTypingFilter.filterProperties); - - composer = new PartComposer(strictTypingFilterStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == FiltersViewsRepository.StrictTypingFilter.Type.class) { - return createTypeGroup(parent); - } - if (key == FiltersViewsRepository.StrictTypingFilter.Type.restriction) { - return createRestrictionFlatComboViewer(parent); - } - if (key == FiltersViewsRepository.StrictTypingFilter.filterProperties) { - return createFilterProperties(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createTypeGroup(Composite parent) { - Group typeGroup = new Group(parent, SWT.NONE); - typeGroup.setText(FiltersMessages.StrictTypingFilterPropertiesEditionPart_TypeGroupLabel); - GridData typeGroupData = new GridData(GridData.FILL_HORIZONTAL); - typeGroupData.horizontalSpan = 3; - typeGroup.setLayoutData(typeGroupData); - GridLayout typeGroupLayout = new GridLayout(); - typeGroupLayout.numColumns = 3; - typeGroup.setLayout(typeGroupLayout); - return typeGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createRestrictionFlatComboViewer(Composite parent) { - createDescription(parent, FiltersViewsRepository.StrictTypingFilter.Type.restriction, FiltersMessages.StrictTypingFilterPropertiesEditionPart_RestrictionLabel); - restriction = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(FiltersViewsRepository.StrictTypingFilter.Type.restriction, FiltersViewsRepository.SWT_KIND)); - restriction.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - restriction.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StrictTypingFilterPropertiesEditionPartImpl.this, FiltersViewsRepository.StrictTypingFilter.Type.restriction, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getRestriction())); - } - - }); - GridData restrictionData = new GridData(GridData.FILL_HORIZONTAL); - restriction.setLayoutData(restrictionData); - restriction.setID(FiltersViewsRepository.StrictTypingFilter.Type.restriction); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(FiltersViewsRepository.StrictTypingFilter.Type.restriction, FiltersViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createRestrictionFlatComboViewer - - // End of user code - return parent; - } - - protected Composite createFilterProperties(Composite container) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance().getProvider(MappingViewsRepository.class); - filterPropertiesPropertiesEditionPart = (FilterPropertiesPropertiesEditionPart)provider.getPropertiesEditionPart(MappingViewsRepository.FilterProperties.class, MappingViewsRepository.SWT_KIND, propertiesEditionComponent); - ((ISWTPropertiesEditionPart)filterPropertiesPropertiesEditionPart).createControls(container); - return container; - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#getRestriction() - * - */ - public EObject getRestriction() { - if (restriction.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) restriction.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#initRestriction(EObjectFlatComboSettings) - */ - public void initRestriction(EObjectFlatComboSettings settings) { - restriction.setInput(settings); - if (current != null) { - restriction.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.StrictTypingFilter.Type.restriction); - if (eefElementEditorReadOnlyState && restriction.isEnabled()) { - restriction.setEnabled(false); - restriction.setToolTipText(FiltersMessages.StrictTypingFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !restriction.isEnabled()) { - restriction.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#setRestriction(EObject newValue) - * - */ - public void setRestriction(EObject newValue) { - if (newValue != null) { - restriction.setSelection(new StructuredSelection(newValue)); - } else { - restriction.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(FiltersViewsRepository.StrictTypingFilter.Type.restriction); - if (eefElementEditorReadOnlyState && restriction.isEnabled()) { - restriction.setEnabled(false); - restriction.setToolTipText(FiltersMessages.StrictTypingFilter_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !restriction.isEnabled()) { - restriction.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#setRestrictionButtonMode(ButtonsModeEnum newValue) - */ - public void setRestrictionButtonMode(ButtonsModeEnum newValue) { - restriction.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#addFilterRestriction(ViewerFilter filter) - * - */ - public void addFilterToRestriction(ViewerFilter filter) { - restriction.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#addBusinessFilterRestriction(ViewerFilter filter) - * - */ - public void addBusinessFilterToRestriction(ViewerFilter filter) { - restriction.addBusinessRuleFilter(filter); - } - - -/** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#getFilterPropertiesReferencedView() - * - */ - public IPropertiesEditionPart getFilterPropertiesReferencedView() { - return (IPropertiesEditionPart) filterPropertiesPropertiesEditionPart; - } - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#getName() - * - */ - public String getName() { - return filterPropertiesPropertiesEditionPart.getName(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - filterPropertiesPropertiesEditionPart.setName(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return filterPropertiesPropertiesEditionPart.getMandatory(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.StrictTypingFilterPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - filterPropertiesPropertiesEditionPart.setMandatory(newValue); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return FiltersMessages.StrictTypingFilter_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/BindingFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/BindingFilterItemProvider.java deleted file mode 100644 index c3c9afdba..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/BindingFilterItemProvider.java +++ /dev/null @@ -1,152 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.provider.DocumentedElementItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.BindingFilter} object. - * - * - * @generated - */ -public class BindingFilterItemProvider extends DocumentedElementItemProvider - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public BindingFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addNamePropertyDescriptor(object); - addMandatoryPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Name feature. - * - * - * @generated - */ - protected void addNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_BindingFilter_name_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_BindingFilter_name_feature", - "_UI_BindingFilter_type"), - FiltersPackage.Literals.BINDING_FILTER__NAME, true, false, - false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - - /** - * This adds a property descriptor for the Mandatory feature. - * - * - * @generated - */ - protected void addMandatoryPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_BindingFilter_mandatory_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_BindingFilter_mandatory_feature", - "_UI_BindingFilter_type"), - FiltersPackage.Literals.BINDING_FILTER__MANDATORY, true, false, - false, ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, null, null)); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((BindingFilter) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_BindingFilter_type") - : getString("_UI_BindingFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(BindingFilter.class)) { - case FiltersPackage.BINDING_FILTER__NAME: - case FiltersPackage.BINDING_FILTER__MANDATORY: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/BusinessFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/BusinessFilterItemProvider.java deleted file mode 100644 index 870a1157b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/BusinessFilterItemProvider.java +++ /dev/null @@ -1,99 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.filters.BusinessFilter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.BusinessFilter} object. - * - * - * @generated - */ -public class BusinessFilterItemProvider extends BindingFilterItemProvider - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public BusinessFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((BusinessFilter) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_BusinessFilter_type") - : getString("_UI_BusinessFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/FiltersItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/FiltersItemProviderAdapterFactory.java deleted file mode 100644 index db2a882b2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/FiltersItemProviderAdapterFactory.java +++ /dev/null @@ -1,412 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ChildCreationExtenderManager; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.util.FiltersAdapterFactory; -import org.eclipse.emf.eef.mapping.provider.MappingEditPlugin; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class FiltersItemProviderAdapterFactory extends FiltersAdapterFactory - implements ComposeableAdapterFactory, IChangeNotifier, IDisposable, - IChildCreationExtender { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This helps manage the child creation extenders. - * - * - * @generated - */ - protected ChildCreationExtenderManager childCreationExtenderManager = new ChildCreationExtenderManager( - MappingEditPlugin.INSTANCE, FiltersPackage.eNS_URI); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public FiltersItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.filters.OCLFilter} instances. - * - * - * @generated - */ - protected OCLFilterItemProvider oclFilterItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.filters.OCLFilter}. - * - * - * @generated - */ - @Override - public Adapter createOCLFilterAdapter() { - if (oclFilterItemProvider == null) { - oclFilterItemProvider = new OCLFilterItemProvider(this); - } - - return oclFilterItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter} instances. - * - * - * @generated - */ - protected JavaDeclarationFilterItemProvider javaDeclarationFilterItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter}. - * - * - * @generated - */ - @Override - public Adapter createJavaDeclarationFilterAdapter() { - if (javaDeclarationFilterItemProvider == null) { - javaDeclarationFilterItemProvider = new JavaDeclarationFilterItemProvider( - this); - } - - return javaDeclarationFilterItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter} instances. - * - * - * @generated - */ - protected JavaExpressionFilterItemProvider javaExpressionFilterItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter}. - * - * - * @generated - */ - @Override - public Adapter createJavaExpressionFilterAdapter() { - if (javaExpressionFilterItemProvider == null) { - javaExpressionFilterItemProvider = new JavaExpressionFilterItemProvider( - this); - } - - return javaExpressionFilterItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter} instances. - * - * - * @generated - */ - protected OnlyReferenceTypeFilterItemProvider onlyReferenceTypeFilterItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter}. - * - * - * @generated - */ - @Override - public Adapter createOnlyReferenceTypeFilterAdapter() { - if (onlyReferenceTypeFilterItemProvider == null) { - onlyReferenceTypeFilterItemProvider = new OnlyReferenceTypeFilterItemProvider( - this); - } - - return onlyReferenceTypeFilterItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.filters.StrictTypingFilter} instances. - * - * - * @generated - */ - protected StrictTypingFilterItemProvider strictTypingFilterItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.filters.StrictTypingFilter}. - * - * - * @generated - */ - @Override - public Adapter createStrictTypingFilterAdapter() { - if (strictTypingFilterItemProvider == null) { - strictTypingFilterItemProvider = new StrictTypingFilterItemProvider( - this); - } - - return strictTypingFilterItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter} instances. - * - * - * @generated - */ - protected JavaBodyStepFilterItemProvider javaBodyStepFilterItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter}. - * - * - * @generated - */ - @Override - public Adapter createJavaBodyStepFilterAdapter() { - if (javaBodyStepFilterItemProvider == null) { - javaBodyStepFilterItemProvider = new JavaBodyStepFilterItemProvider( - this); - } - - return javaBodyStepFilterItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter} instances. - * - * - * @generated - */ - protected JavaDeclarationStepFilterItemProvider javaDeclarationStepFilterItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter}. - * - * - * @generated - */ - @Override - public Adapter createJavaDeclarationStepFilterAdapter() { - if (javaDeclarationStepFilterItemProvider == null) { - javaDeclarationStepFilterItemProvider = new JavaDeclarationStepFilterItemProvider( - this); - } - - return javaDeclarationStepFilterItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory - .getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory( - ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) - || (((Class) type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * - * - * @generated - */ - public List getChildCreationExtenders() { - return childCreationExtenderManager.getChildCreationExtenders(); - } - - /** - * - * - * @generated - */ - public Collection getNewChildDescriptors(Object object, - EditingDomain editingDomain) { - return childCreationExtenderManager.getNewChildDescriptors(object, - editingDomain); - } - - /** - * - * - * @generated - */ - public ResourceLocator getResourceLocator() { - return childCreationExtenderManager; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (oclFilterItemProvider != null) - oclFilterItemProvider.dispose(); - if (javaDeclarationFilterItemProvider != null) - javaDeclarationFilterItemProvider.dispose(); - if (javaExpressionFilterItemProvider != null) - javaExpressionFilterItemProvider.dispose(); - if (onlyReferenceTypeFilterItemProvider != null) - onlyReferenceTypeFilterItemProvider.dispose(); - if (strictTypingFilterItemProvider != null) - strictTypingFilterItemProvider.dispose(); - if (javaBodyStepFilterItemProvider != null) - javaBodyStepFilterItemProvider.dispose(); - if (javaDeclarationStepFilterItemProvider != null) - javaDeclarationStepFilterItemProvider.dispose(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaBodyStepFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaBodyStepFilterItemProvider.java deleted file mode 100644 index 389ec76fd..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaBodyStepFilterItemProvider.java +++ /dev/null @@ -1,112 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter; - -import org.eclipse.emf.eef.mapping.navigation.provider.JavaBodyExpressionItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter} object. - * - * - * @generated - */ -public class JavaBodyStepFilterItemProvider extends - JavaBodyExpressionItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public JavaBodyStepFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns JavaBodyStepFilter.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator().getImage("full/obj16/JavaBodyStepFilter")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((JavaBodyStepFilter) object).getBody(); - return label == null || label.length() == 0 ? getString("_UI_JavaBodyStepFilter_type") - : getString("_UI_JavaBodyStepFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaDeclarationFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaDeclarationFilterItemProvider.java deleted file mode 100644 index 32ddd2f57..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaDeclarationFilterItemProvider.java +++ /dev/null @@ -1,145 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter} object. - * - * - * @generated - */ -public class JavaDeclarationFilterItemProvider extends JavaFilterItemProvider - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public JavaDeclarationFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addMethodNamePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Method Name feature. - * - * - * @generated - */ - protected void addMethodNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_JavaDeclarationFilter_methodName_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_JavaDeclarationFilter_methodName_feature", - "_UI_JavaDeclarationFilter_type"), - FiltersPackage.Literals.JAVA_DECLARATION_FILTER__METHOD_NAME, - true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, null)); - } - - /** - * This returns JavaDeclarationFilter.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/JavaDeclarationFilter")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((JavaDeclarationFilter) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_JavaDeclarationFilter_type") - : getString("_UI_JavaDeclarationFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(JavaDeclarationFilter.class)) { - case FiltersPackage.JAVA_DECLARATION_FILTER__METHOD_NAME: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaDeclarationStepFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaDeclarationStepFilterItemProvider.java deleted file mode 100644 index c96bdcead..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaDeclarationStepFilterItemProvider.java +++ /dev/null @@ -1,114 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter; - -import org.eclipse.emf.eef.mapping.navigation.provider.JavaDeclarationExpressionItemProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter} object. - * - * - * @generated - */ -public class JavaDeclarationStepFilterItemProvider extends - JavaDeclarationExpressionItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public JavaDeclarationStepFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns JavaDeclarationStepFilter.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/JavaDeclarationStepFilter")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((JavaDeclarationStepFilter) object).getMethodName(); - return label == null || label.length() == 0 ? getString("_UI_JavaDeclarationStepFilter_type") - : getString("_UI_JavaDeclarationStepFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaExpressionFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaExpressionFilterItemProvider.java deleted file mode 100644 index f3b74259c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaExpressionFilterItemProvider.java +++ /dev/null @@ -1,144 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter} object. - * - * - * @generated - */ -public class JavaExpressionFilterItemProvider extends JavaFilterItemProvider - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public JavaExpressionFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addJavaBodyPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Java Body feature. - * - * - * @generated - */ - protected void addJavaBodyPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_JavaExpressionFilter_javaBody_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_JavaExpressionFilter_javaBody_feature", - "_UI_JavaExpressionFilter_type"), - FiltersPackage.Literals.JAVA_EXPRESSION_FILTER__JAVA_BODY, - true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, null)); - } - - /** - * This returns JavaExpressionFilter.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator() - .getImage("full/obj16/JavaExpressionFilter")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((JavaExpressionFilter) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_JavaExpressionFilter_type") - : getString("_UI_JavaExpressionFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(JavaExpressionFilter.class)) { - case FiltersPackage.JAVA_EXPRESSION_FILTER__JAVA_BODY: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaFilterItemProvider.java deleted file mode 100644 index 2bb46f2b3..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/JavaFilterItemProvider.java +++ /dev/null @@ -1,99 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.filters.JavaFilter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.JavaFilter} object. - * - * - * @generated - */ -public class JavaFilterItemProvider extends BindingFilterItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public JavaFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((JavaFilter) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_JavaFilter_type") - : getString("_UI_JavaFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/OCLFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/OCLFilterItemProvider.java deleted file mode 100644 index 637ed2854..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/OCLFilterItemProvider.java +++ /dev/null @@ -1,141 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.OCLFilter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.OCLFilter} object. - * - * - * @generated - */ -public class OCLFilterItemProvider extends BindingFilterItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public OCLFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addOCLBodyPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the OCL Body feature. - * - * - * @generated - */ - protected void addOCLBodyPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_OCLFilter_OCLBody_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_OCLFilter_OCLBody_feature", "_UI_OCLFilter_type"), - FiltersPackage.Literals.OCL_FILTER__OCL_BODY, true, false, - false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - - /** - * This returns OCLFilter.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator().getImage("full/obj16/OCLFilter")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((OCLFilter) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_OCLFilter_type") - : getString("_UI_OCLFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(OCLFilter.class)) { - case FiltersPackage.OCL_FILTER__OCL_BODY: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/OnlyReferenceTypeFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/OnlyReferenceTypeFilterItemProvider.java deleted file mode 100644 index 672f8ea48..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/OnlyReferenceTypeFilterItemProvider.java +++ /dev/null @@ -1,136 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter} object. - * - * - * @generated - */ -public class OnlyReferenceTypeFilterItemProvider extends - BusinessFilterItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public OnlyReferenceTypeFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addReferencePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Reference feature. - * - * - * @generated - */ - protected void addReferencePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_OnlyReferenceTypeFilter_reference_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_OnlyReferenceTypeFilter_reference_feature", - "_UI_OnlyReferenceTypeFilter_type"), - FiltersPackage.Literals.ONLY_REFERENCE_TYPE_FILTER__REFERENCE, - true, false, true, null, null, null)); - } - - /** - * This returns OnlyReferenceTypeFilter.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/OnlyReferenceTypeFilter")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((OnlyReferenceTypeFilter) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_OnlyReferenceTypeFilter_type") - : getString("_UI_OnlyReferenceTypeFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/StepFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/StepFilterItemProvider.java deleted file mode 100644 index a2eeb4b68..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/StepFilterItemProvider.java +++ /dev/null @@ -1,108 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.StepFilter} object. - * - * - * @generated - */ -public class StepFilterItemProvider extends ItemProviderAdapter implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public StepFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_StepFilter_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender) adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/StrictTypingFilterItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/StrictTypingFilterItemProvider.java deleted file mode 100644 index e5c7460ee..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/provider/StrictTypingFilterItemProvider.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.StrictTypingFilter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.filters.StrictTypingFilter} object. - * - * - * @generated - */ -public class StrictTypingFilterItemProvider extends BusinessFilterItemProvider - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public StrictTypingFilterItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addTypePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Type feature. - * - * - * @generated - */ - protected void addTypePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_StrictTypingFilter_type_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_StrictTypingFilter_type_feature", - "_UI_StrictTypingFilter_type"), - FiltersPackage.Literals.STRICT_TYPING_FILTER__TYPE, true, - false, true, null, null, null)); - } - - /** - * This returns StrictTypingFilter.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator().getImage("full/obj16/StrictTypingFilter")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((StrictTypingFilter) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_StrictTypingFilter_type") - : getString("_UI_StrictTypingFilter_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/FiltersMessages.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/FiltersMessages.java deleted file mode 100644 index 08665b306..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/FiltersMessages.java +++ /dev/null @@ -1,177 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.providers; - -import org.eclipse.osgi.util.NLS; - -/** - * @author Nathalie Lepine - * - */ -public class FiltersMessages extends NLS { - - private static final String BUNDLE_NAME = "org.eclipse.emf.eef.mapping.filters.providers.filtersMessages"; //$NON-NLS-1$ - - - public static String OnlyReferenceTypeFilterPropertiesEditionPart_ReferencedFeatureGroupLabel; - - - public static String OCLFilterPropertiesEditionPart_FilterExpressionGroupLabel; - - - public static String JavaExpressionFilterPropertiesEditionPart_FilterExpressionGroupLabel; - - - public static String JavaDeclarationFilterPropertiesEditionPart_FilterExpressionGroupLabel; - - - public static String StrictTypingFilterPropertiesEditionPart_TypeGroupLabel; - - - public static String JavaDeclarationStepFilterPropertiesEditionPart_PropertiesGroupLabel; - - - public static String JavaBodyStepFilterPropertiesEditionPart_PropertiesGroupLabel; - - - - public static String OnlyReferenceTypeFilter_ReadOnly; - - - public static String OnlyReferenceTypeFilter_Part_Title; - - - public static String OCLFilter_ReadOnly; - - - public static String OCLFilter_Part_Title; - - - public static String JavaExpressionFilter_ReadOnly; - - - public static String JavaExpressionFilter_Part_Title; - - - public static String JavaDeclarationFilter_ReadOnly; - - - public static String JavaDeclarationFilter_Part_Title; - - - public static String StrictTypingFilter_ReadOnly; - - - public static String StrictTypingFilter_Part_Title; - - - public static String JavaDeclarationStepFilter_ReadOnly; - - - public static String JavaDeclarationStepFilter_Part_Title; - - - public static String JavaBodyStepFilter_ReadOnly; - - - public static String JavaBodyStepFilter_Part_Title; - - - - public static String OnlyReferenceTypeFilterPropertiesEditionPart_ReferencedFeatureLabel; - - - public static String OCLFilterPropertiesEditionPart_OCLExpressionBodyLabel; - - - public static String JavaExpressionFilterPropertiesEditionPart_JavaExpressionBodyLabel; - - - public static String JavaDeclarationFilterPropertiesEditionPart_MethodNameLabel; - - - public static String StrictTypingFilterPropertiesEditionPart_RestrictionLabel; - - - public static String JavaDeclarationStepFilterPropertiesEditionPart_QualifiedClassLabel; - - - public static String JavaDeclarationStepFilterPropertiesEditionPart_MethodFilterLabel; - - - public static String JavaDeclarationStepFilterPropertiesEditionPart_StaticMethodLabel; - - - public static String JavaBodyStepFilterPropertiesEditionPart_BodyLabel; - - - - public static String PropertiesEditionPart_DocumentationLabel; - - - public static String PropertiesEditionPart_IntegerValueMessage; - - - public static String PropertiesEditionPart_FloatValueMessage; - - - public static String PropertiesEditionPart_ShortValueMessage; - - - public static String PropertiesEditionPart_LongValueMessage; - - - public static String PropertiesEditionPart_ByteValueMessage; - - - public static String PropertiesEditionPart_BigIntegerValueMessage; - - - public static String PropertiesEditionPart_BigDecimalValueMessage; - - - public static String PropertiesEditionPart_DoubleValueMessage; - - - public static String PropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesEditionPart_RequiredFeatureMessage; - - - public static String PropertiesEditionPart_AddTableViewerLabel; - - - public static String PropertiesEditionPart_EditTableViewerLabel; - - - public static String PropertiesEditionPart_RemoveTableViewerLabel; - - - public static String PropertiesEditionPart_AddListViewerLabel; - - - public static String PropertiesEditionPart_RemoveListViewerLabel; - - // Start of user code for additionnal NLS Constants - - // End of user code - - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, FiltersMessages.class); - } - - - private FiltersMessages() { - //protect instanciation - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/FiltersPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/FiltersPropertiesEditionPartProvider.java deleted file mode 100644 index b5532f04a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/FiltersPropertiesEditionPartProvider.java +++ /dev/null @@ -1,103 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.providers; - -import org.eclipse.emf.eef.mapping.filters.parts.FiltersViewsRepository; - -import org.eclipse.emf.eef.mapping.filters.parts.forms.JavaBodyStepFilterPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.filters.parts.forms.JavaDeclarationFilterPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.filters.parts.forms.JavaDeclarationStepFilterPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.filters.parts.forms.JavaExpressionFilterPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.filters.parts.forms.OCLFilterPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.filters.parts.forms.OnlyReferenceTypeFilterPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.filters.parts.forms.StrictTypingFilterPropertiesEditionPartForm; - -import org.eclipse.emf.eef.mapping.filters.parts.impl.JavaBodyStepFilterPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.filters.parts.impl.JavaDeclarationFilterPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.filters.parts.impl.JavaDeclarationStepFilterPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.filters.parts.impl.JavaExpressionFilterPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.filters.parts.impl.OCLFilterPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.filters.parts.impl.OnlyReferenceTypeFilterPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.filters.parts.impl.StrictTypingFilterPropertiesEditionPartImpl; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; - -/** - * @author Nathalie Lepine - * - */ -public class FiltersPropertiesEditionPartProvider implements IPropertiesEditionPartProvider { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#provides(java.lang.Object) - * - */ - public boolean provides(Object key) { - return key == FiltersViewsRepository.class; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#getPropertiesEditionPart(java.lang.Object, int, org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, IPropertiesEditionComponent component) { - if (key == FiltersViewsRepository.OnlyReferenceTypeFilter.class) { - if (kind == FiltersViewsRepository.SWT_KIND) - return new OnlyReferenceTypeFilterPropertiesEditionPartImpl(component); - if (kind == FiltersViewsRepository.FORM_KIND) - return new OnlyReferenceTypeFilterPropertiesEditionPartForm(component); - } - if (key == FiltersViewsRepository.OCLFilter.class) { - if (kind == FiltersViewsRepository.SWT_KIND) - return new OCLFilterPropertiesEditionPartImpl(component); - if (kind == FiltersViewsRepository.FORM_KIND) - return new OCLFilterPropertiesEditionPartForm(component); - } - if (key == FiltersViewsRepository.JavaExpressionFilter.class) { - if (kind == FiltersViewsRepository.SWT_KIND) - return new JavaExpressionFilterPropertiesEditionPartImpl(component); - if (kind == FiltersViewsRepository.FORM_KIND) - return new JavaExpressionFilterPropertiesEditionPartForm(component); - } - if (key == FiltersViewsRepository.JavaDeclarationFilter.class) { - if (kind == FiltersViewsRepository.SWT_KIND) - return new JavaDeclarationFilterPropertiesEditionPartImpl(component); - if (kind == FiltersViewsRepository.FORM_KIND) - return new JavaDeclarationFilterPropertiesEditionPartForm(component); - } - if (key == FiltersViewsRepository.StrictTypingFilter.class) { - if (kind == FiltersViewsRepository.SWT_KIND) - return new StrictTypingFilterPropertiesEditionPartImpl(component); - if (kind == FiltersViewsRepository.FORM_KIND) - return new StrictTypingFilterPropertiesEditionPartForm(component); - } - if (key == FiltersViewsRepository.JavaDeclarationStepFilter.class) { - if (kind == FiltersViewsRepository.SWT_KIND) - return new JavaDeclarationStepFilterPropertiesEditionPartImpl(component); - if (kind == FiltersViewsRepository.FORM_KIND) - return new JavaDeclarationStepFilterPropertiesEditionPartForm(component); - } - if (key == FiltersViewsRepository.JavaBodyStepFilter.class) { - if (kind == FiltersViewsRepository.SWT_KIND) - return new JavaBodyStepFilterPropertiesEditionPartImpl(component); - if (kind == FiltersViewsRepository.FORM_KIND) - return new JavaBodyStepFilterPropertiesEditionPartForm(component); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/filtersMessages.properties b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/filtersMessages.properties deleted file mode 100644 index 5c96963f0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/filtersMessages.properties +++ /dev/null @@ -1,62 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -OnlyReferenceTypeFilterPropertiesEditionPart_ReferencedFeatureGroupLabel=Referenced feature -OCLFilterPropertiesEditionPart_FilterExpressionGroupLabel=Filter expression -JavaExpressionFilterPropertiesEditionPart_FilterExpressionGroupLabel=Filter expression -JavaDeclarationFilterPropertiesEditionPart_FilterExpressionGroupLabel=Filter expression -StrictTypingFilterPropertiesEditionPart_TypeGroupLabel=Type -JavaDeclarationStepFilterPropertiesEditionPart_PropertiesGroupLabel=Properties -JavaBodyStepFilterPropertiesEditionPart_PropertiesGroupLabel=Properties -OnlyReferenceTypeFilter_ReadOnly=This property is read only -OnlyReferenceTypeFilter_Part_Title=Base -OCLFilter_ReadOnly=This property is read only -OCLFilter_Part_Title=Base -JavaExpressionFilter_ReadOnly=This property is read only -JavaExpressionFilter_Part_Title=Base -JavaDeclarationFilter_ReadOnly=This property is read only -JavaDeclarationFilter_Part_Title=Base -StrictTypingFilter_ReadOnly=This property is read only -StrictTypingFilter_Part_Title=StrictTypingFilter -JavaDeclarationStepFilter_ReadOnly=This property is read only -JavaDeclarationStepFilter_Part_Title=Base -JavaBodyStepFilter_ReadOnly=This property is read only -JavaBodyStepFilter_Part_Title=Base -OnlyReferenceTypeFilterPropertiesEditionPart_ReferencedFeatureLabel=ReferencedFeature : -OCLFilterPropertiesEditionPart_OCLExpressionBodyLabel=OCLExpressionBody : -JavaExpressionFilterPropertiesEditionPart_JavaExpressionBodyLabel=JavaExpressionBody : -JavaDeclarationFilterPropertiesEditionPart_MethodNameLabel=MethodName : -StrictTypingFilterPropertiesEditionPart_RestrictionLabel=Restriction : -JavaDeclarationStepFilterPropertiesEditionPart_QualifiedClassLabel=QualifiedClass : -JavaDeclarationStepFilterPropertiesEditionPart_MethodFilterLabel=MethodFilter : -JavaDeclarationStepFilterPropertiesEditionPart_StaticMethodLabel=StaticMethod -JavaBodyStepFilterPropertiesEditionPart_BodyLabel=Body : -PropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionPart_EditTableViewerLabel=Edit -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=The property {0} of the object shall be filled -PropertiesEditionPart_RemoveTableViewerLabel=Delete -PropertiesEditionPart_RemoveListViewerLabel=Delete -PropertiesEditionPart_IntegerValueMessage=The property {0} shall be an integer -PropertiesEditionPart_FloatValueMessage=The property {0} shall be a float -PropertiesEditionPart_ShortValueMessage=The property {0} shall be a short -PropertiesEditionPart_DoubleValueMessage=The property {0} shall be a double -PropertiesEditionPart_ByteValueMessage=The property {0} shall be a byte -PropertiesEditionPart_LongValueMessage=The property {0} shall be a long -PropertiesEditionPart_BigIntegerValueMessage=The property {0} shall be a BigInteger -PropertiesEditionPart_BigDecimalValueMessage=The property {0} shall be a BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Add -PropertiesEditionPart_AddListViewerLabel=Add diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/filtersMessages_fr.properties b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/filtersMessages_fr.properties deleted file mode 100644 index 9533c91f7..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/filters/providers/filtersMessages_fr.properties +++ /dev/null @@ -1,62 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -OnlyReferenceTypeFilterPropertiesEditionPart_ReferencedFeatureGroupLabel=Referenced feature -OCLFilterPropertiesEditionPart_FilterExpressionGroupLabel=Filter expression -JavaExpressionFilterPropertiesEditionPart_FilterExpressionGroupLabel=Filter expression -JavaDeclarationFilterPropertiesEditionPart_FilterExpressionGroupLabel=Filter expression -StrictTypingFilterPropertiesEditionPart_TypeGroupLabel=Type -JavaDeclarationStepFilterPropertiesEditionPart_PropertiesGroupLabel=Properties -JavaBodyStepFilterPropertiesEditionPart_PropertiesGroupLabel=Properties -OnlyReferenceTypeFilter_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -OnlyReferenceTypeFilter_Part_Title=Base -OCLFilter_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -OCLFilter_Part_Title=Base -JavaExpressionFilter_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -JavaExpressionFilter_Part_Title=Base -JavaDeclarationFilter_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -JavaDeclarationFilter_Part_Title=Base -StrictTypingFilter_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -StrictTypingFilter_Part_Title=StrictTypingFilter -JavaDeclarationStepFilter_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -JavaDeclarationStepFilter_Part_Title=Base -JavaBodyStepFilter_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -JavaBodyStepFilter_Part_Title=Base -OnlyReferenceTypeFilterPropertiesEditionPart_ReferencedFeatureLabel=ReferencedFeature : -OCLFilterPropertiesEditionPart_OCLExpressionBodyLabel=OCLExpressionBody : -JavaExpressionFilterPropertiesEditionPart_JavaExpressionBodyLabel=JavaExpressionBody : -JavaDeclarationFilterPropertiesEditionPart_MethodNameLabel=MethodName : -StrictTypingFilterPropertiesEditionPart_RestrictionLabel=Restriction : -JavaDeclarationStepFilterPropertiesEditionPart_QualifiedClassLabel=QualifiedClass : -JavaDeclarationStepFilterPropertiesEditionPart_MethodFilterLabel=MethodFilter : -JavaDeclarationStepFilterPropertiesEditionPart_StaticMethodLabel=StaticMethod -JavaBodyStepFilterPropertiesEditionPart_BodyLabel=Body : -PropertiesEditionPart_PropertiesGroupLabel=Propri\u00E9t\u00E9s -PropertiesEditionPart_EditTableViewerLabel=Editer -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=La propri\u00E9t\u00E9 {0} de l\u0027objet doit \u00EAtre renseign\u00E9e -PropertiesEditionPart_RemoveTableViewerLabel=Supprimer -PropertiesEditionPart_RemoveListViewerLabel=Supprimer -PropertiesEditionPart_IntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un entier -PropertiesEditionPart_FloatValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un flottant -PropertiesEditionPart_ShortValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un short -PropertiesEditionPart_DoubleValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un double -PropertiesEditionPart_ByteValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un byte -PropertiesEditionPart_LongValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un long -PropertiesEditionPart_BigIntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigInteger -PropertiesEditionPart_BigDecimalValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Ajouter -PropertiesEditionPart_AddListViewerLabel=Ajouter diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/DeclarativeNavigationStepPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/DeclarativeNavigationStepPropertiesEditionPart.java deleted file mode 100644 index fcff61ff9..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/DeclarativeNavigationStepPropertiesEditionPart.java +++ /dev/null @@ -1,154 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; - -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; - -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface DeclarativeNavigationStepPropertiesEditionPart { - - /** - * @return the index - * - */ - public String getIndex(); - - /** - * Defines a new index - * @param newValue the new index to set - * - */ - public void setIndex(String newValue); - - - /** - * @return the feature - * - */ - public EObject getFeature(); - - /** - * Init the feature - * @param settings the combo setting - */ - public void initFeature(EObjectFlatComboSettings settings); - - /** - * Defines a new feature - * @param newValue the new feature to set - * - */ - public void setFeature(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setFeatureButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the feature edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToFeature(ViewerFilter filter); - - /** - * Adds the given filter to the feature edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToFeature(ViewerFilter filter); - - - /** - * @return the discriminatorType - * - */ - public EObject getDiscriminatorType(); - - /** - * Init the discriminatorType - * @param settings the combo setting - */ - public void initDiscriminatorType(EObjectFlatComboSettings settings); - - /** - * Defines a new discriminatorType - * @param newValue the new discriminatorType to set - * - */ - public void setDiscriminatorType(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setDiscriminatorTypeButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the discriminatorType edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToDiscriminatorType(ViewerFilter filter); - - /** - * Adds the given filter to the discriminatorType edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToDiscriminatorType(ViewerFilter filter); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/JavaBodyStepInitializerPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/JavaBodyStepInitializerPropertiesEditionPart.java deleted file mode 100644 index 89d4f87a3..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/JavaBodyStepInitializerPropertiesEditionPart.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts; - -// Start of user code for imports - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface JavaBodyStepInitializerPropertiesEditionPart { - - /** - * @return the body - * - */ - public String getBody(); - - /** - * Defines a new body - * @param newValue the new body to set - * - */ - public void setBody(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/JavaDeclarationStepInitializerPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/JavaDeclarationStepInitializerPropertiesEditionPart.java deleted file mode 100644 index 74dee96e8..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/JavaDeclarationStepInitializerPropertiesEditionPart.java +++ /dev/null @@ -1,82 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts; - -// Start of user code for imports - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface JavaDeclarationStepInitializerPropertiesEditionPart { - - /** - * @return the qualifiedClass - * - */ - public String getQualifiedClass(); - - /** - * Defines a new qualifiedClass - * @param newValue the new qualifiedClass to set - * - */ - public void setQualifiedClass(String newValue); - - - /** - * @return the methodFilter - * - */ - public String getMethodFilter(); - - /** - * Defines a new methodFilter - * @param newValue the new methodFilter to set - * - */ - public void setMethodFilter(String newValue); - - - /** - * @return the staticMethod - * - */ - public Boolean getStaticMethod(); - - /** - * Defines a new staticMethod - * @param newValue the new staticMethod to set - * - */ - public void setStaticMethod(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/ModelNavigationPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/ModelNavigationPropertiesEditionPart.java deleted file mode 100644 index d5bae735e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/ModelNavigationPropertiesEditionPart.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts; - -// Start of user code for imports - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface ModelNavigationPropertiesEditionPart { - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/NavigationViewsRepository.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/NavigationViewsRepository.java deleted file mode 100644 index ea843b080..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/NavigationViewsRepository.java +++ /dev/null @@ -1,114 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts; - -/** - * @author Nathalie Lepine - * - */ -public class NavigationViewsRepository { - - public static final int SWT_KIND = 0; - - public static final int FORM_KIND = 1; - - - /** - * ModelNavigation view descriptor - * - */ - public static class ModelNavigation { - public static class Properties { - - - } - - } - - /** - * SimpleModelNavigation view descriptor - * - */ - public static class SimpleModelNavigation { - public static class Properties { - - - public static String index = "navigation::SimpleModelNavigation::Properties::index"; - - - public static String feature = "navigation::SimpleModelNavigation::Properties::feature"; - - - public static String discriminatorType = "navigation::SimpleModelNavigation::Properties::discriminatorType"; - - - } - - } - - /** - * DeclarativeNavigationStep view descriptor - * - */ - public static class DeclarativeNavigationStep { - public static class Properties { - - - public static String index = "navigation::DeclarativeNavigationStep::Properties::index"; - - - public static String feature = "navigation::DeclarativeNavigationStep::Properties::feature"; - - - public static String discriminatorType = "navigation::DeclarativeNavigationStep::Properties::discriminatorType"; - - - } - - } - - /** - * JavaDeclarationStepInitializer view descriptor - * - */ - public static class JavaDeclarationStepInitializer { - public static class Properties { - - - public static String qualifiedClass = "navigation::JavaDeclarationStepInitializer::Properties::qualifiedClass"; - - - public static String methodFilter = "navigation::JavaDeclarationStepInitializer::Properties::methodFilter"; - - - public static String staticMethod = "navigation::JavaDeclarationStepInitializer::Properties::staticMethod"; - - - } - - } - - /** - * JavaBodyStepInitializer view descriptor - * - */ - public static class JavaBodyStepInitializer { - public static class Properties { - - - public static String body = "navigation::JavaBodyStepInitializer::Properties::body"; - - - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/SimpleModelNavigationPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/SimpleModelNavigationPropertiesEditionPart.java deleted file mode 100644 index 2e9f16a04..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/SimpleModelNavigationPropertiesEditionPart.java +++ /dev/null @@ -1,152 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface SimpleModelNavigationPropertiesEditionPart { - - /** - * @return the index - * - */ - public String getIndex(); - - /** - * Defines a new index - * @param newValue the new index to set - * - */ - public void setIndex(String newValue); - - - /** - * @return the feature - * - */ - public EObject getFeature(); - - /** - * Init the feature - * @param settings the combo setting - */ - public void initFeature(EObjectFlatComboSettings settings); - - /** - * Defines a new feature - * @param newValue the new feature to set - * - */ - public void setFeature(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setFeatureButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the feature edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToFeature(ViewerFilter filter); - - /** - * Adds the given filter to the feature edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToFeature(ViewerFilter filter); - - - /** - * @return the discriminatorType - * - */ - public EObject getDiscriminatorType(); - - /** - * Init the discriminatorType - * @param settings the combo setting - */ - public void initDiscriminatorType(EObjectFlatComboSettings settings); - - /** - * Defines a new discriminatorType - * @param newValue the new discriminatorType to set - * - */ - public void setDiscriminatorType(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setDiscriminatorTypeButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the discriminatorType edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToDiscriminatorType(ViewerFilter filter); - - /** - * Adds the given filter to the discriminatorType edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToDiscriminatorType(ViewerFilter filter); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/DeclarativeNavigationStepPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/DeclarativeNavigationStepPropertiesEditionPartForm.java deleted file mode 100644 index e6c871df4..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/DeclarativeNavigationStepPropertiesEditionPartForm.java +++ /dev/null @@ -1,534 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class DeclarativeNavigationStepPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, DeclarativeNavigationStepPropertiesEditionPart { - - protected Text index; - protected EObjectFlatComboViewer feature; - protected EObjectFlatComboViewer discriminatorType; - - - - /** - * For {@link ISection} use only. - */ - public DeclarativeNavigationStepPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public DeclarativeNavigationStepPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence declarativeNavigationStepStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = declarativeNavigationStepStep.addStep(NavigationViewsRepository.DeclarativeNavigationStep.Properties.class); - propertiesStep.addStep(NavigationViewsRepository.DeclarativeNavigationStep.Properties.index); - propertiesStep.addStep(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature); - propertiesStep.addStep(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType); - - - composer = new PartComposer(declarativeNavigationStepStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == NavigationViewsRepository.DeclarativeNavigationStep.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == NavigationViewsRepository.DeclarativeNavigationStep.Properties.index) { - return createIndexText(widgetFactory, parent); - } - if (key == NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature) { - return createFeatureFlatComboViewer(parent, widgetFactory); - } - if (key == NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType) { - return createDiscriminatorTypeFlatComboViewer(parent, widgetFactory); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(NavigationMessages.DeclarativeNavigationStepPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createIndexText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, NavigationViewsRepository.DeclarativeNavigationStep.Properties.index, NavigationMessages.DeclarativeNavigationStepPropertiesEditionPart_IndexLabel); - index = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - index.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData indexData = new GridData(GridData.FILL_HORIZONTAL); - index.setLayoutData(indexData); - index.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - DeclarativeNavigationStepPropertiesEditionPartForm.this, - NavigationViewsRepository.DeclarativeNavigationStep.Properties.index, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, index.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - DeclarativeNavigationStepPropertiesEditionPartForm.this, - NavigationViewsRepository.DeclarativeNavigationStep.Properties.index, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, index.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - DeclarativeNavigationStepPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - index.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DeclarativeNavigationStepPropertiesEditionPartForm.this, NavigationViewsRepository.DeclarativeNavigationStep.Properties.index, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, index.getText())); - } - } - }); - EditingUtils.setID(index, NavigationViewsRepository.DeclarativeNavigationStep.Properties.index); - EditingUtils.setEEFtype(index, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.DeclarativeNavigationStep.Properties.index, NavigationViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createIndexText - - // End of user code - return parent; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createFeatureFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature, NavigationMessages.DeclarativeNavigationStepPropertiesEditionPart_FeatureLabel); - feature = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature, NavigationViewsRepository.FORM_KIND)); - widgetFactory.adapt(feature); - feature.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData featureData = new GridData(GridData.FILL_HORIZONTAL); - feature.setLayoutData(featureData); - feature.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DeclarativeNavigationStepPropertiesEditionPartForm.this, NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getFeature())); - } - - }); - feature.setID(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature, NavigationViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createFeatureFlatComboViewer - - // End of user code - return parent; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createDiscriminatorTypeFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType, NavigationMessages.DeclarativeNavigationStepPropertiesEditionPart_DiscriminatorTypeLabel); - discriminatorType = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType, NavigationViewsRepository.FORM_KIND)); - widgetFactory.adapt(discriminatorType); - discriminatorType.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData discriminatorTypeData = new GridData(GridData.FILL_HORIZONTAL); - discriminatorType.setLayoutData(discriminatorTypeData); - discriminatorType.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DeclarativeNavigationStepPropertiesEditionPartForm.this, NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getDiscriminatorType())); - } - - }); - discriminatorType.setID(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType, NavigationViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createDiscriminatorTypeFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#getIndex() - * - */ - public String getIndex() { - return index.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#setIndex(String newValue) - * - */ - public void setIndex(String newValue) { - if (newValue != null) { - index.setText(newValue); - } else { - index.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.DeclarativeNavigationStep.Properties.index); - if (eefElementEditorReadOnlyState && index.isEnabled()) { - index.setEnabled(false); - index.setToolTipText(NavigationMessages.DeclarativeNavigationStep_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !index.isEnabled()) { - index.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#getFeature() - * - */ - public EObject getFeature() { - if (feature.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) feature.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#initFeature(EObjectFlatComboSettings) - */ - public void initFeature(EObjectFlatComboSettings settings) { - feature.setInput(settings); - if (current != null) { - feature.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature); - if (eefElementEditorReadOnlyState && feature.isEnabled()) { - feature.setEnabled(false); - feature.setToolTipText(NavigationMessages.DeclarativeNavigationStep_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !feature.isEnabled()) { - feature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#setFeature(EObject newValue) - * - */ - public void setFeature(EObject newValue) { - if (newValue != null) { - feature.setSelection(new StructuredSelection(newValue)); - } else { - feature.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature); - if (eefElementEditorReadOnlyState && feature.isEnabled()) { - feature.setEnabled(false); - feature.setToolTipText(NavigationMessages.DeclarativeNavigationStep_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !feature.isEnabled()) { - feature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#setFeatureButtonMode(ButtonsModeEnum newValue) - */ - public void setFeatureButtonMode(ButtonsModeEnum newValue) { - feature.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#addFilterFeature(ViewerFilter filter) - * - */ - public void addFilterToFeature(ViewerFilter filter) { - feature.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#addBusinessFilterFeature(ViewerFilter filter) - * - */ - public void addBusinessFilterToFeature(ViewerFilter filter) { - feature.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#getDiscriminatorType() - * - */ - public EObject getDiscriminatorType() { - if (discriminatorType.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) discriminatorType.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#initDiscriminatorType(EObjectFlatComboSettings) - */ - public void initDiscriminatorType(EObjectFlatComboSettings settings) { - discriminatorType.setInput(settings); - if (current != null) { - discriminatorType.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType); - if (eefElementEditorReadOnlyState && discriminatorType.isEnabled()) { - discriminatorType.setEnabled(false); - discriminatorType.setToolTipText(NavigationMessages.DeclarativeNavigationStep_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !discriminatorType.isEnabled()) { - discriminatorType.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#setDiscriminatorType(EObject newValue) - * - */ - public void setDiscriminatorType(EObject newValue) { - if (newValue != null) { - discriminatorType.setSelection(new StructuredSelection(newValue)); - } else { - discriminatorType.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType); - if (eefElementEditorReadOnlyState && discriminatorType.isEnabled()) { - discriminatorType.setEnabled(false); - discriminatorType.setToolTipText(NavigationMessages.DeclarativeNavigationStep_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !discriminatorType.isEnabled()) { - discriminatorType.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#setDiscriminatorTypeButtonMode(ButtonsModeEnum newValue) - */ - public void setDiscriminatorTypeButtonMode(ButtonsModeEnum newValue) { - discriminatorType.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#addFilterDiscriminatorType(ViewerFilter filter) - * - */ - public void addFilterToDiscriminatorType(ViewerFilter filter) { - discriminatorType.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#addBusinessFilterDiscriminatorType(ViewerFilter filter) - * - */ - public void addBusinessFilterToDiscriminatorType(ViewerFilter filter) { - discriminatorType.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return NavigationMessages.DeclarativeNavigationStep_Part_Title; - } - - // Start of user code additional methods - public void setDiscriminatorInput(DeclarativeNavigationStep declarativeNavigationStep, ResourceSet allResources){ - discriminatorType.setInput(EEFUtils.choiceOfValues(adapterFactory, declarativeNavigationStep, NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_DiscriminatorType())); - if (declarativeNavigationStep.getDiscriminatorType() != null){ - discriminatorType.setSelection(new StructuredSelection(declarativeNavigationStep.getDiscriminatorType())); - } - } - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/JavaBodyStepInitializerPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/JavaBodyStepInitializerPropertiesEditionPartForm.java deleted file mode 100644 index 24782b91d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/JavaBodyStepInitializerPropertiesEditionPartForm.java +++ /dev/null @@ -1,270 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.navigation.parts.JavaBodyStepInitializerPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; - -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; - -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaBodyStepInitializerPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, JavaBodyStepInitializerPropertiesEditionPart { - - protected Text body; - - - - /** - * For {@link ISection} use only. - */ - public JavaBodyStepInitializerPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaBodyStepInitializerPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence javaBodyStepInitializerStep = new BindingCompositionSequence(propertiesEditionComponent); - javaBodyStepInitializerStep - .addStep(NavigationViewsRepository.JavaBodyStepInitializer.Properties.class) - .addStep(NavigationViewsRepository.JavaBodyStepInitializer.Properties.body); - - - composer = new PartComposer(javaBodyStepInitializerStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == NavigationViewsRepository.JavaBodyStepInitializer.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == NavigationViewsRepository.JavaBodyStepInitializer.Properties.body) { - return createBodyTextarea(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(NavigationMessages.JavaBodyStepInitializerPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createBodyTextarea(FormToolkit widgetFactory, Composite parent) { - Label bodyLabel = createDescription(parent, NavigationViewsRepository.JavaBodyStepInitializer.Properties.body, NavigationMessages.JavaBodyStepInitializerPropertiesEditionPart_BodyLabel); - GridData bodyLabelData = new GridData(GridData.FILL_HORIZONTAL); - bodyLabelData.horizontalSpan = 3; - bodyLabel.setLayoutData(bodyLabelData); - body = widgetFactory.createText(parent, "", SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); //$NON-NLS-1$ - GridData bodyData = new GridData(GridData.FILL_HORIZONTAL); - bodyData.horizontalSpan = 2; - bodyData.heightHint = 80; - bodyData.widthHint = 200; - body.setLayoutData(bodyData); - body.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - JavaBodyStepInitializerPropertiesEditionPartForm.this, - NavigationViewsRepository.JavaBodyStepInitializer.Properties.body, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, body.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaBodyStepInitializerPropertiesEditionPartForm.this, - NavigationViewsRepository.JavaBodyStepInitializer.Properties.body, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, body.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaBodyStepInitializerPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - EditingUtils.setID(body, NavigationViewsRepository.JavaBodyStepInitializer.Properties.body); - EditingUtils.setEEFtype(body, "eef::Textarea"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.JavaBodyStepInitializer.Properties.body, NavigationViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createBodyTextArea - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaBodyStepInitializerPropertiesEditionPart#getBody() - * - */ - public String getBody() { - return body.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaBodyStepInitializerPropertiesEditionPart#setBody(String newValue) - * - */ - public void setBody(String newValue) { - if (newValue != null) { - body.setText(newValue); - } else { - body.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.JavaBodyStepInitializer.Properties.body); - if (eefElementEditorReadOnlyState && body.isEnabled()) { - body.setEnabled(false); - body.setBackground(body.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - body.setToolTipText(NavigationMessages.JavaBodyStepInitializer_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !body.isEnabled()) { - body.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return NavigationMessages.JavaBodyStepInitializer_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/JavaDeclarationStepInitializerPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/JavaDeclarationStepInitializerPropertiesEditionPartForm.java deleted file mode 100644 index cdccc6bb6..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/JavaDeclarationStepInitializerPropertiesEditionPartForm.java +++ /dev/null @@ -1,453 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; - -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; - -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationStepInitializerPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, JavaDeclarationStepInitializerPropertiesEditionPart { - - protected Text qualifiedClass; - protected Text methodFilter; - protected Button staticMethod; - - - - /** - * For {@link ISection} use only. - */ - public JavaDeclarationStepInitializerPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaDeclarationStepInitializerPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence javaDeclarationStepInitializerStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = javaDeclarationStepInitializerStep.addStep(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.class); - propertiesStep.addStep(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass); - propertiesStep.addStep(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter); - propertiesStep.addStep(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod); - - - composer = new PartComposer(javaDeclarationStepInitializerStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass) { - return createQualifiedClassText(widgetFactory, parent); - } - if (key == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter) { - return createMethodFilterText(widgetFactory, parent); - } - if (key == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod) { - return createStaticMethodCheckbox(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(NavigationMessages.JavaDeclarationStepInitializerPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createQualifiedClassText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass, NavigationMessages.JavaDeclarationStepInitializerPropertiesEditionPart_QualifiedClassLabel); - qualifiedClass = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - qualifiedClass.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData qualifiedClassData = new GridData(GridData.FILL_HORIZONTAL); - qualifiedClass.setLayoutData(qualifiedClassData); - qualifiedClass.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepInitializerPropertiesEditionPartForm.this, - NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, qualifiedClass.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepInitializerPropertiesEditionPartForm.this, - NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, qualifiedClass.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepInitializerPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - qualifiedClass.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepInitializerPropertiesEditionPartForm.this, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, qualifiedClass.getText())); - } - } - }); - EditingUtils.setID(qualifiedClass, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass); - EditingUtils.setEEFtype(qualifiedClass, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass, NavigationViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createQualifiedClassText - - // End of user code - return parent; - } - - - protected Composite createMethodFilterText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter, NavigationMessages.JavaDeclarationStepInitializerPropertiesEditionPart_MethodFilterLabel); - methodFilter = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - methodFilter.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData methodFilterData = new GridData(GridData.FILL_HORIZONTAL); - methodFilter.setLayoutData(methodFilterData); - methodFilter.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepInitializerPropertiesEditionPartForm.this, - NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodFilter.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepInitializerPropertiesEditionPartForm.this, - NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, methodFilter.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - JavaDeclarationStepInitializerPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - methodFilter.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepInitializerPropertiesEditionPartForm.this, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodFilter.getText())); - } - } - }); - EditingUtils.setID(methodFilter, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter); - EditingUtils.setEEFtype(methodFilter, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter, NavigationViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createMethodFilterText - - // End of user code - return parent; - } - - - protected Composite createStaticMethodCheckbox(FormToolkit widgetFactory, Composite parent) { - staticMethod = widgetFactory.createButton(parent, getDescription(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod, NavigationMessages.JavaDeclarationStepInitializerPropertiesEditionPart_StaticMethodLabel), SWT.CHECK); - staticMethod.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepInitializerPropertiesEditionPartForm.this, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(staticMethod.getSelection()))); - } - - }); - GridData staticMethodData = new GridData(GridData.FILL_HORIZONTAL); - staticMethodData.horizontalSpan = 2; - staticMethod.setLayoutData(staticMethodData); - EditingUtils.setID(staticMethod, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod); - EditingUtils.setEEFtype(staticMethod, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod, NavigationViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createStaticMethodCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#getQualifiedClass() - * - */ - public String getQualifiedClass() { - return qualifiedClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#setQualifiedClass(String newValue) - * - */ - public void setQualifiedClass(String newValue) { - if (newValue != null) { - qualifiedClass.setText(newValue); - } else { - qualifiedClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass); - if (eefElementEditorReadOnlyState && qualifiedClass.isEnabled()) { - qualifiedClass.setEnabled(false); - qualifiedClass.setToolTipText(NavigationMessages.JavaDeclarationStepInitializer_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !qualifiedClass.isEnabled()) { - qualifiedClass.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#getMethodFilter() - * - */ - public String getMethodFilter() { - return methodFilter.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#setMethodFilter(String newValue) - * - */ - public void setMethodFilter(String newValue) { - if (newValue != null) { - methodFilter.setText(newValue); - } else { - methodFilter.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter); - if (eefElementEditorReadOnlyState && methodFilter.isEnabled()) { - methodFilter.setEnabled(false); - methodFilter.setToolTipText(NavigationMessages.JavaDeclarationStepInitializer_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !methodFilter.isEnabled()) { - methodFilter.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#getStaticMethod() - * - */ - public Boolean getStaticMethod() { - return Boolean.valueOf(staticMethod.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#setStaticMethod(Boolean newValue) - * - */ - public void setStaticMethod(Boolean newValue) { - if (newValue != null) { - staticMethod.setSelection(newValue.booleanValue()); - } else { - staticMethod.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod); - if (eefElementEditorReadOnlyState && staticMethod.isEnabled()) { - staticMethod.setEnabled(false); - staticMethod.setToolTipText(NavigationMessages.JavaDeclarationStepInitializer_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !staticMethod.isEnabled()) { - staticMethod.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return NavigationMessages.JavaDeclarationStepInitializer_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/ModelNavigationPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/ModelNavigationPropertiesEditionPartForm.java deleted file mode 100644 index 5eb6b8d7b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/ModelNavigationPropertiesEditionPartForm.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.navigation.parts.ModelNavigationPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class ModelNavigationPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, ModelNavigationPropertiesEditionPart { - - - - - /** - * For {@link ISection} use only. - */ - public ModelNavigationPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public ModelNavigationPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence modelNavigationStep = new BindingCompositionSequence(propertiesEditionComponent); - modelNavigationStep - .addStep(NavigationViewsRepository.ModelNavigation.Properties.class); - - composer = new PartComposer(modelNavigationStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == NavigationViewsRepository.ModelNavigation.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(NavigationMessages.ModelNavigationPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return NavigationMessages.ModelNavigation_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/SimpleModelNavigationPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/SimpleModelNavigationPropertiesEditionPartForm.java deleted file mode 100644 index a5c32419d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/forms/SimpleModelNavigationPropertiesEditionPartForm.java +++ /dev/null @@ -1,532 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.parts.SimpleModelNavigationPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class SimpleModelNavigationPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, SimpleModelNavigationPropertiesEditionPart { - - protected Text index; - protected EObjectFlatComboViewer feature; - protected EObjectFlatComboViewer discriminatorType; - - - - /** - * For {@link ISection} use only. - */ - public SimpleModelNavigationPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public SimpleModelNavigationPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence simpleModelNavigationStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = simpleModelNavigationStep.addStep(NavigationViewsRepository.SimpleModelNavigation.Properties.class); - propertiesStep.addStep(NavigationViewsRepository.SimpleModelNavigation.Properties.index); - propertiesStep.addStep(NavigationViewsRepository.SimpleModelNavigation.Properties.feature); - propertiesStep.addStep(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType); - - - composer = new PartComposer(simpleModelNavigationStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == NavigationViewsRepository.SimpleModelNavigation.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == NavigationViewsRepository.SimpleModelNavigation.Properties.index) { - return createIndexText(widgetFactory, parent); - } - if (key == NavigationViewsRepository.SimpleModelNavigation.Properties.feature) { - return createFeatureFlatComboViewer(parent, widgetFactory); - } - if (key == NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType) { - return createDiscriminatorTypeFlatComboViewer(parent, widgetFactory); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(NavigationMessages.SimpleModelNavigationPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createIndexText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, NavigationViewsRepository.SimpleModelNavigation.Properties.index, NavigationMessages.SimpleModelNavigationPropertiesEditionPart_IndexLabel); - index = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - index.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData indexData = new GridData(GridData.FILL_HORIZONTAL); - index.setLayoutData(indexData); - index.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - SimpleModelNavigationPropertiesEditionPartForm.this, - NavigationViewsRepository.SimpleModelNavigation.Properties.index, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, index.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - SimpleModelNavigationPropertiesEditionPartForm.this, - NavigationViewsRepository.SimpleModelNavigation.Properties.index, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, index.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - SimpleModelNavigationPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - index.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(SimpleModelNavigationPropertiesEditionPartForm.this, NavigationViewsRepository.SimpleModelNavigation.Properties.index, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, index.getText())); - } - } - }); - EditingUtils.setID(index, NavigationViewsRepository.SimpleModelNavigation.Properties.index); - EditingUtils.setEEFtype(index, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.SimpleModelNavigation.Properties.index, NavigationViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createIndexText - - // End of user code - return parent; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createFeatureFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, NavigationViewsRepository.SimpleModelNavigation.Properties.feature, NavigationMessages.SimpleModelNavigationPropertiesEditionPart_FeatureLabel); - feature = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(NavigationViewsRepository.SimpleModelNavigation.Properties.feature, NavigationViewsRepository.FORM_KIND)); - widgetFactory.adapt(feature); - feature.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData featureData = new GridData(GridData.FILL_HORIZONTAL); - feature.setLayoutData(featureData); - feature.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(SimpleModelNavigationPropertiesEditionPartForm.this, NavigationViewsRepository.SimpleModelNavigation.Properties.feature, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getFeature())); - } - - }); - feature.setID(NavigationViewsRepository.SimpleModelNavigation.Properties.feature); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.SimpleModelNavigation.Properties.feature, NavigationViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createFeatureFlatComboViewer - - // End of user code - return parent; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createDiscriminatorTypeFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType, NavigationMessages.SimpleModelNavigationPropertiesEditionPart_DiscriminatorTypeLabel); - discriminatorType = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType, NavigationViewsRepository.FORM_KIND)); - widgetFactory.adapt(discriminatorType); - discriminatorType.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData discriminatorTypeData = new GridData(GridData.FILL_HORIZONTAL); - discriminatorType.setLayoutData(discriminatorTypeData); - discriminatorType.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(SimpleModelNavigationPropertiesEditionPartForm.this, NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getDiscriminatorType())); - } - - }); - discriminatorType.setID(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType, NavigationViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createDiscriminatorTypeFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#getIndex() - * - */ - public String getIndex() { - return index.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#setIndex(String newValue) - * - */ - public void setIndex(String newValue) { - if (newValue != null) { - index.setText(newValue); - } else { - index.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.SimpleModelNavigation.Properties.index); - if (eefElementEditorReadOnlyState && index.isEnabled()) { - index.setEnabled(false); - index.setToolTipText(NavigationMessages.SimpleModelNavigation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !index.isEnabled()) { - index.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#getFeature() - * - */ - public EObject getFeature() { - if (feature.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) feature.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#initFeature(EObjectFlatComboSettings) - */ - public void initFeature(EObjectFlatComboSettings settings) { - feature.setInput(settings); - if (current != null) { - feature.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.SimpleModelNavigation.Properties.feature); - if (eefElementEditorReadOnlyState && feature.isEnabled()) { - feature.setEnabled(false); - feature.setToolTipText(NavigationMessages.SimpleModelNavigation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !feature.isEnabled()) { - feature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#setFeature(EObject newValue) - * - */ - public void setFeature(EObject newValue) { - if (newValue != null) { - feature.setSelection(new StructuredSelection(newValue)); - } else { - feature.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.SimpleModelNavigation.Properties.feature); - if (eefElementEditorReadOnlyState && feature.isEnabled()) { - feature.setEnabled(false); - feature.setToolTipText(NavigationMessages.SimpleModelNavigation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !feature.isEnabled()) { - feature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#setFeatureButtonMode(ButtonsModeEnum newValue) - */ - public void setFeatureButtonMode(ButtonsModeEnum newValue) { - feature.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#addFilterFeature(ViewerFilter filter) - * - */ - public void addFilterToFeature(ViewerFilter filter) { - feature.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#addBusinessFilterFeature(ViewerFilter filter) - * - */ - public void addBusinessFilterToFeature(ViewerFilter filter) { - feature.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#getDiscriminatorType() - * - */ - public EObject getDiscriminatorType() { - if (discriminatorType.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) discriminatorType.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#initDiscriminatorType(EObjectFlatComboSettings) - */ - public void initDiscriminatorType(EObjectFlatComboSettings settings) { - discriminatorType.setInput(settings); - if (current != null) { - discriminatorType.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType); - if (eefElementEditorReadOnlyState && discriminatorType.isEnabled()) { - discriminatorType.setEnabled(false); - discriminatorType.setToolTipText(NavigationMessages.SimpleModelNavigation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !discriminatorType.isEnabled()) { - discriminatorType.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#setDiscriminatorType(EObject newValue) - * - */ - public void setDiscriminatorType(EObject newValue) { - if (newValue != null) { - discriminatorType.setSelection(new StructuredSelection(newValue)); - } else { - discriminatorType.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType); - if (eefElementEditorReadOnlyState && discriminatorType.isEnabled()) { - discriminatorType.setEnabled(false); - discriminatorType.setToolTipText(NavigationMessages.SimpleModelNavigation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !discriminatorType.isEnabled()) { - discriminatorType.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#setDiscriminatorTypeButtonMode(ButtonsModeEnum newValue) - */ - public void setDiscriminatorTypeButtonMode(ButtonsModeEnum newValue) { - discriminatorType.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#addFilterDiscriminatorType(ViewerFilter filter) - * - */ - public void addFilterToDiscriminatorType(ViewerFilter filter) { - discriminatorType.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#addBusinessFilterDiscriminatorType(ViewerFilter filter) - * - */ - public void addBusinessFilterToDiscriminatorType(ViewerFilter filter) { - discriminatorType.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return NavigationMessages.SimpleModelNavigation_Part_Title; - } - - // Start of user code additional methods - public void setDiscriminatorInput(SimpleModelNavigation simpleModelNavigation, ResourceSet allResources){ - discriminatorType.setInput(EEFUtils.choiceOfValues(adapterFactory, simpleModelNavigation, NavigationPackage.eINSTANCE.getSimpleModelNavigation_DiscriminatorType())); - if (simpleModelNavigation.getDiscriminatorType() != null){ - discriminatorType.setSelection(new StructuredSelection(simpleModelNavigation.getDiscriminatorType())); - } - } - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/DeclarativeNavigationStepPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/DeclarativeNavigationStepPropertiesEditionPartImpl.java deleted file mode 100644 index ee8c72d13..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/DeclarativeNavigationStepPropertiesEditionPartImpl.java +++ /dev/null @@ -1,508 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; - -import org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; - -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; - -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class DeclarativeNavigationStepPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, DeclarativeNavigationStepPropertiesEditionPart { - - protected Text index; - protected EObjectFlatComboViewer feature; - protected EObjectFlatComboViewer discriminatorType; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public DeclarativeNavigationStepPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence declarativeNavigationStepStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = declarativeNavigationStepStep.addStep(NavigationViewsRepository.DeclarativeNavigationStep.Properties.class); - propertiesStep.addStep(NavigationViewsRepository.DeclarativeNavigationStep.Properties.index); - propertiesStep.addStep(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature); - propertiesStep.addStep(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType); - - - composer = new PartComposer(declarativeNavigationStepStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == NavigationViewsRepository.DeclarativeNavigationStep.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == NavigationViewsRepository.DeclarativeNavigationStep.Properties.index) { - return createIndexText(parent); - } - if (key == NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature) { - return createFeatureFlatComboViewer(parent); - } - if (key == NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType) { - return createDiscriminatorTypeFlatComboViewer(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(NavigationMessages.DeclarativeNavigationStepPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createIndexText(Composite parent) { - createDescription(parent, NavigationViewsRepository.DeclarativeNavigationStep.Properties.index, NavigationMessages.DeclarativeNavigationStepPropertiesEditionPart_IndexLabel); - index = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData indexData = new GridData(GridData.FILL_HORIZONTAL); - index.setLayoutData(indexData); - index.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DeclarativeNavigationStepPropertiesEditionPartImpl.this, NavigationViewsRepository.DeclarativeNavigationStep.Properties.index, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, index.getText())); - } - - }); - index.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DeclarativeNavigationStepPropertiesEditionPartImpl.this, NavigationViewsRepository.DeclarativeNavigationStep.Properties.index, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, index.getText())); - } - } - - }); - EditingUtils.setID(index, NavigationViewsRepository.DeclarativeNavigationStep.Properties.index); - EditingUtils.setEEFtype(index, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.DeclarativeNavigationStep.Properties.index, NavigationViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createIndexText - - // End of user code - return parent; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createFeatureFlatComboViewer(Composite parent) { - createDescription(parent, NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature, NavigationMessages.DeclarativeNavigationStepPropertiesEditionPart_FeatureLabel); - feature = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature, NavigationViewsRepository.SWT_KIND)); - feature.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - feature.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DeclarativeNavigationStepPropertiesEditionPartImpl.this, NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getFeature())); - } - - }); - GridData featureData = new GridData(GridData.FILL_HORIZONTAL); - feature.setLayoutData(featureData); - feature.setID(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature, NavigationViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createFeatureFlatComboViewer - - // End of user code - return parent; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createDiscriminatorTypeFlatComboViewer(Composite parent) { - createDescription(parent, NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType, NavigationMessages.DeclarativeNavigationStepPropertiesEditionPart_DiscriminatorTypeLabel); - discriminatorType = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType, NavigationViewsRepository.SWT_KIND)); - discriminatorType.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - discriminatorType.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DeclarativeNavigationStepPropertiesEditionPartImpl.this, NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getDiscriminatorType())); - } - - }); - GridData discriminatorTypeData = new GridData(GridData.FILL_HORIZONTAL); - discriminatorType.setLayoutData(discriminatorTypeData); - discriminatorType.setID(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType, NavigationViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createDiscriminatorTypeFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#getIndex() - * - */ - public String getIndex() { - return index.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#setIndex(String newValue) - * - */ - public void setIndex(String newValue) { - if (newValue != null) { - index.setText(newValue); - } else { - index.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.DeclarativeNavigationStep.Properties.index); - if (eefElementEditorReadOnlyState && index.isEnabled()) { - index.setEnabled(false); - index.setToolTipText(NavigationMessages.DeclarativeNavigationStep_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !index.isEnabled()) { - index.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#getFeature() - * - */ - public EObject getFeature() { - if (feature.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) feature.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#initFeature(EObjectFlatComboSettings) - */ - public void initFeature(EObjectFlatComboSettings settings) { - feature.setInput(settings); - if (current != null) { - feature.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature); - if (eefElementEditorReadOnlyState && feature.isEnabled()) { - feature.setEnabled(false); - feature.setToolTipText(NavigationMessages.DeclarativeNavigationStep_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !feature.isEnabled()) { - feature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#setFeature(EObject newValue) - * - */ - public void setFeature(EObject newValue) { - if (newValue != null) { - feature.setSelection(new StructuredSelection(newValue)); - } else { - feature.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature); - if (eefElementEditorReadOnlyState && feature.isEnabled()) { - feature.setEnabled(false); - feature.setToolTipText(NavigationMessages.DeclarativeNavigationStep_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !feature.isEnabled()) { - feature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#setFeatureButtonMode(ButtonsModeEnum newValue) - */ - public void setFeatureButtonMode(ButtonsModeEnum newValue) { - feature.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#addFilterFeature(ViewerFilter filter) - * - */ - public void addFilterToFeature(ViewerFilter filter) { - feature.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#addBusinessFilterFeature(ViewerFilter filter) - * - */ - public void addBusinessFilterToFeature(ViewerFilter filter) { - feature.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#getDiscriminatorType() - * - */ - public EObject getDiscriminatorType() { - if (discriminatorType.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) discriminatorType.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#initDiscriminatorType(EObjectFlatComboSettings) - */ - public void initDiscriminatorType(EObjectFlatComboSettings settings) { - discriminatorType.setInput(settings); - if (current != null) { - discriminatorType.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType); - if (eefElementEditorReadOnlyState && discriminatorType.isEnabled()) { - discriminatorType.setEnabled(false); - discriminatorType.setToolTipText(NavigationMessages.DeclarativeNavigationStep_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !discriminatorType.isEnabled()) { - discriminatorType.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#setDiscriminatorType(EObject newValue) - * - */ - public void setDiscriminatorType(EObject newValue) { - if (newValue != null) { - discriminatorType.setSelection(new StructuredSelection(newValue)); - } else { - discriminatorType.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType); - if (eefElementEditorReadOnlyState && discriminatorType.isEnabled()) { - discriminatorType.setEnabled(false); - discriminatorType.setToolTipText(NavigationMessages.DeclarativeNavigationStep_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !discriminatorType.isEnabled()) { - discriminatorType.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#setDiscriminatorTypeButtonMode(ButtonsModeEnum newValue) - */ - public void setDiscriminatorTypeButtonMode(ButtonsModeEnum newValue) { - discriminatorType.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#addFilterDiscriminatorType(ViewerFilter filter) - * - */ - public void addFilterToDiscriminatorType(ViewerFilter filter) { - discriminatorType.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart#addBusinessFilterDiscriminatorType(ViewerFilter filter) - * - */ - public void addBusinessFilterToDiscriminatorType(ViewerFilter filter) { - discriminatorType.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return NavigationMessages.DeclarativeNavigationStep_Part_Title; - } - - // Start of user code additional methods - public void setDiscriminatorInput(DeclarativeNavigationStep declarativeNavigationStep, ResourceSet allResources){ - discriminatorType.setInput(EEFUtils.choiceOfValues(adapterFactory, declarativeNavigationStep, NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_DiscriminatorType())); - if (declarativeNavigationStep.getDiscriminatorType() != null){ - discriminatorType.setSelection(new StructuredSelection(declarativeNavigationStep.getDiscriminatorType())); - } - } - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/JavaBodyStepInitializerPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/JavaBodyStepInitializerPropertiesEditionPartImpl.java deleted file mode 100644 index 686ea89b9..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/JavaBodyStepInitializerPropertiesEditionPartImpl.java +++ /dev/null @@ -1,234 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.navigation.parts.JavaBodyStepInitializerPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; - -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaBodyStepInitializerPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, JavaBodyStepInitializerPropertiesEditionPart { - - protected Text body; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaBodyStepInitializerPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence javaBodyStepInitializerStep = new BindingCompositionSequence(propertiesEditionComponent); - javaBodyStepInitializerStep - .addStep(NavigationViewsRepository.JavaBodyStepInitializer.Properties.class) - .addStep(NavigationViewsRepository.JavaBodyStepInitializer.Properties.body); - - - composer = new PartComposer(javaBodyStepInitializerStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == NavigationViewsRepository.JavaBodyStepInitializer.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == NavigationViewsRepository.JavaBodyStepInitializer.Properties.body) { - return createBodyTextarea(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(NavigationMessages.JavaBodyStepInitializerPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createBodyTextarea(Composite parent) { - Label bodyLabel = createDescription(parent, NavigationViewsRepository.JavaBodyStepInitializer.Properties.body, NavigationMessages.JavaBodyStepInitializerPropertiesEditionPart_BodyLabel); - GridData bodyLabelData = new GridData(GridData.FILL_HORIZONTAL); - bodyLabelData.horizontalSpan = 3; - bodyLabel.setLayoutData(bodyLabelData); - body = SWTUtils.createScrollableText(parent, SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); - GridData bodyData = new GridData(GridData.FILL_HORIZONTAL); - bodyData.horizontalSpan = 2; - bodyData.heightHint = 80; - bodyData.widthHint = 200; - body.setLayoutData(bodyData); - body.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaBodyStepInitializerPropertiesEditionPartImpl.this, NavigationViewsRepository.JavaBodyStepInitializer.Properties.body, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, body.getText())); - } - - }); - EditingUtils.setID(body, NavigationViewsRepository.JavaBodyStepInitializer.Properties.body); - EditingUtils.setEEFtype(body, "eef::Textarea"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.JavaBodyStepInitializer.Properties.body, NavigationViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createBodyTextArea - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaBodyStepInitializerPropertiesEditionPart#getBody() - * - */ - public String getBody() { - return body.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaBodyStepInitializerPropertiesEditionPart#setBody(String newValue) - * - */ - public void setBody(String newValue) { - if (newValue != null) { - body.setText(newValue); - } else { - body.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.JavaBodyStepInitializer.Properties.body); - if (eefElementEditorReadOnlyState && body.isEnabled()) { - body.setEnabled(false); - body.setBackground(body.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - body.setToolTipText(NavigationMessages.JavaBodyStepInitializer_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !body.isEnabled()) { - body.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return NavigationMessages.JavaBodyStepInitializer_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/JavaDeclarationStepInitializerPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/JavaDeclarationStepInitializerPropertiesEditionPartImpl.java deleted file mode 100644 index 17936ec9b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/JavaDeclarationStepInitializerPropertiesEditionPartImpl.java +++ /dev/null @@ -1,404 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; - -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; - -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationStepInitializerPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, JavaDeclarationStepInitializerPropertiesEditionPart { - - protected Text qualifiedClass; - protected Text methodFilter; - protected Button staticMethod; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public JavaDeclarationStepInitializerPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence javaDeclarationStepInitializerStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = javaDeclarationStepInitializerStep.addStep(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.class); - propertiesStep.addStep(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass); - propertiesStep.addStep(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter); - propertiesStep.addStep(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod); - - - composer = new PartComposer(javaDeclarationStepInitializerStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass) { - return createQualifiedClassText(parent); - } - if (key == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter) { - return createMethodFilterText(parent); - } - if (key == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod) { - return createStaticMethodCheckbox(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(NavigationMessages.JavaDeclarationStepInitializerPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createQualifiedClassText(Composite parent) { - createDescription(parent, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass, NavigationMessages.JavaDeclarationStepInitializerPropertiesEditionPart_QualifiedClassLabel); - qualifiedClass = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData qualifiedClassData = new GridData(GridData.FILL_HORIZONTAL); - qualifiedClass.setLayoutData(qualifiedClassData); - qualifiedClass.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepInitializerPropertiesEditionPartImpl.this, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, qualifiedClass.getText())); - } - - }); - qualifiedClass.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepInitializerPropertiesEditionPartImpl.this, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, qualifiedClass.getText())); - } - } - - }); - EditingUtils.setID(qualifiedClass, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass); - EditingUtils.setEEFtype(qualifiedClass, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass, NavigationViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createQualifiedClassText - - // End of user code - return parent; - } - - - protected Composite createMethodFilterText(Composite parent) { - createDescription(parent, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter, NavigationMessages.JavaDeclarationStepInitializerPropertiesEditionPart_MethodFilterLabel); - methodFilter = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData methodFilterData = new GridData(GridData.FILL_HORIZONTAL); - methodFilter.setLayoutData(methodFilterData); - methodFilter.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepInitializerPropertiesEditionPartImpl.this, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodFilter.getText())); - } - - }); - methodFilter.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepInitializerPropertiesEditionPartImpl.this, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, methodFilter.getText())); - } - } - - }); - EditingUtils.setID(methodFilter, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter); - EditingUtils.setEEFtype(methodFilter, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter, NavigationViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createMethodFilterText - - // End of user code - return parent; - } - - - protected Composite createStaticMethodCheckbox(Composite parent) { - staticMethod = new Button(parent, SWT.CHECK); - staticMethod.setText(getDescription(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod, NavigationMessages.JavaDeclarationStepInitializerPropertiesEditionPart_StaticMethodLabel)); - staticMethod.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(JavaDeclarationStepInitializerPropertiesEditionPartImpl.this, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(staticMethod.getSelection()))); - } - - }); - GridData staticMethodData = new GridData(GridData.FILL_HORIZONTAL); - staticMethodData.horizontalSpan = 2; - staticMethod.setLayoutData(staticMethodData); - EditingUtils.setID(staticMethod, NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod); - EditingUtils.setEEFtype(staticMethod, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod, NavigationViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createStaticMethodCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#getQualifiedClass() - * - */ - public String getQualifiedClass() { - return qualifiedClass.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#setQualifiedClass(String newValue) - * - */ - public void setQualifiedClass(String newValue) { - if (newValue != null) { - qualifiedClass.setText(newValue); - } else { - qualifiedClass.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass); - if (eefElementEditorReadOnlyState && qualifiedClass.isEnabled()) { - qualifiedClass.setEnabled(false); - qualifiedClass.setToolTipText(NavigationMessages.JavaDeclarationStepInitializer_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !qualifiedClass.isEnabled()) { - qualifiedClass.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#getMethodFilter() - * - */ - public String getMethodFilter() { - return methodFilter.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#setMethodFilter(String newValue) - * - */ - public void setMethodFilter(String newValue) { - if (newValue != null) { - methodFilter.setText(newValue); - } else { - methodFilter.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter); - if (eefElementEditorReadOnlyState && methodFilter.isEnabled()) { - methodFilter.setEnabled(false); - methodFilter.setToolTipText(NavigationMessages.JavaDeclarationStepInitializer_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !methodFilter.isEnabled()) { - methodFilter.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#getStaticMethod() - * - */ - public Boolean getStaticMethod() { - return Boolean.valueOf(staticMethod.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart#setStaticMethod(Boolean newValue) - * - */ - public void setStaticMethod(Boolean newValue) { - if (newValue != null) { - staticMethod.setSelection(newValue.booleanValue()); - } else { - staticMethod.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod); - if (eefElementEditorReadOnlyState && staticMethod.isEnabled()) { - staticMethod.setEnabled(false); - staticMethod.setToolTipText(NavigationMessages.JavaDeclarationStepInitializer_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !staticMethod.isEnabled()) { - staticMethod.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return NavigationMessages.JavaDeclarationStepInitializer_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/ModelNavigationPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/ModelNavigationPropertiesEditionPartImpl.java deleted file mode 100644 index 825a294e6..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/ModelNavigationPropertiesEditionPartImpl.java +++ /dev/null @@ -1,140 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.navigation.parts.ModelNavigationPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class ModelNavigationPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, ModelNavigationPropertiesEditionPart { - - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public ModelNavigationPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence modelNavigationStep = new BindingCompositionSequence(propertiesEditionComponent); - modelNavigationStep - .addStep(NavigationViewsRepository.ModelNavigation.Properties.class); - - composer = new PartComposer(modelNavigationStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == NavigationViewsRepository.ModelNavigation.Properties.class) { - return createPropertiesGroup(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(NavigationMessages.ModelNavigationPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return NavigationMessages.ModelNavigation_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/SimpleModelNavigationPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/SimpleModelNavigationPropertiesEditionPartImpl.java deleted file mode 100644 index cba29a987..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/parts/impl/SimpleModelNavigationPropertiesEditionPartImpl.java +++ /dev/null @@ -1,487 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.parts.SimpleModelNavigationPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class SimpleModelNavigationPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, SimpleModelNavigationPropertiesEditionPart { - - protected Text index; - protected EObjectFlatComboViewer feature; - protected EObjectFlatComboViewer discriminatorType; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public SimpleModelNavigationPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence simpleModelNavigationStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep propertiesStep = simpleModelNavigationStep.addStep(NavigationViewsRepository.SimpleModelNavigation.Properties.class); - propertiesStep.addStep(NavigationViewsRepository.SimpleModelNavigation.Properties.index); - propertiesStep.addStep(NavigationViewsRepository.SimpleModelNavigation.Properties.feature); - propertiesStep.addStep(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType); - - - composer = new PartComposer(simpleModelNavigationStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == NavigationViewsRepository.SimpleModelNavigation.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == NavigationViewsRepository.SimpleModelNavigation.Properties.index) { - return createIndexText(parent); - } - if (key == NavigationViewsRepository.SimpleModelNavigation.Properties.feature) { - return createFeatureFlatComboViewer(parent); - } - if (key == NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType) { - return createDiscriminatorTypeFlatComboViewer(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(NavigationMessages.SimpleModelNavigationPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createIndexText(Composite parent) { - createDescription(parent, NavigationViewsRepository.SimpleModelNavigation.Properties.index, NavigationMessages.SimpleModelNavigationPropertiesEditionPart_IndexLabel); - index = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData indexData = new GridData(GridData.FILL_HORIZONTAL); - index.setLayoutData(indexData); - index.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(SimpleModelNavigationPropertiesEditionPartImpl.this, NavigationViewsRepository.SimpleModelNavigation.Properties.index, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, index.getText())); - } - - }); - index.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(SimpleModelNavigationPropertiesEditionPartImpl.this, NavigationViewsRepository.SimpleModelNavigation.Properties.index, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, index.getText())); - } - } - - }); - EditingUtils.setID(index, NavigationViewsRepository.SimpleModelNavigation.Properties.index); - EditingUtils.setEEFtype(index, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.SimpleModelNavigation.Properties.index, NavigationViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createIndexText - - // End of user code - return parent; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createFeatureFlatComboViewer(Composite parent) { - createDescription(parent, NavigationViewsRepository.SimpleModelNavigation.Properties.feature, NavigationMessages.SimpleModelNavigationPropertiesEditionPart_FeatureLabel); - feature = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(NavigationViewsRepository.SimpleModelNavigation.Properties.feature, NavigationViewsRepository.SWT_KIND)); - feature.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - feature.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(SimpleModelNavigationPropertiesEditionPartImpl.this, NavigationViewsRepository.SimpleModelNavigation.Properties.feature, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getFeature())); - } - - }); - GridData featureData = new GridData(GridData.FILL_HORIZONTAL); - feature.setLayoutData(featureData); - feature.setID(NavigationViewsRepository.SimpleModelNavigation.Properties.feature); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.SimpleModelNavigation.Properties.feature, NavigationViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createFeatureFlatComboViewer - - // End of user code - return parent; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createDiscriminatorTypeFlatComboViewer(Composite parent) { - createDescription(parent, NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType, NavigationMessages.SimpleModelNavigationPropertiesEditionPart_DiscriminatorTypeLabel); - discriminatorType = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType, NavigationViewsRepository.SWT_KIND)); - discriminatorType.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - discriminatorType.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(SimpleModelNavigationPropertiesEditionPartImpl.this, NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getDiscriminatorType())); - } - - }); - GridData discriminatorTypeData = new GridData(GridData.FILL_HORIZONTAL); - discriminatorType.setLayoutData(discriminatorTypeData); - discriminatorType.setID(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType, NavigationViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createDiscriminatorTypeFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#getIndex() - * - */ - public String getIndex() { - return index.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#setIndex(String newValue) - * - */ - public void setIndex(String newValue) { - if (newValue != null) { - index.setText(newValue); - } else { - index.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.SimpleModelNavigation.Properties.index); - if (eefElementEditorReadOnlyState && index.isEnabled()) { - index.setEnabled(false); - index.setToolTipText(NavigationMessages.SimpleModelNavigation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !index.isEnabled()) { - index.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#getFeature() - * - */ - public EObject getFeature() { - if (feature.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) feature.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#initFeature(EObjectFlatComboSettings) - */ - public void initFeature(EObjectFlatComboSettings settings) { - feature.setInput(settings); - if (current != null) { - feature.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.SimpleModelNavigation.Properties.feature); - if (eefElementEditorReadOnlyState && feature.isEnabled()) { - feature.setEnabled(false); - feature.setToolTipText(NavigationMessages.SimpleModelNavigation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !feature.isEnabled()) { - feature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#setFeature(EObject newValue) - * - */ - public void setFeature(EObject newValue) { - if (newValue != null) { - feature.setSelection(new StructuredSelection(newValue)); - } else { - feature.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.SimpleModelNavigation.Properties.feature); - if (eefElementEditorReadOnlyState && feature.isEnabled()) { - feature.setEnabled(false); - feature.setToolTipText(NavigationMessages.SimpleModelNavigation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !feature.isEnabled()) { - feature.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#setFeatureButtonMode(ButtonsModeEnum newValue) - */ - public void setFeatureButtonMode(ButtonsModeEnum newValue) { - feature.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#addFilterFeature(ViewerFilter filter) - * - */ - public void addFilterToFeature(ViewerFilter filter) { - feature.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#addBusinessFilterFeature(ViewerFilter filter) - * - */ - public void addBusinessFilterToFeature(ViewerFilter filter) { - feature.addBusinessRuleFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#getDiscriminatorType() - * - */ - public EObject getDiscriminatorType() { - if (discriminatorType.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) discriminatorType.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#initDiscriminatorType(EObjectFlatComboSettings) - */ - public void initDiscriminatorType(EObjectFlatComboSettings settings) { - discriminatorType.setInput(settings); - if (current != null) { - discriminatorType.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType); - if (eefElementEditorReadOnlyState && discriminatorType.isEnabled()) { - discriminatorType.setEnabled(false); - discriminatorType.setToolTipText(NavigationMessages.SimpleModelNavigation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !discriminatorType.isEnabled()) { - discriminatorType.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#setDiscriminatorType(EObject newValue) - * - */ - public void setDiscriminatorType(EObject newValue) { - if (newValue != null) { - discriminatorType.setSelection(new StructuredSelection(newValue)); - } else { - discriminatorType.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType); - if (eefElementEditorReadOnlyState && discriminatorType.isEnabled()) { - discriminatorType.setEnabled(false); - discriminatorType.setToolTipText(NavigationMessages.SimpleModelNavigation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !discriminatorType.isEnabled()) { - discriminatorType.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#setDiscriminatorTypeButtonMode(ButtonsModeEnum newValue) - */ - public void setDiscriminatorTypeButtonMode(ButtonsModeEnum newValue) { - discriminatorType.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#addFilterDiscriminatorType(ViewerFilter filter) - * - */ - public void addFilterToDiscriminatorType(ViewerFilter filter) { - discriminatorType.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.navigation.parts.SimpleModelNavigationPropertiesEditionPart#addBusinessFilterDiscriminatorType(ViewerFilter filter) - * - */ - public void addBusinessFilterToDiscriminatorType(ViewerFilter filter) { - discriminatorType.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return NavigationMessages.SimpleModelNavigation_Part_Title; - } - - // Start of user code additional methods - public void setDiscriminatorInput(SimpleModelNavigation simpleModelNavigation, ResourceSet allResources){ - discriminatorType.setInput(EEFUtils.choiceOfValues(adapterFactory, simpleModelNavigation, NavigationPackage.eINSTANCE.getSimpleModelNavigation_DiscriminatorType())); - if (simpleModelNavigation.getDiscriminatorType() != null){ - discriminatorType.setSelection(new StructuredSelection(simpleModelNavigation.getDiscriminatorType())); - } - } - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/ChainedModelNavigationItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/ChainedModelNavigationItemProvider.java deleted file mode 100644 index f92b2dba2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/ChainedModelNavigationItemProvider.java +++ /dev/null @@ -1,197 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationFactory; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation} object. - * - * - * @generated - */ -public class ChainedModelNavigationItemProvider extends - StructuredModelNavigationItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public ChainedModelNavigationItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures - .add(NavigationPackage.Literals.CHAINED_MODEL_NAVIGATION__CURRENT); - childrenFeatures - .add(NavigationPackage.Literals.CHAINED_MODEL_NAVIGATION__NEXT); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns ChainedModelNavigation.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/ChainedModelNavigation")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_ChainedModelNavigation_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(ChainedModelNavigation.class)) { - case NavigationPackage.CHAINED_MODEL_NAVIGATION__CURRENT: - case NavigationPackage.CHAINED_MODEL_NAVIGATION__NEXT: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add(createChildParameter( - NavigationPackage.Literals.CHAINED_MODEL_NAVIGATION__CURRENT, - NavigationFactory.eINSTANCE.createSimpleModelNavigation())); - - newChildDescriptors.add(createChildParameter( - NavigationPackage.Literals.CHAINED_MODEL_NAVIGATION__CURRENT, - NavigationFactory.eINSTANCE.createChainedModelNavigation())); - - newChildDescriptors.add(createChildParameter( - NavigationPackage.Literals.CHAINED_MODEL_NAVIGATION__NEXT, - NavigationFactory.eINSTANCE.createSimpleModelNavigation())); - - newChildDescriptors.add(createChildParameter( - NavigationPackage.Literals.CHAINED_MODEL_NAVIGATION__NEXT, - NavigationFactory.eINSTANCE.createChainedModelNavigation())); - } - - /** - * This returns the label text for {@link org.eclipse.emf.edit.command.CreateChildCommand}. - * - * - * @generated - */ - @Override - public String getCreateChildText(Object owner, Object feature, - Object child, Collection selection) { - Object childFeature = feature; - Object childObject = child; - - boolean qualify = childFeature == NavigationPackage.Literals.CHAINED_MODEL_NAVIGATION__CURRENT - || childFeature == NavigationPackage.Literals.CHAINED_MODEL_NAVIGATION__NEXT; - - if (qualify) { - return getString("_UI_CreateChild_text2", new Object[] { - getTypeText(childObject), getFeatureText(childFeature), - getTypeText(owner) }); - } - return super.getCreateChildText(owner, feature, child, selection); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/CustomModelNavigationItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/CustomModelNavigationItemProvider.java deleted file mode 100644 index 6b30f65b2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/CustomModelNavigationItemProvider.java +++ /dev/null @@ -1,111 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation} object. - * - * - * @generated - */ -public class CustomModelNavigationItemProvider extends - ModelNavigationItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public CustomModelNavigationItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns CustomModelNavigation.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/CustomModelNavigation")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_CustomModelNavigation_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/DeclarativeNavigationStepItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/DeclarativeNavigationStepItemProvider.java deleted file mode 100644 index 1c8c63e4e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/DeclarativeNavigationStepItemProvider.java +++ /dev/null @@ -1,275 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.NavigationStep; -import org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep} object. - * - * - * @generated - */ -public class DeclarativeNavigationStepItemProvider extends - NavigationStepItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public DeclarativeNavigationStepItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addIndexPropertyDescriptor(object); - addFeaturePropertyDescriptor(object); - addDiscriminatorTypePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Index feature. - * - * - * @generated - */ - protected void addIndexPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_DeclarativeNavigationStep_index_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_DeclarativeNavigationStep_index_feature", - "_UI_DeclarativeNavigationStep_type"), - NavigationPackage.Literals.DECLARATIVE_NAVIGATION_STEP__INDEX, - true, false, false, - ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE, null, null)); - } - - /** - * This adds a property descriptor for the Feature feature. - * - * - * @generated NOT - */ - protected void addFeaturePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(initFeatureItemDescriptor()); - } - - /** - * @return - * @generated NOT - */ - private ItemPropertyDescriptor initFeatureItemDescriptor() { - return new ItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_DeclarativeNavigationStep_feature_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_DeclarativeNavigationStep_feature_feature", - "_UI_DeclarativeNavigationStep_type"), - NavigationPackage.Literals.DECLARATIVE_NAVIGATION_STEP__FEATURE, - true, false, true, null, null, null) { - - @Override - public Collection getChoiceOfValues(Object object) { - Collection choiceOfValues = super.getChoiceOfValues(object); - if (object instanceof NavigationStep) { - NavigationStep step = (NavigationStep) object; - EClass currentClass = null; - if (step.eContainer() instanceof SmartModelNavigation) { - currentClass = step.owningEClass(); - } else if (step.eContainer() instanceof NavigationStep - && NavigationPackage.eINSTANCE - .getNavigationStep_SubStep() == step - .eContainingFeature()) { - currentClass = ((NavigationStep) step.eContainer()) - .currentEClass(); - } - - if (currentClass != null) { - EList allStructuralFeatures = currentClass - .getEAllStructuralFeatures(); - List results = new ArrayList(); - for (Object value : choiceOfValues) { - if (value instanceof EStructuralFeature - && allStructuralFeatures.contains(value)) - results.add((EStructuralFeature) value); - } - return results; - } - } - return choiceOfValues; - } - - }; - } - - /** - * This adds a property descriptor for the Discriminator Type feature. - * - * - * @generated - */ - protected void addDiscriminatorTypePropertyDescriptor(Object object) { - itemPropertyDescriptors - .add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_DeclarativeNavigationStep_discriminatorType_feature"), - getString( - "_UI_PropertyDescriptor_description", - "_UI_DeclarativeNavigationStep_discriminatorType_feature", - "_UI_DeclarativeNavigationStep_type"), - NavigationPackage.Literals.DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE, - true, false, true, null, null, null)); - } - - /** - * @return - * @generated NOT - */ - private ItemPropertyDescriptor initializeDiscriminatorTypePropertyDescriptor() { - return new ItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_DeclarativeNavigationStep_discriminatorType_feature"), - getString( - "_UI_PropertyDescriptor_description", - "_UI_DeclarativeNavigationStep_discriminatorType_feature", - "_UI_DeclarativeNavigationStep_type"), - NavigationPackage.Literals.DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE, - true, false, true, null, null, null) { - - @Override - public Collection getChoiceOfValues(Object object) { - Collection choiceOfValues = super.getChoiceOfValues(object); - if (object instanceof DeclarativeNavigationStep) { - DeclarativeNavigationStep step = (DeclarativeNavigationStep) object; - if (step.getFeature() != null) { - EClassifier type = step.getFeature().getEType(); - if (type instanceof EClass) { - EClass targetType = (EClass) type; - List result = new ArrayList(); - for (Object value : choiceOfValues) { - if (value instanceof EClass - && targetType - .isSuperTypeOf((EClass) value)) - result.add((EClassifier) value); - } - return result; - } - } - } - return choiceOfValues; - } - - }; - } - - /** - * This returns DeclarativeNavigationStep.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/DeclarativeNavigationStep")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - DeclarativeNavigationStep declarativeNavigationStep = (DeclarativeNavigationStep) object; - return getString("_UI_DeclarativeNavigationStep_type") + " " - + declarativeNavigationStep.getIndex(); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(DeclarativeNavigationStep.class)) { - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__INDEX: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaBodyExpressionItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaBodyExpressionItemProvider.java deleted file mode 100644 index 033c4ee04..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaBodyExpressionItemProvider.java +++ /dev/null @@ -1,156 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression} object. - * - * - * @generated - */ -public class JavaBodyExpressionItemProvider extends ItemProviderAdapter - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public JavaBodyExpressionItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addBodyPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Body feature. - * - * - * @generated - */ - protected void addBodyPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_JavaBodyExpression_body_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_JavaBodyExpression_body_feature", - "_UI_JavaBodyExpression_type"), - NavigationPackage.Literals.JAVA_BODY_EXPRESSION__BODY, true, - false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, - null)); - } - - /** - * This returns JavaBodyExpression.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator().getImage("full/obj16/JavaBodyExpression")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((JavaBodyExpression) object).getBody(); - return label == null || label.length() == 0 ? getString("_UI_JavaBodyExpression_type") - : getString("_UI_JavaBodyExpression_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(JavaBodyExpression.class)) { - case NavigationPackage.JAVA_BODY_EXPRESSION__BODY: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender) adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaBodyStepInitializerItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaBodyStepInitializerItemProvider.java deleted file mode 100644 index cccaab572..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaBodyStepInitializerItemProvider.java +++ /dev/null @@ -1,112 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer} object. - * - * - * @generated - */ -public class JavaBodyStepInitializerItemProvider extends - JavaBodyExpressionItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public JavaBodyStepInitializerItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns JavaBodyStepInitializer.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/JavaBodyStepInitializer")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((JavaBodyStepInitializer) object).getBody(); - return label == null || label.length() == 0 ? getString("_UI_JavaBodyStepInitializer_type") - : getString("_UI_JavaBodyStepInitializer_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaDeclarationExpressionItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaDeclarationExpressionItemProvider.java deleted file mode 100644 index 769004906..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaDeclarationExpressionItemProvider.java +++ /dev/null @@ -1,194 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression} object. - * - * - * @generated - */ -public class JavaDeclarationExpressionItemProvider extends ItemProviderAdapter - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public JavaDeclarationExpressionItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addQualifiedClassPropertyDescriptor(object); - addMethodNamePropertyDescriptor(object); - addStaticMethodPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Qualified Class feature. - * - * - * @generated - */ - protected void addQualifiedClassPropertyDescriptor(Object object) { - itemPropertyDescriptors - .add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_JavaDeclarationExpression_qualifiedClass_feature"), - getString( - "_UI_PropertyDescriptor_description", - "_UI_JavaDeclarationExpression_qualifiedClass_feature", - "_UI_JavaDeclarationExpression_type"), - NavigationPackage.Literals.JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS, - true, false, false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - - /** - * This adds a property descriptor for the Method Name feature. - * - * - * @generated - */ - protected void addMethodNamePropertyDescriptor(Object object) { - itemPropertyDescriptors - .add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_JavaDeclarationExpression_methodName_feature"), - getString( - "_UI_PropertyDescriptor_description", - "_UI_JavaDeclarationExpression_methodName_feature", - "_UI_JavaDeclarationExpression_type"), - NavigationPackage.Literals.JAVA_DECLARATION_EXPRESSION__METHOD_NAME, - true, false, false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - - /** - * This adds a property descriptor for the Static Method feature. - * - * - * @generated - */ - protected void addStaticMethodPropertyDescriptor(Object object) { - itemPropertyDescriptors - .add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_JavaDeclarationExpression_staticMethod_feature"), - getString( - "_UI_PropertyDescriptor_description", - "_UI_JavaDeclarationExpression_staticMethod_feature", - "_UI_JavaDeclarationExpression_type"), - NavigationPackage.Literals.JAVA_DECLARATION_EXPRESSION__STATIC_METHOD, - true, false, false, - ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, null, null)); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((JavaDeclarationExpression) object).getMethodName(); - return label == null || label.length() == 0 ? getString("_UI_JavaDeclarationExpression_type") - : getString("_UI_JavaDeclarationExpression_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(JavaDeclarationExpression.class)) { - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS: - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__METHOD_NAME: - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__STATIC_METHOD: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender) adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaDeclarationStepInitializerItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaDeclarationStepInitializerItemProvider.java deleted file mode 100644 index 995c7f1a0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/JavaDeclarationStepInitializerItemProvider.java +++ /dev/null @@ -1,115 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer} object. - * - * - * @generated - */ -public class JavaDeclarationStepInitializerItemProvider extends - JavaDeclarationExpressionItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public JavaDeclarationStepInitializerItemProvider( - AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns JavaDeclarationStepInitializer.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/JavaDeclarationStepInitializer")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((JavaDeclarationStepInitializer) object) - .getMethodName(); - return label == null || label.length() == 0 ? getString("_UI_JavaDeclarationStepInitializer_type") - : getString("_UI_JavaDeclarationStepInitializer_type") + " " - + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/ModelNavigationItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/ModelNavigationItemProvider.java deleted file mode 100644 index 7aea62b2a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/ModelNavigationItemProvider.java +++ /dev/null @@ -1,110 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.ModelNavigation} object. - * - * - * @generated - */ -public class ModelNavigationItemProvider extends ItemProviderAdapter implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public ModelNavigationItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_ModelNavigation_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender) adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/NavigationItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/NavigationItemProviderAdapterFactory.java deleted file mode 100644 index 0f5c774ac..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/NavigationItemProviderAdapterFactory.java +++ /dev/null @@ -1,439 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ChildCreationExtenderManager; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.util.NavigationAdapterFactory; -import org.eclipse.emf.eef.mapping.provider.MappingEditPlugin; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class NavigationItemProviderAdapterFactory extends - NavigationAdapterFactory implements ComposeableAdapterFactory, - IChangeNotifier, IDisposable, IChildCreationExtender { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This helps manage the child creation extenders. - * - * - * @generated - */ - protected ChildCreationExtenderManager childCreationExtenderManager = new ChildCreationExtenderManager( - MappingEditPlugin.INSTANCE, NavigationPackage.eNS_URI); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public NavigationItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation} instances. - * - * - * @generated - */ - protected SimpleModelNavigationItemProvider simpleModelNavigationItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation}. - * - * - * @generated - */ - @Override - public Adapter createSimpleModelNavigationAdapter() { - if (simpleModelNavigationItemProvider == null) { - simpleModelNavigationItemProvider = new SimpleModelNavigationItemProvider( - this); - } - - return simpleModelNavigationItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation} instances. - * - * - * @generated - */ - protected ChainedModelNavigationItemProvider chainedModelNavigationItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation}. - * - * - * @generated - */ - @Override - public Adapter createChainedModelNavigationAdapter() { - if (chainedModelNavigationItemProvider == null) { - chainedModelNavigationItemProvider = new ChainedModelNavigationItemProvider( - this); - } - - return chainedModelNavigationItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation} instances. - * - * - * @generated - */ - protected CustomModelNavigationItemProvider customModelNavigationItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation}. - * - * - * @generated - */ - @Override - public Adapter createCustomModelNavigationAdapter() { - if (customModelNavigationItemProvider == null) { - customModelNavigationItemProvider = new CustomModelNavigationItemProvider( - this); - } - - return customModelNavigationItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation} instances. - * - * - * @generated - */ - protected SmartModelNavigationItemProvider smartModelNavigationItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation}. - * - * - * @generated - */ - @Override - public Adapter createSmartModelNavigationAdapter() { - if (smartModelNavigationItemProvider == null) { - smartModelNavigationItemProvider = new SmartModelNavigationItemProvider( - this); - } - - return smartModelNavigationItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep} instances. - * - * - * @generated - */ - protected DeclarativeNavigationStepItemProvider declarativeNavigationStepItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep}. - * - * - * @generated - */ - @Override - public Adapter createDeclarativeNavigationStepAdapter() { - if (declarativeNavigationStepItemProvider == null) { - declarativeNavigationStepItemProvider = new DeclarativeNavigationStepItemProvider( - this); - } - - return declarativeNavigationStepItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression} instances. - * - * - * @generated - */ - protected JavaBodyExpressionItemProvider javaBodyExpressionItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression}. - * - * - * @generated - */ - @Override - public Adapter createJavaBodyExpressionAdapter() { - if (javaBodyExpressionItemProvider == null) { - javaBodyExpressionItemProvider = new JavaBodyExpressionItemProvider( - this); - } - - return javaBodyExpressionItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer} instances. - * - * - * @generated - */ - protected JavaDeclarationStepInitializerItemProvider javaDeclarationStepInitializerItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer}. - * - * - * @generated - */ - @Override - public Adapter createJavaDeclarationStepInitializerAdapter() { - if (javaDeclarationStepInitializerItemProvider == null) { - javaDeclarationStepInitializerItemProvider = new JavaDeclarationStepInitializerItemProvider( - this); - } - - return javaDeclarationStepInitializerItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer} instances. - * - * - * @generated - */ - protected JavaBodyStepInitializerItemProvider javaBodyStepInitializerItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer}. - * - * - * @generated - */ - @Override - public Adapter createJavaBodyStepInitializerAdapter() { - if (javaBodyStepInitializerItemProvider == null) { - javaBodyStepInitializerItemProvider = new JavaBodyStepInitializerItemProvider( - this); - } - - return javaBodyStepInitializerItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory - .getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory( - ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) - || (((Class) type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * - * - * @generated - */ - public List getChildCreationExtenders() { - return childCreationExtenderManager.getChildCreationExtenders(); - } - - /** - * - * - * @generated - */ - public Collection getNewChildDescriptors(Object object, - EditingDomain editingDomain) { - return childCreationExtenderManager.getNewChildDescriptors(object, - editingDomain); - } - - /** - * - * - * @generated - */ - public ResourceLocator getResourceLocator() { - return childCreationExtenderManager; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (simpleModelNavigationItemProvider != null) - simpleModelNavigationItemProvider.dispose(); - if (chainedModelNavigationItemProvider != null) - chainedModelNavigationItemProvider.dispose(); - if (customModelNavigationItemProvider != null) - customModelNavigationItemProvider.dispose(); - if (smartModelNavigationItemProvider != null) - smartModelNavigationItemProvider.dispose(); - if (declarativeNavigationStepItemProvider != null) - declarativeNavigationStepItemProvider.dispose(); - if (javaBodyExpressionItemProvider != null) - javaBodyExpressionItemProvider.dispose(); - if (javaDeclarationStepInitializerItemProvider != null) - javaDeclarationStepInitializerItemProvider.dispose(); - if (javaBodyStepInitializerItemProvider != null) - javaBodyStepInitializerItemProvider.dispose(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/NavigationStepItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/NavigationStepItemProvider.java deleted file mode 100644 index 48a1de6d6..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/NavigationStepItemProvider.java +++ /dev/null @@ -1,184 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.ecore.EStructuralFeature; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.mapping.filters.FiltersFactory; -import org.eclipse.emf.eef.mapping.navigation.NavigationFactory; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.NavigationStep; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.NavigationStep} object. - * - * - * @generated - */ -public class NavigationStepItemProvider extends ItemProviderAdapter implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public NavigationStepItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures - .add(NavigationPackage.Literals.NAVIGATION_STEP__SUB_STEP); - childrenFeatures - .add(NavigationPackage.Literals.NAVIGATION_STEP__INITIALIZER); - childrenFeatures - .add(NavigationPackage.Literals.NAVIGATION_STEP__FILTERS); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_NavigationStep_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(NavigationStep.class)) { - case NavigationPackage.NAVIGATION_STEP__SUB_STEP: - case NavigationPackage.NAVIGATION_STEP__INITIALIZER: - case NavigationPackage.NAVIGATION_STEP__FILTERS: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add(createChildParameter( - NavigationPackage.Literals.NAVIGATION_STEP__SUB_STEP, - NavigationFactory.eINSTANCE.createDeclarativeNavigationStep())); - - newChildDescriptors.add(createChildParameter( - NavigationPackage.Literals.NAVIGATION_STEP__INITIALIZER, - NavigationFactory.eINSTANCE - .createJavaDeclarationStepInitializer())); - - newChildDescriptors.add(createChildParameter( - NavigationPackage.Literals.NAVIGATION_STEP__INITIALIZER, - NavigationFactory.eINSTANCE.createJavaBodyStepInitializer())); - - newChildDescriptors.add(createChildParameter( - NavigationPackage.Literals.NAVIGATION_STEP__FILTERS, - FiltersFactory.eINSTANCE.createJavaBodyStepFilter())); - - newChildDescriptors.add(createChildParameter( - NavigationPackage.Literals.NAVIGATION_STEP__FILTERS, - FiltersFactory.eINSTANCE.createJavaDeclarationStepFilter())); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender) adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/SimpleModelNavigationItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/SimpleModelNavigationItemProvider.java deleted file mode 100644 index 4bfa42387..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/SimpleModelNavigationItemProvider.java +++ /dev/null @@ -1,279 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation} object. - * - * - * @generated - */ -public class SimpleModelNavigationItemProvider extends - StructuredModelNavigationItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public SimpleModelNavigationItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addFeaturePropertyDescriptor(object); - addIndexPropertyDescriptor(object); - addDiscriminatorTypePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Feature feature. - * - * - * @generated NOT - */ - protected void addFeaturePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(initFeatureItemDescriptor()); - } - - /** - * @return - * @generated NOT - */ - private ItemPropertyDescriptor initFeatureItemDescriptor() { - return new ItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_SimpleModelNavigation_feature_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_SimpleModelNavigation_feature_feature", - "_UI_SimpleModelNavigation_type"), - NavigationPackage.Literals.SIMPLE_MODEL_NAVIGATION__FEATURE, - true, false, true, null, null, null) { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.edit.provider.ItemPropertyDescriptor#getComboBoxObjects(java.lang.Object) - */ - @Override - protected Collection getComboBoxObjects(Object object) { - Collection comboBoxObjects = super - .getComboBoxObjects(object); - if (object instanceof SimpleModelNavigation) { - SimpleModelNavigation smn = (SimpleModelNavigation) object; - EClass currentClass = null; - if (smn.eContainer() instanceof EMFPropertyBinding - || (smn.eContainer() instanceof ChainedModelNavigation && NavigationPackage.eINSTANCE - .getChainedModelNavigation_Current() == smn - .eContainingFeature())) - currentClass = smn.owningEClass(); - else if (smn.eContainer() instanceof ChainedModelNavigation - && NavigationPackage.eINSTANCE - .getChainedModelNavigation_Next() == smn - .eContainingFeature()) - currentClass = ((ChainedModelNavigation) smn - .eContainer()).currentEClass(); - if (currentClass != null) { - EList allStructuralFeatures = currentClass - .getEAllStructuralFeatures(); - List result = new ArrayList(); - for (Object object2 : comboBoxObjects) { - if (object2 instanceof EStructuralFeature - && allStructuralFeatures.contains(object2)) - result.add((EStructuralFeature) object2); - } - return result; - } - } - return comboBoxObjects; - } - - }; - } - - /** - * This adds a property descriptor for the Index feature. - * - * - * @generated - */ - protected void addIndexPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_SimpleModelNavigation_index_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_SimpleModelNavigation_index_feature", - "_UI_SimpleModelNavigation_type"), - NavigationPackage.Literals.SIMPLE_MODEL_NAVIGATION__INDEX, - true, false, false, - ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE, null, null)); - } - - /** - * This adds a property descriptor for the Discriminator Type feature. - * - * - * @generated NOT - */ - protected void addDiscriminatorTypePropertyDescriptor(Object object) { - itemPropertyDescriptors - .add(initializeDiscriminatorTypePropertyDescriptor()); - } - - /** - * @return - * @generated NOT - */ - private ItemPropertyDescriptor initializeDiscriminatorTypePropertyDescriptor() { - return new ItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_SimpleModelNavigation_discriminatorType_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_SimpleModelNavigation_discriminatorType_feature", - "_UI_SimpleModelNavigation_type"), - NavigationPackage.Literals.SIMPLE_MODEL_NAVIGATION__DISCRIMINATOR_TYPE, - true, false, true, null, null, null) { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.edit.provider.ItemPropertyDescriptor#getComboBoxObjects(java.lang.Object) - */ - @Override - protected Collection getComboBoxObjects(Object object) { - Collection comboBoxObjects = super - .getComboBoxObjects(object); - if (object instanceof SimpleModelNavigation) { - SimpleModelNavigation smn = (SimpleModelNavigation) object; - if (smn.getFeature() != null) { - EClassifier type = smn.getFeature().getEType(); - if (type instanceof EClass) { - EClass targetType = (EClass) type; - List result = new ArrayList(); - for (Object object2 : comboBoxObjects) { - if (object2 instanceof EClass - && targetType - .isSuperTypeOf((EClass) object2)) - result.add((EClassifier) object2); - } - return result; - } - } - } - return comboBoxObjects; - } - - }; - } - - /** - * This returns SimpleModelNavigation.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/SimpleModelNavigation")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - SimpleModelNavigation simpleModelNavigation = (SimpleModelNavigation) object; - return getString("_UI_SimpleModelNavigation_type") + " " - + simpleModelNavigation.getIndex(); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(SimpleModelNavigation.class)) { - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__INDEX: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/SmartModelNavigationItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/SmartModelNavigationItemProvider.java deleted file mode 100644 index 05a8acf0a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/SmartModelNavigationItemProvider.java +++ /dev/null @@ -1,157 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EStructuralFeature; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.mapping.navigation.NavigationFactory; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation} object. - * - * - * @generated - */ -public class SmartModelNavigationItemProvider extends - ModelNavigationItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public SmartModelNavigationItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures - .add(NavigationPackage.Literals.SMART_MODEL_NAVIGATION__STEP); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns SmartModelNavigation.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator() - .getImage("full/obj16/SmartModelNavigation")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_SmartModelNavigation_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(SmartModelNavigation.class)) { - case NavigationPackage.SMART_MODEL_NAVIGATION__STEP: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add(createChildParameter( - NavigationPackage.Literals.SMART_MODEL_NAVIGATION__STEP, - NavigationFactory.eINSTANCE.createDeclarativeNavigationStep())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/StepInitializerItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/StepInitializerItemProvider.java deleted file mode 100644 index 52e1e1b18..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/StepInitializerItemProvider.java +++ /dev/null @@ -1,108 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.StepInitializer} object. - * - * - * @generated - */ -public class StepInitializerItemProvider extends ItemProviderAdapter implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public StepInitializerItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_StepInitializer_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender) adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/StructuredModelNavigationItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/StructuredModelNavigationItemProvider.java deleted file mode 100644 index 838b4d727..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/provider/StructuredModelNavigationItemProvider.java +++ /dev/null @@ -1,111 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation} object. - * - * - * @generated - */ -public class StructuredModelNavigationItemProvider extends - ModelNavigationItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public StructuredModelNavigationItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns StructuredModelNavigation.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/StructuredModelNavigation")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_StructuredModelNavigation_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/NavigationMessages.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/NavigationMessages.java deleted file mode 100644 index cbc3dce38..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/NavigationMessages.java +++ /dev/null @@ -1,162 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.providers; - -import org.eclipse.osgi.util.NLS; - -/** - * @author Nathalie Lepine - * - */ -public class NavigationMessages extends NLS { - - private static final String BUNDLE_NAME = "org.eclipse.emf.eef.mapping.navigation.providers.navigationMessages"; //$NON-NLS-1$ - - - public static String ModelNavigationPropertiesEditionPart_PropertiesGroupLabel; - - - public static String SimpleModelNavigationPropertiesEditionPart_PropertiesGroupLabel; - - - public static String DeclarativeNavigationStepPropertiesEditionPart_PropertiesGroupLabel; - - - public static String JavaDeclarationStepInitializerPropertiesEditionPart_PropertiesGroupLabel; - - - public static String JavaBodyStepInitializerPropertiesEditionPart_PropertiesGroupLabel; - - - - public static String ModelNavigation_ReadOnly; - - - public static String ModelNavigation_Part_Title; - - - public static String SimpleModelNavigation_ReadOnly; - - - public static String SimpleModelNavigation_Part_Title; - - - public static String DeclarativeNavigationStep_ReadOnly; - - - public static String DeclarativeNavigationStep_Part_Title; - - - public static String JavaDeclarationStepInitializer_ReadOnly; - - - public static String JavaDeclarationStepInitializer_Part_Title; - - - public static String JavaBodyStepInitializer_ReadOnly; - - - public static String JavaBodyStepInitializer_Part_Title; - - - - public static String SimpleModelNavigationPropertiesEditionPart_IndexLabel; - - - public static String SimpleModelNavigationPropertiesEditionPart_FeatureLabel; - - - public static String SimpleModelNavigationPropertiesEditionPart_DiscriminatorTypeLabel; - - - public static String DeclarativeNavigationStepPropertiesEditionPart_IndexLabel; - - - public static String DeclarativeNavigationStepPropertiesEditionPart_FeatureLabel; - - - public static String DeclarativeNavigationStepPropertiesEditionPart_DiscriminatorTypeLabel; - - - public static String JavaDeclarationStepInitializerPropertiesEditionPart_QualifiedClassLabel; - - - public static String JavaDeclarationStepInitializerPropertiesEditionPart_MethodFilterLabel; - - - public static String JavaDeclarationStepInitializerPropertiesEditionPart_StaticMethodLabel; - - - public static String JavaBodyStepInitializerPropertiesEditionPart_BodyLabel; - - - - public static String PropertiesEditionPart_DocumentationLabel; - - - public static String PropertiesEditionPart_IntegerValueMessage; - - - public static String PropertiesEditionPart_FloatValueMessage; - - - public static String PropertiesEditionPart_ShortValueMessage; - - - public static String PropertiesEditionPart_LongValueMessage; - - - public static String PropertiesEditionPart_ByteValueMessage; - - - public static String PropertiesEditionPart_BigIntegerValueMessage; - - - public static String PropertiesEditionPart_BigDecimalValueMessage; - - - public static String PropertiesEditionPart_DoubleValueMessage; - - - public static String PropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesEditionPart_RequiredFeatureMessage; - - - public static String PropertiesEditionPart_AddTableViewerLabel; - - - public static String PropertiesEditionPart_EditTableViewerLabel; - - - public static String PropertiesEditionPart_RemoveTableViewerLabel; - - - public static String PropertiesEditionPart_AddListViewerLabel; - - - public static String PropertiesEditionPart_RemoveListViewerLabel; - - // Start of user code for additionnal NLS Constants - - // End of user code - - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, NavigationMessages.class); - } - - - private NavigationMessages() { - //protect instanciation - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/NavigationPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/NavigationPropertiesEditionPartProvider.java deleted file mode 100644 index 9f8c28381..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/NavigationPropertiesEditionPartProvider.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.providers; - -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; - -import org.eclipse.emf.eef.mapping.navigation.parts.forms.DeclarativeNavigationStepPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.navigation.parts.forms.JavaBodyStepInitializerPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.navigation.parts.forms.JavaDeclarationStepInitializerPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.navigation.parts.forms.ModelNavigationPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.navigation.parts.forms.SimpleModelNavigationPropertiesEditionPartForm; - -import org.eclipse.emf.eef.mapping.navigation.parts.impl.DeclarativeNavigationStepPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.navigation.parts.impl.JavaBodyStepInitializerPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.navigation.parts.impl.JavaDeclarationStepInitializerPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.navigation.parts.impl.ModelNavigationPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.navigation.parts.impl.SimpleModelNavigationPropertiesEditionPartImpl; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; - -/** - * @author Nathalie Lepine - * - */ -public class NavigationPropertiesEditionPartProvider implements IPropertiesEditionPartProvider { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#provides(java.lang.Object) - * - */ - public boolean provides(Object key) { - return key == NavigationViewsRepository.class; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#getPropertiesEditionPart(java.lang.Object, int, org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, IPropertiesEditionComponent component) { - if (key == NavigationViewsRepository.ModelNavigation.class) { - if (kind == NavigationViewsRepository.SWT_KIND) - return new ModelNavigationPropertiesEditionPartImpl(component); - if (kind == NavigationViewsRepository.FORM_KIND) - return new ModelNavigationPropertiesEditionPartForm(component); - } - if (key == NavigationViewsRepository.SimpleModelNavigation.class) { - if (kind == NavigationViewsRepository.SWT_KIND) - return new SimpleModelNavigationPropertiesEditionPartImpl(component); - if (kind == NavigationViewsRepository.FORM_KIND) - return new SimpleModelNavigationPropertiesEditionPartForm(component); - } - if (key == NavigationViewsRepository.DeclarativeNavigationStep.class) { - if (kind == NavigationViewsRepository.SWT_KIND) - return new DeclarativeNavigationStepPropertiesEditionPartImpl(component); - if (kind == NavigationViewsRepository.FORM_KIND) - return new DeclarativeNavigationStepPropertiesEditionPartForm(component); - } - if (key == NavigationViewsRepository.JavaDeclarationStepInitializer.class) { - if (kind == NavigationViewsRepository.SWT_KIND) - return new JavaDeclarationStepInitializerPropertiesEditionPartImpl(component); - if (kind == NavigationViewsRepository.FORM_KIND) - return new JavaDeclarationStepInitializerPropertiesEditionPartForm(component); - } - if (key == NavigationViewsRepository.JavaBodyStepInitializer.class) { - if (kind == NavigationViewsRepository.SWT_KIND) - return new JavaBodyStepInitializerPropertiesEditionPartImpl(component); - if (kind == NavigationViewsRepository.FORM_KIND) - return new JavaBodyStepInitializerPropertiesEditionPartForm(component); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/navigationMessages.properties b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/navigationMessages.properties deleted file mode 100644 index 27ff5403c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/navigationMessages.properties +++ /dev/null @@ -1,57 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -ModelNavigationPropertiesEditionPart_PropertiesGroupLabel=Properties -SimpleModelNavigationPropertiesEditionPart_PropertiesGroupLabel=Properties -DeclarativeNavigationStepPropertiesEditionPart_PropertiesGroupLabel=Properties -JavaDeclarationStepInitializerPropertiesEditionPart_PropertiesGroupLabel=Properties -JavaBodyStepInitializerPropertiesEditionPart_PropertiesGroupLabel=Properties -ModelNavigation_ReadOnly=This property is read only -ModelNavigation_Part_Title=Base -SimpleModelNavigation_ReadOnly=This property is read only -SimpleModelNavigation_Part_Title=Base -DeclarativeNavigationStep_ReadOnly=This property is read only -DeclarativeNavigationStep_Part_Title=Base -JavaDeclarationStepInitializer_ReadOnly=This property is read only -JavaDeclarationStepInitializer_Part_Title=Base -JavaBodyStepInitializer_ReadOnly=This property is read only -JavaBodyStepInitializer_Part_Title=Base -SimpleModelNavigationPropertiesEditionPart_IndexLabel=Index : -SimpleModelNavigationPropertiesEditionPart_FeatureLabel=Feature : -SimpleModelNavigationPropertiesEditionPart_DiscriminatorTypeLabel=DiscriminatorType : -DeclarativeNavigationStepPropertiesEditionPart_IndexLabel=Index : -DeclarativeNavigationStepPropertiesEditionPart_FeatureLabel=Feature : -DeclarativeNavigationStepPropertiesEditionPart_DiscriminatorTypeLabel=DiscriminatorType : -JavaDeclarationStepInitializerPropertiesEditionPart_QualifiedClassLabel=QualifiedClass : -JavaDeclarationStepInitializerPropertiesEditionPart_MethodFilterLabel=MethodFilter : -JavaDeclarationStepInitializerPropertiesEditionPart_StaticMethodLabel=StaticMethod -JavaBodyStepInitializerPropertiesEditionPart_BodyLabel=Body : -PropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionPart_EditTableViewerLabel=Edit -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=The property {0} of the object shall be filled -PropertiesEditionPart_RemoveTableViewerLabel=Delete -PropertiesEditionPart_RemoveListViewerLabel=Delete -PropertiesEditionPart_IntegerValueMessage=The property {0} shall be an integer -PropertiesEditionPart_FloatValueMessage=The property {0} shall be a float -PropertiesEditionPart_ShortValueMessage=The property {0} shall be a short -PropertiesEditionPart_DoubleValueMessage=The property {0} shall be a double -PropertiesEditionPart_ByteValueMessage=The property {0} shall be a byte -PropertiesEditionPart_LongValueMessage=The property {0} shall be a long -PropertiesEditionPart_BigIntegerValueMessage=The property {0} shall be a BigInteger -PropertiesEditionPart_BigDecimalValueMessage=The property {0} shall be a BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Add -PropertiesEditionPart_AddListViewerLabel=Add diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/navigationMessages_fr.properties b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/navigationMessages_fr.properties deleted file mode 100644 index c7eaa5675..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/navigation/providers/navigationMessages_fr.properties +++ /dev/null @@ -1,57 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -ModelNavigationPropertiesEditionPart_PropertiesGroupLabel=Properties -SimpleModelNavigationPropertiesEditionPart_PropertiesGroupLabel=Properties -DeclarativeNavigationStepPropertiesEditionPart_PropertiesGroupLabel=Properties -JavaDeclarationStepInitializerPropertiesEditionPart_PropertiesGroupLabel=Properties -JavaBodyStepInitializerPropertiesEditionPart_PropertiesGroupLabel=Properties -ModelNavigation_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -ModelNavigation_Part_Title=Base -SimpleModelNavigation_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -SimpleModelNavigation_Part_Title=Base -DeclarativeNavigationStep_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -DeclarativeNavigationStep_Part_Title=Base -JavaDeclarationStepInitializer_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -JavaDeclarationStepInitializer_Part_Title=Base -JavaBodyStepInitializer_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -JavaBodyStepInitializer_Part_Title=Base -SimpleModelNavigationPropertiesEditionPart_IndexLabel=Index : -SimpleModelNavigationPropertiesEditionPart_FeatureLabel=Feature : -SimpleModelNavigationPropertiesEditionPart_DiscriminatorTypeLabel=DiscriminatorType : -DeclarativeNavigationStepPropertiesEditionPart_IndexLabel=Index : -DeclarativeNavigationStepPropertiesEditionPart_FeatureLabel=Feature : -DeclarativeNavigationStepPropertiesEditionPart_DiscriminatorTypeLabel=DiscriminatorType : -JavaDeclarationStepInitializerPropertiesEditionPart_QualifiedClassLabel=QualifiedClass : -JavaDeclarationStepInitializerPropertiesEditionPart_MethodFilterLabel=MethodFilter : -JavaDeclarationStepInitializerPropertiesEditionPart_StaticMethodLabel=StaticMethod -JavaBodyStepInitializerPropertiesEditionPart_BodyLabel=Body : -PropertiesEditionPart_PropertiesGroupLabel=Propri\u00E9t\u00E9s -PropertiesEditionPart_EditTableViewerLabel=Editer -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=La propri\u00E9t\u00E9 {0} de l\u0027objet doit \u00EAtre renseign\u00E9e -PropertiesEditionPart_RemoveTableViewerLabel=Supprimer -PropertiesEditionPart_RemoveListViewerLabel=Supprimer -PropertiesEditionPart_IntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un entier -PropertiesEditionPart_FloatValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un flottant -PropertiesEditionPart_ShortValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un short -PropertiesEditionPart_DoubleValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un double -PropertiesEditionPart_ByteValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un byte -PropertiesEditionPart_LongValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un long -PropertiesEditionPart_BigIntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigInteger -PropertiesEditionPart_BigDecimalValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Ajouter -PropertiesEditionPart_AddListViewerLabel=Ajouter diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/CategoryPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/CategoryPropertiesEditionPart.java deleted file mode 100644 index 174657401..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/CategoryPropertiesEditionPart.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts; - -// Start of user code for imports - - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface CategoryPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/DocumentationPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/DocumentationPropertiesEditionPart.java deleted file mode 100644 index a0e3656e7..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/DocumentationPropertiesEditionPart.java +++ /dev/null @@ -1,53 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts; - -// Start of user code for imports - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface DocumentationPropertiesEditionPart { - - /** - * @return the documentation - * - */ - public String getDocumentation(); - - /** - * Defines a new documentation - * @param newValue the new documentation to set - * - */ - public void setDocumentation(String newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFElementBindingPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFElementBindingPropertiesEditionPart.java deleted file mode 100644 index 529eee3de..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFElementBindingPropertiesEditionPart.java +++ /dev/null @@ -1,148 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface EMFElementBindingPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the model - * - */ - public EObject getModel(); - - /** - * Init the model - * @param settings the combo setting - */ - public void initModel(EObjectFlatComboSettings settings); - - /** - * Defines a new model - * @param newValue the new model to set - * - */ - public void setModel(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setModelButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - - - - /** - * Init the views - * @param settings settings for the views ReferencesTable - */ - public void initViews(ReferencesTableSettings settings); - - /** - * Update the views - * @param newValue the views to update - * - */ - public void updateViews(); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViews(ViewerFilter filter); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the views table - * - */ - public boolean isContainedInViewsTable(EObject element); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFMultiPropertiesBindingPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFMultiPropertiesBindingPropertiesEditionPart.java deleted file mode 100644 index 89370c346..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFMultiPropertiesBindingPropertiesEditionPart.java +++ /dev/null @@ -1,141 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface EMFMultiPropertiesBindingPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - - - /** - * Init the model - * @param settings settings for the model ReferencesTable - */ - public void initModel(ReferencesTableSettings settings); - - /** - * Update the model - * @param newValue the model to update - * - */ - public void updateModel(); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the model table - * - */ - public boolean isContainedInModelTable(EObject element); - - - - - /** - * Init the views - * @param settings settings for the views ReferencesTable - */ - public void initViews(ReferencesTableSettings settings); - - /** - * Update the views - * @param newValue the views to update - * - */ - public void updateViews(); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViews(ViewerFilter filter); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the views table - * - */ - public boolean isContainedInViewsTable(EObject element); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFPropertyBindingPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFPropertyBindingPropertiesEditionPart.java deleted file mode 100644 index a89b8b850..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/EMFPropertyBindingPropertiesEditionPart.java +++ /dev/null @@ -1,148 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface EMFPropertyBindingPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the model - * - */ - public EObject getModel(); - - /** - * Init the model - * @param settings the combo setting - */ - public void initModel(EObjectFlatComboSettings settings); - - /** - * Defines a new model - * @param newValue the new model to set - * - */ - public void setModel(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setModelButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - - - - /** - * Init the views - * @param settings settings for the views ReferencesTable - */ - public void initViews(ReferencesTableSettings settings); - - /** - * Update the views - * @param newValue the views to update - * - */ - public void updateViews(); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViews(ViewerFilter filter); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the views table - * - */ - public boolean isContainedInViewsTable(EObject element); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/ElementBindingReferencePropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/ElementBindingReferencePropertiesEditionPart.java deleted file mode 100644 index 0219780b9..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/ElementBindingReferencePropertiesEditionPart.java +++ /dev/null @@ -1,91 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface ElementBindingReferencePropertiesEditionPart { - - /** - * @return the binding - * - */ - public EObject getBinding(); - - /** - * Init the binding - * @param settings the combo setting - */ - public void initBinding(EObjectFlatComboSettings settings); - - /** - * Defines a new binding - * @param newValue the new binding to set - * - */ - public void setBinding(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setBindingButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the binding edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToBinding(ViewerFilter filter); - - /** - * Adds the given filter to the binding edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToBinding(ViewerFilter filter); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/FilterPropertiesPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/FilterPropertiesPropertiesEditionPart.java deleted file mode 100644 index 8777daa3b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/FilterPropertiesPropertiesEditionPart.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts; - -// Start of user code for imports - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface FilterPropertiesPropertiesEditionPart { - - /** - * @return the Name - * - */ - public String getName(); - - /** - * Defines a new Name - * @param newValue the new Name to set - * - */ - public void setName(String newValue); - - - /** - * @return the Mandatory - * - */ - public Boolean getMandatory(); - - /** - * Defines a new Mandatory - * @param newValue the new Mandatory to set - * - */ - public void setMandatory(Boolean newValue); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/MappingViewsRepository.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/MappingViewsRepository.java deleted file mode 100644 index bcf294fbd..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/MappingViewsRepository.java +++ /dev/null @@ -1,218 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts; - -/** - * @author Nathalie Lepine - * - */ -public class MappingViewsRepository { - - public static final int SWT_KIND = 0; - - public static final int FORM_KIND = 1; - - - /** - * EMFElementBinding view descriptor - * - */ - public static class EMFElementBinding { - public static class Properties { - - - public static String name = "mapping::EMFElementBinding::Properties::name"; - - - } - - public static class Binding { - - - public static String model = "mapping::EMFElementBinding::Binding::model"; - - - public static String views = "mapping::EMFElementBinding::Binding::views"; - - - } - - } - - /** - * EMFPropertyBinding view descriptor - * - */ - public static class EMFPropertyBinding { - public static class Properties { - - - public static String name = "mapping::EMFPropertyBinding::Properties::name"; - - - } - - public static class Binding { - - - public static String model = "mapping::EMFPropertyBinding::Binding::model"; - - - public static String views = "mapping::EMFPropertyBinding::Binding::views"; - - - } - - } - - /** - * StandardElementBinding view descriptor - * - */ - public static class StandardElementBinding { - public static class Properties { - - - public static String name = "mapping::StandardElementBinding::Properties::name"; - - - } - - public static class Binding { - - - public static String model = "mapping::StandardElementBinding::Binding::model"; - - - public static String views = "mapping::StandardElementBinding::Binding::views"; - - - } - - } - - /** - * StandardPropertyBinding view descriptor - * - */ - public static class StandardPropertyBinding { - public static class Properties { - - - public static String name = "mapping::StandardPropertyBinding::Properties::name"; - - - } - - public static class Binding { - - - public static String model = "mapping::StandardPropertyBinding::Binding::model"; - - - public static String views = "mapping::StandardPropertyBinding::Binding::views"; - - - } - - } - - /** - * Category view descriptor - * - */ - public static class Category { - public static class Properties { - - - public static String name = "mapping::Category::Properties::name"; - - - } - - } - - /** - * ElementBindingReference view descriptor - * - */ - public static class ElementBindingReference { - public static class Reference { - - - public static String binding = "mapping::ElementBindingReference::Réference::binding"; - - - } - - } - - /** - * EMFMultiPropertiesBinding view descriptor - * - */ - public static class EMFMultiPropertiesBinding { - public static class Properties { - - - public static String name = "mapping::EMFMultiPropertiesBinding::Properties::name"; - - - } - - public static class Binding { - - - public static String model = "mapping::EMFMultiPropertiesBinding::Binding::model"; - - - public static String views = "mapping::EMFMultiPropertiesBinding::Binding::views"; - - - } - - } - - - /** - * Documentation view descriptor - * - */ - public static class Documentation { - public static class Documentation_ { - - - public static String documentation__ = "mapping::Documentation::Documentation_::documentation__"; - - - } - - } - - /** - * Filter properties view descriptor - * - */ - public static class FilterProperties { - public static class FilterProperties_ { - - - public static String name = "mapping::Filter properties::Filter Properties_::Name"; - - - public static String mandatory = "mapping::Filter properties::Filter Properties_::Mandatory"; - - - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/StandardElementBindingPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/StandardElementBindingPropertiesEditionPart.java deleted file mode 100644 index f0a8d7c96..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/StandardElementBindingPropertiesEditionPart.java +++ /dev/null @@ -1,148 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface StandardElementBindingPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the model - * - */ - public EObject getModel(); - - /** - * Init the model - * @param settings the combo setting - */ - public void initModel(EObjectFlatComboSettings settings); - - /** - * Defines a new model - * @param newValue the new model to set - * - */ - public void setModel(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setModelButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - - - - /** - * Init the views - * @param settings settings for the views ReferencesTable - */ - public void initViews(ReferencesTableSettings settings); - - /** - * Update the views - * @param newValue the views to update - * - */ - public void updateViews(); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViews(ViewerFilter filter); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the views table - * - */ - public boolean isContainedInViewsTable(EObject element); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/StandardPropertyBindingPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/StandardPropertyBindingPropertiesEditionPart.java deleted file mode 100644 index 226f66bff..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/StandardPropertyBindingPropertiesEditionPart.java +++ /dev/null @@ -1,148 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ViewerFilter; - - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface StandardPropertyBindingPropertiesEditionPart { - - /** - * @return the name - * - */ - public String getName(); - - /** - * Defines a new name - * @param newValue the new name to set - * - */ - public void setName(String newValue); - - - /** - * @return the model - * - */ - public EObject getModel(); - - /** - * Init the model - * @param settings the combo setting - */ - public void initModel(EObjectFlatComboSettings settings); - - /** - * Defines a new model - * @param newValue the new model to set - * - */ - public void setModel(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setModelButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - - - - /** - * Init the views - * @param settings settings for the views ReferencesTable - */ - public void initViews(ReferencesTableSettings settings); - - /** - * Update the views - * @param newValue the views to update - * - */ - public void updateViews(); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToViews(ViewerFilter filter); - - /** - * Adds the given filter to the views edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter); - - /** - * @return true if the given element is contained inside the views table - * - */ - public boolean isContainedInViewsTable(EObject element); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/CategoryPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/CategoryPropertiesEditionPartForm.java deleted file mode 100644 index ffe102c1b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/CategoryPropertiesEditionPartForm.java +++ /dev/null @@ -1,266 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.parts.CategoryPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class CategoryPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, CategoryPropertiesEditionPart { - - protected Text name; - - - - /** - * For {@link ISection} use only. - */ - public CategoryPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public CategoryPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence categoryStep = new BindingCompositionSequence(propertiesEditionComponent); - categoryStep - .addStep(MappingViewsRepository.Category.Properties.class) - .addStep(MappingViewsRepository.Category.Properties.name); - - - composer = new PartComposer(categoryStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.Category.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.Category.Properties.name) { - return createNameText(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(MappingMessages.CategoryPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, MappingViewsRepository.Category.Properties.name, MappingMessages.CategoryPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - CategoryPropertiesEditionPartForm.this, - MappingViewsRepository.Category.Properties.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - CategoryPropertiesEditionPartForm.this, - MappingViewsRepository.Category.Properties.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - CategoryPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(CategoryPropertiesEditionPartForm.this, MappingViewsRepository.Category.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, MappingViewsRepository.Category.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.Category.Properties.name, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.CategoryPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.CategoryPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.Category.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.Category_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.Category_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/DocumentationPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/DocumentationPropertiesEditionPartForm.java deleted file mode 100644 index 2906319cd..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/DocumentationPropertiesEditionPartForm.java +++ /dev/null @@ -1,257 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.parts.DocumentationPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class DocumentationPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, DocumentationPropertiesEditionPart { - - protected Text documentation; - - - - /** - * For {@link ISection} use only. - */ - public DocumentationPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public DocumentationPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence documentationStep = new BindingCompositionSequence(propertiesEditionComponent); - documentationStep - .addStep(MappingViewsRepository.Documentation.Documentation_.class) - .addStep(MappingViewsRepository.Documentation.Documentation_.documentation__); - - - composer = new PartComposer(documentationStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.Documentation.Documentation_.class) { - return createDocumentationGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.Documentation.Documentation_.documentation__) { - return createDocumentationTextarea(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createDocumentationGroup(FormToolkit widgetFactory, final Composite parent) { - Section documentationSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - documentationSection.setText(MappingMessages.DocumentationPropertiesEditionPart_DocumentationGroupLabel); - GridData documentationSectionData = new GridData(GridData.FILL_HORIZONTAL); - documentationSectionData.horizontalSpan = 3; - documentationSection.setLayoutData(documentationSectionData); - Composite documentationGroup = widgetFactory.createComposite(documentationSection); - GridLayout documentationGroupLayout = new GridLayout(); - documentationGroupLayout.numColumns = 3; - documentationGroup.setLayout(documentationGroupLayout); - documentationSection.setClient(documentationGroup); - return documentationGroup; - } - - - protected Composite createDocumentationTextarea(FormToolkit widgetFactory, Composite parent) { - Label documentationLabel = createDescription(parent, MappingViewsRepository.Documentation.Documentation_.documentation__, MappingMessages.DocumentationPropertiesEditionPart_DocumentationLabel); - GridData documentationLabelData = new GridData(GridData.FILL_HORIZONTAL); - documentationLabelData.horizontalSpan = 3; - documentationLabel.setLayoutData(documentationLabelData); - documentation = widgetFactory.createText(parent, "", SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); //$NON-NLS-1$ - GridData documentationData = new GridData(GridData.FILL_HORIZONTAL); - documentationData.horizontalSpan = 2; - documentationData.heightHint = 80; - documentationData.widthHint = 200; - documentation.setLayoutData(documentationData); - documentation.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - DocumentationPropertiesEditionPartForm.this, - MappingViewsRepository.Documentation.Documentation_.documentation__, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, documentation.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - DocumentationPropertiesEditionPartForm.this, - MappingViewsRepository.Documentation.Documentation_.documentation__, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, documentation.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - DocumentationPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - EditingUtils.setID(documentation, MappingViewsRepository.Documentation.Documentation_.documentation__); - EditingUtils.setEEFtype(documentation, "eef::Textarea"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.Documentation.Documentation_.documentation__, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createDocumentationTextArea - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.DocumentationPropertiesEditionPart#getDocumentation() - * - */ - public String getDocumentation() { - return documentation.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.DocumentationPropertiesEditionPart#setDocumentation(String newValue) - * - */ - public void setDocumentation(String newValue) { - if (newValue != null) { - documentation.setText(newValue); - } else { - documentation.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.Documentation.Documentation_.documentation__); - if (eefElementEditorReadOnlyState && documentation.isEnabled()) { - documentation.setEnabled(false); - documentation.setBackground(documentation.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - documentation.setToolTipText(MappingMessages.Documentation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !documentation.isEnabled()) { - documentation.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.Documentation_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFElementBindingPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFElementBindingPropertiesEditionPartForm.java deleted file mode 100644 index 0b88831a9..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFElementBindingPropertiesEditionPartForm.java +++ /dev/null @@ -1,591 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.forms; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFElementBindingPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, EMFElementBindingPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * For {@link ISection} use only. - */ - public EMFElementBindingPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EMFElementBindingPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence eMFElementBindingStep = new BindingCompositionSequence(propertiesEditionComponent); - eMFElementBindingStep - .addStep(MappingViewsRepository.EMFElementBinding.Properties.class) - .addStep(MappingViewsRepository.EMFElementBinding.Properties.name); - - CompositionStep bindingStep = eMFElementBindingStep.addStep(MappingViewsRepository.EMFElementBinding.Binding.class); - bindingStep.addStep(MappingViewsRepository.EMFElementBinding.Binding.model); - bindingStep.addStep(MappingViewsRepository.EMFElementBinding.Binding.views); - - - composer = new PartComposer(eMFElementBindingStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.EMFElementBinding.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.EMFElementBinding.Properties.name) { - return createNameText(widgetFactory, parent); - } - if (key == MappingViewsRepository.EMFElementBinding.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.EMFElementBinding.Binding.model) { - return createModelFlatComboViewer(parent, widgetFactory); - } - if (key == MappingViewsRepository.EMFElementBinding.Binding.views) { - return createViewsReferencesTable(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(MappingMessages.EMFElementBindingPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, MappingViewsRepository.EMFElementBinding.Properties.name, MappingMessages.EMFElementBindingPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EMFElementBindingPropertiesEditionPartForm.this, - MappingViewsRepository.EMFElementBinding.Properties.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EMFElementBindingPropertiesEditionPartForm.this, - MappingViewsRepository.EMFElementBinding.Properties.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EMFElementBindingPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFElementBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, MappingViewsRepository.EMFElementBinding.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFElementBinding.Properties.name, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(MappingMessages.EMFElementBindingPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createModelFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, MappingViewsRepository.EMFElementBinding.Binding.model, MappingMessages.EMFElementBindingPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(MappingViewsRepository.EMFElementBinding.Binding.model, MappingViewsRepository.FORM_KIND)); - widgetFactory.adapt(model); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFElementBinding.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - model.setID(MappingViewsRepository.EMFElementBinding.Binding.model); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFElementBinding.Binding.model, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.views = new ReferencesTable(getDescription(MappingViewsRepository.EMFElementBinding.Binding.views, MappingMessages.EMFElementBindingPropertiesEditionPart_ViewsLabel), new ReferencesTableListener () { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFElementBinding.Binding.views, MappingViewsRepository.FORM_KIND)); - this.views.createControls(parent, widgetFactory); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFElementBinding.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(MappingViewsRepository.EMFElementBinding.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - // Start of user code for createViewsReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFElementBinding.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFElementBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFElementBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFElementBinding.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.EMFElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFElementBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.EMFElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFElementBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.EMFElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFElementBinding.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(MappingMessages.EMFElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.EMFElementBinding_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFMultiPropertiesBindingPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFMultiPropertiesBindingPropertiesEditionPartForm.java deleted file mode 100644 index 2585f081e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFMultiPropertiesBindingPropertiesEditionPartForm.java +++ /dev/null @@ -1,614 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.forms; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFMultiPropertiesBindingPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, EMFMultiPropertiesBindingPropertiesEditionPart { - - protected Text name; - protected ReferencesTable model; - protected List modelBusinessFilters = new ArrayList(); - protected List modelFilters = new ArrayList(); - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * For {@link ISection} use only. - */ - public EMFMultiPropertiesBindingPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EMFMultiPropertiesBindingPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence eMFMultiPropertiesBindingStep = new BindingCompositionSequence(propertiesEditionComponent); - eMFMultiPropertiesBindingStep - .addStep(MappingViewsRepository.EMFMultiPropertiesBinding.Properties.class) - .addStep(MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name); - - CompositionStep bindingStep = eMFMultiPropertiesBindingStep.addStep(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.class); - bindingStep.addStep(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model); - bindingStep.addStep(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views); - - - composer = new PartComposer(eMFMultiPropertiesBindingStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name) { - return createNameText(widgetFactory, parent); - } - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model) { - return createModelReferencesTable(widgetFactory, parent); - } - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views) { - return createViewsReferencesTable(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(MappingMessages.EMFMultiPropertiesBindingPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name, MappingMessages.EMFMultiPropertiesBindingPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EMFMultiPropertiesBindingPropertiesEditionPartForm.this, - MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EMFMultiPropertiesBindingPropertiesEditionPartForm.this, - MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EMFMultiPropertiesBindingPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(MappingMessages.EMFMultiPropertiesBindingPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * - */ - protected Composite createModelReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.model = new ReferencesTable(getDescription(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, MappingMessages.EMFMultiPropertiesBindingPropertiesEditionPart_ModelLabel), new ReferencesTableListener () { - public void handleAdd() { addModel(); } - public void handleEdit(EObject element) { editModel(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveModel(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromModel(element); } - public void navigateTo(EObject element) { } - }); - this.model.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, MappingViewsRepository.FORM_KIND)); - this.model.createControls(parent, widgetFactory); - this.model.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - modelData.horizontalSpan = 3; - this.model.setLayoutData(modelData); - this.model.disableMove(); - model.setID(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model); - model.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - // Start of user code for createModelReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected void addModel() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(model.getInput(), modelFilters, modelBusinessFilters, - "model", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - model.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveModel(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - model.refresh(); - } - - /** - * - */ - protected void removeFromModel(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - model.refresh(); - } - - /** - * - */ - protected void editModel(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - model.refresh(); - } - } - } - - /** - * - */ - protected Composite createViewsReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.views = new ReferencesTable(getDescription(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, MappingMessages.EMFMultiPropertiesBindingPropertiesEditionPart_ViewsLabel), new ReferencesTableListener () { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, MappingViewsRepository.FORM_KIND)); - this.views.createControls(parent, widgetFactory); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - // Start of user code for createViewsReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.EMFMultiPropertiesBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#initModel(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initModel(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - model.setContentProvider(contentProvider); - model.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.getTable().isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.EMFMultiPropertiesBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.getTable().isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#updateModel() - * - */ - public void updateModel() { - model.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - modelFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - modelBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#isContainedInModelTable(EObject element) - * - */ - public boolean isContainedInModelTable(EObject element) { - return ((ReferencesTableSettings)model.getInput()).contains(element); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(MappingMessages.EMFMultiPropertiesBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.EMFMultiPropertiesBinding_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFPropertyBindingPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFPropertyBindingPropertiesEditionPartForm.java deleted file mode 100644 index c85900e0b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/EMFPropertyBindingPropertiesEditionPartForm.java +++ /dev/null @@ -1,591 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.forms; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFPropertyBindingPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, EMFPropertyBindingPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * For {@link ISection} use only. - */ - public EMFPropertyBindingPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EMFPropertyBindingPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence eMFPropertyBindingStep = new BindingCompositionSequence(propertiesEditionComponent); - eMFPropertyBindingStep - .addStep(MappingViewsRepository.EMFPropertyBinding.Properties.class) - .addStep(MappingViewsRepository.EMFPropertyBinding.Properties.name); - - CompositionStep bindingStep = eMFPropertyBindingStep.addStep(MappingViewsRepository.EMFPropertyBinding.Binding.class); - bindingStep.addStep(MappingViewsRepository.EMFPropertyBinding.Binding.model); - bindingStep.addStep(MappingViewsRepository.EMFPropertyBinding.Binding.views); - - - composer = new PartComposer(eMFPropertyBindingStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.EMFPropertyBinding.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.EMFPropertyBinding.Properties.name) { - return createNameText(widgetFactory, parent); - } - if (key == MappingViewsRepository.EMFPropertyBinding.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.EMFPropertyBinding.Binding.model) { - return createModelFlatComboViewer(parent, widgetFactory); - } - if (key == MappingViewsRepository.EMFPropertyBinding.Binding.views) { - return createViewsReferencesTable(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(MappingMessages.EMFPropertyBindingPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, MappingViewsRepository.EMFPropertyBinding.Properties.name, MappingMessages.EMFPropertyBindingPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - EMFPropertyBindingPropertiesEditionPartForm.this, - MappingViewsRepository.EMFPropertyBinding.Properties.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EMFPropertyBindingPropertiesEditionPartForm.this, - MappingViewsRepository.EMFPropertyBinding.Properties.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - EMFPropertyBindingPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFPropertyBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, MappingViewsRepository.EMFPropertyBinding.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFPropertyBinding.Properties.name, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(MappingMessages.EMFPropertyBindingPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createModelFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, MappingViewsRepository.EMFPropertyBinding.Binding.model, MappingMessages.EMFPropertyBindingPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(MappingViewsRepository.EMFPropertyBinding.Binding.model, MappingViewsRepository.FORM_KIND)); - widgetFactory.adapt(model); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFPropertyBinding.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - model.setID(MappingViewsRepository.EMFPropertyBinding.Binding.model); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFPropertyBinding.Binding.model, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.views = new ReferencesTable(getDescription(MappingViewsRepository.EMFPropertyBinding.Binding.views, MappingMessages.EMFPropertyBindingPropertiesEditionPart_ViewsLabel), new ReferencesTableListener () { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFPropertyBinding.Binding.views, MappingViewsRepository.FORM_KIND)); - this.views.createControls(parent, widgetFactory); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFPropertyBinding.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(MappingViewsRepository.EMFPropertyBinding.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - // Start of user code for createViewsReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFPropertyBinding.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFPropertyBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.EMFPropertyBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFPropertyBinding.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.EMFPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFPropertyBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.EMFPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFPropertyBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.EMFPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFPropertyBinding.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(MappingMessages.EMFPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.EMFPropertyBinding_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/ElementBindingReferencePropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/ElementBindingReferencePropertiesEditionPartForm.java deleted file mode 100644 index 5acec172a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/ElementBindingReferencePropertiesEditionPartForm.java +++ /dev/null @@ -1,287 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class ElementBindingReferencePropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, ElementBindingReferencePropertiesEditionPart { - - protected EObjectFlatComboViewer binding; - - - - /** - * For {@link ISection} use only. - */ - public ElementBindingReferencePropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public ElementBindingReferencePropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence elementBindingReferenceStep = new BindingCompositionSequence(propertiesEditionComponent); - elementBindingReferenceStep - .addStep(MappingViewsRepository.ElementBindingReference.Reference.class) - .addStep(MappingViewsRepository.ElementBindingReference.Reference.binding); - - - composer = new PartComposer(elementBindingReferenceStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.ElementBindingReference.Reference.class) { - return createReferenceGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.ElementBindingReference.Reference.binding) { - return createBindingFlatComboViewer(parent, widgetFactory); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createReferenceGroup(FormToolkit widgetFactory, final Composite parent) { - Section referenceSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - referenceSection.setText(MappingMessages.ElementBindingReferencePropertiesEditionPart_ReferenceGroupLabel); - GridData referenceSectionData = new GridData(GridData.FILL_HORIZONTAL); - referenceSectionData.horizontalSpan = 3; - referenceSection.setLayoutData(referenceSectionData); - Composite referenceGroup = widgetFactory.createComposite(referenceSection); - GridLayout referenceGroupLayout = new GridLayout(); - referenceGroupLayout.numColumns = 3; - referenceGroup.setLayout(referenceGroupLayout); - referenceSection.setClient(referenceGroup); - return referenceGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createBindingFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, MappingViewsRepository.ElementBindingReference.Reference.binding, MappingMessages.ElementBindingReferencePropertiesEditionPart_BindingLabel); - binding = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(MappingViewsRepository.ElementBindingReference.Reference.binding, MappingViewsRepository.FORM_KIND)); - widgetFactory.adapt(binding); - binding.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData bindingData = new GridData(GridData.FILL_HORIZONTAL); - binding.setLayoutData(bindingData); - binding.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(ElementBindingReferencePropertiesEditionPartForm.this, MappingViewsRepository.ElementBindingReference.Reference.binding, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getBinding())); - } - - }); - binding.setID(MappingViewsRepository.ElementBindingReference.Reference.binding); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.ElementBindingReference.Reference.binding, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createBindingFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#getBinding() - * - */ - public EObject getBinding() { - if (binding.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) binding.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#initBinding(EObjectFlatComboSettings) - */ - public void initBinding(EObjectFlatComboSettings settings) { - binding.setInput(settings); - if (current != null) { - binding.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.ElementBindingReference.Reference.binding); - if (eefElementEditorReadOnlyState && binding.isEnabled()) { - binding.setEnabled(false); - binding.setToolTipText(MappingMessages.ElementBindingReference_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !binding.isEnabled()) { - binding.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#setBinding(EObject newValue) - * - */ - public void setBinding(EObject newValue) { - if (newValue != null) { - binding.setSelection(new StructuredSelection(newValue)); - } else { - binding.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.ElementBindingReference.Reference.binding); - if (eefElementEditorReadOnlyState && binding.isEnabled()) { - binding.setEnabled(false); - binding.setToolTipText(MappingMessages.ElementBindingReference_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !binding.isEnabled()) { - binding.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#setBindingButtonMode(ButtonsModeEnum newValue) - */ - public void setBindingButtonMode(ButtonsModeEnum newValue) { - binding.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#addFilterBinding(ViewerFilter filter) - * - */ - public void addFilterToBinding(ViewerFilter filter) { - binding.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#addBusinessFilterBinding(ViewerFilter filter) - * - */ - public void addBusinessFilterToBinding(ViewerFilter filter) { - binding.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.ElementBindingReference_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/FilterPropertiesPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/FilterPropertiesPropertiesEditionPartForm.java deleted file mode 100644 index ebf5dccd4..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/FilterPropertiesPropertiesEditionPartForm.java +++ /dev/null @@ -1,335 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class FilterPropertiesPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, FilterPropertiesPropertiesEditionPart { - - protected Text name; - protected Button mandatory; - - - - /** - * For {@link ISection} use only. - */ - public FilterPropertiesPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public FilterPropertiesPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence filterPropertiesStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep filterProperties_Step = filterPropertiesStep.addStep(MappingViewsRepository.FilterProperties.FilterProperties_.class); - filterProperties_Step.addStep(MappingViewsRepository.FilterProperties.FilterProperties_.name); - filterProperties_Step.addStep(MappingViewsRepository.FilterProperties.FilterProperties_.mandatory); - - - composer = new PartComposer(filterPropertiesStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.FilterProperties.FilterProperties_.class) { - return createFilterPropertiesGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.FilterProperties.FilterProperties_.name) { - return createNameText(widgetFactory, parent); - } - if (key == MappingViewsRepository.FilterProperties.FilterProperties_.mandatory) { - return createMandatoryCheckbox(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createFilterPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section filterPropertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - filterPropertiesSection.setText(MappingMessages.FilterPropertiesPropertiesEditionPart_FilterPropertiesGroupLabel); - GridData filterPropertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - filterPropertiesSectionData.horizontalSpan = 3; - filterPropertiesSection.setLayoutData(filterPropertiesSectionData); - Composite filterPropertiesGroup = widgetFactory.createComposite(filterPropertiesSection); - GridLayout filterPropertiesGroupLayout = new GridLayout(); - filterPropertiesGroupLayout.numColumns = 3; - filterPropertiesGroup.setLayout(filterPropertiesGroupLayout); - filterPropertiesSection.setClient(filterPropertiesGroup); - return filterPropertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, MappingViewsRepository.FilterProperties.FilterProperties_.name, MappingMessages.FilterPropertiesPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - FilterPropertiesPropertiesEditionPartForm.this, - MappingViewsRepository.FilterProperties.FilterProperties_.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - FilterPropertiesPropertiesEditionPartForm.this, - MappingViewsRepository.FilterProperties.FilterProperties_.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - FilterPropertiesPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(FilterPropertiesPropertiesEditionPartForm.this, MappingViewsRepository.FilterProperties.FilterProperties_.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, MappingViewsRepository.FilterProperties.FilterProperties_.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.FilterProperties.FilterProperties_.name, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createMandatoryCheckbox(FormToolkit widgetFactory, Composite parent) { - mandatory = widgetFactory.createButton(parent, getDescription(MappingViewsRepository.FilterProperties.FilterProperties_.mandatory, MappingMessages.FilterPropertiesPropertiesEditionPart_MandatoryLabel), SWT.CHECK); - mandatory.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(FilterPropertiesPropertiesEditionPartForm.this, MappingViewsRepository.FilterProperties.FilterProperties_.mandatory, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(mandatory.getSelection()))); - } - - }); - GridData mandatoryData = new GridData(GridData.FILL_HORIZONTAL); - mandatoryData.horizontalSpan = 2; - mandatory.setLayoutData(mandatoryData); - EditingUtils.setID(mandatory, MappingViewsRepository.FilterProperties.FilterProperties_.mandatory); - EditingUtils.setEEFtype(mandatory, "eef::Checkbox"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.FilterProperties.FilterProperties_.mandatory, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createMandatoryCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.FilterPropertiesPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.FilterPropertiesPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.FilterProperties.FilterProperties_.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.FilterProperties_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.FilterPropertiesPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return Boolean.valueOf(mandatory.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.FilterPropertiesPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - if (newValue != null) { - mandatory.setSelection(newValue.booleanValue()); - } else { - mandatory.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.FilterProperties.FilterProperties_.mandatory); - if (eefElementEditorReadOnlyState && mandatory.isEnabled()) { - mandatory.setEnabled(false); - mandatory.setToolTipText(MappingMessages.FilterProperties_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !mandatory.isEnabled()) { - mandatory.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.FilterProperties_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/StandardElementBindingPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/StandardElementBindingPropertiesEditionPartForm.java deleted file mode 100644 index 3b4779997..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/StandardElementBindingPropertiesEditionPartForm.java +++ /dev/null @@ -1,591 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.forms; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StandardElementBindingPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, StandardElementBindingPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * For {@link ISection} use only. - */ - public StandardElementBindingPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public StandardElementBindingPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence standardElementBindingStep = new BindingCompositionSequence(propertiesEditionComponent); - standardElementBindingStep - .addStep(MappingViewsRepository.StandardElementBinding.Properties.class) - .addStep(MappingViewsRepository.StandardElementBinding.Properties.name); - - CompositionStep bindingStep = standardElementBindingStep.addStep(MappingViewsRepository.StandardElementBinding.Binding.class); - bindingStep.addStep(MappingViewsRepository.StandardElementBinding.Binding.model); - bindingStep.addStep(MappingViewsRepository.StandardElementBinding.Binding.views); - - - composer = new PartComposer(standardElementBindingStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.StandardElementBinding.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.StandardElementBinding.Properties.name) { - return createNameText(widgetFactory, parent); - } - if (key == MappingViewsRepository.StandardElementBinding.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.StandardElementBinding.Binding.model) { - return createModelFlatComboViewer(parent, widgetFactory); - } - if (key == MappingViewsRepository.StandardElementBinding.Binding.views) { - return createViewsReferencesTable(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(MappingMessages.StandardElementBindingPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, MappingViewsRepository.StandardElementBinding.Properties.name, MappingMessages.StandardElementBindingPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - StandardElementBindingPropertiesEditionPartForm.this, - MappingViewsRepository.StandardElementBinding.Properties.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - StandardElementBindingPropertiesEditionPartForm.this, - MappingViewsRepository.StandardElementBinding.Properties.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - StandardElementBindingPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardElementBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, MappingViewsRepository.StandardElementBinding.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardElementBinding.Properties.name, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(MappingMessages.StandardElementBindingPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createModelFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, MappingViewsRepository.StandardElementBinding.Binding.model, MappingMessages.StandardElementBindingPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(MappingViewsRepository.StandardElementBinding.Binding.model, MappingViewsRepository.FORM_KIND)); - widgetFactory.adapt(model); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardElementBinding.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - model.setID(MappingViewsRepository.StandardElementBinding.Binding.model); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardElementBinding.Binding.model, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.views = new ReferencesTable(getDescription(MappingViewsRepository.StandardElementBinding.Binding.views, MappingMessages.StandardElementBindingPropertiesEditionPart_ViewsLabel), new ReferencesTableListener () { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardElementBinding.Binding.views, MappingViewsRepository.FORM_KIND)); - this.views.createControls(parent, widgetFactory); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardElementBinding.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(MappingViewsRepository.StandardElementBinding.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - // Start of user code for createViewsReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardElementBinding.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardElementBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardElementBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardElementBinding.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.StandardElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardElementBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.StandardElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardElementBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.StandardElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardElementBinding.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(MappingMessages.StandardElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.StandardElementBinding_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/StandardPropertyBindingPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/StandardPropertyBindingPropertiesEditionPartForm.java deleted file mode 100644 index 5fbc5624c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/forms/StandardPropertyBindingPropertiesEditionPartForm.java +++ /dev/null @@ -1,591 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.forms; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; -import org.eclipse.ui.views.properties.tabbed.ISection; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StandardPropertyBindingPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, StandardPropertyBindingPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * For {@link ISection} use only. - */ - public StandardPropertyBindingPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public StandardPropertyBindingPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence standardPropertyBindingStep = new BindingCompositionSequence(propertiesEditionComponent); - standardPropertyBindingStep - .addStep(MappingViewsRepository.StandardPropertyBinding.Properties.class) - .addStep(MappingViewsRepository.StandardPropertyBinding.Properties.name); - - CompositionStep bindingStep = standardPropertyBindingStep.addStep(MappingViewsRepository.StandardPropertyBinding.Binding.class); - bindingStep.addStep(MappingViewsRepository.StandardPropertyBinding.Binding.model); - bindingStep.addStep(MappingViewsRepository.StandardPropertyBinding.Binding.views); - - - composer = new PartComposer(standardPropertyBindingStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.StandardPropertyBinding.Properties.class) { - return createPropertiesGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.StandardPropertyBinding.Properties.name) { - return createNameText(widgetFactory, parent); - } - if (key == MappingViewsRepository.StandardPropertyBinding.Binding.class) { - return createBindingGroup(widgetFactory, parent); - } - if (key == MappingViewsRepository.StandardPropertyBinding.Binding.model) { - return createModelFlatComboViewer(parent, widgetFactory); - } - if (key == MappingViewsRepository.StandardPropertyBinding.Binding.views) { - return createViewsReferencesTable(widgetFactory, parent); - } - return parent; - } - }; - composer.compose(view); - } - /** - * - */ - protected Composite createPropertiesGroup(FormToolkit widgetFactory, final Composite parent) { - Section propertiesSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - propertiesSection.setText(MappingMessages.StandardPropertyBindingPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesSectionData = new GridData(GridData.FILL_HORIZONTAL); - propertiesSectionData.horizontalSpan = 3; - propertiesSection.setLayoutData(propertiesSectionData); - Composite propertiesGroup = widgetFactory.createComposite(propertiesSection); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - propertiesSection.setClient(propertiesGroup); - return propertiesGroup; - } - - - protected Composite createNameText(FormToolkit widgetFactory, Composite parent) { - createDescription(parent, MappingViewsRepository.StandardPropertyBinding.Properties.name, MappingMessages.StandardPropertyBindingPropertiesEditionPart_NameLabel); - name = widgetFactory.createText(parent, ""); //$NON-NLS-1$ - name.setData(FormToolkit.KEY_DRAW_BORDER, FormToolkit.TEXT_BORDER); - widgetFactory.paintBordersFor(parent); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - /** - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - StandardPropertyBindingPropertiesEditionPartForm.this, - MappingViewsRepository.StandardPropertyBinding.Properties.name, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - StandardPropertyBindingPropertiesEditionPartForm.this, - MappingViewsRepository.StandardPropertyBinding.Properties.name, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_LOST, - null, name.getText())); - } - } - - /** - * @see org.eclipse.swt.events.FocusAdapter#focusGained(org.eclipse.swt.events.FocusEvent) - */ - @Override - public void focusGained(FocusEvent e) { - if (propertiesEditionComponent != null) { - propertiesEditionComponent - .firePropertiesChanged(new PropertiesEditionEvent( - StandardPropertyBindingPropertiesEditionPartForm.this, - null, - PropertiesEditionEvent.FOCUS_CHANGED, PropertiesEditionEvent.FOCUS_GAINED, - null, null)); - } - } - }); - name.addKeyListener(new KeyAdapter() { - /** - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardPropertyBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - }); - EditingUtils.setID(name, MappingViewsRepository.StandardPropertyBinding.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardPropertyBinding.Properties.name, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(FormToolkit widgetFactory, final Composite parent) { - Section bindingSection = widgetFactory.createSection(parent, Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED); - bindingSection.setText(MappingMessages.StandardPropertyBindingPropertiesEditionPart_BindingGroupLabel); - GridData bindingSectionData = new GridData(GridData.FILL_HORIZONTAL); - bindingSectionData.horizontalSpan = 3; - bindingSection.setLayoutData(bindingSectionData); - Composite bindingGroup = widgetFactory.createComposite(bindingSection); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - bindingSection.setClient(bindingGroup); - return bindingGroup; - } - - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createModelFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, MappingViewsRepository.StandardPropertyBinding.Binding.model, MappingMessages.StandardPropertyBindingPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(MappingViewsRepository.StandardPropertyBinding.Binding.model, MappingViewsRepository.FORM_KIND)); - widgetFactory.adapt(model); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardPropertyBinding.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - model.setID(MappingViewsRepository.StandardPropertyBinding.Binding.model); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardPropertyBinding.Binding.model, MappingViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsReferencesTable(FormToolkit widgetFactory, Composite parent) { - this.views = new ReferencesTable(getDescription(MappingViewsRepository.StandardPropertyBinding.Binding.views, MappingMessages.StandardPropertyBindingPropertiesEditionPart_ViewsLabel), new ReferencesTableListener () { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardPropertyBinding.Binding.views, MappingViewsRepository.FORM_KIND)); - this.views.createControls(parent, widgetFactory); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardPropertyBinding.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(MappingViewsRepository.StandardPropertyBinding.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - // Start of user code for createViewsReferencesTable - - // End of user code - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardPropertyBinding.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardPropertyBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartForm.this, MappingViewsRepository.StandardPropertyBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardPropertyBinding.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.StandardPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardPropertyBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.StandardPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardPropertyBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.StandardPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardPropertyBinding.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(MappingMessages.StandardPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.StandardPropertyBinding_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/CategoryPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/CategoryPropertiesEditionPartImpl.java deleted file mode 100644 index b9ca8fa9c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/CategoryPropertiesEditionPartImpl.java +++ /dev/null @@ -1,235 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.parts.CategoryPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class CategoryPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, CategoryPropertiesEditionPart { - - protected Text name; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public CategoryPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence categoryStep = new BindingCompositionSequence(propertiesEditionComponent); - categoryStep - .addStep(MappingViewsRepository.Category.Properties.class) - .addStep(MappingViewsRepository.Category.Properties.name); - - - composer = new PartComposer(categoryStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.Category.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == MappingViewsRepository.Category.Properties.name) { - return createNameText(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(MappingMessages.CategoryPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, MappingViewsRepository.Category.Properties.name, MappingMessages.CategoryPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(CategoryPropertiesEditionPartImpl.this, MappingViewsRepository.Category.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(CategoryPropertiesEditionPartImpl.this, MappingViewsRepository.Category.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, MappingViewsRepository.Category.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.Category.Properties.name, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.CategoryPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.CategoryPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.Category.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.Category_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.Category_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/DocumentationPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/DocumentationPropertiesEditionPartImpl.java deleted file mode 100644 index 1baeb1c31..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/DocumentationPropertiesEditionPartImpl.java +++ /dev/null @@ -1,221 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.parts.DocumentationPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class DocumentationPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, DocumentationPropertiesEditionPart { - - protected Text documentation; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public DocumentationPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence documentationStep = new BindingCompositionSequence(propertiesEditionComponent); - documentationStep - .addStep(MappingViewsRepository.Documentation.Documentation_.class) - .addStep(MappingViewsRepository.Documentation.Documentation_.documentation__); - - - composer = new PartComposer(documentationStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.Documentation.Documentation_.class) { - return createDocumentationGroup(parent); - } - if (key == MappingViewsRepository.Documentation.Documentation_.documentation__) { - return createDocumentationTextarea(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createDocumentationGroup(Composite parent) { - Group documentationGroup = new Group(parent, SWT.NONE); - documentationGroup.setText(MappingMessages.DocumentationPropertiesEditionPart_DocumentationGroupLabel); - GridData documentationGroupData = new GridData(GridData.FILL_HORIZONTAL); - documentationGroupData.horizontalSpan = 3; - documentationGroup.setLayoutData(documentationGroupData); - GridLayout documentationGroupLayout = new GridLayout(); - documentationGroupLayout.numColumns = 3; - documentationGroup.setLayout(documentationGroupLayout); - return documentationGroup; - } - - - protected Composite createDocumentationTextarea(Composite parent) { - Label documentationLabel = createDescription(parent, MappingViewsRepository.Documentation.Documentation_.documentation__, MappingMessages.DocumentationPropertiesEditionPart_DocumentationLabel); - GridData documentationLabelData = new GridData(GridData.FILL_HORIZONTAL); - documentationLabelData.horizontalSpan = 3; - documentationLabel.setLayoutData(documentationLabelData); - documentation = SWTUtils.createScrollableText(parent, SWT.BORDER | SWT.WRAP | SWT.MULTI | SWT.V_SCROLL); - GridData documentationData = new GridData(GridData.FILL_HORIZONTAL); - documentationData.horizontalSpan = 2; - documentationData.heightHint = 80; - documentationData.widthHint = 200; - documentation.setLayoutData(documentationData); - documentation.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(DocumentationPropertiesEditionPartImpl.this, MappingViewsRepository.Documentation.Documentation_.documentation__, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, documentation.getText())); - } - - }); - EditingUtils.setID(documentation, MappingViewsRepository.Documentation.Documentation_.documentation__); - EditingUtils.setEEFtype(documentation, "eef::Textarea"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.Documentation.Documentation_.documentation__, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createDocumentationTextArea - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.DocumentationPropertiesEditionPart#getDocumentation() - * - */ - public String getDocumentation() { - return documentation.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.DocumentationPropertiesEditionPart#setDocumentation(String newValue) - * - */ - public void setDocumentation(String newValue) { - if (newValue != null) { - documentation.setText(newValue); - } else { - documentation.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.Documentation.Documentation_.documentation__); - if (eefElementEditorReadOnlyState && documentation.isEnabled()) { - documentation.setEnabled(false); - documentation.setBackground(documentation.getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND)); - documentation.setToolTipText(MappingMessages.Documentation_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !documentation.isEnabled()) { - documentation.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.Documentation_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFElementBindingPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFElementBindingPropertiesEditionPartImpl.java deleted file mode 100644 index a886c3ce6..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFElementBindingPropertiesEditionPartImpl.java +++ /dev/null @@ -1,549 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.impl; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFElementBindingPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, EMFElementBindingPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EMFElementBindingPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence eMFElementBindingStep = new BindingCompositionSequence(propertiesEditionComponent); - eMFElementBindingStep - .addStep(MappingViewsRepository.EMFElementBinding.Properties.class) - .addStep(MappingViewsRepository.EMFElementBinding.Properties.name); - - CompositionStep bindingStep = eMFElementBindingStep.addStep(MappingViewsRepository.EMFElementBinding.Binding.class); - bindingStep.addStep(MappingViewsRepository.EMFElementBinding.Binding.model); - bindingStep.addStep(MappingViewsRepository.EMFElementBinding.Binding.views); - - - composer = new PartComposer(eMFElementBindingStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.EMFElementBinding.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == MappingViewsRepository.EMFElementBinding.Properties.name) { - return createNameText(parent); - } - if (key == MappingViewsRepository.EMFElementBinding.Binding.class) { - return createBindingGroup(parent); - } - if (key == MappingViewsRepository.EMFElementBinding.Binding.model) { - return createModelFlatComboViewer(parent); - } - if (key == MappingViewsRepository.EMFElementBinding.Binding.views) { - return createViewsAdvancedReferencesTable(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(MappingMessages.EMFElementBindingPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, MappingViewsRepository.EMFElementBinding.Properties.name, MappingMessages.EMFElementBindingPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFElementBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFElementBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, MappingViewsRepository.EMFElementBinding.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFElementBinding.Properties.name, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(MappingMessages.EMFElementBindingPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createModelFlatComboViewer(Composite parent) { - createDescription(parent, MappingViewsRepository.EMFElementBinding.Binding.model, MappingMessages.EMFElementBindingPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(MappingViewsRepository.EMFElementBinding.Binding.model, MappingViewsRepository.SWT_KIND)); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - model.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFElementBinding.Binding.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.setID(MappingViewsRepository.EMFElementBinding.Binding.model); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFElementBinding.Binding.model, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsAdvancedReferencesTable(Composite parent) { - String label = getDescription(MappingViewsRepository.EMFElementBinding.Binding.views, MappingMessages.EMFElementBindingPropertiesEditionPart_ViewsLabel); - this.views = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFElementBinding.Binding.views, MappingViewsRepository.SWT_KIND)); - this.views.createControls(parent); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFElementBinding.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(MappingViewsRepository.EMFElementBinding.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFElementBinding.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFElementBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFElementBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFElementBinding.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.EMFElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFElementBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.EMFElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFElementBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.EMFElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFElementBinding.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(MappingMessages.EMFElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFElementBindingPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.EMFElementBinding_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFMultiPropertiesBindingPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFMultiPropertiesBindingPropertiesEditionPartImpl.java deleted file mode 100644 index 053dc2269..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFMultiPropertiesBindingPropertiesEditionPartImpl.java +++ /dev/null @@ -1,577 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.impl; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFMultiPropertiesBindingPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, EMFMultiPropertiesBindingPropertiesEditionPart { - - protected Text name; - protected ReferencesTable model; - protected List modelBusinessFilters = new ArrayList(); - protected List modelFilters = new ArrayList(); - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EMFMultiPropertiesBindingPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence eMFMultiPropertiesBindingStep = new BindingCompositionSequence(propertiesEditionComponent); - eMFMultiPropertiesBindingStep - .addStep(MappingViewsRepository.EMFMultiPropertiesBinding.Properties.class) - .addStep(MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name); - - CompositionStep bindingStep = eMFMultiPropertiesBindingStep.addStep(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.class); - bindingStep.addStep(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model); - bindingStep.addStep(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views); - - - composer = new PartComposer(eMFMultiPropertiesBindingStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name) { - return createNameText(parent); - } - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.class) { - return createBindingGroup(parent); - } - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model) { - return createModelAdvancedReferencesTable(parent); - } - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views) { - return createViewsAdvancedReferencesTable(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(MappingMessages.EMFMultiPropertiesBindingPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name, MappingMessages.EMFMultiPropertiesBindingPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(MappingMessages.EMFMultiPropertiesBindingPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * - */ - protected Composite createModelAdvancedReferencesTable(Composite parent) { - String label = getDescription(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, MappingMessages.EMFMultiPropertiesBindingPropertiesEditionPart_ModelLabel); - this.model = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { addModel(); } - public void handleEdit(EObject element) { editModel(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveModel(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromModel(element); } - public void navigateTo(EObject element) { } - }); - this.model.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, MappingViewsRepository.SWT_KIND)); - this.model.createControls(parent); - this.model.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - modelData.horizontalSpan = 3; - this.model.setLayoutData(modelData); - this.model.disableMove(); - model.setID(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model); - model.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - return parent; - } - - /** - * - */ - protected void addModel() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(model.getInput(), modelFilters, modelBusinessFilters, - "model", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - model.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveModel(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - model.refresh(); - } - - /** - * - */ - protected void removeFromModel(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - model.refresh(); - } - - /** - * - */ - protected void editModel(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - model.refresh(); - } - } - } - - /** - * - */ - protected Composite createViewsAdvancedReferencesTable(Composite parent) { - String label = getDescription(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, MappingMessages.EMFMultiPropertiesBindingPropertiesEditionPart_ViewsLabel); - this.views = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, MappingViewsRepository.SWT_KIND)); - this.views.createControls(parent); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFMultiPropertiesBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFMultiPropertiesBinding.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.EMFMultiPropertiesBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#initModel(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initModel(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - model.setContentProvider(contentProvider); - model.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.getTable().isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.EMFMultiPropertiesBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.getTable().isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#updateModel() - * - */ - public void updateModel() { - model.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - modelFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - modelBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#isContainedInModelTable(EObject element) - * - */ - public boolean isContainedInModelTable(EObject element) { - return ((ReferencesTableSettings)model.getInput()).contains(element); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFMultiPropertiesBinding.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(MappingMessages.EMFMultiPropertiesBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFMultiPropertiesBindingPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.EMFMultiPropertiesBinding_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFPropertyBindingPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFPropertyBindingPropertiesEditionPartImpl.java deleted file mode 100644 index 9ce639dc2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/EMFPropertyBindingPropertiesEditionPartImpl.java +++ /dev/null @@ -1,549 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.impl; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EMFPropertyBindingPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, EMFPropertyBindingPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public EMFPropertyBindingPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence eMFPropertyBindingStep = new BindingCompositionSequence(propertiesEditionComponent); - eMFPropertyBindingStep - .addStep(MappingViewsRepository.EMFPropertyBinding.Properties.class) - .addStep(MappingViewsRepository.EMFPropertyBinding.Properties.name); - - CompositionStep bindingStep = eMFPropertyBindingStep.addStep(MappingViewsRepository.EMFPropertyBinding.Binding.class); - bindingStep.addStep(MappingViewsRepository.EMFPropertyBinding.Binding.model); - bindingStep.addStep(MappingViewsRepository.EMFPropertyBinding.Binding.views); - - - composer = new PartComposer(eMFPropertyBindingStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.EMFPropertyBinding.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == MappingViewsRepository.EMFPropertyBinding.Properties.name) { - return createNameText(parent); - } - if (key == MappingViewsRepository.EMFPropertyBinding.Binding.class) { - return createBindingGroup(parent); - } - if (key == MappingViewsRepository.EMFPropertyBinding.Binding.model) { - return createModelFlatComboViewer(parent); - } - if (key == MappingViewsRepository.EMFPropertyBinding.Binding.views) { - return createViewsAdvancedReferencesTable(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(MappingMessages.EMFPropertyBindingPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, MappingViewsRepository.EMFPropertyBinding.Properties.name, MappingMessages.EMFPropertyBindingPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFPropertyBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFPropertyBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, MappingViewsRepository.EMFPropertyBinding.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFPropertyBinding.Properties.name, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(MappingMessages.EMFPropertyBindingPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createModelFlatComboViewer(Composite parent) { - createDescription(parent, MappingViewsRepository.EMFPropertyBinding.Binding.model, MappingMessages.EMFPropertyBindingPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(MappingViewsRepository.EMFPropertyBinding.Binding.model, MappingViewsRepository.SWT_KIND)); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - model.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFPropertyBinding.Binding.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.setID(MappingViewsRepository.EMFPropertyBinding.Binding.model); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFPropertyBinding.Binding.model, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsAdvancedReferencesTable(Composite parent) { - String label = getDescription(MappingViewsRepository.EMFPropertyBinding.Binding.views, MappingMessages.EMFPropertyBindingPropertiesEditionPart_ViewsLabel); - this.views = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.EMFPropertyBinding.Binding.views, MappingViewsRepository.SWT_KIND)); - this.views.createControls(parent); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFPropertyBinding.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(MappingViewsRepository.EMFPropertyBinding.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFPropertyBinding.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFPropertyBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(EMFPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.EMFPropertyBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFPropertyBinding.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.EMFPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFPropertyBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.EMFPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFPropertyBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.EMFPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.EMFPropertyBinding.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(MappingMessages.EMFPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.EMFPropertyBindingPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.EMFPropertyBinding_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/ElementBindingReferencePropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/ElementBindingReferencePropertiesEditionPartImpl.java deleted file mode 100644 index 6f385f766..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/ElementBindingReferencePropertiesEditionPartImpl.java +++ /dev/null @@ -1,269 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class ElementBindingReferencePropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, ElementBindingReferencePropertiesEditionPart { - - protected EObjectFlatComboViewer binding; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public ElementBindingReferencePropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence elementBindingReferenceStep = new BindingCompositionSequence(propertiesEditionComponent); - elementBindingReferenceStep - .addStep(MappingViewsRepository.ElementBindingReference.Reference.class) - .addStep(MappingViewsRepository.ElementBindingReference.Reference.binding); - - - composer = new PartComposer(elementBindingReferenceStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.ElementBindingReference.Reference.class) { - return createReferenceGroup(parent); - } - if (key == MappingViewsRepository.ElementBindingReference.Reference.binding) { - return createBindingFlatComboViewer(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createReferenceGroup(Composite parent) { - Group referenceGroup = new Group(parent, SWT.NONE); - referenceGroup.setText(MappingMessages.ElementBindingReferencePropertiesEditionPart_ReferenceGroupLabel); - GridData referenceGroupData = new GridData(GridData.FILL_HORIZONTAL); - referenceGroupData.horizontalSpan = 3; - referenceGroup.setLayoutData(referenceGroupData); - GridLayout referenceGroupLayout = new GridLayout(); - referenceGroupLayout.numColumns = 3; - referenceGroup.setLayout(referenceGroupLayout); - return referenceGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createBindingFlatComboViewer(Composite parent) { - createDescription(parent, MappingViewsRepository.ElementBindingReference.Reference.binding, MappingMessages.ElementBindingReferencePropertiesEditionPart_BindingLabel); - binding = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(MappingViewsRepository.ElementBindingReference.Reference.binding, MappingViewsRepository.SWT_KIND)); - binding.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - binding.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(ElementBindingReferencePropertiesEditionPartImpl.this, MappingViewsRepository.ElementBindingReference.Reference.binding, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getBinding())); - } - - }); - GridData bindingData = new GridData(GridData.FILL_HORIZONTAL); - binding.setLayoutData(bindingData); - binding.setID(MappingViewsRepository.ElementBindingReference.Reference.binding); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.ElementBindingReference.Reference.binding, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createBindingFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#getBinding() - * - */ - public EObject getBinding() { - if (binding.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) binding.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#initBinding(EObjectFlatComboSettings) - */ - public void initBinding(EObjectFlatComboSettings settings) { - binding.setInput(settings); - if (current != null) { - binding.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.ElementBindingReference.Reference.binding); - if (eefElementEditorReadOnlyState && binding.isEnabled()) { - binding.setEnabled(false); - binding.setToolTipText(MappingMessages.ElementBindingReference_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !binding.isEnabled()) { - binding.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#setBinding(EObject newValue) - * - */ - public void setBinding(EObject newValue) { - if (newValue != null) { - binding.setSelection(new StructuredSelection(newValue)); - } else { - binding.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.ElementBindingReference.Reference.binding); - if (eefElementEditorReadOnlyState && binding.isEnabled()) { - binding.setEnabled(false); - binding.setToolTipText(MappingMessages.ElementBindingReference_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !binding.isEnabled()) { - binding.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#setBindingButtonMode(ButtonsModeEnum newValue) - */ - public void setBindingButtonMode(ButtonsModeEnum newValue) { - binding.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#addFilterBinding(ViewerFilter filter) - * - */ - public void addFilterToBinding(ViewerFilter filter) { - binding.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.ElementBindingReferencePropertiesEditionPart#addBusinessFilterBinding(ViewerFilter filter) - * - */ - public void addBusinessFilterToBinding(ViewerFilter filter) { - binding.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.ElementBindingReference_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/FilterPropertiesPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/FilterPropertiesPropertiesEditionPartImpl.java deleted file mode 100644 index dfeb3c6a1..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/FilterPropertiesPropertiesEditionPartImpl.java +++ /dev/null @@ -1,305 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.eef.mapping.parts.FilterPropertiesPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class FilterPropertiesPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, FilterPropertiesPropertiesEditionPart { - - protected Text name; - protected Button mandatory; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public FilterPropertiesPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence filterPropertiesStep = new BindingCompositionSequence(propertiesEditionComponent); - CompositionStep filterProperties_Step = filterPropertiesStep.addStep(MappingViewsRepository.FilterProperties.FilterProperties_.class); - filterProperties_Step.addStep(MappingViewsRepository.FilterProperties.FilterProperties_.name); - filterProperties_Step.addStep(MappingViewsRepository.FilterProperties.FilterProperties_.mandatory); - - - composer = new PartComposer(filterPropertiesStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.FilterProperties.FilterProperties_.class) { - return createFilterPropertiesGroup(parent); - } - if (key == MappingViewsRepository.FilterProperties.FilterProperties_.name) { - return createNameText(parent); - } - if (key == MappingViewsRepository.FilterProperties.FilterProperties_.mandatory) { - return createMandatoryCheckbox(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createFilterPropertiesGroup(Composite parent) { - Group filterPropertiesGroup = new Group(parent, SWT.NONE); - filterPropertiesGroup.setText(MappingMessages.FilterPropertiesPropertiesEditionPart_FilterPropertiesGroupLabel); - GridData filterPropertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - filterPropertiesGroupData.horizontalSpan = 3; - filterPropertiesGroup.setLayoutData(filterPropertiesGroupData); - GridLayout filterPropertiesGroupLayout = new GridLayout(); - filterPropertiesGroupLayout.numColumns = 3; - filterPropertiesGroup.setLayout(filterPropertiesGroupLayout); - return filterPropertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, MappingViewsRepository.FilterProperties.FilterProperties_.name, MappingMessages.FilterPropertiesPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(FilterPropertiesPropertiesEditionPartImpl.this, MappingViewsRepository.FilterProperties.FilterProperties_.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(FilterPropertiesPropertiesEditionPartImpl.this, MappingViewsRepository.FilterProperties.FilterProperties_.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, MappingViewsRepository.FilterProperties.FilterProperties_.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.FilterProperties.FilterProperties_.name, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - - protected Composite createMandatoryCheckbox(Composite parent) { - mandatory = new Button(parent, SWT.CHECK); - mandatory.setText(getDescription(MappingViewsRepository.FilterProperties.FilterProperties_.mandatory, MappingMessages.FilterPropertiesPropertiesEditionPart_MandatoryLabel)); - mandatory.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - * - */ - public void widgetSelected(SelectionEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(FilterPropertiesPropertiesEditionPartImpl.this, MappingViewsRepository.FilterProperties.FilterProperties_.mandatory, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, new Boolean(mandatory.getSelection()))); - } - - }); - GridData mandatoryData = new GridData(GridData.FILL_HORIZONTAL); - mandatoryData.horizontalSpan = 2; - mandatory.setLayoutData(mandatoryData); - EditingUtils.setID(mandatory, MappingViewsRepository.FilterProperties.FilterProperties_.mandatory); - EditingUtils.setEEFtype(mandatory, "eef::Checkbox"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.FilterProperties.FilterProperties_.mandatory, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createMandatoryCheckbox - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.FilterPropertiesPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.FilterPropertiesPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.FilterProperties.FilterProperties_.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.FilterProperties_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.FilterPropertiesPropertiesEditionPart#getMandatory() - * - */ - public Boolean getMandatory() { - return Boolean.valueOf(mandatory.getSelection()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.filters.parts.FilterPropertiesPropertiesEditionPart#setMandatory(Boolean newValue) - * - */ - public void setMandatory(Boolean newValue) { - if (newValue != null) { - mandatory.setSelection(newValue.booleanValue()); - } else { - mandatory.setSelection(false); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.FilterProperties.FilterProperties_.mandatory); - if (eefElementEditorReadOnlyState && mandatory.isEnabled()) { - mandatory.setEnabled(false); - mandatory.setToolTipText(MappingMessages.FilterProperties_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !mandatory.isEnabled()) { - mandatory.setEnabled(true); - } - - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.FilterProperties_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/StandardElementBindingPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/StandardElementBindingPropertiesEditionPartImpl.java deleted file mode 100644 index 93abece41..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/StandardElementBindingPropertiesEditionPartImpl.java +++ /dev/null @@ -1,549 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.impl; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StandardElementBindingPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, StandardElementBindingPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public StandardElementBindingPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence standardElementBindingStep = new BindingCompositionSequence(propertiesEditionComponent); - standardElementBindingStep - .addStep(MappingViewsRepository.StandardElementBinding.Properties.class) - .addStep(MappingViewsRepository.StandardElementBinding.Properties.name); - - CompositionStep bindingStep = standardElementBindingStep.addStep(MappingViewsRepository.StandardElementBinding.Binding.class); - bindingStep.addStep(MappingViewsRepository.StandardElementBinding.Binding.model); - bindingStep.addStep(MappingViewsRepository.StandardElementBinding.Binding.views); - - - composer = new PartComposer(standardElementBindingStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.StandardElementBinding.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == MappingViewsRepository.StandardElementBinding.Properties.name) { - return createNameText(parent); - } - if (key == MappingViewsRepository.StandardElementBinding.Binding.class) { - return createBindingGroup(parent); - } - if (key == MappingViewsRepository.StandardElementBinding.Binding.model) { - return createModelFlatComboViewer(parent); - } - if (key == MappingViewsRepository.StandardElementBinding.Binding.views) { - return createViewsAdvancedReferencesTable(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(MappingMessages.StandardElementBindingPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, MappingViewsRepository.StandardElementBinding.Properties.name, MappingMessages.StandardElementBindingPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardElementBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardElementBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, MappingViewsRepository.StandardElementBinding.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardElementBinding.Properties.name, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(MappingMessages.StandardElementBindingPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createModelFlatComboViewer(Composite parent) { - createDescription(parent, MappingViewsRepository.StandardElementBinding.Binding.model, MappingMessages.StandardElementBindingPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(MappingViewsRepository.StandardElementBinding.Binding.model, MappingViewsRepository.SWT_KIND)); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - model.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardElementBinding.Binding.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.setID(MappingViewsRepository.StandardElementBinding.Binding.model); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardElementBinding.Binding.model, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsAdvancedReferencesTable(Composite parent) { - String label = getDescription(MappingViewsRepository.StandardElementBinding.Binding.views, MappingMessages.StandardElementBindingPropertiesEditionPart_ViewsLabel); - this.views = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardElementBinding.Binding.views, MappingViewsRepository.SWT_KIND)); - this.views.createControls(parent); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardElementBinding.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(MappingViewsRepository.StandardElementBinding.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardElementBinding.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardElementBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardElementBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardElementBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardElementBinding.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.StandardElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardElementBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.StandardElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardElementBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.StandardElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardElementBinding.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(MappingMessages.StandardElementBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardElementBindingPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.StandardElementBinding_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/StandardPropertyBindingPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/StandardPropertyBindingPropertiesEditionPartImpl.java deleted file mode 100644 index dd7c9e3ee..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/parts/impl/StandardPropertyBindingPropertiesEditionPartImpl.java +++ /dev/null @@ -1,549 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.parts.impl; - -// Start of user code for imports -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.providers.MappingMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.TabElementTreeSelectionDialog; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.FocusAdapter; -import org.eclipse.swt.events.FocusEvent; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Text; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class StandardPropertyBindingPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, StandardPropertyBindingPropertiesEditionPart { - - protected Text name; - protected EObjectFlatComboViewer model; - protected ReferencesTable views; - protected List viewsBusinessFilters = new ArrayList(); - protected List viewsFilters = new ArrayList(); - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public StandardPropertyBindingPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence standardPropertyBindingStep = new BindingCompositionSequence(propertiesEditionComponent); - standardPropertyBindingStep - .addStep(MappingViewsRepository.StandardPropertyBinding.Properties.class) - .addStep(MappingViewsRepository.StandardPropertyBinding.Properties.name); - - CompositionStep bindingStep = standardPropertyBindingStep.addStep(MappingViewsRepository.StandardPropertyBinding.Binding.class); - bindingStep.addStep(MappingViewsRepository.StandardPropertyBinding.Binding.model); - bindingStep.addStep(MappingViewsRepository.StandardPropertyBinding.Binding.views); - - - composer = new PartComposer(standardPropertyBindingStep) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == MappingViewsRepository.StandardPropertyBinding.Properties.class) { - return createPropertiesGroup(parent); - } - if (key == MappingViewsRepository.StandardPropertyBinding.Properties.name) { - return createNameText(parent); - } - if (key == MappingViewsRepository.StandardPropertyBinding.Binding.class) { - return createBindingGroup(parent); - } - if (key == MappingViewsRepository.StandardPropertyBinding.Binding.model) { - return createModelFlatComboViewer(parent); - } - if (key == MappingViewsRepository.StandardPropertyBinding.Binding.views) { - return createViewsAdvancedReferencesTable(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * - */ - protected Composite createPropertiesGroup(Composite parent) { - Group propertiesGroup = new Group(parent, SWT.NONE); - propertiesGroup.setText(MappingMessages.StandardPropertyBindingPropertiesEditionPart_PropertiesGroupLabel); - GridData propertiesGroupData = new GridData(GridData.FILL_HORIZONTAL); - propertiesGroupData.horizontalSpan = 3; - propertiesGroup.setLayoutData(propertiesGroupData); - GridLayout propertiesGroupLayout = new GridLayout(); - propertiesGroupLayout.numColumns = 3; - propertiesGroup.setLayout(propertiesGroupLayout); - return propertiesGroup; - } - - - protected Composite createNameText(Composite parent) { - createDescription(parent, MappingViewsRepository.StandardPropertyBinding.Properties.name, MappingMessages.StandardPropertyBindingPropertiesEditionPart_NameLabel); - name = SWTUtils.createScrollableText(parent, SWT.BORDER); - GridData nameData = new GridData(GridData.FILL_HORIZONTAL); - name.setLayoutData(nameData); - name.addFocusListener(new FocusAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.FocusAdapter#focusLost(org.eclipse.swt.events.FocusEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void focusLost(FocusEvent e) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardPropertyBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - - }); - name.addKeyListener(new KeyAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.KeyAdapter#keyPressed(org.eclipse.swt.events.KeyEvent) - * - */ - @Override - @SuppressWarnings("synthetic-access") - public void keyPressed(KeyEvent e) { - if (e.character == SWT.CR) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardPropertyBinding.Properties.name, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, name.getText())); - } - } - - }); - EditingUtils.setID(name, MappingViewsRepository.StandardPropertyBinding.Properties.name); - EditingUtils.setEEFtype(name, "eef::Text"); //$NON-NLS-1$ - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardPropertyBinding.Properties.name, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createNameText - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createBindingGroup(Composite parent) { - Group bindingGroup = new Group(parent, SWT.NONE); - bindingGroup.setText(MappingMessages.StandardPropertyBindingPropertiesEditionPart_BindingGroupLabel); - GridData bindingGroupData = new GridData(GridData.FILL_HORIZONTAL); - bindingGroupData.horizontalSpan = 3; - bindingGroup.setLayoutData(bindingGroupData); - GridLayout bindingGroupLayout = new GridLayout(); - bindingGroupLayout.numColumns = 3; - bindingGroup.setLayout(bindingGroupLayout); - return bindingGroup; - } - - /** - * @param parent the parent composite - * - */ - protected Composite createModelFlatComboViewer(Composite parent) { - createDescription(parent, MappingViewsRepository.StandardPropertyBinding.Binding.model, MappingMessages.StandardPropertyBindingPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(MappingViewsRepository.StandardPropertyBinding.Binding.model, MappingViewsRepository.SWT_KIND)); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - model.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardPropertyBinding.Binding.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.setID(MappingViewsRepository.StandardPropertyBinding.Binding.model); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardPropertyBinding.Binding.model, MappingViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - /** - * - */ - protected Composite createViewsAdvancedReferencesTable(Composite parent) { - String label = getDescription(MappingViewsRepository.StandardPropertyBinding.Binding.views, MappingMessages.StandardPropertyBindingPropertiesEditionPart_ViewsLabel); - this.views = new ReferencesTable(label, new ReferencesTableListener() { - public void handleAdd() { addViews(); } - public void handleEdit(EObject element) { editViews(element); } - public void handleMove(EObject element, int oldIndex, int newIndex) { moveViews(element, oldIndex, newIndex); } - public void handleRemove(EObject element) { removeFromViews(element); } - public void navigateTo(EObject element) { } - }); - this.views.setHelpText(propertiesEditionComponent.getHelpContent(MappingViewsRepository.StandardPropertyBinding.Binding.views, MappingViewsRepository.SWT_KIND)); - this.views.createControls(parent); - this.views.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - if (e.item != null && e.item.getData() instanceof EObject) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardPropertyBinding.Binding.views, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SELECTION_CHANGED, null, e.item.getData())); - } - } - - }); - GridData viewsData = new GridData(GridData.FILL_HORIZONTAL); - viewsData.horizontalSpan = 3; - this.views.setLayoutData(viewsData); - this.views.disableMove(); - views.setID(MappingViewsRepository.StandardPropertyBinding.Binding.views); - views.setEEFType("eef::AdvancedReferencesTable"); //$NON-NLS-1$ - return parent; - } - - /** - * - */ - protected void addViews() { - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog(views.getInput(), viewsFilters, viewsBusinessFilters, - "views", propertiesEditionComponent.getEditingContext().getAdapterFactory(), current.eResource()) { - @Override - public void process(IStructuredSelection selection) { - for (Iterator iter = selection.iterator(); iter.hasNext();) { - EObject elem = (EObject) iter.next(); - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardPropertyBinding.Binding.views, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.ADD, null, elem)); - } - views.refresh(); - } - }; - dialog.open(); - } - - /** - * - */ - protected void moveViews(EObject element, int oldIndex, int newIndex) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardPropertyBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.MOVE, element, newIndex)); - views.refresh(); - } - - /** - * - */ - protected void removeFromViews(EObject element) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(StandardPropertyBindingPropertiesEditionPartImpl.this, MappingViewsRepository.StandardPropertyBinding.Binding.views, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.REMOVE, null, element)); - views.refresh(); - } - - /** - * - */ - protected void editViews(EObject element) { - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); - PropertiesEditingProvider provider = (PropertiesEditingProvider)adapterFactory.adapt(element, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - views.refresh(); - } - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#getName() - * - */ - public String getName() { - return name.getText(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#setName(String newValue) - * - */ - public void setName(String newValue) { - if (newValue != null) { - name.setText(newValue); - } else { - name.setText(""); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardPropertyBinding.Properties.name); - if (eefElementEditorReadOnlyState && name.isEnabled()) { - name.setEnabled(false); - name.setToolTipText(MappingMessages.StandardPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !name.isEnabled()) { - name.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardPropertyBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.StandardPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardPropertyBinding.Binding.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(MappingMessages.StandardPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#initViews(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) - */ - public void initViews(ReferencesTableSettings settings) { - if (current.eResource() != null && current.eResource().getResourceSet() != null) - this.resourceSet = current.eResource().getResourceSet(); - ReferencesTableContentProvider contentProvider = new ReferencesTableContentProvider(); - views.setContentProvider(contentProvider); - views.setInput(settings); - boolean eefElementEditorReadOnlyState = isReadOnly(MappingViewsRepository.StandardPropertyBinding.Binding.views); - if (eefElementEditorReadOnlyState && views.getTable().isEnabled()) { - views.setEnabled(false); - views.setToolTipText(MappingMessages.StandardPropertyBinding_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !views.getTable().isEnabled()) { - views.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#updateViews() - * - */ - public void updateViews() { - views.refresh(); -} - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#addFilterViews(ViewerFilter filter) - * - */ - public void addFilterToViews(ViewerFilter filter) { - viewsFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#addBusinessFilterViews(ViewerFilter filter) - * - */ - public void addBusinessFilterToViews(ViewerFilter filter) { - viewsBusinessFilters.add(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.parts.StandardPropertyBindingPropertiesEditionPart#isContainedInViewsTable(EObject element) - * - */ - public boolean isContainedInViewsTable(EObject element) { - return ((ReferencesTableSettings)views.getInput()).contains(element); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return MappingMessages.StandardPropertyBinding_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/AbstractElementBindingItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/AbstractElementBindingItemProvider.java deleted file mode 100644 index 22a069b7f..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/AbstractElementBindingItemProvider.java +++ /dev/null @@ -1,234 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.MappingFactory; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.filters.FiltersFactory; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.AbstractElementBinding} object. - * - * - * @generated - */ -public class AbstractElementBindingItemProvider extends - DocumentedElementItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public AbstractElementBindingItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addNamePropertyDescriptor(object); - addViewsPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Name feature. - * - * - * @generated - */ - protected void addNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_AbstractElementBinding_name_feature"), - getString("_UI_AbstractElementBinding_name_description"), - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__NAME, true, - false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, - null)); - } - - /** - * This adds a property descriptor for the Views feature. - * - * - * @generated - */ - protected void addViewsPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_AbstractElementBinding_views_feature"), - getString("_UI_AbstractElementBinding_views_description"), - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__VIEWS, true, - false, true, null, null, null)); - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures - .add(MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS); - childrenFeatures - .add(MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__PROPERTIES); - childrenFeatures - .add(MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING); - childrenFeatures - .add(MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns AbstractElementBinding.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/AbstractElementBinding")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((AbstractElementBinding) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_AbstractElementBinding_type") - : getString("_UI_AbstractElementBinding_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(AbstractElementBinding.class)) { - case MappingPackage.ABSTRACT_ELEMENT_BINDING__NAME: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS: - case MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES: - case MappingPackage.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING: - case MappingPackage.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated NOT - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS, - MappingFactory.eINSTANCE.createEMFElementBinding())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS, - MappingFactory.eINSTANCE.createStandardElementBinding())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__PROPERTIES, - MappingFactory.eINSTANCE.createEMFPropertyBinding())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__PROPERTIES, - MappingFactory.eINSTANCE.createStandardPropertyBinding())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__PROPERTIES, - MappingFactory.eINSTANCE.createEMFMultiPropertiesBinding())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING, - MappingFactory.eINSTANCE - .createElementBindingReference())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/AbstractPropertyBindingItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/AbstractPropertyBindingItemProvider.java deleted file mode 100644 index 5e06a5ac5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/AbstractPropertyBindingItemProvider.java +++ /dev/null @@ -1,281 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.AbstractPropertyBinding; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.filters.FiltersFactory; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.ViewElement; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding} object. - * - * - * @generated - */ -public class AbstractPropertyBindingItemProvider extends - DocumentedElementItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public AbstractPropertyBindingItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addNamePropertyDescriptor(object); - addViewsPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Name feature. - * - * - * @generated - */ - protected void addNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_AbstractPropertyBinding_name_feature"), - getString("_UI_AbstractPropertyBinding_name_description"), - MappingPackage.Literals.ABSTRACT_PROPERTY_BINDING__NAME, true, - false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, - null)); - } - - /** - * This adds a property descriptor for the Views feature. - * - * - * @generated NOT - */ - protected void addViewsPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(initViewsPropertyDescriptors()); - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures - .add(MappingPackage.Literals.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * @generated NOT - */ - private ItemPropertyDescriptor initViewsPropertyDescriptors() { - return new ItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_AbstractPropertyBinding_views_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_AbstractPropertyBinding_views_feature", - "_UI_AbstractPropertyBinding_type"), - MappingPackage.Literals.ABSTRACT_PROPERTY_BINDING__VIEWS, true, - false, true, null, null, null) { - - @Override - protected Collection getComboBoxObjects(Object object) { - if (object instanceof AbstractPropertyBinding) { - AbstractPropertyBinding propertyBinding = (AbstractPropertyBinding) object; - List views = new ArrayList(propertyBinding - .getElement().getViews()); - for (ElementBindingReference reference : propertyBinding - .getElement().getReferencedBinding()) - views.addAll(reference.getBinding().getViews()); - Collection comboBoxObjects = super - .getComboBoxObjects(object); - Collection result = new ArrayList(); - for (Object viewElement : comboBoxObjects) { - if (ownedBy((ViewElement) viewElement, views)) - result.add((ViewElement) viewElement); - } - return result; - } - return super.getComboBoxObjects(object); - } - - }; - } - - private boolean ownedBy(ViewElement element, List views) { - for (View view : views) { - if (ownedBy(element, view)) - return true; - } - return false; - } - - private boolean ownedBy(ViewElement element, View view) { - EObject container = element.eContainer(); - while (container != null) { - if (EcoreUtil.equals(view, container)) - return true; - else - container = container.eContainer(); - } - return false; - } - - /** - * This returns AbstractPropertyBinding.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/AbstractPropertyBinding")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((AbstractPropertyBinding) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_AbstractPropertyBinding_type") - : getString("_UI_AbstractPropertyBinding_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(AbstractPropertyBinding.class)) { - case MappingPackage.ABSTRACT_PROPERTY_BINDING__NAME: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - case MappingPackage.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated NOT - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - //newChildDescriptors - // .add(createChildParameter( - // MappingPackage.Literals.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS, - // FiltersFactory.eINSTANCE.createOCLFilter())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS, - FiltersFactory.eINSTANCE.createJavaDeclarationFilter())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS, - FiltersFactory.eINSTANCE.createJavaExpressionFilter())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS, - FiltersFactory.eINSTANCE - .createOnlyReferenceTypeFilter())); - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS, - FiltersFactory.eINSTANCE.createStrictTypingFilter())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/CategoryItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/CategoryItemProvider.java deleted file mode 100644 index 115777fd5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/CategoryItemProvider.java +++ /dev/null @@ -1,192 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.MappingFactory; -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.Category} object. - * - * - * @generated - */ -public class CategoryItemProvider extends DocumentedElementItemProvider - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public CategoryItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addNamePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Name feature. - * - * - * @generated - */ - protected void addNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_Category_name_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_Category_name_feature", "_UI_Category_type"), - MappingPackage.Literals.CATEGORY__NAME, true, false, false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures.add(MappingPackage.Literals.CATEGORY__BINDINGS); - childrenFeatures.add(MappingPackage.Literals.CATEGORY__CATEGORIES); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns Category.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator().getImage("full/obj16/Category")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Category) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_Category_type") - : getString("_UI_Category_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(Category.class)) { - case MappingPackage.CATEGORY__NAME: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - case MappingPackage.CATEGORY__BINDINGS: - case MappingPackage.CATEGORY__CATEGORIES: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.CATEGORY__BINDINGS, - MappingFactory.eINSTANCE.createEMFElementBinding())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.CATEGORY__BINDINGS, - MappingFactory.eINSTANCE.createStandardElementBinding())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.CATEGORY__CATEGORIES, - MappingFactory.eINSTANCE.createCategory())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/DatabindingItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/DatabindingItemProvider.java deleted file mode 100644 index 14ff86204..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/DatabindingItemProvider.java +++ /dev/null @@ -1,168 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.MappingFactory; -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.Databinding} object. - * - * - * @generated - */ -public class DatabindingItemProvider extends DocumentedElementItemProvider - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public DatabindingItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures.add(MappingPackage.Literals.DATABINDING__BINDINGS); - childrenFeatures - .add(MappingPackage.Literals.DATABINDING__CATEGORIES); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns Databinding.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator().getImage("full/obj16/Databinding")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Databinding) object).getDocumentation(); - return label == null || label.length() == 0 ? getString("_UI_Databinding_type") - : getString("_UI_Databinding_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(Databinding.class)) { - case MappingPackage.DATABINDING__BINDINGS: - case MappingPackage.DATABINDING__CATEGORIES: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.DATABINDING__BINDINGS, - MappingFactory.eINSTANCE.createEMFElementBinding())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.DATABINDING__BINDINGS, - MappingFactory.eINSTANCE.createStandardElementBinding())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.DATABINDING__CATEGORIES, - MappingFactory.eINSTANCE.createCategory())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/DocumentedElementItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/DocumentedElementItemProvider.java deleted file mode 100644 index e88f328fb..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/DocumentedElementItemProvider.java +++ /dev/null @@ -1,154 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.DocumentedElement} object. - * - * - * @generated - */ -public class DocumentedElementItemProvider extends ItemProviderAdapter - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public DocumentedElementItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addDocumentationPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Documentation feature. - * - * - * @generated - */ - protected void addDocumentationPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_DocumentedElement_documentation_feature"), - getString("_UI_DocumentedElement_documentation_description"), - MappingPackage.Literals.DOCUMENTED_ELEMENT__DOCUMENTATION, - true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, null)); - } - - /** - * This returns DocumentedElement.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator().getImage("full/obj16/DocumentedElement")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((DocumentedElement) object).getDocumentation(); - return label == null || label.length() == 0 ? getString("_UI_DocumentedElement_type") - : getString("_UI_DocumentedElement_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(DocumentedElement.class)) { - case MappingPackage.DOCUMENTED_ELEMENT__DOCUMENTATION: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ((IChildCreationExtender) adapterFactory).getResourceLocator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFElementBindingItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFElementBindingItemProvider.java deleted file mode 100644 index 7be7dff33..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFElementBindingItemProvider.java +++ /dev/null @@ -1,131 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.EMFElementBinding} object. - * - * - * @generated - */ -public class EMFElementBindingItemProvider extends - AbstractElementBindingItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EMFElementBindingItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addModelPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Model feature. - * - * - * @generated - */ - protected void addModelPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_EMFElementBinding_model_feature"), - getString("_UI_EMFElementBinding_model_description"), - MappingPackage.Literals.EMF_ELEMENT_BINDING__MODEL, true, - false, true, null, null, null)); - } - - /** - * This returns EMFElementBinding.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator().getImage("full/obj16/EMFElementBinding")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EMFElementBinding) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_EMFElementBinding_type") - : getString("_UI_EMFElementBinding_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFMultiPropertiesBindingItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFMultiPropertiesBindingItemProvider.java deleted file mode 100644 index f25b0ff13..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFMultiPropertiesBindingItemProvider.java +++ /dev/null @@ -1,199 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.navigation.NavigationFactory; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding} object. - * - * - * @generated - */ -public class EMFMultiPropertiesBindingItemProvider extends - AbstractPropertyBindingItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EMFMultiPropertiesBindingItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addModelPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Model feature. - * - * - * @generated - */ - protected void addModelPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_EMFMultiPropertiesBinding_model_feature"), - getString("_UI_EMFMultiPropertiesBinding_model_description"), - MappingPackage.Literals.EMF_MULTI_PROPERTIES_BINDING__MODEL, - true, false, true, null, null, null)); - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures - .add(MappingPackage.Literals.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns EMFMultiPropertiesBinding.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/EMFMultiPropertiesBinding")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EMFMultiPropertiesBinding) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_EMFMultiPropertiesBinding_type") - : getString("_UI_EMFMultiPropertiesBinding_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(EMFMultiPropertiesBinding.class)) { - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION, - NavigationFactory.eINSTANCE - .createSimpleModelNavigation())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION, - NavigationFactory.eINSTANCE - .createChainedModelNavigation())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION, - NavigationFactory.eINSTANCE - .createCustomModelNavigation())); - - newChildDescriptors - .add(createChildParameter( - MappingPackage.Literals.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION, - NavigationFactory.eINSTANCE - .createSmartModelNavigation())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFPropertyBindingItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFPropertyBindingItemProvider.java deleted file mode 100644 index 13fc22022..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/EMFPropertyBindingItemProvider.java +++ /dev/null @@ -1,279 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationFactory; -import org.eclipse.emf.eef.mapping.settings.SettingsFactory; -import org.eclipse.emf.eef.mapping.navigation.NavigationStep; -import org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.EMFPropertyBinding} object. - * - * - * @generated - */ -public class EMFPropertyBindingItemProvider extends - AbstractPropertyBindingItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EMFPropertyBindingItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addModelPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Model feature. - * - * - * @generated NOT - */ - protected void addModelPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(initModelPropertyDescriptor()); - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures - .add(MappingPackage.Literals.EMF_PROPERTY_BINDING__NAVIGATION); - childrenFeatures - .add(MappingPackage.Literals.EMF_PROPERTY_BINDING__EDITOR_SETTING); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * @generated NOT - */ - private ItemPropertyDescriptor initModelPropertyDescriptor() { - return new ItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EMFPropertyBinding_model_feature"), getString( - "_UI_PropertyDescriptor_description", - "_UI_EMFPropertyBinding_model_feature", - "_UI_EMFPropertyBinding_type"), - MappingPackage.Literals.EMF_PROPERTY_BINDING__MODEL, true, - false, true, null, null, null) { - - @Override - protected Collection getComboBoxObjects(Object object) { - if (object instanceof EMFPropertyBinding) { - EMFPropertyBinding propertyBinding = (EMFPropertyBinding) object; - EClassifier model = null; - if (propertyBinding.getNavigation() != null - && propertyBinding.getNavigation() instanceof SmartModelNavigation) { - NavigationStep step = ((SmartModelNavigation) propertyBinding - .getNavigation()).getStep(); - if (step != null) { - model = step.evaluate(); - } else { - model = ((EMFElementBinding) propertyBinding - .getElement()).getModel(); - } - if (model instanceof EClass) { - Collection comboBoxObjects = super - .getComboBoxObjects(object); - Collection results = new ArrayList(); - for (Object feature : comboBoxObjects) { - if (((EClass) model) - .getEAllStructuralFeatures().contains( - feature)) { - results.add((EStructuralFeature) feature); - } - } - return results; - } - } else if (propertyBinding.getNavigation() != null - && !(propertyBinding.getNavigation() instanceof CustomModelNavigation)) { - if (propertyBinding.getNavigation() != null) - model = ((StructuredModelNavigation) propertyBinding - .getNavigation()).evaluate(); - else - model = ((EMFElementBinding) propertyBinding - .getElement()).getModel(); - if (model instanceof EClass) { - Collection comboBoxObjects = super - .getComboBoxObjects(object); - Collection result = new ArrayList(); - for (Object feature : comboBoxObjects) { - if (((EClass) model) - .getEAllStructuralFeatures().contains( - feature)) - result.add((EStructuralFeature) feature); - } - return result; - } - } else { - model = ((EMFElementBinding) propertyBinding - .getElement()).getModel(); - if (model != null) { - if (model instanceof EClass) - return ((EClass) model) - .getEAllStructuralFeatures(); - } - } - } - return super.getComboBoxObjects(object); - } - - }; - } - - /** - * This returns EMFPropertyBinding.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, - getResourceLocator().getImage("full/obj16/EMFPropertyBinding")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EMFPropertyBinding) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_EMFPropertyBinding_type") - : getString("_UI_EMFPropertyBinding_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(EMFPropertyBinding.class)) { - case MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION: - case MappingPackage.EMF_PROPERTY_BINDING__EDITOR_SETTING: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.EMF_PROPERTY_BINDING__NAVIGATION, - NavigationFactory.eINSTANCE.createSimpleModelNavigation())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.EMF_PROPERTY_BINDING__NAVIGATION, - NavigationFactory.eINSTANCE.createChainedModelNavigation())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.EMF_PROPERTY_BINDING__NAVIGATION, - NavigationFactory.eINSTANCE.createCustomModelNavigation())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.EMF_PROPERTY_BINDING__NAVIGATION, - NavigationFactory.eINSTANCE.createSmartModelNavigation())); - - newChildDescriptors.add(createChildParameter( - MappingPackage.Literals.EMF_PROPERTY_BINDING__EDITOR_SETTING, - SettingsFactory.eINSTANCE.createEReferenceViewerSettings())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ElementBindingReferenceItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ElementBindingReferenceItemProvider.java deleted file mode 100644 index 8e36e92a0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ElementBindingReferenceItemProvider.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.ElementBindingReference} object. - * - * - * @generated - */ -public class ElementBindingReferenceItemProvider extends - DocumentedElementItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public ElementBindingReferenceItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addBindingPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Binding feature. - * - * - * @generated - */ - protected void addBindingPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_ElementBindingReference_binding_feature"), - getString("_UI_ElementBindingReference_binding_description"), - MappingPackage.Literals.ELEMENT_BINDING_REFERENCE__BINDING, - true, false, true, null, null, null)); - } - - /** - * This returns ElementBindingReference.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/ElementBindingReference")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((ElementBindingReference) object).getDocumentation(); - return label == null || label.length() == 0 ? getString("_UI_ElementBindingReference_type") - : getString("_UI_ElementBindingReference_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/MappingEditPlugin.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/MappingEditPlugin.java deleted file mode 100644 index a54de7795..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/MappingEditPlugin.java +++ /dev/null @@ -1,102 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.provider.EcoreEditPlugin; -import org.eclipse.emf.eef.views.provider.ViewsEditPlugin; -import org.eclipse.emf.ecore.EValidator; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.runtime.impl.validation.EEFValidator; - -/** - * This is the central singleton for the Mapping edit plugin. - * - * - * @generated - */ -public final class MappingEditPlugin extends EMFPlugin { - /** - * Keep track of the singleton. - * - * - * @generated - */ - public static final MappingEditPlugin INSTANCE = new MappingEditPlugin(); - - /** - * Keep track of the singleton. - * - * - * @generated - */ - private static Implementation plugin; - - /** - * Create the instance. - * - * - * @generated - */ - public MappingEditPlugin() { - super(new ResourceLocator[] { EcoreEditPlugin.INSTANCE, - ViewsEditPlugin.INSTANCE, }); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - @Override - public ResourceLocator getPluginResourceLocator() { - return plugin; - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * - * @generated - */ - public static class Implementation extends EclipsePlugin { - /** - * Creates an instance. - * - * - * @generated NOT - */ - public Implementation() { - super(); - - // Remember the static instance. - // - plugin = this; - EValidator.Registry.INSTANCE.put(MappingPackage.eINSTANCE, - new EEFValidator()); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/MappingItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/MappingItemProviderAdapterFactory.java deleted file mode 100644 index 05abe3147..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/MappingItemProviderAdapterFactory.java +++ /dev/null @@ -1,436 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ChildCreationExtenderManager; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IChildCreationExtender; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.util.MappingAdapterFactory; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class MappingItemProviderAdapterFactory extends MappingAdapterFactory - implements ComposeableAdapterFactory, IChangeNotifier, IDisposable, - IChildCreationExtender { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This helps manage the child creation extenders. - * - * - * @generated - */ - protected ChildCreationExtenderManager childCreationExtenderManager = new ChildCreationExtenderManager( - MappingEditPlugin.INSTANCE, MappingPackage.eNS_URI); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public MappingItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.Databinding} instances. - * - * - * @generated - */ - protected DatabindingItemProvider databindingItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.Databinding}. - * - * - * @generated - */ - @Override - public Adapter createDatabindingAdapter() { - if (databindingItemProvider == null) { - databindingItemProvider = new DatabindingItemProvider(this); - } - - return databindingItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.EMFElementBinding} instances. - * - * - * @generated - */ - protected EMFElementBindingItemProvider emfElementBindingItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.EMFElementBinding}. - * - * - * @generated - */ - @Override - public Adapter createEMFElementBindingAdapter() { - if (emfElementBindingItemProvider == null) { - emfElementBindingItemProvider = new EMFElementBindingItemProvider( - this); - } - - return emfElementBindingItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.EMFPropertyBinding} instances. - * - * - * @generated - */ - protected EMFPropertyBindingItemProvider emfPropertyBindingItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.EMFPropertyBinding}. - * - * - * @generated - */ - @Override - public Adapter createEMFPropertyBindingAdapter() { - if (emfPropertyBindingItemProvider == null) { - emfPropertyBindingItemProvider = new EMFPropertyBindingItemProvider( - this); - } - - return emfPropertyBindingItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.StandardElementBinding} instances. - * - * - * @generated - */ - protected StandardElementBindingItemProvider standardElementBindingItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.StandardElementBinding}. - * - * - * @generated - */ - @Override - public Adapter createStandardElementBindingAdapter() { - if (standardElementBindingItemProvider == null) { - standardElementBindingItemProvider = new StandardElementBindingItemProvider( - this); - } - - return standardElementBindingItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.StandardPropertyBinding} instances. - * - * - * @generated - */ - protected StandardPropertyBindingItemProvider standardPropertyBindingItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.StandardPropertyBinding}. - * - * - * @generated - */ - @Override - public Adapter createStandardPropertyBindingAdapter() { - if (standardPropertyBindingItemProvider == null) { - standardPropertyBindingItemProvider = new StandardPropertyBindingItemProvider( - this); - } - - return standardPropertyBindingItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.Category} instances. - * - * - * @generated - */ - protected CategoryItemProvider categoryItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.Category}. - * - * - * @generated - */ - @Override - public Adapter createCategoryAdapter() { - if (categoryItemProvider == null) { - categoryItemProvider = new CategoryItemProvider(this); - } - - return categoryItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.ElementBindingReference} instances. - * - * - * @generated - */ - protected ElementBindingReferenceItemProvider elementBindingReferenceItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.ElementBindingReference}. - * - * - * @generated - */ - @Override - public Adapter createElementBindingReferenceAdapter() { - if (elementBindingReferenceItemProvider == null) { - elementBindingReferenceItemProvider = new ElementBindingReferenceItemProvider( - this); - } - - return elementBindingReferenceItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding} instances. - * - * - * @generated - */ - protected EMFMultiPropertiesBindingItemProvider emfMultiPropertiesBindingItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding}. - * - * - * @generated - */ - @Override - public Adapter createEMFMultiPropertiesBindingAdapter() { - if (emfMultiPropertiesBindingItemProvider == null) { - emfMultiPropertiesBindingItemProvider = new EMFMultiPropertiesBindingItemProvider( - this); - } - - return emfMultiPropertiesBindingItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory - .getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory( - ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) - || (((Class) type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * - * - * @generated - */ - public List getChildCreationExtenders() { - return childCreationExtenderManager.getChildCreationExtenders(); - } - - /** - * - * - * @generated - */ - public Collection getNewChildDescriptors(Object object, - EditingDomain editingDomain) { - return childCreationExtenderManager.getNewChildDescriptors(object, - editingDomain); - } - - /** - * - * - * @generated - */ - public ResourceLocator getResourceLocator() { - return childCreationExtenderManager; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (databindingItemProvider != null) - databindingItemProvider.dispose(); - if (emfElementBindingItemProvider != null) - emfElementBindingItemProvider.dispose(); - if (emfPropertyBindingItemProvider != null) - emfPropertyBindingItemProvider.dispose(); - if (standardElementBindingItemProvider != null) - standardElementBindingItemProvider.dispose(); - if (standardPropertyBindingItemProvider != null) - standardPropertyBindingItemProvider.dispose(); - if (categoryItemProvider != null) - categoryItemProvider.dispose(); - if (elementBindingReferenceItemProvider != null) - elementBindingReferenceItemProvider.dispose(); - if (emfMultiPropertiesBindingItemProvider != null) - emfMultiPropertiesBindingItemProvider.dispose(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ModelElementItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ModelElementItemProvider.java deleted file mode 100644 index 3cad618aa..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ModelElementItemProvider.java +++ /dev/null @@ -1,162 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelElement; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.ModelElement} object. - * - * - * @generated - */ -public class ModelElementItemProvider extends DocumentedElementItemProvider - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public ModelElementItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addBindingPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Binding feature. - * - * - * @generated - */ - protected void addBindingPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_ModelElement_binding_feature"), - getString("_UI_ModelElement_binding_description"), - MappingPackage.Literals.MODEL_ELEMENT__BINDING, true, false, - true, null, null, null)); - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures - .add(MappingPackage.Literals.MODEL_ELEMENT__PROPERTIES); - childrenFeatures - .add(MappingPackage.Literals.MODEL_ELEMENT__SUB_ELEMENTS); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((ModelElement) object).getDocumentation(); - return label == null || label.length() == 0 ? getString("_UI_ModelElement_type") - : getString("_UI_ModelElement_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(ModelElement.class)) { - case MappingPackage.MODEL_ELEMENT__PROPERTIES: - case MappingPackage.MODEL_ELEMENT__SUB_ELEMENTS: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ModelPropertyItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ModelPropertyItemProvider.java deleted file mode 100644 index 6a7afb1e5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/ModelPropertyItemProvider.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelProperty; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.ModelProperty} object. - * - * - * @generated - */ -public class ModelPropertyItemProvider extends DocumentedElementItemProvider - implements IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public ModelPropertyItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addBindingPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Binding feature. - * - * - * @generated - */ - protected void addBindingPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_ModelProperty_binding_feature"), - getString("_UI_ModelProperty_binding_description"), - MappingPackage.Literals.MODEL_PROPERTY__BINDING, true, false, - true, null, null, null)); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((ModelProperty) object).getDocumentation(); - return label == null || label.length() == 0 ? getString("_UI_ModelProperty_type") - : getString("_UI_ModelProperty_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/StandardElementBindingItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/StandardElementBindingItemProvider.java deleted file mode 100644 index 8887f5d0d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/StandardElementBindingItemProvider.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.StandardElementBinding; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.StandardElementBinding} object. - * - * - * @generated - */ -public class StandardElementBindingItemProvider extends - AbstractElementBindingItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public StandardElementBindingItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addModelPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Model feature. - * - * - * @generated - */ - protected void addModelPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_StandardElementBinding_model_feature"), - getString("_UI_StandardElementBinding_model_description"), - MappingPackage.Literals.STANDARD_ELEMENT_BINDING__MODEL, true, - false, true, null, null, null)); - } - - /** - * This returns StandardElementBinding.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/StandardElementBinding")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((StandardElementBinding) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_StandardElementBinding_type") - : getString("_UI_StandardElementBinding_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/StandardPropertyBindingItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/StandardPropertyBindingItemProvider.java deleted file mode 100644 index 2c596d337..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/provider/StandardPropertyBindingItemProvider.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.StandardPropertyBinding; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.StandardPropertyBinding} object. - * - * - * @generated - */ -public class StandardPropertyBindingItemProvider extends - AbstractPropertyBindingItemProvider implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public StandardPropertyBindingItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addModelPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Model feature. - * - * - * @generated - */ - protected void addModelPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), getResourceLocator(), - getString("_UI_StandardPropertyBinding_model_feature"), - getString("_UI_StandardPropertyBinding_model_description"), - MappingPackage.Literals.STANDARD_PROPERTY_BINDING__MODEL, true, - false, true, null, null, null)); - } - - /** - * This returns StandardPropertyBinding.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/StandardPropertyBinding")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((StandardPropertyBinding) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_StandardPropertyBinding_type") - : getString("_UI_StandardPropertyBinding_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/CategoryPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/CategoryPropertiesEditionProvider.java deleted file mode 100644 index 86f6f3045..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/CategoryPropertiesEditionProvider.java +++ /dev/null @@ -1,157 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.MappingPackage; - -import org.eclipse.emf.eef.mapping.components.CategoryBasePropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.CategoryPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class CategoryPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public CategoryPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public CategoryPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof Category) - && (MappingPackage.Literals.CATEGORY == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof Category) && (CategoryBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof Category) && (refinement == CategoryBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof Category) && ((CategoryBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == CategoryBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof Category) { - return new CategoryPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof Category) { - if (CategoryBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new CategoryBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof Category) { - if (CategoryBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == CategoryBasePropertiesEditionComponent.class) - return new CategoryBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && MappingPackage.Literals.CATEGORY == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/DocumentedElementPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/DocumentedElementPropertiesEditionProvider.java deleted file mode 100644 index 9c8ed43e0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/DocumentedElementPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.MappingPackage; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class DocumentedElementPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public DocumentedElementPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public DocumentedElementPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof DocumentedElement) - && (MappingPackage.Literals.DOCUMENTED_ELEMENT == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof DocumentedElement) && (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof DocumentedElement) && (refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof DocumentedElement) && ((DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof DocumentedElement) { - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof DocumentedElement) { - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof DocumentedElement) { - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && MappingPackage.Literals.DOCUMENTED_ELEMENT == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFElementBindingPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFElementBindingPropertiesEditionProvider.java deleted file mode 100644 index d4251d7b2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFElementBindingPropertiesEditionProvider.java +++ /dev/null @@ -1,157 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.EMFElementBindingBasePropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.EMFElementBindingPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class EMFElementBindingPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public EMFElementBindingPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public EMFElementBindingPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof EMFElementBinding) - && (MappingPackage.Literals.EMF_ELEMENT_BINDING == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof EMFElementBinding) && (EMFElementBindingBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EMFElementBinding) && (refinement == EMFElementBindingBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EMFElementBinding) && ((EMFElementBindingBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == EMFElementBindingBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof EMFElementBinding) { - return new EMFElementBindingPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof EMFElementBinding) { - if (EMFElementBindingBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new EMFElementBindingBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof EMFElementBinding) { - if (EMFElementBindingBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == EMFElementBindingBasePropertiesEditionComponent.class) - return new EMFElementBindingBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && MappingPackage.Literals.EMF_ELEMENT_BINDING == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFMultiPropertiesBindingPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFMultiPropertiesBindingPropertiesEditionProvider.java deleted file mode 100644 index 29c99db39..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFMultiPropertiesBindingPropertiesEditionProvider.java +++ /dev/null @@ -1,157 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.EMFMultiPropertiesBindingBasePropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.EMFMultiPropertiesBindingPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class EMFMultiPropertiesBindingPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public EMFMultiPropertiesBindingPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public EMFMultiPropertiesBindingPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof EMFMultiPropertiesBinding) - && (MappingPackage.Literals.EMF_MULTI_PROPERTIES_BINDING == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof EMFMultiPropertiesBinding) && (EMFMultiPropertiesBindingBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EMFMultiPropertiesBinding) && (refinement == EMFMultiPropertiesBindingBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EMFMultiPropertiesBinding) && ((EMFMultiPropertiesBindingBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == EMFMultiPropertiesBindingBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof EMFMultiPropertiesBinding) { - return new EMFMultiPropertiesBindingPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof EMFMultiPropertiesBinding) { - if (EMFMultiPropertiesBindingBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new EMFMultiPropertiesBindingBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof EMFMultiPropertiesBinding) { - if (EMFMultiPropertiesBindingBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == EMFMultiPropertiesBindingBasePropertiesEditionComponent.class) - return new EMFMultiPropertiesBindingBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && MappingPackage.Literals.EMF_MULTI_PROPERTIES_BINDING == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFPropertyBindingPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFPropertyBindingPropertiesEditionProvider.java deleted file mode 100644 index 6b89905a1..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/EMFPropertyBindingPropertiesEditionProvider.java +++ /dev/null @@ -1,157 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.EMFPropertyBindingBasePropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.EMFPropertyBindingPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class EMFPropertyBindingPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public EMFPropertyBindingPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public EMFPropertyBindingPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof EMFPropertyBinding) - && (MappingPackage.Literals.EMF_PROPERTY_BINDING == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof EMFPropertyBinding) && (EMFPropertyBindingBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EMFPropertyBinding) && (refinement == EMFPropertyBindingBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EMFPropertyBinding) && ((EMFPropertyBindingBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == EMFPropertyBindingBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof EMFPropertyBinding) { - return new EMFPropertyBindingPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof EMFPropertyBinding) { - if (EMFPropertyBindingBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new EMFPropertyBindingBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof EMFPropertyBinding) { - if (EMFPropertyBindingBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == EMFPropertyBindingBasePropertiesEditionComponent.class) - return new EMFPropertyBindingBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && MappingPackage.Literals.EMF_PROPERTY_BINDING == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/ElementBindingReferencePropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/ElementBindingReferencePropertiesEditionProvider.java deleted file mode 100644 index e0c66862c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/ElementBindingReferencePropertiesEditionProvider.java +++ /dev/null @@ -1,157 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.MappingPackage; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.ElementBindingReferenceBasePropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.ElementBindingReferencePropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class ElementBindingReferencePropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public ElementBindingReferencePropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public ElementBindingReferencePropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof ElementBindingReference) - && (MappingPackage.Literals.ELEMENT_BINDING_REFERENCE == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof ElementBindingReference) && (ElementBindingReferenceBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof ElementBindingReference) && (refinement == ElementBindingReferenceBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof ElementBindingReference) && ((ElementBindingReferenceBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == ElementBindingReferenceBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof ElementBindingReference) { - return new ElementBindingReferencePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof ElementBindingReference) { - if (ElementBindingReferenceBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new ElementBindingReferenceBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof ElementBindingReference) { - if (ElementBindingReferenceBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == ElementBindingReferenceBasePropertiesEditionComponent.class) - return new ElementBindingReferenceBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && MappingPackage.Literals.ELEMENT_BINDING_REFERENCE == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/FilterPropertiesPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/FilterPropertiesPropertiesEditionProvider.java deleted file mode 100644 index 6d4b90056..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/FilterPropertiesPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.components.FilterPropertiesPropertiesEditionComponent; - -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class FilterPropertiesPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public FilterPropertiesPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public FilterPropertiesPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof BindingFilter) - && (FiltersPackage.Literals.BINDING_FILTER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof BindingFilter) && (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof BindingFilter) && (refinement == FilterPropertiesPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof BindingFilter) && ((FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) && refinement == FilterPropertiesPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof BindingFilter) { - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof BindingFilter) { - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part)) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof BindingFilter) { - if (FilterPropertiesPropertiesEditionComponent.FILTERPROPERTIES_PART.equals(part) - && refinement == FilterPropertiesPropertiesEditionComponent.class) - return new FilterPropertiesPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && FiltersPackage.Literals.BINDING_FILTER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingEEFAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingEEFAdapterFactory.java deleted file mode 100644 index ff0acf65f..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingEEFAdapterFactory.java +++ /dev/null @@ -1,107 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.notify.Adapter; - -import org.eclipse.emf.eef.mapping.util.MappingAdapterFactory; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -/** - * @author Nathalie Lepine - * - */ -public class MappingEEFAdapterFactory extends MappingAdapterFactory { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.util.MappingAdapterFactory#createDocumentedElementAdapter() - * - */ - public Adapter createDocumentedElementAdapter() { - return new DocumentedElementPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.util.MappingAdapterFactory#createEMFElementBindingAdapter() - * - */ - public Adapter createEMFElementBindingAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new EMFElementBindingPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.util.MappingAdapterFactory#createEMFPropertyBindingAdapter() - * - */ - public Adapter createEMFPropertyBindingAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new EMFPropertyBindingPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.util.MappingAdapterFactory#createStandardElementBindingAdapter() - * - */ - public Adapter createStandardElementBindingAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new StandardElementBindingPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.util.MappingAdapterFactory#createStandardPropertyBindingAdapter() - * - */ - public Adapter createStandardPropertyBindingAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new StandardPropertyBindingPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.util.MappingAdapterFactory#createCategoryAdapter() - * - */ - public Adapter createCategoryAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new CategoryPropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.util.MappingAdapterFactory#createElementBindingReferenceAdapter() - * - */ - public Adapter createElementBindingReferenceAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new ElementBindingReferencePropertiesEditionProvider(providers); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.util.MappingAdapterFactory#createEMFMultiPropertiesBindingAdapter() - * - */ - public Adapter createEMFMultiPropertiesBindingAdapter() { - List providers = new ArrayList(1); - providers.add((PropertiesEditingProvider)createDocumentedElementAdapter()); - return new EMFMultiPropertiesBindingPropertiesEditionProvider(providers); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingMessages.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingMessages.java deleted file mode 100644 index 5424b4c74..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingMessages.java +++ /dev/null @@ -1,243 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import org.eclipse.osgi.util.NLS; - -/** - * @author Nathalie Lepine - * - */ -public class MappingMessages extends NLS { - - private static final String BUNDLE_NAME = "org.eclipse.emf.eef.mapping.providers.mappingMessages"; //$NON-NLS-1$ - - - public static String EMFElementBindingPropertiesEditionPart_PropertiesGroupLabel; - - - public static String EMFElementBindingPropertiesEditionPart_BindingGroupLabel; - - - public static String EMFPropertyBindingPropertiesEditionPart_PropertiesGroupLabel; - - - public static String EMFPropertyBindingPropertiesEditionPart_BindingGroupLabel; - - - public static String StandardElementBindingPropertiesEditionPart_PropertiesGroupLabel; - - - public static String StandardElementBindingPropertiesEditionPart_BindingGroupLabel; - - - public static String StandardPropertyBindingPropertiesEditionPart_PropertiesGroupLabel; - - - public static String StandardPropertyBindingPropertiesEditionPart_BindingGroupLabel; - - - public static String CategoryPropertiesEditionPart_PropertiesGroupLabel; - - - public static String ElementBindingReferencePropertiesEditionPart_ReferenceGroupLabel; - - - public static String EMFMultiPropertiesBindingPropertiesEditionPart_PropertiesGroupLabel; - - - public static String EMFMultiPropertiesBindingPropertiesEditionPart_BindingGroupLabel; - - - public static String DocumentationPropertiesEditionPart_DocumentationGroupLabel; - - - public static String FilterPropertiesPropertiesEditionPart_FilterPropertiesGroupLabel; - - - - public static String EMFElementBinding_ReadOnly; - - - public static String EMFElementBinding_Part_Title; - - - public static String EMFPropertyBinding_ReadOnly; - - - public static String EMFPropertyBinding_Part_Title; - - - public static String StandardElementBinding_ReadOnly; - - - public static String StandardElementBinding_Part_Title; - - - public static String StandardPropertyBinding_ReadOnly; - - - public static String StandardPropertyBinding_Part_Title; - - - public static String Category_ReadOnly; - - - public static String Category_Part_Title; - - - public static String ElementBindingReference_ReadOnly; - - - public static String ElementBindingReference_Part_Title; - - - public static String EMFMultiPropertiesBinding_ReadOnly; - - - public static String EMFMultiPropertiesBinding_Part_Title; - - - public static String Documentation_ReadOnly; - - - public static String Documentation_Part_Title; - - - public static String FilterProperties_ReadOnly; - - - public static String FilterProperties_Part_Title; - - - - public static String EMFElementBindingPropertiesEditionPart_NameLabel; - - - public static String EMFElementBindingPropertiesEditionPart_ModelLabel; - - - public static String EMFElementBindingPropertiesEditionPart_ViewsLabel; - - - public static String EMFPropertyBindingPropertiesEditionPart_NameLabel; - - - public static String EMFPropertyBindingPropertiesEditionPart_ModelLabel; - - - public static String EMFPropertyBindingPropertiesEditionPart_ViewsLabel; - - - public static String StandardElementBindingPropertiesEditionPart_NameLabel; - - - public static String StandardElementBindingPropertiesEditionPart_ModelLabel; - - - public static String StandardElementBindingPropertiesEditionPart_ViewsLabel; - - - public static String StandardPropertyBindingPropertiesEditionPart_NameLabel; - - - public static String StandardPropertyBindingPropertiesEditionPart_ModelLabel; - - - public static String StandardPropertyBindingPropertiesEditionPart_ViewsLabel; - - - public static String CategoryPropertiesEditionPart_NameLabel; - - - public static String ElementBindingReferencePropertiesEditionPart_BindingLabel; - - - public static String EMFMultiPropertiesBindingPropertiesEditionPart_NameLabel; - - - public static String EMFMultiPropertiesBindingPropertiesEditionPart_ModelLabel; - - - public static String EMFMultiPropertiesBindingPropertiesEditionPart_ViewsLabel; - - - public static String DocumentationPropertiesEditionPart_DocumentationLabel; - - - public static String FilterPropertiesPropertiesEditionPart_NameLabel; - - - public static String FilterPropertiesPropertiesEditionPart_MandatoryLabel; - - - - public static String PropertiesEditionPart_DocumentationLabel; - - - public static String PropertiesEditionPart_IntegerValueMessage; - - - public static String PropertiesEditionPart_FloatValueMessage; - - - public static String PropertiesEditionPart_ShortValueMessage; - - - public static String PropertiesEditionPart_LongValueMessage; - - - public static String PropertiesEditionPart_ByteValueMessage; - - - public static String PropertiesEditionPart_BigIntegerValueMessage; - - - public static String PropertiesEditionPart_BigDecimalValueMessage; - - - public static String PropertiesEditionPart_DoubleValueMessage; - - - public static String PropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesEditionPart_RequiredFeatureMessage; - - - public static String PropertiesEditionPart_AddTableViewerLabel; - - - public static String PropertiesEditionPart_EditTableViewerLabel; - - - public static String PropertiesEditionPart_RemoveTableViewerLabel; - - - public static String PropertiesEditionPart_AddListViewerLabel; - - - public static String PropertiesEditionPart_RemoveListViewerLabel; - - // Start of user code for additionnal NLS Constants - - // End of user code - - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, MappingMessages.class); - } - - - private MappingMessages() { - //protect instanciation - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingPropertiesEditionPartProvider.java deleted file mode 100644 index deabc394a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/MappingPropertiesEditionPartProvider.java +++ /dev/null @@ -1,119 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; - -import org.eclipse.emf.eef.mapping.parts.forms.CategoryPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.parts.forms.DocumentationPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.parts.forms.EMFElementBindingPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.parts.forms.EMFMultiPropertiesBindingPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.parts.forms.EMFPropertyBindingPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.parts.forms.ElementBindingReferencePropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.parts.forms.FilterPropertiesPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.parts.forms.StandardElementBindingPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.parts.forms.StandardPropertyBindingPropertiesEditionPartForm; - -import org.eclipse.emf.eef.mapping.parts.impl.CategoryPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.parts.impl.DocumentationPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.parts.impl.EMFElementBindingPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.parts.impl.EMFMultiPropertiesBindingPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.parts.impl.EMFPropertyBindingPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.parts.impl.ElementBindingReferencePropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.parts.impl.FilterPropertiesPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.parts.impl.StandardElementBindingPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.parts.impl.StandardPropertyBindingPropertiesEditionPartImpl; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; - -/** - * @author Nathalie Lepine - * - */ -public class MappingPropertiesEditionPartProvider implements IPropertiesEditionPartProvider { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#provides(java.lang.Object) - * - */ - public boolean provides(Object key) { - return key == MappingViewsRepository.class; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#getPropertiesEditionPart(java.lang.Object, int, org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, IPropertiesEditionComponent component) { - if (key == MappingViewsRepository.EMFElementBinding.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new EMFElementBindingPropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new EMFElementBindingPropertiesEditionPartForm(component); - } - if (key == MappingViewsRepository.EMFPropertyBinding.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new EMFPropertyBindingPropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new EMFPropertyBindingPropertiesEditionPartForm(component); - } - if (key == MappingViewsRepository.StandardElementBinding.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new StandardElementBindingPropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new StandardElementBindingPropertiesEditionPartForm(component); - } - if (key == MappingViewsRepository.StandardPropertyBinding.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new StandardPropertyBindingPropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new StandardPropertyBindingPropertiesEditionPartForm(component); - } - if (key == MappingViewsRepository.Category.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new CategoryPropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new CategoryPropertiesEditionPartForm(component); - } - if (key == MappingViewsRepository.ElementBindingReference.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new ElementBindingReferencePropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new ElementBindingReferencePropertiesEditionPartForm(component); - } - if (key == MappingViewsRepository.EMFMultiPropertiesBinding.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new EMFMultiPropertiesBindingPropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new EMFMultiPropertiesBindingPropertiesEditionPartForm(component); - } - if (key == MappingViewsRepository.Documentation.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new DocumentationPropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new DocumentationPropertiesEditionPartForm(component); - } - if (key == MappingViewsRepository.FilterProperties.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new FilterPropertiesPropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new FilterPropertiesPropertiesEditionPartForm(component); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/StandardElementBindingPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/StandardElementBindingPropertiesEditionProvider.java deleted file mode 100644 index 2ddb97659..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/StandardElementBindingPropertiesEditionProvider.java +++ /dev/null @@ -1,157 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.StandardElementBinding; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.StandardElementBindingBasePropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.StandardElementBindingPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class StandardElementBindingPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public StandardElementBindingPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public StandardElementBindingPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof StandardElementBinding) - && (MappingPackage.Literals.STANDARD_ELEMENT_BINDING == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof StandardElementBinding) && (StandardElementBindingBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof StandardElementBinding) && (refinement == StandardElementBindingBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof StandardElementBinding) && ((StandardElementBindingBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == StandardElementBindingBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof StandardElementBinding) { - return new StandardElementBindingPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof StandardElementBinding) { - if (StandardElementBindingBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new StandardElementBindingBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof StandardElementBinding) { - if (StandardElementBindingBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == StandardElementBindingBasePropertiesEditionComponent.class) - return new StandardElementBindingBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && MappingPackage.Literals.STANDARD_ELEMENT_BINDING == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/StandardPropertyBindingPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/StandardPropertyBindingPropertiesEditionProvider.java deleted file mode 100644 index e3174c438..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/StandardPropertyBindingPropertiesEditionProvider.java +++ /dev/null @@ -1,157 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.StandardPropertyBinding; - -import org.eclipse.emf.eef.mapping.components.DocumentedElementPropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.StandardPropertyBindingBasePropertiesEditionComponent; -import org.eclipse.emf.eef.mapping.components.StandardPropertyBindingPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class StandardPropertyBindingPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public StandardPropertyBindingPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public StandardPropertyBindingPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof StandardPropertyBinding) - && (MappingPackage.Literals.STANDARD_PROPERTY_BINDING == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof StandardPropertyBinding) && (StandardPropertyBindingBasePropertiesEditionComponent.BASE_PART.equals(part) || DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof StandardPropertyBinding) && (refinement == StandardPropertyBindingBasePropertiesEditionComponent.class || refinement == DocumentedElementPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof StandardPropertyBinding) && ((StandardPropertyBindingBasePropertiesEditionComponent.BASE_PART.equals(part) && refinement == StandardPropertyBindingBasePropertiesEditionComponent.class) || (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) && refinement == DocumentedElementPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof StandardPropertyBinding) { - return new StandardPropertyBindingPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof StandardPropertyBinding) { - if (StandardPropertyBindingBasePropertiesEditionComponent.BASE_PART.equals(part)) - return new StandardPropertyBindingBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part)) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof StandardPropertyBinding) { - if (StandardPropertyBindingBasePropertiesEditionComponent.BASE_PART.equals(part) - && refinement == StandardPropertyBindingBasePropertiesEditionComponent.class) - return new StandardPropertyBindingBasePropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - if (DocumentedElementPropertiesEditionComponent.DOCUMENTATION_PART.equals(part) - && refinement == DocumentedElementPropertiesEditionComponent.class) - return new DocumentedElementPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && MappingPackage.Literals.STANDARD_PROPERTY_BINDING == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/mappingMessages.properties b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/mappingMessages.properties deleted file mode 100644 index 736fcbc7a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/mappingMessages.properties +++ /dev/null @@ -1,84 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -EMFElementBindingPropertiesEditionPart_PropertiesGroupLabel=Properties -EMFElementBindingPropertiesEditionPart_BindingGroupLabel=Binding -EMFPropertyBindingPropertiesEditionPart_PropertiesGroupLabel=Properties -EMFPropertyBindingPropertiesEditionPart_BindingGroupLabel=Binding -StandardElementBindingPropertiesEditionPart_PropertiesGroupLabel=Properties -StandardElementBindingPropertiesEditionPart_BindingGroupLabel=Binding -StandardPropertyBindingPropertiesEditionPart_PropertiesGroupLabel=Properties -StandardPropertyBindingPropertiesEditionPart_BindingGroupLabel=Binding -CategoryPropertiesEditionPart_PropertiesGroupLabel=Properties -ElementBindingReferencePropertiesEditionPart_ReferenceGroupLabel=R\u00e9ference -EMFMultiPropertiesBindingPropertiesEditionPart_PropertiesGroupLabel=Properties -EMFMultiPropertiesBindingPropertiesEditionPart_BindingGroupLabel=Binding -DocumentationPropertiesEditionPart_DocumentationGroupLabel=Documentation -FilterPropertiesPropertiesEditionPart_FilterPropertiesGroupLabel=Filter Properties -EMFElementBinding_ReadOnly=This property is read only -EMFElementBinding_Part_Title=Base -EMFPropertyBinding_ReadOnly=This property is read only -EMFPropertyBinding_Part_Title=Base -StandardElementBinding_ReadOnly=This property is read only -StandardElementBinding_Part_Title=Base -StandardPropertyBinding_ReadOnly=This property is read only -StandardPropertyBinding_Part_Title=Base -Category_ReadOnly=This property is read only -Category_Part_Title=Base -ElementBindingReference_ReadOnly=This property is read only -ElementBindingReference_Part_Title=Base -EMFMultiPropertiesBinding_ReadOnly=This property is read only -EMFMultiPropertiesBinding_Part_Title=Base -Documentation_ReadOnly=This property is read only -Documentation_Part_Title=Documentation -FilterProperties_ReadOnly=This property is read only -FilterProperties_Part_Title=Filter properties -EMFElementBindingPropertiesEditionPart_NameLabel=Name : -EMFElementBindingPropertiesEditionPart_ModelLabel=Model : -EMFElementBindingPropertiesEditionPart_ViewsLabel=Views : -EMFPropertyBindingPropertiesEditionPart_NameLabel=Name : -EMFPropertyBindingPropertiesEditionPart_ModelLabel=Model : -EMFPropertyBindingPropertiesEditionPart_ViewsLabel=Views : -StandardElementBindingPropertiesEditionPart_NameLabel=Name : -StandardElementBindingPropertiesEditionPart_ModelLabel=Model : -StandardElementBindingPropertiesEditionPart_ViewsLabel=Views : -StandardPropertyBindingPropertiesEditionPart_NameLabel=Name : -StandardPropertyBindingPropertiesEditionPart_ModelLabel=Model : -StandardPropertyBindingPropertiesEditionPart_ViewsLabel=Views : -CategoryPropertiesEditionPart_NameLabel=Name : -ElementBindingReferencePropertiesEditionPart_BindingLabel=Binding : -EMFMultiPropertiesBindingPropertiesEditionPart_NameLabel=Name : -EMFMultiPropertiesBindingPropertiesEditionPart_ModelLabel=Model : -EMFMultiPropertiesBindingPropertiesEditionPart_ViewsLabel=Views : -DocumentationPropertiesEditionPart_DocumentationLabel=Documentation : -FilterPropertiesPropertiesEditionPart_NameLabel=Name : -FilterPropertiesPropertiesEditionPart_MandatoryLabel=Mandatory -PropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionPart_EditTableViewerLabel=Edit -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=The property {0} of the object shall be filled -PropertiesEditionPart_RemoveTableViewerLabel=Delete -PropertiesEditionPart_RemoveListViewerLabel=Delete -PropertiesEditionPart_IntegerValueMessage=The property {0} shall be an integer -PropertiesEditionPart_FloatValueMessage=The property {0} shall be a float -PropertiesEditionPart_ShortValueMessage=The property {0} shall be a short -PropertiesEditionPart_DoubleValueMessage=The property {0} shall be a double -PropertiesEditionPart_ByteValueMessage=The property {0} shall be a byte -PropertiesEditionPart_LongValueMessage=The property {0} shall be a long -PropertiesEditionPart_BigIntegerValueMessage=The property {0} shall be a BigInteger -PropertiesEditionPart_BigDecimalValueMessage=The property {0} shall be a BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Add -PropertiesEditionPart_AddListViewerLabel=Add diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/mappingMessages_fr.properties b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/mappingMessages_fr.properties deleted file mode 100644 index ec21ad6ec..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/providers/mappingMessages_fr.properties +++ /dev/null @@ -1,84 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -EMFElementBindingPropertiesEditionPart_PropertiesGroupLabel=Properties -EMFElementBindingPropertiesEditionPart_BindingGroupLabel=Binding -EMFPropertyBindingPropertiesEditionPart_PropertiesGroupLabel=Properties -EMFPropertyBindingPropertiesEditionPart_BindingGroupLabel=Binding -StandardElementBindingPropertiesEditionPart_PropertiesGroupLabel=Properties -StandardElementBindingPropertiesEditionPart_BindingGroupLabel=Binding -StandardPropertyBindingPropertiesEditionPart_PropertiesGroupLabel=Properties -StandardPropertyBindingPropertiesEditionPart_BindingGroupLabel=Binding -CategoryPropertiesEditionPart_PropertiesGroupLabel=Properties -ElementBindingReferencePropertiesEditionPart_ReferenceGroupLabel=R\u00e9ference -EMFMultiPropertiesBindingPropertiesEditionPart_PropertiesGroupLabel=Properties -EMFMultiPropertiesBindingPropertiesEditionPart_BindingGroupLabel=Binding -DocumentationPropertiesEditionPart_DocumentationGroupLabel=Documentation -FilterPropertiesPropertiesEditionPart_FilterPropertiesGroupLabel=Filter Properties -EMFElementBinding_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -EMFElementBinding_Part_Title=Base -EMFPropertyBinding_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -EMFPropertyBinding_Part_Title=Base -StandardElementBinding_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -StandardElementBinding_Part_Title=Base -StandardPropertyBinding_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -StandardPropertyBinding_Part_Title=Base -Category_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -Category_Part_Title=Base -ElementBindingReference_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -ElementBindingReference_Part_Title=Base -EMFMultiPropertiesBinding_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -EMFMultiPropertiesBinding_Part_Title=Base -Documentation_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -Documentation_Part_Title=Documentation -FilterProperties_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -FilterProperties_Part_Title=Filter properties -EMFElementBindingPropertiesEditionPart_NameLabel=Name : -EMFElementBindingPropertiesEditionPart_ModelLabel=Model : -EMFElementBindingPropertiesEditionPart_ViewsLabel=Views : -EMFPropertyBindingPropertiesEditionPart_NameLabel=Name : -EMFPropertyBindingPropertiesEditionPart_ModelLabel=Model : -EMFPropertyBindingPropertiesEditionPart_ViewsLabel=Views : -StandardElementBindingPropertiesEditionPart_NameLabel=Name : -StandardElementBindingPropertiesEditionPart_ModelLabel=Model : -StandardElementBindingPropertiesEditionPart_ViewsLabel=Views : -StandardPropertyBindingPropertiesEditionPart_NameLabel=Name : -StandardPropertyBindingPropertiesEditionPart_ModelLabel=Model : -StandardPropertyBindingPropertiesEditionPart_ViewsLabel=Views : -CategoryPropertiesEditionPart_NameLabel=Name : -ElementBindingReferencePropertiesEditionPart_BindingLabel=Binding : -EMFMultiPropertiesBindingPropertiesEditionPart_NameLabel=Name : -EMFMultiPropertiesBindingPropertiesEditionPart_ModelLabel=Model : -EMFMultiPropertiesBindingPropertiesEditionPart_ViewsLabel=Views : -DocumentationPropertiesEditionPart_DocumentationLabel=Documentation : -FilterPropertiesPropertiesEditionPart_NameLabel=Name : -FilterPropertiesPropertiesEditionPart_MandatoryLabel=Mandatory -PropertiesEditionPart_PropertiesGroupLabel=Propri\u00E9t\u00E9s -PropertiesEditionPart_EditTableViewerLabel=Editer -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=La propri\u00E9t\u00E9 {0} de l\u0027objet doit \u00EAtre renseign\u00E9e -PropertiesEditionPart_RemoveTableViewerLabel=Supprimer -PropertiesEditionPart_RemoveListViewerLabel=Supprimer -PropertiesEditionPart_IntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un entier -PropertiesEditionPart_FloatValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un flottant -PropertiesEditionPart_ShortValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un short -PropertiesEditionPart_DoubleValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un double -PropertiesEditionPart_ByteValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un byte -PropertiesEditionPart_LongValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un long -PropertiesEditionPart_BigIntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigInteger -PropertiesEditionPart_BigDecimalValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Ajouter -PropertiesEditionPart_AddListViewerLabel=Ajouter diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/SettingsPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/SettingsPropertiesEditionPart.java deleted file mode 100644 index 0ec80985d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/SettingsPropertiesEditionPart.java +++ /dev/null @@ -1,93 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.settings.parts; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; - -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; - -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public interface SettingsPropertiesEditionPart { - - /** - * @return the model - * - */ - public EObject getModel(); - - /** - * Init the model - * @param settings the combo setting - */ - public void initModel(EObjectFlatComboSettings settings); - - /** - * Defines a new model - * @param newValue the new model to set - * - */ - public void setModel(EObject newValue); - - /** - * Defines the button mode - * @param newValue the new mode to set - * - */ - public void setModelButtonMode(ButtonsModeEnum newValue); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addFilterToModel(ViewerFilter filter); - - /** - * Adds the given filter to the model edition editor. - * - * @param filter - * a viewer filter - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter); - - - - - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - * - */ - public String getTitle(); - - // Start of user code for additional methods - - // End of user code - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/SettingsViewsRepository.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/SettingsViewsRepository.java deleted file mode 100644 index 44a63167b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/SettingsViewsRepository.java +++ /dev/null @@ -1,34 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.settings.parts; - -/** - * @author Nathalie Lepine - * - */ -public class SettingsViewsRepository { - - public static final int SWT_KIND = 0; - - public static final int FORM_KIND = 1; - - - /** - * Settings view descriptor - * - */ - public static class Settings_ { - - public static String model = "settings::Settings_::model"; - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/forms/SettingsPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/forms/SettingsPropertiesEditionPartForm.java deleted file mode 100644 index d3686432d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/forms/SettingsPropertiesEditionPartForm.java +++ /dev/null @@ -1,277 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.settings.parts.forms; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; - -import org.eclipse.emf.eef.mapping.settings.parts.SettingsPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.settings.parts.SettingsViewsRepository; - -import org.eclipse.emf.eef.mapping.settings.providers.SettingsMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.part.impl.SectionPropertiesEditingPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; - -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; - -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Composite; - -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class SettingsPropertiesEditionPartForm extends SectionPropertiesEditingPart implements IFormPropertiesEditionPart, SettingsPropertiesEditionPart { - - protected EObjectFlatComboViewer model; - - - - /** - * For {@link ISection} use only. - */ - public SettingsPropertiesEditionPartForm() { super(); } - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public SettingsPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - * - */ - public Composite createFigure(final Composite parent, final FormToolkit widgetFactory) { - ScrolledForm scrolledForm = widgetFactory.createScrolledForm(parent); - Form form = scrolledForm.getForm(); - view = form.getBody(); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(widgetFactory, view); - return scrolledForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart# - * createControls(org.eclipse.ui.forms.widgets.FormToolkit, org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(final FormToolkit widgetFactory, Composite view) { - CompositionSequence settings_Step = new BindingCompositionSequence(propertiesEditionComponent); - settings_Step.addStep(SettingsViewsRepository.Settings_.model); - - composer = new PartComposer(settings_Step) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == SettingsViewsRepository.Settings_.model) { - return createModelFlatComboViewer(parent, widgetFactory); - } - return parent; - } - }; - composer.compose(view); - } - /** - * @param parent the parent composite - * @param widgetFactory factory to use to instanciante widget of the form - * - */ - protected Composite createModelFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - createDescription(parent, SettingsViewsRepository.Settings_.model, SettingsMessages.SettingsPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(SettingsViewsRepository.Settings_.model, SettingsViewsRepository.FORM_KIND)); - widgetFactory.adapt(model); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(SettingsPropertiesEditionPartForm.this, SettingsViewsRepository.Settings_.model, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - model.setID(SettingsViewsRepository.Settings_.model); - FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(SettingsViewsRepository.Settings_.model, SettingsViewsRepository.FORM_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(SettingsViewsRepository.Settings_.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(SettingsMessages.Settings_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(SettingsViewsRepository.Settings_.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(SettingsMessages.Settings_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return SettingsMessages.Settings_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/impl/SettingsPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/impl/SettingsPropertiesEditionPartImpl.java deleted file mode 100644 index c9e3f084b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/parts/impl/SettingsPropertiesEditionPartImpl.java +++ /dev/null @@ -1,262 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.settings.parts.impl; - -// Start of user code for imports -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; - -import org.eclipse.emf.eef.mapping.settings.parts.SettingsPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.settings.parts.SettingsViewsRepository; - -import org.eclipse.emf.eef.mapping.settings.providers.SettingsMessages; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.BindingCompositionSequence; -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionSequence; - -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; - -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; - -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Composite; - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class SettingsPropertiesEditionPartImpl extends CompositePropertiesEditionPart implements ISWTPropertiesEditionPart, SettingsPropertiesEditionPart { - - protected EObjectFlatComboViewer model; - - - - /** - * Default constructor - * @param editionComponent the {@link IPropertiesEditionComponent} that manage this part - * - */ - public SettingsPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createFigure(org.eclipse.swt.widgets.Composite) - * - */ - public Composite createFigure(final Composite parent) { - view = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 3; - view.setLayout(layout); - createControls(view); - return view; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart# - * createControls(org.eclipse.swt.widgets.Composite) - * - */ - public void createControls(Composite view) { - CompositionSequence settings_Step = new BindingCompositionSequence(propertiesEditionComponent); - settings_Step.addStep(SettingsViewsRepository.Settings_.model); - - composer = new PartComposer(settings_Step) { - - @Override - public Composite addToPart(Composite parent, Object key) { - if (key == SettingsViewsRepository.Settings_.model) { - return createModelFlatComboViewer(parent); - } - return parent; - } - }; - composer.compose(view); - } - - /** - * @param parent the parent composite - * - */ - protected Composite createModelFlatComboViewer(Composite parent) { - createDescription(parent, SettingsViewsRepository.Settings_.model, SettingsMessages.SettingsPropertiesEditionPart_ModelLabel); - model = new EObjectFlatComboViewer(parent, !propertiesEditionComponent.isRequired(SettingsViewsRepository.Settings_.model, SettingsViewsRepository.SWT_KIND)); - model.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - model.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(SettingsPropertiesEditionPartImpl.this, SettingsViewsRepository.Settings_.model, PropertiesEditionEvent.CHANGE, PropertiesEditionEvent.SET, null, getModel())); - } - - }); - GridData modelData = new GridData(GridData.FILL_HORIZONTAL); - model.setLayoutData(modelData); - model.setID(SettingsViewsRepository.Settings_.model); - SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(SettingsViewsRepository.Settings_.model, SettingsViewsRepository.SWT_KIND), null); //$NON-NLS-1$ - // Start of user code for createModelFlatComboViewer - - // End of user code - return parent; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // Start of user code for tab synchronization - - // End of user code - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#getModel() - * - */ - public EObject getModel() { - if (model.getSelection() instanceof StructuredSelection) { - Object firstElement = ((StructuredSelection) model.getSelection()).getFirstElement(); - if (firstElement instanceof EObject) - return (EObject) firstElement; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#initModel(EObjectFlatComboSettings) - */ - public void initModel(EObjectFlatComboSettings settings) { - model.setInput(settings); - if (current != null) { - model.setSelection(new StructuredSelection(settings.getValue())); - } - boolean eefElementEditorReadOnlyState = isReadOnly(SettingsViewsRepository.Settings_.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(SettingsMessages.Settings_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#setModel(EObject newValue) - * - */ - public void setModel(EObject newValue) { - if (newValue != null) { - model.setSelection(new StructuredSelection(newValue)); - } else { - model.setSelection(new StructuredSelection()); //$NON-NLS-1$ - } - boolean eefElementEditorReadOnlyState = isReadOnly(SettingsViewsRepository.Settings_.model); - if (eefElementEditorReadOnlyState && model.isEnabled()) { - model.setEnabled(false); - model.setToolTipText(SettingsMessages.Settings_ReadOnly); - } else if (!eefElementEditorReadOnlyState && !model.isEnabled()) { - model.setEnabled(true); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#setModelButtonMode(ButtonsModeEnum newValue) - */ - public void setModelButtonMode(ButtonsModeEnum newValue) { - model.setButtonMode(newValue); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#addFilterModel(ViewerFilter filter) - * - */ - public void addFilterToModel(ViewerFilter filter) { - model.addFilter(filter); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.settings.parts.SettingsPropertiesEditionPart#addBusinessFilterModel(ViewerFilter filter) - * - */ - public void addBusinessFilterToModel(ViewerFilter filter) { - model.addBusinessRuleFilter(filter); - } - - - - - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - * - */ - public String getTitle() { - return SettingsMessages.Settings_Part_Title; - } - - // Start of user code additional methods - - // End of user code - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/EReferenceViewerSettingsItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/EReferenceViewerSettingsItemProvider.java deleted file mode 100644 index 655bb0b8a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/EReferenceViewerSettingsItemProvider.java +++ /dev/null @@ -1,184 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EStructuralFeature; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.mapping.filters.FiltersFactory; - -import org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings; -import org.eclipse.emf.eef.mapping.settings.SettingsPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings} object. - * - * - * @generated - */ -public class EReferenceViewerSettingsItemProvider extends - EditorSettingsItemProvider implements IEditingDomainItemProvider, - IStructuredItemContentProvider, ITreeItemContentProvider, - IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EReferenceViewerSettingsItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addModelPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Model feature. - * - * - * @generated - */ - protected void addModelPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EReferenceViewerSettings_model_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_EReferenceViewerSettings_model_feature", - "_UI_EReferenceViewerSettings_type"), - SettingsPackage.Literals.EREFERENCE_VIEWER_SETTINGS__MODEL, - true, false, true, null, null, null)); - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures( - Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures - .add(SettingsPackage.Literals.EREFERENCE_VIEWER_SETTINGS__FILTER); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns EReferenceViewerSettings.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage( - object, - getResourceLocator().getImage( - "full/obj16/EReferenceViewerSettings")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_EReferenceViewerSettings_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(EReferenceViewerSettings.class)) { - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS__FILTER: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add(createChildParameter( - SettingsPackage.Literals.EREFERENCE_VIEWER_SETTINGS__FILTER, - FiltersFactory.eINSTANCE.createJavaBodyStepFilter())); - - newChildDescriptors.add(createChildParameter( - SettingsPackage.Literals.EREFERENCE_VIEWER_SETTINGS__FILTER, - FiltersFactory.eINSTANCE.createJavaDeclarationStepFilter())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/EditorSettingsItemProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/EditorSettingsItemProvider.java deleted file mode 100644 index 566811bbf..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/EditorSettingsItemProvider.java +++ /dev/null @@ -1,109 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings.provider; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; - -import org.eclipse.emf.eef.mapping.provider.MappingEditPlugin; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.mapping.settings.EditorSettings} object. - * - * - * @generated - */ -public class EditorSettingsItemProvider extends ItemProviderAdapter implements - IEditingDomainItemProvider, IStructuredItemContentProvider, - ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EditorSettingsItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_EditorSettings_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors( - Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return MappingEditPlugin.INSTANCE; - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/SettingsItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/SettingsItemProviderAdapterFactory.java deleted file mode 100644 index ef9c93f2d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/provider/SettingsItemProviderAdapterFactory.java +++ /dev/null @@ -1,209 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings.provider; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; - -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.mapping.settings.util.SettingsAdapterFactory; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class SettingsItemProviderAdapterFactory extends SettingsAdapterFactory - implements ComposeableAdapterFactory, IChangeNotifier, IDisposable { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public SettingsItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings} instances. - * - * - * @generated - */ - protected EReferenceViewerSettingsItemProvider eReferenceViewerSettingsItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings}. - * - * - * @generated - */ - @Override - public Adapter createEReferenceViewerSettingsAdapter() { - if (eReferenceViewerSettingsItemProvider == null) { - eReferenceViewerSettingsItemProvider = new EReferenceViewerSettingsItemProvider( - this); - } - - return eReferenceViewerSettingsItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory - .getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory( - ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) - || (((Class) type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (eReferenceViewerSettingsItemProvider != null) - eReferenceViewerSettingsItemProvider.dispose(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/SettingsMessages.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/SettingsMessages.java deleted file mode 100644 index 7868218dc..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/SettingsMessages.java +++ /dev/null @@ -1,96 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.settings.providers; - -import org.eclipse.osgi.util.NLS; - -/** - * @author Nathalie Lepine - * - */ -public class SettingsMessages extends NLS { - - private static final String BUNDLE_NAME = "org.eclipse.emf.eef.mapping.settings.providers.settingsMessages"; //$NON-NLS-1$ - - - - public static String Settings_ReadOnly; - - - public static String Settings_Part_Title; - - - - public static String SettingsPropertiesEditionPart_ModelLabel; - - - - public static String PropertiesEditionPart_DocumentationLabel; - - - public static String PropertiesEditionPart_IntegerValueMessage; - - - public static String PropertiesEditionPart_FloatValueMessage; - - - public static String PropertiesEditionPart_ShortValueMessage; - - - public static String PropertiesEditionPart_LongValueMessage; - - - public static String PropertiesEditionPart_ByteValueMessage; - - - public static String PropertiesEditionPart_BigIntegerValueMessage; - - - public static String PropertiesEditionPart_BigDecimalValueMessage; - - - public static String PropertiesEditionPart_DoubleValueMessage; - - - public static String PropertiesEditionPart_PropertiesGroupLabel; - - - public static String PropertiesEditionPart_RequiredFeatureMessage; - - - public static String PropertiesEditionPart_AddTableViewerLabel; - - - public static String PropertiesEditionPart_EditTableViewerLabel; - - - public static String PropertiesEditionPart_RemoveTableViewerLabel; - - - public static String PropertiesEditionPart_AddListViewerLabel; - - - public static String PropertiesEditionPart_RemoveListViewerLabel; - - // Start of user code for additionnal NLS Constants - - // End of user code - - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, SettingsMessages.class); - } - - - private SettingsMessages() { - //protect instanciation - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/SettingsPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/SettingsPropertiesEditionPartProvider.java deleted file mode 100644 index fbebb1b45..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/SettingsPropertiesEditionPartProvider.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.settings.providers; - -import org.eclipse.emf.eef.mapping.settings.parts.SettingsViewsRepository; - -import org.eclipse.emf.eef.mapping.settings.parts.forms.SettingsPropertiesEditionPartForm; - -import org.eclipse.emf.eef.mapping.settings.parts.impl.SettingsPropertiesEditionPartImpl; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; - -/** - * @author Nathalie Lepine - * - */ -public class SettingsPropertiesEditionPartProvider implements IPropertiesEditionPartProvider { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#provides(java.lang.Object) - * - */ - public boolean provides(Object key) { - return key == SettingsViewsRepository.class; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPartProvider#getPropertiesEditionPart(java.lang.Object, int, org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent) - * - */ - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, IPropertiesEditionComponent component) { - if (key == SettingsViewsRepository.Settings_.class) { - if (kind == SettingsViewsRepository.SWT_KIND) - return new SettingsPropertiesEditionPartImpl(component); - if (kind == SettingsViewsRepository.FORM_KIND) - return new SettingsPropertiesEditionPartForm(component); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/settingsMessages.properties b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/settingsMessages.properties deleted file mode 100644 index 9ea591f62..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/settingsMessages.properties +++ /dev/null @@ -1,35 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -Settings_ReadOnly=This property is read only -Settings_Part_Title=Settings -SettingsPropertiesEditionPart_ModelLabel=Model : -PropertiesEditionPart_PropertiesGroupLabel=Properties -PropertiesEditionPart_EditTableViewerLabel=Edit -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=The property {0} of the object shall be filled -PropertiesEditionPart_RemoveTableViewerLabel=Delete -PropertiesEditionPart_RemoveListViewerLabel=Delete -PropertiesEditionPart_IntegerValueMessage=The property {0} shall be an integer -PropertiesEditionPart_FloatValueMessage=The property {0} shall be a float -PropertiesEditionPart_ShortValueMessage=The property {0} shall be a short -PropertiesEditionPart_DoubleValueMessage=The property {0} shall be a double -PropertiesEditionPart_ByteValueMessage=The property {0} shall be a byte -PropertiesEditionPart_LongValueMessage=The property {0} shall be a long -PropertiesEditionPart_BigIntegerValueMessage=The property {0} shall be a BigInteger -PropertiesEditionPart_BigDecimalValueMessage=The property {0} shall be a BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Add -PropertiesEditionPart_AddListViewerLabel=Add diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/settingsMessages_fr.properties b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/settingsMessages_fr.properties deleted file mode 100644 index 6475419be..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/mapping/settings/providers/settingsMessages_fr.properties +++ /dev/null @@ -1,35 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# Start of user code for titles customization - -# End of user code - -# default values ... -Settings_ReadOnly=Cette propri\u00E9t\u00E9 est en lecture seule -Settings_Part_Title=Settings -SettingsPropertiesEditionPart_ModelLabel=Model : -PropertiesEditionPart_PropertiesGroupLabel=Propri\u00E9t\u00E9s -PropertiesEditionPart_EditTableViewerLabel=Editer -PropertiesEditionPart_DocumentationLabel=Documentation -PropertiesEditionPart_RequiredFeatureMessage=La propri\u00E9t\u00E9 {0} de l\u0027objet doit \u00EAtre renseign\u00E9e -PropertiesEditionPart_RemoveTableViewerLabel=Supprimer -PropertiesEditionPart_RemoveListViewerLabel=Supprimer -PropertiesEditionPart_IntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un entier -PropertiesEditionPart_FloatValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un flottant -PropertiesEditionPart_ShortValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un short -PropertiesEditionPart_DoubleValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un double -PropertiesEditionPart_ByteValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un byte -PropertiesEditionPart_LongValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un long -PropertiesEditionPart_BigIntegerValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigInteger -PropertiesEditionPart_BigDecimalValueMessage=La propri\u00E9t\u00E9 {0} doit \u00EAtre un BigDecimal -PropertiesEditionPart_AddTableViewerLabel=Ajouter -PropertiesEditionPart_AddListViewerLabel=Ajouter diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/DeclarativeNavigationStepPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/DeclarativeNavigationStepPropertiesEditionComponent.java deleted file mode 100644 index 35ffb7536..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/DeclarativeNavigationStepPropertiesEditionComponent.java +++ /dev/null @@ -1,319 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; - -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcoreFactory; -import org.eclipse.emf.ecore.EcorePackage; - -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; - -import org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -import org.eclipse.emf.eef.mapping.navigation.parts.DeclarativeNavigationStepPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; - -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; - -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; - -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; - -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; - -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class DeclarativeNavigationStepPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for feature EObjectFlatComboViewer - */ - private EObjectFlatComboSettings featureSettings; - - /** - * Settings for discriminatorType EObjectFlatComboViewer - */ - private EObjectFlatComboSettings discriminatorTypeSettings; - - - /** - * Default constructor - * - */ - public DeclarativeNavigationStepPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject declarativeNavigationStep, String editing_mode) { - super(editingContext, declarativeNavigationStep, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = NavigationViewsRepository.class; - partKey = NavigationViewsRepository.DeclarativeNavigationStep.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final DeclarativeNavigationStep declarativeNavigationStep = (DeclarativeNavigationStep)elt; - final DeclarativeNavigationStepPropertiesEditionPart basePart = (DeclarativeNavigationStepPropertiesEditionPart)editingPart; - // init values - if (isAccessible(NavigationViewsRepository.DeclarativeNavigationStep.Properties.index)) { - basePart.setIndex(EEFConverterUtil.convertToString(EcorePackage.Literals.EINT, declarativeNavigationStep.getIndex())); - } - - if (isAccessible(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature)) { - // init part - featureSettings = new EObjectFlatComboSettings(declarativeNavigationStep, NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_Feature()); - basePart.initFeature(featureSettings); - // set the button mode - basePart.setFeatureButtonMode(ButtonsModeEnum.BROWSE); - } - if (isAccessible(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType)) { - // init part - discriminatorTypeSettings = new EObjectFlatComboSettings(declarativeNavigationStep, NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_DiscriminatorType()); - basePart.initDiscriminatorType(discriminatorTypeSettings); - // set the button mode - basePart.setDiscriminatorTypeButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - - if (isAccessible(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature)) { - basePart.addFilterToFeature(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EReference); - } - - }); - // Start of user code for additional businessfilters for feature - // End of user code - } - if (isAccessible(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType)) { - basePart.addFilterToDiscriminatorType(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof String && element.equals("")) || (element instanceof EClassifier); //$NON-NLS-1$ - } - - }); - // Start of user code for additional businessfilters for discriminatorType - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == NavigationViewsRepository.DeclarativeNavigationStep.Properties.index) { - return NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_Index(); - } - if (editorKey == NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature) { - return NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_Feature(); - } - if (editorKey == NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType) { - return NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_DiscriminatorType(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - DeclarativeNavigationStep declarativeNavigationStep = (DeclarativeNavigationStep)semanticObject; - if (NavigationViewsRepository.DeclarativeNavigationStep.Properties.index == event.getAffectedEditor()) { - declarativeNavigationStep.setIndex((EEFConverterUtil.createIntFromString(EcorePackage.Literals.EINT, (String)event.getNewValue()))); - } - if (NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - featureSettings.setToReference((EReference)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReference eObject = EcoreFactory.eINSTANCE.createEReference(); - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - featureSettings.setToReference(eObject); - } - } - if (NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - discriminatorTypeSettings.setToReference((EClassifier)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, discriminatorTypeSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - DeclarativeNavigationStepPropertiesEditionPart basePart = (DeclarativeNavigationStepPropertiesEditionPart)editingPart; - if (NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_Index().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(NavigationViewsRepository.DeclarativeNavigationStep.Properties.index)) { - if (msg.getNewValue() != null) { - basePart.setIndex(EcoreUtil.convertToString(EcorePackage.Literals.EINT, msg.getNewValue())); - } else { - basePart.setIndex(""); - } - } - if (NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_Feature().equals(msg.getFeature()) && basePart != null && isAccessible(NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature)) - basePart.setFeature((EObject)msg.getNewValue()); - if (NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_DiscriminatorType().equals(msg.getFeature()) && basePart != null && isAccessible(NavigationViewsRepository.DeclarativeNavigationStep.Properties.discriminatorType)) - basePart.setDiscriminatorType((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_Index(), - NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_Feature(), - NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_DiscriminatorType() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (NavigationViewsRepository.DeclarativeNavigationStep.Properties.index == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_Index().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(NavigationPackage.eINSTANCE.getDeclarativeNavigationStep_Index().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/JavaBodyStepInitializerPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/JavaBodyStepInitializerPropertiesEditionComponent.java deleted file mode 100644 index accdf28ba..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/JavaBodyStepInitializerPropertiesEditionComponent.java +++ /dev/null @@ -1,196 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; - -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; - -import org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -import org.eclipse.emf.eef.mapping.navigation.parts.JavaBodyStepInitializerPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; - -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaBodyStepInitializerPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public JavaBodyStepInitializerPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject javaBodyStepInitializer, String editing_mode) { - super(editingContext, javaBodyStepInitializer, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = NavigationViewsRepository.class; - partKey = NavigationViewsRepository.JavaBodyStepInitializer.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final JavaBodyStepInitializer javaBodyStepInitializer = (JavaBodyStepInitializer)elt; - final JavaBodyStepInitializerPropertiesEditionPart basePart = (JavaBodyStepInitializerPropertiesEditionPart)editingPart; - // init values - if (isAccessible(NavigationViewsRepository.JavaBodyStepInitializer.Properties.body)) - basePart.setBody(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, javaBodyStepInitializer.getBody())); - // init filters - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == NavigationViewsRepository.JavaBodyStepInitializer.Properties.body) { - return NavigationPackage.eINSTANCE.getJavaBodyExpression_Body(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - JavaBodyStepInitializer javaBodyStepInitializer = (JavaBodyStepInitializer)semanticObject; - if (NavigationViewsRepository.JavaBodyStepInitializer.Properties.body == event.getAffectedEditor()) { - javaBodyStepInitializer.setBody((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - JavaBodyStepInitializerPropertiesEditionPart basePart = (JavaBodyStepInitializerPropertiesEditionPart)editingPart; - if (NavigationPackage.eINSTANCE.getJavaBodyExpression_Body().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(NavigationViewsRepository.JavaBodyStepInitializer.Properties.body)){ - if (msg.getNewValue() != null) { - basePart.setBody(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setBody(""); - } - } - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - NavigationPackage.eINSTANCE.getJavaBodyExpression_Body() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == NavigationViewsRepository.JavaBodyStepInitializer.Properties.body; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (NavigationViewsRepository.JavaBodyStepInitializer.Properties.body == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(NavigationPackage.eINSTANCE.getJavaBodyExpression_Body().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(NavigationPackage.eINSTANCE.getJavaBodyExpression_Body().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/JavaDeclarationStepInitializerPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/JavaDeclarationStepInitializerPropertiesEditionComponent.java deleted file mode 100644 index ddd22ada2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/JavaDeclarationStepInitializerPropertiesEditionComponent.java +++ /dev/null @@ -1,245 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; - -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; - -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -import org.eclipse.emf.eef.mapping.navigation.parts.JavaDeclarationStepInitializerPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; - -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationStepInitializerPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - - /** - * Default constructor - * - */ - public JavaDeclarationStepInitializerPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject javaDeclarationStepInitializer, String editing_mode) { - super(editingContext, javaDeclarationStepInitializer, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = NavigationViewsRepository.class; - partKey = NavigationViewsRepository.JavaDeclarationStepInitializer.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final JavaDeclarationStepInitializer javaDeclarationStepInitializer = (JavaDeclarationStepInitializer)elt; - final JavaDeclarationStepInitializerPropertiesEditionPart basePart = (JavaDeclarationStepInitializerPropertiesEditionPart)editingPart; - // init values - if (isAccessible(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass)) - basePart.setQualifiedClass(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, javaDeclarationStepInitializer.getQualifiedClass())); - - if (isAccessible(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter)) - basePart.setMethodFilter(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, javaDeclarationStepInitializer.getMethodName())); - - if (isAccessible(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod)) { - basePart.setStaticMethod(javaDeclarationStepInitializer.isStaticMethod()); - } - // init filters - - - - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass) { - return NavigationPackage.eINSTANCE.getJavaDeclarationExpression_QualifiedClass(); - } - if (editorKey == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter) { - return NavigationPackage.eINSTANCE.getJavaDeclarationExpression_MethodName(); - } - if (editorKey == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod) { - return NavigationPackage.eINSTANCE.getJavaDeclarationExpression_StaticMethod(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - JavaDeclarationStepInitializer javaDeclarationStepInitializer = (JavaDeclarationStepInitializer)semanticObject; - if (NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass == event.getAffectedEditor()) { - javaDeclarationStepInitializer.setQualifiedClass((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter == event.getAffectedEditor()) { - javaDeclarationStepInitializer.setMethodName((java.lang.String)EEFConverterUtil.createFromString(EcorePackage.Literals.ESTRING, (String)event.getNewValue())); - } - if (NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod == event.getAffectedEditor()) { - javaDeclarationStepInitializer.setStaticMethod((Boolean)event.getNewValue()); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - JavaDeclarationStepInitializerPropertiesEditionPart basePart = (JavaDeclarationStepInitializerPropertiesEditionPart)editingPart; - if (NavigationPackage.eINSTANCE.getJavaDeclarationExpression_QualifiedClass().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass)) { - if (msg.getNewValue() != null) { - basePart.setQualifiedClass(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setQualifiedClass(""); - } - } - if (NavigationPackage.eINSTANCE.getJavaDeclarationExpression_MethodName().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter)) { - if (msg.getNewValue() != null) { - basePart.setMethodFilter(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, msg.getNewValue())); - } else { - basePart.setMethodFilter(""); - } - } - if (NavigationPackage.eINSTANCE.getJavaDeclarationExpression_StaticMethod().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod)) - basePart.setStaticMethod((Boolean)msg.getNewValue()); - - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - NavigationPackage.eINSTANCE.getJavaDeclarationExpression_QualifiedClass(), - NavigationPackage.eINSTANCE.getJavaDeclarationExpression_MethodName(), - NavigationPackage.eINSTANCE.getJavaDeclarationExpression_StaticMethod() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass || key == NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.qualifiedClass == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_QualifiedClass().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_QualifiedClass().getEAttributeType(), newValue); - } - if (NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.methodFilter == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_MethodName().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_MethodName().getEAttributeType(), newValue); - } - if (NavigationViewsRepository.JavaDeclarationStepInitializer.Properties.staticMethod == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_StaticMethod().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(NavigationPackage.eINSTANCE.getJavaDeclarationExpression_StaticMethod().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/SimpleModelNavigationPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/SimpleModelNavigationPropertiesEditionComponent.java deleted file mode 100644 index ec70afef5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/components/SimpleModelNavigationPropertiesEditionComponent.java +++ /dev/null @@ -1,303 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcoreFactory; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.parts.SimpleModelNavigationPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class SimpleModelNavigationPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String BASE_PART = "Base"; //$NON-NLS-1$ - - - /** - * Settings for feature EObjectFlatComboViewer - */ - private EObjectFlatComboSettings featureSettings; - - /** - * Settings for discriminatorType EObjectFlatComboViewer - */ - private EObjectFlatComboSettings discriminatorTypeSettings; - - - /** - * Default constructor - * - */ - public SimpleModelNavigationPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject simpleModelNavigation, String editing_mode) { - super(editingContext, simpleModelNavigation, editing_mode); - parts = new String[] { BASE_PART }; - repositoryKey = NavigationViewsRepository.class; - partKey = NavigationViewsRepository.SimpleModelNavigation.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final SimpleModelNavigation simpleModelNavigation = (SimpleModelNavigation)elt; - final SimpleModelNavigationPropertiesEditionPart basePart = (SimpleModelNavigationPropertiesEditionPart)editingPart; - // init values - if (isAccessible(NavigationViewsRepository.SimpleModelNavigation.Properties.index)) { - basePart.setIndex(EEFConverterUtil.convertToString(EcorePackage.Literals.EINT, simpleModelNavigation.getIndex())); - } - - if (isAccessible(NavigationViewsRepository.SimpleModelNavigation.Properties.feature)) { - // init part - featureSettings = new EObjectFlatComboSettings(simpleModelNavigation, NavigationPackage.eINSTANCE.getSimpleModelNavigation_Feature()); - basePart.initFeature(featureSettings); - // set the button mode - basePart.setFeatureButtonMode(ButtonsModeEnum.BROWSE); - } - if (isAccessible(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType)) { - // init part - discriminatorTypeSettings = new EObjectFlatComboSettings(simpleModelNavigation, NavigationPackage.eINSTANCE.getSimpleModelNavigation_DiscriminatorType()); - basePart.initDiscriminatorType(discriminatorTypeSettings); - // set the button mode - basePart.setDiscriminatorTypeButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - - if (isAccessible(NavigationViewsRepository.SimpleModelNavigation.Properties.feature)) { - basePart.addFilterToFeature(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EReference); - } - - }); - // Start of user code for additional businessfilters for feature - - // End of user code - } - if (isAccessible(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType)) { - basePart.addFilterToDiscriminatorType(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof String && element.equals("")) || (element instanceof EClassifier); //$NON-NLS-1$ - } - - }); - // Start of user code for additional businessfilters for discriminatorType - - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == NavigationViewsRepository.SimpleModelNavigation.Properties.index) { - return NavigationPackage.eINSTANCE.getSimpleModelNavigation_Index(); - } - if (editorKey == NavigationViewsRepository.SimpleModelNavigation.Properties.feature) { - return NavigationPackage.eINSTANCE.getSimpleModelNavigation_Feature(); - } - if (editorKey == NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType) { - return NavigationPackage.eINSTANCE.getSimpleModelNavigation_DiscriminatorType(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - SimpleModelNavigation simpleModelNavigation = (SimpleModelNavigation)semanticObject; - if (NavigationViewsRepository.SimpleModelNavigation.Properties.index == event.getAffectedEditor()) { - simpleModelNavigation.setIndex((EEFConverterUtil.createIntFromString(EcorePackage.Literals.EINT, (String)event.getNewValue()))); - } - if (NavigationViewsRepository.SimpleModelNavigation.Properties.feature == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - featureSettings.setToReference((EReference)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReference eObject = EcoreFactory.eINSTANCE.createEReference(); - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - featureSettings.setToReference(eObject); - } - } - if (NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - discriminatorTypeSettings.setToReference((EClassifier)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext(editingContext, this, discriminatorTypeSettings, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(semanticObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy instanceof CreateEditingPolicy) { - policy.execute(); - } - } - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - SimpleModelNavigationPropertiesEditionPart basePart = (SimpleModelNavigationPropertiesEditionPart)editingPart; - if (NavigationPackage.eINSTANCE.getSimpleModelNavigation_Index().equals(msg.getFeature()) && msg.getNotifier().equals(semanticObject) && basePart != null && isAccessible(NavigationViewsRepository.SimpleModelNavigation.Properties.index)) { - if (msg.getNewValue() != null) { - basePart.setIndex(EcoreUtil.convertToString(EcorePackage.Literals.EINT, msg.getNewValue())); - } else { - basePart.setIndex(""); - } - } - if (NavigationPackage.eINSTANCE.getSimpleModelNavigation_Feature().equals(msg.getFeature()) && basePart != null && isAccessible(NavigationViewsRepository.SimpleModelNavigation.Properties.feature)) - basePart.setFeature((EObject)msg.getNewValue()); - if (NavigationPackage.eINSTANCE.getSimpleModelNavigation_DiscriminatorType().equals(msg.getFeature()) && basePart != null && isAccessible(NavigationViewsRepository.SimpleModelNavigation.Properties.discriminatorType)) - basePart.setDiscriminatorType((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - NavigationPackage.eINSTANCE.getSimpleModelNavigation_Index(), - NavigationPackage.eINSTANCE.getSimpleModelNavigation_Feature(), - NavigationPackage.eINSTANCE.getSimpleModelNavigation_DiscriminatorType() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == NavigationViewsRepository.SimpleModelNavigation.Properties.feature; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - if (NavigationViewsRepository.SimpleModelNavigation.Properties.index == event.getAffectedEditor()) { - Object newValue = event.getNewValue(); - if (newValue instanceof String) { - newValue = EEFConverterUtil.createFromString(NavigationPackage.eINSTANCE.getSimpleModelNavigation_Index().getEAttributeType(), (String)newValue); - } - ret = Diagnostician.INSTANCE.validate(NavigationPackage.eINSTANCE.getSimpleModelNavigation_Index().getEAttributeType(), newValue); - } - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/DeclarativeNavigationStepPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/DeclarativeNavigationStepPropertiesEditionProvider.java deleted file mode 100644 index d72b5922b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/DeclarativeNavigationStepPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -import org.eclipse.emf.eef.navigation.components.DeclarativeNavigationStepPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class DeclarativeNavigationStepPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public DeclarativeNavigationStepPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public DeclarativeNavigationStepPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof DeclarativeNavigationStep) - && (NavigationPackage.Literals.DECLARATIVE_NAVIGATION_STEP == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof DeclarativeNavigationStep) && (DeclarativeNavigationStepPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof DeclarativeNavigationStep) && (refinement == DeclarativeNavigationStepPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof DeclarativeNavigationStep) && ((DeclarativeNavigationStepPropertiesEditionComponent.BASE_PART.equals(part) && refinement == DeclarativeNavigationStepPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof DeclarativeNavigationStep) { - return new DeclarativeNavigationStepPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof DeclarativeNavigationStep) { - if (DeclarativeNavigationStepPropertiesEditionComponent.BASE_PART.equals(part)) - return new DeclarativeNavigationStepPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof DeclarativeNavigationStep) { - if (DeclarativeNavigationStepPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == DeclarativeNavigationStepPropertiesEditionComponent.class) - return new DeclarativeNavigationStepPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && NavigationPackage.Literals.DECLARATIVE_NAVIGATION_STEP == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/JavaBodyStepInitializerPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/JavaBodyStepInitializerPropertiesEditionProvider.java deleted file mode 100644 index 7163f7636..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/JavaBodyStepInitializerPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -import org.eclipse.emf.eef.navigation.components.JavaBodyStepInitializerPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class JavaBodyStepInitializerPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public JavaBodyStepInitializerPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public JavaBodyStepInitializerPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof JavaBodyStepInitializer) - && (NavigationPackage.Literals.JAVA_BODY_STEP_INITIALIZER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof JavaBodyStepInitializer) && (JavaBodyStepInitializerPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaBodyStepInitializer) && (refinement == JavaBodyStepInitializerPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaBodyStepInitializer) && ((JavaBodyStepInitializerPropertiesEditionComponent.BASE_PART.equals(part) && refinement == JavaBodyStepInitializerPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof JavaBodyStepInitializer) { - return new JavaBodyStepInitializerPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof JavaBodyStepInitializer) { - if (JavaBodyStepInitializerPropertiesEditionComponent.BASE_PART.equals(part)) - return new JavaBodyStepInitializerPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof JavaBodyStepInitializer) { - if (JavaBodyStepInitializerPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == JavaBodyStepInitializerPropertiesEditionComponent.class) - return new JavaBodyStepInitializerPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && NavigationPackage.Literals.JAVA_BODY_STEP_INITIALIZER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/JavaDeclarationStepInitializerPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/JavaDeclarationStepInitializerPropertiesEditionProvider.java deleted file mode 100644 index 75ef16f63..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/JavaDeclarationStepInitializerPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -import org.eclipse.emf.eef.navigation.components.JavaDeclarationStepInitializerPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class JavaDeclarationStepInitializerPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public JavaDeclarationStepInitializerPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public JavaDeclarationStepInitializerPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof JavaDeclarationStepInitializer) - && (NavigationPackage.Literals.JAVA_DECLARATION_STEP_INITIALIZER == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof JavaDeclarationStepInitializer) && (JavaDeclarationStepInitializerPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaDeclarationStepInitializer) && (refinement == JavaDeclarationStepInitializerPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof JavaDeclarationStepInitializer) && ((JavaDeclarationStepInitializerPropertiesEditionComponent.BASE_PART.equals(part) && refinement == JavaDeclarationStepInitializerPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof JavaDeclarationStepInitializer) { - return new JavaDeclarationStepInitializerPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof JavaDeclarationStepInitializer) { - if (JavaDeclarationStepInitializerPropertiesEditionComponent.BASE_PART.equals(part)) - return new JavaDeclarationStepInitializerPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof JavaDeclarationStepInitializer) { - if (JavaDeclarationStepInitializerPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == JavaDeclarationStepInitializerPropertiesEditionComponent.class) - return new JavaDeclarationStepInitializerPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && NavigationPackage.Literals.JAVA_DECLARATION_STEP_INITIALIZER == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/NavigationEEFAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/NavigationEEFAdapterFactory.java deleted file mode 100644 index 3e8b14c9c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/NavigationEEFAdapterFactory.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.providers; - -import org.eclipse.emf.common.notify.Adapter; - -import org.eclipse.emf.eef.mapping.navigation.util.NavigationAdapterFactory; - -/** - * @author Nathalie Lepine - * - */ -public class NavigationEEFAdapterFactory extends NavigationAdapterFactory { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.navigation.util.NavigationAdapterFactory#createSimpleModelNavigationAdapter() - * - */ - public Adapter createSimpleModelNavigationAdapter() { - return new SimpleModelNavigationPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.navigation.util.NavigationAdapterFactory#createDeclarativeNavigationStepAdapter() - * - */ - public Adapter createDeclarativeNavigationStepAdapter() { - return new DeclarativeNavigationStepPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.navigation.util.NavigationAdapterFactory#createJavaDeclarationStepInitializerAdapter() - * - */ - public Adapter createJavaDeclarationStepInitializerAdapter() { - return new JavaDeclarationStepInitializerPropertiesEditionProvider(); - } - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.navigation.util.NavigationAdapterFactory#createJavaBodyStepInitializerAdapter() - * - */ - public Adapter createJavaBodyStepInitializerAdapter() { - return new JavaBodyStepInitializerPropertiesEditionProvider(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/SimpleModelNavigationPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/SimpleModelNavigationPropertiesEditionProvider.java deleted file mode 100644 index 293e974aa..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/navigation/providers/SimpleModelNavigationPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; - -import org.eclipse.emf.eef.navigation.components.SimpleModelNavigationPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class SimpleModelNavigationPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public SimpleModelNavigationPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public SimpleModelNavigationPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof SimpleModelNavigation) - && (NavigationPackage.Literals.SIMPLE_MODEL_NAVIGATION == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof SimpleModelNavigation) && (SimpleModelNavigationPropertiesEditionComponent.BASE_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof SimpleModelNavigation) && (refinement == SimpleModelNavigationPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof SimpleModelNavigation) && ((SimpleModelNavigationPropertiesEditionComponent.BASE_PART.equals(part) && refinement == SimpleModelNavigationPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof SimpleModelNavigation) { - return new SimpleModelNavigationPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof SimpleModelNavigation) { - if (SimpleModelNavigationPropertiesEditionComponent.BASE_PART.equals(part)) - return new SimpleModelNavigationPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof SimpleModelNavigation) { - if (SimpleModelNavigationPropertiesEditionComponent.BASE_PART.equals(part) - && refinement == SimpleModelNavigationPropertiesEditionComponent.class) - return new SimpleModelNavigationPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && NavigationPackage.Literals.SIMPLE_MODEL_NAVIGATION == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/components/EReferenceViewerSettingsPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/components/EReferenceViewerSettingsPropertiesEditionComponent.java deleted file mode 100644 index 301e19d32..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/components/EReferenceViewerSettingsPropertiesEditionComponent.java +++ /dev/null @@ -1,237 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.settings.components; - -// Start of user code for imports -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.WrappedException; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcoreFactory; - -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.util.EcoreUtil; - -import org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings; -import org.eclipse.emf.eef.mapping.settings.SettingsPackage; - -import org.eclipse.emf.eef.mapping.settings.parts.SettingsPropertiesEditionPart; -import org.eclipse.emf.eef.mapping.settings.parts.SettingsViewsRepository; - -import org.eclipse.emf.eef.runtime.api.notify.EStructuralFeatureNotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; - -import org.eclipse.emf.eef.runtime.impl.components.SinglePartPropertiesEditingComponent; - -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFConverterUtil; - -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.ui.widgets.ButtonsModeEnum; - -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; - -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - - -// End of user code - -/** - * @author Nathalie Lepine - * - */ -public class EReferenceViewerSettingsPropertiesEditionComponent extends SinglePartPropertiesEditingComponent { - - - public static String SETTINGS_PART = "Settings"; //$NON-NLS-1$ - - - /** - * Settings for model EObjectFlatComboViewer - */ - private EObjectFlatComboSettings modelSettings; - - - /** - * Default constructor - * - */ - public EReferenceViewerSettingsPropertiesEditionComponent(PropertiesEditingContext editingContext, EObject eReferenceViewerSettings, String editing_mode) { - super(editingContext, eReferenceViewerSettings, editing_mode); - parts = new String[] { SETTINGS_PART }; - repositoryKey = SettingsViewsRepository.class; - partKey = SettingsViewsRepository.Settings_.class; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - * - */ - public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) { - setInitializing(true); - if (editingPart != null && key == partKey) { - editingPart.setContext(elt, allResource); - - final EReferenceViewerSettings eReferenceViewerSettings = (EReferenceViewerSettings)elt; - final SettingsPropertiesEditionPart settingsPart = (SettingsPropertiesEditionPart)editingPart; - // init values - if (isAccessible(SettingsViewsRepository.Settings_.model)) { - // init part - modelSettings = new EObjectFlatComboSettings(eReferenceViewerSettings, SettingsPackage.eINSTANCE.getEReferenceViewerSettings_Model()); - settingsPart.initModel(modelSettings); - // set the button mode - settingsPart.setModelButtonMode(ButtonsModeEnum.BROWSE); - } - // init filters - if (isAccessible(SettingsViewsRepository.Settings_.model)) { - settingsPart.addFilterToModel(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EReference); - } - - }); - // Start of user code for additional businessfilters for model - // End of user code - } - // init values for referenced views - - // init filters for referenced views - - } - setInitializing(false); - } - - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - if (editorKey == SettingsViewsRepository.Settings_.model) { - return SettingsPackage.eINSTANCE.getEReferenceViewerSettings_Model(); - } - return super.associatedFeature(editorKey); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public void updateSemanticModel(final IPropertiesEditionEvent event) { - EReferenceViewerSettings eReferenceViewerSettings = (EReferenceViewerSettings)semanticObject; - if (SettingsViewsRepository.Settings_.model == event.getAffectedEditor()) { - if (event.getKind() == PropertiesEditionEvent.SET) { - modelSettings.setToReference((EReference)event.getNewValue()); - } else if (event.getKind() == PropertiesEditionEvent.ADD) { - EReference eObject = EcoreFactory.eINSTANCE.createEReference(); - EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext(editingContext, this, eObject, editingContext.getAdapterFactory()); - PropertiesEditingProvider provider = (PropertiesEditingProvider)editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - if (provider != null) { - PropertiesEditingPolicy policy = provider.getPolicy(context); - if (policy != null) { - policy.execute(); - } - } - modelSettings.setToReference(eObject); - } - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updatePart(org.eclipse.emf.common.notify.Notification) - */ - public void updatePart(Notification msg) { - super.updatePart(msg); - if (editingPart.isVisible()) { - SettingsPropertiesEditionPart settingsPart = (SettingsPropertiesEditionPart)editingPart; - if (SettingsPackage.eINSTANCE.getEReferenceViewerSettings_Model().equals(msg.getFeature()) && settingsPart != null && isAccessible(SettingsViewsRepository.Settings_.model)) - settingsPart.setModel((EObject)msg.getNewValue()); - - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#getNotificationFilters() - */ - @Override - protected NotificationFilter[] getNotificationFilters() { - NotificationFilter filter = new EStructuralFeatureNotificationFilter( - SettingsPackage.eINSTANCE.getEReferenceViewerSettings_Model() ); - return new NotificationFilter[] {filter,}; - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#isRequired(java.lang.Object, int) - * - */ - public boolean isRequired(Object key, int kind) { - return key == SettingsViewsRepository.Settings_.model; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - * - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - Diagnostic ret = Diagnostic.OK_INSTANCE; - if (event.getNewValue() != null) { - try { - } catch (IllegalArgumentException iae) { - ret = BasicDiagnostic.toDiagnostic(iae); - } catch (WrappedException we) { - ret = BasicDiagnostic.toDiagnostic(we); - } - } - return ret; - } - - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/providers/EReferenceViewerSettingsPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/providers/EReferenceViewerSettingsPropertiesEditionProvider.java deleted file mode 100644 index c17e41acd..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/providers/EReferenceViewerSettingsPropertiesEditionProvider.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.settings.providers; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings; -import org.eclipse.emf.eef.mapping.settings.SettingsPackage; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -import org.eclipse.emf.eef.settings.components.EReferenceViewerSettingsPropertiesEditionComponent; - -import org.eclipse.jface.viewers.IFilter; - -/** - * @author Nathalie Lepine - * - */ -public class EReferenceViewerSettingsPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * Constructor without provider for super types. - */ - public EReferenceViewerSettingsPropertiesEditionProvider() { - super(); - } - - /** - * Constructor with providers for super types. - * @param superProviders providers to use for super types. - */ - public EReferenceViewerSettingsPropertiesEditionProvider(List superProviders) { - super(superProviders); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - * - */ - public boolean provides(PropertiesEditingContext editingContext) { - return (editingContext.getEObject() instanceof EReferenceViewerSettings) - && (SettingsPackage.Literals.EREFERENCE_VIEWER_SETTINGS == editingContext.getEObject().eClass()); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - return (editingContext.getEObject() instanceof EReferenceViewerSettings) && (EReferenceViewerSettingsPropertiesEditionComponent.SETTINGS_PART.equals(part)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EReferenceViewerSettings) && (refinement == EReferenceViewerSettingsPropertiesEditionComponent.class); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.Class) - * - */ - @SuppressWarnings("rawtypes") - public boolean provides(PropertiesEditingContext editingContext, String part, java.lang.Class refinement) { - return (editingContext.getEObject() instanceof EReferenceViewerSettings) && ((EReferenceViewerSettingsPropertiesEditionComponent.SETTINGS_PART.equals(part) && refinement == EReferenceViewerSettingsPropertiesEditionComponent.class)); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - if (editingContext.getEObject() instanceof EReferenceViewerSettings) { - return new EReferenceViewerSettingsPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String) - * - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - if (editingContext.getEObject() instanceof EReferenceViewerSettings) { - if (EReferenceViewerSettingsPropertiesEditionComponent.SETTINGS_PART.equals(part)) - return new EReferenceViewerSettingsPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, java.lang.String, java.lang.String, java.lang.Class) - */ - @SuppressWarnings("rawtypes") - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, java.lang.Class refinement) { - if (editingContext.getEObject() instanceof EReferenceViewerSettings) { - if (EReferenceViewerSettingsPropertiesEditionComponent.SETTINGS_PART.equals(part) - && refinement == EReferenceViewerSettingsPropertiesEditionComponent.class) - return new EReferenceViewerSettingsPropertiesEditionComponent(editingContext, editingContext.getEObject(), mode); - } - return super.getPropertiesEditingComponent(editingContext, mode, part, refinement); - } - - /** - * Provides the filter used by the plugin.xml to assign part forms. - */ - public static class EditionFilter implements IFilter { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = EEFUtils.resolveSemanticObject(toTest); - return eObj != null && SettingsPackage.Literals.EREFERENCE_VIEWER_SETTINGS == eObj.eClass(); - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/providers/SettingsEEFAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/providers/SettingsEEFAdapterFactory.java deleted file mode 100644 index b646ee539..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/org/eclipse/emf/eef/settings/providers/SettingsEEFAdapterFactory.java +++ /dev/null @@ -1,32 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.settings.providers; - -import org.eclipse.emf.common.notify.Adapter; - -import org.eclipse.emf.eef.mapping.settings.util.SettingsAdapterFactory; - -/** - * @author Nathalie Lepine - * - */ -public class SettingsEEFAdapterFactory extends SettingsAdapterFactory { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.mapping.settings.util.SettingsAdapterFactory#createEReferenceViewerSettingsAdapter() - * - */ - public Adapter createEReferenceViewerSettingsAdapter() { - return new EReferenceViewerSettingsPropertiesEditionProvider(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/settings_properties.plugin.xml b/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/settings_properties.plugin.xml deleted file mode 100644 index 9e7da609a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src-gen/settings_properties.plugin.xml +++ /dev/null @@ -1,79 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/forms/DeclarativeNavigationStepCustomPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/forms/DeclarativeNavigationStepCustomPropertiesEditionPartForm.java deleted file mode 100644 index 2e32f63c2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/forms/DeclarativeNavigationStepCustomPropertiesEditionPartForm.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.parts.forms; - -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.parts.forms.DeclarativeNavigationStepPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * @author Nathalie Lepine - */ -public class DeclarativeNavigationStepCustomPropertiesEditionPartForm extends DeclarativeNavigationStepPropertiesEditionPartForm { - - public DeclarativeNavigationStepCustomPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * @param propertiesGroup - */ - protected Composite createFeatureFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - - FormUtils.createPartLabel(widgetFactory, parent, - NavigationMessages.DeclarativeNavigationStepPropertiesEditionPart_FeatureLabel, true); - feature = new EObjectFlatComboViewer(parent, false); - feature.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - feature.addFilter(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, - * java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EReference); - } - - }); - - GridData featureData = new GridData(GridData.FILL_HORIZONTAL); - feature.setLayoutData(featureData); - feature.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - DeclarativeNavigationStepCustomPropertiesEditionPartForm.this, - NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getFeature())); - setDiscriminatorInput((DeclarativeNavigationStep)current, resourceSet); - } - - }); - FormUtils.createHelpButton(widgetFactory, parent, null, null); //$NON-NLS-1$ - return parent; - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/forms/SimpleModelNavigationCustomPropertiesEditionPartForm.java b/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/forms/SimpleModelNavigationCustomPropertiesEditionPartForm.java deleted file mode 100644 index ef76c5530..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/forms/SimpleModelNavigationCustomPropertiesEditionPartForm.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.parts.forms; - -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.parts.forms.SimpleModelNavigationPropertiesEditionPartForm; -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.FormUtils; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * @author Nathalie Lepine - */ -public class SimpleModelNavigationCustomPropertiesEditionPartForm extends SimpleModelNavigationPropertiesEditionPartForm { - - public SimpleModelNavigationCustomPropertiesEditionPartForm(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * @param propertiesGroup - */ - protected Composite createFeatureFlatComboViewer(Composite parent, FormToolkit widgetFactory) { - - FormUtils.createPartLabel(widgetFactory, parent, - NavigationMessages.SimpleModelNavigationPropertiesEditionPart_FeatureLabel, true); - feature = new EObjectFlatComboViewer(parent, false); - feature.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - feature.addFilter(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, - * java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EReference); - } - - }); - - GridData featureData = new GridData(GridData.FILL_HORIZONTAL); - feature.setLayoutData(featureData); - feature.addSelectionChangedListener(new ISelectionChangedListener() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent) - */ - public void selectionChanged(SelectionChangedEvent event) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - SimpleModelNavigationCustomPropertiesEditionPartForm.this, - NavigationViewsRepository.SimpleModelNavigation.Properties.feature, - PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getFeature())); - setDiscriminatorInput((SimpleModelNavigation)current, resourceSet); - } - - }); - FormUtils.createHelpButton(widgetFactory, parent, null, null); //$NON-NLS-1$ - return parent; - } -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/impl/DeclarativeNavigationStepCustomPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/impl/DeclarativeNavigationStepCustomPropertiesEditionPartImpl.java deleted file mode 100644 index 84e6ba9d0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/impl/DeclarativeNavigationStepCustomPropertiesEditionPartImpl.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.parts.impl; - -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.parts.impl.DeclarativeNavigationStepPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.widgets.Composite; - -/** - * @author Nathalie Lepine - */ -public class DeclarativeNavigationStepCustomPropertiesEditionPartImpl extends DeclarativeNavigationStepPropertiesEditionPartImpl { - - public DeclarativeNavigationStepCustomPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * @param propertiesGroup - */ - protected Composite createFeatureFlatComboViewer(Composite parent) { - - SWTUtils.createPartLabel(parent, - NavigationMessages.DeclarativeNavigationStepPropertiesEditionPart_FeatureLabel, true); - feature = new EObjectFlatComboViewer(parent, false); - feature.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - feature.addFilter(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, - * java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EReference); - } - - }); - feature.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - DeclarativeNavigationStepCustomPropertiesEditionPartImpl.this, - NavigationViewsRepository.DeclarativeNavigationStep.Properties.feature, PropertiesEditionEvent.COMMIT, - PropertiesEditionEvent.SET, null, getFeature())); - // TODO : firePropertyChanged has to call setFeature ! - // if (event.getSelection() instanceof StructuredSelection) { - // Object selection = ((StructuredSelection)event.getSelection()).getFirstElement(); - // if (selection instanceof EReference) { - // current.setFeature((EReference) selection); - setDiscriminatorInput((DeclarativeNavigationStep)current, resourceSet); - // } - // } - } - - }); - GridData featureData = new GridData(GridData.FILL_HORIZONTAL); - feature.setLayoutData(featureData); - SWTUtils.createHelpButton(parent, null, null); //$NON-NLS-1$ - return parent; - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/impl/SimpleModelNavigationCustomPropertiesEditionPartImpl.java b/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/impl/SimpleModelNavigationCustomPropertiesEditionPartImpl.java deleted file mode 100644 index a2c5f8f69..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/parts/impl/SimpleModelNavigationCustomPropertiesEditionPartImpl.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.parts.impl; - -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.navigation.parts.impl.SimpleModelNavigationPropertiesEditionPartImpl; -import org.eclipse.emf.eef.mapping.navigation.providers.NavigationMessages; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.ui.widgets.EObjectFlatComboViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.widgets.Composite; - -/** - * @author Nathalie Lepine - */ -public class SimpleModelNavigationCustomPropertiesEditionPartImpl extends SimpleModelNavigationPropertiesEditionPartImpl { - - public SimpleModelNavigationCustomPropertiesEditionPartImpl(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * @param propertiesGroup - */ - protected Composite createFeatureFlatComboViewer(Composite parent) { - - SWTUtils.createPartLabel(parent, - NavigationMessages.SimpleModelNavigationPropertiesEditionPart_FeatureLabel, true); - feature = new EObjectFlatComboViewer(parent, false); - feature.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - feature.addFilter(new ViewerFilter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, - * java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return (element instanceof EReference); - } - - }); - feature.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent( - SimpleModelNavigationCustomPropertiesEditionPartImpl.this, - NavigationViewsRepository.SimpleModelNavigation.Properties.feature, PropertiesEditionEvent.COMMIT, - PropertiesEditionEvent.SET, null, getFeature())); - // TODO : firePropertyChanged has to call setFeature ! - // if (event.getSelection() instanceof StructuredSelection) { - // Object selection = ((StructuredSelection)event.getSelection()).getFirstElement(); - // if (selection instanceof EReference) { - // current.setFeature((EReference) selection); - setDiscriminatorInput((SimpleModelNavigation)current, resourceSet); - // } - // } - } - - }); - GridData featureData = new GridData(GridData.FILL_HORIZONTAL); - feature.setLayoutData(featureData); - SWTUtils.createHelpButton(parent, null, null); //$NON-NLS-1$ - return parent; - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/providers/MappingCustomPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/providers/MappingCustomPropertiesEditionPartProvider.java deleted file mode 100644 index 41d189b14..000000000 --- a/plugins/org.eclipse.emf.eef.mapping.edit/src/org/eclipse/emf/eef/navigation/providers/MappingCustomPropertiesEditionPartProvider.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.navigation.providers; - -import org.eclipse.emf.eef.mapping.navigation.parts.NavigationViewsRepository; -import org.eclipse.emf.eef.mapping.parts.MappingViewsRepository; -import org.eclipse.emf.eef.mapping.providers.MappingPropertiesEditionPartProvider; -import org.eclipse.emf.eef.navigation.parts.forms.DeclarativeNavigationStepCustomPropertiesEditionPartForm; -import org.eclipse.emf.eef.navigation.parts.forms.SimpleModelNavigationCustomPropertiesEditionPartForm; -import org.eclipse.emf.eef.navigation.parts.impl.DeclarativeNavigationStepCustomPropertiesEditionPartImpl; -import org.eclipse.emf.eef.navigation.parts.impl.SimpleModelNavigationCustomPropertiesEditionPartImpl; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -/** - * @author Stephane Bouchet - */ -public class MappingCustomPropertiesEditionPartProvider extends MappingPropertiesEditionPartProvider { - - @Override - public IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, - IPropertiesEditionComponent component) { - if (key == NavigationViewsRepository.SimpleModelNavigation.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new SimpleModelNavigationCustomPropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new SimpleModelNavigationCustomPropertiesEditionPartForm(component); - } else if (key == NavigationViewsRepository.DeclarativeNavigationStep.class) { - if (kind == MappingViewsRepository.SWT_KIND) - return new DeclarativeNavigationStepCustomPropertiesEditionPartImpl(component); - if (kind == MappingViewsRepository.FORM_KIND) - return new DeclarativeNavigationStepCustomPropertiesEditionPartForm(component); - } - return super.getPropertiesEditionPart(key, kind, component); - } - -} diff --git a/plugins/org.eclipse.emf.eef.mapping/.checkstyle b/plugins/org.eclipse.emf.eef.mapping/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping/.classpath b/plugins/org.eclipse.emf.eef.mapping/.classpath deleted file mode 100644 index f9c46b584..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping/.gitignore b/plugins/org.eclipse.emf.eef.mapping/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.mapping/.project b/plugins/org.eclipse.emf.eef.mapping/.project deleted file mode 100644 index 034d3feb0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.mapping - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.mapping/.settings/org.eclipse.core.resources.prefs b/plugins/org.eclipse.emf.eef.mapping/.settings/org.eclipse.core.resources.prefs deleted file mode 100644 index 4f0042273..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/.settings/org.eclipse.core.resources.prefs +++ /dev/null @@ -1,3 +0,0 @@ -#Tue May 05 15:44:27 CEST 2009 -eclipse.preferences.version=1 -encoding//model/mapping.ecore=UTF-8 diff --git a/plugins/org.eclipse.emf.eef.mapping/.settings/org.eclipse.jdt.ui.prefs b/plugins/org.eclipse.emf.eef.mapping/.settings/org.eclipse.jdt.ui.prefs deleted file mode 100644 index 4c8ce2581..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/.settings/org.eclipse.jdt.ui.prefs +++ /dev/null @@ -1,4 +0,0 @@ -#Mon May 25 14:42:46 CEST 2009 -eclipse.preferences.version=1 -formatter_settings_version=11 -org.eclipse.jdt.ui.text.custom_code_templates= diff --git a/plugins/org.eclipse.emf.eef.mapping/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.mapping/META-INF/MANIFEST.MF deleted file mode 100644 index 99915a6b4..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/META-INF/MANIFEST.MF +++ /dev/null @@ -1,24 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Mapping Model -Bundle-SymbolicName: org.eclipse.emf.eef.mapping;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Vendor: Eclipse Modeling Project -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.mapping, - org.eclipse.emf.eef.mapping.filters, - org.eclipse.emf.eef.mapping.filters.impl, - org.eclipse.emf.eef.mapping.filters.util, - org.eclipse.emf.eef.mapping.impl, - org.eclipse.emf.eef.mapping.navigation, - org.eclipse.emf.eef.mapping.navigation.impl, - org.eclipse.emf.eef.mapping.navigation.util, - org.eclipse.emf.eef.mapping.settings, - org.eclipse.emf.eef.mapping.settings.impl, - org.eclipse.emf.eef.mapping.settings.util, - org.eclipse.emf.eef.mapping.util -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.4.0", - org.eclipse.emf.ecore;bundle-version="2.4.0";visibility:=reexport, - org.eclipse.emf.eef.views -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.mapping/about.html b/plugins/org.eclipse.emf.eef.mapping/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.mapping/build.properties b/plugins/org.eclipse.emf.eef.mapping/build.properties deleted file mode 100644 index 14e4c2cba..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/build.properties +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -bin.includes = .,\ - model/,\ - META-INF/,\ - plugin.xml,\ - about.html -jars.compile.order = . -source.. = src-gen/ -output.. = bin/ -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.mapping/model/mapping.ecore b/plugins/org.eclipse.emf.eef.mapping/model/mapping.ecore deleted file mode 100644 index f33679f31..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/model/mapping.ecore +++ /dev/null @@ -1,194 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping/model/mapping.ecorediag b/plugins/org.eclipse.emf.eef.mapping/model/mapping.ecorediag deleted file mode 100644 index 89106cd04..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/model/mapping.ecorediag +++ /dev/null @@ -1,815 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping/model/mapping.genmodel b/plugins/org.eclipse.emf.eef.mapping/model/mapping.genmodel deleted file mode 100644 index 17da9f126..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/model/mapping.genmodel +++ /dev/null @@ -1,192 +0,0 @@ - - - mapping.ecore - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping/plugin.properties b/plugins/org.eclipse.emf.eef.mapping/plugin.properties deleted file mode 100644 index cc1690a66..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/plugin.properties +++ /dev/null @@ -1,8 +0,0 @@ - -# -# -# -# $Id$ - -pluginName = Mapping Model -providerName = www.example.org diff --git a/plugins/org.eclipse.emf.eef.mapping/plugin.xml b/plugins/org.eclipse.emf.eef.mapping/plugin.xml deleted file mode 100644 index 16030732b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/plugin.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.mapping/pom.xml b/plugins/org.eclipse.emf.eef.mapping/pom.xml deleted file mode 100644 index 51235a7dd..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/pom.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.mapping - eclipse-plugin - - EEF Mapping Model Plug-in - diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/AbstractElementBinding.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/AbstractElementBinding.java deleted file mode 100644 index fd5e28bb8..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/AbstractElementBinding.java +++ /dev/null @@ -1,237 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.views.View; - -/** - * - * A representation of the model object 'Abstract Element Binding'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getSubElements Sub Elements}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getProperties Properties}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getDatabinding Databinding}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getSuperElement Super Element}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getName Name}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getReferencedBinding Referenced Binding}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getViews Views}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getCategory Category}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getBindingFilters Binding Filters}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractElementBinding() - * @model abstract="true" - * @generated - */ -public interface AbstractElementBinding extends DocumentedElement { - /** - * Returns the value of the 'Sub Elements' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.AbstractElementBinding}. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getSuperElement Super Element}'. - * - *

- * If the meaning of the 'Sub Elements' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Sub Elements' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractElementBinding_SubElements() - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getSuperElement - * @model opposite="superElement" containment="true" - * @generated - */ - EList getSubElements(); - - /** - * Returns the value of the 'Properties' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding}. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getElement Element}'. - * - *

- * If the meaning of the 'Properties' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Properties' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractElementBinding_Properties() - * @see org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getElement - * @model opposite="element" containment="true" - * @generated - */ - EList getProperties(); - - /** - * Returns the value of the 'Databinding' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.Databinding#getBindings Bindings}'. - * - *

- * If the meaning of the 'Databinding' container reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Databinding' container reference. - * @see #setDatabinding(Databinding) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractElementBinding_Databinding() - * @see org.eclipse.emf.eef.mapping.Databinding#getBindings - * @model opposite="bindings" transient="false" - * @generated - */ - Databinding getDatabinding(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getDatabinding Databinding}' container reference. - * - * - * @param value the new value of the 'Databinding' container reference. - * @see #getDatabinding() - * @generated - */ - void setDatabinding(Databinding value); - - /** - * Returns the value of the 'Super Element' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getSubElements Sub Elements}'. - * - *

- * If the meaning of the 'Super Element' container reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Super Element' container reference. - * @see #setSuperElement(AbstractElementBinding) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractElementBinding_SuperElement() - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getSubElements - * @model opposite="subElements" transient="false" - * @generated - */ - AbstractElementBinding getSuperElement(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getSuperElement Super Element}' container reference. - * - * - * @param value the new value of the 'Super Element' container reference. - * @see #getSuperElement() - * @generated - */ - void setSuperElement(AbstractElementBinding value); - - /** - * Returns the value of the 'Name' attribute. - * - *

- * If the meaning of the 'Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Name' attribute. - * @see #setName(String) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractElementBinding_Name() - * @model required="true" - * @generated - */ - String getName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getName Name}' attribute. - * - * - * @param value the new value of the 'Name' attribute. - * @see #getName() - * @generated - */ - void setName(String value); - - /** - * Returns the value of the 'Referenced Binding' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.ElementBindingReference}. - * - *

- * If the meaning of the 'Referenced Binding' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Referenced Binding' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractElementBinding_ReferencedBinding() - * @model containment="true" - * @generated - */ - EList getReferencedBinding(); - - /** - * Returns the value of the 'Views' reference list. - * The list contents are of type {@link org.eclipse.emf.eef.views.View}. - * - *

- * If the meaning of the 'Views' reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Views' reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractElementBinding_Views() - * @model required="true" - * @generated - */ - EList getViews(); - - /** - * Returns the value of the 'Category' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.Category#getBindings Bindings}'. - * - *

- * If the meaning of the 'Category' container reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Category' container reference. - * @see #setCategory(Category) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractElementBinding_Category() - * @see org.eclipse.emf.eef.mapping.Category#getBindings - * @model opposite="bindings" transient="false" - * @generated - */ - Category getCategory(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getCategory Category}' container reference. - * - * - * @param value the new value of the 'Category' container reference. - * @see #getCategory() - * @generated - */ - void setCategory(Category value); - - /** - * Returns the value of the 'Binding Filters' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.filters.BindingFilter}. - * - *

- * If the meaning of the 'Binding Filters' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Binding Filters' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractElementBinding_BindingFilters() - * @model containment="true" - * @generated - */ - EList getBindingFilters(); - -} // AbstractElementBinding diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/AbstractPropertyBinding.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/AbstractPropertyBinding.java deleted file mode 100644 index 2dd25527e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/AbstractPropertyBinding.java +++ /dev/null @@ -1,124 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.views.ElementEditor; - -/** - * - * A representation of the model object 'Abstract Property Binding'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getName Name}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getViews Views}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getElement Element}
  • - *
  • {@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getBindingFilters Binding Filters}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractPropertyBinding() - * @model abstract="true" - * @generated - */ -public interface AbstractPropertyBinding extends DocumentedElement { - /** - * Returns the value of the 'Name' attribute. - * - *

- * If the meaning of the 'Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Name' attribute. - * @see #setName(String) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractPropertyBinding_Name() - * @model required="true" - * @generated - */ - String getName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getName Name}' attribute. - * - * - * @param value the new value of the 'Name' attribute. - * @see #getName() - * @generated - */ - void setName(String value); - - /** - * Returns the value of the 'Views' reference list. - * The list contents are of type {@link org.eclipse.emf.eef.views.ElementEditor}. - * - *

- * If the meaning of the 'Views' reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Views' reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractPropertyBinding_Views() - * @model required="true" - * @generated - */ - EList getViews(); - - /** - * Returns the value of the 'Element' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getProperties Properties}'. - * - *

- * If the meaning of the 'Element' container reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Element' container reference. - * @see #setElement(AbstractElementBinding) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractPropertyBinding_Element() - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getProperties - * @model opposite="properties" transient="false" - * @generated - */ - AbstractElementBinding getElement(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getElement Element}' container reference. - * - * - * @param value the new value of the 'Element' container reference. - * @see #getElement() - * @generated - */ - void setElement(AbstractElementBinding value); - - /** - * Returns the value of the 'Binding Filters' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.filters.BindingFilter}. - * - *

- * If the meaning of the 'Binding Filters' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Binding Filters' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getAbstractPropertyBinding_BindingFilters() - * @model containment="true" - * @generated - */ - EList getBindingFilters(); - -} // AbstractPropertyBinding diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/Category.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/Category.java deleted file mode 100644 index 121e5b649..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/Category.java +++ /dev/null @@ -1,124 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.eef.mapping.DocumentedElement; - -/** - * - * A representation of the model object 'Category'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.Category#getName Name}
  • - *
  • {@link org.eclipse.emf.eef.mapping.Category#getBindings Bindings}
  • - *
  • {@link org.eclipse.emf.eef.mapping.Category#getDatabinding Databinding}
  • - *
  • {@link org.eclipse.emf.eef.mapping.Category#getCategories Categories}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getCategory() - * @model - * @generated - */ -public interface Category extends DocumentedElement { - /** - * Returns the value of the 'Name' attribute. - * - *

- * If the meaning of the 'Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Name' attribute. - * @see #setName(String) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getCategory_Name() - * @model required="true" - * @generated - */ - String getName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.Category#getName Name}' attribute. - * - * - * @param value the new value of the 'Name' attribute. - * @see #getName() - * @generated - */ - void setName(String value); - - /** - * Returns the value of the 'Bindings' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.AbstractElementBinding}. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getCategory Category}'. - * - *

- * If the meaning of the 'Bindings' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Bindings' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getCategory_Bindings() - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getCategory - * @model opposite="category" containment="true" - * @generated - */ - EList getBindings(); - - /** - * Returns the value of the 'Databinding' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.Databinding#getCategories Categories}'. - * - *

- * If the meaning of the 'Databinding' container reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Databinding' container reference. - * @see #setDatabinding(Databinding) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getCategory_Databinding() - * @see org.eclipse.emf.eef.mapping.Databinding#getCategories - * @model opposite="categories" transient="false" - * @generated - */ - Databinding getDatabinding(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.Category#getDatabinding Databinding}' container reference. - * - * - * @param value the new value of the 'Databinding' container reference. - * @see #getDatabinding() - * @generated - */ - void setDatabinding(Databinding value); - - /** - * Returns the value of the 'Categories' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.Category}. - * - *

- * If the meaning of the 'Categories' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Categories' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getCategory_Categories() - * @model containment="true" - * @generated - */ - EList getCategories(); - -} // Category diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/Databinding.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/Databinding.java deleted file mode 100644 index 162badc9a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/Databinding.java +++ /dev/null @@ -1,70 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.eef.mapping.DocumentedElement; - -/** - * - * A representation of the model object 'Databinding'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.Databinding#getBindings Bindings}
  • - *
  • {@link org.eclipse.emf.eef.mapping.Databinding#getCategories Categories}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getDatabinding() - * @model - * @generated - */ -public interface Databinding extends DocumentedElement { - /** - * Returns the value of the 'Bindings' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.AbstractElementBinding}. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getDatabinding Databinding}'. - * - *

- * If the meaning of the 'Bindings' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Bindings' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getDatabinding_Bindings() - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getDatabinding - * @model opposite="databinding" containment="true" - * @generated - */ - EList getBindings(); - - /** - * Returns the value of the 'Categories' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.Category}. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.Category#getDatabinding Databinding}'. - * - *

- * If the meaning of the 'Categories' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Categories' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getDatabinding_Categories() - * @see org.eclipse.emf.eef.mapping.Category#getDatabinding - * @model opposite="databinding" containment="true" - * @generated - */ - EList getCategories(); - -} // Databinding diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/DocumentedElement.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/DocumentedElement.java deleted file mode 100644 index 9778373db..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/DocumentedElement.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Documented Element'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.DocumentedElement#getDocumentation Documentation}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getDocumentedElement() - * @model abstract="true" - * @generated - */ -public interface DocumentedElement extends EObject { - /** - * Returns the value of the 'Documentation' attribute. - * - *

- * If the meaning of the 'Documentation' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Documentation' attribute. - * @see #setDocumentation(String) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getDocumentedElement_Documentation() - * @model - * @generated - */ - String getDocumentation(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.DocumentedElement#getDocumentation Documentation}' attribute. - * - * - * @param value the new value of the 'Documentation' attribute. - * @see #getDocumentation() - * @generated - */ - void setDocumentation(String value); - -} // DocumentedElement diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFElementBinding.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFElementBinding.java deleted file mode 100644 index 720e962a2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFElementBinding.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.ecore.EClassifier; - -/** - * - * A representation of the model object 'EMF Element Binding'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.EMFElementBinding#getModel Model}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getEMFElementBinding() - * @model - * @generated - */ -public interface EMFElementBinding extends AbstractElementBinding { - /** - * Returns the value of the 'Model' reference. - * - *

- * If the meaning of the 'Model' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Model' reference. - * @see #setModel(EClassifier) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getEMFElementBinding_Model() - * @model required="true" - * @generated - */ - EClassifier getModel(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.EMFElementBinding#getModel Model}' reference. - * - * - * @param value the new value of the 'Model' reference. - * @see #getModel() - * @generated - */ - void setModel(EClassifier value); - -} // EMFElementBinding diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFMultiPropertiesBinding.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFMultiPropertiesBinding.java deleted file mode 100644 index f2397e096..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFMultiPropertiesBinding.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; - -/** - * - * A representation of the model object 'EMF Multi Properties Binding'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding#getModel Model}
  • - *
  • {@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding#getNavigation Navigation}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getEMFMultiPropertiesBinding() - * @model - * @generated - */ -public interface EMFMultiPropertiesBinding extends AbstractPropertyBinding { - /** - * Returns the value of the 'Model' reference list. - * The list contents are of type {@link org.eclipse.emf.ecore.EStructuralFeature}. - * - *

- * If the meaning of the 'Model' reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Model' reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getEMFMultiPropertiesBinding_Model() - * @model required="true" - * @generated - */ - EList getModel(); - - /** - * Returns the value of the 'Navigation' containment reference. - * - *

- * If the meaning of the 'Navigation' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Navigation' containment reference. - * @see #setNavigation(ModelNavigation) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getEMFMultiPropertiesBinding_Navigation() - * @model containment="true" - * @generated - */ - ModelNavigation getNavigation(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding#getNavigation Navigation}' containment reference. - * - * - * @param value the new value of the 'Navigation' containment reference. - * @see #getNavigation() - * @generated - */ - void setNavigation(ModelNavigation value); - -} // EMFMultiPropertiesBinding diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFPropertyBinding.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFPropertyBinding.java deleted file mode 100644 index 47b20f3fd..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/EMFPropertyBinding.java +++ /dev/null @@ -1,114 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; -import org.eclipse.emf.eef.mapping.settings.EditorSettings; - -/** - * - * A representation of the model object 'EMF Property Binding'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.EMFPropertyBinding#getModel Model}
  • - *
  • {@link org.eclipse.emf.eef.mapping.EMFPropertyBinding#getNavigation Navigation}
  • - *
  • {@link org.eclipse.emf.eef.mapping.EMFPropertyBinding#getEditorSetting Editor Setting}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getEMFPropertyBinding() - * @model - * @generated - */ -public interface EMFPropertyBinding extends AbstractPropertyBinding { - /** - * Returns the value of the 'Model' reference. - * - *

- * If the meaning of the 'Model' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Model' reference. - * @see #setModel(EStructuralFeature) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getEMFPropertyBinding_Model() - * @model required="true" - * @generated - */ - EStructuralFeature getModel(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.EMFPropertyBinding#getModel Model}' reference. - * - * - * @param value the new value of the 'Model' reference. - * @see #getModel() - * @generated - */ - void setModel(EStructuralFeature value); - - /** - * Returns the value of the 'Navigation' containment reference. - * - *

- * If the meaning of the 'Navigation' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Navigation' containment reference. - * @see #setNavigation(ModelNavigation) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getEMFPropertyBinding_Navigation() - * @model containment="true" - * @generated - */ - ModelNavigation getNavigation(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.EMFPropertyBinding#getNavigation Navigation}' containment reference. - * - * - * @param value the new value of the 'Navigation' containment reference. - * @see #getNavigation() - * @generated - */ - void setNavigation(ModelNavigation value); - - /** - * Returns the value of the 'Editor Setting' containment reference. - * - *

- * If the meaning of the 'Editor Setting' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Editor Setting' containment reference. - * @see #setEditorSetting(EditorSettings) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getEMFPropertyBinding_EditorSetting() - * @model containment="true" - * @generated - */ - EditorSettings getEditorSetting(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.EMFPropertyBinding#getEditorSetting Editor Setting}' containment reference. - * - * - * @param value the new value of the 'Editor Setting' containment reference. - * @see #getEditorSetting() - * @generated - */ - void setEditorSetting(EditorSettings value); - -} // EMFPropertyBinding diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ElementBindingReference.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ElementBindingReference.java deleted file mode 100644 index 5d2af2dcf..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ElementBindingReference.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.eef.mapping.DocumentedElement; - -/** - * - * A representation of the model object 'Element Binding Reference'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.ElementBindingReference#getBinding Binding}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getElementBindingReference() - * @model - * @generated - */ -public interface ElementBindingReference extends DocumentedElement { - /** - * Returns the value of the 'Binding' reference. - * - *

- * If the meaning of the 'Binding' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Binding' reference. - * @see #setBinding(AbstractElementBinding) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getElementBindingReference_Binding() - * @model required="true" - * @generated - */ - AbstractElementBinding getBinding(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.ElementBindingReference#getBinding Binding}' reference. - * - * - * @param value the new value of the 'Binding' reference. - * @see #getBinding() - * @generated - */ - void setBinding(AbstractElementBinding value); - -} // ElementBindingReference diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/MappingFactory.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/MappingFactory.java deleted file mode 100644 index 3ded1beac..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/MappingFactory.java +++ /dev/null @@ -1,114 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.mapping.MappingPackage - * @generated - */ -public interface MappingFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - MappingFactory eINSTANCE = org.eclipse.emf.eef.mapping.impl.MappingFactoryImpl - .init(); - - /** - * Returns a new object of class 'Databinding'. - * - * - * @return a new object of class 'Databinding'. - * @generated - */ - Databinding createDatabinding(); - - /** - * Returns a new object of class 'EMF Element Binding'. - * - * - * @return a new object of class 'EMF Element Binding'. - * @generated - */ - EMFElementBinding createEMFElementBinding(); - - /** - * Returns a new object of class 'EMF Property Binding'. - * - * - * @return a new object of class 'EMF Property Binding'. - * @generated - */ - EMFPropertyBinding createEMFPropertyBinding(); - - /** - * Returns a new object of class 'Standard Element Binding'. - * - * - * @return a new object of class 'Standard Element Binding'. - * @generated - */ - StandardElementBinding createStandardElementBinding(); - - /** - * Returns a new object of class 'Standard Property Binding'. - * - * - * @return a new object of class 'Standard Property Binding'. - * @generated - */ - StandardPropertyBinding createStandardPropertyBinding(); - - /** - * Returns a new object of class 'Category'. - * - * - * @return a new object of class 'Category'. - * @generated - */ - Category createCategory(); - - /** - * Returns a new object of class 'Element Binding Reference'. - * - * - * @return a new object of class 'Element Binding Reference'. - * @generated - */ - ElementBindingReference createElementBindingReference(); - - /** - * Returns a new object of class 'EMF Multi Properties Binding'. - * - * - * @return a new object of class 'EMF Multi Properties Binding'. - * @generated - */ - EMFMultiPropertiesBinding createEMFMultiPropertiesBinding(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - MappingPackage getMappingPackage(); - -} //MappingFactory diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/MappingPackage.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/MappingPackage.java deleted file mode 100644 index 718650853..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/MappingPackage.java +++ /dev/null @@ -1,1989 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.mapping.MappingFactory - * @model kind="package" - * @generated - */ -public interface MappingPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "mapping"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/mapping/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-mapping"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - MappingPackage eINSTANCE = org.eclipse.emf.eef.mapping.impl.MappingPackageImpl - .init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.DocumentedElementImpl Documented Element}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.DocumentedElementImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getDocumentedElement() - * @generated - */ - int DOCUMENTED_ELEMENT = 11; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int DOCUMENTED_ELEMENT__DOCUMENTATION = 0; - - /** - * The number of structural features of the 'Documented Element' class. - * - * - * @generated - * @ordered - */ - int DOCUMENTED_ELEMENT_FEATURE_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.DatabindingImpl Databinding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.DatabindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getDatabinding() - * @generated - */ - int DATABINDING = 0; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int DATABINDING__DOCUMENTATION = DOCUMENTED_ELEMENT__DOCUMENTATION; - - /** - * The feature id for the 'Bindings' containment reference list. - * - * - * @generated - * @ordered - */ - int DATABINDING__BINDINGS = DOCUMENTED_ELEMENT_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Categories' containment reference list. - * - * - * @generated - * @ordered - */ - int DATABINDING__CATEGORIES = DOCUMENTED_ELEMENT_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Databinding' class. - * - * - * @generated - * @ordered - */ - int DATABINDING_FEATURE_COUNT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.ModelElementImpl Model Element}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.ModelElementImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getModelElement() - * @generated - */ - int MODEL_ELEMENT = 1; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int MODEL_ELEMENT__DOCUMENTATION = DOCUMENTED_ELEMENT__DOCUMENTATION; - - /** - * The feature id for the 'Properties' containment reference list. - * - * - * @generated - * @ordered - */ - int MODEL_ELEMENT__PROPERTIES = DOCUMENTED_ELEMENT_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Sub Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int MODEL_ELEMENT__SUB_ELEMENTS = DOCUMENTED_ELEMENT_FEATURE_COUNT + 1; - - /** - * The feature id for the 'Binding' reference. - * - * - * @generated - * @ordered - */ - int MODEL_ELEMENT__BINDING = DOCUMENTED_ELEMENT_FEATURE_COUNT + 2; - - /** - * The feature id for the 'Super Element' container reference. - * - * - * @generated - * @ordered - */ - int MODEL_ELEMENT__SUPER_ELEMENT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 3; - - /** - * The number of structural features of the 'Model Element' class. - * - * - * @generated - * @ordered - */ - int MODEL_ELEMENT_FEATURE_COUNT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 4; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl Abstract Element Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getAbstractElementBinding() - * @generated - */ - int ABSTRACT_ELEMENT_BINDING = 2; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING__DOCUMENTATION = DOCUMENTED_ELEMENT__DOCUMENTATION; - - /** - * The feature id for the 'Sub Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS = DOCUMENTED_ELEMENT_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Properties' containment reference list. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING__PROPERTIES = DOCUMENTED_ELEMENT_FEATURE_COUNT + 1; - - /** - * The feature id for the 'Databinding' container reference. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING__DATABINDING = DOCUMENTED_ELEMENT_FEATURE_COUNT + 2; - - /** - * The feature id for the 'Super Element' container reference. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 3; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING__NAME = DOCUMENTED_ELEMENT_FEATURE_COUNT + 4; - - /** - * The feature id for the 'Referenced Binding' containment reference list. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING = DOCUMENTED_ELEMENT_FEATURE_COUNT + 5; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING__VIEWS = DOCUMENTED_ELEMENT_FEATURE_COUNT + 6; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING__CATEGORY = DOCUMENTED_ELEMENT_FEATURE_COUNT + 7; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS = DOCUMENTED_ELEMENT_FEATURE_COUNT + 8; - - /** - * The number of structural features of the 'Abstract Element Binding' class. - * - * - * @generated - * @ordered - */ - int ABSTRACT_ELEMENT_BINDING_FEATURE_COUNT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 9; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.ModelPropertyImpl Model Property}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.ModelPropertyImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getModelProperty() - * @generated - */ - int MODEL_PROPERTY = 3; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int MODEL_PROPERTY__DOCUMENTATION = DOCUMENTED_ELEMENT__DOCUMENTATION; - - /** - * The feature id for the 'Binding' reference. - * - * - * @generated - * @ordered - */ - int MODEL_PROPERTY__BINDING = DOCUMENTED_ELEMENT_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Model Element' container reference. - * - * - * @generated - * @ordered - */ - int MODEL_PROPERTY__MODEL_ELEMENT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Model Property' class. - * - * - * @generated - * @ordered - */ - int MODEL_PROPERTY_FEATURE_COUNT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.AbstractPropertyBindingImpl Abstract Property Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.AbstractPropertyBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getAbstractPropertyBinding() - * @generated - */ - int ABSTRACT_PROPERTY_BINDING = 4; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int ABSTRACT_PROPERTY_BINDING__DOCUMENTATION = DOCUMENTED_ELEMENT__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int ABSTRACT_PROPERTY_BINDING__NAME = DOCUMENTED_ELEMENT_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int ABSTRACT_PROPERTY_BINDING__VIEWS = DOCUMENTED_ELEMENT_FEATURE_COUNT + 1; - - /** - * The feature id for the 'Element' container reference. - * - * - * @generated - * @ordered - */ - int ABSTRACT_PROPERTY_BINDING__ELEMENT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 2; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS = DOCUMENTED_ELEMENT_FEATURE_COUNT + 3; - - /** - * The number of structural features of the 'Abstract Property Binding' class. - * - * - * @generated - * @ordered - */ - int ABSTRACT_PROPERTY_BINDING_FEATURE_COUNT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 4; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.EMFElementBindingImpl EMF Element Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.EMFElementBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getEMFElementBinding() - * @generated - */ - int EMF_ELEMENT_BINDING = 5; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__DOCUMENTATION = ABSTRACT_ELEMENT_BINDING__DOCUMENTATION; - - /** - * The feature id for the 'Sub Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__SUB_ELEMENTS = ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS; - - /** - * The feature id for the 'Properties' containment reference list. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__PROPERTIES = ABSTRACT_ELEMENT_BINDING__PROPERTIES; - - /** - * The feature id for the 'Databinding' container reference. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__DATABINDING = ABSTRACT_ELEMENT_BINDING__DATABINDING; - - /** - * The feature id for the 'Super Element' container reference. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__SUPER_ELEMENT = ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__NAME = ABSTRACT_ELEMENT_BINDING__NAME; - - /** - * The feature id for the 'Referenced Binding' containment reference list. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__REFERENCED_BINDING = ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__VIEWS = ABSTRACT_ELEMENT_BINDING__VIEWS; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__CATEGORY = ABSTRACT_ELEMENT_BINDING__CATEGORY; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__BINDING_FILTERS = ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS; - - /** - * The feature id for the 'Model' reference. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING__MODEL = ABSTRACT_ELEMENT_BINDING_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'EMF Element Binding' class. - * - * - * @generated - * @ordered - */ - int EMF_ELEMENT_BINDING_FEATURE_COUNT = ABSTRACT_ELEMENT_BINDING_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.EMFPropertyBindingImpl EMF Property Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.EMFPropertyBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getEMFPropertyBinding() - * @generated - */ - int EMF_PROPERTY_BINDING = 6; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int EMF_PROPERTY_BINDING__DOCUMENTATION = ABSTRACT_PROPERTY_BINDING__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int EMF_PROPERTY_BINDING__NAME = ABSTRACT_PROPERTY_BINDING__NAME; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int EMF_PROPERTY_BINDING__VIEWS = ABSTRACT_PROPERTY_BINDING__VIEWS; - - /** - * The feature id for the 'Element' container reference. - * - * - * @generated - * @ordered - */ - int EMF_PROPERTY_BINDING__ELEMENT = ABSTRACT_PROPERTY_BINDING__ELEMENT; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int EMF_PROPERTY_BINDING__BINDING_FILTERS = ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS; - - /** - * The feature id for the 'Model' reference. - * - * - * @generated - * @ordered - */ - int EMF_PROPERTY_BINDING__MODEL = ABSTRACT_PROPERTY_BINDING_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Navigation' containment reference. - * - * - * @generated - * @ordered - */ - int EMF_PROPERTY_BINDING__NAVIGATION = ABSTRACT_PROPERTY_BINDING_FEATURE_COUNT + 1; - - /** - * The feature id for the 'Editor Setting' containment reference. - * - * - * @generated - * @ordered - */ - int EMF_PROPERTY_BINDING__EDITOR_SETTING = ABSTRACT_PROPERTY_BINDING_FEATURE_COUNT + 2; - - /** - * The number of structural features of the 'EMF Property Binding' class. - * - * - * @generated - * @ordered - */ - int EMF_PROPERTY_BINDING_FEATURE_COUNT = ABSTRACT_PROPERTY_BINDING_FEATURE_COUNT + 3; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.StandardElementBindingImpl Standard Element Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.StandardElementBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getStandardElementBinding() - * @generated - */ - int STANDARD_ELEMENT_BINDING = 7; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__DOCUMENTATION = ABSTRACT_ELEMENT_BINDING__DOCUMENTATION; - - /** - * The feature id for the 'Sub Elements' containment reference list. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__SUB_ELEMENTS = ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS; - - /** - * The feature id for the 'Properties' containment reference list. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__PROPERTIES = ABSTRACT_ELEMENT_BINDING__PROPERTIES; - - /** - * The feature id for the 'Databinding' container reference. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__DATABINDING = ABSTRACT_ELEMENT_BINDING__DATABINDING; - - /** - * The feature id for the 'Super Element' container reference. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__SUPER_ELEMENT = ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__NAME = ABSTRACT_ELEMENT_BINDING__NAME; - - /** - * The feature id for the 'Referenced Binding' containment reference list. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__REFERENCED_BINDING = ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__VIEWS = ABSTRACT_ELEMENT_BINDING__VIEWS; - - /** - * The feature id for the 'Category' container reference. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__CATEGORY = ABSTRACT_ELEMENT_BINDING__CATEGORY; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__BINDING_FILTERS = ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS; - - /** - * The feature id for the 'Model' reference. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING__MODEL = ABSTRACT_ELEMENT_BINDING_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Standard Element Binding' class. - * - * - * @generated - * @ordered - */ - int STANDARD_ELEMENT_BINDING_FEATURE_COUNT = ABSTRACT_ELEMENT_BINDING_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.StandardPropertyBindingImpl Standard Property Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.StandardPropertyBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getStandardPropertyBinding() - * @generated - */ - int STANDARD_PROPERTY_BINDING = 8; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int STANDARD_PROPERTY_BINDING__DOCUMENTATION = ABSTRACT_PROPERTY_BINDING__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int STANDARD_PROPERTY_BINDING__NAME = ABSTRACT_PROPERTY_BINDING__NAME; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int STANDARD_PROPERTY_BINDING__VIEWS = ABSTRACT_PROPERTY_BINDING__VIEWS; - - /** - * The feature id for the 'Element' container reference. - * - * - * @generated - * @ordered - */ - int STANDARD_PROPERTY_BINDING__ELEMENT = ABSTRACT_PROPERTY_BINDING__ELEMENT; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int STANDARD_PROPERTY_BINDING__BINDING_FILTERS = ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS; - - /** - * The feature id for the 'Model' reference. - * - * - * @generated - * @ordered - */ - int STANDARD_PROPERTY_BINDING__MODEL = ABSTRACT_PROPERTY_BINDING_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Standard Property Binding' class. - * - * - * @generated - * @ordered - */ - int STANDARD_PROPERTY_BINDING_FEATURE_COUNT = ABSTRACT_PROPERTY_BINDING_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.CategoryImpl Category}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.CategoryImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getCategory() - * @generated - */ - int CATEGORY = 9; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int CATEGORY__DOCUMENTATION = DOCUMENTED_ELEMENT__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int CATEGORY__NAME = DOCUMENTED_ELEMENT_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Bindings' containment reference list. - * - * - * @generated - * @ordered - */ - int CATEGORY__BINDINGS = DOCUMENTED_ELEMENT_FEATURE_COUNT + 1; - - /** - * The feature id for the 'Databinding' container reference. - * - * - * @generated - * @ordered - */ - int CATEGORY__DATABINDING = DOCUMENTED_ELEMENT_FEATURE_COUNT + 2; - - /** - * The feature id for the 'Categories' containment reference list. - * - * - * @generated - * @ordered - */ - int CATEGORY__CATEGORIES = DOCUMENTED_ELEMENT_FEATURE_COUNT + 3; - - /** - * The number of structural features of the 'Category' class. - * - * - * @generated - * @ordered - */ - int CATEGORY_FEATURE_COUNT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 4; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.ElementBindingReferenceImpl Element Binding Reference}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.ElementBindingReferenceImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getElementBindingReference() - * @generated - */ - int ELEMENT_BINDING_REFERENCE = 10; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int ELEMENT_BINDING_REFERENCE__DOCUMENTATION = DOCUMENTED_ELEMENT__DOCUMENTATION; - - /** - * The feature id for the 'Binding' reference. - * - * - * @generated - * @ordered - */ - int ELEMENT_BINDING_REFERENCE__BINDING = DOCUMENTED_ELEMENT_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Element Binding Reference' class. - * - * - * @generated - * @ordered - */ - int ELEMENT_BINDING_REFERENCE_FEATURE_COUNT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.impl.EMFMultiPropertiesBindingImpl EMF Multi Properties Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.EMFMultiPropertiesBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getEMFMultiPropertiesBinding() - * @generated - */ - int EMF_MULTI_PROPERTIES_BINDING = 12; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int EMF_MULTI_PROPERTIES_BINDING__DOCUMENTATION = ABSTRACT_PROPERTY_BINDING__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int EMF_MULTI_PROPERTIES_BINDING__NAME = ABSTRACT_PROPERTY_BINDING__NAME; - - /** - * The feature id for the 'Views' reference list. - * - * - * @generated - * @ordered - */ - int EMF_MULTI_PROPERTIES_BINDING__VIEWS = ABSTRACT_PROPERTY_BINDING__VIEWS; - - /** - * The feature id for the 'Element' container reference. - * - * - * @generated - * @ordered - */ - int EMF_MULTI_PROPERTIES_BINDING__ELEMENT = ABSTRACT_PROPERTY_BINDING__ELEMENT; - - /** - * The feature id for the 'Binding Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int EMF_MULTI_PROPERTIES_BINDING__BINDING_FILTERS = ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS; - - /** - * The feature id for the 'Model' reference list. - * - * - * @generated - * @ordered - */ - int EMF_MULTI_PROPERTIES_BINDING__MODEL = ABSTRACT_PROPERTY_BINDING_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Navigation' containment reference. - * - * - * @generated - * @ordered - */ - int EMF_MULTI_PROPERTIES_BINDING__NAVIGATION = ABSTRACT_PROPERTY_BINDING_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'EMF Multi Properties Binding' class. - * - * - * @generated - * @ordered - */ - int EMF_MULTI_PROPERTIES_BINDING_FEATURE_COUNT = ABSTRACT_PROPERTY_BINDING_FEATURE_COUNT + 2; - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.Databinding Databinding}'. - * - * - * @return the meta object for class 'Databinding'. - * @see org.eclipse.emf.eef.mapping.Databinding - * @generated - */ - EClass getDatabinding(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.Databinding#getBindings Bindings}'. - * - * - * @return the meta object for the containment reference list 'Bindings'. - * @see org.eclipse.emf.eef.mapping.Databinding#getBindings() - * @see #getDatabinding() - * @generated - */ - EReference getDatabinding_Bindings(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.Databinding#getCategories Categories}'. - * - * - * @return the meta object for the containment reference list 'Categories'. - * @see org.eclipse.emf.eef.mapping.Databinding#getCategories() - * @see #getDatabinding() - * @generated - */ - EReference getDatabinding_Categories(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.ModelElement Model Element}'. - * - * - * @return the meta object for class 'Model Element'. - * @see org.eclipse.emf.eef.mapping.ModelElement - * @generated - */ - EClass getModelElement(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.ModelElement#getProperties Properties}'. - * - * - * @return the meta object for the containment reference list 'Properties'. - * @see org.eclipse.emf.eef.mapping.ModelElement#getProperties() - * @see #getModelElement() - * @generated - */ - EReference getModelElement_Properties(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.ModelElement#getSubElements Sub Elements}'. - * - * - * @return the meta object for the containment reference list 'Sub Elements'. - * @see org.eclipse.emf.eef.mapping.ModelElement#getSubElements() - * @see #getModelElement() - * @generated - */ - EReference getModelElement_SubElements(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.ModelElement#getBinding Binding}'. - * - * - * @return the meta object for the reference 'Binding'. - * @see org.eclipse.emf.eef.mapping.ModelElement#getBinding() - * @see #getModelElement() - * @generated - */ - EReference getModelElement_Binding(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.emf.eef.mapping.ModelElement#getSuperElement Super Element}'. - * - * - * @return the meta object for the container reference 'Super Element'. - * @see org.eclipse.emf.eef.mapping.ModelElement#getSuperElement() - * @see #getModelElement() - * @generated - */ - EReference getModelElement_SuperElement(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding Abstract Element Binding}'. - * - * - * @return the meta object for class 'Abstract Element Binding'. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding - * @generated - */ - EClass getAbstractElementBinding(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getSubElements Sub Elements}'. - * - * - * @return the meta object for the containment reference list 'Sub Elements'. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getSubElements() - * @see #getAbstractElementBinding() - * @generated - */ - EReference getAbstractElementBinding_SubElements(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getProperties Properties}'. - * - * - * @return the meta object for the containment reference list 'Properties'. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getProperties() - * @see #getAbstractElementBinding() - * @generated - */ - EReference getAbstractElementBinding_Properties(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getDatabinding Databinding}'. - * - * - * @return the meta object for the container reference 'Databinding'. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getDatabinding() - * @see #getAbstractElementBinding() - * @generated - */ - EReference getAbstractElementBinding_Databinding(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getSuperElement Super Element}'. - * - * - * @return the meta object for the container reference 'Super Element'. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getSuperElement() - * @see #getAbstractElementBinding() - * @generated - */ - EReference getAbstractElementBinding_SuperElement(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getName Name}'. - * - * - * @return the meta object for the attribute 'Name'. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getName() - * @see #getAbstractElementBinding() - * @generated - */ - EAttribute getAbstractElementBinding_Name(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getReferencedBinding Referenced Binding}'. - * - * - * @return the meta object for the containment reference list 'Referenced Binding'. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getReferencedBinding() - * @see #getAbstractElementBinding() - * @generated - */ - EReference getAbstractElementBinding_ReferencedBinding(); - - /** - * Returns the meta object for the reference list '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getViews Views}'. - * - * - * @return the meta object for the reference list 'Views'. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getViews() - * @see #getAbstractElementBinding() - * @generated - */ - EReference getAbstractElementBinding_Views(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getCategory Category}'. - * - * - * @return the meta object for the container reference 'Category'. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getCategory() - * @see #getAbstractElementBinding() - * @generated - */ - EReference getAbstractElementBinding_Category(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding#getBindingFilters Binding Filters}'. - * - * - * @return the meta object for the containment reference list 'Binding Filters'. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding#getBindingFilters() - * @see #getAbstractElementBinding() - * @generated - */ - EReference getAbstractElementBinding_BindingFilters(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.ModelProperty Model Property}'. - * - * - * @return the meta object for class 'Model Property'. - * @see org.eclipse.emf.eef.mapping.ModelProperty - * @generated - */ - EClass getModelProperty(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.ModelProperty#getBinding Binding}'. - * - * - * @return the meta object for the reference 'Binding'. - * @see org.eclipse.emf.eef.mapping.ModelProperty#getBinding() - * @see #getModelProperty() - * @generated - */ - EReference getModelProperty_Binding(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.emf.eef.mapping.ModelProperty#getModelElement Model Element}'. - * - * - * @return the meta object for the container reference 'Model Element'. - * @see org.eclipse.emf.eef.mapping.ModelProperty#getModelElement() - * @see #getModelProperty() - * @generated - */ - EReference getModelProperty_ModelElement(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding Abstract Property Binding}'. - * - * - * @return the meta object for class 'Abstract Property Binding'. - * @see org.eclipse.emf.eef.mapping.AbstractPropertyBinding - * @generated - */ - EClass getAbstractPropertyBinding(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getName Name}'. - * - * - * @return the meta object for the attribute 'Name'. - * @see org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getName() - * @see #getAbstractPropertyBinding() - * @generated - */ - EAttribute getAbstractPropertyBinding_Name(); - - /** - * Returns the meta object for the reference list '{@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getViews Views}'. - * - * - * @return the meta object for the reference list 'Views'. - * @see org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getViews() - * @see #getAbstractPropertyBinding() - * @generated - */ - EReference getAbstractPropertyBinding_Views(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getElement Element}'. - * - * - * @return the meta object for the container reference 'Element'. - * @see org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getElement() - * @see #getAbstractPropertyBinding() - * @generated - */ - EReference getAbstractPropertyBinding_Element(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getBindingFilters Binding Filters}'. - * - * - * @return the meta object for the containment reference list 'Binding Filters'. - * @see org.eclipse.emf.eef.mapping.AbstractPropertyBinding#getBindingFilters() - * @see #getAbstractPropertyBinding() - * @generated - */ - EReference getAbstractPropertyBinding_BindingFilters(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.EMFElementBinding EMF Element Binding}'. - * - * - * @return the meta object for class 'EMF Element Binding'. - * @see org.eclipse.emf.eef.mapping.EMFElementBinding - * @generated - */ - EClass getEMFElementBinding(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.EMFElementBinding#getModel Model}'. - * - * - * @return the meta object for the reference 'Model'. - * @see org.eclipse.emf.eef.mapping.EMFElementBinding#getModel() - * @see #getEMFElementBinding() - * @generated - */ - EReference getEMFElementBinding_Model(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.EMFPropertyBinding EMF Property Binding}'. - * - * - * @return the meta object for class 'EMF Property Binding'. - * @see org.eclipse.emf.eef.mapping.EMFPropertyBinding - * @generated - */ - EClass getEMFPropertyBinding(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.EMFPropertyBinding#getModel Model}'. - * - * - * @return the meta object for the reference 'Model'. - * @see org.eclipse.emf.eef.mapping.EMFPropertyBinding#getModel() - * @see #getEMFPropertyBinding() - * @generated - */ - EReference getEMFPropertyBinding_Model(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.mapping.EMFPropertyBinding#getNavigation Navigation}'. - * - * - * @return the meta object for the containment reference 'Navigation'. - * @see org.eclipse.emf.eef.mapping.EMFPropertyBinding#getNavigation() - * @see #getEMFPropertyBinding() - * @generated - */ - EReference getEMFPropertyBinding_Navigation(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.mapping.EMFPropertyBinding#getEditorSetting Editor Setting}'. - * - * - * @return the meta object for the containment reference 'Editor Setting'. - * @see org.eclipse.emf.eef.mapping.EMFPropertyBinding#getEditorSetting() - * @see #getEMFPropertyBinding() - * @generated - */ - EReference getEMFPropertyBinding_EditorSetting(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.StandardElementBinding Standard Element Binding}'. - * - * - * @return the meta object for class 'Standard Element Binding'. - * @see org.eclipse.emf.eef.mapping.StandardElementBinding - * @generated - */ - EClass getStandardElementBinding(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.StandardElementBinding#getModel Model}'. - * - * - * @return the meta object for the reference 'Model'. - * @see org.eclipse.emf.eef.mapping.StandardElementBinding#getModel() - * @see #getStandardElementBinding() - * @generated - */ - EReference getStandardElementBinding_Model(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.StandardPropertyBinding Standard Property Binding}'. - * - * - * @return the meta object for class 'Standard Property Binding'. - * @see org.eclipse.emf.eef.mapping.StandardPropertyBinding - * @generated - */ - EClass getStandardPropertyBinding(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.StandardPropertyBinding#getModel Model}'. - * - * - * @return the meta object for the reference 'Model'. - * @see org.eclipse.emf.eef.mapping.StandardPropertyBinding#getModel() - * @see #getStandardPropertyBinding() - * @generated - */ - EReference getStandardPropertyBinding_Model(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.Category Category}'. - * - * - * @return the meta object for class 'Category'. - * @see org.eclipse.emf.eef.mapping.Category - * @generated - */ - EClass getCategory(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.Category#getName Name}'. - * - * - * @return the meta object for the attribute 'Name'. - * @see org.eclipse.emf.eef.mapping.Category#getName() - * @see #getCategory() - * @generated - */ - EAttribute getCategory_Name(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.Category#getBindings Bindings}'. - * - * - * @return the meta object for the containment reference list 'Bindings'. - * @see org.eclipse.emf.eef.mapping.Category#getBindings() - * @see #getCategory() - * @generated - */ - EReference getCategory_Bindings(); - - /** - * Returns the meta object for the container reference '{@link org.eclipse.emf.eef.mapping.Category#getDatabinding Databinding}'. - * - * - * @return the meta object for the container reference 'Databinding'. - * @see org.eclipse.emf.eef.mapping.Category#getDatabinding() - * @see #getCategory() - * @generated - */ - EReference getCategory_Databinding(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.Category#getCategories Categories}'. - * - * - * @return the meta object for the containment reference list 'Categories'. - * @see org.eclipse.emf.eef.mapping.Category#getCategories() - * @see #getCategory() - * @generated - */ - EReference getCategory_Categories(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.ElementBindingReference Element Binding Reference}'. - * - * - * @return the meta object for class 'Element Binding Reference'. - * @see org.eclipse.emf.eef.mapping.ElementBindingReference - * @generated - */ - EClass getElementBindingReference(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.ElementBindingReference#getBinding Binding}'. - * - * - * @return the meta object for the reference 'Binding'. - * @see org.eclipse.emf.eef.mapping.ElementBindingReference#getBinding() - * @see #getElementBindingReference() - * @generated - */ - EReference getElementBindingReference_Binding(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.DocumentedElement Documented Element}'. - * - * - * @return the meta object for class 'Documented Element'. - * @see org.eclipse.emf.eef.mapping.DocumentedElement - * @generated - */ - EClass getDocumentedElement(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.DocumentedElement#getDocumentation Documentation}'. - * - * - * @return the meta object for the attribute 'Documentation'. - * @see org.eclipse.emf.eef.mapping.DocumentedElement#getDocumentation() - * @see #getDocumentedElement() - * @generated - */ - EAttribute getDocumentedElement_Documentation(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding EMF Multi Properties Binding}'. - * - * - * @return the meta object for class 'EMF Multi Properties Binding'. - * @see org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding - * @generated - */ - EClass getEMFMultiPropertiesBinding(); - - /** - * Returns the meta object for the reference list '{@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding#getModel Model}'. - * - * - * @return the meta object for the reference list 'Model'. - * @see org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding#getModel() - * @see #getEMFMultiPropertiesBinding() - * @generated - */ - EReference getEMFMultiPropertiesBinding_Model(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding#getNavigation Navigation}'. - * - * - * @return the meta object for the containment reference 'Navigation'. - * @see org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding#getNavigation() - * @see #getEMFMultiPropertiesBinding() - * @generated - */ - EReference getEMFMultiPropertiesBinding_Navigation(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - MappingFactory getMappingFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.DatabindingImpl Databinding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.DatabindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getDatabinding() - * @generated - */ - EClass DATABINDING = eINSTANCE.getDatabinding(); - - /** - * The meta object literal for the 'Bindings' containment reference list feature. - * - * - * @generated - */ - EReference DATABINDING__BINDINGS = eINSTANCE.getDatabinding_Bindings(); - - /** - * The meta object literal for the 'Categories' containment reference list feature. - * - * - * @generated - */ - EReference DATABINDING__CATEGORIES = eINSTANCE - .getDatabinding_Categories(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.ModelElementImpl Model Element}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.ModelElementImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getModelElement() - * @generated - */ - EClass MODEL_ELEMENT = eINSTANCE.getModelElement(); - - /** - * The meta object literal for the 'Properties' containment reference list feature. - * - * - * @generated - */ - EReference MODEL_ELEMENT__PROPERTIES = eINSTANCE - .getModelElement_Properties(); - - /** - * The meta object literal for the 'Sub Elements' containment reference list feature. - * - * - * @generated - */ - EReference MODEL_ELEMENT__SUB_ELEMENTS = eINSTANCE - .getModelElement_SubElements(); - - /** - * The meta object literal for the 'Binding' reference feature. - * - * - * @generated - */ - EReference MODEL_ELEMENT__BINDING = eINSTANCE.getModelElement_Binding(); - - /** - * The meta object literal for the 'Super Element' container reference feature. - * - * - * @generated - */ - EReference MODEL_ELEMENT__SUPER_ELEMENT = eINSTANCE - .getModelElement_SuperElement(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl Abstract Element Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getAbstractElementBinding() - * @generated - */ - EClass ABSTRACT_ELEMENT_BINDING = eINSTANCE.getAbstractElementBinding(); - - /** - * The meta object literal for the 'Sub Elements' containment reference list feature. - * - * - * @generated - */ - EReference ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS = eINSTANCE - .getAbstractElementBinding_SubElements(); - - /** - * The meta object literal for the 'Properties' containment reference list feature. - * - * - * @generated - */ - EReference ABSTRACT_ELEMENT_BINDING__PROPERTIES = eINSTANCE - .getAbstractElementBinding_Properties(); - - /** - * The meta object literal for the 'Databinding' container reference feature. - * - * - * @generated - */ - EReference ABSTRACT_ELEMENT_BINDING__DATABINDING = eINSTANCE - .getAbstractElementBinding_Databinding(); - - /** - * The meta object literal for the 'Super Element' container reference feature. - * - * - * @generated - */ - EReference ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT = eINSTANCE - .getAbstractElementBinding_SuperElement(); - - /** - * The meta object literal for the 'Name' attribute feature. - * - * - * @generated - */ - EAttribute ABSTRACT_ELEMENT_BINDING__NAME = eINSTANCE - .getAbstractElementBinding_Name(); - - /** - * The meta object literal for the 'Referenced Binding' containment reference list feature. - * - * - * @generated - */ - EReference ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING = eINSTANCE - .getAbstractElementBinding_ReferencedBinding(); - - /** - * The meta object literal for the 'Views' reference list feature. - * - * - * @generated - */ - EReference ABSTRACT_ELEMENT_BINDING__VIEWS = eINSTANCE - .getAbstractElementBinding_Views(); - - /** - * The meta object literal for the 'Category' container reference feature. - * - * - * @generated - */ - EReference ABSTRACT_ELEMENT_BINDING__CATEGORY = eINSTANCE - .getAbstractElementBinding_Category(); - - /** - * The meta object literal for the 'Binding Filters' containment reference list feature. - * - * - * @generated - */ - EReference ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS = eINSTANCE - .getAbstractElementBinding_BindingFilters(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.ModelPropertyImpl Model Property}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.ModelPropertyImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getModelProperty() - * @generated - */ - EClass MODEL_PROPERTY = eINSTANCE.getModelProperty(); - - /** - * The meta object literal for the 'Binding' reference feature. - * - * - * @generated - */ - EReference MODEL_PROPERTY__BINDING = eINSTANCE - .getModelProperty_Binding(); - - /** - * The meta object literal for the 'Model Element' container reference feature. - * - * - * @generated - */ - EReference MODEL_PROPERTY__MODEL_ELEMENT = eINSTANCE - .getModelProperty_ModelElement(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.AbstractPropertyBindingImpl Abstract Property Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.AbstractPropertyBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getAbstractPropertyBinding() - * @generated - */ - EClass ABSTRACT_PROPERTY_BINDING = eINSTANCE - .getAbstractPropertyBinding(); - - /** - * The meta object literal for the 'Name' attribute feature. - * - * - * @generated - */ - EAttribute ABSTRACT_PROPERTY_BINDING__NAME = eINSTANCE - .getAbstractPropertyBinding_Name(); - - /** - * The meta object literal for the 'Views' reference list feature. - * - * - * @generated - */ - EReference ABSTRACT_PROPERTY_BINDING__VIEWS = eINSTANCE - .getAbstractPropertyBinding_Views(); - - /** - * The meta object literal for the 'Element' container reference feature. - * - * - * @generated - */ - EReference ABSTRACT_PROPERTY_BINDING__ELEMENT = eINSTANCE - .getAbstractPropertyBinding_Element(); - - /** - * The meta object literal for the 'Binding Filters' containment reference list feature. - * - * - * @generated - */ - EReference ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS = eINSTANCE - .getAbstractPropertyBinding_BindingFilters(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.EMFElementBindingImpl EMF Element Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.EMFElementBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getEMFElementBinding() - * @generated - */ - EClass EMF_ELEMENT_BINDING = eINSTANCE.getEMFElementBinding(); - - /** - * The meta object literal for the 'Model' reference feature. - * - * - * @generated - */ - EReference EMF_ELEMENT_BINDING__MODEL = eINSTANCE - .getEMFElementBinding_Model(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.EMFPropertyBindingImpl EMF Property Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.EMFPropertyBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getEMFPropertyBinding() - * @generated - */ - EClass EMF_PROPERTY_BINDING = eINSTANCE.getEMFPropertyBinding(); - - /** - * The meta object literal for the 'Model' reference feature. - * - * - * @generated - */ - EReference EMF_PROPERTY_BINDING__MODEL = eINSTANCE - .getEMFPropertyBinding_Model(); - - /** - * The meta object literal for the 'Navigation' containment reference feature. - * - * - * @generated - */ - EReference EMF_PROPERTY_BINDING__NAVIGATION = eINSTANCE - .getEMFPropertyBinding_Navigation(); - - /** - * The meta object literal for the 'Editor Setting' containment reference feature. - * - * - * @generated - */ - EReference EMF_PROPERTY_BINDING__EDITOR_SETTING = eINSTANCE - .getEMFPropertyBinding_EditorSetting(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.StandardElementBindingImpl Standard Element Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.StandardElementBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getStandardElementBinding() - * @generated - */ - EClass STANDARD_ELEMENT_BINDING = eINSTANCE.getStandardElementBinding(); - - /** - * The meta object literal for the 'Model' reference feature. - * - * - * @generated - */ - EReference STANDARD_ELEMENT_BINDING__MODEL = eINSTANCE - .getStandardElementBinding_Model(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.StandardPropertyBindingImpl Standard Property Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.StandardPropertyBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getStandardPropertyBinding() - * @generated - */ - EClass STANDARD_PROPERTY_BINDING = eINSTANCE - .getStandardPropertyBinding(); - - /** - * The meta object literal for the 'Model' reference feature. - * - * - * @generated - */ - EReference STANDARD_PROPERTY_BINDING__MODEL = eINSTANCE - .getStandardPropertyBinding_Model(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.CategoryImpl Category}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.CategoryImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getCategory() - * @generated - */ - EClass CATEGORY = eINSTANCE.getCategory(); - - /** - * The meta object literal for the 'Name' attribute feature. - * - * - * @generated - */ - EAttribute CATEGORY__NAME = eINSTANCE.getCategory_Name(); - - /** - * The meta object literal for the 'Bindings' containment reference list feature. - * - * - * @generated - */ - EReference CATEGORY__BINDINGS = eINSTANCE.getCategory_Bindings(); - - /** - * The meta object literal for the 'Databinding' container reference feature. - * - * - * @generated - */ - EReference CATEGORY__DATABINDING = eINSTANCE.getCategory_Databinding(); - - /** - * The meta object literal for the 'Categories' containment reference list feature. - * - * - * @generated - */ - EReference CATEGORY__CATEGORIES = eINSTANCE.getCategory_Categories(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.ElementBindingReferenceImpl Element Binding Reference}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.ElementBindingReferenceImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getElementBindingReference() - * @generated - */ - EClass ELEMENT_BINDING_REFERENCE = eINSTANCE - .getElementBindingReference(); - - /** - * The meta object literal for the 'Binding' reference feature. - * - * - * @generated - */ - EReference ELEMENT_BINDING_REFERENCE__BINDING = eINSTANCE - .getElementBindingReference_Binding(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.DocumentedElementImpl Documented Element}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.DocumentedElementImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getDocumentedElement() - * @generated - */ - EClass DOCUMENTED_ELEMENT = eINSTANCE.getDocumentedElement(); - - /** - * The meta object literal for the 'Documentation' attribute feature. - * - * - * @generated - */ - EAttribute DOCUMENTED_ELEMENT__DOCUMENTATION = eINSTANCE - .getDocumentedElement_Documentation(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.impl.EMFMultiPropertiesBindingImpl EMF Multi Properties Binding}' class. - * - * - * @see org.eclipse.emf.eef.mapping.impl.EMFMultiPropertiesBindingImpl - * @see org.eclipse.emf.eef.mapping.impl.MappingPackageImpl#getEMFMultiPropertiesBinding() - * @generated - */ - EClass EMF_MULTI_PROPERTIES_BINDING = eINSTANCE - .getEMFMultiPropertiesBinding(); - - /** - * The meta object literal for the 'Model' reference list feature. - * - * - * @generated - */ - EReference EMF_MULTI_PROPERTIES_BINDING__MODEL = eINSTANCE - .getEMFMultiPropertiesBinding_Model(); - - /** - * The meta object literal for the 'Navigation' containment reference feature. - * - * - * @generated - */ - EReference EMF_MULTI_PROPERTIES_BINDING__NAVIGATION = eINSTANCE - .getEMFMultiPropertiesBinding_Navigation(); - - } - -} //MappingPackage diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ModelElement.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ModelElement.java deleted file mode 100644 index 7b669e16c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ModelElement.java +++ /dev/null @@ -1,128 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.eef.mapping.DocumentedElement; - -/** - * - * A representation of the model object 'Model Element'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.ModelElement#getProperties Properties}
  • - *
  • {@link org.eclipse.emf.eef.mapping.ModelElement#getSubElements Sub Elements}
  • - *
  • {@link org.eclipse.emf.eef.mapping.ModelElement#getBinding Binding}
  • - *
  • {@link org.eclipse.emf.eef.mapping.ModelElement#getSuperElement Super Element}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getModelElement() - * @model abstract="true" - * @generated - */ -public interface ModelElement extends DocumentedElement { - /** - * Returns the value of the 'Properties' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.ModelProperty}. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.ModelProperty#getModelElement Model Element}'. - * - *

- * If the meaning of the 'Properties' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Properties' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getModelElement_Properties() - * @see org.eclipse.emf.eef.mapping.ModelProperty#getModelElement - * @model opposite="modelElement" containment="true" - * @generated - */ - EList getProperties(); - - /** - * Returns the value of the 'Sub Elements' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.ModelElement}. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.ModelElement#getSuperElement Super Element}'. - * - *

- * If the meaning of the 'Sub Elements' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Sub Elements' containment reference list. - * @see org.eclipse.emf.eef.mapping.MappingPackage#getModelElement_SubElements() - * @see org.eclipse.emf.eef.mapping.ModelElement#getSuperElement - * @model opposite="superElement" containment="true" - * @generated - */ - EList getSubElements(); - - /** - * Returns the value of the 'Binding' reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.StandardElementBinding#getModel Model}'. - * - *

- * If the meaning of the 'Binding' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Binding' reference. - * @see #setBinding(StandardElementBinding) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getModelElement_Binding() - * @see org.eclipse.emf.eef.mapping.StandardElementBinding#getModel - * @model opposite="model" - * @generated - */ - StandardElementBinding getBinding(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.ModelElement#getBinding Binding}' reference. - * - * - * @param value the new value of the 'Binding' reference. - * @see #getBinding() - * @generated - */ - void setBinding(StandardElementBinding value); - - /** - * Returns the value of the 'Super Element' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.ModelElement#getSubElements Sub Elements}'. - * - *

- * If the meaning of the 'Super Element' container reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Super Element' container reference. - * @see #setSuperElement(ModelElement) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getModelElement_SuperElement() - * @see org.eclipse.emf.eef.mapping.ModelElement#getSubElements - * @model opposite="subElements" transient="false" - * @generated - */ - ModelElement getSuperElement(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.ModelElement#getSuperElement Super Element}' container reference. - * - * - * @param value the new value of the 'Super Element' container reference. - * @see #getSuperElement() - * @generated - */ - void setSuperElement(ModelElement value); - -} // ModelElement diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ModelProperty.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ModelProperty.java deleted file mode 100644 index 00821a150..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/ModelProperty.java +++ /dev/null @@ -1,89 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -import org.eclipse.emf.eef.mapping.DocumentedElement; - -/** - * - * A representation of the model object 'Model Property'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.ModelProperty#getBinding Binding}
  • - *
  • {@link org.eclipse.emf.eef.mapping.ModelProperty#getModelElement Model Element}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getModelProperty() - * @model abstract="true" - * @generated - */ -public interface ModelProperty extends DocumentedElement { - /** - * Returns the value of the 'Binding' reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.StandardPropertyBinding#getModel Model}'. - * - *

- * If the meaning of the 'Binding' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Binding' reference. - * @see #setBinding(StandardPropertyBinding) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getModelProperty_Binding() - * @see org.eclipse.emf.eef.mapping.StandardPropertyBinding#getModel - * @model opposite="model" - * @generated - */ - StandardPropertyBinding getBinding(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.ModelProperty#getBinding Binding}' reference. - * - * - * @param value the new value of the 'Binding' reference. - * @see #getBinding() - * @generated - */ - void setBinding(StandardPropertyBinding value); - - /** - * Returns the value of the 'Model Element' container reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.ModelElement#getProperties Properties}'. - * - *

- * If the meaning of the 'Model Element' container reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Model Element' container reference. - * @see #setModelElement(ModelElement) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getModelProperty_ModelElement() - * @see org.eclipse.emf.eef.mapping.ModelElement#getProperties - * @model opposite="properties" transient="false" - * @generated - */ - ModelElement getModelElement(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.ModelProperty#getModelElement Model Element}' container reference. - * - * - * @param value the new value of the 'Model Element' container reference. - * @see #getModelElement() - * @generated - */ - void setModelElement(ModelElement value); - -} // ModelProperty diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/StandardElementBinding.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/StandardElementBinding.java deleted file mode 100644 index a9643a947..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/StandardElementBinding.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -/** - * - * A representation of the model object 'Standard Element Binding'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.StandardElementBinding#getModel Model}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getStandardElementBinding() - * @model - * @generated - */ -public interface StandardElementBinding extends AbstractElementBinding { - /** - * Returns the value of the 'Model' reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.ModelElement#getBinding Binding}'. - * - *

- * If the meaning of the 'Model' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Model' reference. - * @see #setModel(ModelElement) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getStandardElementBinding_Model() - * @see org.eclipse.emf.eef.mapping.ModelElement#getBinding - * @model opposite="binding" required="true" - * @generated - */ - ModelElement getModel(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.StandardElementBinding#getModel Model}' reference. - * - * - * @param value the new value of the 'Model' reference. - * @see #getModel() - * @generated - */ - void setModel(ModelElement value); - -} // StandardElementBinding diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/StandardPropertyBinding.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/StandardPropertyBinding.java deleted file mode 100644 index 6d6ccd1dc..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/StandardPropertyBinding.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping; - -/** - * - * A representation of the model object 'Standard Property Binding'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.StandardPropertyBinding#getModel Model}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.MappingPackage#getStandardPropertyBinding() - * @model - * @generated - */ -public interface StandardPropertyBinding extends AbstractPropertyBinding { - /** - * Returns the value of the 'Model' reference. - * It is bidirectional and its opposite is '{@link org.eclipse.emf.eef.mapping.ModelProperty#getBinding Binding}'. - * - *

- * If the meaning of the 'Model' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Model' reference. - * @see #setModel(ModelProperty) - * @see org.eclipse.emf.eef.mapping.MappingPackage#getStandardPropertyBinding_Model() - * @see org.eclipse.emf.eef.mapping.ModelProperty#getBinding - * @model opposite="binding" required="true" - * @generated - */ - ModelProperty getModel(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.StandardPropertyBinding#getModel Model}' reference. - * - * - * @param value the new value of the 'Model' reference. - * @see #getModel() - * @generated - */ - void setModel(ModelProperty value); - -} // StandardPropertyBinding diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/BindingFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/BindingFilter.java deleted file mode 100644 index d79eb5996..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/BindingFilter.java +++ /dev/null @@ -1,86 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters; - -import org.eclipse.emf.eef.mapping.DocumentedElement; - -/** - * - * A representation of the model object 'Binding Filter'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.BindingFilter#getName Name}
  • - *
  • {@link org.eclipse.emf.eef.mapping.filters.BindingFilter#isMandatory Mandatory}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getBindingFilter() - * @model abstract="true" - * @generated - */ -public interface BindingFilter extends DocumentedElement { - /** - * Returns the value of the 'Name' attribute. - * - *

- * If the meaning of the 'Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Name' attribute. - * @see #setName(String) - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getBindingFilter_Name() - * @model - * @generated - */ - String getName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.filters.BindingFilter#getName Name}' attribute. - * - * - * @param value the new value of the 'Name' attribute. - * @see #getName() - * @generated - */ - void setName(String value); - - /** - * Returns the value of the 'Mandatory' attribute. - * The default value is "true". - * - *

- * If the meaning of the 'Mandatory' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Mandatory' attribute. - * @see #setMandatory(boolean) - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getBindingFilter_Mandatory() - * @model default="true" - * @generated - */ - boolean isMandatory(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.filters.BindingFilter#isMandatory Mandatory}' attribute. - * - * - * @param value the new value of the 'Mandatory' attribute. - * @see #isMandatory() - * @generated - */ - void setMandatory(boolean value); - -} // BindingFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/BusinessFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/BusinessFilter.java deleted file mode 100644 index 8d09058a9..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/BusinessFilter.java +++ /dev/null @@ -1,24 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters; - -/** - * - * A representation of the model object 'Business Filter'. - * - * - * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getBusinessFilter() - * @model abstract="true" - * @generated - */ -public interface BusinessFilter extends BindingFilter { -} // BusinessFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/FiltersFactory.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/FiltersFactory.java deleted file mode 100644 index b1d5cb620..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/FiltersFactory.java +++ /dev/null @@ -1,105 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage - * @generated - */ -public interface FiltersFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - FiltersFactory eINSTANCE = org.eclipse.emf.eef.mapping.filters.impl.FiltersFactoryImpl - .init(); - - /** - * Returns a new object of class 'OCL Filter'. - * - * - * @return a new object of class 'OCL Filter'. - * @generated - */ - OCLFilter createOCLFilter(); - - /** - * Returns a new object of class 'Java Declaration Filter'. - * - * - * @return a new object of class 'Java Declaration Filter'. - * @generated - */ - JavaDeclarationFilter createJavaDeclarationFilter(); - - /** - * Returns a new object of class 'Java Expression Filter'. - * - * - * @return a new object of class 'Java Expression Filter'. - * @generated - */ - JavaExpressionFilter createJavaExpressionFilter(); - - /** - * Returns a new object of class 'Only Reference Type Filter'. - * - * - * @return a new object of class 'Only Reference Type Filter'. - * @generated - */ - OnlyReferenceTypeFilter createOnlyReferenceTypeFilter(); - - /** - * Returns a new object of class 'Strict Typing Filter'. - * - * - * @return a new object of class 'Strict Typing Filter'. - * @generated - */ - StrictTypingFilter createStrictTypingFilter(); - - /** - * Returns a new object of class 'Java Body Step Filter'. - * - * - * @return a new object of class 'Java Body Step Filter'. - * @generated - */ - JavaBodyStepFilter createJavaBodyStepFilter(); - - /** - * Returns a new object of class 'Java Declaration Step Filter'. - * - * - * @return a new object of class 'Java Declaration Step Filter'. - * @generated - */ - JavaDeclarationStepFilter createJavaDeclarationStepFilter(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - FiltersPackage getFiltersPackage(); - -} //FiltersFactory diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/FiltersPackage.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/FiltersPackage.java deleted file mode 100644 index 34ec2592b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/FiltersPackage.java +++ /dev/null @@ -1,998 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.mapping.filters.FiltersFactory - * @model kind="package" - * @generated - */ -public interface FiltersPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "filters"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/mapping/filters/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-mapping-filters"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - FiltersPackage eINSTANCE = org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl - .init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.BindingFilterImpl Binding Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.BindingFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getBindingFilter() - * @generated - */ - int BINDING_FILTER = 0; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int BINDING_FILTER__DOCUMENTATION = MappingPackage.DOCUMENTED_ELEMENT__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int BINDING_FILTER__NAME = MappingPackage.DOCUMENTED_ELEMENT_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Mandatory' attribute. - * - * - * @generated - * @ordered - */ - int BINDING_FILTER__MANDATORY = MappingPackage.DOCUMENTED_ELEMENT_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Binding Filter' class. - * - * - * @generated - * @ordered - */ - int BINDING_FILTER_FEATURE_COUNT = MappingPackage.DOCUMENTED_ELEMENT_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.OCLFilterImpl OCL Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.OCLFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getOCLFilter() - * @generated - */ - int OCL_FILTER = 1; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int OCL_FILTER__DOCUMENTATION = BINDING_FILTER__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int OCL_FILTER__NAME = BINDING_FILTER__NAME; - - /** - * The feature id for the 'Mandatory' attribute. - * - * - * @generated - * @ordered - */ - int OCL_FILTER__MANDATORY = BINDING_FILTER__MANDATORY; - - /** - * The feature id for the 'OCL Body' attribute. - * - * - * @generated - * @ordered - */ - int OCL_FILTER__OCL_BODY = BINDING_FILTER_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'OCL Filter' class. - * - * - * @generated - * @ordered - */ - int OCL_FILTER_FEATURE_COUNT = BINDING_FILTER_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.JavaFilterImpl Java Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.JavaFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaFilter() - * @generated - */ - int JAVA_FILTER = 2; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_FILTER__DOCUMENTATION = BINDING_FILTER__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_FILTER__NAME = BINDING_FILTER__NAME; - - /** - * The feature id for the 'Mandatory' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_FILTER__MANDATORY = BINDING_FILTER__MANDATORY; - - /** - * The number of structural features of the 'Java Filter' class. - * - * - * @generated - * @ordered - */ - int JAVA_FILTER_FEATURE_COUNT = BINDING_FILTER_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.JavaDeclarationFilterImpl Java Declaration Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.JavaDeclarationFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaDeclarationFilter() - * @generated - */ - int JAVA_DECLARATION_FILTER = 3; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_FILTER__DOCUMENTATION = JAVA_FILTER__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_FILTER__NAME = JAVA_FILTER__NAME; - - /** - * The feature id for the 'Mandatory' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_FILTER__MANDATORY = JAVA_FILTER__MANDATORY; - - /** - * The feature id for the 'Method Name' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_FILTER__METHOD_NAME = JAVA_FILTER_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Java Declaration Filter' class. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_FILTER_FEATURE_COUNT = JAVA_FILTER_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.JavaExpressionFilterImpl Java Expression Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.JavaExpressionFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaExpressionFilter() - * @generated - */ - int JAVA_EXPRESSION_FILTER = 4; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_EXPRESSION_FILTER__DOCUMENTATION = JAVA_FILTER__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_EXPRESSION_FILTER__NAME = JAVA_FILTER__NAME; - - /** - * The feature id for the 'Mandatory' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_EXPRESSION_FILTER__MANDATORY = JAVA_FILTER__MANDATORY; - - /** - * The feature id for the 'Java Body' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_EXPRESSION_FILTER__JAVA_BODY = JAVA_FILTER_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Java Expression Filter' class. - * - * - * @generated - * @ordered - */ - int JAVA_EXPRESSION_FILTER_FEATURE_COUNT = JAVA_FILTER_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.BusinessFilterImpl Business Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.BusinessFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getBusinessFilter() - * @generated - */ - int BUSINESS_FILTER = 5; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int BUSINESS_FILTER__DOCUMENTATION = BINDING_FILTER__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int BUSINESS_FILTER__NAME = BINDING_FILTER__NAME; - - /** - * The feature id for the 'Mandatory' attribute. - * - * - * @generated - * @ordered - */ - int BUSINESS_FILTER__MANDATORY = BINDING_FILTER__MANDATORY; - - /** - * The number of structural features of the 'Business Filter' class. - * - * - * @generated - * @ordered - */ - int BUSINESS_FILTER_FEATURE_COUNT = BINDING_FILTER_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.OnlyReferenceTypeFilterImpl Only Reference Type Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.OnlyReferenceTypeFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getOnlyReferenceTypeFilter() - * @generated - */ - int ONLY_REFERENCE_TYPE_FILTER = 6; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int ONLY_REFERENCE_TYPE_FILTER__DOCUMENTATION = BUSINESS_FILTER__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int ONLY_REFERENCE_TYPE_FILTER__NAME = BUSINESS_FILTER__NAME; - - /** - * The feature id for the 'Mandatory' attribute. - * - * - * @generated - * @ordered - */ - int ONLY_REFERENCE_TYPE_FILTER__MANDATORY = BUSINESS_FILTER__MANDATORY; - - /** - * The feature id for the 'Reference' reference. - * - * - * @generated - * @ordered - */ - int ONLY_REFERENCE_TYPE_FILTER__REFERENCE = BUSINESS_FILTER_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Only Reference Type Filter' class. - * - * - * @generated - * @ordered - */ - int ONLY_REFERENCE_TYPE_FILTER_FEATURE_COUNT = BUSINESS_FILTER_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.StrictTypingFilterImpl Strict Typing Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.StrictTypingFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getStrictTypingFilter() - * @generated - */ - int STRICT_TYPING_FILTER = 7; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int STRICT_TYPING_FILTER__DOCUMENTATION = BUSINESS_FILTER__DOCUMENTATION; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int STRICT_TYPING_FILTER__NAME = BUSINESS_FILTER__NAME; - - /** - * The feature id for the 'Mandatory' attribute. - * - * - * @generated - * @ordered - */ - int STRICT_TYPING_FILTER__MANDATORY = BUSINESS_FILTER__MANDATORY; - - /** - * The feature id for the 'Type' reference. - * - * - * @generated - * @ordered - */ - int STRICT_TYPING_FILTER__TYPE = BUSINESS_FILTER_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Strict Typing Filter' class. - * - * - * @generated - * @ordered - */ - int STRICT_TYPING_FILTER_FEATURE_COUNT = BUSINESS_FILTER_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.StepFilterImpl Step Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.StepFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getStepFilter() - * @generated - */ - int STEP_FILTER = 8; - - /** - * The number of structural features of the 'Step Filter' class. - * - * - * @generated - * @ordered - */ - int STEP_FILTER_FEATURE_COUNT = 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.JavaStepFilter Java Step Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.JavaStepFilter - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaStepFilter() - * @generated - */ - int JAVA_STEP_FILTER = 9; - - /** - * The number of structural features of the 'Java Step Filter' class. - * - * - * @generated - * @ordered - */ - int JAVA_STEP_FILTER_FEATURE_COUNT = STEP_FILTER_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.JavaBodyStepFilterImpl Java Body Step Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.JavaBodyStepFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaBodyStepFilter() - * @generated - */ - int JAVA_BODY_STEP_FILTER = 10; - - /** - * The feature id for the 'Body' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_BODY_STEP_FILTER__BODY = NavigationPackage.JAVA_BODY_EXPRESSION__BODY; - - /** - * The number of structural features of the 'Java Body Step Filter' class. - * - * - * @generated - * @ordered - */ - int JAVA_BODY_STEP_FILTER_FEATURE_COUNT = NavigationPackage.JAVA_BODY_EXPRESSION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.filters.impl.JavaDeclarationStepFilterImpl Java Declaration Step Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.JavaDeclarationStepFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaDeclarationStepFilter() - * @generated - */ - int JAVA_DECLARATION_STEP_FILTER = 11; - - /** - * The feature id for the 'Qualified Class' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_STEP_FILTER__QUALIFIED_CLASS = NavigationPackage.JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS; - - /** - * The feature id for the 'Method Name' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_STEP_FILTER__METHOD_NAME = NavigationPackage.JAVA_DECLARATION_EXPRESSION__METHOD_NAME; - - /** - * The feature id for the 'Static Method' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_STEP_FILTER__STATIC_METHOD = NavigationPackage.JAVA_DECLARATION_EXPRESSION__STATIC_METHOD; - - /** - * The number of structural features of the 'Java Declaration Step Filter' class. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_STEP_FILTER_FEATURE_COUNT = NavigationPackage.JAVA_DECLARATION_EXPRESSION_FEATURE_COUNT + 0; - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.BindingFilter Binding Filter}'. - * - * - * @return the meta object for class 'Binding Filter'. - * @see org.eclipse.emf.eef.mapping.filters.BindingFilter - * @generated - */ - EClass getBindingFilter(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.filters.BindingFilter#getName Name}'. - * - * - * @return the meta object for the attribute 'Name'. - * @see org.eclipse.emf.eef.mapping.filters.BindingFilter#getName() - * @see #getBindingFilter() - * @generated - */ - EAttribute getBindingFilter_Name(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.filters.BindingFilter#isMandatory Mandatory}'. - * - * - * @return the meta object for the attribute 'Mandatory'. - * @see org.eclipse.emf.eef.mapping.filters.BindingFilter#isMandatory() - * @see #getBindingFilter() - * @generated - */ - EAttribute getBindingFilter_Mandatory(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.OCLFilter OCL Filter}'. - * - * - * @return the meta object for class 'OCL Filter'. - * @see org.eclipse.emf.eef.mapping.filters.OCLFilter - * @generated - */ - EClass getOCLFilter(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.filters.OCLFilter#getOCLBody OCL Body}'. - * - * - * @return the meta object for the attribute 'OCL Body'. - * @see org.eclipse.emf.eef.mapping.filters.OCLFilter#getOCLBody() - * @see #getOCLFilter() - * @generated - */ - EAttribute getOCLFilter_OCLBody(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.JavaFilter Java Filter}'. - * - * - * @return the meta object for class 'Java Filter'. - * @see org.eclipse.emf.eef.mapping.filters.JavaFilter - * @generated - */ - EClass getJavaFilter(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter Java Declaration Filter}'. - * - * - * @return the meta object for class 'Java Declaration Filter'. - * @see org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter - * @generated - */ - EClass getJavaDeclarationFilter(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter#getMethodName Method Name}'. - * - * - * @return the meta object for the attribute 'Method Name'. - * @see org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter#getMethodName() - * @see #getJavaDeclarationFilter() - * @generated - */ - EAttribute getJavaDeclarationFilter_MethodName(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter Java Expression Filter}'. - * - * - * @return the meta object for class 'Java Expression Filter'. - * @see org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter - * @generated - */ - EClass getJavaExpressionFilter(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter#getJavaBody Java Body}'. - * - * - * @return the meta object for the attribute 'Java Body'. - * @see org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter#getJavaBody() - * @see #getJavaExpressionFilter() - * @generated - */ - EAttribute getJavaExpressionFilter_JavaBody(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.BusinessFilter Business Filter}'. - * - * - * @return the meta object for class 'Business Filter'. - * @see org.eclipse.emf.eef.mapping.filters.BusinessFilter - * @generated - */ - EClass getBusinessFilter(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter Only Reference Type Filter}'. - * - * - * @return the meta object for class 'Only Reference Type Filter'. - * @see org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter - * @generated - */ - EClass getOnlyReferenceTypeFilter(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter#getReference Reference}'. - * - * - * @return the meta object for the reference 'Reference'. - * @see org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter#getReference() - * @see #getOnlyReferenceTypeFilter() - * @generated - */ - EReference getOnlyReferenceTypeFilter_Reference(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.StrictTypingFilter Strict Typing Filter}'. - * - * - * @return the meta object for class 'Strict Typing Filter'. - * @see org.eclipse.emf.eef.mapping.filters.StrictTypingFilter - * @generated - */ - EClass getStrictTypingFilter(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.filters.StrictTypingFilter#getType Type}'. - * - * - * @return the meta object for the reference 'Type'. - * @see org.eclipse.emf.eef.mapping.filters.StrictTypingFilter#getType() - * @see #getStrictTypingFilter() - * @generated - */ - EReference getStrictTypingFilter_Type(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.StepFilter Step Filter}'. - * - * - * @return the meta object for class 'Step Filter'. - * @see org.eclipse.emf.eef.mapping.filters.StepFilter - * @generated - */ - EClass getStepFilter(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.JavaStepFilter Java Step Filter}'. - * - * - * @return the meta object for class 'Java Step Filter'. - * @see org.eclipse.emf.eef.mapping.filters.JavaStepFilter - * @generated - */ - EClass getJavaStepFilter(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter Java Body Step Filter}'. - * - * - * @return the meta object for class 'Java Body Step Filter'. - * @see org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter - * @generated - */ - EClass getJavaBodyStepFilter(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter Java Declaration Step Filter}'. - * - * - * @return the meta object for class 'Java Declaration Step Filter'. - * @see org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter - * @generated - */ - EClass getJavaDeclarationStepFilter(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - FiltersFactory getFiltersFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.BindingFilterImpl Binding Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.BindingFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getBindingFilter() - * @generated - */ - EClass BINDING_FILTER = eINSTANCE.getBindingFilter(); - - /** - * The meta object literal for the 'Name' attribute feature. - * - * - * @generated - */ - EAttribute BINDING_FILTER__NAME = eINSTANCE.getBindingFilter_Name(); - - /** - * The meta object literal for the 'Mandatory' attribute feature. - * - * - * @generated - */ - EAttribute BINDING_FILTER__MANDATORY = eINSTANCE - .getBindingFilter_Mandatory(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.OCLFilterImpl OCL Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.OCLFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getOCLFilter() - * @generated - */ - EClass OCL_FILTER = eINSTANCE.getOCLFilter(); - - /** - * The meta object literal for the 'OCL Body' attribute feature. - * - * - * @generated - */ - EAttribute OCL_FILTER__OCL_BODY = eINSTANCE.getOCLFilter_OCLBody(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.JavaFilterImpl Java Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.JavaFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaFilter() - * @generated - */ - EClass JAVA_FILTER = eINSTANCE.getJavaFilter(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.JavaDeclarationFilterImpl Java Declaration Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.JavaDeclarationFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaDeclarationFilter() - * @generated - */ - EClass JAVA_DECLARATION_FILTER = eINSTANCE.getJavaDeclarationFilter(); - - /** - * The meta object literal for the 'Method Name' attribute feature. - * - * - * @generated - */ - EAttribute JAVA_DECLARATION_FILTER__METHOD_NAME = eINSTANCE - .getJavaDeclarationFilter_MethodName(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.JavaExpressionFilterImpl Java Expression Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.JavaExpressionFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaExpressionFilter() - * @generated - */ - EClass JAVA_EXPRESSION_FILTER = eINSTANCE.getJavaExpressionFilter(); - - /** - * The meta object literal for the 'Java Body' attribute feature. - * - * - * @generated - */ - EAttribute JAVA_EXPRESSION_FILTER__JAVA_BODY = eINSTANCE - .getJavaExpressionFilter_JavaBody(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.BusinessFilterImpl Business Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.BusinessFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getBusinessFilter() - * @generated - */ - EClass BUSINESS_FILTER = eINSTANCE.getBusinessFilter(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.OnlyReferenceTypeFilterImpl Only Reference Type Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.OnlyReferenceTypeFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getOnlyReferenceTypeFilter() - * @generated - */ - EClass ONLY_REFERENCE_TYPE_FILTER = eINSTANCE - .getOnlyReferenceTypeFilter(); - - /** - * The meta object literal for the 'Reference' reference feature. - * - * - * @generated - */ - EReference ONLY_REFERENCE_TYPE_FILTER__REFERENCE = eINSTANCE - .getOnlyReferenceTypeFilter_Reference(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.StrictTypingFilterImpl Strict Typing Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.StrictTypingFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getStrictTypingFilter() - * @generated - */ - EClass STRICT_TYPING_FILTER = eINSTANCE.getStrictTypingFilter(); - - /** - * The meta object literal for the 'Type' reference feature. - * - * - * @generated - */ - EReference STRICT_TYPING_FILTER__TYPE = eINSTANCE - .getStrictTypingFilter_Type(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.StepFilterImpl Step Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.StepFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getStepFilter() - * @generated - */ - EClass STEP_FILTER = eINSTANCE.getStepFilter(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.JavaStepFilter Java Step Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.JavaStepFilter - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaStepFilter() - * @generated - */ - EClass JAVA_STEP_FILTER = eINSTANCE.getJavaStepFilter(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.JavaBodyStepFilterImpl Java Body Step Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.JavaBodyStepFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaBodyStepFilter() - * @generated - */ - EClass JAVA_BODY_STEP_FILTER = eINSTANCE.getJavaBodyStepFilter(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.filters.impl.JavaDeclarationStepFilterImpl Java Declaration Step Filter}' class. - * - * - * @see org.eclipse.emf.eef.mapping.filters.impl.JavaDeclarationStepFilterImpl - * @see org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl#getJavaDeclarationStepFilter() - * @generated - */ - EClass JAVA_DECLARATION_STEP_FILTER = eINSTANCE - .getJavaDeclarationStepFilter(); - - } - -} //FiltersPackage diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaBodyStepFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaBodyStepFilter.java deleted file mode 100644 index a8d43168d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaBodyStepFilter.java +++ /dev/null @@ -1,22 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.filters; - -import org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression; - -/** - * - * A representation of the model object 'Java Body Step Filter'. - * - * - * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getJavaBodyStepFilter() - * @model - * @generated - */ -public interface JavaBodyStepFilter extends JavaBodyExpression, JavaStepFilter { -} // JavaBodyStepFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaDeclarationFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaDeclarationFilter.java deleted file mode 100644 index 918479af2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaDeclarationFilter.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters; - -/** - * - * A representation of the model object 'Java Declaration Filter'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter#getMethodName Method Name}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getJavaDeclarationFilter() - * @model - * @generated - */ -public interface JavaDeclarationFilter extends JavaFilter { - /** - * Returns the value of the 'Method Name' attribute. - * - *

- * If the meaning of the 'Method Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Method Name' attribute. - * @see #setMethodName(String) - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getJavaDeclarationFilter_MethodName() - * @model - * @generated - */ - String getMethodName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter#getMethodName Method Name}' attribute. - * - * - * @param value the new value of the 'Method Name' attribute. - * @see #getMethodName() - * @generated - */ - void setMethodName(String value); - -} // JavaDeclarationFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaDeclarationStepFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaDeclarationStepFilter.java deleted file mode 100644 index 00ee77f93..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaDeclarationStepFilter.java +++ /dev/null @@ -1,23 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.filters; - -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression; - -/** - * - * A representation of the model object 'Java Declaration Step Filter'. - * - * - * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getJavaDeclarationStepFilter() - * @model - * @generated - */ -public interface JavaDeclarationStepFilter extends JavaDeclarationExpression, - JavaStepFilter { -} // JavaDeclarationStepFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaExpressionFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaExpressionFilter.java deleted file mode 100644 index 78c058917..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaExpressionFilter.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters; - -/** - * - * A representation of the model object 'Java Expression Filter'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter#getJavaBody Java Body}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getJavaExpressionFilter() - * @model - * @generated - */ -public interface JavaExpressionFilter extends JavaFilter { - /** - * Returns the value of the 'Java Body' attribute. - * - *

- * If the meaning of the 'Java Body' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Java Body' attribute. - * @see #setJavaBody(String) - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getJavaExpressionFilter_JavaBody() - * @model - * @generated - */ - String getJavaBody(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter#getJavaBody Java Body}' attribute. - * - * - * @param value the new value of the 'Java Body' attribute. - * @see #getJavaBody() - * @generated - */ - void setJavaBody(String value); - -} // JavaExpressionFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaFilter.java deleted file mode 100644 index 2fbabe7f1..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaFilter.java +++ /dev/null @@ -1,24 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters; - -/** - * - * A representation of the model object 'Java Filter'. - * - * - * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getJavaFilter() - * @model abstract="true" - * @generated - */ -public interface JavaFilter extends BindingFilter { -} // JavaFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaStepFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaStepFilter.java deleted file mode 100644 index e9f4a38c0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/JavaStepFilter.java +++ /dev/null @@ -1,22 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.filters; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Java Step Filter'. - * - * - * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getJavaStepFilter() - * @model interface="true" abstract="true" - * @generated - */ -public interface JavaStepFilter extends StepFilter { -} // JavaStepFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/OCLFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/OCLFilter.java deleted file mode 100644 index 7525dcdc5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/OCLFilter.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters; - -/** - * - * A representation of the model object 'OCL Filter'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.OCLFilter#getOCLBody OCL Body}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getOCLFilter() - * @model - * @generated - */ -public interface OCLFilter extends BindingFilter { - /** - * Returns the value of the 'OCL Body' attribute. - * - *

- * If the meaning of the 'OCL Body' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'OCL Body' attribute. - * @see #setOCLBody(String) - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getOCLFilter_OCLBody() - * @model - * @generated - */ - String getOCLBody(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.filters.OCLFilter#getOCLBody OCL Body}' attribute. - * - * - * @param value the new value of the 'OCL Body' attribute. - * @see #getOCLBody() - * @generated - */ - void setOCLBody(String value); - -} // OCLFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/OnlyReferenceTypeFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/OnlyReferenceTypeFilter.java deleted file mode 100644 index 1241d47e1..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/OnlyReferenceTypeFilter.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters; - -import org.eclipse.emf.ecore.EReference; - -/** - * - * A representation of the model object 'Only Reference Type Filter'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter#getReference Reference}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getOnlyReferenceTypeFilter() - * @model - * @generated - */ -public interface OnlyReferenceTypeFilter extends BusinessFilter { - /** - * Returns the value of the 'Reference' reference. - * - *

- * If the meaning of the 'Reference' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Reference' reference. - * @see #setReference(EReference) - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getOnlyReferenceTypeFilter_Reference() - * @model - * @generated - */ - EReference getReference(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter#getReference Reference}' reference. - * - * - * @param value the new value of the 'Reference' reference. - * @see #getReference() - * @generated - */ - void setReference(EReference value); - -} // OnlyReferenceTypeFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/StepFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/StepFilter.java deleted file mode 100644 index 86f152a86..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/StepFilter.java +++ /dev/null @@ -1,22 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.filters; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Step Filter'. - * - * - * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getStepFilter() - * @model abstract="true" - * @generated - */ -public interface StepFilter extends EObject { -} // StepFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/StrictTypingFilter.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/StrictTypingFilter.java deleted file mode 100644 index 84f7de8c5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/StrictTypingFilter.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters; - -import org.eclipse.emf.ecore.EClassifier; - -/** - * - * A representation of the model object 'Strict Typing Filter'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.StrictTypingFilter#getType Type}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getStrictTypingFilter() - * @model - * @generated - */ -public interface StrictTypingFilter extends BusinessFilter { - /** - * Returns the value of the 'Type' reference. - * - *

- * If the meaning of the 'Type' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Type' reference. - * @see #setType(EClassifier) - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#getStrictTypingFilter_Type() - * @model required="true" - * @generated - */ - EClassifier getType(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.filters.StrictTypingFilter#getType Type}' reference. - * - * - * @param value the new value of the 'Type' reference. - * @see #getType() - * @generated - */ - void setType(EClassifier value); - -} // StrictTypingFilter diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/BindingFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/BindingFilterImpl.java deleted file mode 100644 index 3661f8070..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/BindingFilterImpl.java +++ /dev/null @@ -1,228 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.impl.DocumentedElementImpl; - -/** - * - * An implementation of the model object 'Binding Filter'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.impl.BindingFilterImpl#getName Name}
  • - *
  • {@link org.eclipse.emf.eef.mapping.filters.impl.BindingFilterImpl#isMandatory Mandatory}
  • - *
- *

- * - * @generated - */ -public abstract class BindingFilterImpl extends DocumentedElementImpl implements - BindingFilter { - /** - * The default value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The default value of the '{@link #isMandatory() Mandatory}' attribute. - * - * - * @see #isMandatory() - * @generated - * @ordered - */ - protected static final boolean MANDATORY_EDEFAULT = true; - - /** - * The cached value of the '{@link #isMandatory() Mandatory}' attribute. - * - * - * @see #isMandatory() - * @generated - * @ordered - */ - protected boolean mandatory = MANDATORY_EDEFAULT; - - /** - * - * - * @generated - */ - protected BindingFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.BINDING_FILTER; - } - - /** - * - * - * @generated - */ - public String getName() { - return name; - } - - /** - * - * - * @generated - */ - public void setName(String newName) { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - FiltersPackage.BINDING_FILTER__NAME, oldName, name)); - } - - /** - * - * - * @generated - */ - public boolean isMandatory() { - return mandatory; - } - - /** - * - * - * @generated - */ - public void setMandatory(boolean newMandatory) { - boolean oldMandatory = mandatory; - mandatory = newMandatory; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - FiltersPackage.BINDING_FILTER__MANDATORY, oldMandatory, - mandatory)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case FiltersPackage.BINDING_FILTER__NAME: - return getName(); - case FiltersPackage.BINDING_FILTER__MANDATORY: - return isMandatory(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case FiltersPackage.BINDING_FILTER__NAME: - setName((String) newValue); - return; - case FiltersPackage.BINDING_FILTER__MANDATORY: - setMandatory((Boolean) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case FiltersPackage.BINDING_FILTER__NAME: - setName(NAME_EDEFAULT); - return; - case FiltersPackage.BINDING_FILTER__MANDATORY: - setMandatory(MANDATORY_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case FiltersPackage.BINDING_FILTER__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT - .equals(name); - case FiltersPackage.BINDING_FILTER__MANDATORY: - return mandatory != MANDATORY_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(", mandatory: "); - result.append(mandatory); - result.append(')'); - return result.toString(); - } - -} //BindingFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/BusinessFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/BusinessFilterImpl.java deleted file mode 100644 index 6bcbb221d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/BusinessFilterImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.mapping.filters.BusinessFilter; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; - -/** - * - * An implementation of the model object 'Business Filter'. - * - *

- *

- * - * @generated - */ -public abstract class BusinessFilterImpl extends BindingFilterImpl implements - BusinessFilter { - /** - * - * - * @generated - */ - protected BusinessFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.BUSINESS_FILTER; - } - -} //BusinessFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/FiltersFactoryImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/FiltersFactoryImpl.java deleted file mode 100644 index 11ce801fe..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/FiltersFactoryImpl.java +++ /dev/null @@ -1,181 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.impl.EFactoryImpl; -import org.eclipse.emf.ecore.plugin.EcorePlugin; -import org.eclipse.emf.eef.mapping.filters.*; -import org.eclipse.emf.eef.mapping.filters.FiltersFactory; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter; -import org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter; -import org.eclipse.emf.eef.mapping.filters.OCLFilter; -import org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter; -import org.eclipse.emf.eef.mapping.filters.StrictTypingFilter; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class FiltersFactoryImpl extends EFactoryImpl implements FiltersFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static FiltersFactory init() { - try { - FiltersFactory theFiltersFactory = (FiltersFactory) EPackage.Registry.INSTANCE - .getEFactory("http://www.eclipse.org/emf/eef/mapping/filters/1.0.0"); - if (theFiltersFactory != null) { - return theFiltersFactory; - } - } catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new FiltersFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public FiltersFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case FiltersPackage.OCL_FILTER: - return createOCLFilter(); - case FiltersPackage.JAVA_DECLARATION_FILTER: - return createJavaDeclarationFilter(); - case FiltersPackage.JAVA_EXPRESSION_FILTER: - return createJavaExpressionFilter(); - case FiltersPackage.ONLY_REFERENCE_TYPE_FILTER: - return createOnlyReferenceTypeFilter(); - case FiltersPackage.STRICT_TYPING_FILTER: - return createStrictTypingFilter(); - case FiltersPackage.JAVA_BODY_STEP_FILTER: - return createJavaBodyStepFilter(); - case FiltersPackage.JAVA_DECLARATION_STEP_FILTER: - return createJavaDeclarationStepFilter(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() - + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public OCLFilter createOCLFilter() { - OCLFilterImpl oclFilter = new OCLFilterImpl(); - return oclFilter; - } - - /** - * - * - * @generated - */ - public JavaDeclarationFilter createJavaDeclarationFilter() { - JavaDeclarationFilterImpl javaDeclarationFilter = new JavaDeclarationFilterImpl(); - return javaDeclarationFilter; - } - - /** - * - * - * @generated - */ - public JavaExpressionFilter createJavaExpressionFilter() { - JavaExpressionFilterImpl javaExpressionFilter = new JavaExpressionFilterImpl(); - return javaExpressionFilter; - } - - /** - * - * - * @generated - */ - public OnlyReferenceTypeFilter createOnlyReferenceTypeFilter() { - OnlyReferenceTypeFilterImpl onlyReferenceTypeFilter = new OnlyReferenceTypeFilterImpl(); - return onlyReferenceTypeFilter; - } - - /** - * - * - * @generated - */ - public StrictTypingFilter createStrictTypingFilter() { - StrictTypingFilterImpl strictTypingFilter = new StrictTypingFilterImpl(); - return strictTypingFilter; - } - - /** - * - * - * @generated - */ - public JavaBodyStepFilter createJavaBodyStepFilter() { - JavaBodyStepFilterImpl javaBodyStepFilter = new JavaBodyStepFilterImpl(); - return javaBodyStepFilter; - } - - /** - * - * - * @generated - */ - public JavaDeclarationStepFilter createJavaDeclarationStepFilter() { - JavaDeclarationStepFilterImpl javaDeclarationStepFilter = new JavaDeclarationStepFilterImpl(); - return javaDeclarationStepFilter; - } - - /** - * - * - * @generated - */ - public FiltersPackage getFiltersPackage() { - return (FiltersPackage) getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static FiltersPackage getPackage() { - return FiltersPackage.eINSTANCE; - } - -} //FiltersFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/FiltersPackageImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/FiltersPackageImpl.java deleted file mode 100644 index b10ad3fbc..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/FiltersPackageImpl.java +++ /dev/null @@ -1,592 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.impl.EPackageImpl; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.mapping.filters.BusinessFilter; -import org.eclipse.emf.eef.mapping.filters.FiltersFactory; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter; -import org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter; -import org.eclipse.emf.eef.mapping.filters.JavaFilter; -import org.eclipse.emf.eef.mapping.filters.JavaStepFilter; -import org.eclipse.emf.eef.mapping.filters.OCLFilter; -import org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter; -import org.eclipse.emf.eef.mapping.filters.StepFilter; -import org.eclipse.emf.eef.mapping.filters.StrictTypingFilter; -import org.eclipse.emf.eef.mapping.impl.MappingPackageImpl; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl; -import org.eclipse.emf.eef.mapping.settings.SettingsPackage; -import org.eclipse.emf.eef.mapping.settings.impl.SettingsPackageImpl; -import org.eclipse.emf.eef.views.ViewsPackage; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class FiltersPackageImpl extends EPackageImpl implements FiltersPackage { - /** - * - * - * @generated - */ - private EClass bindingFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass oclFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass javaFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass javaDeclarationFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass javaExpressionFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass businessFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass onlyReferenceTypeFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass strictTypingFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass stepFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass javaStepFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass javaBodyStepFilterEClass = null; - - /** - * - * - * @generated - */ - private EClass javaDeclarationStepFilterEClass = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage#eNS_URI - * @see #init() - * @generated - */ - private FiltersPackageImpl() { - super(eNS_URI, FiltersFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link FiltersPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static FiltersPackage init() { - if (isInited) - return (FiltersPackage) EPackage.Registry.INSTANCE - .getEPackage(FiltersPackage.eNS_URI); - - // Obtain or create and register package - FiltersPackageImpl theFiltersPackage = (FiltersPackageImpl) (EPackage.Registry.INSTANCE - .get(eNS_URI) instanceof FiltersPackageImpl ? EPackage.Registry.INSTANCE - .get(eNS_URI) : new FiltersPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - EcorePackage.eINSTANCE.eClass(); - ViewsPackage.eINSTANCE.eClass(); - - // Obtain or create and register interdependencies - MappingPackageImpl theMappingPackage = (MappingPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(MappingPackage.eNS_URI) instanceof MappingPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(MappingPackage.eNS_URI) : MappingPackage.eINSTANCE); - NavigationPackageImpl theNavigationPackage = (NavigationPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(NavigationPackage.eNS_URI) instanceof NavigationPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(NavigationPackage.eNS_URI) - : NavigationPackage.eINSTANCE); - SettingsPackageImpl theSettingsPackage = (SettingsPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(SettingsPackage.eNS_URI) instanceof SettingsPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(SettingsPackage.eNS_URI) - : SettingsPackage.eINSTANCE); - - // Create package meta-data objects - theFiltersPackage.createPackageContents(); - theMappingPackage.createPackageContents(); - theNavigationPackage.createPackageContents(); - theSettingsPackage.createPackageContents(); - - // Initialize created meta-data - theFiltersPackage.initializePackageContents(); - theMappingPackage.initializePackageContents(); - theNavigationPackage.initializePackageContents(); - theSettingsPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theFiltersPackage.freeze(); - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(FiltersPackage.eNS_URI, - theFiltersPackage); - return theFiltersPackage; - } - - /** - * - * - * @generated - */ - public EClass getBindingFilter() { - return bindingFilterEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getBindingFilter_Name() { - return (EAttribute) bindingFilterEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EAttribute getBindingFilter_Mandatory() { - return (EAttribute) bindingFilterEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getOCLFilter() { - return oclFilterEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getOCLFilter_OCLBody() { - return (EAttribute) oclFilterEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getJavaFilter() { - return javaFilterEClass; - } - - /** - * - * - * @generated - */ - public EClass getJavaDeclarationFilter() { - return javaDeclarationFilterEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getJavaDeclarationFilter_MethodName() { - return (EAttribute) javaDeclarationFilterEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getJavaExpressionFilter() { - return javaExpressionFilterEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getJavaExpressionFilter_JavaBody() { - return (EAttribute) javaExpressionFilterEClass.getEStructuralFeatures() - .get(0); - } - - /** - * - * - * @generated - */ - public EClass getBusinessFilter() { - return businessFilterEClass; - } - - /** - * - * - * @generated - */ - public EClass getOnlyReferenceTypeFilter() { - return onlyReferenceTypeFilterEClass; - } - - /** - * - * - * @generated - */ - public EReference getOnlyReferenceTypeFilter_Reference() { - return (EReference) onlyReferenceTypeFilterEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getStrictTypingFilter() { - return strictTypingFilterEClass; - } - - /** - * - * - * @generated - */ - public EReference getStrictTypingFilter_Type() { - return (EReference) strictTypingFilterEClass.getEStructuralFeatures() - .get(0); - } - - /** - * - * - * @generated - */ - public EClass getStepFilter() { - return stepFilterEClass; - } - - /** - * - * - * @generated - */ - public EClass getJavaStepFilter() { - return javaStepFilterEClass; - } - - /** - * - * - * @generated - */ - public EClass getJavaBodyStepFilter() { - return javaBodyStepFilterEClass; - } - - /** - * - * - * @generated - */ - public EClass getJavaDeclarationStepFilter() { - return javaDeclarationStepFilterEClass; - } - - /** - * - * - * @generated - */ - public FiltersFactory getFiltersFactory() { - return (FiltersFactory) getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) - return; - isCreated = true; - - // Create classes and their features - bindingFilterEClass = createEClass(BINDING_FILTER); - createEAttribute(bindingFilterEClass, BINDING_FILTER__NAME); - createEAttribute(bindingFilterEClass, BINDING_FILTER__MANDATORY); - - oclFilterEClass = createEClass(OCL_FILTER); - createEAttribute(oclFilterEClass, OCL_FILTER__OCL_BODY); - - javaFilterEClass = createEClass(JAVA_FILTER); - - javaDeclarationFilterEClass = createEClass(JAVA_DECLARATION_FILTER); - createEAttribute(javaDeclarationFilterEClass, - JAVA_DECLARATION_FILTER__METHOD_NAME); - - javaExpressionFilterEClass = createEClass(JAVA_EXPRESSION_FILTER); - createEAttribute(javaExpressionFilterEClass, - JAVA_EXPRESSION_FILTER__JAVA_BODY); - - businessFilterEClass = createEClass(BUSINESS_FILTER); - - onlyReferenceTypeFilterEClass = createEClass(ONLY_REFERENCE_TYPE_FILTER); - createEReference(onlyReferenceTypeFilterEClass, - ONLY_REFERENCE_TYPE_FILTER__REFERENCE); - - strictTypingFilterEClass = createEClass(STRICT_TYPING_FILTER); - createEReference(strictTypingFilterEClass, STRICT_TYPING_FILTER__TYPE); - - stepFilterEClass = createEClass(STEP_FILTER); - - javaStepFilterEClass = createEClass(JAVA_STEP_FILTER); - - javaBodyStepFilterEClass = createEClass(JAVA_BODY_STEP_FILTER); - - javaDeclarationStepFilterEClass = createEClass(JAVA_DECLARATION_STEP_FILTER); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) - return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - MappingPackage theMappingPackage = (MappingPackage) EPackage.Registry.INSTANCE - .getEPackage(MappingPackage.eNS_URI); - NavigationPackage theNavigationPackage = (NavigationPackage) EPackage.Registry.INSTANCE - .getEPackage(NavigationPackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - bindingFilterEClass.getESuperTypes().add( - theMappingPackage.getDocumentedElement()); - oclFilterEClass.getESuperTypes().add(this.getBindingFilter()); - javaFilterEClass.getESuperTypes().add(this.getBindingFilter()); - javaDeclarationFilterEClass.getESuperTypes().add(this.getJavaFilter()); - javaExpressionFilterEClass.getESuperTypes().add(this.getJavaFilter()); - businessFilterEClass.getESuperTypes().add(this.getBindingFilter()); - onlyReferenceTypeFilterEClass.getESuperTypes().add( - this.getBusinessFilter()); - strictTypingFilterEClass.getESuperTypes().add(this.getBusinessFilter()); - javaStepFilterEClass.getESuperTypes().add(this.getStepFilter()); - javaBodyStepFilterEClass.getESuperTypes().add( - theNavigationPackage.getJavaBodyExpression()); - javaBodyStepFilterEClass.getESuperTypes().add(this.getJavaStepFilter()); - javaDeclarationStepFilterEClass.getESuperTypes().add( - theNavigationPackage.getJavaDeclarationExpression()); - javaDeclarationStepFilterEClass.getESuperTypes().add( - this.getJavaStepFilter()); - - // Initialize classes and features; add operations and parameters - initEClass(bindingFilterEClass, BindingFilter.class, "BindingFilter", - IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getBindingFilter_Name(), ecorePackage.getEString(), - "name", null, 0, 1, BindingFilter.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, - !IS_DERIVED, IS_ORDERED); - initEAttribute(getBindingFilter_Mandatory(), - ecorePackage.getEBoolean(), "mandatory", "true", 0, 1, - BindingFilter.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - - initEClass(oclFilterEClass, OCLFilter.class, "OCLFilter", !IS_ABSTRACT, - !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getOCLFilter_OCLBody(), ecorePackage.getEString(), - "OCLBody", null, 0, 1, OCLFilter.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, - !IS_DERIVED, IS_ORDERED); - - initEClass(javaFilterEClass, JavaFilter.class, "JavaFilter", - IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(javaDeclarationFilterEClass, JavaDeclarationFilter.class, - "JavaDeclarationFilter", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getJavaDeclarationFilter_MethodName(), - ecorePackage.getEString(), "methodName", null, 0, 1, - JavaDeclarationFilter.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - - initEClass(javaExpressionFilterEClass, JavaExpressionFilter.class, - "JavaExpressionFilter", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getJavaExpressionFilter_JavaBody(), - ecorePackage.getEString(), "javaBody", null, 0, 1, - JavaExpressionFilter.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - - initEClass(businessFilterEClass, BusinessFilter.class, - "BusinessFilter", IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - - initEClass(onlyReferenceTypeFilterEClass, - OnlyReferenceTypeFilter.class, "OnlyReferenceTypeFilter", - !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getOnlyReferenceTypeFilter_Reference(), - ecorePackage.getEReference(), null, "reference", null, 0, 1, - OnlyReferenceTypeFilter.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(strictTypingFilterEClass, StrictTypingFilter.class, - "StrictTypingFilter", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEReference(getStrictTypingFilter_Type(), - ecorePackage.getEClassifier(), null, "type", null, 1, 1, - StrictTypingFilter.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(stepFilterEClass, StepFilter.class, "StepFilter", - IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(javaStepFilterEClass, JavaStepFilter.class, - "JavaStepFilter", IS_ABSTRACT, IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - - initEClass(javaBodyStepFilterEClass, JavaBodyStepFilter.class, - "JavaBodyStepFilter", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - - initEClass(javaDeclarationStepFilterEClass, - JavaDeclarationStepFilter.class, "JavaDeclarationStepFilter", - !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - } - -} //FiltersPackageImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaBodyStepFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaBodyStepFilterImpl.java deleted file mode 100644 index 7b8e32dc4..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaBodyStepFilterImpl.java +++ /dev/null @@ -1,46 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter; - -import org.eclipse.emf.eef.mapping.navigation.impl.JavaBodyExpressionImpl; - -/** - * - * An implementation of the model object 'Java Body Step Filter'. - * - *

- *

- * - * @generated - */ -public class JavaBodyStepFilterImpl extends JavaBodyExpressionImpl implements - JavaBodyStepFilter { - /** - * - * - * @generated - */ - protected JavaBodyStepFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.JAVA_BODY_STEP_FILTER; - } - -} //JavaBodyStepFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaDeclarationFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaDeclarationFilterImpl.java deleted file mode 100644 index 1732ffe9e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaDeclarationFilterImpl.java +++ /dev/null @@ -1,172 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter; - -/** - * - * An implementation of the model object 'Java Declaration Filter'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.impl.JavaDeclarationFilterImpl#getMethodName Method Name}
  • - *
- *

- * - * @generated - */ -public class JavaDeclarationFilterImpl extends JavaFilterImpl implements - JavaDeclarationFilter { - /** - * The default value of the '{@link #getMethodName() Method Name}' attribute. - * - * - * @see #getMethodName() - * @generated - * @ordered - */ - protected static final String METHOD_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getMethodName() Method Name}' attribute. - * - * - * @see #getMethodName() - * @generated - * @ordered - */ - protected String methodName = METHOD_NAME_EDEFAULT; - - /** - * - * - * @generated - */ - protected JavaDeclarationFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.JAVA_DECLARATION_FILTER; - } - - /** - * - * - * @generated - */ - public String getMethodName() { - return methodName; - } - - /** - * - * - * @generated - */ - public void setMethodName(String newMethodName) { - String oldMethodName = methodName; - methodName = newMethodName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - FiltersPackage.JAVA_DECLARATION_FILTER__METHOD_NAME, - oldMethodName, methodName)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case FiltersPackage.JAVA_DECLARATION_FILTER__METHOD_NAME: - return getMethodName(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case FiltersPackage.JAVA_DECLARATION_FILTER__METHOD_NAME: - setMethodName((String) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case FiltersPackage.JAVA_DECLARATION_FILTER__METHOD_NAME: - setMethodName(METHOD_NAME_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case FiltersPackage.JAVA_DECLARATION_FILTER__METHOD_NAME: - return METHOD_NAME_EDEFAULT == null ? methodName != null - : !METHOD_NAME_EDEFAULT.equals(methodName); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (methodName: "); - result.append(methodName); - result.append(')'); - return result.toString(); - } - -} //JavaDeclarationFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaDeclarationStepFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaDeclarationStepFilterImpl.java deleted file mode 100644 index 2b3e3785c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaDeclarationStepFilterImpl.java +++ /dev/null @@ -1,46 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter; - -import org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationExpressionImpl; - -/** - * - * An implementation of the model object 'Java Declaration Step Filter'. - * - *

- *

- * - * @generated - */ -public class JavaDeclarationStepFilterImpl extends - JavaDeclarationExpressionImpl implements JavaDeclarationStepFilter { - /** - * - * - * @generated - */ - protected JavaDeclarationStepFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.JAVA_DECLARATION_STEP_FILTER; - } - -} //JavaDeclarationStepFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaExpressionFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaExpressionFilterImpl.java deleted file mode 100644 index c90df8b43..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaExpressionFilterImpl.java +++ /dev/null @@ -1,172 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter; - -/** - * - * An implementation of the model object 'Java Expression Filter'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.impl.JavaExpressionFilterImpl#getJavaBody Java Body}
  • - *
- *

- * - * @generated - */ -public class JavaExpressionFilterImpl extends JavaFilterImpl implements - JavaExpressionFilter { - /** - * The default value of the '{@link #getJavaBody() Java Body}' attribute. - * - * - * @see #getJavaBody() - * @generated - * @ordered - */ - protected static final String JAVA_BODY_EDEFAULT = null; - - /** - * The cached value of the '{@link #getJavaBody() Java Body}' attribute. - * - * - * @see #getJavaBody() - * @generated - * @ordered - */ - protected String javaBody = JAVA_BODY_EDEFAULT; - - /** - * - * - * @generated - */ - protected JavaExpressionFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.JAVA_EXPRESSION_FILTER; - } - - /** - * - * - * @generated - */ - public String getJavaBody() { - return javaBody; - } - - /** - * - * - * @generated - */ - public void setJavaBody(String newJavaBody) { - String oldJavaBody = javaBody; - javaBody = newJavaBody; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - FiltersPackage.JAVA_EXPRESSION_FILTER__JAVA_BODY, - oldJavaBody, javaBody)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case FiltersPackage.JAVA_EXPRESSION_FILTER__JAVA_BODY: - return getJavaBody(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case FiltersPackage.JAVA_EXPRESSION_FILTER__JAVA_BODY: - setJavaBody((String) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case FiltersPackage.JAVA_EXPRESSION_FILTER__JAVA_BODY: - setJavaBody(JAVA_BODY_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case FiltersPackage.JAVA_EXPRESSION_FILTER__JAVA_BODY: - return JAVA_BODY_EDEFAULT == null ? javaBody != null - : !JAVA_BODY_EDEFAULT.equals(javaBody); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (javaBody: "); - result.append(javaBody); - result.append(')'); - return result.toString(); - } - -} //JavaExpressionFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaFilterImpl.java deleted file mode 100644 index 3da3aceee..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/JavaFilterImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaFilter; - -/** - * - * An implementation of the model object 'Java Filter'. - * - *

- *

- * - * @generated - */ -public abstract class JavaFilterImpl extends BindingFilterImpl implements - JavaFilter { - /** - * - * - * @generated - */ - protected JavaFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.JAVA_FILTER; - } - -} //JavaFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/OCLFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/OCLFilterImpl.java deleted file mode 100644 index c71eb6c07..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/OCLFilterImpl.java +++ /dev/null @@ -1,170 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.OCLFilter; - -/** - * - * An implementation of the model object 'OCL Filter'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.impl.OCLFilterImpl#getOCLBody OCL Body}
  • - *
- *

- * - * @generated - */ -public class OCLFilterImpl extends BindingFilterImpl implements OCLFilter { - /** - * The default value of the '{@link #getOCLBody() OCL Body}' attribute. - * - * - * @see #getOCLBody() - * @generated - * @ordered - */ - protected static final String OCL_BODY_EDEFAULT = null; - - /** - * The cached value of the '{@link #getOCLBody() OCL Body}' attribute. - * - * - * @see #getOCLBody() - * @generated - * @ordered - */ - protected String oclBody = OCL_BODY_EDEFAULT; - - /** - * - * - * @generated - */ - protected OCLFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.OCL_FILTER; - } - - /** - * - * - * @generated - */ - public String getOCLBody() { - return oclBody; - } - - /** - * - * - * @generated - */ - public void setOCLBody(String newOCLBody) { - String oldOCLBody = oclBody; - oclBody = newOCLBody; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - FiltersPackage.OCL_FILTER__OCL_BODY, oldOCLBody, oclBody)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case FiltersPackage.OCL_FILTER__OCL_BODY: - return getOCLBody(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case FiltersPackage.OCL_FILTER__OCL_BODY: - setOCLBody((String) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case FiltersPackage.OCL_FILTER__OCL_BODY: - setOCLBody(OCL_BODY_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case FiltersPackage.OCL_FILTER__OCL_BODY: - return OCL_BODY_EDEFAULT == null ? oclBody != null - : !OCL_BODY_EDEFAULT.equals(oclBody); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (OCLBody: "); - result.append(oclBody); - result.append(')'); - return result.toString(); - } - -} //OCLFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/OnlyReferenceTypeFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/OnlyReferenceTypeFilterImpl.java deleted file mode 100644 index e9859b422..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/OnlyReferenceTypeFilterImpl.java +++ /dev/null @@ -1,169 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter; - -/** - * - * An implementation of the model object 'Only Reference Type Filter'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.impl.OnlyReferenceTypeFilterImpl#getReference Reference}
  • - *
- *

- * - * @generated - */ -public class OnlyReferenceTypeFilterImpl extends BusinessFilterImpl implements - OnlyReferenceTypeFilter { - /** - * The cached value of the '{@link #getReference() Reference}' reference. - * - * - * @see #getReference() - * @generated - * @ordered - */ - protected EReference reference; - - /** - * - * - * @generated - */ - protected OnlyReferenceTypeFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.ONLY_REFERENCE_TYPE_FILTER; - } - - /** - * - * - * @generated - */ - public EReference getReference() { - if (reference != null && reference.eIsProxy()) { - InternalEObject oldReference = (InternalEObject) reference; - reference = (EReference) eResolveProxy(oldReference); - if (reference != oldReference) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl( - this, - Notification.RESOLVE, - FiltersPackage.ONLY_REFERENCE_TYPE_FILTER__REFERENCE, - oldReference, reference)); - } - } - return reference; - } - - /** - * - * - * @generated - */ - public EReference basicGetReference() { - return reference; - } - - /** - * - * - * @generated - */ - public void setReference(EReference newReference) { - EReference oldReference = reference; - reference = newReference; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - FiltersPackage.ONLY_REFERENCE_TYPE_FILTER__REFERENCE, - oldReference, reference)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case FiltersPackage.ONLY_REFERENCE_TYPE_FILTER__REFERENCE: - if (resolve) - return getReference(); - return basicGetReference(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case FiltersPackage.ONLY_REFERENCE_TYPE_FILTER__REFERENCE: - setReference((EReference) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case FiltersPackage.ONLY_REFERENCE_TYPE_FILTER__REFERENCE: - setReference((EReference) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case FiltersPackage.ONLY_REFERENCE_TYPE_FILTER__REFERENCE: - return reference != null; - } - return super.eIsSet(featureID); - } - -} //OnlyReferenceTypeFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/StepFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/StepFilterImpl.java deleted file mode 100644 index 88f96a3f0..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/StepFilterImpl.java +++ /dev/null @@ -1,45 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.EObjectImpl; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.StepFilter; - -/** - * - * An implementation of the model object 'Step Filter'. - * - *

- *

- * - * @generated - */ -public abstract class StepFilterImpl extends EObjectImpl implements StepFilter { - /** - * - * - * @generated - */ - protected StepFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.STEP_FILTER; - } - -} //StepFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/StrictTypingFilterImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/StrictTypingFilterImpl.java deleted file mode 100644 index 2b7097dbd..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/impl/StrictTypingFilterImpl.java +++ /dev/null @@ -1,169 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.StrictTypingFilter; - -/** - * - * An implementation of the model object 'Strict Typing Filter'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.filters.impl.StrictTypingFilterImpl#getType Type}
  • - *
- *

- * - * @generated - */ -public class StrictTypingFilterImpl extends BusinessFilterImpl implements - StrictTypingFilter { - /** - * The cached value of the '{@link #getType() Type}' reference. - * - * - * @see #getType() - * @generated - * @ordered - */ - protected EClassifier type; - - /** - * - * - * @generated - */ - protected StrictTypingFilterImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return FiltersPackage.Literals.STRICT_TYPING_FILTER; - } - - /** - * - * - * @generated - */ - public EClassifier getType() { - if (type != null && type.eIsProxy()) { - InternalEObject oldType = (InternalEObject) type; - type = (EClassifier) eResolveProxy(oldType); - if (type != oldType) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - FiltersPackage.STRICT_TYPING_FILTER__TYPE, oldType, - type)); - } - } - return type; - } - - /** - * - * - * @generated - */ - public EClassifier basicGetType() { - return type; - } - - /** - * - * - * @generated - */ - public void setType(EClassifier newType) { - EClassifier oldType = type; - type = newType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - FiltersPackage.STRICT_TYPING_FILTER__TYPE, oldType, type)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case FiltersPackage.STRICT_TYPING_FILTER__TYPE: - if (resolve) - return getType(); - return basicGetType(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case FiltersPackage.STRICT_TYPING_FILTER__TYPE: - setType((EClassifier) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case FiltersPackage.STRICT_TYPING_FILTER__TYPE: - setType((EClassifier) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case FiltersPackage.STRICT_TYPING_FILTER__TYPE: - return type != null; - } - return super.eIsSet(featureID); - } - -} //StrictTypingFilterImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/util/FiltersAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/util/FiltersAdapterFactory.java deleted file mode 100644 index 2620d3dcd..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/util/FiltersAdapterFactory.java +++ /dev/null @@ -1,405 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.filters.*; -import org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression; -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.mapping.filters.BusinessFilter; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter; -import org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter; -import org.eclipse.emf.eef.mapping.filters.JavaFilter; -import org.eclipse.emf.eef.mapping.filters.OCLFilter; -import org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter; -import org.eclipse.emf.eef.mapping.filters.StrictTypingFilter; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage - * @generated - */ -public class FiltersAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static FiltersPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public FiltersAdapterFactory() { - if (modelPackage == null) { - modelPackage = FiltersPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject) object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected FiltersSwitch modelSwitch = new FiltersSwitch() { - @Override - public Adapter caseBindingFilter(BindingFilter object) { - return createBindingFilterAdapter(); - } - - @Override - public Adapter caseOCLFilter(OCLFilter object) { - return createOCLFilterAdapter(); - } - - @Override - public Adapter caseJavaFilter(JavaFilter object) { - return createJavaFilterAdapter(); - } - - @Override - public Adapter caseJavaDeclarationFilter(JavaDeclarationFilter object) { - return createJavaDeclarationFilterAdapter(); - } - - @Override - public Adapter caseJavaExpressionFilter(JavaExpressionFilter object) { - return createJavaExpressionFilterAdapter(); - } - - @Override - public Adapter caseBusinessFilter(BusinessFilter object) { - return createBusinessFilterAdapter(); - } - - @Override - public Adapter caseOnlyReferenceTypeFilter( - OnlyReferenceTypeFilter object) { - return createOnlyReferenceTypeFilterAdapter(); - } - - @Override - public Adapter caseStrictTypingFilter(StrictTypingFilter object) { - return createStrictTypingFilterAdapter(); - } - - @Override - public Adapter caseStepFilter(StepFilter object) { - return createStepFilterAdapter(); - } - - @Override - public Adapter caseJavaStepFilter(JavaStepFilter object) { - return createJavaStepFilterAdapter(); - } - - @Override - public Adapter caseJavaBodyStepFilter(JavaBodyStepFilter object) { - return createJavaBodyStepFilterAdapter(); - } - - @Override - public Adapter caseJavaDeclarationStepFilter( - JavaDeclarationStepFilter object) { - return createJavaDeclarationStepFilterAdapter(); - } - - @Override - public Adapter caseDocumentedElement(DocumentedElement object) { - return createDocumentedElementAdapter(); - } - - @Override - public Adapter caseJavaBodyExpression(JavaBodyExpression object) { - return createJavaBodyExpressionAdapter(); - } - - @Override - public Adapter caseJavaDeclarationExpression( - JavaDeclarationExpression object) { - return createJavaDeclarationExpressionAdapter(); - } - - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject) target); - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.BindingFilter Binding Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.BindingFilter - * @generated - */ - public Adapter createBindingFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.OCLFilter OCL Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.OCLFilter - * @generated - */ - public Adapter createOCLFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.JavaFilter Java Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.JavaFilter - * @generated - */ - public Adapter createJavaFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter Java Declaration Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter - * @generated - */ - public Adapter createJavaDeclarationFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter Java Expression Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter - * @generated - */ - public Adapter createJavaExpressionFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.BusinessFilter Business Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.BusinessFilter - * @generated - */ - public Adapter createBusinessFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter Only Reference Type Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter - * @generated - */ - public Adapter createOnlyReferenceTypeFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.StrictTypingFilter Strict Typing Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.StrictTypingFilter - * @generated - */ - public Adapter createStrictTypingFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.StepFilter Step Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.StepFilter - * @generated - */ - public Adapter createStepFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.JavaStepFilter Java Step Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.JavaStepFilter - * @generated - */ - public Adapter createJavaStepFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter Java Body Step Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.JavaBodyStepFilter - * @generated - */ - public Adapter createJavaBodyStepFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter Java Declaration Step Filter}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.filters.JavaDeclarationStepFilter - * @generated - */ - public Adapter createJavaDeclarationStepFilterAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.DocumentedElement Documented Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.DocumentedElement - * @generated - */ - public Adapter createDocumentedElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression Java Body Expression}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression - * @generated - */ - public Adapter createJavaBodyExpressionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression Java Declaration Expression}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression - * @generated - */ - public Adapter createJavaDeclarationExpressionAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //FiltersAdapterFactory diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/util/FiltersSwitch.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/util/FiltersSwitch.java deleted file mode 100644 index d5408ad7c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/filters/util/FiltersSwitch.java +++ /dev/null @@ -1,484 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.filters.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.filters.*; -import org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression; -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.mapping.filters.BusinessFilter; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.JavaDeclarationFilter; -import org.eclipse.emf.eef.mapping.filters.JavaExpressionFilter; -import org.eclipse.emf.eef.mapping.filters.JavaFilter; -import org.eclipse.emf.eef.mapping.filters.OCLFilter; -import org.eclipse.emf.eef.mapping.filters.OnlyReferenceTypeFilter; -import org.eclipse.emf.eef.mapping.filters.StrictTypingFilter; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.mapping.filters.FiltersPackage - * @generated - */ -public class FiltersSwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static FiltersPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public FiltersSwitch() { - if (modelPackage == null) { - modelPackage = FiltersPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } else { - List eSuperTypes = theEClass.getESuperTypes(); - return eSuperTypes.isEmpty() ? defaultCase(theEObject) : doSwitch( - eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case FiltersPackage.BINDING_FILTER: { - BindingFilter bindingFilter = (BindingFilter) theEObject; - T result = caseBindingFilter(bindingFilter); - if (result == null) - result = caseDocumentedElement(bindingFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.OCL_FILTER: { - OCLFilter oclFilter = (OCLFilter) theEObject; - T result = caseOCLFilter(oclFilter); - if (result == null) - result = caseBindingFilter(oclFilter); - if (result == null) - result = caseDocumentedElement(oclFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.JAVA_FILTER: { - JavaFilter javaFilter = (JavaFilter) theEObject; - T result = caseJavaFilter(javaFilter); - if (result == null) - result = caseBindingFilter(javaFilter); - if (result == null) - result = caseDocumentedElement(javaFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.JAVA_DECLARATION_FILTER: { - JavaDeclarationFilter javaDeclarationFilter = (JavaDeclarationFilter) theEObject; - T result = caseJavaDeclarationFilter(javaDeclarationFilter); - if (result == null) - result = caseJavaFilter(javaDeclarationFilter); - if (result == null) - result = caseBindingFilter(javaDeclarationFilter); - if (result == null) - result = caseDocumentedElement(javaDeclarationFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.JAVA_EXPRESSION_FILTER: { - JavaExpressionFilter javaExpressionFilter = (JavaExpressionFilter) theEObject; - T result = caseJavaExpressionFilter(javaExpressionFilter); - if (result == null) - result = caseJavaFilter(javaExpressionFilter); - if (result == null) - result = caseBindingFilter(javaExpressionFilter); - if (result == null) - result = caseDocumentedElement(javaExpressionFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.BUSINESS_FILTER: { - BusinessFilter businessFilter = (BusinessFilter) theEObject; - T result = caseBusinessFilter(businessFilter); - if (result == null) - result = caseBindingFilter(businessFilter); - if (result == null) - result = caseDocumentedElement(businessFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.ONLY_REFERENCE_TYPE_FILTER: { - OnlyReferenceTypeFilter onlyReferenceTypeFilter = (OnlyReferenceTypeFilter) theEObject; - T result = caseOnlyReferenceTypeFilter(onlyReferenceTypeFilter); - if (result == null) - result = caseBusinessFilter(onlyReferenceTypeFilter); - if (result == null) - result = caseBindingFilter(onlyReferenceTypeFilter); - if (result == null) - result = caseDocumentedElement(onlyReferenceTypeFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.STRICT_TYPING_FILTER: { - StrictTypingFilter strictTypingFilter = (StrictTypingFilter) theEObject; - T result = caseStrictTypingFilter(strictTypingFilter); - if (result == null) - result = caseBusinessFilter(strictTypingFilter); - if (result == null) - result = caseBindingFilter(strictTypingFilter); - if (result == null) - result = caseDocumentedElement(strictTypingFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.STEP_FILTER: { - StepFilter stepFilter = (StepFilter) theEObject; - T result = caseStepFilter(stepFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.JAVA_STEP_FILTER: { - JavaStepFilter javaStepFilter = (JavaStepFilter) theEObject; - T result = caseJavaStepFilter(javaStepFilter); - if (result == null) - result = caseStepFilter(javaStepFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.JAVA_BODY_STEP_FILTER: { - JavaBodyStepFilter javaBodyStepFilter = (JavaBodyStepFilter) theEObject; - T result = caseJavaBodyStepFilter(javaBodyStepFilter); - if (result == null) - result = caseJavaBodyExpression(javaBodyStepFilter); - if (result == null) - result = caseJavaStepFilter(javaBodyStepFilter); - if (result == null) - result = caseStepFilter(javaBodyStepFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case FiltersPackage.JAVA_DECLARATION_STEP_FILTER: { - JavaDeclarationStepFilter javaDeclarationStepFilter = (JavaDeclarationStepFilter) theEObject; - T result = caseJavaDeclarationStepFilter(javaDeclarationStepFilter); - if (result == null) - result = caseJavaDeclarationExpression(javaDeclarationStepFilter); - if (result == null) - result = caseJavaStepFilter(javaDeclarationStepFilter); - if (result == null) - result = caseStepFilter(javaDeclarationStepFilter); - if (result == null) - result = defaultCase(theEObject); - return result; - } - default: - return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'Binding Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Binding Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseBindingFilter(BindingFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'OCL Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'OCL Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseOCLFilter(OCLFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaFilter(JavaFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Declaration Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Declaration Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaDeclarationFilter(JavaDeclarationFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Expression Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Expression Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaExpressionFilter(JavaExpressionFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Business Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Business Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseBusinessFilter(BusinessFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Only Reference Type Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Only Reference Type Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseOnlyReferenceTypeFilter(OnlyReferenceTypeFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Strict Typing Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Strict Typing Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseStrictTypingFilter(StrictTypingFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Step Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Step Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseStepFilter(StepFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Step Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Step Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaStepFilter(JavaStepFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Body Step Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Body Step Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaBodyStepFilter(JavaBodyStepFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Declaration Step Filter'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Declaration Step Filter'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaDeclarationStepFilter(JavaDeclarationStepFilter object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Documented Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Documented Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDocumentedElement(DocumentedElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Body Expression'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Body Expression'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaBodyExpression(JavaBodyExpression object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Declaration Expression'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Declaration Expression'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaDeclarationExpression(JavaDeclarationExpression object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //FiltersSwitch diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/AbstractElementBindingImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/AbstractElementBindingImpl.java deleted file mode 100644 index 9f0f2dc56..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/AbstractElementBindingImpl.java +++ /dev/null @@ -1,645 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; -import org.eclipse.emf.ecore.util.EObjectResolvingEList; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.ecore.util.InternalEList; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.AbstractPropertyBinding; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.views.View; -import org.eclipse.emf.eef.views.impl.DocumentedElementImpl; - -/** - * - * An implementation of the model object 'Abstract Element Binding'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl#getSubElements Sub Elements}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl#getProperties Properties}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl#getDatabinding Databinding}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl#getSuperElement Super Element}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl#getName Name}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl#getReferencedBinding Referenced Binding}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl#getViews Views}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl#getCategory Category}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractElementBindingImpl#getBindingFilters Binding Filters}
  • - *
- *

- * - * @generated - */ -public abstract class AbstractElementBindingImpl extends DocumentedElementImpl - implements AbstractElementBinding { - /** - * The cached value of the '{@link #getSubElements() Sub Elements}' containment reference list. - * - * - * @see #getSubElements() - * @generated - * @ordered - */ - protected EList subElements; - - /** - * The cached value of the '{@link #getProperties() Properties}' containment reference list. - * - * - * @see #getProperties() - * @generated - * @ordered - */ - protected EList properties; - - /** - * The default value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The cached value of the '{@link #getReferencedBinding() Referenced Binding}' containment reference list. - * - * - * @see #getReferencedBinding() - * @generated - * @ordered - */ - protected EList referencedBinding; - - /** - * The cached value of the '{@link #getViews() Views}' reference list. - * - * - * @see #getViews() - * @generated - * @ordered - */ - protected EList views; - - /** - * The cached value of the '{@link #getBindingFilters() Binding Filters}' containment reference list. - * - * - * @see #getBindingFilters() - * @generated - * @ordered - */ - protected EList bindingFilters; - - /** - * - * - * @generated - */ - protected AbstractElementBindingImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.ABSTRACT_ELEMENT_BINDING; - } - - /** - * - * - * @generated - */ - public EList getSubElements() { - if (subElements == null) { - subElements = new EObjectContainmentWithInverseEList( - AbstractElementBinding.class, this, - MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS, - MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT); - } - return subElements; - } - - /** - * - * - * @generated - */ - public EList getProperties() { - if (properties == null) { - properties = new EObjectContainmentWithInverseEList( - AbstractPropertyBinding.class, this, - MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES, - MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT); - } - return properties; - } - - /** - * - * - * @generated - */ - public Databinding getDatabinding() { - if (eContainerFeatureID() != MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING) - return null; - return (Databinding) eContainer(); - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetDatabinding(Databinding newDatabinding, - NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject) newDatabinding, - MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING, msgs); - return msgs; - } - - /** - * - * - * @generated - */ - public void setDatabinding(Databinding newDatabinding) { - if (newDatabinding != eInternalContainer() - || (eContainerFeatureID() != MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING && newDatabinding != null)) { - if (EcoreUtil.isAncestor(this, newDatabinding)) - throw new IllegalArgumentException( - "Recursive containment not allowed for " + toString()); - NotificationChain msgs = null; - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - if (newDatabinding != null) - msgs = ((InternalEObject) newDatabinding).eInverseAdd(this, - MappingPackage.DATABINDING__BINDINGS, - Databinding.class, msgs); - msgs = basicSetDatabinding(newDatabinding, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING, - newDatabinding, newDatabinding)); - } - - /** - * - * - * @generated - */ - public AbstractElementBinding getSuperElement() { - if (eContainerFeatureID() != MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT) - return null; - return (AbstractElementBinding) eContainer(); - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetSuperElement( - AbstractElementBinding newSuperElement, NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject) newSuperElement, - MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT, msgs); - return msgs; - } - - /** - * - * - * @generated - */ - public void setSuperElement(AbstractElementBinding newSuperElement) { - if (newSuperElement != eInternalContainer() - || (eContainerFeatureID() != MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT && newSuperElement != null)) { - if (EcoreUtil.isAncestor(this, newSuperElement)) - throw new IllegalArgumentException( - "Recursive containment not allowed for " + toString()); - NotificationChain msgs = null; - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - if (newSuperElement != null) - msgs = ((InternalEObject) newSuperElement).eInverseAdd(this, - MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS, - AbstractElementBinding.class, msgs); - msgs = basicSetSuperElement(newSuperElement, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT, - newSuperElement, newSuperElement)); - } - - /** - * - * - * @generated - */ - public String getName() { - return name; - } - - /** - * - * - * @generated - */ - public void setName(String newName) { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.ABSTRACT_ELEMENT_BINDING__NAME, oldName, - name)); - } - - /** - * - * - * @generated - */ - public EList getReferencedBinding() { - if (referencedBinding == null) { - referencedBinding = new EObjectContainmentEList( - ElementBindingReference.class, this, - MappingPackage.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING); - } - return referencedBinding; - } - - /** - * - * - * @generated - */ - public EList getViews() { - if (views == null) { - views = new EObjectResolvingEList(View.class, this, - MappingPackage.ABSTRACT_ELEMENT_BINDING__VIEWS); - } - return views; - } - - /** - * - * - * @generated - */ - public Category getCategory() { - if (eContainerFeatureID() != MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY) - return null; - return (Category) eContainer(); - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetCategory(Category newCategory, - NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject) newCategory, - MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY, msgs); - return msgs; - } - - /** - * - * - * @generated - */ - public void setCategory(Category newCategory) { - if (newCategory != eInternalContainer() - || (eContainerFeatureID() != MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY && newCategory != null)) { - if (EcoreUtil.isAncestor(this, newCategory)) - throw new IllegalArgumentException( - "Recursive containment not allowed for " + toString()); - NotificationChain msgs = null; - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - if (newCategory != null) - msgs = ((InternalEObject) newCategory) - .eInverseAdd(this, MappingPackage.CATEGORY__BINDINGS, - Category.class, msgs); - msgs = basicSetCategory(newCategory, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY, - newCategory, newCategory)); - } - - /** - * - * - * @generated - */ - public EList getBindingFilters() { - if (bindingFilters == null) { - bindingFilters = new EObjectContainmentEList( - BindingFilter.class, this, - MappingPackage.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS); - } - return bindingFilters; - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS: - return ((InternalEList) (InternalEList) getSubElements()) - .basicAdd(otherEnd, msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES: - return ((InternalEList) (InternalEList) getProperties()) - .basicAdd(otherEnd, msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING: - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - return basicSetDatabinding((Databinding) otherEnd, msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT: - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - return basicSetSuperElement((AbstractElementBinding) otherEnd, msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY: - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - return basicSetCategory((Category) otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS: - return ((InternalEList) getSubElements()).basicRemove(otherEnd, - msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES: - return ((InternalEList) getProperties()).basicRemove(otherEnd, - msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING: - return basicSetDatabinding(null, msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT: - return basicSetSuperElement(null, msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING: - return ((InternalEList) getReferencedBinding()).basicRemove( - otherEnd, msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY: - return basicSetCategory(null, msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS: - return ((InternalEList) getBindingFilters()).basicRemove( - otherEnd, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eBasicRemoveFromContainerFeature( - NotificationChain msgs) { - switch (eContainerFeatureID()) { - case MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING: - return eInternalContainer().eInverseRemove(this, - MappingPackage.DATABINDING__BINDINGS, Databinding.class, - msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT: - return eInternalContainer().eInverseRemove(this, - MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS, - AbstractElementBinding.class, msgs); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY: - return eInternalContainer().eInverseRemove(this, - MappingPackage.CATEGORY__BINDINGS, Category.class, msgs); - } - return super.eBasicRemoveFromContainerFeature(msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS: - return getSubElements(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES: - return getProperties(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING: - return getDatabinding(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT: - return getSuperElement(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__NAME: - return getName(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING: - return getReferencedBinding(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__VIEWS: - return getViews(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY: - return getCategory(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS: - return getBindingFilters(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS: - getSubElements().clear(); - getSubElements().addAll( - (Collection) newValue); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES: - getProperties().clear(); - getProperties().addAll( - (Collection) newValue); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING: - setDatabinding((Databinding) newValue); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT: - setSuperElement((AbstractElementBinding) newValue); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__NAME: - setName((String) newValue); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING: - getReferencedBinding().clear(); - getReferencedBinding().addAll( - (Collection) newValue); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__VIEWS: - getViews().clear(); - getViews().addAll((Collection) newValue); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY: - setCategory((Category) newValue); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS: - getBindingFilters().clear(); - getBindingFilters().addAll( - (Collection) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS: - getSubElements().clear(); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES: - getProperties().clear(); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING: - setDatabinding((Databinding) null); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT: - setSuperElement((AbstractElementBinding) null); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__NAME: - setName(NAME_EDEFAULT); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING: - getReferencedBinding().clear(); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__VIEWS: - getViews().clear(); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY: - setCategory((Category) null); - return; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS: - getBindingFilters().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS: - return subElements != null && !subElements.isEmpty(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES: - return properties != null && !properties.isEmpty(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING: - return getDatabinding() != null; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT: - return getSuperElement() != null; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT - .equals(name); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING: - return referencedBinding != null && !referencedBinding.isEmpty(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__VIEWS: - return views != null && !views.isEmpty(); - case MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY: - return getCategory() != null; - case MappingPackage.ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS: - return bindingFilters != null && !bindingFilters.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(')'); - return result.toString(); - } - -} //AbstractElementBindingImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/AbstractPropertyBindingImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/AbstractPropertyBindingImpl.java deleted file mode 100644 index 8fd5d935e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/AbstractPropertyBindingImpl.java +++ /dev/null @@ -1,372 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.EObjectResolvingEList; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.ecore.util.InternalEList; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.AbstractPropertyBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.filters.BindingFilter; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.impl.DocumentedElementImpl; - -/** - * - * An implementation of the model object 'Abstract Property Binding'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractPropertyBindingImpl#getName Name}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractPropertyBindingImpl#getViews Views}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractPropertyBindingImpl#getElement Element}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.AbstractPropertyBindingImpl#getBindingFilters Binding Filters}
  • - *
- *

- * - * @generated - */ -public abstract class AbstractPropertyBindingImpl extends DocumentedElementImpl - implements AbstractPropertyBinding { - /** - * The default value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The cached value of the '{@link #getViews() Views}' reference list. - * - * - * @see #getViews() - * @generated - * @ordered - */ - protected EList views; - - /** - * The cached value of the '{@link #getBindingFilters() Binding Filters}' containment reference list. - * - * - * @see #getBindingFilters() - * @generated - * @ordered - */ - protected EList bindingFilters; - - /** - * - * - * @generated - */ - protected AbstractPropertyBindingImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.ABSTRACT_PROPERTY_BINDING; - } - - /** - * - * - * @generated - */ - public String getName() { - return name; - } - - /** - * - * - * @generated - */ - public void setName(String newName) { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.ABSTRACT_PROPERTY_BINDING__NAME, oldName, - name)); - } - - /** - * - * - * @generated - */ - public EList getViews() { - if (views == null) { - views = new EObjectResolvingEList( - ElementEditor.class, this, - MappingPackage.ABSTRACT_PROPERTY_BINDING__VIEWS); - } - return views; - } - - /** - * - * - * @generated - */ - public AbstractElementBinding getElement() { - if (eContainerFeatureID() != MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT) - return null; - return (AbstractElementBinding) eContainer(); - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetElement(AbstractElementBinding newElement, - NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject) newElement, - MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT, msgs); - return msgs; - } - - /** - * - * - * @generated - */ - public void setElement(AbstractElementBinding newElement) { - if (newElement != eInternalContainer() - || (eContainerFeatureID() != MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT && newElement != null)) { - if (EcoreUtil.isAncestor(this, newElement)) - throw new IllegalArgumentException( - "Recursive containment not allowed for " + toString()); - NotificationChain msgs = null; - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - if (newElement != null) - msgs = ((InternalEObject) newElement).eInverseAdd(this, - MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES, - AbstractElementBinding.class, msgs); - msgs = basicSetElement(newElement, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT, - newElement, newElement)); - } - - /** - * - * - * @generated - */ - public EList getBindingFilters() { - if (bindingFilters == null) { - bindingFilters = new EObjectContainmentEList( - BindingFilter.class, this, - MappingPackage.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS); - } - return bindingFilters; - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT: - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - return basicSetElement((AbstractElementBinding) otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT: - return basicSetElement(null, msgs); - case MappingPackage.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS: - return ((InternalEList) getBindingFilters()).basicRemove( - otherEnd, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eBasicRemoveFromContainerFeature( - NotificationChain msgs) { - switch (eContainerFeatureID()) { - case MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT: - return eInternalContainer().eInverseRemove(this, - MappingPackage.ABSTRACT_ELEMENT_BINDING__PROPERTIES, - AbstractElementBinding.class, msgs); - } - return super.eBasicRemoveFromContainerFeature(msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.ABSTRACT_PROPERTY_BINDING__NAME: - return getName(); - case MappingPackage.ABSTRACT_PROPERTY_BINDING__VIEWS: - return getViews(); - case MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT: - return getElement(); - case MappingPackage.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS: - return getBindingFilters(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.ABSTRACT_PROPERTY_BINDING__NAME: - setName((String) newValue); - return; - case MappingPackage.ABSTRACT_PROPERTY_BINDING__VIEWS: - getViews().clear(); - getViews().addAll((Collection) newValue); - return; - case MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT: - setElement((AbstractElementBinding) newValue); - return; - case MappingPackage.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS: - getBindingFilters().clear(); - getBindingFilters().addAll( - (Collection) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.ABSTRACT_PROPERTY_BINDING__NAME: - setName(NAME_EDEFAULT); - return; - case MappingPackage.ABSTRACT_PROPERTY_BINDING__VIEWS: - getViews().clear(); - return; - case MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT: - setElement((AbstractElementBinding) null); - return; - case MappingPackage.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS: - getBindingFilters().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.ABSTRACT_PROPERTY_BINDING__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT - .equals(name); - case MappingPackage.ABSTRACT_PROPERTY_BINDING__VIEWS: - return views != null && !views.isEmpty(); - case MappingPackage.ABSTRACT_PROPERTY_BINDING__ELEMENT: - return getElement() != null; - case MappingPackage.ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS: - return bindingFilters != null && !bindingFilters.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(')'); - return result.toString(); - } - -} //AbstractPropertyBindingImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/CategoryImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/CategoryImpl.java deleted file mode 100644 index 2ae1fd45c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/CategoryImpl.java +++ /dev/null @@ -1,376 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.ecore.util.InternalEList; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.views.impl.DocumentedElementImpl; - -/** - * - * An implementation of the model object 'Category'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.CategoryImpl#getName Name}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.CategoryImpl#getBindings Bindings}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.CategoryImpl#getDatabinding Databinding}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.CategoryImpl#getCategories Categories}
  • - *
- *

- * - * @generated - */ -public class CategoryImpl extends DocumentedElementImpl implements Category { - /** - * The default value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The cached value of the '{@link #getBindings() Bindings}' containment reference list. - * - * - * @see #getBindings() - * @generated - * @ordered - */ - protected EList bindings; - - /** - * The cached value of the '{@link #getCategories() Categories}' containment reference list. - * - * - * @see #getCategories() - * @generated - * @ordered - */ - protected EList categories; - - /** - * - * - * @generated - */ - protected CategoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.CATEGORY; - } - - /** - * - * - * @generated - */ - public String getName() { - return name; - } - - /** - * - * - * @generated - */ - public void setName(String newName) { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.CATEGORY__NAME, oldName, name)); - } - - /** - * - * - * @generated - */ - public EList getBindings() { - if (bindings == null) { - bindings = new EObjectContainmentWithInverseEList( - AbstractElementBinding.class, this, - MappingPackage.CATEGORY__BINDINGS, - MappingPackage.ABSTRACT_ELEMENT_BINDING__CATEGORY); - } - return bindings; - } - - /** - * - * - * @generated - */ - public Databinding getDatabinding() { - if (eContainerFeatureID() != MappingPackage.CATEGORY__DATABINDING) - return null; - return (Databinding) eContainer(); - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetDatabinding(Databinding newDatabinding, - NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject) newDatabinding, - MappingPackage.CATEGORY__DATABINDING, msgs); - return msgs; - } - - /** - * - * - * @generated - */ - public void setDatabinding(Databinding newDatabinding) { - if (newDatabinding != eInternalContainer() - || (eContainerFeatureID() != MappingPackage.CATEGORY__DATABINDING && newDatabinding != null)) { - if (EcoreUtil.isAncestor(this, newDatabinding)) - throw new IllegalArgumentException( - "Recursive containment not allowed for " + toString()); - NotificationChain msgs = null; - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - if (newDatabinding != null) - msgs = ((InternalEObject) newDatabinding).eInverseAdd(this, - MappingPackage.DATABINDING__CATEGORIES, - Databinding.class, msgs); - msgs = basicSetDatabinding(newDatabinding, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.CATEGORY__DATABINDING, newDatabinding, - newDatabinding)); - } - - /** - * - * - * @generated - */ - public EList getCategories() { - if (categories == null) { - categories = new EObjectContainmentEList(Category.class, - this, MappingPackage.CATEGORY__CATEGORIES); - } - return categories; - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.CATEGORY__BINDINGS: - return ((InternalEList) (InternalEList) getBindings()) - .basicAdd(otherEnd, msgs); - case MappingPackage.CATEGORY__DATABINDING: - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - return basicSetDatabinding((Databinding) otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.CATEGORY__BINDINGS: - return ((InternalEList) getBindings()).basicRemove(otherEnd, - msgs); - case MappingPackage.CATEGORY__DATABINDING: - return basicSetDatabinding(null, msgs); - case MappingPackage.CATEGORY__CATEGORIES: - return ((InternalEList) getCategories()).basicRemove(otherEnd, - msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eBasicRemoveFromContainerFeature( - NotificationChain msgs) { - switch (eContainerFeatureID()) { - case MappingPackage.CATEGORY__DATABINDING: - return eInternalContainer().eInverseRemove(this, - MappingPackage.DATABINDING__CATEGORIES, Databinding.class, - msgs); - } - return super.eBasicRemoveFromContainerFeature(msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.CATEGORY__NAME: - return getName(); - case MappingPackage.CATEGORY__BINDINGS: - return getBindings(); - case MappingPackage.CATEGORY__DATABINDING: - return getDatabinding(); - case MappingPackage.CATEGORY__CATEGORIES: - return getCategories(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.CATEGORY__NAME: - setName((String) newValue); - return; - case MappingPackage.CATEGORY__BINDINGS: - getBindings().clear(); - getBindings().addAll( - (Collection) newValue); - return; - case MappingPackage.CATEGORY__DATABINDING: - setDatabinding((Databinding) newValue); - return; - case MappingPackage.CATEGORY__CATEGORIES: - getCategories().clear(); - getCategories().addAll((Collection) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.CATEGORY__NAME: - setName(NAME_EDEFAULT); - return; - case MappingPackage.CATEGORY__BINDINGS: - getBindings().clear(); - return; - case MappingPackage.CATEGORY__DATABINDING: - setDatabinding((Databinding) null); - return; - case MappingPackage.CATEGORY__CATEGORIES: - getCategories().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.CATEGORY__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT - .equals(name); - case MappingPackage.CATEGORY__BINDINGS: - return bindings != null && !bindings.isEmpty(); - case MappingPackage.CATEGORY__DATABINDING: - return getDatabinding() != null; - case MappingPackage.CATEGORY__CATEGORIES: - return categories != null && !categories.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(')'); - return result.toString(); - } - -} //CategoryImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/DatabindingImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/DatabindingImpl.java deleted file mode 100644 index 3a5229f2b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/DatabindingImpl.java +++ /dev/null @@ -1,223 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; -import org.eclipse.emf.ecore.util.InternalEList; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.views.impl.DocumentedElementImpl; - -/** - * - * An implementation of the model object 'Databinding'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.DatabindingImpl#getBindings Bindings}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.DatabindingImpl#getCategories Categories}
  • - *
- *

- * - * @generated - */ -public class DatabindingImpl extends DocumentedElementImpl implements - Databinding { - /** - * The cached value of the '{@link #getBindings() Bindings}' containment reference list. - * - * - * @see #getBindings() - * @generated - * @ordered - */ - protected EList bindings; - - /** - * The cached value of the '{@link #getCategories() Categories}' containment reference list. - * - * - * @see #getCategories() - * @generated - * @ordered - */ - protected EList categories; - - /** - * - * - * @generated - */ - protected DatabindingImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.DATABINDING; - } - - /** - * - * - * @generated - */ - public EList getBindings() { - if (bindings == null) { - bindings = new EObjectContainmentWithInverseEList( - AbstractElementBinding.class, this, - MappingPackage.DATABINDING__BINDINGS, - MappingPackage.ABSTRACT_ELEMENT_BINDING__DATABINDING); - } - return bindings; - } - - /** - * - * - * @generated - */ - public EList getCategories() { - if (categories == null) { - categories = new EObjectContainmentWithInverseEList( - Category.class, this, - MappingPackage.DATABINDING__CATEGORIES, - MappingPackage.CATEGORY__DATABINDING); - } - return categories; - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.DATABINDING__BINDINGS: - return ((InternalEList) (InternalEList) getBindings()) - .basicAdd(otherEnd, msgs); - case MappingPackage.DATABINDING__CATEGORIES: - return ((InternalEList) (InternalEList) getCategories()) - .basicAdd(otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.DATABINDING__BINDINGS: - return ((InternalEList) getBindings()).basicRemove(otherEnd, - msgs); - case MappingPackage.DATABINDING__CATEGORIES: - return ((InternalEList) getCategories()).basicRemove(otherEnd, - msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.DATABINDING__BINDINGS: - return getBindings(); - case MappingPackage.DATABINDING__CATEGORIES: - return getCategories(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.DATABINDING__BINDINGS: - getBindings().clear(); - getBindings().addAll( - (Collection) newValue); - return; - case MappingPackage.DATABINDING__CATEGORIES: - getCategories().clear(); - getCategories().addAll((Collection) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.DATABINDING__BINDINGS: - getBindings().clear(); - return; - case MappingPackage.DATABINDING__CATEGORIES: - getCategories().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.DATABINDING__BINDINGS: - return bindings != null && !bindings.isEmpty(); - case MappingPackage.DATABINDING__CATEGORIES: - return categories != null && !categories.isEmpty(); - } - return super.eIsSet(featureID); - } - -} //DatabindingImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/DocumentedElementImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/DocumentedElementImpl.java deleted file mode 100644 index 23a3e1d75..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/DocumentedElementImpl.java +++ /dev/null @@ -1,173 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * - * An implementation of the model object 'Documented Element'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.DocumentedElementImpl#getDocumentation Documentation}
  • - *
- *

- * - * @generated - */ -public abstract class DocumentedElementImpl extends EObjectImpl implements - DocumentedElement { - /** - * The default value of the '{@link #getDocumentation() Documentation}' attribute. - * - * - * @see #getDocumentation() - * @generated - * @ordered - */ - protected static final String DOCUMENTATION_EDEFAULT = null; - - /** - * The cached value of the '{@link #getDocumentation() Documentation}' attribute. - * - * - * @see #getDocumentation() - * @generated - * @ordered - */ - protected String documentation = DOCUMENTATION_EDEFAULT; - - /** - * - * - * @generated - */ - protected DocumentedElementImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.DOCUMENTED_ELEMENT; - } - - /** - * - * - * @generated - */ - public String getDocumentation() { - return documentation; - } - - /** - * - * - * @generated - */ - public void setDocumentation(String newDocumentation) { - String oldDocumentation = documentation; - documentation = newDocumentation; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.DOCUMENTED_ELEMENT__DOCUMENTATION, - oldDocumentation, documentation)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.DOCUMENTED_ELEMENT__DOCUMENTATION: - return getDocumentation(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.DOCUMENTED_ELEMENT__DOCUMENTATION: - setDocumentation((String) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.DOCUMENTED_ELEMENT__DOCUMENTATION: - setDocumentation(DOCUMENTATION_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.DOCUMENTED_ELEMENT__DOCUMENTATION: - return DOCUMENTATION_EDEFAULT == null ? documentation != null - : !DOCUMENTATION_EDEFAULT.equals(documentation); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (documentation: "); - result.append(documentation); - result.append(')'); - return result.toString(); - } - -} //DocumentedElementImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFElementBindingImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFElementBindingImpl.java deleted file mode 100644 index 24b755f08..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFElementBindingImpl.java +++ /dev/null @@ -1,166 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; - -/** - * - * An implementation of the model object 'EMF Element Binding'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.EMFElementBindingImpl#getModel Model}
  • - *
- *

- * - * @generated - */ -public class EMFElementBindingImpl extends AbstractElementBindingImpl implements - EMFElementBinding { - /** - * The cached value of the '{@link #getModel() Model}' reference. - * - * - * @see #getModel() - * @generated - * @ordered - */ - protected EClassifier model; - - /** - * - * - * @generated - */ - protected EMFElementBindingImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.EMF_ELEMENT_BINDING; - } - - /** - * - * - * @generated - */ - public EClassifier getModel() { - if (model != null && model.eIsProxy()) { - InternalEObject oldModel = (InternalEObject) model; - model = (EClassifier) eResolveProxy(oldModel); - if (model != oldModel) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - MappingPackage.EMF_ELEMENT_BINDING__MODEL, - oldModel, model)); - } - } - return model; - } - - /** - * - * - * @generated - */ - public EClassifier basicGetModel() { - return model; - } - - /** - * - * - * @generated - */ - public void setModel(EClassifier newModel) { - EClassifier oldModel = model; - model = newModel; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.EMF_ELEMENT_BINDING__MODEL, oldModel, model)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.EMF_ELEMENT_BINDING__MODEL: - if (resolve) - return getModel(); - return basicGetModel(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.EMF_ELEMENT_BINDING__MODEL: - setModel((EClassifier) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.EMF_ELEMENT_BINDING__MODEL: - setModel((EClassifier) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.EMF_ELEMENT_BINDING__MODEL: - return model != null; - } - return super.eIsSet(featureID); - } - -} //EMFElementBindingImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFMultiPropertiesBindingImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFMultiPropertiesBindingImpl.java deleted file mode 100644 index 5309f3c81..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFMultiPropertiesBindingImpl.java +++ /dev/null @@ -1,244 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.util.EObjectResolvingEList; -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; - -/** - * - * An implementation of the model object 'EMF Multi Properties Binding'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.EMFMultiPropertiesBindingImpl#getModel Model}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.EMFMultiPropertiesBindingImpl#getNavigation Navigation}
  • - *
- *

- * - * @generated - */ -public class EMFMultiPropertiesBindingImpl extends AbstractPropertyBindingImpl - implements EMFMultiPropertiesBinding { - /** - * The cached value of the '{@link #getModel() Model}' reference list. - * - * - * @see #getModel() - * @generated - * @ordered - */ - protected EList model; - - /** - * The cached value of the '{@link #getNavigation() Navigation}' containment reference. - * - * - * @see #getNavigation() - * @generated - * @ordered - */ - protected ModelNavigation navigation; - - /** - * - * - * @generated - */ - protected EMFMultiPropertiesBindingImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.EMF_MULTI_PROPERTIES_BINDING; - } - - /** - * - * - * @generated - */ - public EList getModel() { - if (model == null) { - model = new EObjectResolvingEList( - EStructuralFeature.class, this, - MappingPackage.EMF_MULTI_PROPERTIES_BINDING__MODEL); - } - return model; - } - - /** - * - * - * @generated - */ - public ModelNavigation getNavigation() { - return navigation; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetNavigation(ModelNavigation newNavigation, - NotificationChain msgs) { - ModelNavigation oldNavigation = navigation; - navigation = newNavigation; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION, - oldNavigation, newNavigation); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setNavigation(ModelNavigation newNavigation) { - if (newNavigation != navigation) { - NotificationChain msgs = null; - if (navigation != null) - msgs = ((InternalEObject) navigation) - .eInverseRemove( - this, - EOPPOSITE_FEATURE_BASE - - MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION, - null, msgs); - if (newNavigation != null) - msgs = ((InternalEObject) newNavigation) - .eInverseAdd( - this, - EOPPOSITE_FEATURE_BASE - - MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION, - null, msgs); - msgs = basicSetNavigation(newNavigation, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION, - newNavigation, newNavigation)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION: - return basicSetNavigation(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING__MODEL: - return getModel(); - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION: - return getNavigation(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING__MODEL: - getModel().clear(); - getModel().addAll( - (Collection) newValue); - return; - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION: - setNavigation((ModelNavigation) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING__MODEL: - getModel().clear(); - return; - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION: - setNavigation((ModelNavigation) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING__MODEL: - return model != null && !model.isEmpty(); - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING__NAVIGATION: - return navigation != null; - } - return super.eIsSet(featureID); - } - -} //EMFMultiPropertiesBindingImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFPropertyBindingImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFPropertyBindingImpl.java deleted file mode 100644 index c1a780ecf..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/EMFPropertyBindingImpl.java +++ /dev/null @@ -1,352 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; -import org.eclipse.emf.eef.mapping.settings.EditorSettings; - -/** - * - * An implementation of the model object 'EMF Property Binding'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.EMFPropertyBindingImpl#getModel Model}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.EMFPropertyBindingImpl#getNavigation Navigation}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.EMFPropertyBindingImpl#getEditorSetting Editor Setting}
  • - *
- *

- * - * @generated - */ -public class EMFPropertyBindingImpl extends AbstractPropertyBindingImpl - implements EMFPropertyBinding { - /** - * The cached value of the '{@link #getModel() Model}' reference. - * - * - * @see #getModel() - * @generated - * @ordered - */ - protected EStructuralFeature model; - - /** - * The cached value of the '{@link #getNavigation() Navigation}' containment reference. - * - * - * @see #getNavigation() - * @generated - * @ordered - */ - protected ModelNavigation navigation; - - /** - * The cached value of the '{@link #getEditorSetting() Editor Setting}' containment reference. - * - * - * @see #getEditorSetting() - * @generated - * @ordered - */ - protected EditorSettings editorSetting; - - /** - * - * - * @generated - */ - protected EMFPropertyBindingImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.EMF_PROPERTY_BINDING; - } - - /** - * - * - * @generated - */ - public EStructuralFeature getModel() { - if (model != null && model.eIsProxy()) { - InternalEObject oldModel = (InternalEObject) model; - model = (EStructuralFeature) eResolveProxy(oldModel); - if (model != oldModel) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - MappingPackage.EMF_PROPERTY_BINDING__MODEL, - oldModel, model)); - } - } - return model; - } - - /** - * - * - * @generated - */ - public EStructuralFeature basicGetModel() { - return model; - } - - /** - * - * - * @generated - */ - public void setModel(EStructuralFeature newModel) { - EStructuralFeature oldModel = model; - model = newModel; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.EMF_PROPERTY_BINDING__MODEL, oldModel, model)); - } - - /** - * - * - * @generated - */ - public ModelNavigation getNavigation() { - return navigation; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetNavigation(ModelNavigation newNavigation, - NotificationChain msgs) { - ModelNavigation oldNavigation = navigation; - navigation = newNavigation; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION, - oldNavigation, newNavigation); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setNavigation(ModelNavigation newNavigation) { - if (newNavigation != navigation) { - NotificationChain msgs = null; - if (navigation != null) - msgs = ((InternalEObject) navigation) - .eInverseRemove( - this, - EOPPOSITE_FEATURE_BASE - - MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION, - null, msgs); - if (newNavigation != null) - msgs = ((InternalEObject) newNavigation) - .eInverseAdd( - this, - EOPPOSITE_FEATURE_BASE - - MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION, - null, msgs); - msgs = basicSetNavigation(newNavigation, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION, - newNavigation, newNavigation)); - } - - /** - * - * - * @generated - */ - public EditorSettings getEditorSetting() { - return editorSetting; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetEditorSetting( - EditorSettings newEditorSetting, NotificationChain msgs) { - EditorSettings oldEditorSetting = editorSetting; - editorSetting = newEditorSetting; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - MappingPackage.EMF_PROPERTY_BINDING__EDITOR_SETTING, - oldEditorSetting, newEditorSetting); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setEditorSetting(EditorSettings newEditorSetting) { - if (newEditorSetting != editorSetting) { - NotificationChain msgs = null; - if (editorSetting != null) - msgs = ((InternalEObject) editorSetting) - .eInverseRemove( - this, - EOPPOSITE_FEATURE_BASE - - MappingPackage.EMF_PROPERTY_BINDING__EDITOR_SETTING, - null, msgs); - if (newEditorSetting != null) - msgs = ((InternalEObject) newEditorSetting) - .eInverseAdd( - this, - EOPPOSITE_FEATURE_BASE - - MappingPackage.EMF_PROPERTY_BINDING__EDITOR_SETTING, - null, msgs); - msgs = basicSetEditorSetting(newEditorSetting, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.EMF_PROPERTY_BINDING__EDITOR_SETTING, - newEditorSetting, newEditorSetting)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION: - return basicSetNavigation(null, msgs); - case MappingPackage.EMF_PROPERTY_BINDING__EDITOR_SETTING: - return basicSetEditorSetting(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.EMF_PROPERTY_BINDING__MODEL: - if (resolve) - return getModel(); - return basicGetModel(); - case MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION: - return getNavigation(); - case MappingPackage.EMF_PROPERTY_BINDING__EDITOR_SETTING: - return getEditorSetting(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.EMF_PROPERTY_BINDING__MODEL: - setModel((EStructuralFeature) newValue); - return; - case MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION: - setNavigation((ModelNavigation) newValue); - return; - case MappingPackage.EMF_PROPERTY_BINDING__EDITOR_SETTING: - setEditorSetting((EditorSettings) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.EMF_PROPERTY_BINDING__MODEL: - setModel((EStructuralFeature) null); - return; - case MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION: - setNavigation((ModelNavigation) null); - return; - case MappingPackage.EMF_PROPERTY_BINDING__EDITOR_SETTING: - setEditorSetting((EditorSettings) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.EMF_PROPERTY_BINDING__MODEL: - return model != null; - case MappingPackage.EMF_PROPERTY_BINDING__NAVIGATION: - return navigation != null; - case MappingPackage.EMF_PROPERTY_BINDING__EDITOR_SETTING: - return editorSetting != null; - } - return super.eIsSet(featureID); - } - -} //EMFPropertyBindingImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ElementBindingReferenceImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ElementBindingReferenceImpl.java deleted file mode 100644 index a32259fb4..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ElementBindingReferenceImpl.java +++ /dev/null @@ -1,168 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.views.impl.DocumentedElementImpl; - -/** - * - * An implementation of the model object 'Element Binding Reference'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.ElementBindingReferenceImpl#getBinding Binding}
  • - *
- *

- * - * @generated - */ -public class ElementBindingReferenceImpl extends DocumentedElementImpl - implements ElementBindingReference { - /** - * The cached value of the '{@link #getBinding() Binding}' reference. - * - * - * @see #getBinding() - * @generated - * @ordered - */ - protected AbstractElementBinding binding; - - /** - * - * - * @generated - */ - protected ElementBindingReferenceImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.ELEMENT_BINDING_REFERENCE; - } - - /** - * - * - * @generated - */ - public AbstractElementBinding getBinding() { - if (binding != null && binding.eIsProxy()) { - InternalEObject oldBinding = (InternalEObject) binding; - binding = (AbstractElementBinding) eResolveProxy(oldBinding); - if (binding != oldBinding) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - MappingPackage.ELEMENT_BINDING_REFERENCE__BINDING, - oldBinding, binding)); - } - } - return binding; - } - - /** - * - * - * @generated - */ - public AbstractElementBinding basicGetBinding() { - return binding; - } - - /** - * - * - * @generated - */ - public void setBinding(AbstractElementBinding newBinding) { - AbstractElementBinding oldBinding = binding; - binding = newBinding; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.ELEMENT_BINDING_REFERENCE__BINDING, - oldBinding, binding)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.ELEMENT_BINDING_REFERENCE__BINDING: - if (resolve) - return getBinding(); - return basicGetBinding(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.ELEMENT_BINDING_REFERENCE__BINDING: - setBinding((AbstractElementBinding) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.ELEMENT_BINDING_REFERENCE__BINDING: - setBinding((AbstractElementBinding) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.ELEMENT_BINDING_REFERENCE__BINDING: - return binding != null; - } - return super.eIsSet(featureID); - } - -} //ElementBindingReferenceImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/MappingFactoryImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/MappingFactoryImpl.java deleted file mode 100644 index 23368a472..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/MappingFactoryImpl.java +++ /dev/null @@ -1,196 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.impl.EFactoryImpl; -import org.eclipse.emf.ecore.plugin.EcorePlugin; -import org.eclipse.emf.eef.mapping.*; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.MappingFactory; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.StandardElementBinding; -import org.eclipse.emf.eef.mapping.StandardPropertyBinding; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class MappingFactoryImpl extends EFactoryImpl implements MappingFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static MappingFactory init() { - try { - MappingFactory theMappingFactory = (MappingFactory) EPackage.Registry.INSTANCE - .getEFactory("http://www.eclipse.org/emf/eef/mapping/1.0.0"); - if (theMappingFactory != null) { - return theMappingFactory; - } - } catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new MappingFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public MappingFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case MappingPackage.DATABINDING: - return createDatabinding(); - case MappingPackage.EMF_ELEMENT_BINDING: - return createEMFElementBinding(); - case MappingPackage.EMF_PROPERTY_BINDING: - return createEMFPropertyBinding(); - case MappingPackage.STANDARD_ELEMENT_BINDING: - return createStandardElementBinding(); - case MappingPackage.STANDARD_PROPERTY_BINDING: - return createStandardPropertyBinding(); - case MappingPackage.CATEGORY: - return createCategory(); - case MappingPackage.ELEMENT_BINDING_REFERENCE: - return createElementBindingReference(); - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING: - return createEMFMultiPropertiesBinding(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() - + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public Databinding createDatabinding() { - DatabindingImpl databinding = new DatabindingImpl(); - return databinding; - } - - /** - * - * - * @generated - */ - public EMFElementBinding createEMFElementBinding() { - EMFElementBindingImpl emfElementBinding = new EMFElementBindingImpl(); - return emfElementBinding; - } - - /** - * - * - * @generated - */ - public EMFPropertyBinding createEMFPropertyBinding() { - EMFPropertyBindingImpl emfPropertyBinding = new EMFPropertyBindingImpl(); - return emfPropertyBinding; - } - - /** - * - * - * @generated - */ - public StandardElementBinding createStandardElementBinding() { - StandardElementBindingImpl standardElementBinding = new StandardElementBindingImpl(); - return standardElementBinding; - } - - /** - * - * - * @generated - */ - public StandardPropertyBinding createStandardPropertyBinding() { - StandardPropertyBindingImpl standardPropertyBinding = new StandardPropertyBindingImpl(); - return standardPropertyBinding; - } - - /** - * - * - * @generated - */ - public Category createCategory() { - CategoryImpl category = new CategoryImpl(); - return category; - } - - /** - * - * - * @generated - */ - public ElementBindingReference createElementBindingReference() { - ElementBindingReferenceImpl elementBindingReference = new ElementBindingReferenceImpl(); - return elementBindingReference; - } - - /** - * - * - * @generated - */ - public EMFMultiPropertiesBinding createEMFMultiPropertiesBinding() { - EMFMultiPropertiesBindingImpl emfMultiPropertiesBinding = new EMFMultiPropertiesBindingImpl(); - return emfMultiPropertiesBinding; - } - - /** - * - * - * @generated - */ - public MappingPackage getMappingPackage() { - return (MappingPackage) getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static MappingPackage getPackage() { - return MappingPackage.eINSTANCE; - } - -} //MappingFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/MappingPackageImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/MappingPackageImpl.java deleted file mode 100644 index 57266310c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/MappingPackageImpl.java +++ /dev/null @@ -1,1100 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.impl.EPackageImpl; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.AbstractPropertyBinding; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.MappingFactory; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelElement; -import org.eclipse.emf.eef.mapping.ModelProperty; -import org.eclipse.emf.eef.mapping.StandardElementBinding; -import org.eclipse.emf.eef.mapping.StandardPropertyBinding; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl; -import org.eclipse.emf.eef.mapping.settings.SettingsPackage; -import org.eclipse.emf.eef.mapping.settings.impl.SettingsPackageImpl; -import org.eclipse.emf.eef.views.ViewsPackage; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class MappingPackageImpl extends EPackageImpl implements MappingPackage { - /** - * - * - * @generated - */ - private EClass databindingEClass = null; - - /** - * - * - * @generated - */ - private EClass modelElementEClass = null; - - /** - * - * - * @generated - */ - private EClass abstractElementBindingEClass = null; - - /** - * - * - * @generated - */ - private EClass modelPropertyEClass = null; - - /** - * - * - * @generated - */ - private EClass abstractPropertyBindingEClass = null; - - /** - * - * - * @generated - */ - private EClass emfElementBindingEClass = null; - - /** - * - * - * @generated - */ - private EClass emfPropertyBindingEClass = null; - - /** - * - * - * @generated - */ - private EClass standardElementBindingEClass = null; - - /** - * - * - * @generated - */ - private EClass standardPropertyBindingEClass = null; - - /** - * - * - * @generated - */ - private EClass categoryEClass = null; - - /** - * - * - * @generated - */ - private EClass elementBindingReferenceEClass = null; - - /** - * - * - * @generated - */ - private EClass documentedElementEClass = null; - - /** - * - * - * @generated - */ - private EClass emfMultiPropertiesBindingEClass = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.mapping.MappingPackage#eNS_URI - * @see #init() - * @generated - */ - private MappingPackageImpl() { - super(eNS_URI, MappingFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link MappingPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static MappingPackage init() { - if (isInited) - return (MappingPackage) EPackage.Registry.INSTANCE - .getEPackage(MappingPackage.eNS_URI); - - // Obtain or create and register package - MappingPackageImpl theMappingPackage = (MappingPackageImpl) (EPackage.Registry.INSTANCE - .get(eNS_URI) instanceof MappingPackageImpl ? EPackage.Registry.INSTANCE - .get(eNS_URI) : new MappingPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - EcorePackage.eINSTANCE.eClass(); - ViewsPackage.eINSTANCE.eClass(); - - // Obtain or create and register interdependencies - NavigationPackageImpl theNavigationPackage = (NavigationPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(NavigationPackage.eNS_URI) instanceof NavigationPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(NavigationPackage.eNS_URI) - : NavigationPackage.eINSTANCE); - FiltersPackageImpl theFiltersPackage = (FiltersPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(FiltersPackage.eNS_URI) instanceof FiltersPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(FiltersPackage.eNS_URI) : FiltersPackage.eINSTANCE); - SettingsPackageImpl theSettingsPackage = (SettingsPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(SettingsPackage.eNS_URI) instanceof SettingsPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(SettingsPackage.eNS_URI) - : SettingsPackage.eINSTANCE); - - // Create package meta-data objects - theMappingPackage.createPackageContents(); - theNavigationPackage.createPackageContents(); - theFiltersPackage.createPackageContents(); - theSettingsPackage.createPackageContents(); - - // Initialize created meta-data - theMappingPackage.initializePackageContents(); - theNavigationPackage.initializePackageContents(); - theFiltersPackage.initializePackageContents(); - theSettingsPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theMappingPackage.freeze(); - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(MappingPackage.eNS_URI, - theMappingPackage); - return theMappingPackage; - } - - /** - * - * - * @generated - */ - public EClass getDatabinding() { - return databindingEClass; - } - - /** - * - * - * @generated - */ - public EReference getDatabinding_Bindings() { - return (EReference) databindingEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getDatabinding_Categories() { - return (EReference) databindingEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getModelElement() { - return modelElementEClass; - } - - /** - * - * - * @generated - */ - public EReference getModelElement_Properties() { - return (EReference) modelElementEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getModelElement_SubElements() { - return (EReference) modelElementEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EReference getModelElement_Binding() { - return (EReference) modelElementEClass.getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EReference getModelElement_SuperElement() { - return (EReference) modelElementEClass.getEStructuralFeatures().get(3); - } - - /** - * - * - * @generated - */ - public EClass getAbstractElementBinding() { - return abstractElementBindingEClass; - } - - /** - * - * - * @generated - */ - public EReference getAbstractElementBinding_SubElements() { - return (EReference) abstractElementBindingEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getAbstractElementBinding_Properties() { - return (EReference) abstractElementBindingEClass - .getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EReference getAbstractElementBinding_Databinding() { - return (EReference) abstractElementBindingEClass - .getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EReference getAbstractElementBinding_SuperElement() { - return (EReference) abstractElementBindingEClass - .getEStructuralFeatures().get(3); - } - - /** - * - * - * @generated - */ - public EAttribute getAbstractElementBinding_Name() { - return (EAttribute) abstractElementBindingEClass - .getEStructuralFeatures().get(4); - } - - /** - * - * - * @generated - */ - public EReference getAbstractElementBinding_ReferencedBinding() { - return (EReference) abstractElementBindingEClass - .getEStructuralFeatures().get(5); - } - - /** - * - * - * @generated - */ - public EReference getAbstractElementBinding_Views() { - return (EReference) abstractElementBindingEClass - .getEStructuralFeatures().get(6); - } - - /** - * - * - * @generated - */ - public EReference getAbstractElementBinding_Category() { - return (EReference) abstractElementBindingEClass - .getEStructuralFeatures().get(7); - } - - /** - * - * - * @generated - */ - public EReference getAbstractElementBinding_BindingFilters() { - return (EReference) abstractElementBindingEClass - .getEStructuralFeatures().get(8); - } - - /** - * - * - * @generated - */ - public EClass getModelProperty() { - return modelPropertyEClass; - } - - /** - * - * - * @generated - */ - public EReference getModelProperty_Binding() { - return (EReference) modelPropertyEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getModelProperty_ModelElement() { - return (EReference) modelPropertyEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getAbstractPropertyBinding() { - return abstractPropertyBindingEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getAbstractPropertyBinding_Name() { - return (EAttribute) abstractPropertyBindingEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getAbstractPropertyBinding_Views() { - return (EReference) abstractPropertyBindingEClass - .getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EReference getAbstractPropertyBinding_Element() { - return (EReference) abstractPropertyBindingEClass - .getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EReference getAbstractPropertyBinding_BindingFilters() { - return (EReference) abstractPropertyBindingEClass - .getEStructuralFeatures().get(3); - } - - /** - * - * - * @generated - */ - public EClass getEMFElementBinding() { - return emfElementBindingEClass; - } - - /** - * - * - * @generated - */ - public EReference getEMFElementBinding_Model() { - return (EReference) emfElementBindingEClass.getEStructuralFeatures() - .get(0); - } - - /** - * - * - * @generated - */ - public EClass getEMFPropertyBinding() { - return emfPropertyBindingEClass; - } - - /** - * - * - * @generated - */ - public EReference getEMFPropertyBinding_Model() { - return (EReference) emfPropertyBindingEClass.getEStructuralFeatures() - .get(0); - } - - /** - * - * - * @generated - */ - public EReference getEMFPropertyBinding_Navigation() { - return (EReference) emfPropertyBindingEClass.getEStructuralFeatures() - .get(1); - } - - /** - * - * - * @generated - */ - public EReference getEMFPropertyBinding_EditorSetting() { - return (EReference) emfPropertyBindingEClass.getEStructuralFeatures() - .get(2); - } - - /** - * - * - * @generated - */ - public EClass getStandardElementBinding() { - return standardElementBindingEClass; - } - - /** - * - * - * @generated - */ - public EReference getStandardElementBinding_Model() { - return (EReference) standardElementBindingEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getStandardPropertyBinding() { - return standardPropertyBindingEClass; - } - - /** - * - * - * @generated - */ - public EReference getStandardPropertyBinding_Model() { - return (EReference) standardPropertyBindingEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getCategory() { - return categoryEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getCategory_Name() { - return (EAttribute) categoryEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getCategory_Bindings() { - return (EReference) categoryEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EReference getCategory_Databinding() { - return (EReference) categoryEClass.getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EReference getCategory_Categories() { - return (EReference) categoryEClass.getEStructuralFeatures().get(3); - } - - /** - * - * - * @generated - */ - public EClass getElementBindingReference() { - return elementBindingReferenceEClass; - } - - /** - * - * - * @generated - */ - public EReference getElementBindingReference_Binding() { - return (EReference) elementBindingReferenceEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getDocumentedElement() { - return documentedElementEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getDocumentedElement_Documentation() { - return (EAttribute) documentedElementEClass.getEStructuralFeatures() - .get(0); - } - - /** - * - * - * @generated - */ - public EClass getEMFMultiPropertiesBinding() { - return emfMultiPropertiesBindingEClass; - } - - /** - * - * - * @generated - */ - public EReference getEMFMultiPropertiesBinding_Model() { - return (EReference) emfMultiPropertiesBindingEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getEMFMultiPropertiesBinding_Navigation() { - return (EReference) emfMultiPropertiesBindingEClass - .getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public MappingFactory getMappingFactory() { - return (MappingFactory) getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) - return; - isCreated = true; - - // Create classes and their features - databindingEClass = createEClass(DATABINDING); - createEReference(databindingEClass, DATABINDING__BINDINGS); - createEReference(databindingEClass, DATABINDING__CATEGORIES); - - modelElementEClass = createEClass(MODEL_ELEMENT); - createEReference(modelElementEClass, MODEL_ELEMENT__PROPERTIES); - createEReference(modelElementEClass, MODEL_ELEMENT__SUB_ELEMENTS); - createEReference(modelElementEClass, MODEL_ELEMENT__BINDING); - createEReference(modelElementEClass, MODEL_ELEMENT__SUPER_ELEMENT); - - abstractElementBindingEClass = createEClass(ABSTRACT_ELEMENT_BINDING); - createEReference(abstractElementBindingEClass, - ABSTRACT_ELEMENT_BINDING__SUB_ELEMENTS); - createEReference(abstractElementBindingEClass, - ABSTRACT_ELEMENT_BINDING__PROPERTIES); - createEReference(abstractElementBindingEClass, - ABSTRACT_ELEMENT_BINDING__DATABINDING); - createEReference(abstractElementBindingEClass, - ABSTRACT_ELEMENT_BINDING__SUPER_ELEMENT); - createEAttribute(abstractElementBindingEClass, - ABSTRACT_ELEMENT_BINDING__NAME); - createEReference(abstractElementBindingEClass, - ABSTRACT_ELEMENT_BINDING__REFERENCED_BINDING); - createEReference(abstractElementBindingEClass, - ABSTRACT_ELEMENT_BINDING__VIEWS); - createEReference(abstractElementBindingEClass, - ABSTRACT_ELEMENT_BINDING__CATEGORY); - createEReference(abstractElementBindingEClass, - ABSTRACT_ELEMENT_BINDING__BINDING_FILTERS); - - modelPropertyEClass = createEClass(MODEL_PROPERTY); - createEReference(modelPropertyEClass, MODEL_PROPERTY__BINDING); - createEReference(modelPropertyEClass, MODEL_PROPERTY__MODEL_ELEMENT); - - abstractPropertyBindingEClass = createEClass(ABSTRACT_PROPERTY_BINDING); - createEAttribute(abstractPropertyBindingEClass, - ABSTRACT_PROPERTY_BINDING__NAME); - createEReference(abstractPropertyBindingEClass, - ABSTRACT_PROPERTY_BINDING__VIEWS); - createEReference(abstractPropertyBindingEClass, - ABSTRACT_PROPERTY_BINDING__ELEMENT); - createEReference(abstractPropertyBindingEClass, - ABSTRACT_PROPERTY_BINDING__BINDING_FILTERS); - - emfElementBindingEClass = createEClass(EMF_ELEMENT_BINDING); - createEReference(emfElementBindingEClass, EMF_ELEMENT_BINDING__MODEL); - - emfPropertyBindingEClass = createEClass(EMF_PROPERTY_BINDING); - createEReference(emfPropertyBindingEClass, EMF_PROPERTY_BINDING__MODEL); - createEReference(emfPropertyBindingEClass, - EMF_PROPERTY_BINDING__NAVIGATION); - createEReference(emfPropertyBindingEClass, - EMF_PROPERTY_BINDING__EDITOR_SETTING); - - standardElementBindingEClass = createEClass(STANDARD_ELEMENT_BINDING); - createEReference(standardElementBindingEClass, - STANDARD_ELEMENT_BINDING__MODEL); - - standardPropertyBindingEClass = createEClass(STANDARD_PROPERTY_BINDING); - createEReference(standardPropertyBindingEClass, - STANDARD_PROPERTY_BINDING__MODEL); - - categoryEClass = createEClass(CATEGORY); - createEAttribute(categoryEClass, CATEGORY__NAME); - createEReference(categoryEClass, CATEGORY__BINDINGS); - createEReference(categoryEClass, CATEGORY__DATABINDING); - createEReference(categoryEClass, CATEGORY__CATEGORIES); - - elementBindingReferenceEClass = createEClass(ELEMENT_BINDING_REFERENCE); - createEReference(elementBindingReferenceEClass, - ELEMENT_BINDING_REFERENCE__BINDING); - - documentedElementEClass = createEClass(DOCUMENTED_ELEMENT); - createEAttribute(documentedElementEClass, - DOCUMENTED_ELEMENT__DOCUMENTATION); - - emfMultiPropertiesBindingEClass = createEClass(EMF_MULTI_PROPERTIES_BINDING); - createEReference(emfMultiPropertiesBindingEClass, - EMF_MULTI_PROPERTIES_BINDING__MODEL); - createEReference(emfMultiPropertiesBindingEClass, - EMF_MULTI_PROPERTIES_BINDING__NAVIGATION); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) - return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - NavigationPackage theNavigationPackage = (NavigationPackage) EPackage.Registry.INSTANCE - .getEPackage(NavigationPackage.eNS_URI); - FiltersPackage theFiltersPackage = (FiltersPackage) EPackage.Registry.INSTANCE - .getEPackage(FiltersPackage.eNS_URI); - SettingsPackage theSettingsPackage = (SettingsPackage) EPackage.Registry.INSTANCE - .getEPackage(SettingsPackage.eNS_URI); - ViewsPackage theViewsPackage = (ViewsPackage) EPackage.Registry.INSTANCE - .getEPackage(ViewsPackage.eNS_URI); - - // Add subpackages - getESubpackages().add(theNavigationPackage); - getESubpackages().add(theFiltersPackage); - getESubpackages().add(theSettingsPackage); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - databindingEClass.getESuperTypes().add(this.getDocumentedElement()); - modelElementEClass.getESuperTypes().add(this.getDocumentedElement()); - abstractElementBindingEClass.getESuperTypes().add( - this.getDocumentedElement()); - modelPropertyEClass.getESuperTypes().add(this.getDocumentedElement()); - abstractPropertyBindingEClass.getESuperTypes().add( - this.getDocumentedElement()); - emfElementBindingEClass.getESuperTypes().add( - this.getAbstractElementBinding()); - emfPropertyBindingEClass.getESuperTypes().add( - this.getAbstractPropertyBinding()); - standardElementBindingEClass.getESuperTypes().add( - this.getAbstractElementBinding()); - standardPropertyBindingEClass.getESuperTypes().add( - this.getAbstractPropertyBinding()); - categoryEClass.getESuperTypes().add(this.getDocumentedElement()); - elementBindingReferenceEClass.getESuperTypes().add( - this.getDocumentedElement()); - emfMultiPropertiesBindingEClass.getESuperTypes().add( - this.getAbstractPropertyBinding()); - - // Initialize classes and features; add operations and parameters - initEClass(databindingEClass, Databinding.class, "Databinding", - !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getDatabinding_Bindings(), - this.getAbstractElementBinding(), - this.getAbstractElementBinding_Databinding(), "bindings", null, - 0, -1, Databinding.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getDatabinding_Categories(), this.getCategory(), - this.getCategory_Databinding(), "categories", null, 0, -1, - Databinding.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, - IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, - !IS_DERIVED, IS_ORDERED); - - initEClass(modelElementEClass, ModelElement.class, "ModelElement", - IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getModelElement_Properties(), this.getModelProperty(), - this.getModelProperty_ModelElement(), "properties", null, 0, - -1, ModelElement.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getModelElement_SubElements(), this.getModelElement(), - this.getModelElement_SuperElement(), "subElements", null, 0, - -1, ModelElement.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getModelElement_Binding(), - this.getStandardElementBinding(), - this.getStandardElementBinding_Model(), "binding", null, 0, 1, - ModelElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, - !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, - !IS_DERIVED, IS_ORDERED); - initEReference(getModelElement_SuperElement(), this.getModelElement(), - this.getModelElement_SubElements(), "superElement", null, 0, 1, - ModelElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, - !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, - !IS_DERIVED, IS_ORDERED); - - initEClass(abstractElementBindingEClass, AbstractElementBinding.class, - "AbstractElementBinding", IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEReference(getAbstractElementBinding_SubElements(), - this.getAbstractElementBinding(), - this.getAbstractElementBinding_SuperElement(), "subElements", - null, 0, -1, AbstractElementBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getAbstractElementBinding_Properties(), - this.getAbstractPropertyBinding(), - this.getAbstractPropertyBinding_Element(), "properties", null, - 0, -1, AbstractElementBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getAbstractElementBinding_Databinding(), - this.getDatabinding(), this.getDatabinding_Bindings(), - "databinding", null, 0, 1, AbstractElementBinding.class, - !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, - !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEReference(getAbstractElementBinding_SuperElement(), - this.getAbstractElementBinding(), - this.getAbstractElementBinding_SubElements(), "superElement", - null, 0, 1, AbstractElementBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, - !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEAttribute(getAbstractElementBinding_Name(), - ecorePackage.getEString(), "name", null, 1, 1, - AbstractElementBinding.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEReference(getAbstractElementBinding_ReferencedBinding(), - this.getElementBindingReference(), null, "referencedBinding", - null, 0, -1, AbstractElementBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getAbstractElementBinding_Views(), - theViewsPackage.getView(), null, "views", null, 1, -1, - AbstractElementBinding.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getAbstractElementBinding_Category(), - this.getCategory(), this.getCategory_Bindings(), "category", - null, 0, 1, AbstractElementBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, - !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEReference(getAbstractElementBinding_BindingFilters(), - theFiltersPackage.getBindingFilter(), null, "bindingFilters", - null, 0, -1, AbstractElementBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(modelPropertyEClass, ModelProperty.class, "ModelProperty", - IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getModelProperty_Binding(), - this.getStandardPropertyBinding(), - this.getStandardPropertyBinding_Model(), "binding", null, 0, 1, - ModelProperty.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getModelProperty_ModelElement(), this.getModelElement(), - this.getModelElement_Properties(), "modelElement", null, 0, 1, - ModelProperty.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(abstractPropertyBindingEClass, - AbstractPropertyBinding.class, "AbstractPropertyBinding", - IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getAbstractPropertyBinding_Name(), - ecorePackage.getEString(), "name", null, 1, 1, - AbstractPropertyBinding.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEReference(getAbstractPropertyBinding_Views(), - theViewsPackage.getElementEditor(), null, "views", null, 1, -1, - AbstractPropertyBinding.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getAbstractPropertyBinding_Element(), - this.getAbstractElementBinding(), - this.getAbstractElementBinding_Properties(), "element", null, - 0, 1, AbstractPropertyBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, - !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEReference(getAbstractPropertyBinding_BindingFilters(), - theFiltersPackage.getBindingFilter(), null, "bindingFilters", - null, 0, -1, AbstractPropertyBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(emfElementBindingEClass, EMFElementBinding.class, - "EMFElementBinding", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEReference(getEMFElementBinding_Model(), - ecorePackage.getEClassifier(), null, "model", null, 1, 1, - EMFElementBinding.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(emfPropertyBindingEClass, EMFPropertyBinding.class, - "EMFPropertyBinding", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEReference(getEMFPropertyBinding_Model(), - ecorePackage.getEStructuralFeature(), null, "model", null, 1, - 1, EMFPropertyBinding.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getEMFPropertyBinding_Navigation(), - theNavigationPackage.getModelNavigation(), null, "navigation", - null, 0, 1, EMFPropertyBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getEMFPropertyBinding_EditorSetting(), - theSettingsPackage.getEditorSettings(), null, "editorSetting", - null, 0, 1, EMFPropertyBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(standardElementBindingEClass, StandardElementBinding.class, - "StandardElementBinding", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEReference(getStandardElementBinding_Model(), - this.getModelElement(), this.getModelElement_Binding(), - "model", null, 1, 1, StandardElementBinding.class, - !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, - IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - - initEClass(standardPropertyBindingEClass, - StandardPropertyBinding.class, "StandardPropertyBinding", - !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getStandardPropertyBinding_Model(), - this.getModelProperty(), this.getModelProperty_Binding(), - "model", null, 1, 1, StandardPropertyBinding.class, - !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, - IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - - initEClass(categoryEClass, Category.class, "Category", !IS_ABSTRACT, - !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getCategory_Name(), ecorePackage.getEString(), "name", - null, 1, 1, Category.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEReference(getCategory_Bindings(), - this.getAbstractElementBinding(), - this.getAbstractElementBinding_Category(), "bindings", null, 0, - -1, Category.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, - IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, - !IS_DERIVED, IS_ORDERED); - initEReference(getCategory_Databinding(), this.getDatabinding(), - this.getDatabinding_Categories(), "databinding", null, 0, 1, - Category.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, - !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, - !IS_DERIVED, IS_ORDERED); - initEReference(getCategory_Categories(), this.getCategory(), null, - "categories", null, 0, -1, Category.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(elementBindingReferenceEClass, - ElementBindingReference.class, "ElementBindingReference", - !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getElementBindingReference_Binding(), - this.getAbstractElementBinding(), null, "binding", null, 1, 1, - ElementBindingReference.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(documentedElementEClass, DocumentedElement.class, - "DocumentedElement", IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getDocumentedElement_Documentation(), - ecorePackage.getEString(), "documentation", null, 0, 1, - DocumentedElement.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - - initEClass(emfMultiPropertiesBindingEClass, - EMFMultiPropertiesBinding.class, "EMFMultiPropertiesBinding", - !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getEMFMultiPropertiesBinding_Model(), - ecorePackage.getEStructuralFeature(), null, "model", null, 1, - -1, EMFMultiPropertiesBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getEMFMultiPropertiesBinding_Navigation(), - theNavigationPackage.getModelNavigation(), null, "navigation", - null, 0, 1, EMFMultiPropertiesBinding.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - // Create resource - createResource(eNS_URI); - } - -} //MappingPackageImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ModelElementImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ModelElementImpl.java deleted file mode 100644 index e1e0d3457..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ModelElementImpl.java +++ /dev/null @@ -1,416 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.ecore.util.InternalEList; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelElement; -import org.eclipse.emf.eef.mapping.ModelProperty; -import org.eclipse.emf.eef.mapping.StandardElementBinding; -import org.eclipse.emf.eef.views.impl.DocumentedElementImpl; - -/** - * - * An implementation of the model object 'Model Element'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.ModelElementImpl#getProperties Properties}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.ModelElementImpl#getSubElements Sub Elements}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.ModelElementImpl#getBinding Binding}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.ModelElementImpl#getSuperElement Super Element}
  • - *
- *

- * - * @generated - */ -public abstract class ModelElementImpl extends DocumentedElementImpl implements - ModelElement { - /** - * The cached value of the '{@link #getProperties() Properties}' containment reference list. - * - * - * @see #getProperties() - * @generated - * @ordered - */ - protected EList properties; - - /** - * The cached value of the '{@link #getSubElements() Sub Elements}' containment reference list. - * - * - * @see #getSubElements() - * @generated - * @ordered - */ - protected EList subElements; - - /** - * The cached value of the '{@link #getBinding() Binding}' reference. - * - * - * @see #getBinding() - * @generated - * @ordered - */ - protected StandardElementBinding binding; - - /** - * - * - * @generated - */ - protected ModelElementImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.MODEL_ELEMENT; - } - - /** - * - * - * @generated - */ - public EList getProperties() { - if (properties == null) { - properties = new EObjectContainmentWithInverseEList( - ModelProperty.class, this, - MappingPackage.MODEL_ELEMENT__PROPERTIES, - MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT); - } - return properties; - } - - /** - * - * - * @generated - */ - public EList getSubElements() { - if (subElements == null) { - subElements = new EObjectContainmentWithInverseEList( - ModelElement.class, this, - MappingPackage.MODEL_ELEMENT__SUB_ELEMENTS, - MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT); - } - return subElements; - } - - /** - * - * - * @generated - */ - public StandardElementBinding getBinding() { - if (binding != null && binding.eIsProxy()) { - InternalEObject oldBinding = (InternalEObject) binding; - binding = (StandardElementBinding) eResolveProxy(oldBinding); - if (binding != oldBinding) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - MappingPackage.MODEL_ELEMENT__BINDING, oldBinding, - binding)); - } - } - return binding; - } - - /** - * - * - * @generated - */ - public StandardElementBinding basicGetBinding() { - return binding; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetBinding(StandardElementBinding newBinding, - NotificationChain msgs) { - StandardElementBinding oldBinding = binding; - binding = newBinding; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, MappingPackage.MODEL_ELEMENT__BINDING, - oldBinding, newBinding); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setBinding(StandardElementBinding newBinding) { - if (newBinding != binding) { - NotificationChain msgs = null; - if (binding != null) - msgs = ((InternalEObject) binding).eInverseRemove(this, - MappingPackage.STANDARD_ELEMENT_BINDING__MODEL, - StandardElementBinding.class, msgs); - if (newBinding != null) - msgs = ((InternalEObject) newBinding).eInverseAdd(this, - MappingPackage.STANDARD_ELEMENT_BINDING__MODEL, - StandardElementBinding.class, msgs); - msgs = basicSetBinding(newBinding, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.MODEL_ELEMENT__BINDING, newBinding, - newBinding)); - } - - /** - * - * - * @generated - */ - public ModelElement getSuperElement() { - if (eContainerFeatureID() != MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT) - return null; - return (ModelElement) eContainer(); - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetSuperElement(ModelElement newSuperElement, - NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject) newSuperElement, - MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT, msgs); - return msgs; - } - - /** - * - * - * @generated - */ - public void setSuperElement(ModelElement newSuperElement) { - if (newSuperElement != eInternalContainer() - || (eContainerFeatureID() != MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT && newSuperElement != null)) { - if (EcoreUtil.isAncestor(this, newSuperElement)) - throw new IllegalArgumentException( - "Recursive containment not allowed for " + toString()); - NotificationChain msgs = null; - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - if (newSuperElement != null) - msgs = ((InternalEObject) newSuperElement).eInverseAdd(this, - MappingPackage.MODEL_ELEMENT__SUB_ELEMENTS, - ModelElement.class, msgs); - msgs = basicSetSuperElement(newSuperElement, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT, - newSuperElement, newSuperElement)); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.MODEL_ELEMENT__PROPERTIES: - return ((InternalEList) (InternalEList) getProperties()) - .basicAdd(otherEnd, msgs); - case MappingPackage.MODEL_ELEMENT__SUB_ELEMENTS: - return ((InternalEList) (InternalEList) getSubElements()) - .basicAdd(otherEnd, msgs); - case MappingPackage.MODEL_ELEMENT__BINDING: - if (binding != null) - msgs = ((InternalEObject) binding).eInverseRemove(this, - MappingPackage.STANDARD_ELEMENT_BINDING__MODEL, - StandardElementBinding.class, msgs); - return basicSetBinding((StandardElementBinding) otherEnd, msgs); - case MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT: - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - return basicSetSuperElement((ModelElement) otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.MODEL_ELEMENT__PROPERTIES: - return ((InternalEList) getProperties()).basicRemove(otherEnd, - msgs); - case MappingPackage.MODEL_ELEMENT__SUB_ELEMENTS: - return ((InternalEList) getSubElements()).basicRemove(otherEnd, - msgs); - case MappingPackage.MODEL_ELEMENT__BINDING: - return basicSetBinding(null, msgs); - case MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT: - return basicSetSuperElement(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eBasicRemoveFromContainerFeature( - NotificationChain msgs) { - switch (eContainerFeatureID()) { - case MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT: - return eInternalContainer().eInverseRemove(this, - MappingPackage.MODEL_ELEMENT__SUB_ELEMENTS, - ModelElement.class, msgs); - } - return super.eBasicRemoveFromContainerFeature(msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.MODEL_ELEMENT__PROPERTIES: - return getProperties(); - case MappingPackage.MODEL_ELEMENT__SUB_ELEMENTS: - return getSubElements(); - case MappingPackage.MODEL_ELEMENT__BINDING: - if (resolve) - return getBinding(); - return basicGetBinding(); - case MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT: - return getSuperElement(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.MODEL_ELEMENT__PROPERTIES: - getProperties().clear(); - getProperties().addAll( - (Collection) newValue); - return; - case MappingPackage.MODEL_ELEMENT__SUB_ELEMENTS: - getSubElements().clear(); - getSubElements().addAll( - (Collection) newValue); - return; - case MappingPackage.MODEL_ELEMENT__BINDING: - setBinding((StandardElementBinding) newValue); - return; - case MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT: - setSuperElement((ModelElement) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.MODEL_ELEMENT__PROPERTIES: - getProperties().clear(); - return; - case MappingPackage.MODEL_ELEMENT__SUB_ELEMENTS: - getSubElements().clear(); - return; - case MappingPackage.MODEL_ELEMENT__BINDING: - setBinding((StandardElementBinding) null); - return; - case MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT: - setSuperElement((ModelElement) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.MODEL_ELEMENT__PROPERTIES: - return properties != null && !properties.isEmpty(); - case MappingPackage.MODEL_ELEMENT__SUB_ELEMENTS: - return subElements != null && !subElements.isEmpty(); - case MappingPackage.MODEL_ELEMENT__BINDING: - return binding != null; - case MappingPackage.MODEL_ELEMENT__SUPER_ELEMENT: - return getSuperElement() != null; - } - return super.eIsSet(featureID); - } - -} //ModelElementImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ModelPropertyImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ModelPropertyImpl.java deleted file mode 100644 index 72b1da438..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/ModelPropertyImpl.java +++ /dev/null @@ -1,321 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelElement; -import org.eclipse.emf.eef.mapping.ModelProperty; -import org.eclipse.emf.eef.mapping.StandardPropertyBinding; -import org.eclipse.emf.eef.views.impl.DocumentedElementImpl; - -/** - * - * An implementation of the model object 'Model Property'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.ModelPropertyImpl#getBinding Binding}
  • - *
  • {@link org.eclipse.emf.eef.mapping.impl.ModelPropertyImpl#getModelElement Model Element}
  • - *
- *

- * - * @generated - */ -public abstract class ModelPropertyImpl extends DocumentedElementImpl implements - ModelProperty { - /** - * The cached value of the '{@link #getBinding() Binding}' reference. - * - * - * @see #getBinding() - * @generated - * @ordered - */ - protected StandardPropertyBinding binding; - - /** - * - * - * @generated - */ - protected ModelPropertyImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.MODEL_PROPERTY; - } - - /** - * - * - * @generated - */ - public StandardPropertyBinding getBinding() { - if (binding != null && binding.eIsProxy()) { - InternalEObject oldBinding = (InternalEObject) binding; - binding = (StandardPropertyBinding) eResolveProxy(oldBinding); - if (binding != oldBinding) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - MappingPackage.MODEL_PROPERTY__BINDING, oldBinding, - binding)); - } - } - return binding; - } - - /** - * - * - * @generated - */ - public StandardPropertyBinding basicGetBinding() { - return binding; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetBinding( - StandardPropertyBinding newBinding, NotificationChain msgs) { - StandardPropertyBinding oldBinding = binding; - binding = newBinding; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, MappingPackage.MODEL_PROPERTY__BINDING, - oldBinding, newBinding); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setBinding(StandardPropertyBinding newBinding) { - if (newBinding != binding) { - NotificationChain msgs = null; - if (binding != null) - msgs = ((InternalEObject) binding).eInverseRemove(this, - MappingPackage.STANDARD_PROPERTY_BINDING__MODEL, - StandardPropertyBinding.class, msgs); - if (newBinding != null) - msgs = ((InternalEObject) newBinding).eInverseAdd(this, - MappingPackage.STANDARD_PROPERTY_BINDING__MODEL, - StandardPropertyBinding.class, msgs); - msgs = basicSetBinding(newBinding, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.MODEL_PROPERTY__BINDING, newBinding, - newBinding)); - } - - /** - * - * - * @generated - */ - public ModelElement getModelElement() { - if (eContainerFeatureID() != MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT) - return null; - return (ModelElement) eContainer(); - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetModelElement(ModelElement newModelElement, - NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject) newModelElement, - MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT, msgs); - return msgs; - } - - /** - * - * - * @generated - */ - public void setModelElement(ModelElement newModelElement) { - if (newModelElement != eInternalContainer() - || (eContainerFeatureID() != MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT && newModelElement != null)) { - if (EcoreUtil.isAncestor(this, newModelElement)) - throw new IllegalArgumentException( - "Recursive containment not allowed for " + toString()); - NotificationChain msgs = null; - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - if (newModelElement != null) - msgs = ((InternalEObject) newModelElement).eInverseAdd(this, - MappingPackage.MODEL_ELEMENT__PROPERTIES, - ModelElement.class, msgs); - msgs = basicSetModelElement(newModelElement, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT, - newModelElement, newModelElement)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.MODEL_PROPERTY__BINDING: - if (binding != null) - msgs = ((InternalEObject) binding).eInverseRemove(this, - MappingPackage.STANDARD_PROPERTY_BINDING__MODEL, - StandardPropertyBinding.class, msgs); - return basicSetBinding((StandardPropertyBinding) otherEnd, msgs); - case MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT: - if (eInternalContainer() != null) - msgs = eBasicRemoveFromContainer(msgs); - return basicSetModelElement((ModelElement) otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.MODEL_PROPERTY__BINDING: - return basicSetBinding(null, msgs); - case MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT: - return basicSetModelElement(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eBasicRemoveFromContainerFeature( - NotificationChain msgs) { - switch (eContainerFeatureID()) { - case MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT: - return eInternalContainer().eInverseRemove(this, - MappingPackage.MODEL_ELEMENT__PROPERTIES, - ModelElement.class, msgs); - } - return super.eBasicRemoveFromContainerFeature(msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.MODEL_PROPERTY__BINDING: - if (resolve) - return getBinding(); - return basicGetBinding(); - case MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT: - return getModelElement(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.MODEL_PROPERTY__BINDING: - setBinding((StandardPropertyBinding) newValue); - return; - case MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT: - setModelElement((ModelElement) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.MODEL_PROPERTY__BINDING: - setBinding((StandardPropertyBinding) null); - return; - case MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT: - setModelElement((ModelElement) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.MODEL_PROPERTY__BINDING: - return binding != null; - case MappingPackage.MODEL_PROPERTY__MODEL_ELEMENT: - return getModelElement() != null; - } - return super.eIsSet(featureID); - } - -} //ModelPropertyImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/StandardElementBindingImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/StandardElementBindingImpl.java deleted file mode 100644 index c6cd60a5c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/StandardElementBindingImpl.java +++ /dev/null @@ -1,235 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelElement; -import org.eclipse.emf.eef.mapping.StandardElementBinding; - -/** - * - * An implementation of the model object 'Standard Element Binding'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.StandardElementBindingImpl#getModel Model}
  • - *
- *

- * - * @generated - */ -public class StandardElementBindingImpl extends AbstractElementBindingImpl - implements StandardElementBinding { - /** - * The cached value of the '{@link #getModel() Model}' reference. - * - * - * @see #getModel() - * @generated - * @ordered - */ - protected ModelElement model; - - /** - * - * - * @generated - */ - protected StandardElementBindingImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.STANDARD_ELEMENT_BINDING; - } - - /** - * - * - * @generated - */ - public ModelElement getModel() { - if (model != null && model.eIsProxy()) { - InternalEObject oldModel = (InternalEObject) model; - model = (ModelElement) eResolveProxy(oldModel); - if (model != oldModel) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - MappingPackage.STANDARD_ELEMENT_BINDING__MODEL, - oldModel, model)); - } - } - return model; - } - - /** - * - * - * @generated - */ - public ModelElement basicGetModel() { - return model; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetModel(ModelElement newModel, - NotificationChain msgs) { - ModelElement oldModel = model; - model = newModel; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - MappingPackage.STANDARD_ELEMENT_BINDING__MODEL, oldModel, - newModel); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setModel(ModelElement newModel) { - if (newModel != model) { - NotificationChain msgs = null; - if (model != null) - msgs = ((InternalEObject) model).eInverseRemove(this, - MappingPackage.MODEL_ELEMENT__BINDING, - ModelElement.class, msgs); - if (newModel != null) - msgs = ((InternalEObject) newModel).eInverseAdd(this, - MappingPackage.MODEL_ELEMENT__BINDING, - ModelElement.class, msgs); - msgs = basicSetModel(newModel, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.STANDARD_ELEMENT_BINDING__MODEL, newModel, - newModel)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.STANDARD_ELEMENT_BINDING__MODEL: - if (model != null) - msgs = ((InternalEObject) model).eInverseRemove(this, - MappingPackage.MODEL_ELEMENT__BINDING, - ModelElement.class, msgs); - return basicSetModel((ModelElement) otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.STANDARD_ELEMENT_BINDING__MODEL: - return basicSetModel(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.STANDARD_ELEMENT_BINDING__MODEL: - if (resolve) - return getModel(); - return basicGetModel(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.STANDARD_ELEMENT_BINDING__MODEL: - setModel((ModelElement) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.STANDARD_ELEMENT_BINDING__MODEL: - setModel((ModelElement) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.STANDARD_ELEMENT_BINDING__MODEL: - return model != null; - } - return super.eIsSet(featureID); - } - -} //StandardElementBindingImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/StandardPropertyBindingImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/StandardPropertyBindingImpl.java deleted file mode 100644 index 5803640cf..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/impl/StandardPropertyBindingImpl.java +++ /dev/null @@ -1,235 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelProperty; -import org.eclipse.emf.eef.mapping.StandardPropertyBinding; - -/** - * - * An implementation of the model object 'Standard Property Binding'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.impl.StandardPropertyBindingImpl#getModel Model}
  • - *
- *

- * - * @generated - */ -public class StandardPropertyBindingImpl extends AbstractPropertyBindingImpl - implements StandardPropertyBinding { - /** - * The cached value of the '{@link #getModel() Model}' reference. - * - * - * @see #getModel() - * @generated - * @ordered - */ - protected ModelProperty model; - - /** - * - * - * @generated - */ - protected StandardPropertyBindingImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return MappingPackage.Literals.STANDARD_PROPERTY_BINDING; - } - - /** - * - * - * @generated - */ - public ModelProperty getModel() { - if (model != null && model.eIsProxy()) { - InternalEObject oldModel = (InternalEObject) model; - model = (ModelProperty) eResolveProxy(oldModel); - if (model != oldModel) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - MappingPackage.STANDARD_PROPERTY_BINDING__MODEL, - oldModel, model)); - } - } - return model; - } - - /** - * - * - * @generated - */ - public ModelProperty basicGetModel() { - return model; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetModel(ModelProperty newModel, - NotificationChain msgs) { - ModelProperty oldModel = model; - model = newModel; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - MappingPackage.STANDARD_PROPERTY_BINDING__MODEL, oldModel, - newModel); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setModel(ModelProperty newModel) { - if (newModel != model) { - NotificationChain msgs = null; - if (model != null) - msgs = ((InternalEObject) model).eInverseRemove(this, - MappingPackage.MODEL_PROPERTY__BINDING, - ModelProperty.class, msgs); - if (newModel != null) - msgs = ((InternalEObject) newModel).eInverseAdd(this, - MappingPackage.MODEL_PROPERTY__BINDING, - ModelProperty.class, msgs); - msgs = basicSetModel(newModel, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - MappingPackage.STANDARD_PROPERTY_BINDING__MODEL, newModel, - newModel)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseAdd(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.STANDARD_PROPERTY_BINDING__MODEL: - if (model != null) - msgs = ((InternalEObject) model).eInverseRemove(this, - MappingPackage.MODEL_PROPERTY__BINDING, - ModelProperty.class, msgs); - return basicSetModel((ModelProperty) otherEnd, msgs); - } - return super.eInverseAdd(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case MappingPackage.STANDARD_PROPERTY_BINDING__MODEL: - return basicSetModel(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case MappingPackage.STANDARD_PROPERTY_BINDING__MODEL: - if (resolve) - return getModel(); - return basicGetModel(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case MappingPackage.STANDARD_PROPERTY_BINDING__MODEL: - setModel((ModelProperty) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case MappingPackage.STANDARD_PROPERTY_BINDING__MODEL: - setModel((ModelProperty) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case MappingPackage.STANDARD_PROPERTY_BINDING__MODEL: - return model != null; - } - return super.eIsSet(featureID); - } - -} //StandardPropertyBindingImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/ChainedModelNavigation.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/ChainedModelNavigation.java deleted file mode 100644 index de5bf690a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/ChainedModelNavigation.java +++ /dev/null @@ -1,97 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EClass; - -/** - * - * A representation of the model object 'Chained Model Navigation'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#getCurrent Current}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#getNext Next}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getChainedModelNavigation() - * @model - * @generated - */ -public interface ChainedModelNavigation extends StructuredModelNavigation { - /** - * Returns the value of the 'Current' containment reference. - * - *

- * If the meaning of the 'Current' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Current' containment reference. - * @see #setCurrent(StructuredModelNavigation) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getChainedModelNavigation_Current() - * @model containment="true" required="true" - * @generated - */ - StructuredModelNavigation getCurrent(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#getCurrent Current}' containment reference. - * - * - * @param value the new value of the 'Current' containment reference. - * @see #getCurrent() - * @generated - */ - void setCurrent(StructuredModelNavigation value); - - /** - * Returns the value of the 'Next' containment reference. - * - *

- * If the meaning of the 'Next' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Next' containment reference. - * @see #setNext(StructuredModelNavigation) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getChainedModelNavigation_Next() - * @model containment="true" required="true" - * @generated - */ - StructuredModelNavigation getNext(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#getNext Next}' containment reference. - * - * - * @param value the new value of the 'Next' containment reference. - * @see #getNext() - * @generated - */ - void setNext(StructuredModelNavigation value); - - /** - * @return the owning EClass - * @generated NOT - */ - EClass owningEClass(); - - /** - * @return the current EClass - * @generated NOT - */ - EClass currentEClass(); - -} // ChainedModelNavigation diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/CustomModelNavigation.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/CustomModelNavigation.java deleted file mode 100644 index 232b6d84d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/CustomModelNavigation.java +++ /dev/null @@ -1,24 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation; - -/** - * - * A representation of the model object 'Custom Model Navigation'. - * - * - * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getCustomModelNavigation() - * @model - * @generated - */ -public interface CustomModelNavigation extends ModelNavigation { -} // CustomModelNavigation diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/DeclarativeNavigationStep.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/DeclarativeNavigationStep.java deleted file mode 100644 index 5a8d5145c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/DeclarativeNavigationStep.java +++ /dev/null @@ -1,109 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EReference; - -/** - * - * A representation of the model object 'Declarative Navigation Step'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getIndex Index}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getFeature Feature}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getDiscriminatorType Discriminator Type}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getDeclarativeNavigationStep() - * @model - * @generated - */ -public interface DeclarativeNavigationStep extends NavigationStep { - /** - * Returns the value of the 'Index' attribute. - * - *

- * If the meaning of the 'Index' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Index' attribute. - * @see #setIndex(int) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getDeclarativeNavigationStep_Index() - * @model - * @generated - */ - int getIndex(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getIndex Index}' attribute. - * - * - * @param value the new value of the 'Index' attribute. - * @see #getIndex() - * @generated - */ - void setIndex(int value); - - /** - * Returns the value of the 'Feature' reference. - * - *

- * If the meaning of the 'Feature' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Feature' reference. - * @see #setFeature(EReference) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getDeclarativeNavigationStep_Feature() - * @model required="true" - * @generated - */ - EReference getFeature(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getFeature Feature}' reference. - * - * - * @param value the new value of the 'Feature' reference. - * @see #getFeature() - * @generated - */ - void setFeature(EReference value); - - /** - * Returns the value of the 'Discriminator Type' reference. - * - *

- * If the meaning of the 'Discriminator Type' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Discriminator Type' reference. - * @see #setDiscriminatorType(EClassifier) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getDeclarativeNavigationStep_DiscriminatorType() - * @model - * @generated - */ - EClassifier getDiscriminatorType(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getDiscriminatorType Discriminator Type}' reference. - * - * - * @param value the new value of the 'Discriminator Type' reference. - * @see #getDiscriminatorType() - * @generated - */ - void setDiscriminatorType(EClassifier value); - -} // DeclarativeNavigationStep diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaBodyExpression.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaBodyExpression.java deleted file mode 100644 index 0d2ee289f..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaBodyExpression.java +++ /dev/null @@ -1,54 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Java Body Expression'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression#getBody Body}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getJavaBodyExpression() - * @model - * @generated - */ -public interface JavaBodyExpression extends EObject { - /** - * Returns the value of the 'Body' attribute. - * - *

- * If the meaning of the 'Body' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Body' attribute. - * @see #setBody(String) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getJavaBodyExpression_Body() - * @model required="true" - * @generated - */ - String getBody(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression#getBody Body}' attribute. - * - * - * @param value the new value of the 'Body' attribute. - * @see #getBody() - * @generated - */ - void setBody(String value); - -} // JavaBodyExpression diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaBodyStepInitializer.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaBodyStepInitializer.java deleted file mode 100644 index 489745a7f..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaBodyStepInitializer.java +++ /dev/null @@ -1,21 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation; - -/** - * - * A representation of the model object 'Java Body Step Initializer'. - * - * - * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getJavaBodyStepInitializer() - * @model - * @generated - */ -public interface JavaBodyStepInitializer extends JavaBodyExpression, - JavaStepInitializer { -} // JavaBodyStepInitializer diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaDeclarationExpression.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaDeclarationExpression.java deleted file mode 100644 index 9de021e3e..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaDeclarationExpression.java +++ /dev/null @@ -1,108 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Java Declaration Expression'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#getQualifiedClass Qualified Class}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#getMethodName Method Name}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#isStaticMethod Static Method}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getJavaDeclarationExpression() - * @model abstract="true" - * @generated - */ -public interface JavaDeclarationExpression extends EObject { - /** - * Returns the value of the 'Qualified Class' attribute. - * - *

- * If the meaning of the 'Qualified Class' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Qualified Class' attribute. - * @see #setQualifiedClass(String) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getJavaDeclarationExpression_QualifiedClass() - * @model required="true" - * @generated - */ - String getQualifiedClass(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#getQualifiedClass Qualified Class}' attribute. - * - * - * @param value the new value of the 'Qualified Class' attribute. - * @see #getQualifiedClass() - * @generated - */ - void setQualifiedClass(String value); - - /** - * Returns the value of the 'Method Name' attribute. - * - *

- * If the meaning of the 'Method Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Method Name' attribute. - * @see #setMethodName(String) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getJavaDeclarationExpression_MethodName() - * @model required="true" - * @generated - */ - String getMethodName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#getMethodName Method Name}' attribute. - * - * - * @param value the new value of the 'Method Name' attribute. - * @see #getMethodName() - * @generated - */ - void setMethodName(String value); - - /** - * Returns the value of the 'Static Method' attribute. - * - *

- * If the meaning of the 'Static Method' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Static Method' attribute. - * @see #setStaticMethod(boolean) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getJavaDeclarationExpression_StaticMethod() - * @model - * @generated - */ - boolean isStaticMethod(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#isStaticMethod Static Method}' attribute. - * - * - * @param value the new value of the 'Static Method' attribute. - * @see #isStaticMethod() - * @generated - */ - void setStaticMethod(boolean value); - -} // JavaDeclarationExpression diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaDeclarationStepInitializer.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaDeclarationStepInitializer.java deleted file mode 100644 index d1725482d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaDeclarationStepInitializer.java +++ /dev/null @@ -1,21 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation; - -/** - * - * A representation of the model object 'Java Declaration Step Initializer'. - * - * - * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getJavaDeclarationStepInitializer() - * @model - * @generated - */ -public interface JavaDeclarationStepInitializer extends - JavaDeclarationExpression, JavaStepInitializer { -} // JavaDeclarationStepInitializer diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaStepInitializer.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaStepInitializer.java deleted file mode 100644 index f3fde3f42..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/JavaStepInitializer.java +++ /dev/null @@ -1,22 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Java Step Initializer'. - * - * - * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getJavaStepInitializer() - * @model interface="true" abstract="true" - * @generated - */ -public interface JavaStepInitializer extends StepInitializer { -} // JavaStepInitializer diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/ModelNavigation.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/ModelNavigation.java deleted file mode 100644 index c5bfee41d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/ModelNavigation.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Model Navigation'. - * - * - * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getModelNavigation() - * @model abstract="true" - * @generated - */ -public interface ModelNavigation extends EObject { -} // ModelNavigation diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationFactory.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationFactory.java deleted file mode 100644 index ecc0f667f..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationFactory.java +++ /dev/null @@ -1,114 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage - * @generated - */ -public interface NavigationFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - NavigationFactory eINSTANCE = org.eclipse.emf.eef.mapping.navigation.impl.NavigationFactoryImpl - .init(); - - /** - * Returns a new object of class 'Simple Model Navigation'. - * - * - * @return a new object of class 'Simple Model Navigation'. - * @generated - */ - SimpleModelNavigation createSimpleModelNavigation(); - - /** - * Returns a new object of class 'Chained Model Navigation'. - * - * - * @return a new object of class 'Chained Model Navigation'. - * @generated - */ - ChainedModelNavigation createChainedModelNavigation(); - - /** - * Returns a new object of class 'Custom Model Navigation'. - * - * - * @return a new object of class 'Custom Model Navigation'. - * @generated - */ - CustomModelNavigation createCustomModelNavigation(); - - /** - * Returns a new object of class 'Smart Model Navigation'. - * - * - * @return a new object of class 'Smart Model Navigation'. - * @generated - */ - SmartModelNavigation createSmartModelNavigation(); - - /** - * Returns a new object of class 'Declarative Navigation Step'. - * - * - * @return a new object of class 'Declarative Navigation Step'. - * @generated - */ - DeclarativeNavigationStep createDeclarativeNavigationStep(); - - /** - * Returns a new object of class 'Java Body Expression'. - * - * - * @return a new object of class 'Java Body Expression'. - * @generated - */ - JavaBodyExpression createJavaBodyExpression(); - - /** - * Returns a new object of class 'Java Declaration Step Initializer'. - * - * - * @return a new object of class 'Java Declaration Step Initializer'. - * @generated - */ - JavaDeclarationStepInitializer createJavaDeclarationStepInitializer(); - - /** - * Returns a new object of class 'Java Body Step Initializer'. - * - * - * @return a new object of class 'Java Body Step Initializer'. - * @generated - */ - JavaBodyStepInitializer createJavaBodyStepInitializer(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - NavigationPackage getNavigationPackage(); - -} //NavigationFactory diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationPackage.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationPackage.java deleted file mode 100644 index b58e4bb99..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationPackage.java +++ /dev/null @@ -1,1169 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationFactory - * @model kind="package" - * @generated - */ -public interface NavigationPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "navigation"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/mapping/navigation/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-mapping-navigation"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - NavigationPackage eINSTANCE = org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl - .init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.ModelNavigationImpl Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.ModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getModelNavigation() - * @generated - */ - int MODEL_NAVIGATION = 0; - - /** - * The number of structural features of the 'Model Navigation' class. - * - * - * @generated - * @ordered - */ - int MODEL_NAVIGATION_FEATURE_COUNT = 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.StructuredModelNavigationImpl Structured Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.StructuredModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getStructuredModelNavigation() - * @generated - */ - int STRUCTURED_MODEL_NAVIGATION = 3; - - /** - * The number of structural features of the 'Structured Model Navigation' class. - * - * - * @generated - * @ordered - */ - int STRUCTURED_MODEL_NAVIGATION_FEATURE_COUNT = MODEL_NAVIGATION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.SimpleModelNavigationImpl Simple Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.SimpleModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getSimpleModelNavigation() - * @generated - */ - int SIMPLE_MODEL_NAVIGATION = 1; - - /** - * The feature id for the 'Feature' reference. - * - * - * @generated - * @ordered - */ - int SIMPLE_MODEL_NAVIGATION__FEATURE = STRUCTURED_MODEL_NAVIGATION_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Index' attribute. - * - * - * @generated - * @ordered - */ - int SIMPLE_MODEL_NAVIGATION__INDEX = STRUCTURED_MODEL_NAVIGATION_FEATURE_COUNT + 1; - - /** - * The feature id for the 'Discriminator Type' reference. - * - * - * @generated - * @ordered - */ - int SIMPLE_MODEL_NAVIGATION__DISCRIMINATOR_TYPE = STRUCTURED_MODEL_NAVIGATION_FEATURE_COUNT + 2; - - /** - * The number of structural features of the 'Simple Model Navigation' class. - * - * - * @generated - * @ordered - */ - int SIMPLE_MODEL_NAVIGATION_FEATURE_COUNT = STRUCTURED_MODEL_NAVIGATION_FEATURE_COUNT + 3; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.ChainedModelNavigationImpl Chained Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.ChainedModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getChainedModelNavigation() - * @generated - */ - int CHAINED_MODEL_NAVIGATION = 2; - - /** - * The feature id for the 'Current' containment reference. - * - * - * @generated - * @ordered - */ - int CHAINED_MODEL_NAVIGATION__CURRENT = STRUCTURED_MODEL_NAVIGATION_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Next' containment reference. - * - * - * @generated - * @ordered - */ - int CHAINED_MODEL_NAVIGATION__NEXT = STRUCTURED_MODEL_NAVIGATION_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Chained Model Navigation' class. - * - * - * @generated - * @ordered - */ - int CHAINED_MODEL_NAVIGATION_FEATURE_COUNT = STRUCTURED_MODEL_NAVIGATION_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.CustomModelNavigationImpl Custom Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.CustomModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getCustomModelNavigation() - * @generated - */ - int CUSTOM_MODEL_NAVIGATION = 4; - - /** - * The number of structural features of the 'Custom Model Navigation' class. - * - * - * @generated - * @ordered - */ - int CUSTOM_MODEL_NAVIGATION_FEATURE_COUNT = MODEL_NAVIGATION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.SmartModelNavigationImpl Smart Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.SmartModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getSmartModelNavigation() - * @generated - */ - int SMART_MODEL_NAVIGATION = 5; - - /** - * The feature id for the 'Step' containment reference. - * - * - * @generated - * @ordered - */ - int SMART_MODEL_NAVIGATION__STEP = MODEL_NAVIGATION_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Smart Model Navigation' class. - * - * - * @generated - * @ordered - */ - int SMART_MODEL_NAVIGATION_FEATURE_COUNT = MODEL_NAVIGATION_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.NavigationStepImpl Step}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationStepImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getNavigationStep() - * @generated - */ - int NAVIGATION_STEP = 6; - - /** - * The feature id for the 'Sub Step' containment reference. - * - * - * @generated - * @ordered - */ - int NAVIGATION_STEP__SUB_STEP = 0; - - /** - * The feature id for the 'Initializer' containment reference. - * - * - * @generated - * @ordered - */ - int NAVIGATION_STEP__INITIALIZER = 1; - - /** - * The feature id for the 'Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int NAVIGATION_STEP__FILTERS = 2; - - /** - * The number of structural features of the 'Step' class. - * - * - * @generated - * @ordered - */ - int NAVIGATION_STEP_FEATURE_COUNT = 3; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.DeclarativeNavigationStepImpl Declarative Navigation Step}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.DeclarativeNavigationStepImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getDeclarativeNavigationStep() - * @generated - */ - int DECLARATIVE_NAVIGATION_STEP = 7; - - /** - * The feature id for the 'Sub Step' containment reference. - * - * - * @generated - * @ordered - */ - int DECLARATIVE_NAVIGATION_STEP__SUB_STEP = NAVIGATION_STEP__SUB_STEP; - - /** - * The feature id for the 'Initializer' containment reference. - * - * - * @generated - * @ordered - */ - int DECLARATIVE_NAVIGATION_STEP__INITIALIZER = NAVIGATION_STEP__INITIALIZER; - - /** - * The feature id for the 'Filters' containment reference list. - * - * - * @generated - * @ordered - */ - int DECLARATIVE_NAVIGATION_STEP__FILTERS = NAVIGATION_STEP__FILTERS; - - /** - * The feature id for the 'Index' attribute. - * - * - * @generated - * @ordered - */ - int DECLARATIVE_NAVIGATION_STEP__INDEX = NAVIGATION_STEP_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Feature' reference. - * - * - * @generated - * @ordered - */ - int DECLARATIVE_NAVIGATION_STEP__FEATURE = NAVIGATION_STEP_FEATURE_COUNT + 1; - - /** - * The feature id for the 'Discriminator Type' reference. - * - * - * @generated - * @ordered - */ - int DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE = NAVIGATION_STEP_FEATURE_COUNT + 2; - - /** - * The number of structural features of the 'Declarative Navigation Step' class. - * - * - * @generated - * @ordered - */ - int DECLARATIVE_NAVIGATION_STEP_FEATURE_COUNT = NAVIGATION_STEP_FEATURE_COUNT + 3; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.StepInitializerImpl Step Initializer}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.StepInitializerImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getStepInitializer() - * @generated - */ - int STEP_INITIALIZER = 8; - - /** - * The number of structural features of the 'Step Initializer' class. - * - * - * @generated - * @ordered - */ - int STEP_INITIALIZER_FEATURE_COUNT = 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.JavaStepInitializer Java Step Initializer}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.JavaStepInitializer - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getJavaStepInitializer() - * @generated - */ - int JAVA_STEP_INITIALIZER = 9; - - /** - * The number of structural features of the 'Java Step Initializer' class. - * - * - * @generated - * @ordered - */ - int JAVA_STEP_INITIALIZER_FEATURE_COUNT = STEP_INITIALIZER_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationExpressionImpl Java Declaration Expression}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationExpressionImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getJavaDeclarationExpression() - * @generated - */ - int JAVA_DECLARATION_EXPRESSION = 10; - - /** - * The feature id for the 'Qualified Class' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS = 0; - - /** - * The feature id for the 'Method Name' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_EXPRESSION__METHOD_NAME = 1; - - /** - * The feature id for the 'Static Method' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_EXPRESSION__STATIC_METHOD = 2; - - /** - * The number of structural features of the 'Java Declaration Expression' class. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_EXPRESSION_FEATURE_COUNT = 3; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.JavaBodyExpressionImpl Java Body Expression}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.JavaBodyExpressionImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getJavaBodyExpression() - * @generated - */ - int JAVA_BODY_EXPRESSION = 11; - - /** - * The feature id for the 'Body' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_BODY_EXPRESSION__BODY = 0; - - /** - * The number of structural features of the 'Java Body Expression' class. - * - * - * @generated - * @ordered - */ - int JAVA_BODY_EXPRESSION_FEATURE_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationStepInitializerImpl Java Declaration Step Initializer}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationStepInitializerImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getJavaDeclarationStepInitializer() - * @generated - */ - int JAVA_DECLARATION_STEP_INITIALIZER = 12; - - /** - * The feature id for the 'Qualified Class' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_STEP_INITIALIZER__QUALIFIED_CLASS = JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS; - - /** - * The feature id for the 'Method Name' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_STEP_INITIALIZER__METHOD_NAME = JAVA_DECLARATION_EXPRESSION__METHOD_NAME; - - /** - * The feature id for the 'Static Method' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_STEP_INITIALIZER__STATIC_METHOD = JAVA_DECLARATION_EXPRESSION__STATIC_METHOD; - - /** - * The number of structural features of the 'Java Declaration Step Initializer' class. - * - * - * @generated - * @ordered - */ - int JAVA_DECLARATION_STEP_INITIALIZER_FEATURE_COUNT = JAVA_DECLARATION_EXPRESSION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.JavaBodyStepInitializerImpl Java Body Step Initializer}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.JavaBodyStepInitializerImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getJavaBodyStepInitializer() - * @generated - */ - int JAVA_BODY_STEP_INITIALIZER = 13; - - /** - * The feature id for the 'Body' attribute. - * - * - * @generated - * @ordered - */ - int JAVA_BODY_STEP_INITIALIZER__BODY = JAVA_BODY_EXPRESSION__BODY; - - /** - * The number of structural features of the 'Java Body Step Initializer' class. - * - * - * @generated - * @ordered - */ - int JAVA_BODY_STEP_INITIALIZER_FEATURE_COUNT = JAVA_BODY_EXPRESSION_FEATURE_COUNT + 0; - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.ModelNavigation Model Navigation}'. - * - * - * @return the meta object for class 'Model Navigation'. - * @see org.eclipse.emf.eef.mapping.navigation.ModelNavigation - * @generated - */ - EClass getModelNavigation(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation Simple Model Navigation}'. - * - * - * @return the meta object for class 'Simple Model Navigation'. - * @see org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation - * @generated - */ - EClass getSimpleModelNavigation(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getFeature Feature}'. - * - * - * @return the meta object for the reference 'Feature'. - * @see org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getFeature() - * @see #getSimpleModelNavigation() - * @generated - */ - EReference getSimpleModelNavigation_Feature(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getIndex Index}'. - * - * - * @return the meta object for the attribute 'Index'. - * @see org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getIndex() - * @see #getSimpleModelNavigation() - * @generated - */ - EAttribute getSimpleModelNavigation_Index(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getDiscriminatorType Discriminator Type}'. - * - * - * @return the meta object for the reference 'Discriminator Type'. - * @see org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getDiscriminatorType() - * @see #getSimpleModelNavigation() - * @generated - */ - EReference getSimpleModelNavigation_DiscriminatorType(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation Chained Model Navigation}'. - * - * - * @return the meta object for class 'Chained Model Navigation'. - * @see org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation - * @generated - */ - EClass getChainedModelNavigation(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#getCurrent Current}'. - * - * - * @return the meta object for the containment reference 'Current'. - * @see org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#getCurrent() - * @see #getChainedModelNavigation() - * @generated - */ - EReference getChainedModelNavigation_Current(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#getNext Next}'. - * - * - * @return the meta object for the containment reference 'Next'. - * @see org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#getNext() - * @see #getChainedModelNavigation() - * @generated - */ - EReference getChainedModelNavigation_Next(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation Structured Model Navigation}'. - * - * - * @return the meta object for class 'Structured Model Navigation'. - * @see org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation - * @generated - */ - EClass getStructuredModelNavigation(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation Custom Model Navigation}'. - * - * - * @return the meta object for class 'Custom Model Navigation'. - * @see org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation - * @generated - */ - EClass getCustomModelNavigation(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation Smart Model Navigation}'. - * - * - * @return the meta object for class 'Smart Model Navigation'. - * @see org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation - * @generated - */ - EClass getSmartModelNavigation(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation#getStep Step}'. - * - * - * @return the meta object for the containment reference 'Step'. - * @see org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation#getStep() - * @see #getSmartModelNavigation() - * @generated - */ - EReference getSmartModelNavigation_Step(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.NavigationStep Step}'. - * - * - * @return the meta object for class 'Step'. - * @see org.eclipse.emf.eef.mapping.navigation.NavigationStep - * @generated - */ - EClass getNavigationStep(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.mapping.navigation.NavigationStep#getSubStep Sub Step}'. - * - * - * @return the meta object for the containment reference 'Sub Step'. - * @see org.eclipse.emf.eef.mapping.navigation.NavigationStep#getSubStep() - * @see #getNavigationStep() - * @generated - */ - EReference getNavigationStep_SubStep(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.mapping.navigation.NavigationStep#getInitializer Initializer}'. - * - * - * @return the meta object for the containment reference 'Initializer'. - * @see org.eclipse.emf.eef.mapping.navigation.NavigationStep#getInitializer() - * @see #getNavigationStep() - * @generated - */ - EReference getNavigationStep_Initializer(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.mapping.navigation.NavigationStep#getFilters Filters}'. - * - * - * @return the meta object for the containment reference list 'Filters'. - * @see org.eclipse.emf.eef.mapping.navigation.NavigationStep#getFilters() - * @see #getNavigationStep() - * @generated - */ - EReference getNavigationStep_Filters(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep Declarative Navigation Step}'. - * - * - * @return the meta object for class 'Declarative Navigation Step'. - * @see org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep - * @generated - */ - EClass getDeclarativeNavigationStep(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getIndex Index}'. - * - * - * @return the meta object for the attribute 'Index'. - * @see org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getIndex() - * @see #getDeclarativeNavigationStep() - * @generated - */ - EAttribute getDeclarativeNavigationStep_Index(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getFeature Feature}'. - * - * - * @return the meta object for the reference 'Feature'. - * @see org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getFeature() - * @see #getDeclarativeNavigationStep() - * @generated - */ - EReference getDeclarativeNavigationStep_Feature(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getDiscriminatorType Discriminator Type}'. - * - * - * @return the meta object for the reference 'Discriminator Type'. - * @see org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#getDiscriminatorType() - * @see #getDeclarativeNavigationStep() - * @generated - */ - EReference getDeclarativeNavigationStep_DiscriminatorType(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.StepInitializer Step Initializer}'. - * - * - * @return the meta object for class 'Step Initializer'. - * @see org.eclipse.emf.eef.mapping.navigation.StepInitializer - * @generated - */ - EClass getStepInitializer(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.JavaStepInitializer Java Step Initializer}'. - * - * - * @return the meta object for class 'Java Step Initializer'. - * @see org.eclipse.emf.eef.mapping.navigation.JavaStepInitializer - * @generated - */ - EClass getJavaStepInitializer(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression Java Declaration Expression}'. - * - * - * @return the meta object for class 'Java Declaration Expression'. - * @see org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression - * @generated - */ - EClass getJavaDeclarationExpression(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#getQualifiedClass Qualified Class}'. - * - * - * @return the meta object for the attribute 'Qualified Class'. - * @see org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#getQualifiedClass() - * @see #getJavaDeclarationExpression() - * @generated - */ - EAttribute getJavaDeclarationExpression_QualifiedClass(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#getMethodName Method Name}'. - * - * - * @return the meta object for the attribute 'Method Name'. - * @see org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#getMethodName() - * @see #getJavaDeclarationExpression() - * @generated - */ - EAttribute getJavaDeclarationExpression_MethodName(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#isStaticMethod Static Method}'. - * - * - * @return the meta object for the attribute 'Static Method'. - * @see org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression#isStaticMethod() - * @see #getJavaDeclarationExpression() - * @generated - */ - EAttribute getJavaDeclarationExpression_StaticMethod(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression Java Body Expression}'. - * - * - * @return the meta object for class 'Java Body Expression'. - * @see org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression - * @generated - */ - EClass getJavaBodyExpression(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression#getBody Body}'. - * - * - * @return the meta object for the attribute 'Body'. - * @see org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression#getBody() - * @see #getJavaBodyExpression() - * @generated - */ - EAttribute getJavaBodyExpression_Body(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer Java Declaration Step Initializer}'. - * - * - * @return the meta object for class 'Java Declaration Step Initializer'. - * @see org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer - * @generated - */ - EClass getJavaDeclarationStepInitializer(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer Java Body Step Initializer}'. - * - * - * @return the meta object for class 'Java Body Step Initializer'. - * @see org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer - * @generated - */ - EClass getJavaBodyStepInitializer(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - NavigationFactory getNavigationFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.ModelNavigationImpl Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.ModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getModelNavigation() - * @generated - */ - EClass MODEL_NAVIGATION = eINSTANCE.getModelNavigation(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.SimpleModelNavigationImpl Simple Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.SimpleModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getSimpleModelNavigation() - * @generated - */ - EClass SIMPLE_MODEL_NAVIGATION = eINSTANCE.getSimpleModelNavigation(); - - /** - * The meta object literal for the 'Feature' reference feature. - * - * - * @generated - */ - EReference SIMPLE_MODEL_NAVIGATION__FEATURE = eINSTANCE - .getSimpleModelNavigation_Feature(); - - /** - * The meta object literal for the 'Index' attribute feature. - * - * - * @generated - */ - EAttribute SIMPLE_MODEL_NAVIGATION__INDEX = eINSTANCE - .getSimpleModelNavigation_Index(); - - /** - * The meta object literal for the 'Discriminator Type' reference feature. - * - * - * @generated - */ - EReference SIMPLE_MODEL_NAVIGATION__DISCRIMINATOR_TYPE = eINSTANCE - .getSimpleModelNavigation_DiscriminatorType(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.ChainedModelNavigationImpl Chained Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.ChainedModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getChainedModelNavigation() - * @generated - */ - EClass CHAINED_MODEL_NAVIGATION = eINSTANCE.getChainedModelNavigation(); - - /** - * The meta object literal for the 'Current' containment reference feature. - * - * - * @generated - */ - EReference CHAINED_MODEL_NAVIGATION__CURRENT = eINSTANCE - .getChainedModelNavigation_Current(); - - /** - * The meta object literal for the 'Next' containment reference feature. - * - * - * @generated - */ - EReference CHAINED_MODEL_NAVIGATION__NEXT = eINSTANCE - .getChainedModelNavigation_Next(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.StructuredModelNavigationImpl Structured Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.StructuredModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getStructuredModelNavigation() - * @generated - */ - EClass STRUCTURED_MODEL_NAVIGATION = eINSTANCE - .getStructuredModelNavigation(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.CustomModelNavigationImpl Custom Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.CustomModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getCustomModelNavigation() - * @generated - */ - EClass CUSTOM_MODEL_NAVIGATION = eINSTANCE.getCustomModelNavigation(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.SmartModelNavigationImpl Smart Model Navigation}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.SmartModelNavigationImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getSmartModelNavigation() - * @generated - */ - EClass SMART_MODEL_NAVIGATION = eINSTANCE.getSmartModelNavigation(); - - /** - * The meta object literal for the 'Step' containment reference feature. - * - * - * @generated - */ - EReference SMART_MODEL_NAVIGATION__STEP = eINSTANCE - .getSmartModelNavigation_Step(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.NavigationStepImpl Step}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationStepImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getNavigationStep() - * @generated - */ - EClass NAVIGATION_STEP = eINSTANCE.getNavigationStep(); - - /** - * The meta object literal for the 'Sub Step' containment reference feature. - * - * - * @generated - */ - EReference NAVIGATION_STEP__SUB_STEP = eINSTANCE - .getNavigationStep_SubStep(); - - /** - * The meta object literal for the 'Initializer' containment reference feature. - * - * - * @generated - */ - EReference NAVIGATION_STEP__INITIALIZER = eINSTANCE - .getNavigationStep_Initializer(); - - /** - * The meta object literal for the 'Filters' containment reference list feature. - * - * - * @generated - */ - EReference NAVIGATION_STEP__FILTERS = eINSTANCE - .getNavigationStep_Filters(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.DeclarativeNavigationStepImpl Declarative Navigation Step}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.DeclarativeNavigationStepImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getDeclarativeNavigationStep() - * @generated - */ - EClass DECLARATIVE_NAVIGATION_STEP = eINSTANCE - .getDeclarativeNavigationStep(); - - /** - * The meta object literal for the 'Index' attribute feature. - * - * - * @generated - */ - EAttribute DECLARATIVE_NAVIGATION_STEP__INDEX = eINSTANCE - .getDeclarativeNavigationStep_Index(); - - /** - * The meta object literal for the 'Feature' reference feature. - * - * - * @generated - */ - EReference DECLARATIVE_NAVIGATION_STEP__FEATURE = eINSTANCE - .getDeclarativeNavigationStep_Feature(); - - /** - * The meta object literal for the 'Discriminator Type' reference feature. - * - * - * @generated - */ - EReference DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE = eINSTANCE - .getDeclarativeNavigationStep_DiscriminatorType(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.StepInitializerImpl Step Initializer}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.StepInitializerImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getStepInitializer() - * @generated - */ - EClass STEP_INITIALIZER = eINSTANCE.getStepInitializer(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.JavaStepInitializer Java Step Initializer}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.JavaStepInitializer - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getJavaStepInitializer() - * @generated - */ - EClass JAVA_STEP_INITIALIZER = eINSTANCE.getJavaStepInitializer(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationExpressionImpl Java Declaration Expression}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationExpressionImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getJavaDeclarationExpression() - * @generated - */ - EClass JAVA_DECLARATION_EXPRESSION = eINSTANCE - .getJavaDeclarationExpression(); - - /** - * The meta object literal for the 'Qualified Class' attribute feature. - * - * - * @generated - */ - EAttribute JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS = eINSTANCE - .getJavaDeclarationExpression_QualifiedClass(); - - /** - * The meta object literal for the 'Method Name' attribute feature. - * - * - * @generated - */ - EAttribute JAVA_DECLARATION_EXPRESSION__METHOD_NAME = eINSTANCE - .getJavaDeclarationExpression_MethodName(); - - /** - * The meta object literal for the 'Static Method' attribute feature. - * - * - * @generated - */ - EAttribute JAVA_DECLARATION_EXPRESSION__STATIC_METHOD = eINSTANCE - .getJavaDeclarationExpression_StaticMethod(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.JavaBodyExpressionImpl Java Body Expression}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.JavaBodyExpressionImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getJavaBodyExpression() - * @generated - */ - EClass JAVA_BODY_EXPRESSION = eINSTANCE.getJavaBodyExpression(); - - /** - * The meta object literal for the 'Body' attribute feature. - * - * - * @generated - */ - EAttribute JAVA_BODY_EXPRESSION__BODY = eINSTANCE - .getJavaBodyExpression_Body(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationStepInitializerImpl Java Declaration Step Initializer}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationStepInitializerImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getJavaDeclarationStepInitializer() - * @generated - */ - EClass JAVA_DECLARATION_STEP_INITIALIZER = eINSTANCE - .getJavaDeclarationStepInitializer(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.navigation.impl.JavaBodyStepInitializerImpl Java Body Step Initializer}' class. - * - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.JavaBodyStepInitializerImpl - * @see org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl#getJavaBodyStepInitializer() - * @generated - */ - EClass JAVA_BODY_STEP_INITIALIZER = eINSTANCE - .getJavaBodyStepInitializer(); - - } - -} //NavigationPackage diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationStep.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationStep.java deleted file mode 100644 index 7877394bb..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/NavigationStep.java +++ /dev/null @@ -1,120 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.filters.StepFilter; - -/** - * - * A representation of the model object 'Step'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.NavigationStep#getSubStep Sub Step}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.NavigationStep#getInitializer Initializer}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.NavigationStep#getFilters Filters}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getNavigationStep() - * @model abstract="true" - * @generated - */ -public interface NavigationStep extends EObject { - /** - * Returns the value of the 'Sub Step' containment reference. - * - *

- * If the meaning of the 'Sub Step' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Sub Step' containment reference. - * @see #setSubStep(NavigationStep) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getNavigationStep_SubStep() - * @model containment="true" - * @generated - */ - NavigationStep getSubStep(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.NavigationStep#getSubStep Sub Step}' containment reference. - * - * - * @param value the new value of the 'Sub Step' containment reference. - * @see #getSubStep() - * @generated - */ - void setSubStep(NavigationStep value); - - /** - * Returns the value of the 'Initializer' containment reference. - * - *

- * If the meaning of the 'Initializer' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Initializer' containment reference. - * @see #setInitializer(StepInitializer) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getNavigationStep_Initializer() - * @model containment="true" - * @generated - */ - StepInitializer getInitializer(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.NavigationStep#getInitializer Initializer}' containment reference. - * - * - * @param value the new value of the 'Initializer' containment reference. - * @see #getInitializer() - * @generated - */ - void setInitializer(StepInitializer value); - - /** - * Returns the value of the 'Filters' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.mapping.filters.StepFilter}. - * - *

- * If the meaning of the 'Filters' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Filters' containment reference list. - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getNavigationStep_Filters() - * @model containment="true" - * @generated - */ - EList getFilters(); - - /** - * @return the owning EClass - * @generated NOT - */ - EClass owningEClass(); - - /** - * @return the current EClass - * @generated NOT - */ - EClass currentEClass(); - - /** - * @return the current EClass - * @generated NOT - */ - EClass evaluate(); -} // NavigationStep diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/SimpleModelNavigation.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/SimpleModelNavigation.java deleted file mode 100644 index bef71df10..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/SimpleModelNavigation.java +++ /dev/null @@ -1,126 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EReference; - -/** - * - * A representation of the model object 'Simple Model Navigation'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getFeature Feature}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getIndex Index}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getDiscriminatorType Discriminator Type}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getSimpleModelNavigation() - * @model - * @generated - */ -public interface SimpleModelNavigation extends StructuredModelNavigation { - /** - * Returns the value of the 'Feature' reference. - * - *

- * If the meaning of the 'Feature' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Feature' reference. - * @see #setFeature(EReference) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getSimpleModelNavigation_Feature() - * @model required="true" - * @generated - */ - EReference getFeature(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getFeature Feature}' reference. - * - * - * @param value the new value of the 'Feature' reference. - * @see #getFeature() - * @generated - */ - void setFeature(EReference value); - - /** - * Returns the value of the 'Index' attribute. - * - *

- * If the meaning of the 'Index' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Index' attribute. - * @see #setIndex(int) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getSimpleModelNavigation_Index() - * @model - * @generated - */ - int getIndex(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getIndex Index}' attribute. - * - * - * @param value the new value of the 'Index' attribute. - * @see #getIndex() - * @generated - */ - void setIndex(int value); - - /** - * Returns the value of the 'Discriminator Type' reference. - * - *

- * If the meaning of the 'Discriminator Type' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Discriminator Type' reference. - * @see #setDiscriminatorType(EClassifier) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getSimpleModelNavigation_DiscriminatorType() - * @model - * @generated - */ - EClassifier getDiscriminatorType(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#getDiscriminatorType Discriminator Type}' reference. - * - * - * @param value the new value of the 'Discriminator Type' reference. - * @see #getDiscriminatorType() - * @generated - */ - void setDiscriminatorType(EClassifier value); - - /** - * @return the owning EClass - * @generated NOT - */ - EClass owningEClass(); - - /** - * @return the current EClass - * @generated NOT - */ - EClass targetEClass(); - -} // SimpleModelNavigation diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/SmartModelNavigation.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/SmartModelNavigation.java deleted file mode 100644 index 27dcb70b2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/SmartModelNavigation.java +++ /dev/null @@ -1,52 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation; - -/** - * - * A representation of the model object 'Smart Model Navigation'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation#getStep Step}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getSmartModelNavigation() - * @model - * @generated - */ -public interface SmartModelNavigation extends ModelNavigation { - /** - * Returns the value of the 'Step' containment reference. - * - *

- * If the meaning of the 'Step' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Step' containment reference. - * @see #setStep(NavigationStep) - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getSmartModelNavigation_Step() - * @model containment="true" required="true" - * @generated - */ - NavigationStep getStep(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation#getStep Step}' containment reference. - * - * - * @param value the new value of the 'Step' containment reference. - * @see #getStep() - * @generated - */ - void setStep(NavigationStep value); - -} // SmartModelNavigation diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/StepInitializer.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/StepInitializer.java deleted file mode 100644 index 856d86618..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/StepInitializer.java +++ /dev/null @@ -1,22 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Step Initializer'. - * - * - * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getStepInitializer() - * @model abstract="true" - * @generated - */ -public interface StepInitializer extends EObject { -} // StepInitializer diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/StructuredModelNavigation.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/StructuredModelNavigation.java deleted file mode 100644 index cef606a8b..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/StructuredModelNavigation.java +++ /dev/null @@ -1,34 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation; - -import org.eclipse.emf.ecore.EClass; - -/** - * - * A representation of the model object 'Structured Model Navigation'. - * - * - * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#getStructuredModelNavigation() - * @model abstract="true" - * @generated - */ -public interface StructuredModelNavigation extends ModelNavigation { - /** - * - * - * @model - * @generated - */ - EClass evaluate(); - -} // StructuredModelNavigation diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/ChainedModelNavigationImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/ChainedModelNavigationImpl.java deleted file mode 100644 index 770b06fa3..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/ChainedModelNavigationImpl.java +++ /dev/null @@ -1,343 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation; - -/** - * - * An implementation of the model object 'Chained Model Navigation'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.ChainedModelNavigationImpl#getCurrent Current}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.ChainedModelNavigationImpl#getNext Next}
  • - *
- *

- * - * @generated - */ -public class ChainedModelNavigationImpl extends StructuredModelNavigationImpl - implements ChainedModelNavigation { - /** - * The cached value of the '{@link #getCurrent() Current}' containment reference. - * - * - * @see #getCurrent() - * @generated - * @ordered - */ - protected StructuredModelNavigation current; - - /** - * The cached value of the '{@link #getNext() Next}' containment reference. - * - * - * @see #getNext() - * @generated - * @ordered - */ - protected StructuredModelNavigation next; - - /** - * - * - * @generated - */ - protected ChainedModelNavigationImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.CHAINED_MODEL_NAVIGATION; - } - - /** - * - * - * @generated - */ - public StructuredModelNavigation getCurrent() { - return current; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetCurrent( - StructuredModelNavigation newCurrent, NotificationChain msgs) { - StructuredModelNavigation oldCurrent = current; - current = newCurrent; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - NavigationPackage.CHAINED_MODEL_NAVIGATION__CURRENT, - oldCurrent, newCurrent); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setCurrent(StructuredModelNavigation newCurrent) { - if (newCurrent != current) { - NotificationChain msgs = null; - if (current != null) - msgs = ((InternalEObject) current) - .eInverseRemove( - this, - EOPPOSITE_FEATURE_BASE - - NavigationPackage.CHAINED_MODEL_NAVIGATION__CURRENT, - null, msgs); - if (newCurrent != null) - msgs = ((InternalEObject) newCurrent) - .eInverseAdd( - this, - EOPPOSITE_FEATURE_BASE - - NavigationPackage.CHAINED_MODEL_NAVIGATION__CURRENT, - null, msgs); - msgs = basicSetCurrent(newCurrent, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.CHAINED_MODEL_NAVIGATION__CURRENT, - newCurrent, newCurrent)); - } - - /** - * - * - * @generated - */ - public StructuredModelNavigation getNext() { - return next; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetNext(StructuredModelNavigation newNext, - NotificationChain msgs) { - StructuredModelNavigation oldNext = next; - next = newNext; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - NavigationPackage.CHAINED_MODEL_NAVIGATION__NEXT, oldNext, - newNext); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setNext(StructuredModelNavigation newNext) { - if (newNext != next) { - NotificationChain msgs = null; - if (next != null) - msgs = ((InternalEObject) next) - .eInverseRemove( - this, - EOPPOSITE_FEATURE_BASE - - NavigationPackage.CHAINED_MODEL_NAVIGATION__NEXT, - null, msgs); - if (newNext != null) - msgs = ((InternalEObject) newNext) - .eInverseAdd( - this, - EOPPOSITE_FEATURE_BASE - - NavigationPackage.CHAINED_MODEL_NAVIGATION__NEXT, - null, msgs); - msgs = basicSetNext(newNext, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.CHAINED_MODEL_NAVIGATION__NEXT, newNext, - newNext)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case NavigationPackage.CHAINED_MODEL_NAVIGATION__CURRENT: - return basicSetCurrent(null, msgs); - case NavigationPackage.CHAINED_MODEL_NAVIGATION__NEXT: - return basicSetNext(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case NavigationPackage.CHAINED_MODEL_NAVIGATION__CURRENT: - return getCurrent(); - case NavigationPackage.CHAINED_MODEL_NAVIGATION__NEXT: - return getNext(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case NavigationPackage.CHAINED_MODEL_NAVIGATION__CURRENT: - setCurrent((StructuredModelNavigation) newValue); - return; - case NavigationPackage.CHAINED_MODEL_NAVIGATION__NEXT: - setNext((StructuredModelNavigation) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case NavigationPackage.CHAINED_MODEL_NAVIGATION__CURRENT: - setCurrent((StructuredModelNavigation) null); - return; - case NavigationPackage.CHAINED_MODEL_NAVIGATION__NEXT: - setNext((StructuredModelNavigation) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case NavigationPackage.CHAINED_MODEL_NAVIGATION__CURRENT: - return current != null; - case NavigationPackage.CHAINED_MODEL_NAVIGATION__NEXT: - return next != null; - } - return super.eIsSet(featureID); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.StructuredModelNavigationImpl#evaluate() - * @generated NOT - */ - @Override - public EClass evaluate() { - if (getNext() != null) - return getNext().evaluate(); - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#owningEClass() - * @generated NOT - */ - public EClass owningEClass() { - if (this.eContainer() instanceof EMFPropertyBinding) { - EMFPropertyBinding propertyBinding = (EMFPropertyBinding) this - .eContainer(); - if (propertyBinding.eContainer() instanceof EMFElementBinding) { - EMFElementBinding elementBinding = (EMFElementBinding) propertyBinding - .eContainer(); - if (elementBinding.getModel() instanceof EClass) - return (EClass) elementBinding.getModel(); - } - } else if (eContainer() instanceof ChainedModelNavigation) { - ChainedModelNavigation container = (ChainedModelNavigation) eContainer(); - if (NavigationPackage.eINSTANCE.getChainedModelNavigation_Current() == eContainingFeature()) - return container.owningEClass(); - else if (NavigationPackage.eINSTANCE - .getChainedModelNavigation_Next() == eContainingFeature()) - return container.currentEClass(); - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#currentEClass() - * @generated NOT - */ - public EClass currentEClass() { - if (getCurrent() instanceof SimpleModelNavigation) { - SimpleModelNavigation smn = (SimpleModelNavigation) getCurrent(); - return smn.targetEClass(); - } - return null; - } - -} //ChainedModelNavigationImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/CustomModelNavigationImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/CustomModelNavigationImpl.java deleted file mode 100644 index 6a589f947..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/CustomModelNavigationImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * - * An implementation of the model object 'Custom Model Navigation'. - * - *

- *

- * - * @generated - */ -public class CustomModelNavigationImpl extends ModelNavigationImpl implements - CustomModelNavigation { - /** - * - * - * @generated - */ - protected CustomModelNavigationImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.CUSTOM_MODEL_NAVIGATION; - } - -} //CustomModelNavigationImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/DeclarativeNavigationStepImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/DeclarativeNavigationStepImpl.java deleted file mode 100644 index 0c5e551bb..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/DeclarativeNavigationStepImpl.java +++ /dev/null @@ -1,376 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation; - -/** - * - * An implementation of the model object 'Declarative Navigation Step'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.DeclarativeNavigationStepImpl#getIndex Index}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.DeclarativeNavigationStepImpl#getFeature Feature}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.DeclarativeNavigationStepImpl#getDiscriminatorType Discriminator Type}
  • - *
- *

- * - * @generated - */ -public class DeclarativeNavigationStepImpl extends NavigationStepImpl implements - DeclarativeNavigationStep { - /** - * The default value of the '{@link #getIndex() Index}' attribute. - * - * - * @see #getIndex() - * @generated - * @ordered - */ - protected static final int INDEX_EDEFAULT = 0; - - /** - * The cached value of the '{@link #getIndex() Index}' attribute. - * - * - * @see #getIndex() - * @generated - * @ordered - */ - protected int index = INDEX_EDEFAULT; - - /** - * The cached value of the '{@link #getFeature() Feature}' reference. - * - * - * @see #getFeature() - * @generated - * @ordered - */ - protected EReference feature; - - /** - * The cached value of the '{@link #getDiscriminatorType() Discriminator Type}' reference. - * - * - * @see #getDiscriminatorType() - * @generated - * @ordered - */ - protected EClassifier discriminatorType; - - /** - * - * - * @generated - */ - protected DeclarativeNavigationStepImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.DECLARATIVE_NAVIGATION_STEP; - } - - /** - * - * - * @generated - */ - public int getIndex() { - return index; - } - - /** - * - * - * @generated - */ - public void setIndex(int newIndex) { - int oldIndex = index; - index = newIndex; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.DECLARATIVE_NAVIGATION_STEP__INDEX, - oldIndex, index)); - } - - /** - * - * - * @generated - */ - public EReference getFeature() { - if (feature != null && feature.eIsProxy()) { - InternalEObject oldFeature = (InternalEObject) feature; - feature = (EReference) eResolveProxy(oldFeature); - if (feature != oldFeature) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl( - this, - Notification.RESOLVE, - NavigationPackage.DECLARATIVE_NAVIGATION_STEP__FEATURE, - oldFeature, feature)); - } - } - return feature; - } - - /** - * - * - * @generated - */ - public EReference basicGetFeature() { - return feature; - } - - /** - * - * - * @generated - */ - public void setFeature(EReference newFeature) { - EReference oldFeature = feature; - feature = newFeature; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.DECLARATIVE_NAVIGATION_STEP__FEATURE, - oldFeature, feature)); - } - - /** - * - * - * @generated - */ - public EClassifier getDiscriminatorType() { - if (discriminatorType != null && discriminatorType.eIsProxy()) { - InternalEObject oldDiscriminatorType = (InternalEObject) discriminatorType; - discriminatorType = (EClassifier) eResolveProxy(oldDiscriminatorType); - if (discriminatorType != oldDiscriminatorType) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl( - this, - Notification.RESOLVE, - NavigationPackage.DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE, - oldDiscriminatorType, discriminatorType)); - } - } - return discriminatorType; - } - - /** - * - * - * @generated - */ - public EClassifier basicGetDiscriminatorType() { - return discriminatorType; - } - - /** - * - * - * @generated - */ - public void setDiscriminatorType(EClassifier newDiscriminatorType) { - EClassifier oldDiscriminatorType = discriminatorType; - discriminatorType = newDiscriminatorType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl( - this, - Notification.SET, - NavigationPackage.DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE, - oldDiscriminatorType, discriminatorType)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__INDEX: - return getIndex(); - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__FEATURE: - if (resolve) - return getFeature(); - return basicGetFeature(); - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE: - if (resolve) - return getDiscriminatorType(); - return basicGetDiscriminatorType(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__INDEX: - setIndex((Integer) newValue); - return; - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__FEATURE: - setFeature((EReference) newValue); - return; - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE: - setDiscriminatorType((EClassifier) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__INDEX: - setIndex(INDEX_EDEFAULT); - return; - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__FEATURE: - setFeature((EReference) null); - return; - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE: - setDiscriminatorType((EClassifier) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__INDEX: - return index != INDEX_EDEFAULT; - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__FEATURE: - return feature != null; - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE: - return discriminatorType != null; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (index: "); - result.append(index); - result.append(')'); - return result.toString(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#owningEClass() - * @generated NOT - */ - public EClass owningEClass() { - if (eContainer() instanceof SmartModelNavigation) { - SmartModelNavigation modelNavigation = (SmartModelNavigation) eContainer(); - if (modelNavigation.eContainer() instanceof EMFPropertyBinding) { - EMFPropertyBinding propertyBinding = (EMFPropertyBinding) modelNavigation - .eContainer(); - if (propertyBinding.eContainer() instanceof EMFElementBinding) { - EMFElementBinding elementBinding = (EMFElementBinding) propertyBinding - .eContainer(); - if (elementBinding.getModel() instanceof EClass) - return (EClass) elementBinding.getModel(); - } - } - } - - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep#currentEClass() - * @generated NOT - */ - public EClass currentEClass() { - if (getFeature().getEType() instanceof EClass) { - EClass featureType = (EClass) getFeature().getEType(); - if (getDiscriminatorType() != null - && getDiscriminatorType() instanceof EClass) { - EClass discriminatorType = (EClass) getDiscriminatorType(); - if (featureType.isSuperTypeOf(discriminatorType)) - return discriminatorType; - } - return (EClass) getFeature().getEType(); - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.DeclarativeNavigationStep#evaluate() - * @generated NOT - */ - public EClass evaluate() { - if (getSubStep() != null) { - return getSubStep().evaluate(); - } else if (getFeature() != null - && getFeature().getEType() instanceof EClass) { - EClass featureType = (EClass) getFeature().getEType(); - EClassifier discriminatorType = getDiscriminatorType(); - if (discriminatorType != null - && discriminatorType instanceof EClass) { - if (featureType.isSuperTypeOf((EClass) discriminatorType)) - return (EClass) discriminatorType; - } - return featureType; - } - return null; - } - -} //DeclarativeNavigationStepImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaBodyExpressionImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaBodyExpressionImpl.java deleted file mode 100644 index 52f0ebd40..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaBodyExpressionImpl.java +++ /dev/null @@ -1,171 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; - -import org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * - * An implementation of the model object 'Java Body Expression'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.JavaBodyExpressionImpl#getBody Body}
  • - *
- *

- * - * @generated - */ -public class JavaBodyExpressionImpl extends EObjectImpl implements - JavaBodyExpression { - /** - * The default value of the '{@link #getBody() Body}' attribute. - * - * - * @see #getBody() - * @generated - * @ordered - */ - protected static final String BODY_EDEFAULT = null; - - /** - * The cached value of the '{@link #getBody() Body}' attribute. - * - * - * @see #getBody() - * @generated - * @ordered - */ - protected String body = BODY_EDEFAULT; - - /** - * - * - * @generated - */ - protected JavaBodyExpressionImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.JAVA_BODY_EXPRESSION; - } - - /** - * - * - * @generated - */ - public String getBody() { - return body; - } - - /** - * - * - * @generated - */ - public void setBody(String newBody) { - String oldBody = body; - body = newBody; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.JAVA_BODY_EXPRESSION__BODY, oldBody, body)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case NavigationPackage.JAVA_BODY_EXPRESSION__BODY: - return getBody(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case NavigationPackage.JAVA_BODY_EXPRESSION__BODY: - setBody((String) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case NavigationPackage.JAVA_BODY_EXPRESSION__BODY: - setBody(BODY_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case NavigationPackage.JAVA_BODY_EXPRESSION__BODY: - return BODY_EDEFAULT == null ? body != null : !BODY_EDEFAULT - .equals(body); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (body: "); - result.append(body); - result.append(')'); - return result.toString(); - } - -} //JavaBodyExpressionImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaBodyStepInitializerImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaBodyStepInitializerImpl.java deleted file mode 100644 index 6e61323a8..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaBodyStepInitializerImpl.java +++ /dev/null @@ -1,44 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * - * An implementation of the model object 'Java Body Step Initializer'. - * - *

- *

- * - * @generated - */ -public class JavaBodyStepInitializerImpl extends JavaBodyExpressionImpl - implements JavaBodyStepInitializer { - /** - * - * - * @generated - */ - protected JavaBodyStepInitializerImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.JAVA_BODY_STEP_INITIALIZER; - } - -} //JavaBodyStepInitializerImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaDeclarationExpressionImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaDeclarationExpressionImpl.java deleted file mode 100644 index 9279e0177..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaDeclarationExpressionImpl.java +++ /dev/null @@ -1,289 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; - -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * - * An implementation of the model object 'Java Declaration Expression'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationExpressionImpl#getQualifiedClass Qualified Class}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationExpressionImpl#getMethodName Method Name}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.JavaDeclarationExpressionImpl#isStaticMethod Static Method}
  • - *
- *

- * - * @generated - */ -public abstract class JavaDeclarationExpressionImpl extends EObjectImpl - implements JavaDeclarationExpression { - /** - * The default value of the '{@link #getQualifiedClass() Qualified Class}' attribute. - * - * - * @see #getQualifiedClass() - * @generated - * @ordered - */ - protected static final String QUALIFIED_CLASS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getQualifiedClass() Qualified Class}' attribute. - * - * - * @see #getQualifiedClass() - * @generated - * @ordered - */ - protected String qualifiedClass = QUALIFIED_CLASS_EDEFAULT; - - /** - * The default value of the '{@link #getMethodName() Method Name}' attribute. - * - * - * @see #getMethodName() - * @generated - * @ordered - */ - protected static final String METHOD_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getMethodName() Method Name}' attribute. - * - * - * @see #getMethodName() - * @generated - * @ordered - */ - protected String methodName = METHOD_NAME_EDEFAULT; - - /** - * The default value of the '{@link #isStaticMethod() Static Method}' attribute. - * - * - * @see #isStaticMethod() - * @generated - * @ordered - */ - protected static final boolean STATIC_METHOD_EDEFAULT = false; - - /** - * The cached value of the '{@link #isStaticMethod() Static Method}' attribute. - * - * - * @see #isStaticMethod() - * @generated - * @ordered - */ - protected boolean staticMethod = STATIC_METHOD_EDEFAULT; - - /** - * - * - * @generated - */ - protected JavaDeclarationExpressionImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.JAVA_DECLARATION_EXPRESSION; - } - - /** - * - * - * @generated - */ - public String getQualifiedClass() { - return qualifiedClass; - } - - /** - * - * - * @generated - */ - public void setQualifiedClass(String newQualifiedClass) { - String oldQualifiedClass = qualifiedClass; - qualifiedClass = newQualifiedClass; - if (eNotificationRequired()) - eNotify(new ENotificationImpl( - this, - Notification.SET, - NavigationPackage.JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS, - oldQualifiedClass, qualifiedClass)); - } - - /** - * - * - * @generated - */ - public String getMethodName() { - return methodName; - } - - /** - * - * - * @generated - */ - public void setMethodName(String newMethodName) { - String oldMethodName = methodName; - methodName = newMethodName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.JAVA_DECLARATION_EXPRESSION__METHOD_NAME, - oldMethodName, methodName)); - } - - /** - * - * - * @generated - */ - public boolean isStaticMethod() { - return staticMethod; - } - - /** - * - * - * @generated - */ - public void setStaticMethod(boolean newStaticMethod) { - boolean oldStaticMethod = staticMethod; - staticMethod = newStaticMethod; - if (eNotificationRequired()) - eNotify(new ENotificationImpl( - this, - Notification.SET, - NavigationPackage.JAVA_DECLARATION_EXPRESSION__STATIC_METHOD, - oldStaticMethod, staticMethod)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS: - return getQualifiedClass(); - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__METHOD_NAME: - return getMethodName(); - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__STATIC_METHOD: - return isStaticMethod(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS: - setQualifiedClass((String) newValue); - return; - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__METHOD_NAME: - setMethodName((String) newValue); - return; - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__STATIC_METHOD: - setStaticMethod((Boolean) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS: - setQualifiedClass(QUALIFIED_CLASS_EDEFAULT); - return; - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__METHOD_NAME: - setMethodName(METHOD_NAME_EDEFAULT); - return; - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__STATIC_METHOD: - setStaticMethod(STATIC_METHOD_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS: - return QUALIFIED_CLASS_EDEFAULT == null ? qualifiedClass != null - : !QUALIFIED_CLASS_EDEFAULT.equals(qualifiedClass); - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__METHOD_NAME: - return METHOD_NAME_EDEFAULT == null ? methodName != null - : !METHOD_NAME_EDEFAULT.equals(methodName); - case NavigationPackage.JAVA_DECLARATION_EXPRESSION__STATIC_METHOD: - return staticMethod != STATIC_METHOD_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (qualifiedClass: "); - result.append(qualifiedClass); - result.append(", methodName: "); - result.append(methodName); - result.append(", staticMethod: "); - result.append(staticMethod); - result.append(')'); - return result.toString(); - } - -} //JavaDeclarationExpressionImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaDeclarationStepInitializerImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaDeclarationStepInitializerImpl.java deleted file mode 100644 index f5e03d1c5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/JavaDeclarationStepInitializerImpl.java +++ /dev/null @@ -1,44 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * - * An implementation of the model object 'Java Declaration Step Initializer'. - * - *

- *

- * - * @generated - */ -public class JavaDeclarationStepInitializerImpl extends - JavaDeclarationExpressionImpl implements JavaDeclarationStepInitializer { - /** - * - * - * @generated - */ - protected JavaDeclarationStepInitializerImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.JAVA_DECLARATION_STEP_INITIALIZER; - } - -} //JavaDeclarationStepInitializerImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/ModelNavigationImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/ModelNavigationImpl.java deleted file mode 100644 index 021e65936..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/ModelNavigationImpl.java +++ /dev/null @@ -1,48 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -/** - * - * An implementation of the model object 'Model Navigation'. - * - *

- *

- * - * @generated - */ -public abstract class ModelNavigationImpl extends EObjectImpl implements - ModelNavigation { - /** - * - * - * @generated - */ - protected ModelNavigationImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.MODEL_NAVIGATION; - } - -} //ModelNavigationImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationFactoryImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationFactoryImpl.java deleted file mode 100644 index 893ede9a6..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationFactoryImpl.java +++ /dev/null @@ -1,192 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.impl.EFactoryImpl; -import org.eclipse.emf.ecore.plugin.EcorePlugin; -import org.eclipse.emf.eef.mapping.navigation.*; -import org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationFactory; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class NavigationFactoryImpl extends EFactoryImpl implements - NavigationFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static NavigationFactory init() { - try { - NavigationFactory theNavigationFactory = (NavigationFactory) EPackage.Registry.INSTANCE - .getEFactory("http://www.eclipse.org/emf/eef/mapping/navigation/1.0.0"); - if (theNavigationFactory != null) { - return theNavigationFactory; - } - } catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new NavigationFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public NavigationFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case NavigationPackage.SIMPLE_MODEL_NAVIGATION: - return createSimpleModelNavigation(); - case NavigationPackage.CHAINED_MODEL_NAVIGATION: - return createChainedModelNavigation(); - case NavigationPackage.CUSTOM_MODEL_NAVIGATION: - return createCustomModelNavigation(); - case NavigationPackage.SMART_MODEL_NAVIGATION: - return createSmartModelNavigation(); - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP: - return createDeclarativeNavigationStep(); - case NavigationPackage.JAVA_BODY_EXPRESSION: - return createJavaBodyExpression(); - case NavigationPackage.JAVA_DECLARATION_STEP_INITIALIZER: - return createJavaDeclarationStepInitializer(); - case NavigationPackage.JAVA_BODY_STEP_INITIALIZER: - return createJavaBodyStepInitializer(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() - + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public SimpleModelNavigation createSimpleModelNavigation() { - SimpleModelNavigationImpl simpleModelNavigation = new SimpleModelNavigationImpl(); - return simpleModelNavigation; - } - - /** - * - * - * @generated - */ - public ChainedModelNavigation createChainedModelNavigation() { - ChainedModelNavigationImpl chainedModelNavigation = new ChainedModelNavigationImpl(); - return chainedModelNavigation; - } - - /** - * - * - * @generated - */ - public CustomModelNavigation createCustomModelNavigation() { - CustomModelNavigationImpl customModelNavigation = new CustomModelNavigationImpl(); - return customModelNavigation; - } - - /** - * - * - * @generated - */ - public SmartModelNavigation createSmartModelNavigation() { - SmartModelNavigationImpl smartModelNavigation = new SmartModelNavigationImpl(); - return smartModelNavigation; - } - - /** - * - * - * @generated - */ - public DeclarativeNavigationStep createDeclarativeNavigationStep() { - DeclarativeNavigationStepImpl declarativeNavigationStep = new DeclarativeNavigationStepImpl(); - return declarativeNavigationStep; - } - - /** - * - * - * @generated - */ - public JavaBodyExpression createJavaBodyExpression() { - JavaBodyExpressionImpl javaBodyExpression = new JavaBodyExpressionImpl(); - return javaBodyExpression; - } - - /** - * - * - * @generated - */ - public JavaDeclarationStepInitializer createJavaDeclarationStepInitializer() { - JavaDeclarationStepInitializerImpl javaDeclarationStepInitializer = new JavaDeclarationStepInitializerImpl(); - return javaDeclarationStepInitializer; - } - - /** - * - * - * @generated - */ - public JavaBodyStepInitializer createJavaBodyStepInitializer() { - JavaBodyStepInitializerImpl javaBodyStepInitializer = new JavaBodyStepInitializerImpl(); - return javaBodyStepInitializer; - } - - /** - * - * - * @generated - */ - public NavigationPackage getNavigationPackage() { - return (NavigationPackage) getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static NavigationPackage getPackage() { - return NavigationPackage.eINSTANCE; - } - -} //NavigationFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationPackageImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationPackageImpl.java deleted file mode 100644 index c91cdb04d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationPackageImpl.java +++ /dev/null @@ -1,809 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.impl.EPackageImpl; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; -import org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl; -import org.eclipse.emf.eef.mapping.impl.MappingPackageImpl; -import org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep; -import org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression; -import org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer; -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression; -import org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer; -import org.eclipse.emf.eef.mapping.navigation.JavaStepInitializer; -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationFactory; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.NavigationStep; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.StepInitializer; -import org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation; -import org.eclipse.emf.eef.mapping.settings.SettingsPackage; -import org.eclipse.emf.eef.mapping.settings.impl.SettingsPackageImpl; -import org.eclipse.emf.eef.views.ViewsPackage; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class NavigationPackageImpl extends EPackageImpl implements - NavigationPackage { - /** - * - * - * @generated - */ - private EClass modelNavigationEClass = null; - - /** - * - * - * @generated - */ - private EClass simpleModelNavigationEClass = null; - - /** - * - * - * @generated - */ - private EClass chainedModelNavigationEClass = null; - - /** - * - * - * @generated - */ - private EClass structuredModelNavigationEClass = null; - - /** - * - * - * @generated - */ - private EClass customModelNavigationEClass = null; - - /** - * - * - * @generated - */ - private EClass smartModelNavigationEClass = null; - - /** - * - * - * @generated - */ - private EClass navigationStepEClass = null; - - /** - * - * - * @generated - */ - private EClass declarativeNavigationStepEClass = null; - - /** - * - * - * @generated - */ - private EClass stepInitializerEClass = null; - - /** - * - * - * @generated - */ - private EClass javaStepInitializerEClass = null; - - /** - * - * - * @generated - */ - private EClass javaDeclarationExpressionEClass = null; - - /** - * - * - * @generated - */ - private EClass javaBodyExpressionEClass = null; - - /** - * - * - * @generated - */ - private EClass javaDeclarationStepInitializerEClass = null; - - /** - * - * - * @generated - */ - private EClass javaBodyStepInitializerEClass = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage#eNS_URI - * @see #init() - * @generated - */ - private NavigationPackageImpl() { - super(eNS_URI, NavigationFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link NavigationPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static NavigationPackage init() { - if (isInited) - return (NavigationPackage) EPackage.Registry.INSTANCE - .getEPackage(NavigationPackage.eNS_URI); - - // Obtain or create and register package - NavigationPackageImpl theNavigationPackage = (NavigationPackageImpl) (EPackage.Registry.INSTANCE - .get(eNS_URI) instanceof NavigationPackageImpl ? EPackage.Registry.INSTANCE - .get(eNS_URI) : new NavigationPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - EcorePackage.eINSTANCE.eClass(); - ViewsPackage.eINSTANCE.eClass(); - - // Obtain or create and register interdependencies - MappingPackageImpl theMappingPackage = (MappingPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(MappingPackage.eNS_URI) instanceof MappingPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(MappingPackage.eNS_URI) : MappingPackage.eINSTANCE); - FiltersPackageImpl theFiltersPackage = (FiltersPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(FiltersPackage.eNS_URI) instanceof FiltersPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(FiltersPackage.eNS_URI) : FiltersPackage.eINSTANCE); - SettingsPackageImpl theSettingsPackage = (SettingsPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(SettingsPackage.eNS_URI) instanceof SettingsPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(SettingsPackage.eNS_URI) - : SettingsPackage.eINSTANCE); - - // Create package meta-data objects - theNavigationPackage.createPackageContents(); - theMappingPackage.createPackageContents(); - theFiltersPackage.createPackageContents(); - theSettingsPackage.createPackageContents(); - - // Initialize created meta-data - theNavigationPackage.initializePackageContents(); - theMappingPackage.initializePackageContents(); - theFiltersPackage.initializePackageContents(); - theSettingsPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theNavigationPackage.freeze(); - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(NavigationPackage.eNS_URI, - theNavigationPackage); - return theNavigationPackage; - } - - /** - * - * - * @generated - */ - public EClass getModelNavigation() { - return modelNavigationEClass; - } - - /** - * - * - * @generated - */ - public EClass getSimpleModelNavigation() { - return simpleModelNavigationEClass; - } - - /** - * - * - * @generated - */ - public EReference getSimpleModelNavigation_Feature() { - return (EReference) simpleModelNavigationEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EAttribute getSimpleModelNavigation_Index() { - return (EAttribute) simpleModelNavigationEClass - .getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EReference getSimpleModelNavigation_DiscriminatorType() { - return (EReference) simpleModelNavigationEClass - .getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EClass getChainedModelNavigation() { - return chainedModelNavigationEClass; - } - - /** - * - * - * @generated - */ - public EReference getChainedModelNavigation_Current() { - return (EReference) chainedModelNavigationEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getChainedModelNavigation_Next() { - return (EReference) chainedModelNavigationEClass - .getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getStructuredModelNavigation() { - return structuredModelNavigationEClass; - } - - /** - * - * - * @generated - */ - public EClass getCustomModelNavigation() { - return customModelNavigationEClass; - } - - /** - * - * - * @generated - */ - public EClass getSmartModelNavigation() { - return smartModelNavigationEClass; - } - - /** - * - * - * @generated - */ - public EReference getSmartModelNavigation_Step() { - return (EReference) smartModelNavigationEClass.getEStructuralFeatures() - .get(0); - } - - /** - * - * - * @generated - */ - public EClass getNavigationStep() { - return navigationStepEClass; - } - - /** - * - * - * @generated - */ - public EReference getNavigationStep_SubStep() { - return (EReference) navigationStepEClass.getEStructuralFeatures() - .get(0); - } - - /** - * - * - * @generated - */ - public EReference getNavigationStep_Initializer() { - return (EReference) navigationStepEClass.getEStructuralFeatures() - .get(1); - } - - /** - * - * - * @generated - */ - public EReference getNavigationStep_Filters() { - return (EReference) navigationStepEClass.getEStructuralFeatures() - .get(2); - } - - /** - * - * - * @generated - */ - public EClass getDeclarativeNavigationStep() { - return declarativeNavigationStepEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getDeclarativeNavigationStep_Index() { - return (EAttribute) declarativeNavigationStepEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getDeclarativeNavigationStep_Feature() { - return (EReference) declarativeNavigationStepEClass - .getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EReference getDeclarativeNavigationStep_DiscriminatorType() { - return (EReference) declarativeNavigationStepEClass - .getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EClass getStepInitializer() { - return stepInitializerEClass; - } - - /** - * - * - * @generated - */ - public EClass getJavaStepInitializer() { - return javaStepInitializerEClass; - } - - /** - * - * - * @generated - */ - public EClass getJavaDeclarationExpression() { - return javaDeclarationExpressionEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getJavaDeclarationExpression_QualifiedClass() { - return (EAttribute) javaDeclarationExpressionEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EAttribute getJavaDeclarationExpression_MethodName() { - return (EAttribute) javaDeclarationExpressionEClass - .getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EAttribute getJavaDeclarationExpression_StaticMethod() { - return (EAttribute) javaDeclarationExpressionEClass - .getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EClass getJavaBodyExpression() { - return javaBodyExpressionEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getJavaBodyExpression_Body() { - return (EAttribute) javaBodyExpressionEClass.getEStructuralFeatures() - .get(0); - } - - /** - * - * - * @generated - */ - public EClass getJavaDeclarationStepInitializer() { - return javaDeclarationStepInitializerEClass; - } - - /** - * - * - * @generated - */ - public EClass getJavaBodyStepInitializer() { - return javaBodyStepInitializerEClass; - } - - /** - * - * - * @generated - */ - public NavigationFactory getNavigationFactory() { - return (NavigationFactory) getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) - return; - isCreated = true; - - // Create classes and their features - modelNavigationEClass = createEClass(MODEL_NAVIGATION); - - simpleModelNavigationEClass = createEClass(SIMPLE_MODEL_NAVIGATION); - createEReference(simpleModelNavigationEClass, - SIMPLE_MODEL_NAVIGATION__FEATURE); - createEAttribute(simpleModelNavigationEClass, - SIMPLE_MODEL_NAVIGATION__INDEX); - createEReference(simpleModelNavigationEClass, - SIMPLE_MODEL_NAVIGATION__DISCRIMINATOR_TYPE); - - chainedModelNavigationEClass = createEClass(CHAINED_MODEL_NAVIGATION); - createEReference(chainedModelNavigationEClass, - CHAINED_MODEL_NAVIGATION__CURRENT); - createEReference(chainedModelNavigationEClass, - CHAINED_MODEL_NAVIGATION__NEXT); - - structuredModelNavigationEClass = createEClass(STRUCTURED_MODEL_NAVIGATION); - - customModelNavigationEClass = createEClass(CUSTOM_MODEL_NAVIGATION); - - smartModelNavigationEClass = createEClass(SMART_MODEL_NAVIGATION); - createEReference(smartModelNavigationEClass, - SMART_MODEL_NAVIGATION__STEP); - - navigationStepEClass = createEClass(NAVIGATION_STEP); - createEReference(navigationStepEClass, NAVIGATION_STEP__SUB_STEP); - createEReference(navigationStepEClass, NAVIGATION_STEP__INITIALIZER); - createEReference(navigationStepEClass, NAVIGATION_STEP__FILTERS); - - declarativeNavigationStepEClass = createEClass(DECLARATIVE_NAVIGATION_STEP); - createEAttribute(declarativeNavigationStepEClass, - DECLARATIVE_NAVIGATION_STEP__INDEX); - createEReference(declarativeNavigationStepEClass, - DECLARATIVE_NAVIGATION_STEP__FEATURE); - createEReference(declarativeNavigationStepEClass, - DECLARATIVE_NAVIGATION_STEP__DISCRIMINATOR_TYPE); - - stepInitializerEClass = createEClass(STEP_INITIALIZER); - - javaStepInitializerEClass = createEClass(JAVA_STEP_INITIALIZER); - - javaDeclarationExpressionEClass = createEClass(JAVA_DECLARATION_EXPRESSION); - createEAttribute(javaDeclarationExpressionEClass, - JAVA_DECLARATION_EXPRESSION__QUALIFIED_CLASS); - createEAttribute(javaDeclarationExpressionEClass, - JAVA_DECLARATION_EXPRESSION__METHOD_NAME); - createEAttribute(javaDeclarationExpressionEClass, - JAVA_DECLARATION_EXPRESSION__STATIC_METHOD); - - javaBodyExpressionEClass = createEClass(JAVA_BODY_EXPRESSION); - createEAttribute(javaBodyExpressionEClass, JAVA_BODY_EXPRESSION__BODY); - - javaDeclarationStepInitializerEClass = createEClass(JAVA_DECLARATION_STEP_INITIALIZER); - - javaBodyStepInitializerEClass = createEClass(JAVA_BODY_STEP_INITIALIZER); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) - return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - FiltersPackage theFiltersPackage = (FiltersPackage) EPackage.Registry.INSTANCE - .getEPackage(FiltersPackage.eNS_URI); - EcorePackage theEcorePackage = (EcorePackage) EPackage.Registry.INSTANCE - .getEPackage(EcorePackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - simpleModelNavigationEClass.getESuperTypes().add( - this.getStructuredModelNavigation()); - chainedModelNavigationEClass.getESuperTypes().add( - this.getStructuredModelNavigation()); - structuredModelNavigationEClass.getESuperTypes().add( - this.getModelNavigation()); - customModelNavigationEClass.getESuperTypes().add( - this.getModelNavigation()); - smartModelNavigationEClass.getESuperTypes().add( - this.getModelNavigation()); - declarativeNavigationStepEClass.getESuperTypes().add( - this.getNavigationStep()); - javaStepInitializerEClass.getESuperTypes().add( - this.getStepInitializer()); - javaDeclarationStepInitializerEClass.getESuperTypes().add( - this.getJavaDeclarationExpression()); - javaDeclarationStepInitializerEClass.getESuperTypes().add( - this.getJavaStepInitializer()); - javaBodyStepInitializerEClass.getESuperTypes().add( - this.getJavaBodyExpression()); - javaBodyStepInitializerEClass.getESuperTypes().add( - this.getJavaStepInitializer()); - - // Initialize classes and features; add operations and parameters - initEClass(modelNavigationEClass, ModelNavigation.class, - "ModelNavigation", IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - - initEClass(simpleModelNavigationEClass, SimpleModelNavigation.class, - "SimpleModelNavigation", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEReference(getSimpleModelNavigation_Feature(), - ecorePackage.getEReference(), null, "feature", null, 1, 1, - SimpleModelNavigation.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getSimpleModelNavigation_Index(), - ecorePackage.getEInt(), "index", null, 0, 1, - SimpleModelNavigation.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEReference(getSimpleModelNavigation_DiscriminatorType(), - ecorePackage.getEClassifier(), null, "discriminatorType", null, - 0, 1, SimpleModelNavigation.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(chainedModelNavigationEClass, ChainedModelNavigation.class, - "ChainedModelNavigation", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEReference(getChainedModelNavigation_Current(), - this.getStructuredModelNavigation(), null, "current", null, 1, - 1, ChainedModelNavigation.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getChainedModelNavigation_Next(), - this.getStructuredModelNavigation(), null, "next", null, 1, 1, - ChainedModelNavigation.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(structuredModelNavigationEClass, - StructuredModelNavigation.class, "StructuredModelNavigation", - IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - addEOperation(structuredModelNavigationEClass, - ecorePackage.getEClass(), "evaluate", 0, 1, IS_UNIQUE, - IS_ORDERED); - - initEClass(customModelNavigationEClass, CustomModelNavigation.class, - "CustomModelNavigation", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - - initEClass(smartModelNavigationEClass, SmartModelNavigation.class, - "SmartModelNavigation", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEReference(getSmartModelNavigation_Step(), - this.getNavigationStep(), null, "step", null, 1, 1, - SmartModelNavigation.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(navigationStepEClass, NavigationStep.class, - "NavigationStep", IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEReference(getNavigationStep_SubStep(), this.getNavigationStep(), - null, "subStep", null, 0, 1, NavigationStep.class, - !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, - !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEReference(getNavigationStep_Initializer(), - this.getStepInitializer(), null, "initializer", null, 0, 1, - NavigationStep.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getNavigationStep_Filters(), - theFiltersPackage.getStepFilter(), null, "filters", null, 0, - -1, NavigationStep.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(declarativeNavigationStepEClass, - DeclarativeNavigationStep.class, "DeclarativeNavigationStep", - !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getDeclarativeNavigationStep_Index(), - theEcorePackage.getEInt(), "index", null, 0, 1, - DeclarativeNavigationStep.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEReference(getDeclarativeNavigationStep_Feature(), - ecorePackage.getEReference(), null, "feature", null, 1, 1, - DeclarativeNavigationStep.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getDeclarativeNavigationStep_DiscriminatorType(), - ecorePackage.getEClassifier(), null, "discriminatorType", null, - 0, 1, DeclarativeNavigationStep.class, !IS_TRANSIENT, - !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(stepInitializerEClass, StepInitializer.class, - "StepInitializer", IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - - initEClass(javaStepInitializerEClass, JavaStepInitializer.class, - "JavaStepInitializer", IS_ABSTRACT, IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - - initEClass(javaDeclarationExpressionEClass, - JavaDeclarationExpression.class, "JavaDeclarationExpression", - IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getJavaDeclarationExpression_QualifiedClass(), - theEcorePackage.getEString(), "qualifiedClass", null, 1, 1, - JavaDeclarationExpression.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEAttribute(getJavaDeclarationExpression_MethodName(), - theEcorePackage.getEString(), "methodName", null, 1, 1, - JavaDeclarationExpression.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - initEAttribute(getJavaDeclarationExpression_StaticMethod(), - theEcorePackage.getEBoolean(), "staticMethod", null, 0, 1, - JavaDeclarationExpression.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - - initEClass(javaBodyExpressionEClass, JavaBodyExpression.class, - "JavaBodyExpression", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getJavaBodyExpression_Body(), - theEcorePackage.getEString(), "body", null, 1, 1, - JavaBodyExpression.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, - IS_ORDERED); - - initEClass(javaDeclarationStepInitializerEClass, - JavaDeclarationStepInitializer.class, - "JavaDeclarationStepInitializer", !IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - - initEClass(javaBodyStepInitializerEClass, - JavaBodyStepInitializer.class, "JavaBodyStepInitializer", - !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - } - -} //NavigationPackageImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationStepImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationStepImpl.java deleted file mode 100644 index a8e706e2a..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/NavigationStepImpl.java +++ /dev/null @@ -1,330 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; - -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.InternalEList; - -import org.eclipse.emf.eef.mapping.filters.StepFilter; - -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.NavigationStep; -import org.eclipse.emf.eef.mapping.navigation.StepInitializer; - -/** - * - * An implementation of the model object 'Step'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.NavigationStepImpl#getSubStep Sub Step}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.NavigationStepImpl#getInitializer Initializer}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.NavigationStepImpl#getFilters Filters}
  • - *
- *

- * - * @generated - */ -public abstract class NavigationStepImpl extends EObjectImpl implements - NavigationStep { - /** - * The cached value of the '{@link #getSubStep() Sub Step}' containment reference. - * - * - * @see #getSubStep() - * @generated - * @ordered - */ - protected NavigationStep subStep; - - /** - * The cached value of the '{@link #getInitializer() Initializer}' containment reference. - * - * - * @see #getInitializer() - * @generated - * @ordered - */ - protected StepInitializer initializer; - - /** - * The cached value of the '{@link #getFilters() Filters}' containment reference list. - * - * - * @see #getFilters() - * @generated - * @ordered - */ - protected EList filters; - - /** - * - * - * @generated - */ - protected NavigationStepImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.NAVIGATION_STEP; - } - - /** - * - * - * @generated - */ - public NavigationStep getSubStep() { - return subStep; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetSubStep(NavigationStep newSubStep, - NotificationChain msgs) { - NavigationStep oldSubStep = subStep; - subStep = newSubStep; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - NavigationPackage.NAVIGATION_STEP__SUB_STEP, oldSubStep, - newSubStep); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setSubStep(NavigationStep newSubStep) { - if (newSubStep != subStep) { - NotificationChain msgs = null; - if (subStep != null) - msgs = ((InternalEObject) subStep).eInverseRemove(this, - EOPPOSITE_FEATURE_BASE - - NavigationPackage.NAVIGATION_STEP__SUB_STEP, - null, msgs); - if (newSubStep != null) - msgs = ((InternalEObject) newSubStep).eInverseAdd(this, - EOPPOSITE_FEATURE_BASE - - NavigationPackage.NAVIGATION_STEP__SUB_STEP, - null, msgs); - msgs = basicSetSubStep(newSubStep, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.NAVIGATION_STEP__SUB_STEP, newSubStep, - newSubStep)); - } - - /** - * - * - * @generated - */ - public StepInitializer getInitializer() { - return initializer; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetInitializer( - StepInitializer newInitializer, NotificationChain msgs) { - StepInitializer oldInitializer = initializer; - initializer = newInitializer; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - NavigationPackage.NAVIGATION_STEP__INITIALIZER, - oldInitializer, newInitializer); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setInitializer(StepInitializer newInitializer) { - if (newInitializer != initializer) { - NotificationChain msgs = null; - if (initializer != null) - msgs = ((InternalEObject) initializer) - .eInverseRemove( - this, - EOPPOSITE_FEATURE_BASE - - NavigationPackage.NAVIGATION_STEP__INITIALIZER, - null, msgs); - if (newInitializer != null) - msgs = ((InternalEObject) newInitializer) - .eInverseAdd( - this, - EOPPOSITE_FEATURE_BASE - - NavigationPackage.NAVIGATION_STEP__INITIALIZER, - null, msgs); - msgs = basicSetInitializer(newInitializer, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.NAVIGATION_STEP__INITIALIZER, - newInitializer, newInitializer)); - } - - /** - * - * - * @generated - */ - public EList getFilters() { - if (filters == null) { - filters = new EObjectContainmentEList(StepFilter.class, - this, NavigationPackage.NAVIGATION_STEP__FILTERS); - } - return filters; - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case NavigationPackage.NAVIGATION_STEP__SUB_STEP: - return basicSetSubStep(null, msgs); - case NavigationPackage.NAVIGATION_STEP__INITIALIZER: - return basicSetInitializer(null, msgs); - case NavigationPackage.NAVIGATION_STEP__FILTERS: - return ((InternalEList) getFilters()) - .basicRemove(otherEnd, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case NavigationPackage.NAVIGATION_STEP__SUB_STEP: - return getSubStep(); - case NavigationPackage.NAVIGATION_STEP__INITIALIZER: - return getInitializer(); - case NavigationPackage.NAVIGATION_STEP__FILTERS: - return getFilters(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case NavigationPackage.NAVIGATION_STEP__SUB_STEP: - setSubStep((NavigationStep) newValue); - return; - case NavigationPackage.NAVIGATION_STEP__INITIALIZER: - setInitializer((StepInitializer) newValue); - return; - case NavigationPackage.NAVIGATION_STEP__FILTERS: - getFilters().clear(); - getFilters().addAll((Collection) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case NavigationPackage.NAVIGATION_STEP__SUB_STEP: - setSubStep((NavigationStep) null); - return; - case NavigationPackage.NAVIGATION_STEP__INITIALIZER: - setInitializer((StepInitializer) null); - return; - case NavigationPackage.NAVIGATION_STEP__FILTERS: - getFilters().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case NavigationPackage.NAVIGATION_STEP__SUB_STEP: - return subStep != null; - case NavigationPackage.NAVIGATION_STEP__INITIALIZER: - return initializer != null; - case NavigationPackage.NAVIGATION_STEP__FILTERS: - return filters != null && !filters.isEmpty(); - } - return super.eIsSet(featureID); - } - -} //NavigationStepImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/SimpleModelNavigationImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/SimpleModelNavigationImpl.java deleted file mode 100644 index 67bc27b67..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/SimpleModelNavigationImpl.java +++ /dev/null @@ -1,377 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; - -/** - * - * An implementation of the model object 'Simple Model Navigation'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.SimpleModelNavigationImpl#getFeature Feature}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.SimpleModelNavigationImpl#getIndex Index}
  • - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.SimpleModelNavigationImpl#getDiscriminatorType Discriminator Type}
  • - *
- *

- * - * @generated - */ -public class SimpleModelNavigationImpl extends StructuredModelNavigationImpl - implements SimpleModelNavigation { - /** - * The cached value of the '{@link #getFeature() Feature}' reference. - * - * - * @see #getFeature() - * @generated - * @ordered - */ - protected EReference feature; - - /** - * The default value of the '{@link #getIndex() Index}' attribute. - * - * - * @see #getIndex() - * @generated - * @ordered - */ - protected static final int INDEX_EDEFAULT = 0; - - /** - * The cached value of the '{@link #getIndex() Index}' attribute. - * - * - * @see #getIndex() - * @generated - * @ordered - */ - protected int index = INDEX_EDEFAULT; - - /** - * The cached value of the '{@link #getDiscriminatorType() Discriminator Type}' reference. - * - * - * @see #getDiscriminatorType() - * @generated - * @ordered - */ - protected EClassifier discriminatorType; - - /** - * - * - * @generated - */ - protected SimpleModelNavigationImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.SIMPLE_MODEL_NAVIGATION; - } - - /** - * - * - * @generated - */ - public EReference getFeature() { - if (feature != null && feature.eIsProxy()) { - InternalEObject oldFeature = (InternalEObject) feature; - feature = (EReference) eResolveProxy(oldFeature); - if (feature != oldFeature) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - NavigationPackage.SIMPLE_MODEL_NAVIGATION__FEATURE, - oldFeature, feature)); - } - } - return feature; - } - - /** - * - * - * @generated - */ - public EReference basicGetFeature() { - return feature; - } - - /** - * - * - * @generated - */ - public void setFeature(EReference newFeature) { - EReference oldFeature = feature; - feature = newFeature; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.SIMPLE_MODEL_NAVIGATION__FEATURE, - oldFeature, feature)); - } - - /** - * - * - * @generated - */ - public int getIndex() { - return index; - } - - /** - * - * - * @generated - */ - public void setIndex(int newIndex) { - int oldIndex = index; - index = newIndex; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.SIMPLE_MODEL_NAVIGATION__INDEX, oldIndex, - index)); - } - - /** - * - * - * @generated - */ - public EClassifier getDiscriminatorType() { - if (discriminatorType != null && discriminatorType.eIsProxy()) { - InternalEObject oldDiscriminatorType = (InternalEObject) discriminatorType; - discriminatorType = (EClassifier) eResolveProxy(oldDiscriminatorType); - if (discriminatorType != oldDiscriminatorType) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl( - this, - Notification.RESOLVE, - NavigationPackage.SIMPLE_MODEL_NAVIGATION__DISCRIMINATOR_TYPE, - oldDiscriminatorType, discriminatorType)); - } - } - return discriminatorType; - } - - /** - * - * - * @generated - */ - public EClassifier basicGetDiscriminatorType() { - return discriminatorType; - } - - /** - * - * - * @generated - */ - public void setDiscriminatorType(EClassifier newDiscriminatorType) { - EClassifier oldDiscriminatorType = discriminatorType; - discriminatorType = newDiscriminatorType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl( - this, - Notification.SET, - NavigationPackage.SIMPLE_MODEL_NAVIGATION__DISCRIMINATOR_TYPE, - oldDiscriminatorType, discriminatorType)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__FEATURE: - if (resolve) - return getFeature(); - return basicGetFeature(); - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__INDEX: - return getIndex(); - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__DISCRIMINATOR_TYPE: - if (resolve) - return getDiscriminatorType(); - return basicGetDiscriminatorType(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__FEATURE: - setFeature((EReference) newValue); - return; - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__INDEX: - setIndex((Integer) newValue); - return; - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__DISCRIMINATOR_TYPE: - setDiscriminatorType((EClassifier) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__FEATURE: - setFeature((EReference) null); - return; - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__INDEX: - setIndex(INDEX_EDEFAULT); - return; - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__DISCRIMINATOR_TYPE: - setDiscriminatorType((EClassifier) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__FEATURE: - return feature != null; - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__INDEX: - return index != INDEX_EDEFAULT; - case NavigationPackage.SIMPLE_MODEL_NAVIGATION__DISCRIMINATOR_TYPE: - return discriminatorType != null; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (index: "); - result.append(index); - result.append(')'); - return result.toString(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.navigation.impl.StructuredModelNavigationImpl#evaluate() - * @generated NOT - */ - public EClass evaluate() { - if (getFeature() != null && getFeature().getEType() instanceof EClass) { - EClass featureType = (EClass) getFeature().getEType(); - EClassifier discriminatorType = getDiscriminatorType(); - if (discriminatorType != null - && discriminatorType instanceof EClass) { - if (featureType.isSuperTypeOf((EClass) discriminatorType)) - return (EClass) discriminatorType; - } - return featureType; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation#owningEClass() - * @generated NOT - */ - public EClass owningEClass() { - if (eContainer() instanceof EMFPropertyBinding) { - EMFPropertyBinding propertyBinding = (EMFPropertyBinding) eContainer(); - if (propertyBinding.eContainer() instanceof EMFElementBinding) { - EMFElementBinding elementBinding = (EMFElementBinding) propertyBinding - .eContainer(); - if (elementBinding.getModel() instanceof EClass) - return (EClass) elementBinding.getModel(); - } - } else if (eContainer() instanceof ChainedModelNavigation) { - ChainedModelNavigation container = (ChainedModelNavigation) eContainer(); - if (NavigationPackage.eINSTANCE.getChainedModelNavigation_Current() == eContainingFeature()) - return container.owningEClass(); - else if (NavigationPackage.eINSTANCE - .getChainedModelNavigation_Next() == eContainingFeature()) - return container.currentEClass(); - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation#targetEClass() - * @generated NOT - */ - public EClass targetEClass() { - if (getFeature().getEType() instanceof EClass) { - EClass featureType = (EClass) getFeature().getEType(); - if (getDiscriminatorType() != null - && getDiscriminatorType() instanceof EClass) { - EClass discriminatorType = (EClass) getDiscriminatorType(); - if (featureType.isSuperTypeOf(discriminatorType)) - return discriminatorType; - } - return (EClass) getFeature().getEType(); - } - return null; - } - -} //SimpleModelNavigationImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/SmartModelNavigationImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/SmartModelNavigationImpl.java deleted file mode 100644 index 01d58f123..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/SmartModelNavigationImpl.java +++ /dev/null @@ -1,200 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.NavigationStep; -import org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation; - -/** - * - * An implementation of the model object 'Smart Model Navigation'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.navigation.impl.SmartModelNavigationImpl#getStep Step}
  • - *
- *

- * - * @generated - */ -public class SmartModelNavigationImpl extends ModelNavigationImpl implements - SmartModelNavigation { - /** - * The cached value of the '{@link #getStep() Step}' containment reference. - * - * - * @see #getStep() - * @generated - * @ordered - */ - protected NavigationStep step; - - /** - * - * - * @generated - */ - protected SmartModelNavigationImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.SMART_MODEL_NAVIGATION; - } - - /** - * - * - * @generated - */ - public NavigationStep getStep() { - return step; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetStep(NavigationStep newStep, - NotificationChain msgs) { - NavigationStep oldStep = step; - step = newStep; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - NavigationPackage.SMART_MODEL_NAVIGATION__STEP, oldStep, - newStep); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setStep(NavigationStep newStep) { - if (newStep != step) { - NotificationChain msgs = null; - if (step != null) - msgs = ((InternalEObject) step) - .eInverseRemove( - this, - EOPPOSITE_FEATURE_BASE - - NavigationPackage.SMART_MODEL_NAVIGATION__STEP, - null, msgs); - if (newStep != null) - msgs = ((InternalEObject) newStep) - .eInverseAdd( - this, - EOPPOSITE_FEATURE_BASE - - NavigationPackage.SMART_MODEL_NAVIGATION__STEP, - null, msgs); - msgs = basicSetStep(newStep, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - NavigationPackage.SMART_MODEL_NAVIGATION__STEP, newStep, - newStep)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case NavigationPackage.SMART_MODEL_NAVIGATION__STEP: - return basicSetStep(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case NavigationPackage.SMART_MODEL_NAVIGATION__STEP: - return getStep(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case NavigationPackage.SMART_MODEL_NAVIGATION__STEP: - setStep((NavigationStep) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case NavigationPackage.SMART_MODEL_NAVIGATION__STEP: - setStep((NavigationStep) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case NavigationPackage.SMART_MODEL_NAVIGATION__STEP: - return step != null; - } - return super.eIsSet(featureID); - } - -} //SmartModelNavigationImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/StepInitializerImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/StepInitializerImpl.java deleted file mode 100644 index 0e8f1b17d..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/StepInitializerImpl.java +++ /dev/null @@ -1,46 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.EObjectImpl; - -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.StepInitializer; - -/** - * - * An implementation of the model object 'Step Initializer'. - * - *

- *

- * - * @generated - */ -public abstract class StepInitializerImpl extends EObjectImpl implements - StepInitializer { - /** - * - * - * @generated - */ - protected StepInitializerImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.STEP_INITIALIZER; - } - -} //StepInitializerImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/StructuredModelNavigationImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/StructuredModelNavigationImpl.java deleted file mode 100644 index 233b4eb08..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/impl/StructuredModelNavigationImpl.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation; - -/** - * - * An implementation of the model object 'Structured Model Navigation'. - * - *

- *

- * - * @generated - */ -public abstract class StructuredModelNavigationImpl extends ModelNavigationImpl - implements StructuredModelNavigation { - /** - * - * - * @generated - */ - protected StructuredModelNavigationImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return NavigationPackage.Literals.STRUCTURED_MODEL_NAVIGATION; - } - - /** - * - * - * @generated NOT - */ - public abstract EClass evaluate(); - -} //StructuredModelNavigationImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/util/NavigationAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/util/NavigationAdapterFactory.java deleted file mode 100644 index b6735eda2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/util/NavigationAdapterFactory.java +++ /dev/null @@ -1,382 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.mapping.navigation.*; -import org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage - * @generated - */ -public class NavigationAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static NavigationPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public NavigationAdapterFactory() { - if (modelPackage == null) { - modelPackage = NavigationPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject) object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected NavigationSwitch modelSwitch = new NavigationSwitch() { - @Override - public Adapter caseModelNavigation(ModelNavigation object) { - return createModelNavigationAdapter(); - } - - @Override - public Adapter caseSimpleModelNavigation(SimpleModelNavigation object) { - return createSimpleModelNavigationAdapter(); - } - - @Override - public Adapter caseChainedModelNavigation(ChainedModelNavigation object) { - return createChainedModelNavigationAdapter(); - } - - @Override - public Adapter caseStructuredModelNavigation( - StructuredModelNavigation object) { - return createStructuredModelNavigationAdapter(); - } - - @Override - public Adapter caseCustomModelNavigation(CustomModelNavigation object) { - return createCustomModelNavigationAdapter(); - } - - @Override - public Adapter caseSmartModelNavigation(SmartModelNavigation object) { - return createSmartModelNavigationAdapter(); - } - - @Override - public Adapter caseNavigationStep(NavigationStep object) { - return createNavigationStepAdapter(); - } - - @Override - public Adapter caseDeclarativeNavigationStep( - DeclarativeNavigationStep object) { - return createDeclarativeNavigationStepAdapter(); - } - - @Override - public Adapter caseStepInitializer(StepInitializer object) { - return createStepInitializerAdapter(); - } - - @Override - public Adapter caseJavaStepInitializer(JavaStepInitializer object) { - return createJavaStepInitializerAdapter(); - } - - @Override - public Adapter caseJavaDeclarationExpression( - JavaDeclarationExpression object) { - return createJavaDeclarationExpressionAdapter(); - } - - @Override - public Adapter caseJavaBodyExpression(JavaBodyExpression object) { - return createJavaBodyExpressionAdapter(); - } - - @Override - public Adapter caseJavaDeclarationStepInitializer( - JavaDeclarationStepInitializer object) { - return createJavaDeclarationStepInitializerAdapter(); - } - - @Override - public Adapter caseJavaBodyStepInitializer( - JavaBodyStepInitializer object) { - return createJavaBodyStepInitializerAdapter(); - } - - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject) target); - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.ModelNavigation Model Navigation}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.ModelNavigation - * @generated - */ - public Adapter createModelNavigationAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation Simple Model Navigation}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation - * @generated - */ - public Adapter createSimpleModelNavigationAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation Chained Model Navigation}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation - * @generated - */ - public Adapter createChainedModelNavigationAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation Structured Model Navigation}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation - * @generated - */ - public Adapter createStructuredModelNavigationAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation Custom Model Navigation}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation - * @generated - */ - public Adapter createCustomModelNavigationAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation Smart Model Navigation}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.SmartModelNavigation - * @generated - */ - public Adapter createSmartModelNavigationAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.NavigationStep Step}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.NavigationStep - * @generated - */ - public Adapter createNavigationStepAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep Declarative Navigation Step}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.DeclarativeNavigationStep - * @generated - */ - public Adapter createDeclarativeNavigationStepAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.StepInitializer Step Initializer}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.StepInitializer - * @generated - */ - public Adapter createStepInitializerAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.JavaStepInitializer Java Step Initializer}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.JavaStepInitializer - * @generated - */ - public Adapter createJavaStepInitializerAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression Java Declaration Expression}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.JavaDeclarationExpression - * @generated - */ - public Adapter createJavaDeclarationExpressionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression Java Body Expression}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.JavaBodyExpression - * @generated - */ - public Adapter createJavaBodyExpressionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer Java Declaration Step Initializer}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.JavaDeclarationStepInitializer - * @generated - */ - public Adapter createJavaDeclarationStepInitializerAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer Java Body Step Initializer}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.navigation.JavaBodyStepInitializer - * @generated - */ - public Adapter createJavaBodyStepInitializerAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //NavigationAdapterFactory diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/util/NavigationSwitch.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/util/NavigationSwitch.java deleted file mode 100644 index 06bbcdcb2..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/navigation/util/NavigationSwitch.java +++ /dev/null @@ -1,455 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.navigation.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.mapping.navigation.*; -import org.eclipse.emf.eef.mapping.navigation.ChainedModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.CustomModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.ModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; -import org.eclipse.emf.eef.mapping.navigation.SimpleModelNavigation; -import org.eclipse.emf.eef.mapping.navigation.StructuredModelNavigation; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.mapping.navigation.NavigationPackage - * @generated - */ -public class NavigationSwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static NavigationPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public NavigationSwitch() { - if (modelPackage == null) { - modelPackage = NavigationPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } else { - List eSuperTypes = theEClass.getESuperTypes(); - return eSuperTypes.isEmpty() ? defaultCase(theEObject) : doSwitch( - eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case NavigationPackage.MODEL_NAVIGATION: { - ModelNavigation modelNavigation = (ModelNavigation) theEObject; - T result = caseModelNavigation(modelNavigation); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.SIMPLE_MODEL_NAVIGATION: { - SimpleModelNavigation simpleModelNavigation = (SimpleModelNavigation) theEObject; - T result = caseSimpleModelNavigation(simpleModelNavigation); - if (result == null) - result = caseStructuredModelNavigation(simpleModelNavigation); - if (result == null) - result = caseModelNavigation(simpleModelNavigation); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.CHAINED_MODEL_NAVIGATION: { - ChainedModelNavigation chainedModelNavigation = (ChainedModelNavigation) theEObject; - T result = caseChainedModelNavigation(chainedModelNavigation); - if (result == null) - result = caseStructuredModelNavigation(chainedModelNavigation); - if (result == null) - result = caseModelNavigation(chainedModelNavigation); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.STRUCTURED_MODEL_NAVIGATION: { - StructuredModelNavigation structuredModelNavigation = (StructuredModelNavigation) theEObject; - T result = caseStructuredModelNavigation(structuredModelNavigation); - if (result == null) - result = caseModelNavigation(structuredModelNavigation); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.CUSTOM_MODEL_NAVIGATION: { - CustomModelNavigation customModelNavigation = (CustomModelNavigation) theEObject; - T result = caseCustomModelNavigation(customModelNavigation); - if (result == null) - result = caseModelNavigation(customModelNavigation); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.SMART_MODEL_NAVIGATION: { - SmartModelNavigation smartModelNavigation = (SmartModelNavigation) theEObject; - T result = caseSmartModelNavigation(smartModelNavigation); - if (result == null) - result = caseModelNavigation(smartModelNavigation); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.NAVIGATION_STEP: { - NavigationStep navigationStep = (NavigationStep) theEObject; - T result = caseNavigationStep(navigationStep); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.DECLARATIVE_NAVIGATION_STEP: { - DeclarativeNavigationStep declarativeNavigationStep = (DeclarativeNavigationStep) theEObject; - T result = caseDeclarativeNavigationStep(declarativeNavigationStep); - if (result == null) - result = caseNavigationStep(declarativeNavigationStep); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.STEP_INITIALIZER: { - StepInitializer stepInitializer = (StepInitializer) theEObject; - T result = caseStepInitializer(stepInitializer); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.JAVA_STEP_INITIALIZER: { - JavaStepInitializer javaStepInitializer = (JavaStepInitializer) theEObject; - T result = caseJavaStepInitializer(javaStepInitializer); - if (result == null) - result = caseStepInitializer(javaStepInitializer); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.JAVA_DECLARATION_EXPRESSION: { - JavaDeclarationExpression javaDeclarationExpression = (JavaDeclarationExpression) theEObject; - T result = caseJavaDeclarationExpression(javaDeclarationExpression); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.JAVA_BODY_EXPRESSION: { - JavaBodyExpression javaBodyExpression = (JavaBodyExpression) theEObject; - T result = caseJavaBodyExpression(javaBodyExpression); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.JAVA_DECLARATION_STEP_INITIALIZER: { - JavaDeclarationStepInitializer javaDeclarationStepInitializer = (JavaDeclarationStepInitializer) theEObject; - T result = caseJavaDeclarationStepInitializer(javaDeclarationStepInitializer); - if (result == null) - result = caseJavaDeclarationExpression(javaDeclarationStepInitializer); - if (result == null) - result = caseJavaStepInitializer(javaDeclarationStepInitializer); - if (result == null) - result = caseStepInitializer(javaDeclarationStepInitializer); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case NavigationPackage.JAVA_BODY_STEP_INITIALIZER: { - JavaBodyStepInitializer javaBodyStepInitializer = (JavaBodyStepInitializer) theEObject; - T result = caseJavaBodyStepInitializer(javaBodyStepInitializer); - if (result == null) - result = caseJavaBodyExpression(javaBodyStepInitializer); - if (result == null) - result = caseJavaStepInitializer(javaBodyStepInitializer); - if (result == null) - result = caseStepInitializer(javaBodyStepInitializer); - if (result == null) - result = defaultCase(theEObject); - return result; - } - default: - return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'Model Navigation'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Model Navigation'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseModelNavigation(ModelNavigation object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Simple Model Navigation'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Simple Model Navigation'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseSimpleModelNavigation(SimpleModelNavigation object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Chained Model Navigation'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Chained Model Navigation'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseChainedModelNavigation(ChainedModelNavigation object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Structured Model Navigation'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Structured Model Navigation'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseStructuredModelNavigation(StructuredModelNavigation object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Custom Model Navigation'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Custom Model Navigation'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCustomModelNavigation(CustomModelNavigation object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Smart Model Navigation'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Smart Model Navigation'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseSmartModelNavigation(SmartModelNavigation object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Step'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Step'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseNavigationStep(NavigationStep object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Declarative Navigation Step'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Declarative Navigation Step'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDeclarativeNavigationStep(DeclarativeNavigationStep object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Step Initializer'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Step Initializer'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseStepInitializer(StepInitializer object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Step Initializer'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Step Initializer'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaStepInitializer(JavaStepInitializer object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Declaration Expression'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Declaration Expression'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaDeclarationExpression(JavaDeclarationExpression object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Body Expression'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Body Expression'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaBodyExpression(JavaBodyExpression object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Declaration Step Initializer'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Declaration Step Initializer'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaDeclarationStepInitializer( - JavaDeclarationStepInitializer object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Java Body Step Initializer'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Java Body Step Initializer'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseJavaBodyStepInitializer(JavaBodyStepInitializer object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //NavigationSwitch diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/EReferenceViewerSettings.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/EReferenceViewerSettings.java deleted file mode 100644 index f413d80b1..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/EReferenceViewerSettings.java +++ /dev/null @@ -1,83 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings; - -import org.eclipse.emf.ecore.EReference; - -import org.eclipse.emf.eef.mapping.filters.StepFilter; - -/** - * - * A representation of the model object 'EReference Viewer Settings'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings#getModel Model}
  • - *
  • {@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings#getFilter Filter}
  • - *
- *

- * - * @see org.eclipse.emf.eef.mapping.settings.SettingsPackage#getEReferenceViewerSettings() - * @model - * @generated - */ -public interface EReferenceViewerSettings extends EditorSettings { - /** - * Returns the value of the 'Model' reference. - * - *

- * If the meaning of the 'Model' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Model' reference. - * @see #setModel(EReference) - * @see org.eclipse.emf.eef.mapping.settings.SettingsPackage#getEReferenceViewerSettings_Model() - * @model required="true" - * @generated - */ - EReference getModel(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings#getModel Model}' reference. - * - * - * @param value the new value of the 'Model' reference. - * @see #getModel() - * @generated - */ - void setModel(EReference value); - - /** - * Returns the value of the 'Filter' containment reference. - * - *

- * If the meaning of the 'Filter' containment reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Filter' containment reference. - * @see #setFilter(StepFilter) - * @see org.eclipse.emf.eef.mapping.settings.SettingsPackage#getEReferenceViewerSettings_Filter() - * @model containment="true" - * @generated - */ - StepFilter getFilter(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings#getFilter Filter}' containment reference. - * - * - * @param value the new value of the 'Filter' containment reference. - * @see #getFilter() - * @generated - */ - void setFilter(StepFilter value); - -} // EReferenceViewerSettings diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/EditorSettings.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/EditorSettings.java deleted file mode 100644 index b65fdf76c..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/EditorSettings.java +++ /dev/null @@ -1,22 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Editor Settings'. - * - * - * - * @see org.eclipse.emf.eef.mapping.settings.SettingsPackage#getEditorSettings() - * @model abstract="true" - * @generated - */ -public interface EditorSettings extends EObject { -} // EditorSettings diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/SettingsFactory.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/SettingsFactory.java deleted file mode 100644 index 4119e6826..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/SettingsFactory.java +++ /dev/null @@ -1,47 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.mapping.settings.SettingsPackage - * @generated - */ -public interface SettingsFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - SettingsFactory eINSTANCE = org.eclipse.emf.eef.mapping.settings.impl.SettingsFactoryImpl - .init(); - - /** - * Returns a new object of class 'EReference Viewer Settings'. - * - * - * @return a new object of class 'EReference Viewer Settings'. - * @generated - */ - EReferenceViewerSettings createEReferenceViewerSettings(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - SettingsPackage getSettingsPackage(); - -} //SettingsFactory diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/SettingsPackage.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/SettingsPackage.java deleted file mode 100644 index bc27ba636..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/SettingsPackage.java +++ /dev/null @@ -1,223 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.mapping.settings.SettingsFactory - * @model kind="package" - * @generated - */ -public interface SettingsPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "settings"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/mapping/settings/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-mapping-settings"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - SettingsPackage eINSTANCE = org.eclipse.emf.eef.mapping.settings.impl.SettingsPackageImpl - .init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.settings.impl.EditorSettingsImpl Editor Settings}' class. - * - * - * @see org.eclipse.emf.eef.mapping.settings.impl.EditorSettingsImpl - * @see org.eclipse.emf.eef.mapping.settings.impl.SettingsPackageImpl#getEditorSettings() - * @generated - */ - int EDITOR_SETTINGS = 0; - - /** - * The number of structural features of the 'Editor Settings' class. - * - * - * @generated - * @ordered - */ - int EDITOR_SETTINGS_FEATURE_COUNT = 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.mapping.settings.impl.EReferenceViewerSettingsImpl EReference Viewer Settings}' class. - * - * - * @see org.eclipse.emf.eef.mapping.settings.impl.EReferenceViewerSettingsImpl - * @see org.eclipse.emf.eef.mapping.settings.impl.SettingsPackageImpl#getEReferenceViewerSettings() - * @generated - */ - int EREFERENCE_VIEWER_SETTINGS = 1; - - /** - * The feature id for the 'Model' reference. - * - * - * @generated - * @ordered - */ - int EREFERENCE_VIEWER_SETTINGS__MODEL = EDITOR_SETTINGS_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Filter' containment reference. - * - * - * @generated - * @ordered - */ - int EREFERENCE_VIEWER_SETTINGS__FILTER = EDITOR_SETTINGS_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'EReference Viewer Settings' class. - * - * - * @generated - * @ordered - */ - int EREFERENCE_VIEWER_SETTINGS_FEATURE_COUNT = EDITOR_SETTINGS_FEATURE_COUNT + 2; - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.settings.EditorSettings Editor Settings}'. - * - * - * @return the meta object for class 'Editor Settings'. - * @see org.eclipse.emf.eef.mapping.settings.EditorSettings - * @generated - */ - EClass getEditorSettings(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings EReference Viewer Settings}'. - * - * - * @return the meta object for class 'EReference Viewer Settings'. - * @see org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings - * @generated - */ - EClass getEReferenceViewerSettings(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings#getModel Model}'. - * - * - * @return the meta object for the reference 'Model'. - * @see org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings#getModel() - * @see #getEReferenceViewerSettings() - * @generated - */ - EReference getEReferenceViewerSettings_Model(); - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings#getFilter Filter}'. - * - * - * @return the meta object for the containment reference 'Filter'. - * @see org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings#getFilter() - * @see #getEReferenceViewerSettings() - * @generated - */ - EReference getEReferenceViewerSettings_Filter(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - SettingsFactory getSettingsFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.settings.impl.EditorSettingsImpl Editor Settings}' class. - * - * - * @see org.eclipse.emf.eef.mapping.settings.impl.EditorSettingsImpl - * @see org.eclipse.emf.eef.mapping.settings.impl.SettingsPackageImpl#getEditorSettings() - * @generated - */ - EClass EDITOR_SETTINGS = eINSTANCE.getEditorSettings(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.mapping.settings.impl.EReferenceViewerSettingsImpl EReference Viewer Settings}' class. - * - * - * @see org.eclipse.emf.eef.mapping.settings.impl.EReferenceViewerSettingsImpl - * @see org.eclipse.emf.eef.mapping.settings.impl.SettingsPackageImpl#getEReferenceViewerSettings() - * @generated - */ - EClass EREFERENCE_VIEWER_SETTINGS = eINSTANCE - .getEReferenceViewerSettings(); - - /** - * The meta object literal for the 'Model' reference feature. - * - * - * @generated - */ - EReference EREFERENCE_VIEWER_SETTINGS__MODEL = eINSTANCE - .getEReferenceViewerSettings_Model(); - - /** - * The meta object literal for the 'Filter' containment reference feature. - * - * - * @generated - */ - EReference EREFERENCE_VIEWER_SETTINGS__FILTER = eINSTANCE - .getEReferenceViewerSettings_Filter(); - - } - -} //SettingsPackage diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/EReferenceViewerSettingsImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/EReferenceViewerSettingsImpl.java deleted file mode 100644 index d2ab1c5a8..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/EReferenceViewerSettingsImpl.java +++ /dev/null @@ -1,267 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.mapping.filters.StepFilter; - -import org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings; -import org.eclipse.emf.eef.mapping.settings.SettingsPackage; - -/** - * - * An implementation of the model object 'EReference Viewer Settings'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.mapping.settings.impl.EReferenceViewerSettingsImpl#getModel Model}
  • - *
  • {@link org.eclipse.emf.eef.mapping.settings.impl.EReferenceViewerSettingsImpl#getFilter Filter}
  • - *
- *

- * - * @generated - */ -public class EReferenceViewerSettingsImpl extends EditorSettingsImpl implements - EReferenceViewerSettings { - /** - * The cached value of the '{@link #getModel() Model}' reference. - * - * - * @see #getModel() - * @generated - * @ordered - */ - protected EReference model; - - /** - * The cached value of the '{@link #getFilter() Filter}' containment reference. - * - * - * @see #getFilter() - * @generated - * @ordered - */ - protected StepFilter filter; - - /** - * - * - * @generated - */ - protected EReferenceViewerSettingsImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return SettingsPackage.Literals.EREFERENCE_VIEWER_SETTINGS; - } - - /** - * - * - * @generated - */ - public EReference getModel() { - if (model != null && model.eIsProxy()) { - InternalEObject oldModel = (InternalEObject) model; - model = (EReference) eResolveProxy(oldModel); - if (model != oldModel) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, - SettingsPackage.EREFERENCE_VIEWER_SETTINGS__MODEL, - oldModel, model)); - } - } - return model; - } - - /** - * - * - * @generated - */ - public EReference basicGetModel() { - return model; - } - - /** - * - * - * @generated - */ - public void setModel(EReference newModel) { - EReference oldModel = model; - model = newModel; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - SettingsPackage.EREFERENCE_VIEWER_SETTINGS__MODEL, - oldModel, model)); - } - - /** - * - * - * @generated - */ - public StepFilter getFilter() { - return filter; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetFilter(StepFilter newFilter, - NotificationChain msgs) { - StepFilter oldFilter = filter; - filter = newFilter; - if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, - Notification.SET, - SettingsPackage.EREFERENCE_VIEWER_SETTINGS__FILTER, - oldFilter, newFilter); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - public void setFilter(StepFilter newFilter) { - if (newFilter != filter) { - NotificationChain msgs = null; - if (filter != null) - msgs = ((InternalEObject) filter) - .eInverseRemove( - this, - EOPPOSITE_FEATURE_BASE - - SettingsPackage.EREFERENCE_VIEWER_SETTINGS__FILTER, - null, msgs); - if (newFilter != null) - msgs = ((InternalEObject) newFilter) - .eInverseAdd( - this, - EOPPOSITE_FEATURE_BASE - - SettingsPackage.EREFERENCE_VIEWER_SETTINGS__FILTER, - null, msgs); - msgs = basicSetFilter(newFilter, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, - SettingsPackage.EREFERENCE_VIEWER_SETTINGS__FILTER, - newFilter, newFilter)); - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, - int featureID, NotificationChain msgs) { - switch (featureID) { - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS__FILTER: - return basicSetFilter(null, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS__MODEL: - if (resolve) - return getModel(); - return basicGetModel(); - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS__FILTER: - return getFilter(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS__MODEL: - setModel((EReference) newValue); - return; - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS__FILTER: - setFilter((StepFilter) newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS__MODEL: - setModel((EReference) null); - return; - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS__FILTER: - setFilter((StepFilter) null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS__MODEL: - return model != null; - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS__FILTER: - return filter != null; - } - return super.eIsSet(featureID); - } - -} //EReferenceViewerSettingsImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/EditorSettingsImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/EditorSettingsImpl.java deleted file mode 100644 index 44a3feef8..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/EditorSettingsImpl.java +++ /dev/null @@ -1,46 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.EObjectImpl; - -import org.eclipse.emf.eef.mapping.settings.EditorSettings; -import org.eclipse.emf.eef.mapping.settings.SettingsPackage; - -/** - * - * An implementation of the model object 'Editor Settings'. - * - *

- *

- * - * @generated - */ -public abstract class EditorSettingsImpl extends EObjectImpl implements - EditorSettings { - /** - * - * - * @generated - */ - protected EditorSettingsImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return SettingsPackage.Literals.EDITOR_SETTINGS; - } - -} //EditorSettingsImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/SettingsFactoryImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/SettingsFactoryImpl.java deleted file mode 100644 index ff63e34d5..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/SettingsFactoryImpl.java +++ /dev/null @@ -1,102 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.impl.EFactoryImpl; - -import org.eclipse.emf.ecore.plugin.EcorePlugin; - -import org.eclipse.emf.eef.mapping.settings.*; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class SettingsFactoryImpl extends EFactoryImpl implements - SettingsFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static SettingsFactory init() { - try { - SettingsFactory theSettingsFactory = (SettingsFactory) EPackage.Registry.INSTANCE - .getEFactory("http://www.eclipse.org/emf/eef/mapping/settings/1.0.0"); - if (theSettingsFactory != null) { - return theSettingsFactory; - } - } catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new SettingsFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public SettingsFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS: - return createEReferenceViewerSettings(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() - + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public EReferenceViewerSettings createEReferenceViewerSettings() { - EReferenceViewerSettingsImpl eReferenceViewerSettings = new EReferenceViewerSettingsImpl(); - return eReferenceViewerSettings; - } - - /** - * - * - * @generated - */ - public SettingsPackage getSettingsPackage() { - return (SettingsPackage) getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static SettingsPackage getPackage() { - return SettingsPackage.eINSTANCE; - } - -} //SettingsFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/SettingsPackageImpl.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/SettingsPackageImpl.java deleted file mode 100644 index a84601480..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/impl/SettingsPackageImpl.java +++ /dev/null @@ -1,278 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EcorePackage; - -import org.eclipse.emf.ecore.impl.EPackageImpl; - -import org.eclipse.emf.eef.mapping.MappingPackage; - -import org.eclipse.emf.eef.mapping.filters.FiltersPackage; - -import org.eclipse.emf.eef.mapping.filters.impl.FiltersPackageImpl; - -import org.eclipse.emf.eef.mapping.impl.MappingPackageImpl; - -import org.eclipse.emf.eef.mapping.navigation.NavigationPackage; - -import org.eclipse.emf.eef.mapping.navigation.impl.NavigationPackageImpl; - -import org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings; -import org.eclipse.emf.eef.mapping.settings.EditorSettings; -import org.eclipse.emf.eef.mapping.settings.SettingsFactory; -import org.eclipse.emf.eef.mapping.settings.SettingsPackage; - -import org.eclipse.emf.eef.views.ViewsPackage; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class SettingsPackageImpl extends EPackageImpl implements - SettingsPackage { - /** - * - * - * @generated - */ - private EClass editorSettingsEClass = null; - - /** - * - * - * @generated - */ - private EClass eReferenceViewerSettingsEClass = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.mapping.settings.SettingsPackage#eNS_URI - * @see #init() - * @generated - */ - private SettingsPackageImpl() { - super(eNS_URI, SettingsFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link SettingsPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static SettingsPackage init() { - if (isInited) - return (SettingsPackage) EPackage.Registry.INSTANCE - .getEPackage(SettingsPackage.eNS_URI); - - // Obtain or create and register package - SettingsPackageImpl theSettingsPackage = (SettingsPackageImpl) (EPackage.Registry.INSTANCE - .get(eNS_URI) instanceof SettingsPackageImpl ? EPackage.Registry.INSTANCE - .get(eNS_URI) : new SettingsPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - EcorePackage.eINSTANCE.eClass(); - ViewsPackage.eINSTANCE.eClass(); - - // Obtain or create and register interdependencies - MappingPackageImpl theMappingPackage = (MappingPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(MappingPackage.eNS_URI) instanceof MappingPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(MappingPackage.eNS_URI) : MappingPackage.eINSTANCE); - NavigationPackageImpl theNavigationPackage = (NavigationPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(NavigationPackage.eNS_URI) instanceof NavigationPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(NavigationPackage.eNS_URI) - : NavigationPackage.eINSTANCE); - FiltersPackageImpl theFiltersPackage = (FiltersPackageImpl) (EPackage.Registry.INSTANCE - .getEPackage(FiltersPackage.eNS_URI) instanceof FiltersPackageImpl ? EPackage.Registry.INSTANCE - .getEPackage(FiltersPackage.eNS_URI) : FiltersPackage.eINSTANCE); - - // Create package meta-data objects - theSettingsPackage.createPackageContents(); - theMappingPackage.createPackageContents(); - theNavigationPackage.createPackageContents(); - theFiltersPackage.createPackageContents(); - - // Initialize created meta-data - theSettingsPackage.initializePackageContents(); - theMappingPackage.initializePackageContents(); - theNavigationPackage.initializePackageContents(); - theFiltersPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theSettingsPackage.freeze(); - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(SettingsPackage.eNS_URI, - theSettingsPackage); - return theSettingsPackage; - } - - /** - * - * - * @generated - */ - public EClass getEditorSettings() { - return editorSettingsEClass; - } - - /** - * - * - * @generated - */ - public EClass getEReferenceViewerSettings() { - return eReferenceViewerSettingsEClass; - } - - /** - * - * - * @generated - */ - public EReference getEReferenceViewerSettings_Model() { - return (EReference) eReferenceViewerSettingsEClass - .getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getEReferenceViewerSettings_Filter() { - return (EReference) eReferenceViewerSettingsEClass - .getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public SettingsFactory getSettingsFactory() { - return (SettingsFactory) getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) - return; - isCreated = true; - - // Create classes and their features - editorSettingsEClass = createEClass(EDITOR_SETTINGS); - - eReferenceViewerSettingsEClass = createEClass(EREFERENCE_VIEWER_SETTINGS); - createEReference(eReferenceViewerSettingsEClass, - EREFERENCE_VIEWER_SETTINGS__MODEL); - createEReference(eReferenceViewerSettingsEClass, - EREFERENCE_VIEWER_SETTINGS__FILTER); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) - return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - EcorePackage theEcorePackage = (EcorePackage) EPackage.Registry.INSTANCE - .getEPackage(EcorePackage.eNS_URI); - FiltersPackage theFiltersPackage = (FiltersPackage) EPackage.Registry.INSTANCE - .getEPackage(FiltersPackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - eReferenceViewerSettingsEClass.getESuperTypes().add( - this.getEditorSettings()); - - // Initialize classes and features; add operations and parameters - initEClass(editorSettingsEClass, EditorSettings.class, - "EditorSettings", IS_ABSTRACT, !IS_INTERFACE, - IS_GENERATED_INSTANCE_CLASS); - - initEClass(eReferenceViewerSettingsEClass, - EReferenceViewerSettings.class, "EReferenceViewerSettings", - !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getEReferenceViewerSettings_Model(), - theEcorePackage.getEReference(), null, "model", null, 1, 1, - EReferenceViewerSettings.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getEReferenceViewerSettings_Filter(), - theFiltersPackage.getStepFilter(), null, "filter", null, 0, 1, - EReferenceViewerSettings.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, - !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - } - -} //SettingsPackageImpl diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/util/SettingsAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/util/SettingsAdapterFactory.java deleted file mode 100644 index 532dad7e3..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/util/SettingsAdapterFactory.java +++ /dev/null @@ -1,143 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; - -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.settings.*; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.mapping.settings.SettingsPackage - * @generated - */ -public class SettingsAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static SettingsPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public SettingsAdapterFactory() { - if (modelPackage == null) { - modelPackage = SettingsPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject) object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected SettingsSwitch modelSwitch = new SettingsSwitch() { - @Override - public Adapter caseEditorSettings(EditorSettings object) { - return createEditorSettingsAdapter(); - } - - @Override - public Adapter caseEReferenceViewerSettings( - EReferenceViewerSettings object) { - return createEReferenceViewerSettingsAdapter(); - } - - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject) target); - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.settings.EditorSettings Editor Settings}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.settings.EditorSettings - * @generated - */ - public Adapter createEditorSettingsAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings EReference Viewer Settings}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.settings.EReferenceViewerSettings - * @generated - */ - public Adapter createEReferenceViewerSettingsAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //SettingsAdapterFactory diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/util/SettingsSwitch.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/util/SettingsSwitch.java deleted file mode 100644 index b1c93c888..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/settings/util/SettingsSwitch.java +++ /dev/null @@ -1,153 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.mapping.settings.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.mapping.settings.*; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.mapping.settings.SettingsPackage - * @generated - */ -public class SettingsSwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static SettingsPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public SettingsSwitch() { - if (modelPackage == null) { - modelPackage = SettingsPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } else { - List eSuperTypes = theEClass.getESuperTypes(); - return eSuperTypes.isEmpty() ? defaultCase(theEObject) : doSwitch( - eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case SettingsPackage.EDITOR_SETTINGS: { - EditorSettings editorSettings = (EditorSettings) theEObject; - T result = caseEditorSettings(editorSettings); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case SettingsPackage.EREFERENCE_VIEWER_SETTINGS: { - EReferenceViewerSettings eReferenceViewerSettings = (EReferenceViewerSettings) theEObject; - T result = caseEReferenceViewerSettings(eReferenceViewerSettings); - if (result == null) - result = caseEditorSettings(eReferenceViewerSettings); - if (result == null) - result = defaultCase(theEObject); - return result; - } - default: - return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'Editor Settings'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Editor Settings'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEditorSettings(EditorSettings object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EReference Viewer Settings'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EReference Viewer Settings'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEReferenceViewerSettings(EReferenceViewerSettings object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //SettingsSwitch diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/util/MappingAdapterFactory.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/util/MappingAdapterFactory.java deleted file mode 100644 index f18b2c3d7..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/util/MappingAdapterFactory.java +++ /dev/null @@ -1,370 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.mapping.*; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.AbstractPropertyBinding; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelElement; -import org.eclipse.emf.eef.mapping.ModelProperty; -import org.eclipse.emf.eef.mapping.StandardElementBinding; -import org.eclipse.emf.eef.mapping.StandardPropertyBinding; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.mapping.MappingPackage - * @generated - */ -public class MappingAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static MappingPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public MappingAdapterFactory() { - if (modelPackage == null) { - modelPackage = MappingPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject) object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected MappingSwitch modelSwitch = new MappingSwitch() { - @Override - public Adapter caseDatabinding(Databinding object) { - return createDatabindingAdapter(); - } - - @Override - public Adapter caseModelElement(ModelElement object) { - return createModelElementAdapter(); - } - - @Override - public Adapter caseAbstractElementBinding(AbstractElementBinding object) { - return createAbstractElementBindingAdapter(); - } - - @Override - public Adapter caseModelProperty(ModelProperty object) { - return createModelPropertyAdapter(); - } - - @Override - public Adapter caseAbstractPropertyBinding( - AbstractPropertyBinding object) { - return createAbstractPropertyBindingAdapter(); - } - - @Override - public Adapter caseEMFElementBinding(EMFElementBinding object) { - return createEMFElementBindingAdapter(); - } - - @Override - public Adapter caseEMFPropertyBinding(EMFPropertyBinding object) { - return createEMFPropertyBindingAdapter(); - } - - @Override - public Adapter caseStandardElementBinding(StandardElementBinding object) { - return createStandardElementBindingAdapter(); - } - - @Override - public Adapter caseStandardPropertyBinding( - StandardPropertyBinding object) { - return createStandardPropertyBindingAdapter(); - } - - @Override - public Adapter caseCategory(Category object) { - return createCategoryAdapter(); - } - - @Override - public Adapter caseElementBindingReference( - ElementBindingReference object) { - return createElementBindingReferenceAdapter(); - } - - @Override - public Adapter caseDocumentedElement(DocumentedElement object) { - return createDocumentedElementAdapter(); - } - - @Override - public Adapter caseEMFMultiPropertiesBinding( - EMFMultiPropertiesBinding object) { - return createEMFMultiPropertiesBindingAdapter(); - } - - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject) target); - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.Databinding Databinding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.Databinding - * @generated - */ - public Adapter createDatabindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.ModelElement Model Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.ModelElement - * @generated - */ - public Adapter createModelElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.AbstractElementBinding Abstract Element Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.AbstractElementBinding - * @generated - */ - public Adapter createAbstractElementBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.ModelProperty Model Property}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.ModelProperty - * @generated - */ - public Adapter createModelPropertyAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.AbstractPropertyBinding Abstract Property Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.AbstractPropertyBinding - * @generated - */ - public Adapter createAbstractPropertyBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.EMFElementBinding EMF Element Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.EMFElementBinding - * @generated - */ - public Adapter createEMFElementBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.EMFPropertyBinding EMF Property Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.EMFPropertyBinding - * @generated - */ - public Adapter createEMFPropertyBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.StandardElementBinding Standard Element Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.StandardElementBinding - * @generated - */ - public Adapter createStandardElementBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.StandardPropertyBinding Standard Property Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.StandardPropertyBinding - * @generated - */ - public Adapter createStandardPropertyBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.Category Category}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.Category - * @generated - */ - public Adapter createCategoryAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.ElementBindingReference Element Binding Reference}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.ElementBindingReference - * @generated - */ - public Adapter createElementBindingReferenceAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.DocumentedElement Documented Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.DocumentedElement - * @generated - */ - public Adapter createDocumentedElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding EMF Multi Properties Binding}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding - * @generated - */ - public Adapter createEMFMultiPropertiesBindingAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //MappingAdapterFactory diff --git a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/util/MappingSwitch.java b/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/util/MappingSwitch.java deleted file mode 100644 index 8957bde68..000000000 --- a/plugins/org.eclipse.emf.eef.mapping/src-gen/org/eclipse/emf/eef/mapping/util/MappingSwitch.java +++ /dev/null @@ -1,444 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.mapping.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.mapping.*; -import org.eclipse.emf.eef.mapping.AbstractElementBinding; -import org.eclipse.emf.eef.mapping.AbstractPropertyBinding; -import org.eclipse.emf.eef.mapping.Category; -import org.eclipse.emf.eef.mapping.Databinding; -import org.eclipse.emf.eef.mapping.DocumentedElement; -import org.eclipse.emf.eef.mapping.EMFElementBinding; -import org.eclipse.emf.eef.mapping.EMFMultiPropertiesBinding; -import org.eclipse.emf.eef.mapping.EMFPropertyBinding; -import org.eclipse.emf.eef.mapping.ElementBindingReference; -import org.eclipse.emf.eef.mapping.MappingPackage; -import org.eclipse.emf.eef.mapping.ModelElement; -import org.eclipse.emf.eef.mapping.ModelProperty; -import org.eclipse.emf.eef.mapping.StandardElementBinding; -import org.eclipse.emf.eef.mapping.StandardPropertyBinding; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.mapping.MappingPackage - * @generated - */ -public class MappingSwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static MappingPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public MappingSwitch() { - if (modelPackage == null) { - modelPackage = MappingPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } else { - List eSuperTypes = theEClass.getESuperTypes(); - return eSuperTypes.isEmpty() ? defaultCase(theEObject) : doSwitch( - eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case MappingPackage.DATABINDING: { - Databinding databinding = (Databinding) theEObject; - T result = caseDatabinding(databinding); - if (result == null) - result = caseDocumentedElement(databinding); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.MODEL_ELEMENT: { - ModelElement modelElement = (ModelElement) theEObject; - T result = caseModelElement(modelElement); - if (result == null) - result = caseDocumentedElement(modelElement); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.ABSTRACT_ELEMENT_BINDING: { - AbstractElementBinding abstractElementBinding = (AbstractElementBinding) theEObject; - T result = caseAbstractElementBinding(abstractElementBinding); - if (result == null) - result = caseDocumentedElement(abstractElementBinding); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.MODEL_PROPERTY: { - ModelProperty modelProperty = (ModelProperty) theEObject; - T result = caseModelProperty(modelProperty); - if (result == null) - result = caseDocumentedElement(modelProperty); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.ABSTRACT_PROPERTY_BINDING: { - AbstractPropertyBinding abstractPropertyBinding = (AbstractPropertyBinding) theEObject; - T result = caseAbstractPropertyBinding(abstractPropertyBinding); - if (result == null) - result = caseDocumentedElement(abstractPropertyBinding); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.EMF_ELEMENT_BINDING: { - EMFElementBinding emfElementBinding = (EMFElementBinding) theEObject; - T result = caseEMFElementBinding(emfElementBinding); - if (result == null) - result = caseAbstractElementBinding(emfElementBinding); - if (result == null) - result = caseDocumentedElement(emfElementBinding); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.EMF_PROPERTY_BINDING: { - EMFPropertyBinding emfPropertyBinding = (EMFPropertyBinding) theEObject; - T result = caseEMFPropertyBinding(emfPropertyBinding); - if (result == null) - result = caseAbstractPropertyBinding(emfPropertyBinding); - if (result == null) - result = caseDocumentedElement(emfPropertyBinding); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.STANDARD_ELEMENT_BINDING: { - StandardElementBinding standardElementBinding = (StandardElementBinding) theEObject; - T result = caseStandardElementBinding(standardElementBinding); - if (result == null) - result = caseAbstractElementBinding(standardElementBinding); - if (result == null) - result = caseDocumentedElement(standardElementBinding); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.STANDARD_PROPERTY_BINDING: { - StandardPropertyBinding standardPropertyBinding = (StandardPropertyBinding) theEObject; - T result = caseStandardPropertyBinding(standardPropertyBinding); - if (result == null) - result = caseAbstractPropertyBinding(standardPropertyBinding); - if (result == null) - result = caseDocumentedElement(standardPropertyBinding); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.CATEGORY: { - Category category = (Category) theEObject; - T result = caseCategory(category); - if (result == null) - result = caseDocumentedElement(category); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.ELEMENT_BINDING_REFERENCE: { - ElementBindingReference elementBindingReference = (ElementBindingReference) theEObject; - T result = caseElementBindingReference(elementBindingReference); - if (result == null) - result = caseDocumentedElement(elementBindingReference); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.DOCUMENTED_ELEMENT: { - DocumentedElement documentedElement = (DocumentedElement) theEObject; - T result = caseDocumentedElement(documentedElement); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case MappingPackage.EMF_MULTI_PROPERTIES_BINDING: { - EMFMultiPropertiesBinding emfMultiPropertiesBinding = (EMFMultiPropertiesBinding) theEObject; - T result = caseEMFMultiPropertiesBinding(emfMultiPropertiesBinding); - if (result == null) - result = caseAbstractPropertyBinding(emfMultiPropertiesBinding); - if (result == null) - result = caseDocumentedElement(emfMultiPropertiesBinding); - if (result == null) - result = defaultCase(theEObject); - return result; - } - default: - return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'Databinding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Databinding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDatabinding(Databinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Model Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Model Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseModelElement(ModelElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Abstract Element Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Abstract Element Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAbstractElementBinding(AbstractElementBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Model Property'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Model Property'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseModelProperty(ModelProperty object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Abstract Property Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Abstract Property Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAbstractPropertyBinding(AbstractPropertyBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EMF Element Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EMF Element Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEMFElementBinding(EMFElementBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EMF Property Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EMF Property Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEMFPropertyBinding(EMFPropertyBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Standard Element Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Standard Element Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseStandardElementBinding(StandardElementBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Standard Property Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Standard Property Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseStandardPropertyBinding(StandardPropertyBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Category'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Category'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCategory(Category object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Element Binding Reference'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Element Binding Reference'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseElementBindingReference(ElementBindingReference object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Documented Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Documented Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDocumentedElement(DocumentedElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EMF Multi Properties Binding'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EMF Multi Properties Binding'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEMFMultiPropertiesBinding(EMFMultiPropertiesBinding object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //MappingSwitch diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/.classpath b/plugins/org.eclipse.emf.eef.modelingbot.edit/.classpath deleted file mode 100644 index 756f42890..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/.classpath +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/.gitignore b/plugins/org.eclipse.emf.eef.modelingbot.edit/.gitignore deleted file mode 100644 index 4058d0f36..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -bin -/target diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/.project b/plugins/org.eclipse.emf.eef.modelingbot.edit/.project deleted file mode 100644 index 01a2d7474..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.modelingbot.edit - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.modelingbot.edit/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index 5cbbd42aa..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,8 +0,0 @@ -#Tue Apr 05 16:22:02 CEST 2011 -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.modelingbot.edit/META-INF/MANIFEST.MF deleted file mode 100644 index e7538fc69..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/META-INF/MANIFEST.MF +++ /dev/null @@ -1,32 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: %pluginName -Bundle-SymbolicName: org.eclipse.emf.eef.modelingbot.edit;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Activator: org.eclipse.emf.eef.modelingBot.provider.MbotEditPlugin$Implementation -Bundle-Vendor: %providerName -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.modelingBot.EEFActions.provider, - org.eclipse.emf.eef.modelingBot.EclipseActions.provider, - org.eclipse.emf.eef.modelingBot.edit.commands, - org.eclipse.emf.eef.modelingBot.provider -Require-Bundle: org.eclipse.core.runtime, - org.eclipse.emf.eef.modelingbot;visibility:=reexport, - org.eclipse.emf.edit;visibility:=reexport, - org.eclipse.emf.eef.components;visibility:=reexport, - org.eclipse.emf.eef.components.edit;visibility:=reexport, - org.eclipse.emf.ecore;visibility:=reexport, - org.eclipse.emf.ecore.edit;visibility:=reexport, - org.eclipse.emf.eef.editor.model;visibility:=reexport, - org.eclipse.emf.codegen.ecore;visibility:=reexport, - org.eclipse.emf.codegen.ecore.ui;visibility:=reexport, - org.eclipse.emf.eef.mapping;visibility:=reexport, - org.eclipse.emf.eef.mapping.edit;visibility:=reexport, - org.eclipse.emf.eef.views;visibility:=reexport, - org.eclipse.emf.eef.views.edit;visibility:=reexport, - org.eclipse.ui, - org.eclipse.core.resources, - org.eclipse.emf.ecore.xmi -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/build.properties b/plugins/org.eclipse.emf.eef.modelingbot.edit/build.properties deleted file mode 100755 index 85da56404..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/build.properties +++ /dev/null @@ -1,19 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2011 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -bin.includes = .,\ - icons/,\ - META-INF/,\ - plugin.xml,\ - plugin.properties -jars.compile.order = . -source.. = src-gen/,\ - src/ -output.. = bin/ diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Add.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Add.gif deleted file mode 100644 index 252d7ebcb8c74d6e5de66ef0eb8856622a0e9d89..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 318 zcmZ?wbhEHb6krfwxXQp_S{7na6>d=(Ze15;Qy1mX8t2lT^ zHOHgY9FJamJZkN+sI|wVk6ueSb}ixP)r4bLfn?%^+sU^crQUj&`rv8W|Ns9PC;*B- zSr{1@v>9|jW`O*}z!rUAYJrE2RKG`JYNRKhwpQrnor{(Ph`sVEnyR2Kc;c~(o$WdP zMb0Wl6K^dQ-0hgs;hmj@| z!^cNU^)$=D93{1Bmt2ikM6pZxXf80Q*w4ngKxIMPYAL6e2AVtWx1L;h<;IQo|F3@j|LW)e*FXQi`}P0h@Bcsk{(tl9|Jz^xzx?_C z`q%$=zyH7g{r~fy|G)qJ|M=(sx4-{?{rmsx|NlS#|Ns3D0u0mxia%Kx85qF&s24FDJgfQhSsP^7`ND_vh~U`1$;6ftmC6`|$Mo@bvrO>G$F4 z_>6r@_4xajf=029KH9x};_CRLh(hG-_>zA}_W1mQcuc5@LFDcDq7}_xb$o^7);GM5v2F^Y;4p`TO$r`{L{P)v{@R zc242z_vh~To`po<$d7(?PUY#~AxB-+Aupfh$)JUb%hZ*6owG9-e>j^vaWm7alw~fB(US`%kYvIkx8L z`JLw+Z^fk6idfdJ$u2DUnfX$2lSQvL1?LJcxZVHZS&IZt>fwYH`0lqnN?utDOD zV3U#P7OTzwIGjbe+a31bFcf$4u$biYM@WdHk+D(9NrhdIT|j`1jlD}yP}NC|m0y~5 z_H2GWepYoS4PIuhv+QF>!M8Y~3oQ<*d1P-~PS6hYq_qGFSruxw(hb diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/CreateModel.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/CreateModel.gif deleted file mode 100644 index 62cef1f3191f2731f28f9e98c39a6d18f53bec49..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 595 zcmZ?wbhEHb6krfwc*ekxTeSA`*WW*X{r&Ot&)4sNK7IZD>-XQEzy2gvF3oOQTiU(( z&BtFKzWgrj*<3euSNq(9-3t!)FFrbV!?}fF*UcdkP<%eIdKmL04;pfM%zrX+d^X=1XU&{&;oQC@3py9f?VdZkZ~wNA(}!oRSk$&_ZRM_Y zmD^U=Y+BK$ z+0$!slOr1&yR(h}FNcnsr@M2L6FZZV6{~~<%Nor>7YmoF@uY*laCi{3rPAZpxXC&#UABK4o) z|3!f>i=DSgNeTs>a7aw#bu_uOv_Mdqt*1*&lWWz+g~?t0@~IMwG6a=*dRv$n8LR+f~| diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/CreateProject.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/CreateProject.gif deleted file mode 100644 index fbbac0f0ca843fd448a14d9cc125b3afcd149b01..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 348 zcmZ?wbhEHb6krfwxXQpVYtpm{T@yMwXE(LZt7=$OP_^v(osV$^>(WbCWml}c{oqq# z(VEoVjXJ%SEMz$RK3PUtLs_;;tgXF` zOOs2>nOStg#EER8%+4%AGiS{fVsT~_T)1elAgeQnz{*vt1vs3!c{Xm^%){->zGLUE NonCwQxj8ae0{{eulr{hW diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/DetailsPage.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/DetailsPage.gif deleted file mode 100644 index d8ee67c1d83b319e445b51b9718fd38a514ecb6f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 914 zcmZ?wbhEHb6krfw_|5*vSE+t=5}&!1mEe?Jh+zkh%Ko0m8K-=F{g z|9_CeQ7{?;!!86Af3kr6qyr*Bd4ho>pFxyE#$&?+2WAdoB@>Mc2bkCd6s0r{TyQwj z!73J@lQEH@nMsVhB4=}QsCZF3Q q@nu=VVvosksu@KZ%~M#c>s&exsGMx`voDf4S*mh)Jqt4vgEaul>p}AX diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/EEFActionsModelFile.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/EEFActionsModelFile.gif deleted file mode 100644 index 388b93755fcb68e853cac46d13f11af2cb1c491a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 346 zcmZ?wbhEHb6krfwxXQrL(9jScAHRS9{{Q#qA2@IT$YuD?z`*by$o~Hy%=!;v&zUm^ zC{?WHvt@!U5N+tUThrsPyxVC}hx6Q4*Xd1e&E>vzrGC}L0arF<-r8I9;6(q=Uw^*; z{QdRE?@wQUfB5?Q?WbR_KK#7@^2eR$-+>lT3n>0%VPs%nW6%K^2=WsHTe(AXfrpNe z;t7>Y8Z8y`F7UQ!{)|{Jv$BxsRh9Kk&xt}>?Q+iqmPQEfD< diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/ModelingBot.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/ModelingBot.gif deleted file mode 100644 index 1ef9c8fa924121f22f0a584c1b7c86d78436c16b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 934 zcmZ?wbhEHb6krfw_|5J+ciDPFBtx>mnztwF^aql$G#mFvuF*PB*vw5Z)+QMcK$ zZnH(*mh4Tj_Kllu8n)UrZnbULX4|;UrFEM_%MR!ET`nNB+r4YAd-q=5|>`@@0-OBxy){sWBwCMhrlq=76TQ2fcl$iQI2 zpaU`=lqVQCni(=VWIQ%3IM~b~ER}L#!omY>JX}T{0*+0rjj|4NIy^2ovT%v%ar_BT za&2xBPzgD(z%jv7l%LCQLqno7d!uI9mKh5I7Whd>@)W%gIOGCUn{ehsLP5*1Il2ia u1Og8$a0$6bADQ8`RqLR5!r?B7=*4TCSTn>|yq#I*=-s)RRH2yZMG-dG{LyHRvkqv*C;prFW}Cb1QH0&9u|R~HDbFBMu_B(%Cf zXj8fH`cmQLIReYF1^)m4&p+|z+lLr1JVKV69Zf3ff)rJI#S8AmOS&g!objY zXp*F{?P9eo9}@`oK{Iw9&}i^SBU4D}c3FLN?5SiQ`V!5RSYo{04T diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/MoveUp.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/MoveUp.gif deleted file mode 100644 index 07164754e5ca231666d9daf7fa4a9d12e378a52a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 323 zcmZ?wbhEHb6krfwxXQrr@9+D6zn=X4cJ<${r+>d*`SKk--`OT*-X9 diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/OpenEEFEditor.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/OpenEEFEditor.gif deleted file mode 100644 index b709469c20aea3ea0d9b3f031506071f02aeb055..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1045 zcmeH`TThY!0ERz@ZB)2Eb$M9Yuvt3GyH>g`QbL6bC)jK*+bTnIrHz)uvjQ>|Q^Nyb zW}YzA07W^eC<9T%AifU-L@*Di8LhT(IdxuG{)p~+|G=~7+1?a$xPIHYgL$?E2nr8dw-r9$$?;%r*y!|vXBR*Ool`C>LX z)4DS5urpG)1k-rW!opgq@FlAPy~yHEu|vzCxiQa*PL8oMLfOk zbp3qWp|#pPbMxyHllDdH*WOYB1a0aU)>~TDZik7(o!Qy(Zn(W>%g)5)QgO)u3~g~( zQ)%59uSors6yeC5{6Y#}IBYsNJlfkkJU%|QY9-p)mD&pFgwjsR<)v_ml~n2IsM%oL z6bPXaF>JGYoG#Btp)s4(J3L~cmWaipFe!&uRw3R$I4ZA{>K8UFkc-Wkkx1=0F0qxZ zo>V%fRW9B9+OzyY9EYgZEW4LXO%Ebj&C@1mTOfd?vc*Z|Qbm;n`s`+NHD;5ekEfr} zuGEwWrlyx_>c%NWgD|`~ty*!qzH{0&^7i8L$}z>bePGC7GT4+;%T+XKZXRDIx6&E% zF^LU=w++VihDN1Ip}L1-$JQqORRjL-9~X!?^z{J%CUEV9bMgrQxeEk_lBs$c4U6=P z1;lC)gQx>>*g_bjB0_xP`qcmei9$t3-beS4@NrD=ROUng@e)v*t@CB&QJc?X#V|ry z(JAz9q8;r`2h5Dqao~9z=^Lx*LSdWukTs|V0uY=lVcFVhHiiJ!7xYl6^x)L=HXlS{ zwFB#i%oKx+a~)^H>&c#7PC^Z;I1(oK^K^lM{;M%)35Jdi%DC~XeHTbt3orPM+V$C* z@4Wp&H5FccxiJJ2%m91)bokc_3WwCZ83i>bfEUR~ZxDzIF2ersMC4#QZ$_=!<9Q#_ Q7+3K|+|z`)6%1JVgHgMmfQ;H2m3y%w*(d{g0nSm?Ull=W6hg4cqDUv2b0PE)&T WR^GExlV5i^W2f7Zi9*7R4AuaR0y3!p diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/OpenPerspective.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/OpenPerspective.gif deleted file mode 100644 index 420eee177528d9bd6d862c38d2a66c14835a6140..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 129 zcmZ?wbhEHb6krfw*vtS14M4Jip`qcxfddT<4GjN*-2XuK|Nmgte-L}loH;~uRaQAn7P!5RRp7cZRv diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/OpenProject.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/OpenProject.gif deleted file mode 100644 index 7efb86ec1008357fd0f3c9c9feef1a470844edee..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 213 zcmZ?wbhEHb6krfwI3mUHA0JNqxY4nxQse*s{|u-= z@h1x-1A`QU4oDbeCj)EH0=2%B%z5bx*j~(-pf9D##cb)n-hZ>S6+GNEh=hXt{*wUGHHfY(sY~DSvDy%9n$AGq|bKB zn&+Ccz%6HiXZ|AZ!X>`N%lwL$`IjvBFI^r`x_s^4%j@@F)eh^`3GdU1=+ler|NZy> zo@;McpMACE((66f-uTVA8Z!S{`KEh~+aESm&C*9=-Q5c>cA<9S`>2djIS1|L=ePfByad&CmbufBnDu`Ty&m|KI)k|K`{K*T4S1 z|NZ~-pa0+g{{Q{&|F3`l>zbR|I%+5MmCu|~xNv6n!kIZUCl@ZClkxxme}~T`~pIg6%-Aa zbd^-pG&Hs3AKmSyJqelE@oXlOjge=P0TG_J)F%$ie^s diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Redo.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Redo.gif deleted file mode 100644 index 10a87c20006d6a430b256fae745c6fdc2c40bdda..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 353 zcmZ?wbhEHb6krfw_{zZW=hw}@f1dsMdGp`j_kVvs`wL|Je)jvr=HDN-{QkJ*_se;| zU(Wyic;dSo-M^ns`~7tK?-%p#oa+AlV*ac9TYleb{e8dl_k+&g4|{(<>OH%o^!MXQ z_pa`|vMv75%Ct-S+pZsEV{QvY)`Y;=1SpR4WhdmMYq<7>}e9) zQ75{(P;h0Q;M!uL)rCSE%7m9?3#`Z$T%IHN|NnmmLO}5+3nK%A34;zuA;?b*Y;_K^ z3OsbAS~uSKsImCWw4>9OUTW%cSbzO#Q=+839$)gA3mFo6kJz7OY?m)M&TM94s>0n- zw=v*>qMC`kA_oUMCwm)bD~G0&q97A111~QtE7MGEXGLK~K@D|D4K_9w4HqqDVP$7k eX6CgnD$FXIx4Nka%WmH0CZ{4DaQLtzgEauAc$m!q diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Remove.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Remove.gif deleted file mode 100644 index 64b438488bcb51f639e52a3c685f55b740883016..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 350 zcmZ?wbhEHb6krfwxXQqAFDUd$XvEX-s3+l3*MdThhK7Bvto~e8{RxC>?gfP%@e4Za z7j!fz^mBg6Cm<>)Iqd2GAv*PabjlI$z{B2wpAs@ZBxHU{%e_=seQ(b4%iWD9GU85T z#vRX$JCT!crab5N()q_zVvom19gmMb79V{tFY9Y-)92QvhpEX&qauz*MLs-q=>Px! z3}gYtpDc_F47v7O@vFB`qe}(^LZldT0EV8>Vg_9 zLJJQmK3X=#VuqVqOJj;^TG)i+hd&0SPGDu0Xl7#d(B)+m7ZYRT^^oKinmn1O-c?d$ wGK(mSkg(`@Cf|62_ON9lcoOJ}bmOHOv5R7r!u*hlEj`sZrbR8M20XzVCnE(I) diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/RemoveProject.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/RemoveProject.gif deleted file mode 100644 index 0e536fbdfdd1b5c15f1b1fec38fcff52338102b1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 358 zcmZ?wbhEHb6krfwxN6C8CAH*uxB35%hyH&(^Z#P$|EsnCUvK{Zbjkl)o&WDoTVJaG z|Le_<_Cf#u|3Bew|Nqmab9r&cH4XlMICfN6_4=;q|KFc}YGC>2!;Z}bYDX2ck9L}U zE-E=0;Cxg<{gX$;_FBWAFE>6sJo`|)*)av3-3`Y7AI$r7f5qpN>|>G|`&&$oN~#~X zwftOMdbG=YOQpd{ce|%2CZ2S+|D2q)v0VSnh_kv4-V$E?}%PJ&`` xVuEI>tjm_`RVwqy@<=k6vuxUIY^lM+Ai}_-CBn7;fD?l-L*)_Q6RwU7)&M_rn;8HA diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Save.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Save.gif deleted file mode 100644 index 499dd0ca6021c351c641053be30eecb5b4a7e7e8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 639 zcmZ?wbhEHb6krfwc*el+6w~t;=?ud9vy7?cE^q z*1q%4_Md-x_|o&km!6%t_VVPl7w2!kK6mTY)%$O+-hXrZ@w-PaKBPA<&u(2-(6RIc zNcPq9H=oX5zOnP@<=ao*J$&)u*_+SB-Al@Q7r*)NC8Bg+ zz;2_n+r|KMbN2{G6a4_&{kGN)4gvc5juAGR#sRMOu1@w&t^vlzRuN`KMgigX?uQ4k zYgk5@s;SFPcrC52W*VWRCnlyRuKMMRsEVpigru?tONzsU2OVNcZfg!)N^s&3;9>A! zDQIQv=+@exGeO}YGc&uwQjf$B2b)>gB6wUn7Bn7go*uf&AmXGW<1{9LBBLK|i+M*v0+_d-|ihJAMZT%c+Z(9d(S>8 z=-*W~W#0}U_w18Hm!2QK^!(_R7ytgg|NVN&@7GIrOi|fB8HiMOO;=mrp|Gw)VRNt2 z=02r$9f~_9t8DI5Uf-ek|NnmmngPY1EQ|~ciVQj+8$f0W`wW{w%V-yYfVFK^BFpUx6ZO^wYG o&f-E{V$O11LZZ$xBEljv&eBsv;I&}kR~x;L)6}k- WmG`XFk diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/SetAttribute.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/SetAttribute.gif deleted file mode 100644 index 13dcfceaf4fe26594f82f6011d68e911702c5619..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 574 zcmZ?wbhEHb6krfwc*el+&MPH%GC&~LY< z$6FfuT>GU$L@4T=*6 z_Sp@tP0cN>Ee;)>9c@hxZ2c3Q9D1x6q^3z}IlD}5wU%b()Lv}w>}cI;!_Tj+%&4r* zuW8$AC&{#yiG@W{!>-jriEqPNW@aUeR!c>3bv KJX+wuU=09~V$sR~ diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/SetReference.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/SetReference.gif deleted file mode 100644 index 6edba7b3e4a7e0f9a053aba770fe0d8c7e2934ee..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 185 zcmZ?wbhEHb6krfwIKsf79W`Au|A=PZAOH%o^!MXQ z_pa`|vMv75%Ct-S+pZsEV{QvY)`Y;=1SpR4WhdmMYq<7>}e9) zQ75{(P;h0Q;M!uL)rCSE%7m9?3#`Z$T%IHN|NnmmLO}5+3nK%A34;zuA;?b*Yz+>x z3OsbA`nT|&ELNG=G56$V4=JD4tE&r4B&M`2KI!1hK7fZIWkxS0HZON`v3p{ diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Unset.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Unset.gif deleted file mode 100644 index 7787c40e9ca519699f3aadeb7725760a3d6cf7ae..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 120 zcmZ?wbhEHb6krfw*v!CSS{CBi5%1KV5IjFWcz!|rhU%qm_K2i5{GzVHM((q{G!C T;}O7Ev5q|Nde+_OTYvNDwKxC&|5yCU!pOkD&Y;5p v1R%8x%!(De?))=2<*6-W@%m!RPX!GV$3TG$FBaYh`wSA!mgL^%WUvMROWq=h diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/UnsetReference.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/UnsetReference.gif deleted file mode 100644 index 03ca23bcd2cbb20d938b5937953354230877c707..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 92 zcmZ?wbhEHb6krfwIK<8n?~$4xQrecGFSruBm*Jv diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Wizard.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/obj16/Wizard.gif deleted file mode 100644 index f302d8c882b0ffd7bcd1bb01a7f3ca634f048b6e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 167 zcmZ?wbhEHb6krfw*v!E2|347T-@kwU{rmg>-?!fnWX+%7(9jScAO9aHhXE9SvM@3* za5CtCWI$#xu!I<#v^?r4Ascnn;b@=;hkC`~>4~wglnx3qJbihOqkw^>>E1f;X9*fo z{SJ+eo0drAH61DZRpL6E)vr`wYTv&5x#FvROZPt5Q0Y`wG&l2Wq?hSAVL=9K022~E A)c^nh diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/wizban/NewModelingBot.gif b/plugins/org.eclipse.emf.eef.modelingbot.edit/icons/full/wizban/NewModelingBot.gif deleted file mode 100644 index 5db54235cf43b94b5a178a0638146079be418f8b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2462 zcmd6m`8OMg8ivzyXM`x-QPZJfTAHHK&QR5jT4P#9t7t6^##XzkW!$Ks6H6r4G!aW; zt;8;gy<$ls42=?%D3Kz9#?qG288hx*ao_Wt_s8!%-#OoBZEIy>>TM6W1^5Ek&)(kN z+WPj|`WHHLVuΞ?0RA8>{QvW^U=`?iuFp>ARn{SNi$yi@V>%R#6xtFY9X$lobXGwR~d4ZmTVe#0~-7toLeG*nT0dQk_4)PvopJFlV_SKWuJ zW)f-#itAV<`wWsBIW_bVYWpaSIYIB6?BxnrW3#;JrSa*-3894letAZ`CJ?PGNH@ij z^{Wpvu06^$f0%yVBkQ_H=1niO<>P<1z*zg{SovV=e$9miE&$iC73F8~zw0CEbNHuWX1lNFBYKlC>`anK2*V@EI< z)2>ce)e97yyO@tiQ!|Xvw8eTs(zGo6Ane9@+g$yNt%Pcs4*;zPr;^#5evo2?h~PUO4MC_>wMfRQ1Az>G~#;lAyDhiySg_C{I*1Dt?c_;8A8bBu@-WY*Er>dN_ zsj92@@9g=mm!DQXH2lik(?FjO^Lt$sy?fQwoXTgIDJ`D~xr+N>(+p2LsUi*C zac>txg>k1pEzCp%hiO81E#m|`vH6D0(6f5(8AY$c1Ae(7hR2`HMn|b%Dh>x3k50YWRP}KTcp#wME)rfZ7 zGFkijXH&yUh1KVV=wP>mivvM{-0)wnv!Qk@9k}yG`Ps^qdWz~vF|_OWAKV_Ux{^RU z4J-RPT~6jcZaimK!ma1IUi$T9ZxE`4>NY%dD!w67}WWRlaM$}s(PG5 zp-lxt_hi_(hFS^_5_+D{(qS?EXEa)+ueNz6o+qHApB#1u8UJ$Bqmg}6XC_+s?S)Q1 zZmh*2#uUk&i}(;cXlWvF9U7K#=o(;%q#U1kWjV)e)b(OXbLQf-%ivn9=(Y+t?ju7w zvP*lVBL8(ZCFa^sLZGsR(tMU@?d}`w7v*OFrWY}1q5f1cR9Nyo`7fam-D%b>a`}1G z=ykitU+qe-2$DSy3)XJMv2NB_-2n-1#0Z2ayy$4}FO4kJxpeuagKsE&&+g@y?bfzB zu{d0MXC-4!6?#t^C)K>{Bn4Jh$t@Q&thD z0?Y1Q&j7DY^~I##8{cT+8(2D* zn3(KfE8`3!wynk-*7~mY&>@kvp&mLa#f_w4&d;~B+sLhg>FTF@v0?XR_kohzgMXg@ zI5x0TPeH|ZVAUKCA~p{#ATb}~?0XJ#LP?qmM`PFk&$1)Oh7lFuOql}sq4fT$@e9Kx z@@YrCrqucL6eG2s3_l|hVG*`yIvmS^Z2%D{3)YX}rgr+5wK8q(Dqc|AMy({@Nw%nWHUV;KhX?P|iK>#YL1X12|N#TsA!R)sVHe5C3gWs1Tr&(i^!`?|44vYpj!?xore#UhJ- z06pguT-5$^5R~@g_z(A$^=F?S&LC4Gv$Aa-5dVxZk2?-Nfqii6UW&#WA5>%ELDL#r zT^#Z|Cx=?4pa;&o&e;dZm(@D~sb1gO^LsTu*QXx;=7tLi=>$-&^U?LcidRcN00NxI zV-LZ#NCm?Sy1+PZ7}OFkKT!BNw>%R`6y#r*&}gr&t0{CVjVO!0F0D z7#BR+I8tay!VdRS{u`GUc+2nI{e%6AXT4FtkZ9? - - - - - - - - - - - - - - - - %_UI_EEFActionsModelWizard_description - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/pom.xml b/plugins/org.eclipse.emf.eef.modelingbot.edit/pom.xml deleted file mode 100644 index 542b82f02..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/pom.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.modelingbot.edit - eclipse-plugin - - EEF ModelingBot Edit Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/AddItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/AddItemProvider.java deleted file mode 100644 index 54d205281..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/AddItemProvider.java +++ /dev/null @@ -1,166 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.Add; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.Add} object. - * - * - * @generated - */ -public class AddItemProvider - extends EditActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public AddItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addTypePropertyDescriptor(object); - addEContainingFeaturePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Type feature. - * - * - * @generated - */ - protected void addTypePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_Add_type_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_Add_type_feature", "_UI_Add_type"), - EEFActionsPackage.Literals.ADD__TYPE, - true, - false, - true, - null, - null, - null)); - } - - /** - * This adds a property descriptor for the EContaining Feature feature. - * - * - * @generated - */ - protected void addEContainingFeaturePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_Add_eContainingFeature_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_Add_eContainingFeature_feature", "_UI_Add_type"), - EEFActionsPackage.Literals.ADD__ECONTAINING_FEATURE, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns Add.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/Add")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Add)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Add_type") : - getString("_UI_Add_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/CancelItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/CancelItemProvider.java deleted file mode 100644 index 1f66f5521..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/CancelItemProvider.java +++ /dev/null @@ -1,143 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.Cancel; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.Cancel} object. - * - * - * @generated - */ -public class CancelItemProvider - extends EEFActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public CancelItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addProcessingPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Processing feature. - * - * - * @generated - */ - protected void addProcessingPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_Cancel_processing_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_Cancel_processing_feature", "_UI_Cancel_type"), - EEFActionsPackage.Literals.CANCEL__PROCESSING, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns Cancel.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/Cancel")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Cancel)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Cancel_type") : - getString("_UI_Cancel_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/CheckItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/CheckItemProvider.java deleted file mode 100644 index 47b201310..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/CheckItemProvider.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.Check; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.Check} object. - * - * - * @generated - */ -public class CheckItemProvider - extends EEFActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public CheckItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns Check.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/Check")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Check)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Check_type") : - getString("_UI_Check_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EEFActionItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EEFActionItemProvider.java deleted file mode 100644 index 77ff37439..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EEFActionItemProvider.java +++ /dev/null @@ -1,123 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFAction; - -import org.eclipse.emf.eef.modelingBot.provider.ActionItemProvider; -import org.eclipse.emf.eef.modelingBot.provider.MbotEditPlugin; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.EEFAction} object. - * - * - * @generated - */ -public class EEFActionItemProvider - extends ActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EEFActionItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EEFAction)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_EEFAction_type") : - getString("_UI_EEFAction_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return MbotEditPlugin.INSTANCE; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EEFActionsItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EEFActionsItemProviderAdapterFactory.java deleted file mode 100644 index 17ff99a5a..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EEFActionsItemProviderAdapterFactory.java +++ /dev/null @@ -1,471 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; - -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.util.EEFActionsAdapterFactory; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class EEFActionsItemProviderAdapterFactory extends EEFActionsAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public EEFActionsItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.Add} instances. - * - * - * @generated - */ - protected AddItemProvider addItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.Add}. - * - * - * @generated - */ - @Override - public Adapter createAddAdapter() { - if (addItemProvider == null) { - addItemProvider = new AddItemProvider(this); - } - - return addItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.Remove} instances. - * - * - * @generated - */ - protected RemoveItemProvider removeItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.Remove}. - * - * - * @generated - */ - @Override - public Adapter createRemoveAdapter() { - if (removeItemProvider == null) { - removeItemProvider = new RemoveItemProvider(this); - } - - return removeItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute} instances. - * - * - * @generated - */ - protected SetAttributeItemProvider setAttributeItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute}. - * - * - * @generated - */ - @Override - public Adapter createSetAttributeAdapter() { - if (setAttributeItemProvider == null) { - setAttributeItemProvider = new SetAttributeItemProvider(this); - } - - return setAttributeItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute} instances. - * - * - * @generated - */ - protected UnsetAttributeItemProvider unsetAttributeItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute}. - * - * - * @generated - */ - @Override - public Adapter createUnsetAttributeAdapter() { - if (unsetAttributeItemProvider == null) { - unsetAttributeItemProvider = new UnsetAttributeItemProvider(this); - } - - return unsetAttributeItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.Unset} instances. - * - * - * @generated - */ - protected UnsetItemProvider unsetItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.Unset}. - * - * - * @generated - */ - @Override - public Adapter createUnsetAdapter() { - if (unsetItemProvider == null) { - unsetItemProvider = new UnsetItemProvider(this); - } - - return unsetItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.Cancel} instances. - * - * - * @generated - */ - protected CancelItemProvider cancelItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.Cancel}. - * - * - * @generated - */ - @Override - public Adapter createCancelAdapter() { - if (cancelItemProvider == null) { - cancelItemProvider = new CancelItemProvider(this); - } - - return cancelItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.Check} instances. - * - * - * @generated - */ - protected CheckItemProvider checkItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.Check}. - * - * - * @generated - */ - @Override - public Adapter createCheckAdapter() { - if (checkItemProvider == null) { - checkItemProvider = new CheckItemProvider(this); - } - - return checkItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor} instances. - * - * - * @generated - */ - protected OpenEEFEditorItemProvider openEEFEditorItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor}. - * - * - * @generated - */ - @Override - public Adapter createOpenEEFEditorAdapter() { - if (openEEFEditorItemProvider == null) { - openEEFEditorItemProvider = new OpenEEFEditorItemProvider(this); - } - - return openEEFEditorItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.SetReference} instances. - * - * - * @generated - */ - protected SetReferenceItemProvider setReferenceItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.SetReference}. - * - * - * @generated - */ - @Override - public Adapter createSetReferenceAdapter() { - if (setReferenceItemProvider == null) { - setReferenceItemProvider = new SetReferenceItemProvider(this); - } - - return setReferenceItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference} instances. - * - * - * @generated - */ - protected UnsetReferenceItemProvider unsetReferenceItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference}. - * - * - * @generated - */ - @Override - public Adapter createUnsetReferenceAdapter() { - if (unsetReferenceItemProvider == null) { - unsetReferenceItemProvider = new UnsetReferenceItemProvider(this); - } - - return unsetReferenceItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp} instances. - * - * - * @generated - */ - protected MoveUpItemProvider moveUpItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp}. - * - * - * @generated - */ - @Override - public Adapter createMoveUpAdapter() { - if (moveUpItemProvider == null) { - moveUpItemProvider = new MoveUpItemProvider(this); - } - - return moveUpItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown} instances. - * - * - * @generated - */ - protected MoveDownItemProvider moveDownItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown}. - * - * - * @generated - */ - @Override - public Adapter createMoveDownAdapter() { - if (moveDownItemProvider == null) { - moveDownItemProvider = new MoveDownItemProvider(this); - } - - return moveDownItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) || (((Class)type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (addItemProvider != null) addItemProvider.dispose(); - if (removeItemProvider != null) removeItemProvider.dispose(); - if (setAttributeItemProvider != null) setAttributeItemProvider.dispose(); - if (unsetAttributeItemProvider != null) unsetAttributeItemProvider.dispose(); - if (unsetItemProvider != null) unsetItemProvider.dispose(); - if (cancelItemProvider != null) cancelItemProvider.dispose(); - if (checkItemProvider != null) checkItemProvider.dispose(); - if (openEEFEditorItemProvider != null) openEEFEditorItemProvider.dispose(); - if (setReferenceItemProvider != null) setReferenceItemProvider.dispose(); - if (unsetReferenceItemProvider != null) unsetReferenceItemProvider.dispose(); - if (moveUpItemProvider != null) moveUpItemProvider.dispose(); - if (moveDownItemProvider != null) moveDownItemProvider.dispose(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EditActionItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EditActionItemProvider.java deleted file mode 100644 index e2e164a25..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/EditActionItemProvider.java +++ /dev/null @@ -1,155 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.EditAction; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.EditAction} object. - * - * - * @generated - */ -public class EditActionItemProvider - extends EEFActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EditActionItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addPropertiesEditionElementPropertyDescriptor(object); - addReferenceableObjectPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Properties Edition Element feature. - * - * - * @generated - */ - protected void addPropertiesEditionElementPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EditAction_propertiesEditionElement_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EditAction_propertiesEditionElement_feature", "_UI_EditAction_type"), - EEFActionsPackage.Literals.EDIT_ACTION__PROPERTIES_EDITION_ELEMENT, - true, - false, - true, - null, - null, - null)); - } - - /** - * This adds a property descriptor for the Referenceable Object feature. - * - * - * @generated - */ - protected void addReferenceableObjectPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_EditAction_referenceableObject_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_EditAction_referenceableObject_feature", "_UI_EditAction_type"), - EEFActionsPackage.Literals.EDIT_ACTION__REFERENCEABLE_OBJECT, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EditAction)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_EditAction_type") : - getString("_UI_EditAction_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/MoveDownItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/MoveDownItemProvider.java deleted file mode 100644 index bceae34df..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/MoveDownItemProvider.java +++ /dev/null @@ -1,114 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown} object. - * - * - * @generated - */ -public class MoveDownItemProvider - extends EditActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public MoveDownItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns MoveDown.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/MoveDown")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((MoveDown)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_MoveDown_type") : - getString("_UI_MoveDown_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/MoveUpItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/MoveUpItemProvider.java deleted file mode 100644 index b8bfbc33e..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/MoveUpItemProvider.java +++ /dev/null @@ -1,114 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp} object. - * - * - * @generated - */ -public class MoveUpItemProvider - extends EditActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public MoveUpItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns MoveUp.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/MoveUp")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((MoveUp)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_MoveUp_type") : - getString("_UI_MoveUp_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/OpenEEFEditorItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/OpenEEFEditorItemProvider.java deleted file mode 100644 index deed482d7..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/OpenEEFEditorItemProvider.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor} object. - * - * - * @generated - */ -public class OpenEEFEditorItemProvider - extends EEFActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public OpenEEFEditorItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addEditorNamePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Editor Name feature. - * - * - * @generated - */ - protected void addEditorNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_OpenEEFEditor_editorName_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_OpenEEFEditor_editorName_feature", "_UI_OpenEEFEditor_type"), - EEFActionsPackage.Literals.OPEN_EEF_EDITOR__EDITOR_NAME, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns OpenEEFEditor.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/OpenEEFEditor")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((OpenEEFEditor)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_OpenEEFEditor_type") : - getString("_UI_OpenEEFEditor_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(OpenEEFEditor.class)) { - case EEFActionsPackage.OPEN_EEF_EDITOR__EDITOR_NAME: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/RemoveItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/RemoveItemProvider.java deleted file mode 100644 index 39f8d56f4..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/RemoveItemProvider.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.Remove; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.Remove} object. - * - * - * @generated - */ -public class RemoveItemProvider - extends EditActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public RemoveItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns Remove.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/Remove")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Remove)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Remove_type") : - getString("_UI_Remove_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/SetAttributeItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/SetAttributeItemProvider.java deleted file mode 100644 index 14f06622b..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/SetAttributeItemProvider.java +++ /dev/null @@ -1,174 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute} object. - * - * - * @generated - */ -public class SetAttributeItemProvider - extends EditActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public SetAttributeItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addValuesPropertyDescriptor(object); - addEContainingFeaturePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Values feature. - * - * - * @generated - */ - protected void addValuesPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_SetAttribute_values_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_SetAttribute_values_feature", "_UI_SetAttribute_type"), - EEFActionsPackage.Literals.SET_ATTRIBUTE__VALUES, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the EContaining Feature feature. - * - * - * @generated - */ - protected void addEContainingFeaturePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_SetAttribute_eContainingFeature_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_SetAttribute_eContainingFeature_feature", "_UI_SetAttribute_type"), - EEFActionsPackage.Literals.SET_ATTRIBUTE__ECONTAINING_FEATURE, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns SetAttribute.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/SetAttribute")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((SetAttribute)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_SetAttribute_type") : - getString("_UI_SetAttribute_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(SetAttribute.class)) { - case EEFActionsPackage.SET_ATTRIBUTE__VALUES: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/SetReferenceItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/SetReferenceItemProvider.java deleted file mode 100644 index 01f1edafe..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/SetReferenceItemProvider.java +++ /dev/null @@ -1,166 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.SetReference; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.SetReference} object. - * - * - * @generated - */ -public class SetReferenceItemProvider - extends EditActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public SetReferenceItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addValuesPropertyDescriptor(object); - addEContainingFeaturePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Values feature. - * - * - * @generated - */ - protected void addValuesPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_SetReference_values_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_SetReference_values_feature", "_UI_SetReference_type"), - EEFActionsPackage.Literals.SET_REFERENCE__VALUES, - true, - false, - true, - null, - null, - null)); - } - - /** - * This adds a property descriptor for the EContaining Feature feature. - * - * - * @generated - */ - protected void addEContainingFeaturePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_SetReference_eContainingFeature_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_SetReference_eContainingFeature_feature", "_UI_SetReference_type"), - EEFActionsPackage.Literals.SET_REFERENCE__ECONTAINING_FEATURE, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns SetReference.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/SetReference")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((SetReference)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_SetReference_type") : - getString("_UI_SetReference_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetAttributeItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetAttributeItemProvider.java deleted file mode 100644 index e803df2ae..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetAttributeItemProvider.java +++ /dev/null @@ -1,170 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute} object. - * - * - * @generated - */ -public class UnsetAttributeItemProvider - extends EditActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public UnsetAttributeItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addValuesPropertyDescriptor(object); - addEContainingFeaturePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Values feature. - * - * - * @generated - */ - protected void addValuesPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_UnsetAttribute_values_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_UnsetAttribute_values_feature", "_UI_UnsetAttribute_type"), - EEFActionsPackage.Literals.UNSET_ATTRIBUTE__VALUES, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the EContaining Feature feature. - * - * - * @generated - */ - protected void addEContainingFeaturePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_UnsetAttribute_eContainingFeature_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_UnsetAttribute_eContainingFeature_feature", "_UI_UnsetAttribute_type"), - EEFActionsPackage.Literals.UNSET_ATTRIBUTE__ECONTAINING_FEATURE, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns UnsetAttribute.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/UnsetAttribute")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((UnsetAttribute)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_UnsetAttribute_type") : - getString("_UI_UnsetAttribute_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(UnsetAttribute.class)) { - case EEFActionsPackage.UNSET_ATTRIBUTE__VALUES: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetItemProvider.java deleted file mode 100644 index 00421f0fa..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetItemProvider.java +++ /dev/null @@ -1,143 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.Unset; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.Unset} object. - * - * - * @generated - */ -public class UnsetItemProvider - extends EditActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public UnsetItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addFeaturePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Feature feature. - * - * - * @generated - */ - protected void addFeaturePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_Unset_feature_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_Unset_feature_feature", "_UI_Unset_type"), - EEFActionsPackage.Literals.UNSET__FEATURE, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns Unset.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/Unset")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Unset)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Unset_type") : - getString("_UI_Unset_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetReferenceItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetReferenceItemProvider.java deleted file mode 100644 index 678070301..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/provider/UnsetReferenceItemProvider.java +++ /dev/null @@ -1,162 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference} object. - * - * - * @generated - */ -public class UnsetReferenceItemProvider - extends EditActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public UnsetReferenceItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addFeaturePropertyDescriptor(object); - addValuesPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Feature feature. - * - * - * @generated - */ - protected void addFeaturePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_UnsetReference_feature_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_UnsetReference_feature_feature", "_UI_UnsetReference_type"), - EEFActionsPackage.Literals.UNSET_REFERENCE__FEATURE, - true, - false, - true, - null, - null, - null)); - } - - /** - * This adds a property descriptor for the Values feature. - * - * - * @generated - */ - protected void addValuesPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_UnsetReference_values_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_UnsetReference_values_feature", "_UI_UnsetReference_type"), - EEFActionsPackage.Literals.UNSET_REFERENCE__VALUES, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns UnsetReference.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/UnsetReference")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((UnsetReference)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_UnsetReference_type") : - getString("_UI_UnsetReference_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CloseEditorItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CloseEditorItemProvider.java deleted file mode 100644 index d39e3b580..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CloseEditorItemProvider.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor} object. - * - * - * @generated - */ -public class CloseEditorItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public CloseEditorItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addPathPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Path feature. - * - * - * @generated - */ - protected void addPathPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_CloseEditor_path_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_CloseEditor_path_feature", "_UI_CloseEditor_type"), - EclipseActionsPackage.Literals.CLOSE_EDITOR__PATH, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns CloseEditor.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/CloseEditor")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((CloseEditor)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_CloseEditor_type") : - getString("_UI_CloseEditor_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(CloseEditor.class)) { - case EclipseActionsPackage.CLOSE_EDITOR__PATH: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CloseProjectItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CloseProjectItemProvider.java deleted file mode 100644 index eea4dc1ab..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CloseProjectItemProvider.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject} object. - * - * - * @generated - */ -public class CloseProjectItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public CloseProjectItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addProjectNamePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Project Name feature. - * - * - * @generated - */ - protected void addProjectNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_CloseProject_projectName_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_CloseProject_projectName_feature", "_UI_CloseProject_type"), - EclipseActionsPackage.Literals.CLOSE_PROJECT__PROJECT_NAME, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns CloseProject.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/CloseProject")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((CloseProject)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_CloseProject_type") : - getString("_UI_CloseProject_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(CloseProject.class)) { - case EclipseActionsPackage.CLOSE_PROJECT__PROJECT_NAME: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CreateModelItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CreateModelItemProvider.java deleted file mode 100644 index 8e6bf9dd3..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CreateModelItemProvider.java +++ /dev/null @@ -1,198 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel} object. - * - * - * @generated - */ -public class CreateModelItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public CreateModelItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addModelNamePropertyDescriptor(object); - addPathPropertyDescriptor(object); - addRootPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Model Name feature. - * - * - * @generated - */ - protected void addModelNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_CreateModel_modelName_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_CreateModel_modelName_feature", "_UI_CreateModel_type"), - EclipseActionsPackage.Literals.CREATE_MODEL__MODEL_NAME, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Path feature. - * - * - * @generated - */ - protected void addPathPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_CreateModel_path_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_CreateModel_path_feature", "_UI_CreateModel_type"), - EclipseActionsPackage.Literals.CREATE_MODEL__PATH, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Root feature. - * - * - * @generated - */ - protected void addRootPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_CreateModel_root_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_CreateModel_root_feature", "_UI_CreateModel_type"), - EclipseActionsPackage.Literals.CREATE_MODEL__ROOT, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns CreateModel.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/CreateModel")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((CreateModel)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_CreateModel_type") : - getString("_UI_CreateModel_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(CreateModel.class)) { - case EclipseActionsPackage.CREATE_MODEL__MODEL_NAME: - case EclipseActionsPackage.CREATE_MODEL__PATH: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CreateProjectItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CreateProjectItemProvider.java deleted file mode 100644 index b21a5eaa9..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/CreateProjectItemProvider.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject} object. - * - * - * @generated - */ -public class CreateProjectItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public CreateProjectItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addProjectNamePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Project Name feature. - * - * - * @generated - */ - protected void addProjectNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_CreateProject_projectName_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_CreateProject_projectName_feature", "_UI_CreateProject_type"), - EclipseActionsPackage.Literals.CREATE_PROJECT__PROJECT_NAME, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns CreateProject.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/CreateProject")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((CreateProject)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_CreateProject_type") : - getString("_UI_CreateProject_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(CreateProject.class)) { - case EclipseActionsPackage.CREATE_PROJECT__PROJECT_NAME: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/EclipseActionItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/EclipseActionItemProvider.java deleted file mode 100644 index 2f4fce9a3..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/EclipseActionItemProvider.java +++ /dev/null @@ -1,123 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseAction; - -import org.eclipse.emf.eef.modelingBot.provider.ActionItemProvider; -import org.eclipse.emf.eef.modelingBot.provider.MbotEditPlugin; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseAction} object. - * - * - * @generated - */ -public class EclipseActionItemProvider - extends ActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public EclipseActionItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((EclipseAction)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_EclipseAction_type") : - getString("_UI_EclipseAction_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return MbotEditPlugin.INSTANCE; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/EclipseActionsItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/EclipseActionsItemProviderAdapterFactory.java deleted file mode 100644 index a444eaa22..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/EclipseActionsItemProviderAdapterFactory.java +++ /dev/null @@ -1,447 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; - -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.util.EclipseActionsAdapterFactory; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class EclipseActionsItemProviderAdapterFactory extends EclipseActionsAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public EclipseActionsItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject} instances. - * - * - * @generated - */ - protected CreateProjectItemProvider createProjectItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject}. - * - * - * @generated - */ - @Override - public Adapter createCreateProjectAdapter() { - if (createProjectItemProvider == null) { - createProjectItemProvider = new CreateProjectItemProvider(this); - } - - return createProjectItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective} instances. - * - * - * @generated - */ - protected OpenPerspectiveItemProvider openPerspectiveItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective}. - * - * - * @generated - */ - @Override - public Adapter createOpenPerspectiveAdapter() { - if (openPerspectiveItemProvider == null) { - openPerspectiveItemProvider = new OpenPerspectiveItemProvider(this); - } - - return openPerspectiveItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject} instances. - * - * - * @generated - */ - protected CloseProjectItemProvider closeProjectItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject}. - * - * - * @generated - */ - @Override - public Adapter createCloseProjectAdapter() { - if (closeProjectItemProvider == null) { - closeProjectItemProvider = new CloseProjectItemProvider(this); - } - - return closeProjectItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.Save} instances. - * - * - * @generated - */ - protected SaveItemProvider saveItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.Save}. - * - * - * @generated - */ - @Override - public Adapter createSaveAdapter() { - if (saveItemProvider == null) { - saveItemProvider = new SaveItemProvider(this); - } - - return saveItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.Undo} instances. - * - * - * @generated - */ - protected UndoItemProvider undoItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.Undo}. - * - * - * @generated - */ - @Override - public Adapter createUndoAdapter() { - if (undoItemProvider == null) { - undoItemProvider = new UndoItemProvider(this); - } - - return undoItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.Redo} instances. - * - * - * @generated - */ - protected RedoItemProvider redoItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.Redo}. - * - * - * @generated - */ - @Override - public Adapter createRedoAdapter() { - if (redoItemProvider == null) { - redoItemProvider = new RedoItemProvider(this); - } - - return redoItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject} instances. - * - * - * @generated - */ - protected OpenProjectItemProvider openProjectItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject}. - * - * - * @generated - */ - @Override - public Adapter createOpenProjectAdapter() { - if (openProjectItemProvider == null) { - openProjectItemProvider = new OpenProjectItemProvider(this); - } - - return openProjectItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject} instances. - * - * - * @generated - */ - protected RemoveProjectItemProvider removeProjectItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject}. - * - * - * @generated - */ - @Override - public Adapter createRemoveProjectAdapter() { - if (removeProjectItemProvider == null) { - removeProjectItemProvider = new RemoveProjectItemProvider(this); - } - - return removeProjectItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor} instances. - * - * - * @generated - */ - protected CloseEditorItemProvider closeEditorItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor}. - * - * - * @generated - */ - @Override - public Adapter createCloseEditorAdapter() { - if (closeEditorItemProvider == null) { - closeEditorItemProvider = new CloseEditorItemProvider(this); - } - - return closeEditorItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor} instances. - * - * - * @generated - */ - protected OpenEditorItemProvider openEditorItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor}. - * - * - * @generated - */ - @Override - public Adapter createOpenEditorAdapter() { - if (openEditorItemProvider == null) { - openEditorItemProvider = new OpenEditorItemProvider(this); - } - - return openEditorItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel} instances. - * - * - * @generated - */ - protected CreateModelItemProvider createModelItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel}. - * - * - * @generated - */ - @Override - public Adapter createCreateModelAdapter() { - if (createModelItemProvider == null) { - createModelItemProvider = new CreateModelItemProvider(this); - } - - return createModelItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) || (((Class)type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (createProjectItemProvider != null) createProjectItemProvider.dispose(); - if (openPerspectiveItemProvider != null) openPerspectiveItemProvider.dispose(); - if (closeProjectItemProvider != null) closeProjectItemProvider.dispose(); - if (saveItemProvider != null) saveItemProvider.dispose(); - if (undoItemProvider != null) undoItemProvider.dispose(); - if (redoItemProvider != null) redoItemProvider.dispose(); - if (openProjectItemProvider != null) openProjectItemProvider.dispose(); - if (removeProjectItemProvider != null) removeProjectItemProvider.dispose(); - if (closeEditorItemProvider != null) closeEditorItemProvider.dispose(); - if (openEditorItemProvider != null) openEditorItemProvider.dispose(); - if (createModelItemProvider != null) createModelItemProvider.dispose(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenEditorItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenEditorItemProvider.java deleted file mode 100644 index b95b2b2b0..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenEditorItemProvider.java +++ /dev/null @@ -1,170 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor} object. - * - * - * @generated - */ -public class OpenEditorItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public OpenEditorItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addEditorNamePropertyDescriptor(object); - addRootPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Editor Name feature. - * - * - * @generated - */ - protected void addEditorNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_OpenEditor_editorName_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_OpenEditor_editorName_feature", "_UI_OpenEditor_type"), - EclipseActionsPackage.Literals.OPEN_EDITOR__EDITOR_NAME, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Root feature. - * - * - * @generated - */ - protected void addRootPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_OpenEditor_root_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_OpenEditor_root_feature", "_UI_OpenEditor_type"), - EclipseActionsPackage.Literals.OPEN_EDITOR__ROOT, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns OpenEditor.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/OpenEditor")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((OpenEditor)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_OpenEditor_type") : - getString("_UI_OpenEditor_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(OpenEditor.class)) { - case EclipseActionsPackage.OPEN_EDITOR__EDITOR_NAME: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenPerspectiveItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenPerspectiveItemProvider.java deleted file mode 100644 index 4636c8f9d..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenPerspectiveItemProvider.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective} object. - * - * - * @generated - */ -public class OpenPerspectiveItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public OpenPerspectiveItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addTypePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Type feature. - * - * - * @generated - */ - protected void addTypePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_OpenPerspective_type_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_OpenPerspective_type_feature", "_UI_OpenPerspective_type"), - EclipseActionsPackage.Literals.OPEN_PERSPECTIVE__TYPE, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns OpenPerspective.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/OpenPerspective")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((OpenPerspective)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_OpenPerspective_type") : - getString("_UI_OpenPerspective_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(OpenPerspective.class)) { - case EclipseActionsPackage.OPEN_PERSPECTIVE__TYPE: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenProjectItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenProjectItemProvider.java deleted file mode 100644 index a32598b35..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/OpenProjectItemProvider.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject} object. - * - * - * @generated - */ -public class OpenProjectItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public OpenProjectItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addProjectNamePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Project Name feature. - * - * - * @generated - */ - protected void addProjectNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_OpenProject_projectName_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_OpenProject_projectName_feature", "_UI_OpenProject_type"), - EclipseActionsPackage.Literals.OPEN_PROJECT__PROJECT_NAME, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns OpenProject.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/OpenProject")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((OpenProject)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_OpenProject_type") : - getString("_UI_OpenProject_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(OpenProject.class)) { - case EclipseActionsPackage.OPEN_PROJECT__PROJECT_NAME: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/RedoItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/RedoItemProvider.java deleted file mode 100644 index 41e444d2d..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/RedoItemProvider.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.Redo; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.Redo} object. - * - * - * @generated - */ -public class RedoItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public RedoItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns Redo.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/Redo")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Redo)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Redo_type") : - getString("_UI_Redo_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/RemoveProjectItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/RemoveProjectItemProvider.java deleted file mode 100644 index 7723ea265..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/RemoveProjectItemProvider.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject} object. - * - * - * @generated - */ -public class RemoveProjectItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public RemoveProjectItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addProjectNamePropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Project Name feature. - * - * - * @generated - */ - protected void addProjectNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_RemoveProject_projectName_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_RemoveProject_projectName_feature", "_UI_RemoveProject_type"), - EclipseActionsPackage.Literals.REMOVE_PROJECT__PROJECT_NAME, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns RemoveProject.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/RemoveProject")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((RemoveProject)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_RemoveProject_type") : - getString("_UI_RemoveProject_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(RemoveProject.class)) { - case EclipseActionsPackage.REMOVE_PROJECT__PROJECT_NAME: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/SaveItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/SaveItemProvider.java deleted file mode 100644 index c184c7d35..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/SaveItemProvider.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.Save; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.Save} object. - * - * - * @generated - */ -public class SaveItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public SaveItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns Save.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/Save")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Save)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Save_type") : - getString("_UI_Save_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/UndoItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/UndoItemProvider.java deleted file mode 100644 index f5230bac6..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/provider/UndoItemProvider.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.Undo; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.EclipseActions.Undo} object. - * - * - * @generated - */ -public class UndoItemProvider - extends EclipseActionItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public UndoItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns Undo.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/Undo")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Undo)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Undo_type") : - getString("_UI_Undo_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ActionItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ActionItemProvider.java deleted file mode 100755 index 8fcea3098..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ActionItemProvider.java +++ /dev/null @@ -1,107 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.Action; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.Action} object. - * - * - * @generated - */ -public class ActionItemProvider - extends DocumentedElementItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public ActionItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Action)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Action_type") : - getString("_UI_Action_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/DetailsPageItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/DetailsPageItemProvider.java deleted file mode 100755 index a69f6dcb2..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/DetailsPageItemProvider.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.DetailsPage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.DetailsPage} object. - * - * - * @generated - */ -public class DetailsPageItemProvider - extends SequenceItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public DetailsPageItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns DetailsPage.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/DetailsPage")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((DetailsPage)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_DetailsPage_type") : - getString("_UI_DetailsPage_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/DocumentedElementItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/DocumentedElementItemProvider.java deleted file mode 100755 index 1a511b8cf..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/DocumentedElementItemProvider.java +++ /dev/null @@ -1,178 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.DocumentedElement; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.DocumentedElement} object. - * - * - * @generated - */ -public class DocumentedElementItemProvider - extends ItemProviderAdapter - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public DocumentedElementItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addNamePropertyDescriptor(object); - addDocumentationPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Name feature. - * - * - * @generated - */ - protected void addNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_DocumentedElement_name_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_DocumentedElement_name_feature", "_UI_DocumentedElement_type"), - ModelingBotPackage.Literals.DOCUMENTED_ELEMENT__NAME, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This adds a property descriptor for the Documentation feature. - * - * - * @generated - */ - protected void addDocumentationPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_DocumentedElement_documentation_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_DocumentedElement_documentation_feature", "_UI_DocumentedElement_type"), - ModelingBotPackage.Literals.DOCUMENTED_ELEMENT__DOCUMENTATION, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((DocumentedElement)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_DocumentedElement_type") : - getString("_UI_DocumentedElement_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(DocumentedElement.class)) { - case ModelingBotPackage.DOCUMENTED_ELEMENT__NAME: - case ModelingBotPackage.DOCUMENTED_ELEMENT__DOCUMENTATION: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return MbotEditPlugin.INSTANCE; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/MbotEditPlugin.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/MbotEditPlugin.java deleted file mode 100755 index 001ae3158..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/MbotEditPlugin.java +++ /dev/null @@ -1,114 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.provider; - -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelEditPlugin; - -import org.eclipse.emf.common.EMFPlugin; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.ecore.provider.EcoreEditPlugin; - -import org.eclipse.emf.eef.components.provider.ComponentsEditPlugin; - -import org.eclipse.emf.eef.extended.editor.provider.ExtendedEditPlugin; - -import org.eclipse.emf.eef.mapping.provider.MappingEditPlugin; - -import org.eclipse.emf.eef.views.provider.ViewsEditPlugin; - -/** - * This is the central singleton for the Mbot edit plugin. - * - * @generated - */ -public final class MbotEditPlugin extends EMFPlugin { - /** - * Keep track of the singleton. - * - * @generated - */ - public static final MbotEditPlugin INSTANCE = new MbotEditPlugin(); - - /** - * EEF Editor ID - * - * @generated NOT - */ - public static final String INTERACTIVE_EEF_EDITOR_ID = "org.eclipse.emf.eef.runtime.ui.editor.InteractiveEEFEditorID"; - - /** - * Keep track of the singleton. - * - * @generated - */ - private static Implementation plugin; - - /** - * Create the instance. - * - * @generated - */ - public MbotEditPlugin() { - super - (new ResourceLocator [] { - ComponentsEditPlugin.INSTANCE, - EcoreEditPlugin.INSTANCE, - ExtendedEditPlugin.INSTANCE, - GenModelEditPlugin.INSTANCE, - MappingEditPlugin.INSTANCE, - ViewsEditPlugin.INSTANCE, - }); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * @return the singleton instance. - * @generated - */ - @Override - public ResourceLocator getPluginResourceLocator() { - return plugin; - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * @generated - */ - public static class Implementation extends EclipsePlugin { - /** - * Creates an instance. - * - * @generated - */ - public Implementation() { - super(); - - // Remember the static instance. - // - plugin = this; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ModelingBotItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ModelingBotItemProvider.java deleted file mode 100755 index 2be4c6040..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ModelingBotItemProvider.java +++ /dev/null @@ -1,237 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.ecore.EStructuralFeature; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.ModelingBot; -import org.eclipse.emf.eef.modelingBot.ModelingBotFactory; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.ModelingBot} object. - * - * - * @generated - */ -public class ModelingBotItemProvider - extends ItemProviderAdapter - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public ModelingBotItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addPropertiesEditionContextPropertyDescriptor(object); - addSequencesPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Properties Edition Context feature. - * - * - * @generated - */ - protected void addPropertiesEditionContextPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_ModelingBot_propertiesEditionContext_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_ModelingBot_propertiesEditionContext_feature", "_UI_ModelingBot_type"), - ModelingBotPackage.Literals.MODELING_BOT__PROPERTIES_EDITION_CONTEXT, - true, - false, - true, - null, - null, - null)); - } - - /** - * This adds a property descriptor for the Sequences feature. - * - * - * @generated - */ - protected void addSequencesPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_ModelingBot_sequences_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_ModelingBot_sequences_feature", "_UI_ModelingBot_type"), - ModelingBotPackage.Literals.MODELING_BOT__SEQUENCES, - true, - false, - true, - null, - null, - null)); - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures(Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures.add(ModelingBotPackage.Literals.MODELING_BOT__SEQUENCES); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns ModelingBot.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/ModelingBot")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - return getString("_UI_ModelingBot_type"); - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(ModelingBot.class)) { - case ModelingBotPackage.MODELING_BOT__SEQUENCES: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.MODELING_BOT__SEQUENCES, - ModelingBotFactory.eINSTANCE.createScenario())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.MODELING_BOT__SEQUENCES, - ModelingBotFactory.eINSTANCE.createWizard())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.MODELING_BOT__SEQUENCES, - ModelingBotFactory.eINSTANCE.createDetailsPage())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.MODELING_BOT__SEQUENCES, - ModelingBotFactory.eINSTANCE.createPropertiesView())); - } - - /** - * Return the resource locator for this item provider's resources. - * - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return MbotEditPlugin.INSTANCE; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ModelingBotItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ModelingBotItemProviderAdapterFactory.java deleted file mode 100755 index 83e9a4988..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ModelingBotItemProviderAdapterFactory.java +++ /dev/null @@ -1,303 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.provider; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; - -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IDisposable; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.util.ModelingBotAdapterFactory; - -/** - * This is the factory that is used to provide the interfaces needed to support Viewers. - * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. - * The adapters also support Eclipse property sheets. - * Note that most of the adapters are shared among multiple instances. - * - * - * @generated - */ -public class ModelingBotItemProviderAdapterFactory extends ModelingBotAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - * - * - * @generated - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. - * - * - * @generated - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. - * - * - * @generated - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - * - * - * @generated - */ - public ModelingBotItemProviderAdapterFactory() { - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(IItemPropertySource.class); - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.Scenario} instances. - * - * - * @generated - */ - protected ScenarioItemProvider scenarioItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.Scenario}. - * - * - * @generated - */ - @Override - public Adapter createScenarioAdapter() { - if (scenarioItemProvider == null) { - scenarioItemProvider = new ScenarioItemProvider(this); - } - - return scenarioItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.Wizard} instances. - * - * - * @generated - */ - protected WizardItemProvider wizardItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.Wizard}. - * - * - * @generated - */ - @Override - public Adapter createWizardAdapter() { - if (wizardItemProvider == null) { - wizardItemProvider = new WizardItemProvider(this); - } - - return wizardItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.ModelingBot} instances. - * - * - * @generated - */ - protected ModelingBotItemProvider modelingBotItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.ModelingBot}. - * - * - * @generated - */ - @Override - public Adapter createModelingBotAdapter() { - if (modelingBotItemProvider == null) { - modelingBotItemProvider = new ModelingBotItemProvider(this); - } - - return modelingBotItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.DetailsPage} instances. - * - * - * @generated - */ - protected DetailsPageItemProvider detailsPageItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.DetailsPage}. - * - * - * @generated - */ - @Override - public Adapter createDetailsPageAdapter() { - if (detailsPageItemProvider == null) { - detailsPageItemProvider = new DetailsPageItemProvider(this); - } - - return detailsPageItemProvider; - } - - /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.eef.modelingBot.PropertiesView} instances. - * - * - * @generated - */ - protected PropertiesViewItemProvider propertiesViewItemProvider; - - /** - * This creates an adapter for a {@link org.eclipse.emf.eef.modelingBot.PropertiesView}. - * - * - * @generated - */ - @Override - public Adapter createPropertiesViewAdapter() { - if (propertiesViewItemProvider == null) { - propertiesViewItemProvider = new PropertiesViewItemProvider(this); - } - - return propertiesViewItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - * - * - * @generated - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - * - * - * @generated - */ - public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public boolean isFactoryForType(Object type) { - return supportedTypes.contains(type) || super.isFactoryForType(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - * - * - * @generated - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - /** - * - * - * @generated - */ - @Override - public Object adapt(Object object, Object type) { - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) || (((Class)type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * This adds a listener. - * - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. - * - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This disposes all of the item providers created by this factory. - * - * - * @generated - */ - public void dispose() { - if (scenarioItemProvider != null) scenarioItemProvider.dispose(); - if (wizardItemProvider != null) wizardItemProvider.dispose(); - if (modelingBotItemProvider != null) modelingBotItemProvider.dispose(); - if (detailsPageItemProvider != null) detailsPageItemProvider.dispose(); - if (propertiesViewItemProvider != null) propertiesViewItemProvider.dispose(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/PropertiesViewItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/PropertiesViewItemProvider.java deleted file mode 100755 index fddeb9440..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/PropertiesViewItemProvider.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.PropertiesView; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.PropertiesView} object. - * - * - * @generated - */ -public class PropertiesViewItemProvider - extends SequenceItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public PropertiesViewItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addIdPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Id feature. - * - * - * @generated - */ - protected void addIdPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_PropertiesView_id_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_PropertiesView_id_feature", "_UI_PropertiesView_type"), - ModelingBotPackage.Literals.PROPERTIES_VIEW__ID, - true, - false, - false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, - null)); - } - - /** - * This returns PropertiesView.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/PropertiesView")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((PropertiesView)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_PropertiesView_type") : - getString("_UI_PropertiesView_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(PropertiesView.class)) { - case ModelingBotPackage.PROPERTIES_VIEW__ID: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ScenarioItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ScenarioItemProvider.java deleted file mode 100755 index f3f424856..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/ScenarioItemProvider.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.Scenario; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.Scenario} object. - * - * - * @generated - */ -public class ScenarioItemProvider - extends SequenceItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public ScenarioItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - } - return itemPropertyDescriptors; - } - - /** - * This returns Scenario.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/Scenario")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Scenario)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Scenario_type") : - getString("_UI_Scenario_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/SequenceItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/SequenceItemProvider.java deleted file mode 100755 index 3208162b3..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/SequenceItemProvider.java +++ /dev/null @@ -1,311 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EStructuralFeature; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ViewerNotification; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsFactory; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsFactory; - -import org.eclipse.emf.eef.modelingBot.ModelingBotFactory; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.Sequence; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.Sequence} object. - * - * - * @generated - */ -public class SequenceItemProvider - extends DocumentedElementItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public SequenceItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addSequencesPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Sequences feature. - * - * - * @generated - */ - protected void addSequencesPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_Sequence_sequences_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_Sequence_sequences_feature", "_UI_Sequence_type"), - ModelingBotPackage.Literals.SEQUENCE__SEQUENCES, - true, - false, - true, - null, - null, - null)); - } - - /** - * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an - * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or - * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. - * - * - * @generated - */ - @Override - public Collection getChildrenFeatures(Object object) { - if (childrenFeatures == null) { - super.getChildrenFeatures(object); - childrenFeatures.add(ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS); - } - return childrenFeatures; - } - - /** - * - * - * @generated - */ - @Override - protected EStructuralFeature getChildFeature(Object object, Object child) { - // Check the type of the specified child object and return the proper feature to use for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildFeature(object, child); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Sequence)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Sequence_type") : - getString("_UI_Sequence_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - - switch (notification.getFeatureID(Sequence.class)) { - case ModelingBotPackage.SEQUENCE__PROCESSINGS: - fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); - return; - } - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - ModelingBotFactory.eINSTANCE.createScenario())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - ModelingBotFactory.eINSTANCE.createWizard())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - ModelingBotFactory.eINSTANCE.createDetailsPage())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - ModelingBotFactory.eINSTANCE.createPropertiesView())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createAdd())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createRemove())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createSetAttribute())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createUnsetAttribute())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createUnset())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createCancel())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createCheck())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createOpenEEFEditor())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createSetReference())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createUnsetReference())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createMoveUp())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EEFActionsFactory.eINSTANCE.createMoveDown())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createCreateProject())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createOpenPerspective())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createCloseProject())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createSave())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createUndo())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createRedo())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createOpenProject())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createRemoveProject())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createCloseEditor())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createOpenEditor())); - - newChildDescriptors.add - (createChildParameter - (ModelingBotPackage.Literals.SEQUENCE__PROCESSINGS, - EclipseActionsFactory.eINSTANCE.createCreateModel())); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/WizardItemProvider.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/WizardItemProvider.java deleted file mode 100755 index a2f9e7c6b..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src-gen/org/eclipse/emf/eef/modelingBot/provider/WizardItemProvider.java +++ /dev/null @@ -1,143 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.provider; - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; - -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.Wizard; - -/** - * This is the item provider adapter for a {@link org.eclipse.emf.eef.modelingBot.Wizard} object. - * - * - * @generated - */ -public class WizardItemProvider - extends SequenceItemProvider - implements - IEditingDomainItemProvider, - IStructuredItemContentProvider, - ITreeItemContentProvider, - IItemLabelProvider, - IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - * - * - * @generated - */ - public WizardItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - * - * - * @generated - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - addReferenceableObjectPropertyDescriptor(object); - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Referenceable Object feature. - * - * - * @generated - */ - protected void addReferenceableObjectPropertyDescriptor(Object object) { - itemPropertyDescriptors.add - (createItemPropertyDescriptor - (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_Wizard_referenceableObject_feature"), - getString("_UI_PropertyDescriptor_description", "_UI_Wizard_referenceableObject_feature", "_UI_Wizard_type"), - ModelingBotPackage.Literals.WIZARD__REFERENCEABLE_OBJECT, - true, - false, - true, - null, - null, - null)); - } - - /** - * This returns Wizard.gif. - * - * - * @generated - */ - @Override - public Object getImage(Object object) { - return overlayImage(object, getResourceLocator().getImage("full/obj16/Wizard")); - } - - /** - * This returns the label text for the adapted class. - * - * - * @generated - */ - @Override - public String getText(Object object) { - String label = ((Wizard)object).getName(); - return label == null || label.length() == 0 ? - getString("_UI_Wizard_type") : - getString("_UI_Wizard_type") + " " + label; - } - - /** - * This handles model notifications by calling {@link #updateChildren} to update any cached - * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. - * - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - updateChildren(notification); - super.notifyChanged(notification); - } - - /** - * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children - * that can be created under this object. - * - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src/org/eclipse/emf/eef/modelingBot/edit/commands/OpenWithEEFHandler.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src/org/eclipse/emf/eef/modelingBot/edit/commands/OpenWithEEFHandler.java deleted file mode 100644 index 0a8555638..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src/org/eclipse/emf/eef/modelingBot/edit/commands/OpenWithEEFHandler.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.edit.commands; - -import org.eclipse.core.commands.AbstractHandler; -import org.eclipse.core.commands.ExecutionEvent; -import org.eclipse.core.commands.ExecutionException; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.eef.modelingBot.provider.MbotEditPlugin; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.ui.PartInitException; -import org.eclipse.ui.handlers.HandlerUtil; -import org.eclipse.ui.part.FileEditorInput; - -/** - * The Open with interactive EEF editor action handler. - * - * @author Stephane Bouchet - */ -public class OpenWithEEFHandler extends AbstractHandler { - - /** - * {@inheritDoc} - * - * @see org.eclipse.core.commands.IHandler#execute(org.eclipse.core.commands.ExecutionEvent) - */ - public Object execute(ExecutionEvent event) throws ExecutionException { - try { - final ISelection selection = HandlerUtil.getCurrentSelectionChecked(event); - if (!selection.isEmpty() && selection instanceof IStructuredSelection - && ((IStructuredSelection)selection).getFirstElement() instanceof IFile) { - HandlerUtil - .getActiveWorkbenchWindowChecked(event) - .getActivePage() - .openEditor(new FileEditorInput((IFile)((IStructuredSelection)selection).getFirstElement()), - MbotEditPlugin.INTERACTIVE_EEF_EDITOR_ID); - } - } catch (PartInitException e) { - final Status status = new Status(IStatus.ERROR, MbotEditPlugin.INTERACTIVE_EEF_EDITOR_ID, e.getMessage()); - MbotEditPlugin.getPlugin().getLog().log(status); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.edit/src/org/eclipse/emf/eef/modelingBot/edit/wizards/ModelCreationWizard.java b/plugins/org.eclipse.emf.eef.modelingbot.edit/src/org/eclipse/emf/eef/modelingBot/edit/wizards/ModelCreationWizard.java deleted file mode 100755 index 89f0ca82e..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.edit/src/org/eclipse/emf/eef/modelingBot/edit/wizards/ModelCreationWizard.java +++ /dev/null @@ -1,778 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.edit.wizards; - -import java.io.File; -import java.io.IOException; -import java.lang.reflect.InvocationTargetException; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.HashMap; -import java.util.Iterator; -import java.util.List; -import java.util.Map; -import java.util.StringTokenizer; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.emf.common.CommonPlugin; -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.ui.CommonUIPlugin; -import org.eclipse.emf.common.ui.dialogs.WorkspaceResourceDialog; -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.plugin.EcorePlugin; -import org.eclipse.emf.ecore.provider.EcoreEditPlugin; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.ecore.xmi.XMLResource; -import org.eclipse.emf.edit.ui.provider.ExtendedImageRegistry; -import org.eclipse.emf.eef.modelingBot.provider.MbotEditPlugin; -import org.eclipse.jface.dialogs.MessageDialog; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.LabelProvider; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.wizard.Wizard; -import org.eclipse.jface.wizard.WizardPage; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.ModifyEvent; -import org.eclipse.swt.events.ModifyListener; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.graphics.Image; -import org.eclipse.swt.layout.FormAttachment; -import org.eclipse.swt.layout.FormData; -import org.eclipse.swt.layout.FormLayout; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Combo; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.FileDialog; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.INewWizard; -import org.eclipse.ui.IWorkbench; -import org.eclipse.ui.IWorkbenchPage; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.IWorkbenchWindow; -import org.eclipse.ui.PartInitException; -import org.eclipse.ui.actions.WorkspaceModifyOperation; -import org.eclipse.ui.dialogs.ElementListSelectionDialog; -import org.eclipse.ui.dialogs.WizardNewFileCreationPage; -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.ISetSelectionTarget; - -/** - * The wizard for creating modelingBots models. - * - * @author Goulwen Le Fur - */ -public class ModelCreationWizard extends Wizard implements INewWizard { - - private List initialObjects = new ArrayList(); - - protected static final int CONTROL_OFFSET = 10; - - /** - * This is the metamodel selection page. - */ - private MetamodelSelectionWizardPage metamodelSelectionPage; - - /** - * Remember the selection during initialization for populating the default container. - */ - protected IStructuredSelection selection; - - /** - * Remember the workbench during initialization. - */ - protected IWorkbench workbench; - - /** - * Caches the names of the types that can be created as the root object. - */ - protected List initialObjectNames; - - /** - * This is the file creation page. - */ - protected ModelCreationWizardNewFileCreationPage newFileCreationPage; - - /** - * This is the initial object creation page. - */ - protected ModelingBotModelWizardInitialObjectCreationPage initialObjectCreationPage; - - /** - * ResourceSet to use. - */ - protected ResourceSet resourceSet = new ResourceSetImpl(); - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.wizard.Wizard#performFinish() - */ - @Override - public boolean performFinish() { - try { - // Remember the file. - final IFile modelFile = getModelFile(); - - // Do the work within an operation. - final WorkspaceModifyOperation operation = new WorkspaceModifyOperation() { - @Override - protected void execute(IProgressMonitor progressMonitor) { - try { - // Create a resource set - final ResourceSet wResourceSet = new ResourceSetImpl(); - - // Get the URI of the model file. - final URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true); - - // Create a resource for this file. - final Resource resource = wResourceSet.createResource(fileURI); - - // Add the initial model object to the contents. - final EObject rootObject = createInitialModel(); - if (rootObject != null) { - resource.getContents().add(rootObject); - } - - // Save the contents of the resource to the file system. - final Map options = new HashMap(); - options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding()); - resource.save(options); - } catch (IOException exception) { - MbotEditPlugin.INSTANCE.log(exception); - } finally { - progressMonitor.done(); - } - } - }; - - getContainer().run(false, false, operation); - - // Select the new file resource in the current view. - final IWorkbenchWindow workbenchWindow = workbench.getActiveWorkbenchWindow(); - final IWorkbenchPage page = workbenchWindow.getActivePage(); - final IWorkbenchPart activePart = page.getActivePart(); - if (activePart instanceof ISetSelectionTarget) { - final ISelection targetSelection = new StructuredSelection(modelFile); - getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - ((ISetSelectionTarget)activePart).selectReveal(targetSelection); - } - }); - } - - // Open an editor on the new file. - try { - page.openEditor(new FileEditorInput(modelFile), MbotEditPlugin.INTERACTIVE_EEF_EDITOR_ID); - return true; - } catch (PartInitException exception) { - MessageDialog.openError(workbenchWindow.getShell(), - MbotEditPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage()); - } - } catch (InterruptedException exception) { - MbotEditPlugin.INSTANCE.log(exception); - } catch (InvocationTargetException exception) { - MbotEditPlugin.INSTANCE.log(exception); - } - return false; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.IWorkbenchWizard#init(org.eclipse.ui.IWorkbench, - * org.eclipse.jface.viewers.IStructuredSelection) - */ - public void init(IWorkbench workbench, IStructuredSelection selection) { - this.workbench = workbench; - this.selection = selection; - setWindowTitle(MbotEditPlugin.INSTANCE.getString("_UI_Wizard_label")); - setDefaultPageImageDescriptor(ExtendedImageRegistry.INSTANCE.getImageDescriptor(MbotEditPlugin.INSTANCE - .getImage("full/wizban/NewModelingBot"))); - } - - /** - * Get the file from the page. - */ - public IFile getModelFile() { - return newFileCreationPage.getModelFile(); - } - - /** - * Create a new model. - */ - protected EObject createInitialModel() { - final EClass eClass = getEClassifier(initialObjectCreationPage.getInitialObjectName()); - final EObject rootObject = EcoreUtil.create(eClass); - return rootObject; - } - - private EClass getEClassifier(String initialObjectName) { - for (EClass eClass : initialObjects) { - if (eClass.getName().equals(initialObjectName)) - return eClass; - } - return null; - } - - /** - * Returns the names of the types that can be created as the root object. - */ - protected Collection getInitialObjectNames() { - initialObjectNames = new ArrayList(); - for (EClass eClass : initialObjects) { - if (!eClass.isAbstract()) { - initialObjectNames.add(eClass.getName()); - } - } - Collections.sort(initialObjectNames, CommonPlugin.INSTANCE.getComparator()); - return initialObjectNames; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.wizard.Wizard#addPages() - */ - public void addPages() { - metamodelSelectionPage = new MetamodelSelectionWizardPage("Whatever0"); - metamodelSelectionPage.setTitle(MbotEditPlugin.INSTANCE.getString("_UI_EEFActionsModelWizard_label")); - metamodelSelectionPage.setDescription(MbotEditPlugin.INSTANCE - .getString("_UI_ModelCreationMetamodelSelection_description")); - addPage(metamodelSelectionPage); - - // Create a page, set the title, and the initial model file name. - // - newFileCreationPage = new ModelCreationWizardNewFileCreationPage("Whatever", selection); - newFileCreationPage.setTitle(MbotEditPlugin.INSTANCE.getString("_UI_EEFActionsModelWizard_label")); - newFileCreationPage.setDescription(MbotEditPlugin.INSTANCE.getString("_UI_EEFActionsModelWizard_description")); - newFileCreationPage.setFileName(MbotEditPlugin.INSTANCE.getString("_UI_ModelingBotEditorFilenameDefaultBase")); - addPage(newFileCreationPage); - - // Try and get the resource selection to determine a current directory for the file dialog. - // - if (selection != null && !selection.isEmpty()) { - // Get the resource... - // - final Object selectedElement = selection.iterator().next(); - if (selectedElement instanceof IResource) { - // Get the resource parent, if its a file. - // - IResource selectedResource = (IResource)selectedElement; - if (selectedResource.getType() == IResource.FILE) { - selectedResource = selectedResource.getParent(); - } - - // This gives us a directory... - // - if (selectedResource instanceof IFolder || selectedResource instanceof IProject) { - // Set this for the container. - // - newFileCreationPage.setContainerFullPath(selectedResource.getFullPath()); - - // Make up a unique new name here. - // - final String defaultModelBaseFilename = MbotEditPlugin.INSTANCE - .getString("_UI_ModelingBotEditorFilenameDefaultBase"); - String modelFilename = defaultModelBaseFilename; - for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) { - modelFilename = defaultModelBaseFilename + i; - } - newFileCreationPage.setFileName(modelFilename); - } - } - } - initialObjectCreationPage = new ModelingBotModelWizardInitialObjectCreationPage("Whatever2"); - initialObjectCreationPage.setTitle(MbotEditPlugin.INSTANCE.getString("_UI_EEFActionsModelWizard_label")); - initialObjectCreationPage.setDescription(MbotEditPlugin.INSTANCE - .getString("_UI_Wizard_initial_object_description")); - addPage(initialObjectCreationPage); - } - - private void updateObjectField() { - initialObjectCreationPage.getInitialObjectField().removeAll(); - for (String objectName : getInitialObjectNames()) { - initialObjectCreationPage.getInitialObjectField().add(objectName); - } - - if (initialObjectCreationPage.getInitialObjectField().getItemCount() == 1) { - initialObjectCreationPage.getInitialObjectField().select(0); - } - } - - public class MetamodelSelectionWizardPage extends WizardPage { - - protected Text uriField; - - /** - * @param pageName - */ - public MetamodelSelectionWizardPage(String pageName) { - super(pageName); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.dialogs.IDialogPage#createControl(org.eclipse.swt.widgets.Composite) - */ - public void createControl(Composite parent) { - final Composite composite = new Composite(parent, SWT.NONE); - final FormLayout layout = new FormLayout(); - composite.setLayout(layout); - final GridData gData = new GridData(); - gData.verticalAlignment = GridData.FILL; - gData.grabExcessVerticalSpace = true; - gData.horizontalAlignment = GridData.FILL; - gData.grabExcessHorizontalSpace = true; - if (!EMFPlugin.IS_RESOURCES_BUNDLE_AVAILABLE) { - gData.widthHint = 330; - } - composite.setLayoutData(gData); - // buttonComposite has to be the first child of composite because subclasses are expecting this. - final Composite buttonComposite = new Composite(composite, SWT.NONE); - - final Label resourceURILabel = new Label(composite, SWT.LEFT); - resourceURILabel.setText(CommonUIPlugin.INSTANCE.getString("_UI_ResourceURI_label")); - FormData fData = new FormData(); - fData.left = new FormAttachment(0, CONTROL_OFFSET); - fData.top = new FormAttachment(0, CONTROL_OFFSET); - resourceURILabel.setLayoutData(fData); - fData = new FormData(); - fData.top = new FormAttachment(resourceURILabel, CONTROL_OFFSET, SWT.CENTER); - fData.left = new FormAttachment(resourceURILabel, CONTROL_OFFSET); - fData.right = new FormAttachment(100, -CONTROL_OFFSET); - buttonComposite.setLayoutData(fData); - buttonComposite.setLayout(new FormLayout()); - uriField = new Text(composite, SWT.BORDER); - fData = new FormData(); - fData.top = new FormAttachment(buttonComposite, CONTROL_OFFSET); - fData.left = new FormAttachment(0, CONTROL_OFFSET); - fData.right = new FormAttachment(100, -CONTROL_OFFSET); - uriField.setLayoutData(fData); - uriField.addModifyListener(new ModifyListener() { - - public void modifyText(ModifyEvent e) { - updateMetamodel(); - setPageComplete(validatePage()); - } - - }); - final Button browseFileSystemButton = new Button(buttonComposite, SWT.PUSH); - browseFileSystemButton.setText(CommonUIPlugin.INSTANCE.getString("_UI_BrowseFileSystem_label")); - prepareBrowseFileSystemButton(browseFileSystemButton); - - if (EMFPlugin.IS_RESOURCES_BUNDLE_AVAILABLE) { - final Button browseWorkspaceButton = new Button(buttonComposite, SWT.PUSH); - fData = new FormData(); - fData.right = new FormAttachment(100); - browseWorkspaceButton.setLayoutData(fData); - fData = new FormData(); - fData.right = new FormAttachment(browseWorkspaceButton, -CONTROL_OFFSET); - browseFileSystemButton.setLayoutData(fData); - browseWorkspaceButton.setText(CommonUIPlugin.INSTANCE.getString("_UI_BrowseWorkspace_label")); - prepareBrowseWorkspaceButton(browseWorkspaceButton); - } else { - fData = new FormData(); - fData.right = new FormAttachment(100); - browseFileSystemButton.setLayoutData(fData); - } - - final Label separatorLabel = new Label(composite, SWT.SEPARATOR | SWT.HORIZONTAL); - fData = new FormData(); - fData.top = new FormAttachment(uriField, (int)(1.5 * CONTROL_OFFSET)); - fData.left = new FormAttachment(0, -CONTROL_OFFSET); - fData.right = new FormAttachment(100, CONTROL_OFFSET); - separatorLabel.setLayoutData(fData); - composite.setTabList(new Control[] {uriField, buttonComposite}); - final Button browseRegisteredPackagesButton = new Button(buttonComposite, SWT.PUSH); - browseRegisteredPackagesButton.setText(MbotEditPlugin.INSTANCE - .getString("_UI_BrowseRegisteredPackages_label")); - prepareBrowseRegisteredPackagesButton(browseRegisteredPackagesButton); - fData = new FormData(); - Control[] children = buttonComposite.getChildren(); - fData.left = new FormAttachment(0, 0); - fData.right = new FormAttachment(children[0], -CONTROL_OFFSET); - browseRegisteredPackagesButton.setLayoutData(fData); - setControl(composite); - setPageComplete(validatePage()); - } - - public String getURIText() { - return uriField.getText(); - } - - private void updateMetamodel() { - final List uris = new ArrayList(); - for (StringTokenizer stringTokenizer = new StringTokenizer(getURIText()); stringTokenizer.hasMoreTokens();) { - final String uri = stringTokenizer.nextToken(); - uris.add(URI.createURI(uri)); - } - final List newInitialObjects = new ArrayList(); - for (URI uri : uris) { - try { - final Resource resource = resourceSet.getResource(uri, true); - if (resource.getContents() != null) { - final List allClasses = getAllClasses(resource); - if (!allClasses.isEmpty()) { - newInitialObjects.addAll(allClasses); - } - } - } catch (Exception e) { - // Silent catch malformed protocol - } - } - if (!newInitialObjects.isEmpty()) { - initialObjects.clear(); - initialObjects.addAll(newInitialObjects); - updateObjectField(); - } - } - - private List getAllClasses(Resource resource) { - final List eclasses = new ArrayList(); - for (Iterator iterator = resource.getAllContents(); iterator.hasNext();) { - final Object next = iterator.next(); - if (next instanceof EClass) { - eclasses.add((EClass)next); - } - } - return eclasses; - } - - private boolean validatePage() { - return !initialObjects.isEmpty(); - } - - /** - * Called to prepare the Browse File System button, this implementation adds a selection listener that - * creates an appropriate {@link FileDialog}. - */ - protected void prepareBrowseFileSystemButton(Button browseFileSystemButton) { - browseFileSystemButton.addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent event) { - final FileDialog fileDialog = new FileDialog(getShell(), SWT.NONE); - fileDialog.open(); - - final String filterPath = fileDialog.getFilterPath(); - final String fileName = fileDialog.getFileName(); - if (fileName != null) { - uriField.setText(URI.createFileURI(filterPath + File.separator + fileName).toString()); - } - } - }); - } - - /** - * Called to prepare the Browse Workspace button, this implementation adds a selection listener that - * creates an appropriate {@link WorkspaceResourceDialog}. - */ - protected void prepareBrowseWorkspaceButton(Button browseWorkspaceButton) { - browseWorkspaceButton.addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent event) { - IFile file = null; - final IFile[] files = WorkspaceResourceDialog.openFileSelection(getShell(), null, null, false, - null, null); - if (files.length != 0) { - file = files[0]; - } - if (file != null) { - uriField.setText(URI.createPlatformResourceURI(file.getFullPath().toString(), true).toString()); - } - } - }); - } - - protected void prepareBrowseRegisteredPackagesButton(Button browseRegisteredPackagesButton) { - browseRegisteredPackagesButton.addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent event) { - final RegisteredPackageDialog registeredPackageDialog = new RegisteredPackageDialog(getShell()); - registeredPackageDialog.open(); - final Object[] result = registeredPackageDialog.getResult(); - if (result != null) { - final List nsURIs = Arrays.asList(result); - if (registeredPackageDialog.isDevelopmentTimeVersion()) { - final ResourceSet resourceSet = new ResourceSetImpl(); - resourceSet.getURIConverter().getURIMap().putAll(EcorePlugin.computePlatformURIMap()); - final StringBuffer uris = new StringBuffer(); - final Map ePackageNsURItoGenModelLocationMap = EcorePlugin - .getEPackageNsURIToGenModelLocationMap(); - for (int i = 0, length = result.length; i < length; i++) { - final URI location = ePackageNsURItoGenModelLocationMap.get(result[i]); - final Resource resource = resourceSet.getResource(location, true); - EcoreUtil.resolveAll(resource); - } - for (Resource resource : resourceSet.getResources()) { - for (EPackage ePackage : getAllPackages(resource)) { - if (nsURIs.contains(ePackage.getNsURI())) { - uris.append(resource.getURI()); - uris.append(" "); - break; - } - } - } - uriField.setText((uriField.getText() + " " + uris.toString()).trim()); - } else { - final StringBuffer uris = new StringBuffer(); - for (int i = 0, length = result.length; i < length; i++) { - uris.append(result[i]); - uris.append(" "); - } - uriField.setText((uriField.getText() + " " + uris.toString()).trim()); - } - } - } - }); - } - - protected Collection getAllPackages(Resource resource) { - final List result = new ArrayList(); - for (TreeIterator j = new EcoreUtil.ContentTreeIterator(resource.getContents()) { - private static final long serialVersionUID = 1L; - - @Override - protected Iterator getEObjectChildren(EObject eObject) { - return eObject instanceof EPackage ? ((EPackage)eObject).getESubpackages().iterator() : Collections - . emptyList().iterator(); - } - }; j.hasNext();) { - final Object content = j.next(); - if (content instanceof EPackage) { - result.add((EPackage)content); - } - } - return result; - } - } - - /** - * This is the one page of the wizard. - */ - public class ModelCreationWizardNewFileCreationPage extends WizardNewFileCreationPage { - - /** - * Pass in the selection. - */ - public ModelCreationWizardNewFileCreationPage(String pageId, IStructuredSelection selection) { - super(pageId, selection); - } - - /** - */ - public IFile getModelFile() { - return ResourcesPlugin.getWorkspace().getRoot().getFile(getContainerFullPath().append(getFileName())); - } - } - - /** - * This is the page where the type of object to create is selected. - */ - public class ModelingBotModelWizardInitialObjectCreationPage extends WizardPage { - - protected Combo initialObjectField; - - protected List encodings; - - protected Combo encodingField; - - /** - * Pass in the selection. - */ - public ModelingBotModelWizardInitialObjectCreationPage(String pageId) { - super(pageId); - } - - public void createControl(Composite parent) { - final Composite composite = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - layout.verticalSpacing = 12; - composite.setLayout(layout); - GridData gData = new GridData(); - gData.verticalAlignment = GridData.FILL; - gData.grabExcessVerticalSpace = true; - gData.horizontalAlignment = GridData.FILL; - composite.setLayoutData(gData); - final Label containerLabel = new Label(composite, SWT.LEFT); - containerLabel.setText(MbotEditPlugin.INSTANCE.getString("_UI_ModelObject")); - gData = new GridData(); - gData.horizontalAlignment = GridData.FILL; - containerLabel.setLayoutData(gData); - initialObjectField = new Combo(composite, SWT.BORDER); - gData = new GridData(); - gData.horizontalAlignment = GridData.FILL; - gData.grabExcessHorizontalSpace = true; - initialObjectField.setLayoutData(gData); - updateObjectField(); - initialObjectField.addModifyListener(validator); - - final Label encodingLabel = new Label(composite, SWT.LEFT); - encodingLabel.setText(MbotEditPlugin.INSTANCE.getString("_UI_XMLEncoding")); - gData = new GridData(); - gData.horizontalAlignment = GridData.FILL; - encodingLabel.setLayoutData(gData); - encodingField = new Combo(composite, SWT.BORDER); - gData = new GridData(); - gData.horizontalAlignment = GridData.FILL; - gData.grabExcessHorizontalSpace = true; - encodingField.setLayoutData(gData); - for (String encoding : getEncodings()) { - encodingField.add(encoding); - } - - encodingField.select(0); - encodingField.addModifyListener(validator); - - setPageComplete(validatePage()); - setControl(composite); - } - - protected ModifyListener validator = new ModifyListener() { - public void modifyText(ModifyEvent e) { - setPageComplete(validatePage()); - } - }; - - /** - * @return the initialObjectField - */ - public Combo getInitialObjectField() { - return initialObjectField; - } - - protected boolean validatePage() { - return getInitialObjectName() != null && !getInitialObjectName().equals("") - && getEncodings().contains(encodingField.getText()); - } - - @Override - public void setVisible(boolean visible) { - super.setVisible(visible); - if (visible) { - if (initialObjectField.getItemCount() == 1) { - initialObjectField.clearSelection(); - encodingField.setFocus(); - } else { - encodingField.clearSelection(); - initialObjectField.setFocus(); - } - } - } - - public String getInitialObjectName() { - return initialObjectField.getText(); - } - - public String getEncoding() { - return encodingField.getText(); - } - - protected Collection getEncodings() { - if (encodings == null) { - encodings = new ArrayList(); - for (StringTokenizer stringTokenizer = new StringTokenizer( - MbotEditPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens();) { - encodings.add(stringTokenizer.nextToken()); - } - } - return encodings; - } - } - - public static class RegisteredPackageDialog extends ElementListSelectionDialog { - protected boolean isDevelopmentTimeVersion = true; - - public RegisteredPackageDialog(Shell parent) { - super(parent, new LabelProvider() { - @Override - public Image getImage(Object element) { - return ExtendedImageRegistry.getInstance().getImage( - EcoreEditPlugin.INSTANCE.getImage("full/obj16/EPackage")); - } - }); - - setMultipleSelection(true); - setMessage(MbotEditPlugin.INSTANCE.getString("_UI_SelectRegisteredPackageURI")); - setFilter("*"); - setTitle(MbotEditPlugin.INSTANCE.getString("_UI_PackageSelection_label")); - } - - public boolean isDevelopmentTimeVersion() { - return isDevelopmentTimeVersion; - } - - protected void updateElements() { - if (isDevelopmentTimeVersion) { - final Map ePackageNsURItoGenModelLocationMap = EcorePlugin - .getEPackageNsURIToGenModelLocationMap(); - final Object[] result = ePackageNsURItoGenModelLocationMap.keySet().toArray( - new Object[ePackageNsURItoGenModelLocationMap.size()]); - Arrays.sort(result); - setListElements(result); - } else { - final Object[] result = EPackage.Registry.INSTANCE.keySet().toArray( - new Object[EPackage.Registry.INSTANCE.size()]); - Arrays.sort(result); - setListElements(result); - } - } - - @Override - protected Control createDialogArea(Composite parent) { - final Composite result = (Composite)super.createDialogArea(parent); - final Composite buttonGroup = new Composite(result, SWT.NONE); - final GridLayout layout = new GridLayout(); - layout.numColumns = 2; - buttonGroup.setLayout(layout); - final Button developmentTimeVersionButton = new Button(buttonGroup, SWT.RADIO); - developmentTimeVersionButton.addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent event) { - isDevelopmentTimeVersion = developmentTimeVersionButton.getSelection(); - updateElements(); - } - }); - developmentTimeVersionButton.setText(MbotEditPlugin.INSTANCE.getString("_UI_DevelopmentTimeVersion_label")); - final Button runtimeTimeVersionButton = new Button(buttonGroup, SWT.RADIO); - runtimeTimeVersionButton.setText(MbotEditPlugin.INSTANCE.getString("_UI_RuntimeVersion_label")); - developmentTimeVersionButton.setSelection(true); - - updateElements(); - - return result; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/.classpath b/plugins/org.eclipse.emf.eef.modelingbot.editor/.classpath deleted file mode 100644 index f9c46b584..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/.gitignore b/plugins/org.eclipse.emf.eef.modelingbot.editor/.gitignore deleted file mode 100644 index 4058d0f36..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -bin -/target diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/.project b/plugins/org.eclipse.emf.eef.modelingbot.editor/.project deleted file mode 100644 index 9b5cb3b2d..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.modelingbot.editor - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.modelingbot.editor/META-INF/MANIFEST.MF deleted file mode 100644 index 40a827e31..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/META-INF/MANIFEST.MF +++ /dev/null @@ -1,26 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: %pluginName -Bundle-SymbolicName: org.eclipse.emf.eef.modelingbot.editor;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Activator: org.eclipse.emf.eef.modelingBot.presentation.MbotEditorPlugin$Implementation -Bundle-Vendor: %providerName -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.modelingBot.EEFActions.presentation, - org.eclipse.emf.eef.modelingBot.EclipseActions.presentation, - org.eclipse.emf.eef.modelingBot.presentation -Require-Bundle: org.eclipse.core.runtime, - org.eclipse.core.resources;visibility:=reexport, - org.eclipse.emf.eef.modelingbot.edit;visibility:=reexport, - org.eclipse.emf.ecore.xmi;visibility:=reexport, - org.eclipse.emf.edit.ui;visibility:=reexport, - org.eclipse.ui.ide;visibility:=reexport, - org.eclipse.emf.eef.components.edit;visibility:=reexport, - org.eclipse.emf.ecore.edit;visibility:=reexport, - org.eclipse.emf.eef.editor.model;visibility:=reexport, - org.eclipse.emf.codegen.ecore.ui;visibility:=reexport, - org.eclipse.emf.eef.mapping.edit;visibility:=reexport, - org.eclipse.emf.eef.views.edit;visibility:=reexport -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/build.properties b/plugins/org.eclipse.emf.eef.modelingbot.editor/build.properties deleted file mode 100644 index 5e666f3a8..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/build.properties +++ /dev/null @@ -1,24 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2011 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# -# -# -# $Id: build.properties,v 1.1 2011/04/06 13:09:23 nlepine Exp $ - -bin.includes = .,\ - icons/,\ - META-INF/,\ - plugin.xml,\ - plugin.properties -jars.compile.order = . -source.. = src-gen/ -output.. = bin/ diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/obj16/EEFActionsModelFile.gif b/plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/obj16/EEFActionsModelFile.gif deleted file mode 100644 index 388b93755fcb68e853cac46d13f11af2cb1c491a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 346 zcmZ?wbhEHb6krfwxXQrL(9jScAHRS9{{Q#qA2@IT$YuD?z`*by$o~Hy%=!;v&zUm^ zC{?WHvt@!U5N+tUThrsPyxVC}hx6Q4*Xd1e&E>vzrGC}L0arF<-r8I9;6(q=Uw^*; z{QdRE?@wQUfB5?Q?WbR_KK#7@^2eR$-+>lT3n>0%VPs%nW6%K^2=WsHTe(AXfrpNe z;t7>Y8Z8y`F7UQ!{)|{Jv$BxsRh9Kk&xt}>?Q+iqmPQEfD< diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/obj16/EclipseActionsModelFile.gif b/plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/obj16/EclipseActionsModelFile.gif deleted file mode 100644 index 7ede4ac8f48128cccdcfaa04d4437433bf352010..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 346 zcmZ?wbhEHb6krfwxXQrL(9jScAHRS9{{Q#qA2@IT$YuD?z`*by$o~Hy%=-Vo>Drp$ zV?CB@ignr|w@k1Fq7D6aYkC}(cRMZWaGu-hI=#uQx!kv|)UUcY;L4`VTYGCBoaq1g z>(BR}zrX(Y{psuP4_|-3{q*bAhoARf{P3TpAqY2Ru(e7svP|pe@9LS_&oa?PLRGb`b&-Utq}r+~{#9y{ Wu2P$%3RpHv`8YB0&v$WTum%8&zjzn` diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/obj16/ModelingBotModelFile.gif b/plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/obj16/ModelingBotModelFile.gif deleted file mode 100644 index f3aa87a3ebf01a8a91fb0d31e723806831282936..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 592 zcmV-W0d~v%i^V|%GK8Cva`{am%?$baFv$A%+lO*sC(Sp z>$SJm+S=;z@%Mp)vC-1!Z+3+L|Nj6000000000000000000000A^8LW004OaEC2ui z01yBW000NAfO&$0goTEOg$WG@h=dFd1a1$Ff&vIPGXjSJC<-S4Ivqp+h5>RL3lMoi zHcf_IMNcg$AA)#;iU$E-CP_2{bGCwy1X4Z`1$JReS+;n1mQ`?GNLN1+H5tNr0C6l) zTR3%2QwAj4MiV<&A!1M?EM=vLTQw!M2Qp;G?p$#XUw>N#eL6n-XFj7eCK?ht-XzzxvwMOI^YXnH#<8! zt7~6Z*S^qM6vBenaN}_2?PQHfrvf{v+~Wo0moYV=Gwrq zHgJrcf1XoN;mwfZn;}Kc4{*&MO&Jh}GoZdIl%M-FkXZTZ#V^a&`BB|j0(zIk%C|;hIZAheR zm+oa-Mmi(fi`X#QeudI<>+AvVoI6!LQR<-eJ>BE%H5o*^+ zQ_q{$mt&m+f*#JhmptLX=*-}lcxYTQGC4myA>mIgycJ1BlGQ2k^343lY01j6{Bv;~ zi$Hl*`tQKTfvR>MrE7%NH{Qd2*Y|pw{bq(cHp>?-j!b?So|qe-mP(e^#f$Q#kDnJ; zHV59!3{A}Og$r+|rGlBI_wye`l9eg3OeX)l^zqZ;%ErfyudC}{=9f1lOKXd(n=9*I zHmTm5Q_UN*{S$qaZ7n55q@r|uVNwA$7LyB4Nh3Bj*U(zKdKv%HKhWOAsIS0dyIBM8 zXQp}muZP*AqrCA+!QB6D?fDGVAXs?%Tp=Pu!#GOY9_s_i(6I`DaGK}r^9|3n6Kdst0JH&|O6F_?KuVROmX;^^ z^PIBl@B<}5n}N4n?5&K>PM!z2kZ;AJ2pwzH6L`0Bn*x+c(PT>?zs_kpZ`Q5BjTJ0P zPXX_OUBLHg0KKF{Qv?E?u6D|% z#<3uXPjR844gs+tcBDWK@hsjwU`W*>@h_0p8S!XrUabq|S!{?0`WKOGAkqKV-3j3b=n)~j}dj~jU>lzoc#1muSqAAUR&8>4x?G!lH-46iWc zWTy)u2_JdJAY%nYU->KBTqFJFenKe7j0u2zb3SbkH41nHGtz#vIGZ8Y*RYRMvoZHn zP&;2HM$M_ZgJZl5IK&iR{YvD4@6BpSzguwUnF^;L;3~nIVdjXUv6QXp8-B+ln1+dk z_F8}Jui^mkYTxJ;;HSM$a7G=VgD{0|?L1J4ce;%OF_Bs!tpZZpwL{gZ26d>Xg%<%v z3kgcbT>llbub2~(+T|{vM!*d%JGM-w=^O2 zke_r0=@PE^LoTmg=HCg=0X7iF$2)@BzthyiBbgURn6G-F>Lv__X+=k9|5Z;7q64o& z-nsVK+_+k4<%uym)FbI!e@HMd^4BXIr~_LM?z&!is(QJRqJC5Y?K%9K$K+|M2z4{C z@^4d>WZr}3(+*|4My`PBV%+m5R|rt>GZi)PWzst^Q}?ZVZEt}g-JiHg$wQ=?2YD3Q zWGHk;j!kH)r|==+X9#UwR#Sh*qSgB9Tc;EGLOS~4epis`uLr%FIoI^2V@2Pe?GE6@ zTkT^^l012c51|9rW1%^l~@yQpL@+?N&&y}@iFHE@&tj3FPsDTqcGGxQs zwC8Gy-)7R{F8?e7s#>Yc<#^X`zrlV{eGFjv5cB36kCj42Wj~Vt5{b~=7B9qZzl@l? z?DYDpQ{_29y5nWV-mW_If<4->M~WLZ0U?UdIXec*qKoy;U%2Mv9}eGfc=qLMdq)FU ze(HmQmf{3W*|xY5dFXt(@~L8VuY6@^&8$+%MRxh7&`)FVt_FBtBkQ(~Z`xImSZ@a* z=slXF;;cpfQPuLaItgT@Nxk;uP_^9+gNrAC=*NBg+v%@t0@sk7V^3AQzcxgstsssC zSKJ&k1Nm8>07hiZ?Z=wf8bysN#Yx1#vrluqd?MgY>WArqu|lKTb1A)7zthGyvGvZg zFu9>NrdcK&d#zcl?JeEGePUZ<19VK92T99PP-yM2o?ipgH_Y_m!0yQJ0Hrqu{yqY5 zZsMdLgGz3~YPnuSYynzGVm-h)GWT=CN!m&W<2V5CiUWs+5LMu8xf1xE?9PhmQ{zSQ zac6^;^tsG56AflofC-7P09!C0is!=Cfe4fp`=>~A2g3_G+4c@q&&P2)zeHEG5csfO z3x-WAGBmo-Tk5uQoiPtr%8BDPjs{VVXdWT z?V2v?RwMG;^&+}4(3&>PAAk08|_N^aC&9H8S^r07nWq zgK!;E(a^j;Fu@lFwZ<#<7k|#L%tjK0g_kFrS}U~;42K1JdXA}S*1)4FKkOKBdvXw_ zMfcYa6kC(9L$4_RO(+Py9`NqY-dD<}d{Mx#SlPS2wY7SNx#ax=@V%*yA^P}6ZPd@v z>@|HUZ~i;K>;2fO VR;s7Btfnt`D|=>PpSn80;vb8p#u5Mk diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/wizban/NewEclipseActions.gif b/plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/wizban/NewEclipseActions.gif deleted file mode 100644 index e3b9c14a6a6faac84c9b8bd6d2f6a3b48650a53b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2462 zcmd6m`8OMg8ivzyXM`x-QPZJfTAHHK&QR5jT4P#9t7t6^##XzkW!xa>#1e@$O~jH| zE3r#rtBR6D7#fYJM2Qp;G?p$#XUw>N#eL6n-XFj7eCK?ht-XzzxvwMO2H-PbFT1ZBl3O9g&W~^|k8rNx&)gyjZjpG87@|i^>4Ug(@AyieJu2Xdq=4kA zpp=@>w7T$&=Mfq8(Z5q3XE!FGn}5T${)TBuE2bffX{ge!tkP}_sSmryi^A%DT-^Y! zj!9@3ENf(y?=eJf;ndSdsa<0Vp4Giz9^{>8;i+mH7L=k(d$XCGJIH~-4q)k2?*2zXfQw~D2oJNF~cj2 zIN9k!NW#aSG00c}(O3S;HqS`EWsndGGV23CzB-?=hZ+Suh8bx;UYg64>ucD@so9u& zDyUs37o+A?-N7+l25e%AuYMKs(6?rFq~9z!3w;V_9^$INnqlUM;)#^)nVWtmBl-*z zi|n<2KUmEM;MKm;E5T3uQ*lO}pu;eQ9_@Tksdt8r12K_WDXj)lJG4X9sRs3^r$v_l zMhpms3k50ZWs?hxcDIjIoB>X z!&pBy1T!Ov9G$dgI$!c5(_@3+4JhV*>oBqfiKY9HoP zXj7rkT{$+Pxq-rigr6m}cUw*W8H-jMXlR>BDd#)#d z8*g=hF-7v^BHo7%S(^#nhezZbx)vBBt->c?TF$o^b3b3+ma{nRHnbKmzNrRI_`r~j z?$DmADSn+zkGt}d2&ihMGN0?+u=5)GS@j8k=|jw4XgW~_6_tNa{!1i6_gK6TyZt<7 z^0Le8uP&A61nI7q6>F#Z$P3nZ<31^F)C7bmIq&QkD2p!9yKwQklYcmT*WuacFCCqY zVEO6y3R;SjG-cb8CghO|70Rbe)V&Inoi($|B$rqfTS7mL;d>h315M03I=<=GKw`aJ zgrNU;u8Ol3`FmB%GwLLel_vFi>X90|n+BIo0ntwe4tCIA*#xd5*(aW=cz~z1uYIG9Z)WLT zU}Ew@ZA`OG*!Eg;SlipW!w1B+#s=t^bPtl2rJ%^#VWXfHrf-<#!-n0J-vvr<4*h)$ z;M~m4I02R1g4J=nh}c53ki>k5bL>0F2`6bQ9gbrIyekhK89`KobL2|k`?9;MrcaHR z$S0i*S~KRe(oHn_vI9&=ghkk*`A9qmwgE(-tXMxrnmZU?)XA}TsD94J?fx8H*-GHS z`YjkXZOG8*B5$el76^CkqoR(6#I?p6r|XoWoDgN+)nwDTahl|I;HAn`@`DG z(Au@#)a@qZ*Bixj?L51Ei}n73t!h~k_)zT~$`plLRj3ED^!H$m=DBLx-N~>Yjz^aM z07?}Q+%*2PAC&py#1D5>4QEpiW|OJWxp{W?h=0aeCL9GH!`{1bCtd5cAF8Efzj?jA zJ`VYvi&KM2$UWB`*Svk?i<&)v44-cu1^rr|nlg@lbIpx}bOER~`soK=#%pBl0|AZ| zvWMY1q~ehUePDtw3~G&694z@%P?duu3X85xHMdo18yJoX^zPVX?Be1MBMz40Fl5hv56uog;MqW?j@z z(X4fSDdX`ok2lJh7a97;5oz1ip-lUlIc5J&ioPtwS6bw^yunzh!2BJPNN@SOp!?m# WnpT>px2$#`csply@qoHIz~Uc=qs65F diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/wizban/NewModelingBot.gif b/plugins/org.eclipse.emf.eef.modelingbot.editor/icons/full/wizban/NewModelingBot.gif deleted file mode 100644 index f3aa87a3ebf01a8a91fb0d31e723806831282936..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 592 zcmV-W0d~v%i^V|%GK8Cva`{am%?$baFv$A%+lO*sC(Sp z>$SJm+S=;z@%Mp)vC-1!Z+3+L|Nj6000000000000000000000A^8LW004OaEC2ui z01yBW000NAfO&$0goTEOg$WG@h=dFd1a1$Ff&vIPGXjSJC<-S4Ivqp+h5>RL3lMoi zHcf_IMNcg$AA)#;iU$E-CP_2{bGCwy1X4Z`1$JReS+;n1mQ`?GNLN1+H5tNr0C6l) zTR3%2QwAj4MiV<&A!1M?E - - - - - - - - - - %_UI_ModelingBotModelWizard_description - - - - - - - - - - - - - %_UI_EEFActionsModelWizard_description - - - - - - - - - - - - - %_UI_EclipseActionsModelWizard_description - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/pom.xml b/plugins/org.eclipse.emf.eef.modelingbot.editor/pom.xml deleted file mode 100644 index 1e511995c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/pom.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.modelingbot.editor - eclipse-plugin - - EEF ModelingBot Editor Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsActionBarContributor.java b/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsActionBarContributor.java deleted file mode 100644 index c80f8ffb2..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsActionBarContributor.java +++ /dev/null @@ -1,433 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.presentation; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.ui.viewer.IViewerProvider; - -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; - -import org.eclipse.emf.edit.ui.action.ControlAction; -import org.eclipse.emf.edit.ui.action.CreateChildAction; -import org.eclipse.emf.edit.ui.action.CreateSiblingAction; -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; -import org.eclipse.emf.edit.ui.action.LoadResourceAction; -import org.eclipse.emf.edit.ui.action.ValidateAction; - -import org.eclipse.emf.eef.modelingBot.presentation.MbotEditorPlugin; - -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.ActionContributionItem; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.action.IContributionItem; -import org.eclipse.jface.action.IContributionManager; -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.action.SubContributionItem; - -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.Viewer; - -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.PartInitException; - -/** - * This is the action bar contributor for the EEFActions model editor. - * - * - * @generated - */ -public class EEFActionsActionBarContributor - extends EditingDomainActionBarContributor - implements ISelectionChangedListener { - /** - * This keeps track of the active editor. - * - * - * @generated - */ - protected IEditorPart activeEditorPart; - - /** - * This keeps track of the current selection provider. - * - * - * @generated - */ - protected ISelectionProvider selectionProvider; - - /** - * This action opens the Properties view. - * - * - * @generated - */ - protected IAction showPropertiesViewAction = - new Action(MbotEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) { - @Override - public void run() { - try { - getPage().showView("org.eclipse.ui.views.PropertySheet"); - } - catch (PartInitException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - }; - - /** - * This action refreshes the viewer of the current editor if the editor - * implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}. - * - * - * @generated - */ - protected IAction refreshViewerAction = - new Action(MbotEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) { - @Override - public boolean isEnabled() { - return activeEditorPart instanceof IViewerProvider; - } - - @Override - public void run() { - if (activeEditorPart instanceof IViewerProvider) { - Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer(); - if (viewer != null) { - viewer.refresh(); - } - } - } - }; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected Collection createChildActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateChild actions. - * - * - * @generated - */ - protected IMenuManager createChildMenuManager; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected Collection createSiblingActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateSibling actions. - * - * - * @generated - */ - protected IMenuManager createSiblingMenuManager; - - /** - * This creates an instance of the contributor. - * - * - * @generated - */ - public EEFActionsActionBarContributor() { - super(ADDITIONS_LAST_STYLE); - loadResourceAction = new LoadResourceAction(); - validateAction = new ValidateAction(); - controlAction = new ControlAction(); - } - - /** - * This adds Separators for editor additions to the tool bar. - * - * - * @generated - */ - @Override - public void contributeToToolBar(IToolBarManager toolBarManager) { - toolBarManager.add(new Separator("eefactions-settings")); - toolBarManager.add(new Separator("eefactions-additions")); - } - - /** - * This adds to the menu bar a menu and some separators for editor additions, - * as well as the sub-menus for object creation items. - * - * - * @generated - */ - @Override - public void contributeToMenu(IMenuManager menuManager) { - super.contributeToMenu(menuManager); - - IMenuManager submenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_EEFActionsEditor_menu"), "org.eclipse.emf.eef.modelingBot.EEFActionsMenuID"); - menuManager.insertAfter("additions", submenuManager); - submenuManager.add(new Separator("settings")); - submenuManager.add(new Separator("actions")); - submenuManager.add(new Separator("additions")); - submenuManager.add(new Separator("additions-end")); - - // Prepare for CreateChild item addition or removal. - // - createChildMenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); - submenuManager.insertBefore("additions", createChildMenuManager); - - // Prepare for CreateSibling item addition or removal. - // - createSiblingMenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); - submenuManager.insertBefore("additions", createSiblingMenuManager); - - // Force an update because Eclipse hides empty menus now. - // - submenuManager.addMenuListener - (new IMenuListener() { - public void menuAboutToShow(IMenuManager menuManager) { - menuManager.updateAll(true); - } - }); - - addGlobalActions(submenuManager); - } - - /** - * When the active editor changes, this remembers the change and registers with it as a selection provider. - * - * - * @generated - */ - @Override - public void setActiveEditor(IEditorPart part) { - super.setActiveEditor(part); - activeEditorPart = part; - - // Switch to the new selection provider. - // - if (selectionProvider != null) { - selectionProvider.removeSelectionChangedListener(this); - } - if (part == null) { - selectionProvider = null; - } - else { - selectionProvider = part.getSite().getSelectionProvider(); - selectionProvider.addSelectionChangedListener(this); - - // Fake a selection changed event to update the menus. - // - if (selectionProvider.getSelection() != null) { - selectionChanged(new SelectionChangedEvent(selectionProvider, selectionProvider.getSelection())); - } - } - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionChangedListener}, - * handling {@link org.eclipse.jface.viewers.SelectionChangedEvent}s by querying for the children and siblings - * that can be added to the selected object and updating the menus accordingly. - * - * - * @generated - */ - public void selectionChanged(SelectionChangedEvent event) { - // Remove any menu items for old selection. - // - if (createChildMenuManager != null) { - depopulateManager(createChildMenuManager, createChildActions); - } - if (createSiblingMenuManager != null) { - depopulateManager(createSiblingMenuManager, createSiblingActions); - } - - // Query the new selection for appropriate new child/sibling descriptors - // - Collection newChildDescriptors = null; - Collection newSiblingDescriptors = null; - - ISelection selection = event.getSelection(); - if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) { - Object object = ((IStructuredSelection)selection).getFirstElement(); - - EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain(); - - newChildDescriptors = domain.getNewChildDescriptors(object, null); - newSiblingDescriptors = domain.getNewChildDescriptors(null, object); - } - - // Generate actions for selection; populate and redraw the menus. - // - createChildActions = generateCreateChildActions(newChildDescriptors, selection); - createSiblingActions = generateCreateSiblingActions(newSiblingDescriptors, selection); - - if (createChildMenuManager != null) { - populateManager(createChildMenuManager, createChildActions, null); - createChildMenuManager.update(true); - } - if (createSiblingMenuManager != null) { - populateManager(createSiblingMenuManager, createSiblingActions, null); - createSiblingMenuManager.update(true); - } - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateChildAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected Collection generateCreateChildActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateChildAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected Collection generateCreateSiblingActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateSiblingAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This populates the specified manager with {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection, - * by inserting them before the specified contribution item contributionID. - * If contributionID is null, they are simply added. - * - * - * @generated - */ - protected void populateManager(IContributionManager manager, Collection actions, String contributionID) { - if (actions != null) { - for (IAction action : actions) { - if (contributionID != null) { - manager.insertBefore(contributionID, action); - } - else { - manager.add(action); - } - } - } - } - - /** - * This removes from the specified manager all {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection. - * - * - * @generated - */ - protected void depopulateManager(IContributionManager manager, Collection actions) { - if (actions != null) { - IContributionItem[] items = manager.getItems(); - for (int i = 0; i < items.length; i++) { - // Look into SubContributionItems - // - IContributionItem contributionItem = items[i]; - while (contributionItem instanceof SubContributionItem) { - contributionItem = ((SubContributionItem)contributionItem).getInnerItem(); - } - - // Delete the ActionContributionItems with matching action. - // - if (contributionItem instanceof ActionContributionItem) { - IAction action = ((ActionContributionItem)contributionItem).getAction(); - if (actions.contains(action)) { - manager.remove(contributionItem); - } - } - } - } - } - - /** - * This populates the pop-up menu before it appears. - * - * - * @generated - */ - @Override - public void menuAboutToShow(IMenuManager menuManager) { - super.menuAboutToShow(menuManager); - MenuManager submenuManager = null; - - submenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); - populateManager(submenuManager, createChildActions, null); - menuManager.insertBefore("edit", submenuManager); - - submenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); - populateManager(submenuManager, createSiblingActions, null); - menuManager.insertBefore("edit", submenuManager); - } - - /** - * This inserts global actions before the "additions-end" separator. - * - * - * @generated - */ - @Override - protected void addGlobalActions(IMenuManager menuManager) { - menuManager.insertAfter("additions-end", new Separator("ui-actions")); - menuManager.insertAfter("ui-actions", showPropertiesViewAction); - - refreshViewerAction.setEnabled(refreshViewerAction.isEnabled()); - menuManager.insertAfter("ui-actions", refreshViewerAction); - - super.addGlobalActions(menuManager); - } - - /** - * This ensures that a delete action will clean up all references to deleted objects. - * - * - * @generated - */ - @Override - protected boolean removeAllReferencesOnDelete() { - return true; - } - -} \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsEditor.java b/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsEditor.java deleted file mode 100644 index a6ea4c127..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsEditor.java +++ /dev/null @@ -1,1858 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.presentation; - - -import java.io.IOException; -import java.io.InputStream; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.EventObject; -import java.util.HashMap; -import java.util.Iterator; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IMarker; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.IResourceChangeEvent; -import org.eclipse.core.resources.IResourceChangeListener; -import org.eclipse.core.resources.IResourceDelta; -import org.eclipse.core.resources.IResourceDeltaVisitor; -import org.eclipse.core.resources.ResourcesPlugin; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.NullProgressMonitor; - -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IStatusLineManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; - -import org.eclipse.jface.dialogs.MessageDialog; -import org.eclipse.jface.dialogs.ProgressMonitorDialog; - -import org.eclipse.jface.viewers.ColumnWeightData; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ListViewer; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.jface.viewers.TableLayout; -import org.eclipse.jface.viewers.TableViewer; -import org.eclipse.jface.viewers.TreeViewer; -import org.eclipse.jface.viewers.Viewer; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.custom.CTabFolder; - -import org.eclipse.swt.dnd.DND; -import org.eclipse.swt.dnd.Transfer; - -import org.eclipse.swt.events.ControlAdapter; -import org.eclipse.swt.events.ControlEvent; - -import org.eclipse.swt.graphics.Point; - -import org.eclipse.swt.layout.FillLayout; - -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Menu; -import org.eclipse.swt.widgets.Table; -import org.eclipse.swt.widgets.TableColumn; -import org.eclipse.swt.widgets.Tree; -import org.eclipse.swt.widgets.TreeColumn; - -import org.eclipse.ui.IActionBars; -import org.eclipse.ui.IEditorInput; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IEditorSite; -import org.eclipse.ui.IPartListener; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.PartInitException; - -import org.eclipse.ui.dialogs.SaveAsDialog; - -import org.eclipse.ui.ide.IGotoMarker; - -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.MultiPageEditorPart; - -import org.eclipse.ui.views.contentoutline.ContentOutline; -import org.eclipse.ui.views.contentoutline.ContentOutlinePage; -import org.eclipse.ui.views.contentoutline.IContentOutlinePage; - -import org.eclipse.ui.views.properties.IPropertySheetPage; -import org.eclipse.ui.views.properties.PropertySheet; -import org.eclipse.ui.views.properties.PropertySheetPage; - -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.command.CommandStack; -import org.eclipse.emf.common.command.CommandStackListener; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.ui.MarkerHelper; -import org.eclipse.emf.common.ui.ViewerPane; - -import org.eclipse.emf.common.ui.editor.ProblemEditorPart; - -import org.eclipse.emf.common.ui.viewer.IViewerProvider; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.URI; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EValidator; - -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.util.EContentAdapter; -import org.eclipse.emf.ecore.util.EcoreUtil; - -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; - -import org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory; - -import org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory; - -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; - -import org.eclipse.emf.edit.ui.celleditor.AdapterFactoryTreeEditor; - -import org.eclipse.emf.edit.ui.dnd.EditingDomainViewerDropAdapter; -import org.eclipse.emf.edit.ui.dnd.LocalTransfer; -import org.eclipse.emf.edit.ui.dnd.ViewerDragAdapter; - -import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.edit.ui.provider.UnwrappingSelectionProvider; - -import org.eclipse.emf.edit.ui.util.EditUIMarkerHelper; -import org.eclipse.emf.edit.ui.util.EditUIUtil; - -import org.eclipse.emf.edit.ui.view.ExtendedPropertySheetPage; - -import org.eclipse.emf.eef.modelingBot.EEFActions.provider.EEFActionsItemProviderAdapterFactory; - -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelItemProviderAdapterFactory; - -import org.eclipse.emf.ecore.provider.EcoreItemProviderAdapterFactory; - -import org.eclipse.emf.eef.components.provider.ComponentsItemProviderAdapterFactory; - -import org.eclipse.emf.eef.extended.editor.provider.EditorItemProviderAdapterFactory; - -import org.eclipse.emf.eef.extended.query.provider.QueryItemProviderAdapterFactory; - -import org.eclipse.emf.eef.mapping.filters.provider.FiltersItemProviderAdapterFactory; - -import org.eclipse.emf.eef.mapping.navigation.provider.NavigationItemProviderAdapterFactory; - -import org.eclipse.emf.eef.mapping.provider.MappingItemProviderAdapterFactory; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.provider.EclipseActionsItemProviderAdapterFactory; - -import org.eclipse.emf.eef.modelingBot.presentation.MbotEditorPlugin; - -import org.eclipse.emf.eef.modelingBot.provider.ModelingBotItemProviderAdapterFactory; - -import org.eclipse.emf.eef.toolkits.provider.ToolkitsItemProviderAdapterFactory; - -import org.eclipse.emf.eef.views.provider.ViewsItemProviderAdapterFactory; - -import org.eclipse.ui.actions.WorkspaceModifyOperation; - - -/** - * This is an example of a EEFActions model editor. - * - * - * @generated - */ -public class EEFActionsEditor - extends MultiPageEditorPart - implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker { - /** - * This keeps track of the editing domain that is used to track all changes to the model. - * - * - * @generated - */ - protected AdapterFactoryEditingDomain editingDomain; - - /** - * This is the one adapter factory used for providing views of the model. - * - * - * @generated - */ - protected ComposedAdapterFactory adapterFactory; - - /** - * This is the content outline page. - * - * - * @generated - */ - protected IContentOutlinePage contentOutlinePage; - - /** - * This is a kludge... - * - * - * @generated - */ - protected IStatusLineManager contentOutlineStatusLineManager; - - /** - * This is the content outline page's viewer. - * - * - * @generated - */ - protected TreeViewer contentOutlineViewer; - - /** - * This is the property sheet page. - * - * - * @generated - */ - protected PropertySheetPage propertySheetPage; - - /** - * This is the viewer that shadows the selection in the content outline. - * The parent relation must be correctly defined for this to work. - * - * - * @generated - */ - protected TreeViewer selectionViewer; - - /** - * This inverts the roll of parent and child in the content provider and show parents as a tree. - * - * - * @generated - */ - protected TreeViewer parentViewer; - - /** - * This shows how a tree view works. - * - * - * @generated - */ - protected TreeViewer treeViewer; - - /** - * This shows how a list view works. - * A list viewer doesn't support icons. - * - * - * @generated - */ - protected ListViewer listViewer; - - /** - * This shows how a table view works. - * A table can be used as a list with icons. - * - * - * @generated - */ - protected TableViewer tableViewer; - - /** - * This shows how a tree view with columns works. - * - * - * @generated - */ - protected TreeViewer treeViewerWithColumns; - - /** - * This keeps track of the active viewer pane, in the book. - * - * - * @generated - */ - protected ViewerPane currentViewerPane; - - /** - * This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer. - * - * - * @generated - */ - protected Viewer currentViewer; - - /** - * This listens to which ever viewer is active. - * - * - * @generated - */ - protected ISelectionChangedListener selectionChangedListener; - - /** - * This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor. - * - * - * @generated - */ - protected Collection selectionChangedListeners = new ArrayList(); - - /** - * This keeps track of the selection of the editor as a whole. - * - * - * @generated - */ - protected ISelection editorSelection = StructuredSelection.EMPTY; - - /** - * The MarkerHelper is responsible for creating workspace resource markers presented - * in Eclipse's Problems View. - * - * - * @generated - */ - protected MarkerHelper markerHelper = new EditUIMarkerHelper(); - - /** - * This listens for when the outline becomes active - * - * - * @generated - */ - protected IPartListener partListener = - new IPartListener() { - public void partActivated(IWorkbenchPart p) { - if (p instanceof ContentOutline) { - if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) { - getActionBarContributor().setActiveEditor(EEFActionsEditor.this); - - setCurrentViewer(contentOutlineViewer); - } - } - else if (p instanceof PropertySheet) { - if (((PropertySheet)p).getCurrentPage() == propertySheetPage) { - getActionBarContributor().setActiveEditor(EEFActionsEditor.this); - handleActivate(); - } - } - else if (p == EEFActionsEditor.this) { - handleActivate(); - } - } - public void partBroughtToTop(IWorkbenchPart p) { - // Ignore. - } - public void partClosed(IWorkbenchPart p) { - // Ignore. - } - public void partDeactivated(IWorkbenchPart p) { - // Ignore. - } - public void partOpened(IWorkbenchPart p) { - // Ignore. - } - }; - - /** - * Resources that have been removed since last activation. - * - * - * @generated - */ - protected Collection removedResources = new ArrayList(); - - /** - * Resources that have been changed since last activation. - * - * - * @generated - */ - protected Collection changedResources = new ArrayList(); - - /** - * Resources that have been saved. - * - * - * @generated - */ - protected Collection savedResources = new ArrayList(); - - /** - * Map to store the diagnostic associated with a resource. - * - * - * @generated - */ - protected Map resourceToDiagnosticMap = new LinkedHashMap(); - - /** - * Controls whether the problem indication should be updated. - * - * - * @generated - */ - protected boolean updateProblemIndication = true; - - /** - * Adapter used to update the problem indication when resources are demanded loaded. - * - * - * @generated - */ - protected EContentAdapter problemIndicationAdapter = - new EContentAdapter() { - @Override - public void notifyChanged(Notification notification) { - if (notification.getNotifier() instanceof Resource) { - switch (notification.getFeatureID(Resource.class)) { - case Resource.RESOURCE__IS_LOADED: - case Resource.RESOURCE__ERRORS: - case Resource.RESOURCE__WARNINGS: { - Resource resource = (Resource)notification.getNotifier(); - Diagnostic diagnostic = analyzeResourceProblems(resource, null); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, diagnostic); - } - else { - resourceToDiagnosticMap.remove(resource); - } - - if (updateProblemIndication) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - break; - } - } - } - else { - super.notifyChanged(notification); - } - } - - @Override - protected void setTarget(Resource target) { - basicSetTarget(target); - } - - @Override - protected void unsetTarget(Resource target) { - basicUnsetTarget(target); - } - }; - - /** - * This listens for workspace changes. - * - * - * @generated - */ - protected IResourceChangeListener resourceChangeListener = - new IResourceChangeListener() { - public void resourceChanged(IResourceChangeEvent event) { - IResourceDelta delta = event.getDelta(); - try { - class ResourceDeltaVisitor implements IResourceDeltaVisitor { - protected ResourceSet resourceSet = editingDomain.getResourceSet(); - protected Collection changedResources = new ArrayList(); - protected Collection removedResources = new ArrayList(); - - public boolean visit(IResourceDelta delta) { - if (delta.getResource().getType() == IResource.FILE) { - if (delta.getKind() == IResourceDelta.REMOVED || - delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) { - Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false); - if (resource != null) { - if (delta.getKind() == IResourceDelta.REMOVED) { - removedResources.add(resource); - } - else if (!savedResources.remove(resource)) { - changedResources.add(resource); - } - } - } - } - - return true; - } - - public Collection getChangedResources() { - return changedResources; - } - - public Collection getRemovedResources() { - return removedResources; - } - } - - final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor(); - delta.accept(visitor); - - if (!visitor.getRemovedResources().isEmpty()) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - removedResources.addAll(visitor.getRemovedResources()); - if (!isDirty()) { - getSite().getPage().closeEditor(EEFActionsEditor.this, false); - } - } - }); - } - - if (!visitor.getChangedResources().isEmpty()) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - changedResources.addAll(visitor.getChangedResources()); - if (getSite().getPage().getActiveEditor() == EEFActionsEditor.this) { - handleActivate(); - } - } - }); - } - } - catch (CoreException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - }; - - /** - * Handles activation of the editor or it's associated views. - * - * - * @generated - */ - protected void handleActivate() { - // Recompute the read only state. - // - if (editingDomain.getResourceToReadOnlyMap() != null) { - editingDomain.getResourceToReadOnlyMap().clear(); - - // Refresh any actions that may become enabled or disabled. - // - setSelection(getSelection()); - } - - if (!removedResources.isEmpty()) { - if (handleDirtyConflict()) { - getSite().getPage().closeEditor(EEFActionsEditor.this, false); - } - else { - removedResources.clear(); - changedResources.clear(); - savedResources.clear(); - } - } - else if (!changedResources.isEmpty()) { - changedResources.removeAll(savedResources); - handleChangedResources(); - changedResources.clear(); - savedResources.clear(); - } - } - - /** - * Handles what to do with changed resources on activation. - * - * - * @generated - */ - protected void handleChangedResources() { - if (!changedResources.isEmpty() && (!isDirty() || handleDirtyConflict())) { - if (isDirty()) { - changedResources.addAll(editingDomain.getResourceSet().getResources()); - } - editingDomain.getCommandStack().flush(); - - updateProblemIndication = false; - for (Resource resource : changedResources) { - if (resource.isLoaded()) { - resource.unload(); - try { - resource.load(Collections.EMPTY_MAP); - } - catch (IOException exception) { - if (!resourceToDiagnosticMap.containsKey(resource)) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - } - } - } - - if (AdapterFactoryEditingDomain.isStale(editorSelection)) { - setSelection(StructuredSelection.EMPTY); - } - - updateProblemIndication = true; - updateProblemIndication(); - } - } - - /** - * Updates the problems indication with the information described in the specified diagnostic. - * - * - * @generated - */ - protected void updateProblemIndication() { - if (updateProblemIndication) { - BasicDiagnostic diagnostic = - new BasicDiagnostic - (Diagnostic.OK, - "org.eclipse.emf.eef.modelingbot.editor", - 0, - null, - new Object [] { editingDomain.getResourceSet() }); - for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) { - if (childDiagnostic.getSeverity() != Diagnostic.OK) { - diagnostic.add(childDiagnostic); - } - } - - int lastEditorPage = getPageCount() - 1; - if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) { - ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic); - if (diagnostic.getSeverity() != Diagnostic.OK) { - setActivePage(lastEditorPage); - } - } - else if (diagnostic.getSeverity() != Diagnostic.OK) { - ProblemEditorPart problemEditorPart = new ProblemEditorPart(); - problemEditorPart.setDiagnostic(diagnostic); - problemEditorPart.setMarkerHelper(markerHelper); - try { - addPage(++lastEditorPage, problemEditorPart, getEditorInput()); - setPageText(lastEditorPage, problemEditorPart.getPartName()); - setActivePage(lastEditorPage); - showTabs(); - } - catch (PartInitException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - - if (markerHelper.hasMarkers(editingDomain.getResourceSet())) { - markerHelper.deleteMarkers(editingDomain.getResourceSet()); - if (diagnostic.getSeverity() != Diagnostic.OK) { - try { - markerHelper.createMarkers(diagnostic); - } - catch (CoreException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - } - } - } - - /** - * Shows a dialog that asks if conflicting changes should be discarded. - * - * - * @generated - */ - protected boolean handleDirtyConflict() { - return - MessageDialog.openQuestion - (getSite().getShell(), - getString("_UI_FileConflict_label"), - getString("_WARN_FileConflict")); - } - - /** - * This creates a model editor. - * - * - * @generated - */ - public EEFActionsEditor() { - super(); - initializeEditingDomain(); - } - - /** - * This sets up the editing domain for the model editor. - * - * - * @generated - */ - protected void initializeEditingDomain() { - // Create an adapter factory that yields item providers. - // - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - - adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ModelingBotItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EEFActionsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EclipseActionsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ComponentsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EditorItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new QueryItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new GenModelItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new MappingItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new NavigationItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new FiltersItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ViewsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ToolkitsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory()); - - // Create the command stack that will notify this editor as commands are executed. - // - BasicCommandStack commandStack = new BasicCommandStack(); - - // Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus. - // - commandStack.addCommandStackListener - (new CommandStackListener() { - public void commandStackChanged(final EventObject event) { - getContainer().getDisplay().asyncExec - (new Runnable() { - public void run() { - firePropertyChange(IEditorPart.PROP_DIRTY); - - // Try to select the affected objects. - // - Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand(); - if (mostRecentCommand != null) { - setSelectionToViewer(mostRecentCommand.getAffectedObjects()); - } - if (propertySheetPage != null && !propertySheetPage.getControl().isDisposed()) { - propertySheetPage.refresh(); - } - } - }); - } - }); - - // Create the editing domain with a special command stack. - // - editingDomain = new AdapterFactoryEditingDomain(adapterFactory, commandStack, new HashMap()); - } - - /** - * This is here for the listener to be able to call it. - * - * - * @generated - */ - @Override - protected void firePropertyChange(int action) { - super.firePropertyChange(action); - } - - /** - * This sets the selection into whichever viewer is active. - * - * - * @generated - */ - public void setSelectionToViewer(Collection collection) { - final Collection theSelection = collection; - // Make sure it's okay. - // - if (theSelection != null && !theSelection.isEmpty()) { - Runnable runnable = - new Runnable() { - public void run() { - // Try to select the items in the current content viewer of the editor. - // - if (currentViewer != null) { - currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true); - } - } - }; - getSite().getShell().getDisplay().asyncExec(runnable); - } - } - - /** - * This returns the editing domain as required by the {@link IEditingDomainProvider} interface. - * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} - * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}. - * - * - * @generated - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * - * - * @generated - */ - public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider { - /** - * - * - * @generated - */ - public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * - * - * @generated - */ - @Override - public Object [] getElements(Object object) { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ - @Override - public Object [] getChildren(Object object) { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ - @Override - public boolean hasChildren(Object object) { - Object parent = super.getParent(object); - return parent != null; - } - - /** - * - * - * @generated - */ - @Override - public Object getParent(Object object) { - return null; - } - } - - /** - * - * - * @generated - */ - public void setCurrentViewerPane(ViewerPane viewerPane) { - if (currentViewerPane != viewerPane) { - if (currentViewerPane != null) { - currentViewerPane.showFocus(false); - } - currentViewerPane = viewerPane; - } - setCurrentViewer(currentViewerPane.getViewer()); - } - - /** - * This makes sure that one content viewer, either for the current page or the outline view, if it has focus, - * is the current one. - * - * - * @generated - */ - public void setCurrentViewer(Viewer viewer) { - // If it is changing... - // - if (currentViewer != viewer) { - if (selectionChangedListener == null) { - // Create the listener on demand. - // - selectionChangedListener = - new ISelectionChangedListener() { - // This just notifies those things that are affected by the section. - // - public void selectionChanged(SelectionChangedEvent selectionChangedEvent) { - setSelection(selectionChangedEvent.getSelection()); - } - }; - } - - // Stop listening to the old one. - // - if (currentViewer != null) { - currentViewer.removeSelectionChangedListener(selectionChangedListener); - } - - // Start listening to the new one. - // - if (viewer != null) { - viewer.addSelectionChangedListener(selectionChangedListener); - } - - // Remember it. - // - currentViewer = viewer; - - // Set the editors selection based on the current viewer's selection. - // - setSelection(currentViewer == null ? StructuredSelection.EMPTY : currentViewer.getSelection()); - } - } - - /** - * This returns the viewer as required by the {@link IViewerProvider} interface. - * - * - * @generated - */ - public Viewer getViewer() { - return currentViewer; - } - - /** - * This creates a context menu for the viewer and adds a listener as well registering the menu for extension. - * - * - * @generated - */ - protected void createContextMenuFor(StructuredViewer viewer) { - MenuManager contextMenu = new MenuManager("#PopUp"); - contextMenu.add(new Separator("additions")); - contextMenu.setRemoveAllWhenShown(true); - contextMenu.addMenuListener(this); - Menu menu= contextMenu.createContextMenu(viewer.getControl()); - viewer.getControl().setMenu(menu); - getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer)); - - int dndOperations = DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK; - Transfer[] transfers = new Transfer[] { LocalTransfer.getInstance() }; - viewer.addDragSupport(dndOperations, transfers, new ViewerDragAdapter(viewer)); - viewer.addDropSupport(dndOperations, transfers, new EditingDomainViewerDropAdapter(editingDomain, viewer)); - } - - /** - * This is the method called to load a resource into the editing domain's resource set based on the editor's input. - * - * - * @generated - */ - public void createModel() { - URI resourceURI = EditUIUtil.getURI(getEditorInput()); - Exception exception = null; - Resource resource = null; - try { - // Load the resource through the editing domain. - // - resource = editingDomain.getResourceSet().getResource(resourceURI, true); - } - catch (Exception e) { - exception = e; - resource = editingDomain.getResourceSet().getResource(resourceURI, false); - } - - Diagnostic diagnostic = analyzeResourceProblems(resource, exception); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter); - } - - /** - * Returns a diagnostic describing the errors and warnings listed in the resource - * and the specified exception (if any). - * - * - * @generated - */ - public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) { - if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) { - BasicDiagnostic basicDiagnostic = - new BasicDiagnostic - (Diagnostic.ERROR, - "org.eclipse.emf.eef.modelingbot.editor", - 0, - getString("_UI_CreateModelError_message", resource.getURI()), - new Object [] { exception == null ? (Object)resource : exception }); - basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true)); - return basicDiagnostic; - } - else if (exception != null) { - return - new BasicDiagnostic - (Diagnostic.ERROR, - "org.eclipse.emf.eef.modelingbot.editor", - 0, - getString("_UI_CreateModelError_message", resource.getURI()), - new Object[] { exception }); - } - else { - return Diagnostic.OK_INSTANCE; - } - } - - /** - * This is the method used by the framework to install your own controls. - * - * - * @generated - */ - @Override - public void createPages() { - // Creates the model from the editor input - // - createModel(); - - // Only creates the other pages if there is something that can be edited - // - if (!getEditingDomain().getResourceSet().getResources().isEmpty()) { - // Create a page for the selection tree view. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EEFActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - Tree tree = new Tree(composite, SWT.MULTI); - TreeViewer newTreeViewer = new TreeViewer(tree); - return newTreeViewer; - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - selectionViewer = (TreeViewer)viewerPane.getViewer(); - selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - - selectionViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - selectionViewer.setInput(editingDomain.getResourceSet()); - selectionViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - viewerPane.setTitle(editingDomain.getResourceSet()); - - new AdapterFactoryTreeEditor(selectionViewer.getTree(), adapterFactory); - - createContextMenuFor(selectionViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_SelectionPage_label")); - } - - // Create a page for the parent tree view. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EEFActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - Tree tree = new Tree(composite, SWT.MULTI); - TreeViewer newTreeViewer = new TreeViewer(tree); - return newTreeViewer; - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - parentViewer = (TreeViewer)viewerPane.getViewer(); - parentViewer.setAutoExpandLevel(30); - parentViewer.setContentProvider(new ReverseAdapterFactoryContentProvider(adapterFactory)); - parentViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(parentViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_ParentPage_label")); - } - - // This is the page for the list viewer - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EEFActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new ListViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - listViewer = (ListViewer)viewerPane.getViewer(); - listViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - listViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(listViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_ListPage_label")); - } - - // This is the page for the tree viewer - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EEFActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new TreeViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - treeViewer = (TreeViewer)viewerPane.getViewer(); - treeViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - treeViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - new AdapterFactoryTreeEditor(treeViewer.getTree(), adapterFactory); - - createContextMenuFor(treeViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TreePage_label")); - } - - // This is the page for the table viewer. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EEFActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new TableViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - tableViewer = (TableViewer)viewerPane.getViewer(); - - Table table = tableViewer.getTable(); - TableLayout layout = new TableLayout(); - table.setLayout(layout); - table.setHeaderVisible(true); - table.setLinesVisible(true); - - TableColumn objectColumn = new TableColumn(table, SWT.NONE); - layout.addColumnData(new ColumnWeightData(3, 100, true)); - objectColumn.setText(getString("_UI_ObjectColumn_label")); - objectColumn.setResizable(true); - - TableColumn selfColumn = new TableColumn(table, SWT.NONE); - layout.addColumnData(new ColumnWeightData(2, 100, true)); - selfColumn.setText(getString("_UI_SelfColumn_label")); - selfColumn.setResizable(true); - - tableViewer.setColumnProperties(new String [] {"a", "b"}); - tableViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(tableViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TablePage_label")); - } - - // This is the page for the table tree viewer. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EEFActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new TreeViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - treeViewerWithColumns = (TreeViewer)viewerPane.getViewer(); - - Tree tree = treeViewerWithColumns.getTree(); - tree.setLayoutData(new FillLayout()); - tree.setHeaderVisible(true); - tree.setLinesVisible(true); - - TreeColumn objectColumn = new TreeColumn(tree, SWT.NONE); - objectColumn.setText(getString("_UI_ObjectColumn_label")); - objectColumn.setResizable(true); - objectColumn.setWidth(250); - - TreeColumn selfColumn = new TreeColumn(tree, SWT.NONE); - selfColumn.setText(getString("_UI_SelfColumn_label")); - selfColumn.setResizable(true); - selfColumn.setWidth(200); - - treeViewerWithColumns.setColumnProperties(new String [] {"a", "b"}); - treeViewerWithColumns.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - treeViewerWithColumns.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(treeViewerWithColumns); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TreeWithColumnsPage_label")); - } - - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - setActivePage(0); - } - }); - } - - // Ensures that this editor will only display the page's tab - // area if there are more than one page - // - getContainer().addControlListener - (new ControlAdapter() { - boolean guard = false; - @Override - public void controlResized(ControlEvent event) { - if (!guard) { - guard = true; - hideTabs(); - guard = false; - } - } - }); - - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - - /** - * If there is just one page in the multi-page editor part, - * this hides the single tab at the bottom. - * - * - * @generated - */ - protected void hideTabs() { - if (getPageCount() <= 1) { - setPageText(0, ""); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(1); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y + 6); - } - } - } - - /** - * If there is more than one page in the multi-page editor part, - * this shows the tabs at the bottom. - * - * - * @generated - */ - protected void showTabs() { - if (getPageCount() > 1) { - setPageText(0, getString("_UI_SelectionPage_label")); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y - 6); - } - } - } - - /** - * This is used to track the active viewer. - * - * - * @generated - */ - @Override - protected void pageChange(int pageIndex) { - super.pageChange(pageIndex); - - if (contentOutlinePage != null) { - handleContentOutlineSelection(contentOutlinePage.getSelection()); - } - } - - /** - * This is how the framework determines which interfaces we implement. - * - * - * @generated - */ - @SuppressWarnings("rawtypes") - @Override - public Object getAdapter(Class key) { - if (key.equals(IContentOutlinePage.class)) { - return showOutlineView() ? getContentOutlinePage() : null; - } - else if (key.equals(IPropertySheetPage.class)) { - return getPropertySheetPage(); - } - else if (key.equals(IGotoMarker.class)) { - return this; - } - else { - return super.getAdapter(key); - } - } - - /** - * This accesses a cached version of the content outliner. - * - * - * @generated - */ - public IContentOutlinePage getContentOutlinePage() { - if (contentOutlinePage == null) { - // The content outline is just a tree. - // - class MyContentOutlinePage extends ContentOutlinePage { - @Override - public void createControl(Composite parent) { - super.createControl(parent); - contentOutlineViewer = getTreeViewer(); - contentOutlineViewer.addSelectionChangedListener(this); - - // Set up the tree viewer. - // - contentOutlineViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - contentOutlineViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - contentOutlineViewer.setInput(editingDomain.getResourceSet()); - - // Make sure our popups work. - // - createContextMenuFor(contentOutlineViewer); - - if (!editingDomain.getResourceSet().getResources().isEmpty()) { - // Select the root object in the view. - // - contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - } - } - - @Override - public void makeContributions(IMenuManager menuManager, IToolBarManager toolBarManager, IStatusLineManager statusLineManager) { - super.makeContributions(menuManager, toolBarManager, statusLineManager); - contentOutlineStatusLineManager = statusLineManager; - } - - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - } - - contentOutlinePage = new MyContentOutlinePage(); - - // Listen to selection so that we can handle it is a special way. - // - contentOutlinePage.addSelectionChangedListener - (new ISelectionChangedListener() { - // This ensures that we handle selections correctly. - // - public void selectionChanged(SelectionChangedEvent event) { - handleContentOutlineSelection(event.getSelection()); - } - }); - } - - return contentOutlinePage; - } - - /** - * This accesses a cached version of the property sheet. - * - * - * @generated - */ - public IPropertySheetPage getPropertySheetPage() { - if (propertySheetPage == null) { - propertySheetPage = - new ExtendedPropertySheetPage(editingDomain) { - @Override - public void setSelectionToViewer(List selection) { - EEFActionsEditor.this.setSelectionToViewer(selection); - EEFActionsEditor.this.setFocus(); - } - - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - }; - propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory)); - } - - return propertySheetPage; - } - - /** - * This deals with how we want selection in the outliner to affect the other views. - * - * - * @generated - */ - public void handleContentOutlineSelection(ISelection selection) { - if (currentViewerPane != null && !selection.isEmpty() && selection instanceof IStructuredSelection) { - Iterator selectedElements = ((IStructuredSelection)selection).iterator(); - if (selectedElements.hasNext()) { - // Get the first selected element. - // - Object selectedElement = selectedElements.next(); - - // If it's the selection viewer, then we want it to select the same selection as this selection. - // - if (currentViewerPane.getViewer() == selectionViewer) { - ArrayList selectionList = new ArrayList(); - selectionList.add(selectedElement); - while (selectedElements.hasNext()) { - selectionList.add(selectedElements.next()); - } - - // Set the selection to the widget. - // - selectionViewer.setSelection(new StructuredSelection(selectionList)); - } - else { - // Set the input to the widget. - // - if (currentViewerPane.getViewer().getInput() != selectedElement) { - currentViewerPane.getViewer().setInput(selectedElement); - currentViewerPane.setTitle(selectedElement); - } - } - } - } - } - - /** - * This is for implementing {@link IEditorPart} and simply tests the command stack. - * - * - * @generated - */ - @Override - public boolean isDirty() { - return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded(); - } - - /** - * This is for implementing {@link IEditorPart} and simply saves the model file. - * - * - * @generated - */ - @Override - public void doSave(IProgressMonitor progressMonitor) { - // Save only resources that have actually changed. - // - final Map saveOptions = new HashMap(); - saveOptions.put(Resource.OPTION_SAVE_ONLY_IF_CHANGED, Resource.OPTION_SAVE_ONLY_IF_CHANGED_MEMORY_BUFFER); - - // Do the work within an operation because this is a long running activity that modifies the workbench. - // - WorkspaceModifyOperation operation = - new WorkspaceModifyOperation() { - // This is the method that gets invoked when the operation runs. - // - @Override - public void execute(IProgressMonitor monitor) { - // Save the resources to the file system. - // - boolean first = true; - for (Resource resource : editingDomain.getResourceSet().getResources()) { - if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) { - try { - long timeStamp = resource.getTimeStamp(); - resource.save(saveOptions); - if (resource.getTimeStamp() != timeStamp) { - savedResources.add(resource); - } - } - catch (Exception exception) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - first = false; - } - } - } - }; - - updateProblemIndication = false; - try { - // This runs the options, and shows progress. - // - new ProgressMonitorDialog(getSite().getShell()).run(true, false, operation); - - // Refresh the necessary state. - // - ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone(); - firePropertyChange(IEditorPart.PROP_DIRTY); - } - catch (Exception exception) { - // Something went wrong that shouldn't. - // - MbotEditorPlugin.INSTANCE.log(exception); - } - updateProblemIndication = true; - updateProblemIndication(); - } - - /** - * This returns whether something has been persisted to the URI of the specified resource. - * The implementation uses the URI converter from the editor's resource set to try to open an input stream. - * - * - * @generated - */ - protected boolean isPersisted(Resource resource) { - boolean result = false; - try { - InputStream stream = editingDomain.getResourceSet().getURIConverter().createInputStream(resource.getURI()); - if (stream != null) { - result = true; - stream.close(); - } - } - catch (IOException e) { - // Ignore - } - return result; - } - - /** - * This always returns true because it is not currently supported. - * - * - * @generated - */ - @Override - public boolean isSaveAsAllowed() { - return true; - } - - /** - * This also changes the editor's input. - * - * - * @generated - */ - @Override - public void doSaveAs() { - SaveAsDialog saveAsDialog = new SaveAsDialog(getSite().getShell()); - saveAsDialog.open(); - IPath path = saveAsDialog.getResult(); - if (path != null) { - IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path); - if (file != null) { - doSaveAs(URI.createPlatformResourceURI(file.getFullPath().toString(), true), new FileEditorInput(file)); - } - } - } - - /** - * - * - * @generated - */ - protected void doSaveAs(URI uri, IEditorInput editorInput) { - (editingDomain.getResourceSet().getResources().get(0)).setURI(uri); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - IProgressMonitor progressMonitor = - getActionBars().getStatusLineManager() != null ? - getActionBars().getStatusLineManager().getProgressMonitor() : - new NullProgressMonitor(); - doSave(progressMonitor); - } - - /** - * - * - * @generated - */ - public void gotoMarker(IMarker marker) { - try { - if (marker.getType().equals(EValidator.MARKER)) { - String uriAttribute = marker.getAttribute(EValidator.URI_ATTRIBUTE, null); - if (uriAttribute != null) { - URI uri = URI.createURI(uriAttribute); - EObject eObject = editingDomain.getResourceSet().getEObject(uri, true); - if (eObject != null) { - setSelectionToViewer(Collections.singleton(editingDomain.getWrapper(eObject))); - } - } - } - } - catch (CoreException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - - /** - * This is called during startup. - * - * - * @generated - */ - @Override - public void init(IEditorSite site, IEditorInput editorInput) { - setSite(site); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - site.setSelectionProvider(this); - site.getPage().addPartListener(partListener); - ResourcesPlugin.getWorkspace().addResourceChangeListener(resourceChangeListener, IResourceChangeEvent.POST_CHANGE); - } - - /** - * - * - * @generated - */ - @Override - public void setFocus() { - if (currentViewerPane != null) { - currentViewerPane.setFocus(); - } - else { - getControl(getActivePage()).setFocus(); - } - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void addSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.add(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void removeSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.remove(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection. - * - * - * @generated - */ - public ISelection getSelection() { - return editorSelection; - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to set this editor's overall selection. - * Calling this result will notify the listeners. - * - * - * @generated - */ - public void setSelection(ISelection selection) { - editorSelection = selection; - - for (ISelectionChangedListener listener : selectionChangedListeners) { - listener.selectionChanged(new SelectionChangedEvent(this, selection)); - } - setStatusLineManager(selection); - } - - /** - * - * - * @generated - */ - public void setStatusLineManager(ISelection selection) { - IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ? - contentOutlineStatusLineManager : getActionBars().getStatusLineManager(); - - if (statusLineManager != null) { - if (selection instanceof IStructuredSelection) { - Collection collection = ((IStructuredSelection)selection).toList(); - switch (collection.size()) { - case 0: { - statusLineManager.setMessage(getString("_UI_NoObjectSelected")); - break; - } - case 1: { - String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next()); - statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text)); - break; - } - default: { - statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size()))); - break; - } - } - } - else { - statusLineManager.setMessage(""); - } - } - } - - /** - * This looks up a string in the plugin's plugin.properties file. - * - * - * @generated - */ - private static String getString(String key) { - return MbotEditorPlugin.INSTANCE.getString(key); - } - - /** - * This looks up a string in plugin.properties, making a substitution. - * - * - * @generated - */ - private static String getString(String key, Object s1) { - return MbotEditorPlugin.INSTANCE.getString(key, new Object [] { s1 }); - } - - /** - * This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu. - * - * - * @generated - */ - public void menuAboutToShow(IMenuManager menuManager) { - ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager); - } - - /** - * - * - * @generated - */ - public EditingDomainActionBarContributor getActionBarContributor() { - return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor(); - } - - /** - * - * - * @generated - */ - public IActionBars getActionBars() { - return getActionBarContributor().getActionBars(); - } - - /** - * - * - * @generated - */ - public AdapterFactory getAdapterFactory() { - return adapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public void dispose() { - updateProblemIndication = false; - - ResourcesPlugin.getWorkspace().removeResourceChangeListener(resourceChangeListener); - - getSite().getPage().removePartListener(partListener); - - adapterFactory.dispose(); - - if (getActionBarContributor().getActiveEditor() == this) { - getActionBarContributor().setActiveEditor(null); - } - - if (propertySheetPage != null) { - propertySheetPage.dispose(); - } - - if (contentOutlinePage != null) { - contentOutlinePage.dispose(); - } - - super.dispose(); - } - - /** - * Returns whether the outline view should be presented to the user. - * - * - * @generated - */ - protected boolean showOutlineView() { - return true; - } -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsModelWizard.java b/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsModelWizard.java deleted file mode 100644 index 06d1543d3..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/presentation/EEFActionsModelWizard.java +++ /dev/null @@ -1,637 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.presentation; - - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.MissingResourceException; -import java.util.StringTokenizer; - -import org.eclipse.emf.common.CommonPlugin; - -import org.eclipse.emf.common.util.URI; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; - -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.ecore.xmi.XMLResource; - -import org.eclipse.emf.edit.ui.provider.ExtendedImageRegistry; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; - -import org.eclipse.core.runtime.IProgressMonitor; - -import org.eclipse.jface.dialogs.MessageDialog; - -import org.eclipse.jface.viewers.IStructuredSelection; - -import org.eclipse.jface.wizard.Wizard; -import org.eclipse.jface.wizard.WizardPage; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.ModifyListener; -import org.eclipse.swt.events.ModifyEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Combo; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; - -import org.eclipse.ui.INewWizard; -import org.eclipse.ui.IWorkbench; - -import org.eclipse.ui.actions.WorkspaceModifyOperation; - -import org.eclipse.ui.dialogs.WizardNewFileCreationPage; - -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.ISetSelectionTarget; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsFactory; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.provider.MbotEditPlugin; - - -import org.eclipse.core.runtime.Path; - -import org.eclipse.emf.eef.modelingBot.presentation.MbotEditorPlugin; - -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; - -import org.eclipse.ui.IWorkbenchPage; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.IWorkbenchWindow; -import org.eclipse.ui.PartInitException; - - -/** - * This is a simple wizard for creating a new model file. - * - * - * @generated - */ -public class EEFActionsModelWizard extends Wizard implements INewWizard { - /** - * The supported extensions for created files. - * - * - * @generated - */ - public static final List FILE_EXTENSIONS = - Collections.unmodifiableList(Arrays.asList(MbotEditorPlugin.INSTANCE.getString("_UI_EEFActionsEditorFilenameExtensions").split("\\s*,\\s*"))); - - /** - * A formatted list of supported file extensions, suitable for display. - * - * - * @generated - */ - public static final String FORMATTED_FILE_EXTENSIONS = - MbotEditorPlugin.INSTANCE.getString("_UI_EEFActionsEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", "); - - /** - * This caches an instance of the model package. - * - * - * @generated - */ - protected EEFActionsPackage eefActionsPackage = EEFActionsPackage.eINSTANCE; - - /** - * This caches an instance of the model factory. - * - * - * @generated - */ - protected EEFActionsFactory eefActionsFactory = eefActionsPackage.getEEFActionsFactory(); - - /** - * This is the file creation page. - * - * - * @generated - */ - protected EEFActionsModelWizardNewFileCreationPage newFileCreationPage; - - /** - * This is the initial object creation page. - * - * - * @generated - */ - protected EEFActionsModelWizardInitialObjectCreationPage initialObjectCreationPage; - - /** - * Remember the selection during initialization for populating the default container. - * - * - * @generated - */ - protected IStructuredSelection selection; - - /** - * Remember the workbench during initialization. - * - * - * @generated - */ - protected IWorkbench workbench; - - /** - * Caches the names of the types that can be created as the root object. - * - * - * @generated - */ - protected List initialObjectNames; - - /** - * This just records the information. - * - * - * @generated - */ - public void init(IWorkbench workbench, IStructuredSelection selection) { - this.workbench = workbench; - this.selection = selection; - setWindowTitle(MbotEditorPlugin.INSTANCE.getString("_UI_Wizard_label")); - setDefaultPageImageDescriptor(ExtendedImageRegistry.INSTANCE.getImageDescriptor(MbotEditorPlugin.INSTANCE.getImage("full/wizban/NewEEFActions"))); - } - - /** - * Returns the names of the types that can be created as the root object. - * - * - * @generated - */ - protected Collection getInitialObjectNames() { - if (initialObjectNames == null) { - initialObjectNames = new ArrayList(); - for (EClassifier eClassifier : eefActionsPackage.getEClassifiers()) { - if (eClassifier instanceof EClass) { - EClass eClass = (EClass)eClassifier; - if (!eClass.isAbstract()) { - initialObjectNames.add(eClass.getName()); - } - } - } - Collections.sort(initialObjectNames, CommonPlugin.INSTANCE.getComparator()); - } - return initialObjectNames; - } - - /** - * Create a new model. - * - * - * @generated - */ - protected EObject createInitialModel() { - EClass eClass = (EClass)eefActionsPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName()); - EObject rootObject = eefActionsFactory.create(eClass); - return rootObject; - } - - /** - * Do the work after everything is specified. - * - * - * @generated - */ - @Override - public boolean performFinish() { - try { - // Remember the file. - // - final IFile modelFile = getModelFile(); - - // Do the work within an operation. - // - WorkspaceModifyOperation operation = - new WorkspaceModifyOperation() { - @Override - protected void execute(IProgressMonitor progressMonitor) { - try { - // Create a resource set - // - ResourceSet resourceSet = new ResourceSetImpl(); - - // Get the URI of the model file. - // - URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true); - - // Create a resource for this file. - // - Resource resource = resourceSet.createResource(fileURI); - - // Add the initial model object to the contents. - // - EObject rootObject = createInitialModel(); - if (rootObject != null) { - resource.getContents().add(rootObject); - } - - // Save the contents of the resource to the file system. - // - Map options = new HashMap(); - options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding()); - resource.save(options); - } - catch (Exception exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - finally { - progressMonitor.done(); - } - } - }; - - getContainer().run(false, false, operation); - - // Select the new file resource in the current view. - // - IWorkbenchWindow workbenchWindow = workbench.getActiveWorkbenchWindow(); - IWorkbenchPage page = workbenchWindow.getActivePage(); - final IWorkbenchPart activePart = page.getActivePart(); - if (activePart instanceof ISetSelectionTarget) { - final ISelection targetSelection = new StructuredSelection(modelFile); - getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - ((ISetSelectionTarget)activePart).selectReveal(targetSelection); - } - }); - } - - // Open an editor on the new file. - // - try { - page.openEditor - (new FileEditorInput(modelFile), - workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId()); - } - catch (PartInitException exception) { - MessageDialog.openError(workbenchWindow.getShell(), MbotEditorPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage()); - return false; - } - - return true; - } - catch (Exception exception) { - MbotEditorPlugin.INSTANCE.log(exception); - return false; - } - } - - /** - * This is the one page of the wizard. - * - * - * @generated - */ - public class EEFActionsModelWizardNewFileCreationPage extends WizardNewFileCreationPage { - /** - * Pass in the selection. - * - * - * @generated - */ - public EEFActionsModelWizardNewFileCreationPage(String pageId, IStructuredSelection selection) { - super(pageId, selection); - } - - /** - * The framework calls this to see if the file is correct. - * - * - * @generated - */ - @Override - protected boolean validatePage() { - if (super.validatePage()) { - String extension = new Path(getFileName()).getFileExtension(); - if (extension == null || !FILE_EXTENSIONS.contains(extension)) { - String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension"; - setErrorMessage(MbotEditorPlugin.INSTANCE.getString(key, new Object [] { FORMATTED_FILE_EXTENSIONS })); - return false; - } - return true; - } - return false; - } - - /** - * - * - * @generated - */ - public IFile getModelFile() { - return ResourcesPlugin.getWorkspace().getRoot().getFile(getContainerFullPath().append(getFileName())); - } - } - - /** - * This is the page where the type of object to create is selected. - * - * - * @generated - */ - public class EEFActionsModelWizardInitialObjectCreationPage extends WizardPage { - /** - * - * - * @generated - */ - protected Combo initialObjectField; - - /** - * @generated - * - * - */ - protected List encodings; - - /** - * - * - * @generated - */ - protected Combo encodingField; - - /** - * Pass in the selection. - * - * - * @generated - */ - public EEFActionsModelWizardInitialObjectCreationPage(String pageId) { - super(pageId); - } - - /** - * - * - * @generated - */ - public void createControl(Composite parent) { - Composite composite = new Composite(parent, SWT.NONE); { - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - layout.verticalSpacing = 12; - composite.setLayout(layout); - - GridData data = new GridData(); - data.verticalAlignment = GridData.FILL; - data.grabExcessVerticalSpace = true; - data.horizontalAlignment = GridData.FILL; - composite.setLayoutData(data); - } - - Label containerLabel = new Label(composite, SWT.LEFT); - { - containerLabel.setText(MbotEditorPlugin.INSTANCE.getString("_UI_ModelObject")); - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - containerLabel.setLayoutData(data); - } - - initialObjectField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - initialObjectField.setLayoutData(data); - } - - for (String objectName : getInitialObjectNames()) { - initialObjectField.add(getLabel(objectName)); - } - - if (initialObjectField.getItemCount() == 1) { - initialObjectField.select(0); - } - initialObjectField.addModifyListener(validator); - - Label encodingLabel = new Label(composite, SWT.LEFT); - { - encodingLabel.setText(MbotEditorPlugin.INSTANCE.getString("_UI_XMLEncoding")); - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - encodingLabel.setLayoutData(data); - } - encodingField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - encodingField.setLayoutData(data); - } - - for (String encoding : getEncodings()) { - encodingField.add(encoding); - } - - encodingField.select(0); - encodingField.addModifyListener(validator); - - setPageComplete(validatePage()); - setControl(composite); - } - - /** - * - * - * @generated - */ - protected ModifyListener validator = - new ModifyListener() { - public void modifyText(ModifyEvent e) { - setPageComplete(validatePage()); - } - }; - - /** - * - * - * @generated - */ - protected boolean validatePage() { - return getInitialObjectName() != null && getEncodings().contains(encodingField.getText()); - } - - /** - * - * - * @generated - */ - @Override - public void setVisible(boolean visible) { - super.setVisible(visible); - if (visible) { - if (initialObjectField.getItemCount() == 1) { - initialObjectField.clearSelection(); - encodingField.setFocus(); - } - else { - encodingField.clearSelection(); - initialObjectField.setFocus(); - } - } - } - - /** - * - * - * @generated - */ - public String getInitialObjectName() { - String label = initialObjectField.getText(); - - for (String name : getInitialObjectNames()) { - if (getLabel(name).equals(label)) { - return name; - } - } - return null; - } - - /** - * - * - * @generated - */ - public String getEncoding() { - return encodingField.getText(); - } - - /** - * Returns the label for the specified type name. - * - * - * @generated - */ - protected String getLabel(String typeName) { - try { - return MbotEditPlugin.INSTANCE.getString("_UI_" + typeName + "_type"); - } - catch(MissingResourceException mre) { - MbotEditorPlugin.INSTANCE.log(mre); - } - return typeName; - } - - /** - * - * - * @generated - */ - protected Collection getEncodings() { - if (encodings == null) { - encodings = new ArrayList(); - for (StringTokenizer stringTokenizer = new StringTokenizer(MbotEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens(); ) { - encodings.add(stringTokenizer.nextToken()); - } - } - return encodings; - } - } - - /** - * The framework calls this to create the contents of the wizard. - * - * - * @generated - */ - @Override - public void addPages() { - // Create a page, set the title, and the initial model file name. - // - newFileCreationPage = new EEFActionsModelWizardNewFileCreationPage("Whatever", selection); - newFileCreationPage.setTitle(MbotEditorPlugin.INSTANCE.getString("_UI_EEFActionsModelWizard_label")); - newFileCreationPage.setDescription(MbotEditorPlugin.INSTANCE.getString("_UI_EEFActionsModelWizard_description")); - newFileCreationPage.setFileName(MbotEditorPlugin.INSTANCE.getString("_UI_EEFActionsEditorFilenameDefaultBase") + "." + FILE_EXTENSIONS.get(0)); - addPage(newFileCreationPage); - - // Try and get the resource selection to determine a current directory for the file dialog. - // - if (selection != null && !selection.isEmpty()) { - // Get the resource... - // - Object selectedElement = selection.iterator().next(); - if (selectedElement instanceof IResource) { - // Get the resource parent, if its a file. - // - IResource selectedResource = (IResource)selectedElement; - if (selectedResource.getType() == IResource.FILE) { - selectedResource = selectedResource.getParent(); - } - - // This gives us a directory... - // - if (selectedResource instanceof IFolder || selectedResource instanceof IProject) { - // Set this for the container. - // - newFileCreationPage.setContainerFullPath(selectedResource.getFullPath()); - - // Make up a unique new name here. - // - String defaultModelBaseFilename = MbotEditorPlugin.INSTANCE.getString("_UI_EEFActionsEditorFilenameDefaultBase"); - String defaultModelFilenameExtension = FILE_EXTENSIONS.get(0); - String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension; - for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) { - modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension; - } - newFileCreationPage.setFileName(modelFilename); - } - } - } - initialObjectCreationPage = new EEFActionsModelWizardInitialObjectCreationPage("Whatever2"); - initialObjectCreationPage.setTitle(MbotEditorPlugin.INSTANCE.getString("_UI_EEFActionsModelWizard_label")); - initialObjectCreationPage.setDescription(MbotEditorPlugin.INSTANCE.getString("_UI_Wizard_initial_object_description")); - addPage(initialObjectCreationPage); - } - - /** - * Get the file from the page. - * - * - * @generated - */ - public IFile getModelFile() { - return newFileCreationPage.getModelFile(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsActionBarContributor.java b/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsActionBarContributor.java deleted file mode 100644 index f33b24926..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsActionBarContributor.java +++ /dev/null @@ -1,433 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.presentation; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.ui.viewer.IViewerProvider; - -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; - -import org.eclipse.emf.edit.ui.action.ControlAction; -import org.eclipse.emf.edit.ui.action.CreateChildAction; -import org.eclipse.emf.edit.ui.action.CreateSiblingAction; -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; -import org.eclipse.emf.edit.ui.action.LoadResourceAction; -import org.eclipse.emf.edit.ui.action.ValidateAction; - -import org.eclipse.emf.eef.modelingBot.presentation.MbotEditorPlugin; - -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.ActionContributionItem; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.action.IContributionItem; -import org.eclipse.jface.action.IContributionManager; -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.action.SubContributionItem; - -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.Viewer; - -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.PartInitException; - -/** - * This is the action bar contributor for the EclipseActions model editor. - * - * - * @generated - */ -public class EclipseActionsActionBarContributor - extends EditingDomainActionBarContributor - implements ISelectionChangedListener { - /** - * This keeps track of the active editor. - * - * - * @generated - */ - protected IEditorPart activeEditorPart; - - /** - * This keeps track of the current selection provider. - * - * - * @generated - */ - protected ISelectionProvider selectionProvider; - - /** - * This action opens the Properties view. - * - * - * @generated - */ - protected IAction showPropertiesViewAction = - new Action(MbotEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) { - @Override - public void run() { - try { - getPage().showView("org.eclipse.ui.views.PropertySheet"); - } - catch (PartInitException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - }; - - /** - * This action refreshes the viewer of the current editor if the editor - * implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}. - * - * - * @generated - */ - protected IAction refreshViewerAction = - new Action(MbotEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) { - @Override - public boolean isEnabled() { - return activeEditorPart instanceof IViewerProvider; - } - - @Override - public void run() { - if (activeEditorPart instanceof IViewerProvider) { - Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer(); - if (viewer != null) { - viewer.refresh(); - } - } - } - }; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected Collection createChildActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateChild actions. - * - * - * @generated - */ - protected IMenuManager createChildMenuManager; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected Collection createSiblingActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateSibling actions. - * - * - * @generated - */ - protected IMenuManager createSiblingMenuManager; - - /** - * This creates an instance of the contributor. - * - * - * @generated - */ - public EclipseActionsActionBarContributor() { - super(ADDITIONS_LAST_STYLE); - loadResourceAction = new LoadResourceAction(); - validateAction = new ValidateAction(); - controlAction = new ControlAction(); - } - - /** - * This adds Separators for editor additions to the tool bar. - * - * - * @generated - */ - @Override - public void contributeToToolBar(IToolBarManager toolBarManager) { - toolBarManager.add(new Separator("eclipseactions-settings")); - toolBarManager.add(new Separator("eclipseactions-additions")); - } - - /** - * This adds to the menu bar a menu and some separators for editor additions, - * as well as the sub-menus for object creation items. - * - * - * @generated - */ - @Override - public void contributeToMenu(IMenuManager menuManager) { - super.contributeToMenu(menuManager); - - IMenuManager submenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_EclipseActionsEditor_menu"), "org.eclipse.emf.eef.modelingBot.EclipseActionsMenuID"); - menuManager.insertAfter("additions", submenuManager); - submenuManager.add(new Separator("settings")); - submenuManager.add(new Separator("actions")); - submenuManager.add(new Separator("additions")); - submenuManager.add(new Separator("additions-end")); - - // Prepare for CreateChild item addition or removal. - // - createChildMenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); - submenuManager.insertBefore("additions", createChildMenuManager); - - // Prepare for CreateSibling item addition or removal. - // - createSiblingMenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); - submenuManager.insertBefore("additions", createSiblingMenuManager); - - // Force an update because Eclipse hides empty menus now. - // - submenuManager.addMenuListener - (new IMenuListener() { - public void menuAboutToShow(IMenuManager menuManager) { - menuManager.updateAll(true); - } - }); - - addGlobalActions(submenuManager); - } - - /** - * When the active editor changes, this remembers the change and registers with it as a selection provider. - * - * - * @generated - */ - @Override - public void setActiveEditor(IEditorPart part) { - super.setActiveEditor(part); - activeEditorPart = part; - - // Switch to the new selection provider. - // - if (selectionProvider != null) { - selectionProvider.removeSelectionChangedListener(this); - } - if (part == null) { - selectionProvider = null; - } - else { - selectionProvider = part.getSite().getSelectionProvider(); - selectionProvider.addSelectionChangedListener(this); - - // Fake a selection changed event to update the menus. - // - if (selectionProvider.getSelection() != null) { - selectionChanged(new SelectionChangedEvent(selectionProvider, selectionProvider.getSelection())); - } - } - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionChangedListener}, - * handling {@link org.eclipse.jface.viewers.SelectionChangedEvent}s by querying for the children and siblings - * that can be added to the selected object and updating the menus accordingly. - * - * - * @generated - */ - public void selectionChanged(SelectionChangedEvent event) { - // Remove any menu items for old selection. - // - if (createChildMenuManager != null) { - depopulateManager(createChildMenuManager, createChildActions); - } - if (createSiblingMenuManager != null) { - depopulateManager(createSiblingMenuManager, createSiblingActions); - } - - // Query the new selection for appropriate new child/sibling descriptors - // - Collection newChildDescriptors = null; - Collection newSiblingDescriptors = null; - - ISelection selection = event.getSelection(); - if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) { - Object object = ((IStructuredSelection)selection).getFirstElement(); - - EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain(); - - newChildDescriptors = domain.getNewChildDescriptors(object, null); - newSiblingDescriptors = domain.getNewChildDescriptors(null, object); - } - - // Generate actions for selection; populate and redraw the menus. - // - createChildActions = generateCreateChildActions(newChildDescriptors, selection); - createSiblingActions = generateCreateSiblingActions(newSiblingDescriptors, selection); - - if (createChildMenuManager != null) { - populateManager(createChildMenuManager, createChildActions, null); - createChildMenuManager.update(true); - } - if (createSiblingMenuManager != null) { - populateManager(createSiblingMenuManager, createSiblingActions, null); - createSiblingMenuManager.update(true); - } - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateChildAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected Collection generateCreateChildActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateChildAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected Collection generateCreateSiblingActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateSiblingAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This populates the specified manager with {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection, - * by inserting them before the specified contribution item contributionID. - * If contributionID is null, they are simply added. - * - * - * @generated - */ - protected void populateManager(IContributionManager manager, Collection actions, String contributionID) { - if (actions != null) { - for (IAction action : actions) { - if (contributionID != null) { - manager.insertBefore(contributionID, action); - } - else { - manager.add(action); - } - } - } - } - - /** - * This removes from the specified manager all {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection. - * - * - * @generated - */ - protected void depopulateManager(IContributionManager manager, Collection actions) { - if (actions != null) { - IContributionItem[] items = manager.getItems(); - for (int i = 0; i < items.length; i++) { - // Look into SubContributionItems - // - IContributionItem contributionItem = items[i]; - while (contributionItem instanceof SubContributionItem) { - contributionItem = ((SubContributionItem)contributionItem).getInnerItem(); - } - - // Delete the ActionContributionItems with matching action. - // - if (contributionItem instanceof ActionContributionItem) { - IAction action = ((ActionContributionItem)contributionItem).getAction(); - if (actions.contains(action)) { - manager.remove(contributionItem); - } - } - } - } - } - - /** - * This populates the pop-up menu before it appears. - * - * - * @generated - */ - @Override - public void menuAboutToShow(IMenuManager menuManager) { - super.menuAboutToShow(menuManager); - MenuManager submenuManager = null; - - submenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); - populateManager(submenuManager, createChildActions, null); - menuManager.insertBefore("edit", submenuManager); - - submenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); - populateManager(submenuManager, createSiblingActions, null); - menuManager.insertBefore("edit", submenuManager); - } - - /** - * This inserts global actions before the "additions-end" separator. - * - * - * @generated - */ - @Override - protected void addGlobalActions(IMenuManager menuManager) { - menuManager.insertAfter("additions-end", new Separator("ui-actions")); - menuManager.insertAfter("ui-actions", showPropertiesViewAction); - - refreshViewerAction.setEnabled(refreshViewerAction.isEnabled()); - menuManager.insertAfter("ui-actions", refreshViewerAction); - - super.addGlobalActions(menuManager); - } - - /** - * This ensures that a delete action will clean up all references to deleted objects. - * - * - * @generated - */ - @Override - protected boolean removeAllReferencesOnDelete() { - return true; - } - -} \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsEditor.java b/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsEditor.java deleted file mode 100644 index 756316d6f..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsEditor.java +++ /dev/null @@ -1,1858 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.presentation; - - -import java.io.IOException; -import java.io.InputStream; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.EventObject; -import java.util.HashMap; -import java.util.Iterator; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IMarker; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.IResourceChangeEvent; -import org.eclipse.core.resources.IResourceChangeListener; -import org.eclipse.core.resources.IResourceDelta; -import org.eclipse.core.resources.IResourceDeltaVisitor; -import org.eclipse.core.resources.ResourcesPlugin; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.NullProgressMonitor; - -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IStatusLineManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; - -import org.eclipse.jface.dialogs.MessageDialog; -import org.eclipse.jface.dialogs.ProgressMonitorDialog; - -import org.eclipse.jface.viewers.ColumnWeightData; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ListViewer; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.jface.viewers.TableLayout; -import org.eclipse.jface.viewers.TableViewer; -import org.eclipse.jface.viewers.TreeViewer; -import org.eclipse.jface.viewers.Viewer; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.custom.CTabFolder; - -import org.eclipse.swt.dnd.DND; -import org.eclipse.swt.dnd.Transfer; - -import org.eclipse.swt.events.ControlAdapter; -import org.eclipse.swt.events.ControlEvent; - -import org.eclipse.swt.graphics.Point; - -import org.eclipse.swt.layout.FillLayout; - -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Menu; -import org.eclipse.swt.widgets.Table; -import org.eclipse.swt.widgets.TableColumn; -import org.eclipse.swt.widgets.Tree; -import org.eclipse.swt.widgets.TreeColumn; - -import org.eclipse.ui.IActionBars; -import org.eclipse.ui.IEditorInput; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IEditorSite; -import org.eclipse.ui.IPartListener; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.PartInitException; - -import org.eclipse.ui.dialogs.SaveAsDialog; - -import org.eclipse.ui.ide.IGotoMarker; - -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.MultiPageEditorPart; - -import org.eclipse.ui.views.contentoutline.ContentOutline; -import org.eclipse.ui.views.contentoutline.ContentOutlinePage; -import org.eclipse.ui.views.contentoutline.IContentOutlinePage; - -import org.eclipse.ui.views.properties.IPropertySheetPage; -import org.eclipse.ui.views.properties.PropertySheet; -import org.eclipse.ui.views.properties.PropertySheetPage; - -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.command.CommandStack; -import org.eclipse.emf.common.command.CommandStackListener; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.ui.MarkerHelper; -import org.eclipse.emf.common.ui.ViewerPane; - -import org.eclipse.emf.common.ui.editor.ProblemEditorPart; - -import org.eclipse.emf.common.ui.viewer.IViewerProvider; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.URI; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EValidator; - -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.util.EContentAdapter; -import org.eclipse.emf.ecore.util.EcoreUtil; - -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; - -import org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory; - -import org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory; - -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; - -import org.eclipse.emf.edit.ui.celleditor.AdapterFactoryTreeEditor; - -import org.eclipse.emf.edit.ui.dnd.EditingDomainViewerDropAdapter; -import org.eclipse.emf.edit.ui.dnd.LocalTransfer; -import org.eclipse.emf.edit.ui.dnd.ViewerDragAdapter; - -import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.edit.ui.provider.UnwrappingSelectionProvider; - -import org.eclipse.emf.edit.ui.util.EditUIMarkerHelper; -import org.eclipse.emf.edit.ui.util.EditUIUtil; - -import org.eclipse.emf.edit.ui.view.ExtendedPropertySheetPage; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.provider.EclipseActionsItemProviderAdapterFactory; - -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelItemProviderAdapterFactory; - -import org.eclipse.emf.ecore.provider.EcoreItemProviderAdapterFactory; - -import org.eclipse.emf.eef.components.provider.ComponentsItemProviderAdapterFactory; - -import org.eclipse.emf.eef.extended.editor.provider.EditorItemProviderAdapterFactory; - -import org.eclipse.emf.eef.extended.query.provider.QueryItemProviderAdapterFactory; - -import org.eclipse.emf.eef.mapping.filters.provider.FiltersItemProviderAdapterFactory; - -import org.eclipse.emf.eef.mapping.navigation.provider.NavigationItemProviderAdapterFactory; - -import org.eclipse.emf.eef.mapping.provider.MappingItemProviderAdapterFactory; - -import org.eclipse.emf.eef.modelingBot.EEFActions.provider.EEFActionsItemProviderAdapterFactory; - -import org.eclipse.emf.eef.modelingBot.presentation.MbotEditorPlugin; - -import org.eclipse.emf.eef.modelingBot.provider.ModelingBotItemProviderAdapterFactory; - -import org.eclipse.emf.eef.toolkits.provider.ToolkitsItemProviderAdapterFactory; - -import org.eclipse.emf.eef.views.provider.ViewsItemProviderAdapterFactory; - -import org.eclipse.ui.actions.WorkspaceModifyOperation; - - -/** - * This is an example of a EclipseActions model editor. - * - * - * @generated - */ -public class EclipseActionsEditor - extends MultiPageEditorPart - implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker { - /** - * This keeps track of the editing domain that is used to track all changes to the model. - * - * - * @generated - */ - protected AdapterFactoryEditingDomain editingDomain; - - /** - * This is the one adapter factory used for providing views of the model. - * - * - * @generated - */ - protected ComposedAdapterFactory adapterFactory; - - /** - * This is the content outline page. - * - * - * @generated - */ - protected IContentOutlinePage contentOutlinePage; - - /** - * This is a kludge... - * - * - * @generated - */ - protected IStatusLineManager contentOutlineStatusLineManager; - - /** - * This is the content outline page's viewer. - * - * - * @generated - */ - protected TreeViewer contentOutlineViewer; - - /** - * This is the property sheet page. - * - * - * @generated - */ - protected PropertySheetPage propertySheetPage; - - /** - * This is the viewer that shadows the selection in the content outline. - * The parent relation must be correctly defined for this to work. - * - * - * @generated - */ - protected TreeViewer selectionViewer; - - /** - * This inverts the roll of parent and child in the content provider and show parents as a tree. - * - * - * @generated - */ - protected TreeViewer parentViewer; - - /** - * This shows how a tree view works. - * - * - * @generated - */ - protected TreeViewer treeViewer; - - /** - * This shows how a list view works. - * A list viewer doesn't support icons. - * - * - * @generated - */ - protected ListViewer listViewer; - - /** - * This shows how a table view works. - * A table can be used as a list with icons. - * - * - * @generated - */ - protected TableViewer tableViewer; - - /** - * This shows how a tree view with columns works. - * - * - * @generated - */ - protected TreeViewer treeViewerWithColumns; - - /** - * This keeps track of the active viewer pane, in the book. - * - * - * @generated - */ - protected ViewerPane currentViewerPane; - - /** - * This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer. - * - * - * @generated - */ - protected Viewer currentViewer; - - /** - * This listens to which ever viewer is active. - * - * - * @generated - */ - protected ISelectionChangedListener selectionChangedListener; - - /** - * This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor. - * - * - * @generated - */ - protected Collection selectionChangedListeners = new ArrayList(); - - /** - * This keeps track of the selection of the editor as a whole. - * - * - * @generated - */ - protected ISelection editorSelection = StructuredSelection.EMPTY; - - /** - * The MarkerHelper is responsible for creating workspace resource markers presented - * in Eclipse's Problems View. - * - * - * @generated - */ - protected MarkerHelper markerHelper = new EditUIMarkerHelper(); - - /** - * This listens for when the outline becomes active - * - * - * @generated - */ - protected IPartListener partListener = - new IPartListener() { - public void partActivated(IWorkbenchPart p) { - if (p instanceof ContentOutline) { - if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) { - getActionBarContributor().setActiveEditor(EclipseActionsEditor.this); - - setCurrentViewer(contentOutlineViewer); - } - } - else if (p instanceof PropertySheet) { - if (((PropertySheet)p).getCurrentPage() == propertySheetPage) { - getActionBarContributor().setActiveEditor(EclipseActionsEditor.this); - handleActivate(); - } - } - else if (p == EclipseActionsEditor.this) { - handleActivate(); - } - } - public void partBroughtToTop(IWorkbenchPart p) { - // Ignore. - } - public void partClosed(IWorkbenchPart p) { - // Ignore. - } - public void partDeactivated(IWorkbenchPart p) { - // Ignore. - } - public void partOpened(IWorkbenchPart p) { - // Ignore. - } - }; - - /** - * Resources that have been removed since last activation. - * - * - * @generated - */ - protected Collection removedResources = new ArrayList(); - - /** - * Resources that have been changed since last activation. - * - * - * @generated - */ - protected Collection changedResources = new ArrayList(); - - /** - * Resources that have been saved. - * - * - * @generated - */ - protected Collection savedResources = new ArrayList(); - - /** - * Map to store the diagnostic associated with a resource. - * - * - * @generated - */ - protected Map resourceToDiagnosticMap = new LinkedHashMap(); - - /** - * Controls whether the problem indication should be updated. - * - * - * @generated - */ - protected boolean updateProblemIndication = true; - - /** - * Adapter used to update the problem indication when resources are demanded loaded. - * - * - * @generated - */ - protected EContentAdapter problemIndicationAdapter = - new EContentAdapter() { - @Override - public void notifyChanged(Notification notification) { - if (notification.getNotifier() instanceof Resource) { - switch (notification.getFeatureID(Resource.class)) { - case Resource.RESOURCE__IS_LOADED: - case Resource.RESOURCE__ERRORS: - case Resource.RESOURCE__WARNINGS: { - Resource resource = (Resource)notification.getNotifier(); - Diagnostic diagnostic = analyzeResourceProblems(resource, null); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, diagnostic); - } - else { - resourceToDiagnosticMap.remove(resource); - } - - if (updateProblemIndication) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - break; - } - } - } - else { - super.notifyChanged(notification); - } - } - - @Override - protected void setTarget(Resource target) { - basicSetTarget(target); - } - - @Override - protected void unsetTarget(Resource target) { - basicUnsetTarget(target); - } - }; - - /** - * This listens for workspace changes. - * - * - * @generated - */ - protected IResourceChangeListener resourceChangeListener = - new IResourceChangeListener() { - public void resourceChanged(IResourceChangeEvent event) { - IResourceDelta delta = event.getDelta(); - try { - class ResourceDeltaVisitor implements IResourceDeltaVisitor { - protected ResourceSet resourceSet = editingDomain.getResourceSet(); - protected Collection changedResources = new ArrayList(); - protected Collection removedResources = new ArrayList(); - - public boolean visit(IResourceDelta delta) { - if (delta.getResource().getType() == IResource.FILE) { - if (delta.getKind() == IResourceDelta.REMOVED || - delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) { - Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false); - if (resource != null) { - if (delta.getKind() == IResourceDelta.REMOVED) { - removedResources.add(resource); - } - else if (!savedResources.remove(resource)) { - changedResources.add(resource); - } - } - } - } - - return true; - } - - public Collection getChangedResources() { - return changedResources; - } - - public Collection getRemovedResources() { - return removedResources; - } - } - - final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor(); - delta.accept(visitor); - - if (!visitor.getRemovedResources().isEmpty()) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - removedResources.addAll(visitor.getRemovedResources()); - if (!isDirty()) { - getSite().getPage().closeEditor(EclipseActionsEditor.this, false); - } - } - }); - } - - if (!visitor.getChangedResources().isEmpty()) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - changedResources.addAll(visitor.getChangedResources()); - if (getSite().getPage().getActiveEditor() == EclipseActionsEditor.this) { - handleActivate(); - } - } - }); - } - } - catch (CoreException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - }; - - /** - * Handles activation of the editor or it's associated views. - * - * - * @generated - */ - protected void handleActivate() { - // Recompute the read only state. - // - if (editingDomain.getResourceToReadOnlyMap() != null) { - editingDomain.getResourceToReadOnlyMap().clear(); - - // Refresh any actions that may become enabled or disabled. - // - setSelection(getSelection()); - } - - if (!removedResources.isEmpty()) { - if (handleDirtyConflict()) { - getSite().getPage().closeEditor(EclipseActionsEditor.this, false); - } - else { - removedResources.clear(); - changedResources.clear(); - savedResources.clear(); - } - } - else if (!changedResources.isEmpty()) { - changedResources.removeAll(savedResources); - handleChangedResources(); - changedResources.clear(); - savedResources.clear(); - } - } - - /** - * Handles what to do with changed resources on activation. - * - * - * @generated - */ - protected void handleChangedResources() { - if (!changedResources.isEmpty() && (!isDirty() || handleDirtyConflict())) { - if (isDirty()) { - changedResources.addAll(editingDomain.getResourceSet().getResources()); - } - editingDomain.getCommandStack().flush(); - - updateProblemIndication = false; - for (Resource resource : changedResources) { - if (resource.isLoaded()) { - resource.unload(); - try { - resource.load(Collections.EMPTY_MAP); - } - catch (IOException exception) { - if (!resourceToDiagnosticMap.containsKey(resource)) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - } - } - } - - if (AdapterFactoryEditingDomain.isStale(editorSelection)) { - setSelection(StructuredSelection.EMPTY); - } - - updateProblemIndication = true; - updateProblemIndication(); - } - } - - /** - * Updates the problems indication with the information described in the specified diagnostic. - * - * - * @generated - */ - protected void updateProblemIndication() { - if (updateProblemIndication) { - BasicDiagnostic diagnostic = - new BasicDiagnostic - (Diagnostic.OK, - "org.eclipse.emf.eef.modelingbot.editor", - 0, - null, - new Object [] { editingDomain.getResourceSet() }); - for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) { - if (childDiagnostic.getSeverity() != Diagnostic.OK) { - diagnostic.add(childDiagnostic); - } - } - - int lastEditorPage = getPageCount() - 1; - if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) { - ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic); - if (diagnostic.getSeverity() != Diagnostic.OK) { - setActivePage(lastEditorPage); - } - } - else if (diagnostic.getSeverity() != Diagnostic.OK) { - ProblemEditorPart problemEditorPart = new ProblemEditorPart(); - problemEditorPart.setDiagnostic(diagnostic); - problemEditorPart.setMarkerHelper(markerHelper); - try { - addPage(++lastEditorPage, problemEditorPart, getEditorInput()); - setPageText(lastEditorPage, problemEditorPart.getPartName()); - setActivePage(lastEditorPage); - showTabs(); - } - catch (PartInitException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - - if (markerHelper.hasMarkers(editingDomain.getResourceSet())) { - markerHelper.deleteMarkers(editingDomain.getResourceSet()); - if (diagnostic.getSeverity() != Diagnostic.OK) { - try { - markerHelper.createMarkers(diagnostic); - } - catch (CoreException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - } - } - } - - /** - * Shows a dialog that asks if conflicting changes should be discarded. - * - * - * @generated - */ - protected boolean handleDirtyConflict() { - return - MessageDialog.openQuestion - (getSite().getShell(), - getString("_UI_FileConflict_label"), - getString("_WARN_FileConflict")); - } - - /** - * This creates a model editor. - * - * - * @generated - */ - public EclipseActionsEditor() { - super(); - initializeEditingDomain(); - } - - /** - * This sets up the editing domain for the model editor. - * - * - * @generated - */ - protected void initializeEditingDomain() { - // Create an adapter factory that yields item providers. - // - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - - adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ModelingBotItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EEFActionsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EclipseActionsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ComponentsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EditorItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new QueryItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new GenModelItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new MappingItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new NavigationItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new FiltersItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ViewsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ToolkitsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory()); - - // Create the command stack that will notify this editor as commands are executed. - // - BasicCommandStack commandStack = new BasicCommandStack(); - - // Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus. - // - commandStack.addCommandStackListener - (new CommandStackListener() { - public void commandStackChanged(final EventObject event) { - getContainer().getDisplay().asyncExec - (new Runnable() { - public void run() { - firePropertyChange(IEditorPart.PROP_DIRTY); - - // Try to select the affected objects. - // - Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand(); - if (mostRecentCommand != null) { - setSelectionToViewer(mostRecentCommand.getAffectedObjects()); - } - if (propertySheetPage != null && !propertySheetPage.getControl().isDisposed()) { - propertySheetPage.refresh(); - } - } - }); - } - }); - - // Create the editing domain with a special command stack. - // - editingDomain = new AdapterFactoryEditingDomain(adapterFactory, commandStack, new HashMap()); - } - - /** - * This is here for the listener to be able to call it. - * - * - * @generated - */ - @Override - protected void firePropertyChange(int action) { - super.firePropertyChange(action); - } - - /** - * This sets the selection into whichever viewer is active. - * - * - * @generated - */ - public void setSelectionToViewer(Collection collection) { - final Collection theSelection = collection; - // Make sure it's okay. - // - if (theSelection != null && !theSelection.isEmpty()) { - Runnable runnable = - new Runnable() { - public void run() { - // Try to select the items in the current content viewer of the editor. - // - if (currentViewer != null) { - currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true); - } - } - }; - getSite().getShell().getDisplay().asyncExec(runnable); - } - } - - /** - * This returns the editing domain as required by the {@link IEditingDomainProvider} interface. - * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} - * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}. - * - * - * @generated - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * - * - * @generated - */ - public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider { - /** - * - * - * @generated - */ - public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * - * - * @generated - */ - @Override - public Object [] getElements(Object object) { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ - @Override - public Object [] getChildren(Object object) { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ - @Override - public boolean hasChildren(Object object) { - Object parent = super.getParent(object); - return parent != null; - } - - /** - * - * - * @generated - */ - @Override - public Object getParent(Object object) { - return null; - } - } - - /** - * - * - * @generated - */ - public void setCurrentViewerPane(ViewerPane viewerPane) { - if (currentViewerPane != viewerPane) { - if (currentViewerPane != null) { - currentViewerPane.showFocus(false); - } - currentViewerPane = viewerPane; - } - setCurrentViewer(currentViewerPane.getViewer()); - } - - /** - * This makes sure that one content viewer, either for the current page or the outline view, if it has focus, - * is the current one. - * - * - * @generated - */ - public void setCurrentViewer(Viewer viewer) { - // If it is changing... - // - if (currentViewer != viewer) { - if (selectionChangedListener == null) { - // Create the listener on demand. - // - selectionChangedListener = - new ISelectionChangedListener() { - // This just notifies those things that are affected by the section. - // - public void selectionChanged(SelectionChangedEvent selectionChangedEvent) { - setSelection(selectionChangedEvent.getSelection()); - } - }; - } - - // Stop listening to the old one. - // - if (currentViewer != null) { - currentViewer.removeSelectionChangedListener(selectionChangedListener); - } - - // Start listening to the new one. - // - if (viewer != null) { - viewer.addSelectionChangedListener(selectionChangedListener); - } - - // Remember it. - // - currentViewer = viewer; - - // Set the editors selection based on the current viewer's selection. - // - setSelection(currentViewer == null ? StructuredSelection.EMPTY : currentViewer.getSelection()); - } - } - - /** - * This returns the viewer as required by the {@link IViewerProvider} interface. - * - * - * @generated - */ - public Viewer getViewer() { - return currentViewer; - } - - /** - * This creates a context menu for the viewer and adds a listener as well registering the menu for extension. - * - * - * @generated - */ - protected void createContextMenuFor(StructuredViewer viewer) { - MenuManager contextMenu = new MenuManager("#PopUp"); - contextMenu.add(new Separator("additions")); - contextMenu.setRemoveAllWhenShown(true); - contextMenu.addMenuListener(this); - Menu menu= contextMenu.createContextMenu(viewer.getControl()); - viewer.getControl().setMenu(menu); - getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer)); - - int dndOperations = DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK; - Transfer[] transfers = new Transfer[] { LocalTransfer.getInstance() }; - viewer.addDragSupport(dndOperations, transfers, new ViewerDragAdapter(viewer)); - viewer.addDropSupport(dndOperations, transfers, new EditingDomainViewerDropAdapter(editingDomain, viewer)); - } - - /** - * This is the method called to load a resource into the editing domain's resource set based on the editor's input. - * - * - * @generated - */ - public void createModel() { - URI resourceURI = EditUIUtil.getURI(getEditorInput()); - Exception exception = null; - Resource resource = null; - try { - // Load the resource through the editing domain. - // - resource = editingDomain.getResourceSet().getResource(resourceURI, true); - } - catch (Exception e) { - exception = e; - resource = editingDomain.getResourceSet().getResource(resourceURI, false); - } - - Diagnostic diagnostic = analyzeResourceProblems(resource, exception); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter); - } - - /** - * Returns a diagnostic describing the errors and warnings listed in the resource - * and the specified exception (if any). - * - * - * @generated - */ - public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) { - if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) { - BasicDiagnostic basicDiagnostic = - new BasicDiagnostic - (Diagnostic.ERROR, - "org.eclipse.emf.eef.modelingbot.editor", - 0, - getString("_UI_CreateModelError_message", resource.getURI()), - new Object [] { exception == null ? (Object)resource : exception }); - basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true)); - return basicDiagnostic; - } - else if (exception != null) { - return - new BasicDiagnostic - (Diagnostic.ERROR, - "org.eclipse.emf.eef.modelingbot.editor", - 0, - getString("_UI_CreateModelError_message", resource.getURI()), - new Object[] { exception }); - } - else { - return Diagnostic.OK_INSTANCE; - } - } - - /** - * This is the method used by the framework to install your own controls. - * - * - * @generated - */ - @Override - public void createPages() { - // Creates the model from the editor input - // - createModel(); - - // Only creates the other pages if there is something that can be edited - // - if (!getEditingDomain().getResourceSet().getResources().isEmpty()) { - // Create a page for the selection tree view. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EclipseActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - Tree tree = new Tree(composite, SWT.MULTI); - TreeViewer newTreeViewer = new TreeViewer(tree); - return newTreeViewer; - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - selectionViewer = (TreeViewer)viewerPane.getViewer(); - selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - - selectionViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - selectionViewer.setInput(editingDomain.getResourceSet()); - selectionViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - viewerPane.setTitle(editingDomain.getResourceSet()); - - new AdapterFactoryTreeEditor(selectionViewer.getTree(), adapterFactory); - - createContextMenuFor(selectionViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_SelectionPage_label")); - } - - // Create a page for the parent tree view. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EclipseActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - Tree tree = new Tree(composite, SWT.MULTI); - TreeViewer newTreeViewer = new TreeViewer(tree); - return newTreeViewer; - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - parentViewer = (TreeViewer)viewerPane.getViewer(); - parentViewer.setAutoExpandLevel(30); - parentViewer.setContentProvider(new ReverseAdapterFactoryContentProvider(adapterFactory)); - parentViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(parentViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_ParentPage_label")); - } - - // This is the page for the list viewer - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EclipseActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new ListViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - listViewer = (ListViewer)viewerPane.getViewer(); - listViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - listViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(listViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_ListPage_label")); - } - - // This is the page for the tree viewer - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EclipseActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new TreeViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - treeViewer = (TreeViewer)viewerPane.getViewer(); - treeViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - treeViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - new AdapterFactoryTreeEditor(treeViewer.getTree(), adapterFactory); - - createContextMenuFor(treeViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TreePage_label")); - } - - // This is the page for the table viewer. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EclipseActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new TableViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - tableViewer = (TableViewer)viewerPane.getViewer(); - - Table table = tableViewer.getTable(); - TableLayout layout = new TableLayout(); - table.setLayout(layout); - table.setHeaderVisible(true); - table.setLinesVisible(true); - - TableColumn objectColumn = new TableColumn(table, SWT.NONE); - layout.addColumnData(new ColumnWeightData(3, 100, true)); - objectColumn.setText(getString("_UI_ObjectColumn_label")); - objectColumn.setResizable(true); - - TableColumn selfColumn = new TableColumn(table, SWT.NONE); - layout.addColumnData(new ColumnWeightData(2, 100, true)); - selfColumn.setText(getString("_UI_SelfColumn_label")); - selfColumn.setResizable(true); - - tableViewer.setColumnProperties(new String [] {"a", "b"}); - tableViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(tableViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TablePage_label")); - } - - // This is the page for the table tree viewer. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), EclipseActionsEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new TreeViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - treeViewerWithColumns = (TreeViewer)viewerPane.getViewer(); - - Tree tree = treeViewerWithColumns.getTree(); - tree.setLayoutData(new FillLayout()); - tree.setHeaderVisible(true); - tree.setLinesVisible(true); - - TreeColumn objectColumn = new TreeColumn(tree, SWT.NONE); - objectColumn.setText(getString("_UI_ObjectColumn_label")); - objectColumn.setResizable(true); - objectColumn.setWidth(250); - - TreeColumn selfColumn = new TreeColumn(tree, SWT.NONE); - selfColumn.setText(getString("_UI_SelfColumn_label")); - selfColumn.setResizable(true); - selfColumn.setWidth(200); - - treeViewerWithColumns.setColumnProperties(new String [] {"a", "b"}); - treeViewerWithColumns.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - treeViewerWithColumns.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(treeViewerWithColumns); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TreeWithColumnsPage_label")); - } - - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - setActivePage(0); - } - }); - } - - // Ensures that this editor will only display the page's tab - // area if there are more than one page - // - getContainer().addControlListener - (new ControlAdapter() { - boolean guard = false; - @Override - public void controlResized(ControlEvent event) { - if (!guard) { - guard = true; - hideTabs(); - guard = false; - } - } - }); - - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - - /** - * If there is just one page in the multi-page editor part, - * this hides the single tab at the bottom. - * - * - * @generated - */ - protected void hideTabs() { - if (getPageCount() <= 1) { - setPageText(0, ""); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(1); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y + 6); - } - } - } - - /** - * If there is more than one page in the multi-page editor part, - * this shows the tabs at the bottom. - * - * - * @generated - */ - protected void showTabs() { - if (getPageCount() > 1) { - setPageText(0, getString("_UI_SelectionPage_label")); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y - 6); - } - } - } - - /** - * This is used to track the active viewer. - * - * - * @generated - */ - @Override - protected void pageChange(int pageIndex) { - super.pageChange(pageIndex); - - if (contentOutlinePage != null) { - handleContentOutlineSelection(contentOutlinePage.getSelection()); - } - } - - /** - * This is how the framework determines which interfaces we implement. - * - * - * @generated - */ - @SuppressWarnings("rawtypes") - @Override - public Object getAdapter(Class key) { - if (key.equals(IContentOutlinePage.class)) { - return showOutlineView() ? getContentOutlinePage() : null; - } - else if (key.equals(IPropertySheetPage.class)) { - return getPropertySheetPage(); - } - else if (key.equals(IGotoMarker.class)) { - return this; - } - else { - return super.getAdapter(key); - } - } - - /** - * This accesses a cached version of the content outliner. - * - * - * @generated - */ - public IContentOutlinePage getContentOutlinePage() { - if (contentOutlinePage == null) { - // The content outline is just a tree. - // - class MyContentOutlinePage extends ContentOutlinePage { - @Override - public void createControl(Composite parent) { - super.createControl(parent); - contentOutlineViewer = getTreeViewer(); - contentOutlineViewer.addSelectionChangedListener(this); - - // Set up the tree viewer. - // - contentOutlineViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - contentOutlineViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - contentOutlineViewer.setInput(editingDomain.getResourceSet()); - - // Make sure our popups work. - // - createContextMenuFor(contentOutlineViewer); - - if (!editingDomain.getResourceSet().getResources().isEmpty()) { - // Select the root object in the view. - // - contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - } - } - - @Override - public void makeContributions(IMenuManager menuManager, IToolBarManager toolBarManager, IStatusLineManager statusLineManager) { - super.makeContributions(menuManager, toolBarManager, statusLineManager); - contentOutlineStatusLineManager = statusLineManager; - } - - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - } - - contentOutlinePage = new MyContentOutlinePage(); - - // Listen to selection so that we can handle it is a special way. - // - contentOutlinePage.addSelectionChangedListener - (new ISelectionChangedListener() { - // This ensures that we handle selections correctly. - // - public void selectionChanged(SelectionChangedEvent event) { - handleContentOutlineSelection(event.getSelection()); - } - }); - } - - return contentOutlinePage; - } - - /** - * This accesses a cached version of the property sheet. - * - * - * @generated - */ - public IPropertySheetPage getPropertySheetPage() { - if (propertySheetPage == null) { - propertySheetPage = - new ExtendedPropertySheetPage(editingDomain) { - @Override - public void setSelectionToViewer(List selection) { - EclipseActionsEditor.this.setSelectionToViewer(selection); - EclipseActionsEditor.this.setFocus(); - } - - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - }; - propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory)); - } - - return propertySheetPage; - } - - /** - * This deals with how we want selection in the outliner to affect the other views. - * - * - * @generated - */ - public void handleContentOutlineSelection(ISelection selection) { - if (currentViewerPane != null && !selection.isEmpty() && selection instanceof IStructuredSelection) { - Iterator selectedElements = ((IStructuredSelection)selection).iterator(); - if (selectedElements.hasNext()) { - // Get the first selected element. - // - Object selectedElement = selectedElements.next(); - - // If it's the selection viewer, then we want it to select the same selection as this selection. - // - if (currentViewerPane.getViewer() == selectionViewer) { - ArrayList selectionList = new ArrayList(); - selectionList.add(selectedElement); - while (selectedElements.hasNext()) { - selectionList.add(selectedElements.next()); - } - - // Set the selection to the widget. - // - selectionViewer.setSelection(new StructuredSelection(selectionList)); - } - else { - // Set the input to the widget. - // - if (currentViewerPane.getViewer().getInput() != selectedElement) { - currentViewerPane.getViewer().setInput(selectedElement); - currentViewerPane.setTitle(selectedElement); - } - } - } - } - } - - /** - * This is for implementing {@link IEditorPart} and simply tests the command stack. - * - * - * @generated - */ - @Override - public boolean isDirty() { - return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded(); - } - - /** - * This is for implementing {@link IEditorPart} and simply saves the model file. - * - * - * @generated - */ - @Override - public void doSave(IProgressMonitor progressMonitor) { - // Save only resources that have actually changed. - // - final Map saveOptions = new HashMap(); - saveOptions.put(Resource.OPTION_SAVE_ONLY_IF_CHANGED, Resource.OPTION_SAVE_ONLY_IF_CHANGED_MEMORY_BUFFER); - - // Do the work within an operation because this is a long running activity that modifies the workbench. - // - WorkspaceModifyOperation operation = - new WorkspaceModifyOperation() { - // This is the method that gets invoked when the operation runs. - // - @Override - public void execute(IProgressMonitor monitor) { - // Save the resources to the file system. - // - boolean first = true; - for (Resource resource : editingDomain.getResourceSet().getResources()) { - if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) { - try { - long timeStamp = resource.getTimeStamp(); - resource.save(saveOptions); - if (resource.getTimeStamp() != timeStamp) { - savedResources.add(resource); - } - } - catch (Exception exception) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - first = false; - } - } - } - }; - - updateProblemIndication = false; - try { - // This runs the options, and shows progress. - // - new ProgressMonitorDialog(getSite().getShell()).run(true, false, operation); - - // Refresh the necessary state. - // - ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone(); - firePropertyChange(IEditorPart.PROP_DIRTY); - } - catch (Exception exception) { - // Something went wrong that shouldn't. - // - MbotEditorPlugin.INSTANCE.log(exception); - } - updateProblemIndication = true; - updateProblemIndication(); - } - - /** - * This returns whether something has been persisted to the URI of the specified resource. - * The implementation uses the URI converter from the editor's resource set to try to open an input stream. - * - * - * @generated - */ - protected boolean isPersisted(Resource resource) { - boolean result = false; - try { - InputStream stream = editingDomain.getResourceSet().getURIConverter().createInputStream(resource.getURI()); - if (stream != null) { - result = true; - stream.close(); - } - } - catch (IOException e) { - // Ignore - } - return result; - } - - /** - * This always returns true because it is not currently supported. - * - * - * @generated - */ - @Override - public boolean isSaveAsAllowed() { - return true; - } - - /** - * This also changes the editor's input. - * - * - * @generated - */ - @Override - public void doSaveAs() { - SaveAsDialog saveAsDialog = new SaveAsDialog(getSite().getShell()); - saveAsDialog.open(); - IPath path = saveAsDialog.getResult(); - if (path != null) { - IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path); - if (file != null) { - doSaveAs(URI.createPlatformResourceURI(file.getFullPath().toString(), true), new FileEditorInput(file)); - } - } - } - - /** - * - * - * @generated - */ - protected void doSaveAs(URI uri, IEditorInput editorInput) { - (editingDomain.getResourceSet().getResources().get(0)).setURI(uri); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - IProgressMonitor progressMonitor = - getActionBars().getStatusLineManager() != null ? - getActionBars().getStatusLineManager().getProgressMonitor() : - new NullProgressMonitor(); - doSave(progressMonitor); - } - - /** - * - * - * @generated - */ - public void gotoMarker(IMarker marker) { - try { - if (marker.getType().equals(EValidator.MARKER)) { - String uriAttribute = marker.getAttribute(EValidator.URI_ATTRIBUTE, null); - if (uriAttribute != null) { - URI uri = URI.createURI(uriAttribute); - EObject eObject = editingDomain.getResourceSet().getEObject(uri, true); - if (eObject != null) { - setSelectionToViewer(Collections.singleton(editingDomain.getWrapper(eObject))); - } - } - } - } - catch (CoreException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - - /** - * This is called during startup. - * - * - * @generated - */ - @Override - public void init(IEditorSite site, IEditorInput editorInput) { - setSite(site); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - site.setSelectionProvider(this); - site.getPage().addPartListener(partListener); - ResourcesPlugin.getWorkspace().addResourceChangeListener(resourceChangeListener, IResourceChangeEvent.POST_CHANGE); - } - - /** - * - * - * @generated - */ - @Override - public void setFocus() { - if (currentViewerPane != null) { - currentViewerPane.setFocus(); - } - else { - getControl(getActivePage()).setFocus(); - } - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void addSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.add(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void removeSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.remove(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection. - * - * - * @generated - */ - public ISelection getSelection() { - return editorSelection; - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to set this editor's overall selection. - * Calling this result will notify the listeners. - * - * - * @generated - */ - public void setSelection(ISelection selection) { - editorSelection = selection; - - for (ISelectionChangedListener listener : selectionChangedListeners) { - listener.selectionChanged(new SelectionChangedEvent(this, selection)); - } - setStatusLineManager(selection); - } - - /** - * - * - * @generated - */ - public void setStatusLineManager(ISelection selection) { - IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ? - contentOutlineStatusLineManager : getActionBars().getStatusLineManager(); - - if (statusLineManager != null) { - if (selection instanceof IStructuredSelection) { - Collection collection = ((IStructuredSelection)selection).toList(); - switch (collection.size()) { - case 0: { - statusLineManager.setMessage(getString("_UI_NoObjectSelected")); - break; - } - case 1: { - String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next()); - statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text)); - break; - } - default: { - statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size()))); - break; - } - } - } - else { - statusLineManager.setMessage(""); - } - } - } - - /** - * This looks up a string in the plugin's plugin.properties file. - * - * - * @generated - */ - private static String getString(String key) { - return MbotEditorPlugin.INSTANCE.getString(key); - } - - /** - * This looks up a string in plugin.properties, making a substitution. - * - * - * @generated - */ - private static String getString(String key, Object s1) { - return MbotEditorPlugin.INSTANCE.getString(key, new Object [] { s1 }); - } - - /** - * This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu. - * - * - * @generated - */ - public void menuAboutToShow(IMenuManager menuManager) { - ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager); - } - - /** - * - * - * @generated - */ - public EditingDomainActionBarContributor getActionBarContributor() { - return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor(); - } - - /** - * - * - * @generated - */ - public IActionBars getActionBars() { - return getActionBarContributor().getActionBars(); - } - - /** - * - * - * @generated - */ - public AdapterFactory getAdapterFactory() { - return adapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public void dispose() { - updateProblemIndication = false; - - ResourcesPlugin.getWorkspace().removeResourceChangeListener(resourceChangeListener); - - getSite().getPage().removePartListener(partListener); - - adapterFactory.dispose(); - - if (getActionBarContributor().getActiveEditor() == this) { - getActionBarContributor().setActiveEditor(null); - } - - if (propertySheetPage != null) { - propertySheetPage.dispose(); - } - - if (contentOutlinePage != null) { - contentOutlinePage.dispose(); - } - - super.dispose(); - } - - /** - * Returns whether the outline view should be presented to the user. - * - * - * @generated - */ - protected boolean showOutlineView() { - return true; - } -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsModelWizard.java b/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsModelWizard.java deleted file mode 100644 index 1f566aafb..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/presentation/EclipseActionsModelWizard.java +++ /dev/null @@ -1,637 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.presentation; - - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.MissingResourceException; -import java.util.StringTokenizer; - -import org.eclipse.emf.common.CommonPlugin; - -import org.eclipse.emf.common.util.URI; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; - -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.ecore.xmi.XMLResource; - -import org.eclipse.emf.edit.ui.provider.ExtendedImageRegistry; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; - -import org.eclipse.core.runtime.IProgressMonitor; - -import org.eclipse.jface.dialogs.MessageDialog; - -import org.eclipse.jface.viewers.IStructuredSelection; - -import org.eclipse.jface.wizard.Wizard; -import org.eclipse.jface.wizard.WizardPage; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.ModifyListener; -import org.eclipse.swt.events.ModifyEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Combo; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; - -import org.eclipse.ui.INewWizard; -import org.eclipse.ui.IWorkbench; - -import org.eclipse.ui.actions.WorkspaceModifyOperation; - -import org.eclipse.ui.dialogs.WizardNewFileCreationPage; - -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.ISetSelectionTarget; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsFactory; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.provider.MbotEditPlugin; - - -import org.eclipse.core.runtime.Path; - -import org.eclipse.emf.eef.modelingBot.presentation.MbotEditorPlugin; - -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; - -import org.eclipse.ui.IWorkbenchPage; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.IWorkbenchWindow; -import org.eclipse.ui.PartInitException; - - -/** - * This is a simple wizard for creating a new model file. - * - * - * @generated - */ -public class EclipseActionsModelWizard extends Wizard implements INewWizard { - /** - * The supported extensions for created files. - * - * - * @generated - */ - public static final List FILE_EXTENSIONS = - Collections.unmodifiableList(Arrays.asList(MbotEditorPlugin.INSTANCE.getString("_UI_EclipseActionsEditorFilenameExtensions").split("\\s*,\\s*"))); - - /** - * A formatted list of supported file extensions, suitable for display. - * - * - * @generated - */ - public static final String FORMATTED_FILE_EXTENSIONS = - MbotEditorPlugin.INSTANCE.getString("_UI_EclipseActionsEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", "); - - /** - * This caches an instance of the model package. - * - * - * @generated - */ - protected EclipseActionsPackage eclipseActionsPackage = EclipseActionsPackage.eINSTANCE; - - /** - * This caches an instance of the model factory. - * - * - * @generated - */ - protected EclipseActionsFactory eclipseActionsFactory = eclipseActionsPackage.getEclipseActionsFactory(); - - /** - * This is the file creation page. - * - * - * @generated - */ - protected EclipseActionsModelWizardNewFileCreationPage newFileCreationPage; - - /** - * This is the initial object creation page. - * - * - * @generated - */ - protected EclipseActionsModelWizardInitialObjectCreationPage initialObjectCreationPage; - - /** - * Remember the selection during initialization for populating the default container. - * - * - * @generated - */ - protected IStructuredSelection selection; - - /** - * Remember the workbench during initialization. - * - * - * @generated - */ - protected IWorkbench workbench; - - /** - * Caches the names of the types that can be created as the root object. - * - * - * @generated - */ - protected List initialObjectNames; - - /** - * This just records the information. - * - * - * @generated - */ - public void init(IWorkbench workbench, IStructuredSelection selection) { - this.workbench = workbench; - this.selection = selection; - setWindowTitle(MbotEditorPlugin.INSTANCE.getString("_UI_Wizard_label")); - setDefaultPageImageDescriptor(ExtendedImageRegistry.INSTANCE.getImageDescriptor(MbotEditorPlugin.INSTANCE.getImage("full/wizban/NewEclipseActions"))); - } - - /** - * Returns the names of the types that can be created as the root object. - * - * - * @generated - */ - protected Collection getInitialObjectNames() { - if (initialObjectNames == null) { - initialObjectNames = new ArrayList(); - for (EClassifier eClassifier : eclipseActionsPackage.getEClassifiers()) { - if (eClassifier instanceof EClass) { - EClass eClass = (EClass)eClassifier; - if (!eClass.isAbstract()) { - initialObjectNames.add(eClass.getName()); - } - } - } - Collections.sort(initialObjectNames, CommonPlugin.INSTANCE.getComparator()); - } - return initialObjectNames; - } - - /** - * Create a new model. - * - * - * @generated - */ - protected EObject createInitialModel() { - EClass eClass = (EClass)eclipseActionsPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName()); - EObject rootObject = eclipseActionsFactory.create(eClass); - return rootObject; - } - - /** - * Do the work after everything is specified. - * - * - * @generated - */ - @Override - public boolean performFinish() { - try { - // Remember the file. - // - final IFile modelFile = getModelFile(); - - // Do the work within an operation. - // - WorkspaceModifyOperation operation = - new WorkspaceModifyOperation() { - @Override - protected void execute(IProgressMonitor progressMonitor) { - try { - // Create a resource set - // - ResourceSet resourceSet = new ResourceSetImpl(); - - // Get the URI of the model file. - // - URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true); - - // Create a resource for this file. - // - Resource resource = resourceSet.createResource(fileURI); - - // Add the initial model object to the contents. - // - EObject rootObject = createInitialModel(); - if (rootObject != null) { - resource.getContents().add(rootObject); - } - - // Save the contents of the resource to the file system. - // - Map options = new HashMap(); - options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding()); - resource.save(options); - } - catch (Exception exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - finally { - progressMonitor.done(); - } - } - }; - - getContainer().run(false, false, operation); - - // Select the new file resource in the current view. - // - IWorkbenchWindow workbenchWindow = workbench.getActiveWorkbenchWindow(); - IWorkbenchPage page = workbenchWindow.getActivePage(); - final IWorkbenchPart activePart = page.getActivePart(); - if (activePart instanceof ISetSelectionTarget) { - final ISelection targetSelection = new StructuredSelection(modelFile); - getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - ((ISetSelectionTarget)activePart).selectReveal(targetSelection); - } - }); - } - - // Open an editor on the new file. - // - try { - page.openEditor - (new FileEditorInput(modelFile), - workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId()); - } - catch (PartInitException exception) { - MessageDialog.openError(workbenchWindow.getShell(), MbotEditorPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage()); - return false; - } - - return true; - } - catch (Exception exception) { - MbotEditorPlugin.INSTANCE.log(exception); - return false; - } - } - - /** - * This is the one page of the wizard. - * - * - * @generated - */ - public class EclipseActionsModelWizardNewFileCreationPage extends WizardNewFileCreationPage { - /** - * Pass in the selection. - * - * - * @generated - */ - public EclipseActionsModelWizardNewFileCreationPage(String pageId, IStructuredSelection selection) { - super(pageId, selection); - } - - /** - * The framework calls this to see if the file is correct. - * - * - * @generated - */ - @Override - protected boolean validatePage() { - if (super.validatePage()) { - String extension = new Path(getFileName()).getFileExtension(); - if (extension == null || !FILE_EXTENSIONS.contains(extension)) { - String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension"; - setErrorMessage(MbotEditorPlugin.INSTANCE.getString(key, new Object [] { FORMATTED_FILE_EXTENSIONS })); - return false; - } - return true; - } - return false; - } - - /** - * - * - * @generated - */ - public IFile getModelFile() { - return ResourcesPlugin.getWorkspace().getRoot().getFile(getContainerFullPath().append(getFileName())); - } - } - - /** - * This is the page where the type of object to create is selected. - * - * - * @generated - */ - public class EclipseActionsModelWizardInitialObjectCreationPage extends WizardPage { - /** - * - * - * @generated - */ - protected Combo initialObjectField; - - /** - * @generated - * - * - */ - protected List encodings; - - /** - * - * - * @generated - */ - protected Combo encodingField; - - /** - * Pass in the selection. - * - * - * @generated - */ - public EclipseActionsModelWizardInitialObjectCreationPage(String pageId) { - super(pageId); - } - - /** - * - * - * @generated - */ - public void createControl(Composite parent) { - Composite composite = new Composite(parent, SWT.NONE); { - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - layout.verticalSpacing = 12; - composite.setLayout(layout); - - GridData data = new GridData(); - data.verticalAlignment = GridData.FILL; - data.grabExcessVerticalSpace = true; - data.horizontalAlignment = GridData.FILL; - composite.setLayoutData(data); - } - - Label containerLabel = new Label(composite, SWT.LEFT); - { - containerLabel.setText(MbotEditorPlugin.INSTANCE.getString("_UI_ModelObject")); - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - containerLabel.setLayoutData(data); - } - - initialObjectField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - initialObjectField.setLayoutData(data); - } - - for (String objectName : getInitialObjectNames()) { - initialObjectField.add(getLabel(objectName)); - } - - if (initialObjectField.getItemCount() == 1) { - initialObjectField.select(0); - } - initialObjectField.addModifyListener(validator); - - Label encodingLabel = new Label(composite, SWT.LEFT); - { - encodingLabel.setText(MbotEditorPlugin.INSTANCE.getString("_UI_XMLEncoding")); - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - encodingLabel.setLayoutData(data); - } - encodingField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - encodingField.setLayoutData(data); - } - - for (String encoding : getEncodings()) { - encodingField.add(encoding); - } - - encodingField.select(0); - encodingField.addModifyListener(validator); - - setPageComplete(validatePage()); - setControl(composite); - } - - /** - * - * - * @generated - */ - protected ModifyListener validator = - new ModifyListener() { - public void modifyText(ModifyEvent e) { - setPageComplete(validatePage()); - } - }; - - /** - * - * - * @generated - */ - protected boolean validatePage() { - return getInitialObjectName() != null && getEncodings().contains(encodingField.getText()); - } - - /** - * - * - * @generated - */ - @Override - public void setVisible(boolean visible) { - super.setVisible(visible); - if (visible) { - if (initialObjectField.getItemCount() == 1) { - initialObjectField.clearSelection(); - encodingField.setFocus(); - } - else { - encodingField.clearSelection(); - initialObjectField.setFocus(); - } - } - } - - /** - * - * - * @generated - */ - public String getInitialObjectName() { - String label = initialObjectField.getText(); - - for (String name : getInitialObjectNames()) { - if (getLabel(name).equals(label)) { - return name; - } - } - return null; - } - - /** - * - * - * @generated - */ - public String getEncoding() { - return encodingField.getText(); - } - - /** - * Returns the label for the specified type name. - * - * - * @generated - */ - protected String getLabel(String typeName) { - try { - return MbotEditPlugin.INSTANCE.getString("_UI_" + typeName + "_type"); - } - catch(MissingResourceException mre) { - MbotEditorPlugin.INSTANCE.log(mre); - } - return typeName; - } - - /** - * - * - * @generated - */ - protected Collection getEncodings() { - if (encodings == null) { - encodings = new ArrayList(); - for (StringTokenizer stringTokenizer = new StringTokenizer(MbotEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens(); ) { - encodings.add(stringTokenizer.nextToken()); - } - } - return encodings; - } - } - - /** - * The framework calls this to create the contents of the wizard. - * - * - * @generated - */ - @Override - public void addPages() { - // Create a page, set the title, and the initial model file name. - // - newFileCreationPage = new EclipseActionsModelWizardNewFileCreationPage("Whatever", selection); - newFileCreationPage.setTitle(MbotEditorPlugin.INSTANCE.getString("_UI_EclipseActionsModelWizard_label")); - newFileCreationPage.setDescription(MbotEditorPlugin.INSTANCE.getString("_UI_EclipseActionsModelWizard_description")); - newFileCreationPage.setFileName(MbotEditorPlugin.INSTANCE.getString("_UI_EclipseActionsEditorFilenameDefaultBase") + "." + FILE_EXTENSIONS.get(0)); - addPage(newFileCreationPage); - - // Try and get the resource selection to determine a current directory for the file dialog. - // - if (selection != null && !selection.isEmpty()) { - // Get the resource... - // - Object selectedElement = selection.iterator().next(); - if (selectedElement instanceof IResource) { - // Get the resource parent, if its a file. - // - IResource selectedResource = (IResource)selectedElement; - if (selectedResource.getType() == IResource.FILE) { - selectedResource = selectedResource.getParent(); - } - - // This gives us a directory... - // - if (selectedResource instanceof IFolder || selectedResource instanceof IProject) { - // Set this for the container. - // - newFileCreationPage.setContainerFullPath(selectedResource.getFullPath()); - - // Make up a unique new name here. - // - String defaultModelBaseFilename = MbotEditorPlugin.INSTANCE.getString("_UI_EclipseActionsEditorFilenameDefaultBase"); - String defaultModelFilenameExtension = FILE_EXTENSIONS.get(0); - String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension; - for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) { - modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension; - } - newFileCreationPage.setFileName(modelFilename); - } - } - } - initialObjectCreationPage = new EclipseActionsModelWizardInitialObjectCreationPage("Whatever2"); - initialObjectCreationPage.setTitle(MbotEditorPlugin.INSTANCE.getString("_UI_EclipseActionsModelWizard_label")); - initialObjectCreationPage.setDescription(MbotEditorPlugin.INSTANCE.getString("_UI_Wizard_initial_object_description")); - addPage(initialObjectCreationPage); - } - - /** - * Get the file from the page. - * - * - * @generated - */ - public IFile getModelFile() { - return newFileCreationPage.getModelFile(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/MbotEditorPlugin.java b/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/MbotEditorPlugin.java deleted file mode 100644 index 465a78fc3..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/MbotEditorPlugin.java +++ /dev/null @@ -1,117 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.presentation; - -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelEditPlugin; - -import org.eclipse.emf.common.EMFPlugin; - -import org.eclipse.emf.common.ui.EclipseUIPlugin; - -import org.eclipse.emf.common.util.ResourceLocator; - -import org.eclipse.emf.ecore.provider.EcoreEditPlugin; - -import org.eclipse.emf.eef.components.provider.ComponentsEditPlugin; - -import org.eclipse.emf.eef.extended.editor.provider.ExtendedEditPlugin; - -import org.eclipse.emf.eef.mapping.provider.MappingEditPlugin; - -import org.eclipse.emf.eef.views.provider.ViewsEditPlugin; - -/** - * This is the central singleton for the Mbot editor plugin. - * - * - * @generated - */ -public final class MbotEditorPlugin extends EMFPlugin { - /** - * Keep track of the singleton. - * - * - * @generated - */ - public static final MbotEditorPlugin INSTANCE = new MbotEditorPlugin(); - - /** - * Keep track of the singleton. - * - * - * @generated - */ - private static Implementation plugin; - - /** - * Create the instance. - * - * - * @generated - */ - public MbotEditorPlugin() { - super - (new ResourceLocator [] { - ComponentsEditPlugin.INSTANCE, - EcoreEditPlugin.INSTANCE, - ExtendedEditPlugin.INSTANCE, - GenModelEditPlugin.INSTANCE, - MappingEditPlugin.INSTANCE, - ViewsEditPlugin.INSTANCE, - }); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - @Override - public ResourceLocator getPluginResourceLocator() { - return plugin; - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * - * - * @return the singleton instance. - * @generated - */ - public static Implementation getPlugin() { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - * - * @generated - */ - public static class Implementation extends EclipseUIPlugin { - /** - * Creates an instance. - * - * - * @generated - */ - public Implementation() { - super(); - - // Remember the static instance. - // - plugin = this; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotActionBarContributor.java b/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotActionBarContributor.java deleted file mode 100644 index ea1afbe73..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotActionBarContributor.java +++ /dev/null @@ -1,431 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.presentation; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.ui.viewer.IViewerProvider; - -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; - -import org.eclipse.emf.edit.ui.action.ControlAction; -import org.eclipse.emf.edit.ui.action.CreateChildAction; -import org.eclipse.emf.edit.ui.action.CreateSiblingAction; -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; -import org.eclipse.emf.edit.ui.action.LoadResourceAction; -import org.eclipse.emf.edit.ui.action.ValidateAction; - -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.ActionContributionItem; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.action.IContributionItem; -import org.eclipse.jface.action.IContributionManager; -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.action.SubContributionItem; - -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.Viewer; - -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.PartInitException; - -/** - * This is the action bar contributor for the ModelingBot model editor. - * - * - * @generated - */ -public class ModelingBotActionBarContributor - extends EditingDomainActionBarContributor - implements ISelectionChangedListener { - /** - * This keeps track of the active editor. - * - * - * @generated - */ - protected IEditorPart activeEditorPart; - - /** - * This keeps track of the current selection provider. - * - * - * @generated - */ - protected ISelectionProvider selectionProvider; - - /** - * This action opens the Properties view. - * - * - * @generated - */ - protected IAction showPropertiesViewAction = - new Action(MbotEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) { - @Override - public void run() { - try { - getPage().showView("org.eclipse.ui.views.PropertySheet"); - } - catch (PartInitException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - }; - - /** - * This action refreshes the viewer of the current editor if the editor - * implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}. - * - * - * @generated - */ - protected IAction refreshViewerAction = - new Action(MbotEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) { - @Override - public boolean isEnabled() { - return activeEditorPart instanceof IViewerProvider; - } - - @Override - public void run() { - if (activeEditorPart instanceof IViewerProvider) { - Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer(); - if (viewer != null) { - viewer.refresh(); - } - } - } - }; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected Collection createChildActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateChild actions. - * - * - * @generated - */ - protected IMenuManager createChildMenuManager; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} corresponding to each descriptor - * generated for the current selection by the item provider. - * - * - * @generated - */ - protected Collection createSiblingActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateSibling actions. - * - * - * @generated - */ - protected IMenuManager createSiblingMenuManager; - - /** - * This creates an instance of the contributor. - * - * - * @generated - */ - public ModelingBotActionBarContributor() { - super(ADDITIONS_LAST_STYLE); - loadResourceAction = new LoadResourceAction(); - validateAction = new ValidateAction(); - controlAction = new ControlAction(); - } - - /** - * This adds Separators for editor additions to the tool bar. - * - * - * @generated - */ - @Override - public void contributeToToolBar(IToolBarManager toolBarManager) { - toolBarManager.add(new Separator("modelingbot-settings")); - toolBarManager.add(new Separator("modelingbot-additions")); - } - - /** - * This adds to the menu bar a menu and some separators for editor additions, - * as well as the sub-menus for object creation items. - * - * - * @generated - */ - @Override - public void contributeToMenu(IMenuManager menuManager) { - super.contributeToMenu(menuManager); - - IMenuManager submenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_ModelingBotEditor_menu"), "org.eclipse.emf.eef.modelingBotMenuID"); - menuManager.insertAfter("additions", submenuManager); - submenuManager.add(new Separator("settings")); - submenuManager.add(new Separator("actions")); - submenuManager.add(new Separator("additions")); - submenuManager.add(new Separator("additions-end")); - - // Prepare for CreateChild item addition or removal. - // - createChildMenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); - submenuManager.insertBefore("additions", createChildMenuManager); - - // Prepare for CreateSibling item addition or removal. - // - createSiblingMenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); - submenuManager.insertBefore("additions", createSiblingMenuManager); - - // Force an update because Eclipse hides empty menus now. - // - submenuManager.addMenuListener - (new IMenuListener() { - public void menuAboutToShow(IMenuManager menuManager) { - menuManager.updateAll(true); - } - }); - - addGlobalActions(submenuManager); - } - - /** - * When the active editor changes, this remembers the change and registers with it as a selection provider. - * - * - * @generated - */ - @Override - public void setActiveEditor(IEditorPart part) { - super.setActiveEditor(part); - activeEditorPart = part; - - // Switch to the new selection provider. - // - if (selectionProvider != null) { - selectionProvider.removeSelectionChangedListener(this); - } - if (part == null) { - selectionProvider = null; - } - else { - selectionProvider = part.getSite().getSelectionProvider(); - selectionProvider.addSelectionChangedListener(this); - - // Fake a selection changed event to update the menus. - // - if (selectionProvider.getSelection() != null) { - selectionChanged(new SelectionChangedEvent(selectionProvider, selectionProvider.getSelection())); - } - } - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionChangedListener}, - * handling {@link org.eclipse.jface.viewers.SelectionChangedEvent}s by querying for the children and siblings - * that can be added to the selected object and updating the menus accordingly. - * - * - * @generated - */ - public void selectionChanged(SelectionChangedEvent event) { - // Remove any menu items for old selection. - // - if (createChildMenuManager != null) { - depopulateManager(createChildMenuManager, createChildActions); - } - if (createSiblingMenuManager != null) { - depopulateManager(createSiblingMenuManager, createSiblingActions); - } - - // Query the new selection for appropriate new child/sibling descriptors - // - Collection newChildDescriptors = null; - Collection newSiblingDescriptors = null; - - ISelection selection = event.getSelection(); - if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) { - Object object = ((IStructuredSelection)selection).getFirstElement(); - - EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain(); - - newChildDescriptors = domain.getNewChildDescriptors(object, null); - newSiblingDescriptors = domain.getNewChildDescriptors(null, object); - } - - // Generate actions for selection; populate and redraw the menus. - // - createChildActions = generateCreateChildActions(newChildDescriptors, selection); - createSiblingActions = generateCreateSiblingActions(newSiblingDescriptors, selection); - - if (createChildMenuManager != null) { - populateManager(createChildMenuManager, createChildActions, null); - createChildMenuManager.update(true); - } - if (createSiblingMenuManager != null) { - populateManager(createSiblingMenuManager, createSiblingActions, null); - createSiblingMenuManager.update(true); - } - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateChildAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected Collection generateCreateChildActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateChildAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} for each object in descriptors, - * and returns the collection of these actions. - * - * - * @generated - */ - protected Collection generateCreateSiblingActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateSiblingAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This populates the specified manager with {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection, - * by inserting them before the specified contribution item contributionID. - * If contributionID is null, they are simply added. - * - * - * @generated - */ - protected void populateManager(IContributionManager manager, Collection actions, String contributionID) { - if (actions != null) { - for (IAction action : actions) { - if (contributionID != null) { - manager.insertBefore(contributionID, action); - } - else { - manager.add(action); - } - } - } - } - - /** - * This removes from the specified manager all {@link org.eclipse.jface.action.ActionContributionItem}s - * based on the {@link org.eclipse.jface.action.IAction}s contained in the actions collection. - * - * - * @generated - */ - protected void depopulateManager(IContributionManager manager, Collection actions) { - if (actions != null) { - IContributionItem[] items = manager.getItems(); - for (int i = 0; i < items.length; i++) { - // Look into SubContributionItems - // - IContributionItem contributionItem = items[i]; - while (contributionItem instanceof SubContributionItem) { - contributionItem = ((SubContributionItem)contributionItem).getInnerItem(); - } - - // Delete the ActionContributionItems with matching action. - // - if (contributionItem instanceof ActionContributionItem) { - IAction action = ((ActionContributionItem)contributionItem).getAction(); - if (actions.contains(action)) { - manager.remove(contributionItem); - } - } - } - } - } - - /** - * This populates the pop-up menu before it appears. - * - * - * @generated - */ - @Override - public void menuAboutToShow(IMenuManager menuManager) { - super.menuAboutToShow(menuManager); - MenuManager submenuManager = null; - - submenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); - populateManager(submenuManager, createChildActions, null); - menuManager.insertBefore("edit", submenuManager); - - submenuManager = new MenuManager(MbotEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); - populateManager(submenuManager, createSiblingActions, null); - menuManager.insertBefore("edit", submenuManager); - } - - /** - * This inserts global actions before the "additions-end" separator. - * - * - * @generated - */ - @Override - protected void addGlobalActions(IMenuManager menuManager) { - menuManager.insertAfter("additions-end", new Separator("ui-actions")); - menuManager.insertAfter("ui-actions", showPropertiesViewAction); - - refreshViewerAction.setEnabled(refreshViewerAction.isEnabled()); - menuManager.insertAfter("ui-actions", refreshViewerAction); - - super.addGlobalActions(menuManager); - } - - /** - * This ensures that a delete action will clean up all references to deleted objects. - * - * - * @generated - */ - @Override - protected boolean removeAllReferencesOnDelete() { - return true; - } - -} \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotEditor.java b/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotEditor.java deleted file mode 100644 index 4638559f6..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotEditor.java +++ /dev/null @@ -1,1856 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.presentation; - - -import java.io.IOException; -import java.io.InputStream; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.EventObject; -import java.util.HashMap; -import java.util.Iterator; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IMarker; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.IResourceChangeEvent; -import org.eclipse.core.resources.IResourceChangeListener; -import org.eclipse.core.resources.IResourceDelta; -import org.eclipse.core.resources.IResourceDeltaVisitor; -import org.eclipse.core.resources.ResourcesPlugin; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.NullProgressMonitor; - -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IStatusLineManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; - -import org.eclipse.jface.dialogs.MessageDialog; -import org.eclipse.jface.dialogs.ProgressMonitorDialog; - -import org.eclipse.jface.viewers.ColumnWeightData; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.ListViewer; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.jface.viewers.TableLayout; -import org.eclipse.jface.viewers.TableViewer; -import org.eclipse.jface.viewers.TreeViewer; -import org.eclipse.jface.viewers.Viewer; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.custom.CTabFolder; - -import org.eclipse.swt.dnd.DND; -import org.eclipse.swt.dnd.Transfer; - -import org.eclipse.swt.events.ControlAdapter; -import org.eclipse.swt.events.ControlEvent; - -import org.eclipse.swt.graphics.Point; - -import org.eclipse.swt.layout.FillLayout; - -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Menu; -import org.eclipse.swt.widgets.Table; -import org.eclipse.swt.widgets.TableColumn; -import org.eclipse.swt.widgets.Tree; -import org.eclipse.swt.widgets.TreeColumn; - -import org.eclipse.ui.IActionBars; -import org.eclipse.ui.IEditorInput; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IEditorSite; -import org.eclipse.ui.IPartListener; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.PartInitException; - -import org.eclipse.ui.dialogs.SaveAsDialog; - -import org.eclipse.ui.ide.IGotoMarker; - -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.MultiPageEditorPart; - -import org.eclipse.ui.views.contentoutline.ContentOutline; -import org.eclipse.ui.views.contentoutline.ContentOutlinePage; -import org.eclipse.ui.views.contentoutline.IContentOutlinePage; - -import org.eclipse.ui.views.properties.IPropertySheetPage; -import org.eclipse.ui.views.properties.PropertySheet; -import org.eclipse.ui.views.properties.PropertySheetPage; - -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.command.CommandStack; -import org.eclipse.emf.common.command.CommandStackListener; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.ui.MarkerHelper; -import org.eclipse.emf.common.ui.ViewerPane; - -import org.eclipse.emf.common.ui.editor.ProblemEditorPart; - -import org.eclipse.emf.common.ui.viewer.IViewerProvider; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.URI; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EValidator; - -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.util.EContentAdapter; -import org.eclipse.emf.ecore.util.EcoreUtil; - -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; - -import org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory; - -import org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory; - -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; - -import org.eclipse.emf.edit.ui.celleditor.AdapterFactoryTreeEditor; - -import org.eclipse.emf.edit.ui.dnd.EditingDomainViewerDropAdapter; -import org.eclipse.emf.edit.ui.dnd.LocalTransfer; -import org.eclipse.emf.edit.ui.dnd.ViewerDragAdapter; - -import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.edit.ui.provider.UnwrappingSelectionProvider; - -import org.eclipse.emf.edit.ui.util.EditUIMarkerHelper; -import org.eclipse.emf.edit.ui.util.EditUIUtil; - -import org.eclipse.emf.edit.ui.view.ExtendedPropertySheetPage; - -import org.eclipse.emf.eef.modelingBot.provider.ModelingBotItemProviderAdapterFactory; - -import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelItemProviderAdapterFactory; - -import org.eclipse.emf.ecore.provider.EcoreItemProviderAdapterFactory; - -import org.eclipse.emf.eef.components.provider.ComponentsItemProviderAdapterFactory; - -import org.eclipse.emf.eef.extended.editor.provider.EditorItemProviderAdapterFactory; - -import org.eclipse.emf.eef.extended.query.provider.QueryItemProviderAdapterFactory; - -import org.eclipse.emf.eef.mapping.filters.provider.FiltersItemProviderAdapterFactory; - -import org.eclipse.emf.eef.mapping.navigation.provider.NavigationItemProviderAdapterFactory; - -import org.eclipse.emf.eef.mapping.provider.MappingItemProviderAdapterFactory; - -import org.eclipse.emf.eef.modelingBot.EEFActions.provider.EEFActionsItemProviderAdapterFactory; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.provider.EclipseActionsItemProviderAdapterFactory; - -import org.eclipse.emf.eef.toolkits.provider.ToolkitsItemProviderAdapterFactory; - -import org.eclipse.emf.eef.views.provider.ViewsItemProviderAdapterFactory; - -import org.eclipse.ui.actions.WorkspaceModifyOperation; - - -/** - * This is an example of a ModelingBot model editor. - * - * - * @generated - */ -public class ModelingBotEditor - extends MultiPageEditorPart - implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker { - /** - * This keeps track of the editing domain that is used to track all changes to the model. - * - * - * @generated - */ - protected AdapterFactoryEditingDomain editingDomain; - - /** - * This is the one adapter factory used for providing views of the model. - * - * - * @generated - */ - protected ComposedAdapterFactory adapterFactory; - - /** - * This is the content outline page. - * - * - * @generated - */ - protected IContentOutlinePage contentOutlinePage; - - /** - * This is a kludge... - * - * - * @generated - */ - protected IStatusLineManager contentOutlineStatusLineManager; - - /** - * This is the content outline page's viewer. - * - * - * @generated - */ - protected TreeViewer contentOutlineViewer; - - /** - * This is the property sheet page. - * - * - * @generated - */ - protected PropertySheetPage propertySheetPage; - - /** - * This is the viewer that shadows the selection in the content outline. - * The parent relation must be correctly defined for this to work. - * - * - * @generated - */ - protected TreeViewer selectionViewer; - - /** - * This inverts the roll of parent and child in the content provider and show parents as a tree. - * - * - * @generated - */ - protected TreeViewer parentViewer; - - /** - * This shows how a tree view works. - * - * - * @generated - */ - protected TreeViewer treeViewer; - - /** - * This shows how a list view works. - * A list viewer doesn't support icons. - * - * - * @generated - */ - protected ListViewer listViewer; - - /** - * This shows how a table view works. - * A table can be used as a list with icons. - * - * - * @generated - */ - protected TableViewer tableViewer; - - /** - * This shows how a tree view with columns works. - * - * - * @generated - */ - protected TreeViewer treeViewerWithColumns; - - /** - * This keeps track of the active viewer pane, in the book. - * - * - * @generated - */ - protected ViewerPane currentViewerPane; - - /** - * This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer. - * - * - * @generated - */ - protected Viewer currentViewer; - - /** - * This listens to which ever viewer is active. - * - * - * @generated - */ - protected ISelectionChangedListener selectionChangedListener; - - /** - * This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor. - * - * - * @generated - */ - protected Collection selectionChangedListeners = new ArrayList(); - - /** - * This keeps track of the selection of the editor as a whole. - * - * - * @generated - */ - protected ISelection editorSelection = StructuredSelection.EMPTY; - - /** - * The MarkerHelper is responsible for creating workspace resource markers presented - * in Eclipse's Problems View. - * - * - * @generated - */ - protected MarkerHelper markerHelper = new EditUIMarkerHelper(); - - /** - * This listens for when the outline becomes active - * - * - * @generated - */ - protected IPartListener partListener = - new IPartListener() { - public void partActivated(IWorkbenchPart p) { - if (p instanceof ContentOutline) { - if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) { - getActionBarContributor().setActiveEditor(ModelingBotEditor.this); - - setCurrentViewer(contentOutlineViewer); - } - } - else if (p instanceof PropertySheet) { - if (((PropertySheet)p).getCurrentPage() == propertySheetPage) { - getActionBarContributor().setActiveEditor(ModelingBotEditor.this); - handleActivate(); - } - } - else if (p == ModelingBotEditor.this) { - handleActivate(); - } - } - public void partBroughtToTop(IWorkbenchPart p) { - // Ignore. - } - public void partClosed(IWorkbenchPart p) { - // Ignore. - } - public void partDeactivated(IWorkbenchPart p) { - // Ignore. - } - public void partOpened(IWorkbenchPart p) { - // Ignore. - } - }; - - /** - * Resources that have been removed since last activation. - * - * - * @generated - */ - protected Collection removedResources = new ArrayList(); - - /** - * Resources that have been changed since last activation. - * - * - * @generated - */ - protected Collection changedResources = new ArrayList(); - - /** - * Resources that have been saved. - * - * - * @generated - */ - protected Collection savedResources = new ArrayList(); - - /** - * Map to store the diagnostic associated with a resource. - * - * - * @generated - */ - protected Map resourceToDiagnosticMap = new LinkedHashMap(); - - /** - * Controls whether the problem indication should be updated. - * - * - * @generated - */ - protected boolean updateProblemIndication = true; - - /** - * Adapter used to update the problem indication when resources are demanded loaded. - * - * - * @generated - */ - protected EContentAdapter problemIndicationAdapter = - new EContentAdapter() { - @Override - public void notifyChanged(Notification notification) { - if (notification.getNotifier() instanceof Resource) { - switch (notification.getFeatureID(Resource.class)) { - case Resource.RESOURCE__IS_LOADED: - case Resource.RESOURCE__ERRORS: - case Resource.RESOURCE__WARNINGS: { - Resource resource = (Resource)notification.getNotifier(); - Diagnostic diagnostic = analyzeResourceProblems(resource, null); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, diagnostic); - } - else { - resourceToDiagnosticMap.remove(resource); - } - - if (updateProblemIndication) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - break; - } - } - } - else { - super.notifyChanged(notification); - } - } - - @Override - protected void setTarget(Resource target) { - basicSetTarget(target); - } - - @Override - protected void unsetTarget(Resource target) { - basicUnsetTarget(target); - } - }; - - /** - * This listens for workspace changes. - * - * - * @generated - */ - protected IResourceChangeListener resourceChangeListener = - new IResourceChangeListener() { - public void resourceChanged(IResourceChangeEvent event) { - IResourceDelta delta = event.getDelta(); - try { - class ResourceDeltaVisitor implements IResourceDeltaVisitor { - protected ResourceSet resourceSet = editingDomain.getResourceSet(); - protected Collection changedResources = new ArrayList(); - protected Collection removedResources = new ArrayList(); - - public boolean visit(IResourceDelta delta) { - if (delta.getResource().getType() == IResource.FILE) { - if (delta.getKind() == IResourceDelta.REMOVED || - delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) { - Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false); - if (resource != null) { - if (delta.getKind() == IResourceDelta.REMOVED) { - removedResources.add(resource); - } - else if (!savedResources.remove(resource)) { - changedResources.add(resource); - } - } - } - } - - return true; - } - - public Collection getChangedResources() { - return changedResources; - } - - public Collection getRemovedResources() { - return removedResources; - } - } - - final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor(); - delta.accept(visitor); - - if (!visitor.getRemovedResources().isEmpty()) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - removedResources.addAll(visitor.getRemovedResources()); - if (!isDirty()) { - getSite().getPage().closeEditor(ModelingBotEditor.this, false); - } - } - }); - } - - if (!visitor.getChangedResources().isEmpty()) { - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - changedResources.addAll(visitor.getChangedResources()); - if (getSite().getPage().getActiveEditor() == ModelingBotEditor.this) { - handleActivate(); - } - } - }); - } - } - catch (CoreException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - }; - - /** - * Handles activation of the editor or it's associated views. - * - * - * @generated - */ - protected void handleActivate() { - // Recompute the read only state. - // - if (editingDomain.getResourceToReadOnlyMap() != null) { - editingDomain.getResourceToReadOnlyMap().clear(); - - // Refresh any actions that may become enabled or disabled. - // - setSelection(getSelection()); - } - - if (!removedResources.isEmpty()) { - if (handleDirtyConflict()) { - getSite().getPage().closeEditor(ModelingBotEditor.this, false); - } - else { - removedResources.clear(); - changedResources.clear(); - savedResources.clear(); - } - } - else if (!changedResources.isEmpty()) { - changedResources.removeAll(savedResources); - handleChangedResources(); - changedResources.clear(); - savedResources.clear(); - } - } - - /** - * Handles what to do with changed resources on activation. - * - * - * @generated - */ - protected void handleChangedResources() { - if (!changedResources.isEmpty() && (!isDirty() || handleDirtyConflict())) { - if (isDirty()) { - changedResources.addAll(editingDomain.getResourceSet().getResources()); - } - editingDomain.getCommandStack().flush(); - - updateProblemIndication = false; - for (Resource resource : changedResources) { - if (resource.isLoaded()) { - resource.unload(); - try { - resource.load(Collections.EMPTY_MAP); - } - catch (IOException exception) { - if (!resourceToDiagnosticMap.containsKey(resource)) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - } - } - } - - if (AdapterFactoryEditingDomain.isStale(editorSelection)) { - setSelection(StructuredSelection.EMPTY); - } - - updateProblemIndication = true; - updateProblemIndication(); - } - } - - /** - * Updates the problems indication with the information described in the specified diagnostic. - * - * - * @generated - */ - protected void updateProblemIndication() { - if (updateProblemIndication) { - BasicDiagnostic diagnostic = - new BasicDiagnostic - (Diagnostic.OK, - "org.eclipse.emf.eef.modelingbot.editor", - 0, - null, - new Object [] { editingDomain.getResourceSet() }); - for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) { - if (childDiagnostic.getSeverity() != Diagnostic.OK) { - diagnostic.add(childDiagnostic); - } - } - - int lastEditorPage = getPageCount() - 1; - if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) { - ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic); - if (diagnostic.getSeverity() != Diagnostic.OK) { - setActivePage(lastEditorPage); - } - } - else if (diagnostic.getSeverity() != Diagnostic.OK) { - ProblemEditorPart problemEditorPart = new ProblemEditorPart(); - problemEditorPart.setDiagnostic(diagnostic); - problemEditorPart.setMarkerHelper(markerHelper); - try { - addPage(++lastEditorPage, problemEditorPart, getEditorInput()); - setPageText(lastEditorPage, problemEditorPart.getPartName()); - setActivePage(lastEditorPage); - showTabs(); - } - catch (PartInitException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - - if (markerHelper.hasMarkers(editingDomain.getResourceSet())) { - markerHelper.deleteMarkers(editingDomain.getResourceSet()); - if (diagnostic.getSeverity() != Diagnostic.OK) { - try { - markerHelper.createMarkers(diagnostic); - } - catch (CoreException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - } - } - } - - /** - * Shows a dialog that asks if conflicting changes should be discarded. - * - * - * @generated - */ - protected boolean handleDirtyConflict() { - return - MessageDialog.openQuestion - (getSite().getShell(), - getString("_UI_FileConflict_label"), - getString("_WARN_FileConflict")); - } - - /** - * This creates a model editor. - * - * - * @generated - */ - public ModelingBotEditor() { - super(); - initializeEditingDomain(); - } - - /** - * This sets up the editing domain for the model editor. - * - * - * @generated - */ - protected void initializeEditingDomain() { - // Create an adapter factory that yields item providers. - // - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - - adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ModelingBotItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EEFActionsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EclipseActionsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ComponentsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new EditorItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new QueryItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new GenModelItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new MappingItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new NavigationItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new FiltersItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ViewsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ToolkitsItemProviderAdapterFactory()); - adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory()); - - // Create the command stack that will notify this editor as commands are executed. - // - BasicCommandStack commandStack = new BasicCommandStack(); - - // Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus. - // - commandStack.addCommandStackListener - (new CommandStackListener() { - public void commandStackChanged(final EventObject event) { - getContainer().getDisplay().asyncExec - (new Runnable() { - public void run() { - firePropertyChange(IEditorPart.PROP_DIRTY); - - // Try to select the affected objects. - // - Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand(); - if (mostRecentCommand != null) { - setSelectionToViewer(mostRecentCommand.getAffectedObjects()); - } - if (propertySheetPage != null && !propertySheetPage.getControl().isDisposed()) { - propertySheetPage.refresh(); - } - } - }); - } - }); - - // Create the editing domain with a special command stack. - // - editingDomain = new AdapterFactoryEditingDomain(adapterFactory, commandStack, new HashMap()); - } - - /** - * This is here for the listener to be able to call it. - * - * - * @generated - */ - @Override - protected void firePropertyChange(int action) { - super.firePropertyChange(action); - } - - /** - * This sets the selection into whichever viewer is active. - * - * - * @generated - */ - public void setSelectionToViewer(Collection collection) { - final Collection theSelection = collection; - // Make sure it's okay. - // - if (theSelection != null && !theSelection.isEmpty()) { - Runnable runnable = - new Runnable() { - public void run() { - // Try to select the items in the current content viewer of the editor. - // - if (currentViewer != null) { - currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true); - } - } - }; - getSite().getShell().getDisplay().asyncExec(runnable); - } - } - - /** - * This returns the editing domain as required by the {@link IEditingDomainProvider} interface. - * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} - * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}. - * - * - * @generated - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * - * - * @generated - */ - public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider { - /** - * - * - * @generated - */ - public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * - * - * @generated - */ - @Override - public Object [] getElements(Object object) { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ - @Override - public Object [] getChildren(Object object) { - Object parent = super.getParent(object); - return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); - } - - /** - * - * - * @generated - */ - @Override - public boolean hasChildren(Object object) { - Object parent = super.getParent(object); - return parent != null; - } - - /** - * - * - * @generated - */ - @Override - public Object getParent(Object object) { - return null; - } - } - - /** - * - * - * @generated - */ - public void setCurrentViewerPane(ViewerPane viewerPane) { - if (currentViewerPane != viewerPane) { - if (currentViewerPane != null) { - currentViewerPane.showFocus(false); - } - currentViewerPane = viewerPane; - } - setCurrentViewer(currentViewerPane.getViewer()); - } - - /** - * This makes sure that one content viewer, either for the current page or the outline view, if it has focus, - * is the current one. - * - * - * @generated - */ - public void setCurrentViewer(Viewer viewer) { - // If it is changing... - // - if (currentViewer != viewer) { - if (selectionChangedListener == null) { - // Create the listener on demand. - // - selectionChangedListener = - new ISelectionChangedListener() { - // This just notifies those things that are affected by the section. - // - public void selectionChanged(SelectionChangedEvent selectionChangedEvent) { - setSelection(selectionChangedEvent.getSelection()); - } - }; - } - - // Stop listening to the old one. - // - if (currentViewer != null) { - currentViewer.removeSelectionChangedListener(selectionChangedListener); - } - - // Start listening to the new one. - // - if (viewer != null) { - viewer.addSelectionChangedListener(selectionChangedListener); - } - - // Remember it. - // - currentViewer = viewer; - - // Set the editors selection based on the current viewer's selection. - // - setSelection(currentViewer == null ? StructuredSelection.EMPTY : currentViewer.getSelection()); - } - } - - /** - * This returns the viewer as required by the {@link IViewerProvider} interface. - * - * - * @generated - */ - public Viewer getViewer() { - return currentViewer; - } - - /** - * This creates a context menu for the viewer and adds a listener as well registering the menu for extension. - * - * - * @generated - */ - protected void createContextMenuFor(StructuredViewer viewer) { - MenuManager contextMenu = new MenuManager("#PopUp"); - contextMenu.add(new Separator("additions")); - contextMenu.setRemoveAllWhenShown(true); - contextMenu.addMenuListener(this); - Menu menu= contextMenu.createContextMenu(viewer.getControl()); - viewer.getControl().setMenu(menu); - getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer)); - - int dndOperations = DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK; - Transfer[] transfers = new Transfer[] { LocalTransfer.getInstance() }; - viewer.addDragSupport(dndOperations, transfers, new ViewerDragAdapter(viewer)); - viewer.addDropSupport(dndOperations, transfers, new EditingDomainViewerDropAdapter(editingDomain, viewer)); - } - - /** - * This is the method called to load a resource into the editing domain's resource set based on the editor's input. - * - * - * @generated - */ - public void createModel() { - URI resourceURI = EditUIUtil.getURI(getEditorInput()); - Exception exception = null; - Resource resource = null; - try { - // Load the resource through the editing domain. - // - resource = editingDomain.getResourceSet().getResource(resourceURI, true); - } - catch (Exception e) { - exception = e; - resource = editingDomain.getResourceSet().getResource(resourceURI, false); - } - - Diagnostic diagnostic = analyzeResourceProblems(resource, exception); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter); - } - - /** - * Returns a diagnostic describing the errors and warnings listed in the resource - * and the specified exception (if any). - * - * - * @generated - */ - public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) { - if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) { - BasicDiagnostic basicDiagnostic = - new BasicDiagnostic - (Diagnostic.ERROR, - "org.eclipse.emf.eef.modelingbot.editor", - 0, - getString("_UI_CreateModelError_message", resource.getURI()), - new Object [] { exception == null ? (Object)resource : exception }); - basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true)); - return basicDiagnostic; - } - else if (exception != null) { - return - new BasicDiagnostic - (Diagnostic.ERROR, - "org.eclipse.emf.eef.modelingbot.editor", - 0, - getString("_UI_CreateModelError_message", resource.getURI()), - new Object[] { exception }); - } - else { - return Diagnostic.OK_INSTANCE; - } - } - - /** - * This is the method used by the framework to install your own controls. - * - * - * @generated - */ - @Override - public void createPages() { - // Creates the model from the editor input - // - createModel(); - - // Only creates the other pages if there is something that can be edited - // - if (!getEditingDomain().getResourceSet().getResources().isEmpty()) { - // Create a page for the selection tree view. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), ModelingBotEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - Tree tree = new Tree(composite, SWT.MULTI); - TreeViewer newTreeViewer = new TreeViewer(tree); - return newTreeViewer; - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - selectionViewer = (TreeViewer)viewerPane.getViewer(); - selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - - selectionViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - selectionViewer.setInput(editingDomain.getResourceSet()); - selectionViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - viewerPane.setTitle(editingDomain.getResourceSet()); - - new AdapterFactoryTreeEditor(selectionViewer.getTree(), adapterFactory); - - createContextMenuFor(selectionViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_SelectionPage_label")); - } - - // Create a page for the parent tree view. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), ModelingBotEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - Tree tree = new Tree(composite, SWT.MULTI); - TreeViewer newTreeViewer = new TreeViewer(tree); - return newTreeViewer; - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - parentViewer = (TreeViewer)viewerPane.getViewer(); - parentViewer.setAutoExpandLevel(30); - parentViewer.setContentProvider(new ReverseAdapterFactoryContentProvider(adapterFactory)); - parentViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(parentViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_ParentPage_label")); - } - - // This is the page for the list viewer - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), ModelingBotEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new ListViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - listViewer = (ListViewer)viewerPane.getViewer(); - listViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - listViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(listViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_ListPage_label")); - } - - // This is the page for the tree viewer - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), ModelingBotEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new TreeViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - treeViewer = (TreeViewer)viewerPane.getViewer(); - treeViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - treeViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - new AdapterFactoryTreeEditor(treeViewer.getTree(), adapterFactory); - - createContextMenuFor(treeViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TreePage_label")); - } - - // This is the page for the table viewer. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), ModelingBotEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new TableViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - tableViewer = (TableViewer)viewerPane.getViewer(); - - Table table = tableViewer.getTable(); - TableLayout layout = new TableLayout(); - table.setLayout(layout); - table.setHeaderVisible(true); - table.setLinesVisible(true); - - TableColumn objectColumn = new TableColumn(table, SWT.NONE); - layout.addColumnData(new ColumnWeightData(3, 100, true)); - objectColumn.setText(getString("_UI_ObjectColumn_label")); - objectColumn.setResizable(true); - - TableColumn selfColumn = new TableColumn(table, SWT.NONE); - layout.addColumnData(new ColumnWeightData(2, 100, true)); - selfColumn.setText(getString("_UI_SelfColumn_label")); - selfColumn.setResizable(true); - - tableViewer.setColumnProperties(new String [] {"a", "b"}); - tableViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(tableViewer); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TablePage_label")); - } - - // This is the page for the table tree viewer. - // - { - ViewerPane viewerPane = - new ViewerPane(getSite().getPage(), ModelingBotEditor.this) { - @Override - public Viewer createViewer(Composite composite) { - return new TreeViewer(composite); - } - @Override - public void requestActivation() { - super.requestActivation(); - setCurrentViewerPane(this); - } - }; - viewerPane.createControl(getContainer()); - - treeViewerWithColumns = (TreeViewer)viewerPane.getViewer(); - - Tree tree = treeViewerWithColumns.getTree(); - tree.setLayoutData(new FillLayout()); - tree.setHeaderVisible(true); - tree.setLinesVisible(true); - - TreeColumn objectColumn = new TreeColumn(tree, SWT.NONE); - objectColumn.setText(getString("_UI_ObjectColumn_label")); - objectColumn.setResizable(true); - objectColumn.setWidth(250); - - TreeColumn selfColumn = new TreeColumn(tree, SWT.NONE); - selfColumn.setText(getString("_UI_SelfColumn_label")); - selfColumn.setResizable(true); - selfColumn.setWidth(200); - - treeViewerWithColumns.setColumnProperties(new String [] {"a", "b"}); - treeViewerWithColumns.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - treeViewerWithColumns.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - - createContextMenuFor(treeViewerWithColumns); - int pageIndex = addPage(viewerPane.getControl()); - setPageText(pageIndex, getString("_UI_TreeWithColumnsPage_label")); - } - - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - setActivePage(0); - } - }); - } - - // Ensures that this editor will only display the page's tab - // area if there are more than one page - // - getContainer().addControlListener - (new ControlAdapter() { - boolean guard = false; - @Override - public void controlResized(ControlEvent event) { - if (!guard) { - guard = true; - hideTabs(); - guard = false; - } - } - }); - - getSite().getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - - /** - * If there is just one page in the multi-page editor part, - * this hides the single tab at the bottom. - * - * - * @generated - */ - protected void hideTabs() { - if (getPageCount() <= 1) { - setPageText(0, ""); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(1); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y + 6); - } - } - } - - /** - * If there is more than one page in the multi-page editor part, - * this shows the tabs at the bottom. - * - * - * @generated - */ - protected void showTabs() { - if (getPageCount() > 1) { - setPageText(0, getString("_UI_SelectionPage_label")); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y - 6); - } - } - } - - /** - * This is used to track the active viewer. - * - * - * @generated - */ - @Override - protected void pageChange(int pageIndex) { - super.pageChange(pageIndex); - - if (contentOutlinePage != null) { - handleContentOutlineSelection(contentOutlinePage.getSelection()); - } - } - - /** - * This is how the framework determines which interfaces we implement. - * - * - * @generated - */ - @SuppressWarnings("rawtypes") - @Override - public Object getAdapter(Class key) { - if (key.equals(IContentOutlinePage.class)) { - return showOutlineView() ? getContentOutlinePage() : null; - } - else if (key.equals(IPropertySheetPage.class)) { - return getPropertySheetPage(); - } - else if (key.equals(IGotoMarker.class)) { - return this; - } - else { - return super.getAdapter(key); - } - } - - /** - * This accesses a cached version of the content outliner. - * - * - * @generated - */ - public IContentOutlinePage getContentOutlinePage() { - if (contentOutlinePage == null) { - // The content outline is just a tree. - // - class MyContentOutlinePage extends ContentOutlinePage { - @Override - public void createControl(Composite parent) { - super.createControl(parent); - contentOutlineViewer = getTreeViewer(); - contentOutlineViewer.addSelectionChangedListener(this); - - // Set up the tree viewer. - // - contentOutlineViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - contentOutlineViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - contentOutlineViewer.setInput(editingDomain.getResourceSet()); - - // Make sure our popups work. - // - createContextMenuFor(contentOutlineViewer); - - if (!editingDomain.getResourceSet().getResources().isEmpty()) { - // Select the root object in the view. - // - contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); - } - } - - @Override - public void makeContributions(IMenuManager menuManager, IToolBarManager toolBarManager, IStatusLineManager statusLineManager) { - super.makeContributions(menuManager, toolBarManager, statusLineManager); - contentOutlineStatusLineManager = statusLineManager; - } - - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - } - - contentOutlinePage = new MyContentOutlinePage(); - - // Listen to selection so that we can handle it is a special way. - // - contentOutlinePage.addSelectionChangedListener - (new ISelectionChangedListener() { - // This ensures that we handle selections correctly. - // - public void selectionChanged(SelectionChangedEvent event) { - handleContentOutlineSelection(event.getSelection()); - } - }); - } - - return contentOutlinePage; - } - - /** - * This accesses a cached version of the property sheet. - * - * - * @generated - */ - public IPropertySheetPage getPropertySheetPage() { - if (propertySheetPage == null) { - propertySheetPage = - new ExtendedPropertySheetPage(editingDomain) { - @Override - public void setSelectionToViewer(List selection) { - ModelingBotEditor.this.setSelectionToViewer(selection); - ModelingBotEditor.this.setFocus(); - } - - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - }; - propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory)); - } - - return propertySheetPage; - } - - /** - * This deals with how we want selection in the outliner to affect the other views. - * - * - * @generated - */ - public void handleContentOutlineSelection(ISelection selection) { - if (currentViewerPane != null && !selection.isEmpty() && selection instanceof IStructuredSelection) { - Iterator selectedElements = ((IStructuredSelection)selection).iterator(); - if (selectedElements.hasNext()) { - // Get the first selected element. - // - Object selectedElement = selectedElements.next(); - - // If it's the selection viewer, then we want it to select the same selection as this selection. - // - if (currentViewerPane.getViewer() == selectionViewer) { - ArrayList selectionList = new ArrayList(); - selectionList.add(selectedElement); - while (selectedElements.hasNext()) { - selectionList.add(selectedElements.next()); - } - - // Set the selection to the widget. - // - selectionViewer.setSelection(new StructuredSelection(selectionList)); - } - else { - // Set the input to the widget. - // - if (currentViewerPane.getViewer().getInput() != selectedElement) { - currentViewerPane.getViewer().setInput(selectedElement); - currentViewerPane.setTitle(selectedElement); - } - } - } - } - } - - /** - * This is for implementing {@link IEditorPart} and simply tests the command stack. - * - * - * @generated - */ - @Override - public boolean isDirty() { - return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded(); - } - - /** - * This is for implementing {@link IEditorPart} and simply saves the model file. - * - * - * @generated - */ - @Override - public void doSave(IProgressMonitor progressMonitor) { - // Save only resources that have actually changed. - // - final Map saveOptions = new HashMap(); - saveOptions.put(Resource.OPTION_SAVE_ONLY_IF_CHANGED, Resource.OPTION_SAVE_ONLY_IF_CHANGED_MEMORY_BUFFER); - - // Do the work within an operation because this is a long running activity that modifies the workbench. - // - WorkspaceModifyOperation operation = - new WorkspaceModifyOperation() { - // This is the method that gets invoked when the operation runs. - // - @Override - public void execute(IProgressMonitor monitor) { - // Save the resources to the file system. - // - boolean first = true; - for (Resource resource : editingDomain.getResourceSet().getResources()) { - if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) { - try { - long timeStamp = resource.getTimeStamp(); - resource.save(saveOptions); - if (resource.getTimeStamp() != timeStamp) { - savedResources.add(resource); - } - } - catch (Exception exception) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - first = false; - } - } - } - }; - - updateProblemIndication = false; - try { - // This runs the options, and shows progress. - // - new ProgressMonitorDialog(getSite().getShell()).run(true, false, operation); - - // Refresh the necessary state. - // - ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone(); - firePropertyChange(IEditorPart.PROP_DIRTY); - } - catch (Exception exception) { - // Something went wrong that shouldn't. - // - MbotEditorPlugin.INSTANCE.log(exception); - } - updateProblemIndication = true; - updateProblemIndication(); - } - - /** - * This returns whether something has been persisted to the URI of the specified resource. - * The implementation uses the URI converter from the editor's resource set to try to open an input stream. - * - * - * @generated - */ - protected boolean isPersisted(Resource resource) { - boolean result = false; - try { - InputStream stream = editingDomain.getResourceSet().getURIConverter().createInputStream(resource.getURI()); - if (stream != null) { - result = true; - stream.close(); - } - } - catch (IOException e) { - // Ignore - } - return result; - } - - /** - * This always returns true because it is not currently supported. - * - * - * @generated - */ - @Override - public boolean isSaveAsAllowed() { - return true; - } - - /** - * This also changes the editor's input. - * - * - * @generated - */ - @Override - public void doSaveAs() { - SaveAsDialog saveAsDialog = new SaveAsDialog(getSite().getShell()); - saveAsDialog.open(); - IPath path = saveAsDialog.getResult(); - if (path != null) { - IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path); - if (file != null) { - doSaveAs(URI.createPlatformResourceURI(file.getFullPath().toString(), true), new FileEditorInput(file)); - } - } - } - - /** - * - * - * @generated - */ - protected void doSaveAs(URI uri, IEditorInput editorInput) { - (editingDomain.getResourceSet().getResources().get(0)).setURI(uri); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - IProgressMonitor progressMonitor = - getActionBars().getStatusLineManager() != null ? - getActionBars().getStatusLineManager().getProgressMonitor() : - new NullProgressMonitor(); - doSave(progressMonitor); - } - - /** - * - * - * @generated - */ - public void gotoMarker(IMarker marker) { - try { - if (marker.getType().equals(EValidator.MARKER)) { - String uriAttribute = marker.getAttribute(EValidator.URI_ATTRIBUTE, null); - if (uriAttribute != null) { - URI uri = URI.createURI(uriAttribute); - EObject eObject = editingDomain.getResourceSet().getEObject(uri, true); - if (eObject != null) { - setSelectionToViewer(Collections.singleton(editingDomain.getWrapper(eObject))); - } - } - } - } - catch (CoreException exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - } - - /** - * This is called during startup. - * - * - * @generated - */ - @Override - public void init(IEditorSite site, IEditorInput editorInput) { - setSite(site); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - site.setSelectionProvider(this); - site.getPage().addPartListener(partListener); - ResourcesPlugin.getWorkspace().addResourceChangeListener(resourceChangeListener, IResourceChangeEvent.POST_CHANGE); - } - - /** - * - * - * @generated - */ - @Override - public void setFocus() { - if (currentViewerPane != null) { - currentViewerPane.setFocus(); - } - else { - getControl(getActivePage()).setFocus(); - } - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void addSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.add(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - * - * - * @generated - */ - public void removeSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.remove(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection. - * - * - * @generated - */ - public ISelection getSelection() { - return editorSelection; - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to set this editor's overall selection. - * Calling this result will notify the listeners. - * - * - * @generated - */ - public void setSelection(ISelection selection) { - editorSelection = selection; - - for (ISelectionChangedListener listener : selectionChangedListeners) { - listener.selectionChanged(new SelectionChangedEvent(this, selection)); - } - setStatusLineManager(selection); - } - - /** - * - * - * @generated - */ - public void setStatusLineManager(ISelection selection) { - IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ? - contentOutlineStatusLineManager : getActionBars().getStatusLineManager(); - - if (statusLineManager != null) { - if (selection instanceof IStructuredSelection) { - Collection collection = ((IStructuredSelection)selection).toList(); - switch (collection.size()) { - case 0: { - statusLineManager.setMessage(getString("_UI_NoObjectSelected")); - break; - } - case 1: { - String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next()); - statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text)); - break; - } - default: { - statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size()))); - break; - } - } - } - else { - statusLineManager.setMessage(""); - } - } - } - - /** - * This looks up a string in the plugin's plugin.properties file. - * - * - * @generated - */ - private static String getString(String key) { - return MbotEditorPlugin.INSTANCE.getString(key); - } - - /** - * This looks up a string in plugin.properties, making a substitution. - * - * - * @generated - */ - private static String getString(String key, Object s1) { - return MbotEditorPlugin.INSTANCE.getString(key, new Object [] { s1 }); - } - - /** - * This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu. - * - * - * @generated - */ - public void menuAboutToShow(IMenuManager menuManager) { - ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager); - } - - /** - * - * - * @generated - */ - public EditingDomainActionBarContributor getActionBarContributor() { - return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor(); - } - - /** - * - * - * @generated - */ - public IActionBars getActionBars() { - return getActionBarContributor().getActionBars(); - } - - /** - * - * - * @generated - */ - public AdapterFactory getAdapterFactory() { - return adapterFactory; - } - - /** - * - * - * @generated - */ - @Override - public void dispose() { - updateProblemIndication = false; - - ResourcesPlugin.getWorkspace().removeResourceChangeListener(resourceChangeListener); - - getSite().getPage().removePartListener(partListener); - - adapterFactory.dispose(); - - if (getActionBarContributor().getActiveEditor() == this) { - getActionBarContributor().setActiveEditor(null); - } - - if (propertySheetPage != null) { - propertySheetPage.dispose(); - } - - if (contentOutlinePage != null) { - contentOutlinePage.dispose(); - } - - super.dispose(); - } - - /** - * Returns whether the outline view should be presented to the user. - * - * - * @generated - */ - protected boolean showOutlineView() { - return true; - } -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotModelWizard.java b/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotModelWizard.java deleted file mode 100644 index f874bf6c9..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot.editor/src-gen/org/eclipse/emf/eef/modelingBot/presentation/ModelingBotModelWizard.java +++ /dev/null @@ -1,635 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.presentation; - - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.MissingResourceException; -import java.util.StringTokenizer; - -import org.eclipse.emf.common.CommonPlugin; - -import org.eclipse.emf.common.util.URI; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; - -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; - -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.ecore.xmi.XMLResource; - -import org.eclipse.emf.edit.ui.provider.ExtendedImageRegistry; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.ResourcesPlugin; - -import org.eclipse.core.runtime.IProgressMonitor; - -import org.eclipse.jface.dialogs.MessageDialog; - -import org.eclipse.jface.viewers.IStructuredSelection; - -import org.eclipse.jface.wizard.Wizard; -import org.eclipse.jface.wizard.WizardPage; - -import org.eclipse.swt.SWT; - -import org.eclipse.swt.events.ModifyListener; -import org.eclipse.swt.events.ModifyEvent; - -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; - -import org.eclipse.swt.widgets.Combo; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Label; - -import org.eclipse.ui.INewWizard; -import org.eclipse.ui.IWorkbench; - -import org.eclipse.ui.actions.WorkspaceModifyOperation; - -import org.eclipse.ui.dialogs.WizardNewFileCreationPage; - -import org.eclipse.ui.part.FileEditorInput; -import org.eclipse.ui.part.ISetSelectionTarget; - -import org.eclipse.emf.eef.modelingBot.ModelingBotFactory; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.provider.MbotEditPlugin; - - -import org.eclipse.core.runtime.Path; - -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; - -import org.eclipse.ui.IWorkbenchPage; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.IWorkbenchWindow; -import org.eclipse.ui.PartInitException; - - -/** - * This is a simple wizard for creating a new model file. - * - * - * @generated - */ -public class ModelingBotModelWizard extends Wizard implements INewWizard { - /** - * The supported extensions for created files. - * - * - * @generated - */ - public static final List FILE_EXTENSIONS = - Collections.unmodifiableList(Arrays.asList(MbotEditorPlugin.INSTANCE.getString("_UI_ModelingBotEditorFilenameExtensions").split("\\s*,\\s*"))); - - /** - * A formatted list of supported file extensions, suitable for display. - * - * - * @generated - */ - public static final String FORMATTED_FILE_EXTENSIONS = - MbotEditorPlugin.INSTANCE.getString("_UI_ModelingBotEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", "); - - /** - * This caches an instance of the model package. - * - * - * @generated - */ - protected ModelingBotPackage modelingBotPackage = ModelingBotPackage.eINSTANCE; - - /** - * This caches an instance of the model factory. - * - * - * @generated - */ - protected ModelingBotFactory modelingBotFactory = modelingBotPackage.getModelingBotFactory(); - - /** - * This is the file creation page. - * - * - * @generated - */ - protected ModelingBotModelWizardNewFileCreationPage newFileCreationPage; - - /** - * This is the initial object creation page. - * - * - * @generated - */ - protected ModelingBotModelWizardInitialObjectCreationPage initialObjectCreationPage; - - /** - * Remember the selection during initialization for populating the default container. - * - * - * @generated - */ - protected IStructuredSelection selection; - - /** - * Remember the workbench during initialization. - * - * - * @generated - */ - protected IWorkbench workbench; - - /** - * Caches the names of the types that can be created as the root object. - * - * - * @generated - */ - protected List initialObjectNames; - - /** - * This just records the information. - * - * - * @generated - */ - public void init(IWorkbench workbench, IStructuredSelection selection) { - this.workbench = workbench; - this.selection = selection; - setWindowTitle(MbotEditorPlugin.INSTANCE.getString("_UI_Wizard_label")); - setDefaultPageImageDescriptor(ExtendedImageRegistry.INSTANCE.getImageDescriptor(MbotEditorPlugin.INSTANCE.getImage("full/wizban/NewModelingBot"))); - } - - /** - * Returns the names of the types that can be created as the root object. - * - * - * @generated - */ - protected Collection getInitialObjectNames() { - if (initialObjectNames == null) { - initialObjectNames = new ArrayList(); - for (EClassifier eClassifier : modelingBotPackage.getEClassifiers()) { - if (eClassifier instanceof EClass) { - EClass eClass = (EClass)eClassifier; - if (!eClass.isAbstract()) { - initialObjectNames.add(eClass.getName()); - } - } - } - Collections.sort(initialObjectNames, CommonPlugin.INSTANCE.getComparator()); - } - return initialObjectNames; - } - - /** - * Create a new model. - * - * - * @generated - */ - protected EObject createInitialModel() { - EClass eClass = (EClass)modelingBotPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName()); - EObject rootObject = modelingBotFactory.create(eClass); - return rootObject; - } - - /** - * Do the work after everything is specified. - * - * - * @generated - */ - @Override - public boolean performFinish() { - try { - // Remember the file. - // - final IFile modelFile = getModelFile(); - - // Do the work within an operation. - // - WorkspaceModifyOperation operation = - new WorkspaceModifyOperation() { - @Override - protected void execute(IProgressMonitor progressMonitor) { - try { - // Create a resource set - // - ResourceSet resourceSet = new ResourceSetImpl(); - - // Get the URI of the model file. - // - URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true); - - // Create a resource for this file. - // - Resource resource = resourceSet.createResource(fileURI); - - // Add the initial model object to the contents. - // - EObject rootObject = createInitialModel(); - if (rootObject != null) { - resource.getContents().add(rootObject); - } - - // Save the contents of the resource to the file system. - // - Map options = new HashMap(); - options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding()); - resource.save(options); - } - catch (Exception exception) { - MbotEditorPlugin.INSTANCE.log(exception); - } - finally { - progressMonitor.done(); - } - } - }; - - getContainer().run(false, false, operation); - - // Select the new file resource in the current view. - // - IWorkbenchWindow workbenchWindow = workbench.getActiveWorkbenchWindow(); - IWorkbenchPage page = workbenchWindow.getActivePage(); - final IWorkbenchPart activePart = page.getActivePart(); - if (activePart instanceof ISetSelectionTarget) { - final ISelection targetSelection = new StructuredSelection(modelFile); - getShell().getDisplay().asyncExec - (new Runnable() { - public void run() { - ((ISetSelectionTarget)activePart).selectReveal(targetSelection); - } - }); - } - - // Open an editor on the new file. - // - try { - page.openEditor - (new FileEditorInput(modelFile), - workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId()); - } - catch (PartInitException exception) { - MessageDialog.openError(workbenchWindow.getShell(), MbotEditorPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage()); - return false; - } - - return true; - } - catch (Exception exception) { - MbotEditorPlugin.INSTANCE.log(exception); - return false; - } - } - - /** - * This is the one page of the wizard. - * - * - * @generated - */ - public class ModelingBotModelWizardNewFileCreationPage extends WizardNewFileCreationPage { - /** - * Pass in the selection. - * - * - * @generated - */ - public ModelingBotModelWizardNewFileCreationPage(String pageId, IStructuredSelection selection) { - super(pageId, selection); - } - - /** - * The framework calls this to see if the file is correct. - * - * - * @generated - */ - @Override - protected boolean validatePage() { - if (super.validatePage()) { - String extension = new Path(getFileName()).getFileExtension(); - if (extension == null || !FILE_EXTENSIONS.contains(extension)) { - String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension"; - setErrorMessage(MbotEditorPlugin.INSTANCE.getString(key, new Object [] { FORMATTED_FILE_EXTENSIONS })); - return false; - } - return true; - } - return false; - } - - /** - * - * - * @generated - */ - public IFile getModelFile() { - return ResourcesPlugin.getWorkspace().getRoot().getFile(getContainerFullPath().append(getFileName())); - } - } - - /** - * This is the page where the type of object to create is selected. - * - * - * @generated - */ - public class ModelingBotModelWizardInitialObjectCreationPage extends WizardPage { - /** - * - * - * @generated - */ - protected Combo initialObjectField; - - /** - * @generated - * - * - */ - protected List encodings; - - /** - * - * - * @generated - */ - protected Combo encodingField; - - /** - * Pass in the selection. - * - * - * @generated - */ - public ModelingBotModelWizardInitialObjectCreationPage(String pageId) { - super(pageId); - } - - /** - * - * - * @generated - */ - public void createControl(Composite parent) { - Composite composite = new Composite(parent, SWT.NONE); { - GridLayout layout = new GridLayout(); - layout.numColumns = 1; - layout.verticalSpacing = 12; - composite.setLayout(layout); - - GridData data = new GridData(); - data.verticalAlignment = GridData.FILL; - data.grabExcessVerticalSpace = true; - data.horizontalAlignment = GridData.FILL; - composite.setLayoutData(data); - } - - Label containerLabel = new Label(composite, SWT.LEFT); - { - containerLabel.setText(MbotEditorPlugin.INSTANCE.getString("_UI_ModelObject")); - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - containerLabel.setLayoutData(data); - } - - initialObjectField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - initialObjectField.setLayoutData(data); - } - - for (String objectName : getInitialObjectNames()) { - initialObjectField.add(getLabel(objectName)); - } - - if (initialObjectField.getItemCount() == 1) { - initialObjectField.select(0); - } - initialObjectField.addModifyListener(validator); - - Label encodingLabel = new Label(composite, SWT.LEFT); - { - encodingLabel.setText(MbotEditorPlugin.INSTANCE.getString("_UI_XMLEncoding")); - - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - encodingLabel.setLayoutData(data); - } - encodingField = new Combo(composite, SWT.BORDER); - { - GridData data = new GridData(); - data.horizontalAlignment = GridData.FILL; - data.grabExcessHorizontalSpace = true; - encodingField.setLayoutData(data); - } - - for (String encoding : getEncodings()) { - encodingField.add(encoding); - } - - encodingField.select(0); - encodingField.addModifyListener(validator); - - setPageComplete(validatePage()); - setControl(composite); - } - - /** - * - * - * @generated - */ - protected ModifyListener validator = - new ModifyListener() { - public void modifyText(ModifyEvent e) { - setPageComplete(validatePage()); - } - }; - - /** - * - * - * @generated - */ - protected boolean validatePage() { - return getInitialObjectName() != null && getEncodings().contains(encodingField.getText()); - } - - /** - * - * - * @generated - */ - @Override - public void setVisible(boolean visible) { - super.setVisible(visible); - if (visible) { - if (initialObjectField.getItemCount() == 1) { - initialObjectField.clearSelection(); - encodingField.setFocus(); - } - else { - encodingField.clearSelection(); - initialObjectField.setFocus(); - } - } - } - - /** - * - * - * @generated - */ - public String getInitialObjectName() { - String label = initialObjectField.getText(); - - for (String name : getInitialObjectNames()) { - if (getLabel(name).equals(label)) { - return name; - } - } - return null; - } - - /** - * - * - * @generated - */ - public String getEncoding() { - return encodingField.getText(); - } - - /** - * Returns the label for the specified type name. - * - * - * @generated - */ - protected String getLabel(String typeName) { - try { - return MbotEditPlugin.INSTANCE.getString("_UI_" + typeName + "_type"); - } - catch(MissingResourceException mre) { - MbotEditorPlugin.INSTANCE.log(mre); - } - return typeName; - } - - /** - * - * - * @generated - */ - protected Collection getEncodings() { - if (encodings == null) { - encodings = new ArrayList(); - for (StringTokenizer stringTokenizer = new StringTokenizer(MbotEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens(); ) { - encodings.add(stringTokenizer.nextToken()); - } - } - return encodings; - } - } - - /** - * The framework calls this to create the contents of the wizard. - * - * - * @generated - */ - @Override - public void addPages() { - // Create a page, set the title, and the initial model file name. - // - newFileCreationPage = new ModelingBotModelWizardNewFileCreationPage("Whatever", selection); - newFileCreationPage.setTitle(MbotEditorPlugin.INSTANCE.getString("_UI_ModelingBotModelWizard_label")); - newFileCreationPage.setDescription(MbotEditorPlugin.INSTANCE.getString("_UI_ModelingBotModelWizard_description")); - newFileCreationPage.setFileName(MbotEditorPlugin.INSTANCE.getString("_UI_ModelingBotEditorFilenameDefaultBase") + "." + FILE_EXTENSIONS.get(0)); - addPage(newFileCreationPage); - - // Try and get the resource selection to determine a current directory for the file dialog. - // - if (selection != null && !selection.isEmpty()) { - // Get the resource... - // - Object selectedElement = selection.iterator().next(); - if (selectedElement instanceof IResource) { - // Get the resource parent, if its a file. - // - IResource selectedResource = (IResource)selectedElement; - if (selectedResource.getType() == IResource.FILE) { - selectedResource = selectedResource.getParent(); - } - - // This gives us a directory... - // - if (selectedResource instanceof IFolder || selectedResource instanceof IProject) { - // Set this for the container. - // - newFileCreationPage.setContainerFullPath(selectedResource.getFullPath()); - - // Make up a unique new name here. - // - String defaultModelBaseFilename = MbotEditorPlugin.INSTANCE.getString("_UI_ModelingBotEditorFilenameDefaultBase"); - String defaultModelFilenameExtension = FILE_EXTENSIONS.get(0); - String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension; - for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) { - modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension; - } - newFileCreationPage.setFileName(modelFilename); - } - } - } - initialObjectCreationPage = new ModelingBotModelWizardInitialObjectCreationPage("Whatever2"); - initialObjectCreationPage.setTitle(MbotEditorPlugin.INSTANCE.getString("_UI_ModelingBotModelWizard_label")); - initialObjectCreationPage.setDescription(MbotEditorPlugin.INSTANCE.getString("_UI_Wizard_initial_object_description")); - addPage(initialObjectCreationPage); - } - - /** - * Get the file from the page. - * - * - * @generated - */ - public IFile getModelFile() { - return newFileCreationPage.getModelFile(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/.classpath b/plugins/org.eclipse.emf.eef.modelingbot/.classpath deleted file mode 100644 index 756f42890..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/.classpath +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot/.gitignore b/plugins/org.eclipse.emf.eef.modelingbot/.gitignore deleted file mode 100644 index 4058d0f36..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -bin -/target diff --git a/plugins/org.eclipse.emf.eef.modelingbot/.project b/plugins/org.eclipse.emf.eef.modelingbot/.project deleted file mode 100644 index e8ebe691e..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.modelingbot - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot/.settings/org.eclipse.core.resources.prefs b/plugins/org.eclipse.emf.eef.modelingbot/.settings/org.eclipse.core.resources.prefs deleted file mode 100644 index 8d33386d2..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/.settings/org.eclipse.core.resources.prefs +++ /dev/null @@ -1,3 +0,0 @@ -#Mon Apr 11 17:18:44 CEST 2011 -eclipse.preferences.version=1 -encoding//model/mbot.ecore=ISO-8859-1 diff --git a/plugins/org.eclipse.emf.eef.modelingbot/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.modelingbot/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index e845efbc7..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,8 +0,0 @@ -#Mon Apr 04 16:00:09 CEST 2011 -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.modelingbot/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.modelingbot/META-INF/MANIFEST.MF deleted file mode 100644 index 0ba7418b2..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/META-INF/MANIFEST.MF +++ /dev/null @@ -1,89 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: %pluginName -Bundle-SymbolicName: org.eclipse.emf.eef.modelingbot;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-ClassPath: . -Bundle-Vendor: %providerName -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Export-Package: org.eclipse.emf.eef.modelingBot; - uses:="org.eclipse.emf.eef.extended.editor, - org.eclipse.emf.ecore.resource, - org.eclipse.emf.ecore, - org.eclipse.emf.eef.components.parts, - org.eclipse.emf.edit.domain", - org.eclipse.emf.eef.modelingBot.EEFActions; - uses:="org.eclipse.emf.eef.extended.editor, - org.eclipse.emf.ecore, - org.eclipse.emf.eef.modelingBot, - org.eclipse.emf.eef.components", - org.eclipse.emf.eef.modelingBot.EEFActions.impl; - uses:="org.eclipse.emf.eef.extended.editor, - org.eclipse.emf.ecore, - org.eclipse.emf.eef.modelingBot.impl, - org.eclipse.emf.eef.components, - org.eclipse.emf.ecore.impl, - org.eclipse.emf.eef.modelingBot.EEFActions", - org.eclipse.emf.eef.modelingBot.EEFActions.util; - uses:="org.eclipse.emf.ecore, - org.eclipse.emf.common.notify.impl, - org.eclipse.emf.eef.modelingBot, - org.eclipse.emf.common.notify, - org.eclipse.emf.eef.modelingBot.EEFActions", - org.eclipse.emf.eef.modelingBot.EclipseActions;uses:="org.eclipse.emf.ecore,org.eclipse.emf.eef.modelingBot", - org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - uses:="org.eclipse.emf.ecore, - org.eclipse.emf.eef.modelingBot.impl, - org.eclipse.emf.eef.modelingBot.EclipseActions, - org.eclipse.emf.ecore.impl", - org.eclipse.emf.eef.modelingBot.EclipseActions.util; - uses:="org.eclipse.emf.ecore, - org.eclipse.emf.common.notify.impl, - org.eclipse.emf.eef.modelingBot, - org.eclipse.emf.eef.modelingBot.EclipseActions, - org.eclipse.emf.common.notify", - org.eclipse.emf.eef.modelingBot.batch, - org.eclipse.emf.eef.modelingBot.exception, - org.eclipse.emf.eef.modelingBot.helper;uses:="org.eclipse.emf.ecore.resource,org.eclipse.core.resources", - org.eclipse.emf.eef.modelingBot.impl; - uses:="org.eclipse.emf.ecore, - org.eclipse.emf.common.util, - org.eclipse.emf.eef.modelingBot, - org.eclipse.emf.eef.components, - org.eclipse.emf.ecore.impl, - org.eclipse.emf.common.notify", - org.eclipse.emf.eef.modelingBot.interpreter, - org.eclipse.emf.eef.modelingBot.menu, - org.eclipse.emf.eef.modelingBot.swtbot; - uses:="org.eclipse.emf.eef.extended.editor, - org.eclipse.emf.ecore, - org.eclipse.emf.eef.components.parts, - org.eclipse.emf.eef.modelingBot, - org.eclipse.swtbot.swt.finder.widgets, - org.eclipse.swtbot.swt.finder", - org.eclipse.emf.eef.modelingBot.testcase;uses:="org.eclipse.swtbot.eclipse.finder,org.eclipse.emf.eef.modelingBot.swtbot", - org.eclipse.emf.eef.modelingBot.uri, - org.eclipse.emf.eef.modelingBot.util; - uses:="org.eclipse.emf.ecore, - org.eclipse.emf.common.notify.impl, - org.eclipse.emf.eef.modelingBot, - org.eclipse.emf.common.notify" -Require-Bundle: org.eclipse.core.runtime, - org.eclipse.emf.ecore;visibility:=reexport, - org.eclipse.emf.eef.components;visibility:=reexport, - org.eclipse.emf.eef.editor.model;visibility:=reexport, - org.eclipse.emf.codegen.ecore;visibility:=reexport, - org.eclipse.emf.eef.mapping;visibility:=reexport, - org.eclipse.emf.eef.views;visibility:=reexport, - org.eclipse.swtbot.eclipse.finder;visibility:=reexport, - org.eclipse.swtbot.swt.finder;visibility:=reexport, - org.hamcrest, - org.junit4, - org.eclipse.core.resources, - org.apache.log4j, - org.eclipse.emf.ecore.xmi, - org.eclipse.emf.compare, - org.eclipse.emf.compare.diff, - org.eclipse.emf.compare.match -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.modelingbot/build.properties b/plugins/org.eclipse.emf.eef.modelingbot/build.properties deleted file mode 100644 index a26bb040c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/build.properties +++ /dev/null @@ -1,29 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2011 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### - -# -# -# -# $Id: build.properties,v 1.1 2011/04/06 13:07:28 nlepine Exp $ - -bin.includes = .,\ - model/,\ - META-INF/,\ - plugin.xml,\ - plugin.properties,\ - src/,\ - src-gen/,\ - build.properties -jars.compile.order = . -source.. = src-gen/,\ - src -output.. = bin/ -src.includes = model/ diff --git a/plugins/org.eclipse.emf.eef.modelingbot/model/mbot.ecore b/plugins/org.eclipse.emf.eef.modelingbot/model/mbot.ecore deleted file mode 100644 index d11ab3291..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/model/mbot.ecore +++ /dev/null @@ -1,120 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot/model/mbot.genmodel b/plugins/org.eclipse.emf.eef.modelingbot/model/mbot.genmodel deleted file mode 100755 index 915050dd9..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/model/mbot.genmodel +++ /dev/null @@ -1,132 +0,0 @@ - - - mbot.ecore - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot/modelingBot package entities.jpg b/plugins/org.eclipse.emf.eef.modelingbot/modelingBot package entities.jpg deleted file mode 100644 index 13ff8fb0d0489a68b9f5bd2a860421c956dab4fa..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 119351 zcmeFa1zc3y+CM(Dgdio&&>$(@3?VJj4We`-4HAPvNQZzZNK1os${-*e64Kq$ARROR z?YZy!yXyI!bMJlcx$pnp^AkRMX4cH!Yd>r4wVw6F_jwj#3^50~rX;5*2SP#ufslZI z5MmM}1G<8ab_Ius9E^^RfpwLNni2y8C{oc=Vqjw9k+ZXaF|i3L=>++haR?}BZtw|n zlF=};^NEY`GH~AH7UJRK`C17QCMFIk5AcVHeUJI+o(2X5hdc|7je8!SkoY3$WkzOJ_M4pCy!^8Aipr|$n%cVNmevn#?H!$6gG0lg zMn=cRC*~IxmzGyn*FLZB?SDBqJUTu(Jpja_0>mjSHn41Dv9dtWL4h48ueK_j_+b!%Ob5?4E0-P_{p3xPeXAPL|z}=2JRaj|SN)dl}dGk`VW4 z(G<$y+k=iQ>n~K5Jzdp_aVnI!#0}*>9uo4LDP+NWSVQ>ro%mt5Kh0yc*<{te;3>46 zk=oBmzDT%#0f}(w<2;uLuV_0NY9$ZMXm)cU>#41KV$HPPhwV+4AQoB1>Ku6(fzkTv z&1)IQn5hY&$k~<$$VA3{qiEQj&QAip@zUqaab7<>4`cJzC--_HLdaiW4qum-&I$0z z#P8r&T5UelY9X}Q3n0>OEsf2%q9fVTi68Sg5()KQWLuqXY60!(Lw_cY<5uj`>k6B0 zAsUASRxq99r)Agk8z!c%JTsjij*5Xy(7k%&d#mPop|g$P5Q}z2{qQGq3GIPO9Q`rb zYHJ4M+waRSgjOn+cjdy@hznQM1o2r_SiB_$jvLOiAGG&1_35p?(|^)JZm-%nf|=oa zWtu)gG7dG$ns*X?LMaV}QSmrq`rL3e_n|jD7?OR`x4@!y`P#5P?rJoL*yi;GKRG$0 zw-aL%Q?Wz|+d>7g7jpFzvW>wgQyIO^d4>&3j12~^0ls06@EN)k+P6n%i8C>tR^&F} z>)%wPzlAO@s?#RjfyC|=*xA11wNTEF03o$_a9fD!c=PZNH!0m!tuphBXLpqkSaKm1 zp_aINqr1Deg!4TZ!Ulh%)yO?^dvicFk1?YcE%WhPQjQ|d^rtbxD7{k#GLI$H+q`;B zKEWC8GH{MexIM_kTo`b=oy0S(hmHV6z0yd=7;E+I-$t|LdR!5G{&Hsi)eTX(A;mKN zq5_Z#JP#MQp{ zR!{m5iojbC0tD#eyEFu7&JF?E=PImKm2E+U39SR<8|fyVsCPKDJ+T{9!67X8K8 z@t2qcw`_`;f@FmW+Rnn4i0+R+>h;h90Tb`%@#pFTB%B1b((d-SsimW%HwciGAp+FT zHH-j7=w$@3eOvZjo;L~AP%SP^z=U^-Ud5u2NuHFBc*-cQeJYV;d#2OSa_ht?=Y6q} z3V8{>e7@oPNSgZL*V>kvJImY%&?6r;jLdJV1CNg&Kwr8KA&WXJX;=u*|0&8Jxx+5@ zFI7)Ig|Z;S{<|=6nc{>1iNQ4C{HCFxNH*)COAWKp*EMIu&($T-h<+Y_%06)QFxe-l zL4Zo^OfFd(ieqc*xlS>Spre%~@aK2cFcf8p)R2B2fBrr&nohiUS`68k09IKgF1D;< z$8NZ^F8FW@kOQ(wo+AzZ-om6yvEWDEwtqJ6?jSL^&Be6t{&*gRwX0k|K>DUwE>k`0 zio40_6+`IgyIJ^ieI4y84@xBjXt!950|Al_4hB9_L*PtNC%V+vfyG{?1yKI+zz7hb z@pYCD-n!79-bQ&*1PE)fdG>(C3kt~Ni-5EMsQ!V@^G;_(Vh{u`1n(htf@6MxK>}Qvv6Gyr~Xas*#a5y4$bpDqSv;M z$_T&U>X+SVdLlf*t#e#3*^zKA39#rNZomg^uGy`=#G(d>Yw`l9e3`R2X-J~bmz`(* zmbEs8!~M3mNT#>Fz!W-te4kXyy(9jB*BqZ163~X;4DspVJW#dBneNEvY8a)BMYATY zP6z-IFVNE@KhY#@jP(neO+1b)ffKg}!q(Jw5g<59I|9@?@T-Q~MKaH}Y!_tS$jcBOh=&JAf@07M6<1fgiHVCrySJs0Y=*U_ zm3k8#+9i(0dPxT2V{RxE`shBUuRIsd4})~V?uOjOl<0QNh9qRRjL_{ky;$tBYzo70 z#kk{IP2>Vwfv+*ud#4Cquti}*Kc>$kKo=NM2+*_49~(Z(<(EArM zpW8|xB_4LiU#A8?P3*yg(5$1J4S(8C?BN48UpQ(48Ai6u72@n4N*mtCCvk+hyQtdF zdoKi%T z=n*aA8_ODgDt`3ZyF}*Wa;+D=;IV*fmzLP5K>Ljct$u41D8ZBm)Wg{%BdTwKrY6CD z9O$JDDs$6VgF>^)yGJoLH)|@cO})orlZB~2rHW<2SkaI-*xoZ*jR-yyL4Za-{3~>R9;(emS@l>#BlQg(Cx#wtuj5EVW;>v45QU(ObQ{pg1J8fV{T@Sn)whlcI zKM96kPC)lLekgihG+K|WRHf(0y98PaX-2f$COh2oU&?RE-OibOnU{UyI5Y69+Bezz zmbWt(YScmypZGgxeUYG4j*KVy7q>rgTuWsY=0tlL9ETBTRYf^R9%QbNsatbW;75ex zVK`k|hADb)kLb-TM!-XIVX==!n=Hj-huFlR&b>%kO?X~U0%;t^3EucQISe<2JrEU4 z$ghw6#MwNTy?lz}#U<-7Oz}SF&r&D<&1r`TvIV>40^FG(IlDmUoaUm#^Xcd`F{`{IZ_Q5!Q zb${{B;Xj*}^S7jXqsUCq$e8%!Big(n`a5AaI^ zHT!yV0&rb}Y(#X*ZKKM>8CRma^Y6TopCmrmznULT`25yfO4@41mk+(RU4tyk(KcN} z&#hnT(Qz;ou_6WP4ae2nMy6nhVQKo+o2(*0xI(ALWe2cRLOg=8Ebh+yyW?YR>t(bx zF|KkpdLwr~h-j$T%xZrpYiLKi)MZ9(!V3GN z_lu2Q6-Z0O9S!PzY|NyH=9$lV-eT6Y!k9jc7HdzIjE9CKa4{*ys))4HzG{Ntc3sXpY-NUSP26kR1 zc@`TAEl)4by>!r%M=Q8#FHLqKB?<3=2jd}gcSt$^s;(-p(79}O^^5xAboxU4RfcPL zH2Au9k#Bbcw+cU|(9QHUPis3I$|@&;w;r@cJl$suOT94}{Dru5*erC@1_5fphEoFO zX>{UVTa$hKDnNzxfnBnc6(`iblZQ(S%pUG|0;h|hh{zJV{LGV_|rr(QGiEfyLrTon7Bw3NYdg#LPA?K>#LK3+!htcHSZt~lM zQ?I;IdRRtWaVpdbD6iAF6&oC3AGjwpcWsX_)e9c2AH{Y!%!#<(@IF}cczb@UcB5h+ z8`t@6?C8w`H17rdD_l4X;a#PROu%e2qnC&`uIv?7<6Td{#-A#kA|tU6y4JcGCv^Ey zhxzqQ*TKAp-cXYVkP~p~Y4X-ZwXVlrZ26P|CyjTKgGCtr2al&QHp1+vHp5Gy9V6_O zwVZbsM&)%C?h4tt)(MSyGp zeJo&b!ccf%=U_`u{?!2oaYf17DO-i^cXV3Zv9I5`M}@lCy=hA-u@O{_;`@Nw(JChzui-_s1!*-eT0l5`UAs*)_^#M2(qSIR4#Te zN5yyxmG*W7JO>*m4YT!TSTcqjz}|*=<=nlkkFsL0v%$1c;U`>g=cz0U8YJ z0)75H-x^!;Fl33|0Rg&u3_Vk~Fs5>S8GP~70k$y%3@at}eDf=xhGlmWpk=Z-sqHaG z;hX0z5|(}b+feeH>7JQM#&9v@T|-K@hQ0V%tqvw!*AQa;6utqSx2 zCcqo(L*DVY-H0&kncF=AMd}fE9amNxU98;4hG3R^w>l!BUe2)!8<9tgCPQ@L;v+>l zEskURj!W^>_t_ za6Ym&<~Tc}#)Ro53_Q>1C`C!1`C^21PBQTc`O3&UQ*8b@2d+eJl*XPct zugb#aa0c5eNskK00cKC5Dex{Uqh{7}iwDWAb_3=5YU=Hgr{(hGabl%y0c7U!A;^5{ zpT>^VWnmrS7-kdUKH5GJ8hym*+wegmVe9OeCIZ%UW;4PI7R)nXJ?dZBB48eO1)l7U zApD}N6cjcgQgpiU(??Xf%lp^}P*Pr$?aGB4WMCBD$PTEet7wk$`TAA;tnh*ArEv#m z_={`im#G*j1^r~j&^FJT-S%%Lys}LyCR&ZJ&?r(DT%n1XCcWl&RVYp56|@c}b&;)-CT@Iwh$iEfGouDFtnw9uc)`cp{DHd zXEVL*QLaqW$CF$8*I*VEqF>6%grDDYW7w0wxXD|Tk;Iox6d$U11+7&vyi3bXQen9< zqgJosz8~L%&a27SLx)nX!`qx|pL4V@nY|VS5woS%Exr}+M1ZayKS6+=oTWGrM?n{_ za*n7aR%^5~5l=tWAgb0M3p`gD%+vm&cTMnSuQXhApvlyc>k6(t`lNT%gri!OP6xY{ zcX)x7<)&G(8u}q|6iIkR5*b?MQe1g%ZAc5n+fWh)6nDBCSfr07OyA*UOTLB-kSQvU zcTjkg#BpxK*O(HGe<mT~+|_Xk49>y#`n#Fm|YgQJNM^xgrsIk(-qzB zo5{ehTRua8)c=bhB4~5Z0AyVlu&I-nT$rX;z9x$?7}SatK(=PQ8!NZ?7^bf2efN_z z-iiK8=1Y0VF7gHf6t0c{Ve{TXfO1#iAYGz5;dQ9VlXb5B+G3a9=(t|I!X9tYn?-uO3^@;hWnXucqJM(&1Zflxf4-W`& zrdUpelCg@bSjz8Rx6yvtE+3>ID4S!m`Q_TNXX0LK7h_l#t+vjcJ4a#<-UKdR+Bx-z z-{}ioDiU+{5qqs&{LJC#17}^b#+_RpF_SM&A1~cf_Rf%{@wS7Huoi*|IT?BUqM9e3 z@8-rAF-HLMg;GM-?fYZRB*(3k4zZf;G}OQdIZ8}}p0jVQ70ZhG(cZKiQr=%?5-tgB zIn^1=O0y50YvQH1+AjOhPu8m?AyN|vSuoD@%K_UCbIN|`w%|DEewWkXO0m?L9H0~+ z)W>poaQ?{qAyqGNhhQsaQv29}MZ$0gU!03YOXXC;IRfNr^Y$@_#=I*>9Gy+Kg__<^ znr_H&VzNd;t170WXT+g`sycVCO*>I6B4?OTvIK5D0SL3CKRTCw6qY`-y(&Y1qT|~y zeGGtEBD)N7d;UAzg1B!s>g2`bfBBnqWsPP-*xj{jf{Y3JnwPR%ZH6YNlsaR)cCQUI zI4d5D#fsp*v$-k2kN;IkO#P}Pf~}{^cW_Q$37^+q*uH+w-`jrfbWYLT-g#tv`o%@! zIBAlsuzxG{I`m`7SFDUV?BbdHQGXa@P4^>om&XKtE7$pp87!SE)ZS?+cJ!PjL!@W0 zQ!IwJsKT=Ee$t}c9nxrtlclI^GcdN@^-&hLSM_p9u`ByW`*t4O6a`6Xv>FWY9y^n5 z#!;yIcADo_A5st4)*vTjTmYy>{jz+a|BUzme1Ve)AYgCg9vu*V;db*;WbbWAJhRN* z3t4@zW$ZVhU08K00ESYlHz%s1RuTUZhYfKsevZ<{m@z`vhz+9?o ziY1N}FLGJ$e>}bsle`H1{X1qa&#=|Qx*K?WQ z-&-y5)L#&Jsw(!fj!A)u`wC;=oA=EMLoES2>rLQ?i)K-p6)y#XC<>hGE*X+GtzMwj z496$loQ$XMlZsY+PsNr4AK$aO#5w~INr2<0<2ls+q#PdThk*d00KlRpB}M;&9oT8` z1;#PySw&eXm&0X6H5b;T5~MuKn!l6+(&=peK1rYy@=)PKT+c<+M`(IM-P?}nwi-uo z{y|_8y0+i*Jw5QG1R(UJn@9m}!A|HYK{=$nQso>rZ*;=j+n;(AC0y-Y+vnR~Y9+iX z+)MfH<3qAUa@=eN5=`g&9^DR30udQ0S%8Ku-c>bHO}f->kMGsb5cp_CGcTQst`;cvKq!G2&4yfZt-|t3QKCd>x@B z^zo?*!*kx`SDDV#Emu}$Zb?Hc?hiW(3RS2H@81*k>KD@)Dan3UoPw+Zf2(5d7+dOk>CC-eOy(WcUY5Sp-N&je;p$}t9=*(}z^Bx!W53${8_n0G#SalY^rkgIEW zEB{+@okL~mpqWF)GsSoqn~NOElJ?hwjn$$i!BX##;+310qP8jK7qJp1PZFKYi~xS? z!kx{6)HB?5$Z?O!g=5sWg#f;vzy7sre)h)y(%7Ki6AwSW9+#bb*Sv%%;b_ksk4K-5 z=4y}RX;dC^>2?DZ|DvN^5_@KhX_Uc`g{Q-1bJhQd8~j)-W4^ z{(JthbH$NjM_tn}7V|nQI&II+2?`Wz`^9KB*K^iY_>;P*%P%Ad5Jl$qB?M@~#19be zn=aU0Cty$ADY}zNJ+D@V$H-WC-1d3BE5n|hFd;=V8F-J!%(20RbzoPkBL;w#t(Sgq zrYu|cs3wrDRe*V8>KC;XOBcTAh`A%@S77q}J-#btp$zjND}Ybpa}{*Ff+xI z>*tH{6`90W-MYQP=D^jne+IQsxU*FcTW)j?-&?oy`HtrA`z!}|E`WLYMG;({E&aq* zCv?lVgCR;aYzxow3;X>nyHlxVMWX&_T<1EL5Yj#sPxq7`p6mC;kFYsBIORY_IjpQ0 zx+aGP177X&!MMGy5g_ zWQrmI`oe0b)`C>~jM?YVHH!h7=xvXB`3YLfAbrAzv5=GLN1~v0KEt*2q?X zD7ulnut(A*u!pmnOt2>=%jNja#|4_NcPPwp4;%@z)d{+^fC!IWXGg^H#qvomPz4bn z)Gx;JEr}1xZ*y#MFkclP7`8A6TUIKwZ-9-E6AQXy?TxpQK|QJ9#B-mYrrhHuzf z#!F9ei~uQ2?Kl(OG~K?^_a)h%_%pS(iDz8y{4Qu z(HLNz7~MSwSZuF=@Ke_65N3Vy{@VEQpQV$)zn*A%VC#fq&VJR*q_AE58| zNrJY##6K~)BZ(?7D3>NrsoqZih+MCfm4N@AgtYhK3YkA8>yEZvFBXLeLh14GHW@SQ0hd?g@ETf{GnsonM+!8F;3fuvilF zan?20ex(XH(cn1M)yE;z2`lr&FHEh~kzeR5OqgmJIk1JByK4RFp+JA^#k(e>YRuGV z15N5wMLibE%EYa%U1g$oq?{zSjCj4XaJDV`&~5b^Xy3FMO=cfRSS~tK>JqXB$Cur{ zmKDGz>KczVbMX=w9Dk!ZH=!+YQOKVuv`D$I*!*&DjS}KJ3&(kE4DynHgWIgcbir4zzjK4$bKiPpxjiw%MLEv%XnyNvsNt*hf{w1Q}3|enk zw-U|eu=4B;H>R1NSP!~yj58S-X3R0~Ivb|Fuc?Tg1l0j}O?47J%Yrn!TO5gQ&YJov^GP~tBS6X zndcbLrE90A+2c{3BkC-}ZL>w%?RE1@FQaSRjoS5TJoLorrJe@i0>6Kilk| z*Q=qrKJ!Q|CnC6a%6Nv!-FD&83t0HZMP5Ycuo;URU#Sh<>}mI%k5uN0M}Rn7Tn~$5 z^JE#`c;c9JV^Xw*~U;yC71p(rn$PoP9 zJb*fKe=`p4P+Ek)D}o+m?5E6uPcaOjqYaR=I~9}v+OWUxRt)PAH^?3!db$EOP&pMz za=t&R?f={Ls9o8VWs=W5Q$rq*qH(8DkC_6p1*GARg(6Xf08WnEQR)ZT47gcXAeKz} zS|Vgod?1b%cvXy9mv|1UP*b2%ATsx)0}}P1de8;Pn*yM=IQn6~8;U4-$iSB!+p?g@ zR)8-7uNvkLqq0F9LU=0o)11lGSktR??7Mmju4#5si_gF9jmVzrH3> zXMUE%mPLIu{76pT1*rV%Exz6f>jsaw{NVFwk!aw{@W`dF%>WVo+crj9Z%0|FLk*N4 z7X;snPj(Tn`jjSb%37xEv~p7x**Jf&`Z$CAgzShm7rFO8wu9_b@P^Jb^UB;Hs-Gn( z0q_NMiOL2L=zuuD&mu$LiFbE?b9G@s$@-(Ap@nPE#Rb)~RT6mk%L+RY@X1LWy!HbE zl*yEKmHa<3$ri5YfE0LMlBnVw`%06DLs5lo6LBm*N^f{1Ps>Q^Wt;`fbBx1xYUj(* z)ya3B3#k^?Z`<<2^;koQqxMkMgsBh3K{~aATTJv@2|7dg`{^-K6L`mpM5l#COUC7s zG7P?^%xaR8YdM2&G6HCWx@Pz%og8p%W*F3vrq?q^k{q%pq*cc@i_)2wEh8kSF!GQK z2PBE1W%kwE=V&FbQsDmY>phDvG^Rd##Ni)xv)P24s&%AoVVq}$mdk=<_~RSGs(h@? zqrz{kU!m|LI#a(I-(XiYGeJ7kppb@A|4F_`MHZw}HMm8~yy>CyF>b$HF3k~T_>tnT zT2`bkNnGq!uNZP}5ns{jn`^G-@#Jz)R>F?Wo5cR;V<(vO+3+=ivl|C_xoKDKmsLl2 zOis#>dp;uqc|OcNd}Cg3t zjHp_~IIGpKtZTwlLW_q*R0{r?4ruYUUJEC>t=AJ|^o#f+kI`pkC7#PzIFWBvR|WCy z5U_x@57jp`0RoFE>J=2vsp2abE(!;7DFO~@G@$0=PSZ!&CW4|Dmrp!)j86)*)X?lw zI0sE7#w{GU!K`FNRDjFdEk^Za*Np6>cmNZ7B<~ zAgY;sahrq*<1B{D$gT+je;w=Lt4$B1S$m0)bkCW({de9PoYu~+Zc=equ#12Na3XQPTHgD0oCkl3Ph>n0*1$ak4Jm^5Fp6C>H1NB)=xx82CK>yFQTgS z4R6bL1<7JqL#7!tSIVkmJo+7QV)jB(q)?nPQk7nYf`Ta6yha_~RdDBc#Ykd!=0_P= zR3+MALd?plo~FjX<*VqXH`?7pYSIwR;79hUagXq?(SWH9J3ELb5@w z@ZYm2h&Dm?aVr4uf*154#ir`pTrX+3vEMlbTRL|RA$;}apW?BC)J5{(*VgfvCvtKf#8SeJ#2a-m#*Ys6OWS6f-+Y6! z{2xx}zsVq0FZA=fk>xl_?tV&Xbup&Va45PLkN#N_M%V|C+XY(2LS4}W7KCG!?v5ye*M z*7CH_G&}-)yXu1wTF7cFq|Te}UC=vrHg~2>AF-p)Y*P0Eb!kl_q!fHBjkc4^!k5lp z>H@-a_eBew;_N)~b?D-zm>ccb%O20z4*mJYVSF{2oN0MNQTc|lSPptrb9!6}vzH00 z?Sc$4M|fA)!!4p^Q8iAbiVL5zf7tri#a)4P+(rG+D%2DR<`k)8i-BBoxG(3#tox2E z;YeYCzArUryi2Q`s!Je9Gg5!@t&V041kwqpHJT=c(FcbWVr{&7IshTu zEoK$I0@wio2dPOg;1ivXj127?;IC{95!2BX*sJb$S|#nDpu2a){APW)fKRlato4vx zO=2`)p8l6+<19Qf?<%AO&xfzgjGU$+u-0W+C z-fi6Gm-7L3K)TxwM^Z+BI^8Iuu6vG%aeqdDs5JoRzp<+M){02jtJ-K*r8jO^>Pt3A z6UfY{ESq+a4~?`nWg!TV#bk^4xK2%V(CsZfjyU!q2l}UXMGk3nc?uva`)e{VH${6f zO)S>;g(t42k5COamzhm*u5NM$3mp-2P52rDxY#Hh=-gNGfe@dkuaU>9%j=WT3=1}1 z9BmF|#`8#g+}`-)-5f;YP8r%+zL#enap+^WfzDl3z+a=q=ISVb);3~x-WKfuW+O~~ zG+6K&+ItE$#?t)?duUB+bM%82pS+mm3Q0!@+fmpwEGAHi!diIj<4Pu%Gus|hl|jSpkMA9c`E=9Me;NYoQPWlEnlrc;`yR;~{z=$W}hC6HLs z3o$G{3SGC(gi}K1BP|-K#>z`yAFIbQeF=GMX`HaCf#DsJkA6ANT#)S1l$ZEEi!|&c z*udMAou<}_na8k;h$#LR&AmX%Ks@*-HzJMdQ;ZAYZg9|KUq+D*W;ToVZt`&OoS)vR?Leoa_VWZt(>_;LUvl#B%(S+z!Y+SHC-YiS-iiFL~jH zFYiO?nNvGck`u!jwXfXNUgfwPBBYt~*)C>Y6b#tC!P(0t!V+VOTXmdE96?b-@nx7dgQ%(xm+37 z>B;{1MrvPal{kTr6k5|^O3fLP@%QNh!9Ub+qU%o%c%C(-04MP;dGaLQ!eW9UaiU#p zeQuW+s-?sC;cY|gg-@h}YOZ$_tZvp;w7r!~y~H3&ZC4=P zYjdJ9TsORngO21%Av>KBfc$u2F;^?h9P71-CJHC;L4eNieSsyz?<+=38@wAg3%K^f z7EI390pwR~0j@MS<}Mg%vW-+W&(;pRjh)NEOi&EoC^o=iHOdM{ z?{wFBmk>*NHY3&XNum?6P?|;sAMpyL+M5k;FHqkWia@>(9f*6g1nJ9$63)&6K!&To z5FQEHSbuW@IC5z=oX!^U;Bkx&vJX92+1{PMf{Z7E56EB_nLzNa8`RPW`q2_-cN7rK z@#&1s-$`o!>^Y>I6SBq&J(UMSbl2cLKz7wMK;l~l1Hl*t2kO0Rl#SVVo83`oIJ0no zF9FE^Z_Z!8ByxR-!IdX-&a()AB8UJzhklKH`sQqyEal9j?sc{AE6)7({E`8A!8Dhj zg#5J!fA+{PkwD*!sh>UavqygNk^gwkiksv-Y4DfT$i36{F8c8JexkAq9=bOLIyVBO zf^=}yKUm+zIhA6s8>@$^6zxuI_uNt_G;ukjQEet?1g*qr2x^&V*b zT{EkK5BDA06{A$lR@$?TyfQw@N61Y_$1x1`yjM;?RkR`Vq(*=|-nm*(un7TMmp!C5 z%=6084rSE8kh=Qreb`o=+Zr85k&*G8Zt`17#1a|~vz5aAU6LD)CggY7%HDgF_r#0zHl(NioEN&_ok|3rSp2K1E0SPfB1X-?0ubU>&UGVY9Gd+#Hw$+LbpAh z@#EoB+>}wZa?_!K(*W2Q9J|3G#ZHH$ z6Z>=9*ZQbCDopk`dZ(+q=tB}vS;)RzVOYgN^C5Pw4vSElgx45BKWnFWXn#_6z_0KF z0;h}6{~qVKrT))8AA0$Ejtmk1= zFrOl2Zo^}z^7iwd#Rp`nr{WyZAgbI`LKl zfc|ud0FV7EJhW5(f)$1ZNYh0b&^a-a3t2Y-k86{;hI-9%H)G_|kN}(nsu~6sMmAqP z@~s1PS?)hfVfv#Kum3?klqyH@?#_A2N8+ApLwgPmu+47#bGeOz{=?V48h$+R=+l3O ze<6ziL4nW~ru5c?U}*D=JfLq67r^Jo0Me?X;#XhHo~Z0V*5vm{E-xwpr1MM2ykGINBLpSmqzpSq|Y$_1)>1lC>88psxiEhUUt?~blI z*&7W5d52%kKtDz;aGjsp0p>Qozo)89DAhFA?5=!>sm;bOdLf}q->37px%bQ%Bk8<^H#VA|uxa_71*yU|?;Ik9JWFyLxb)Aig-i!=9Bh2xe3SZkg zRKrMu-ZRVu->8MC)4-)umTaM4E&&^eKVZ*`{B*|Z-4Ns3XrKPw*8^7K{V%#b8SCdY z+`NXP4ht7?umx2r{c~I3?+~DkWat@X#n5*2%gtHSLn3uGy&to~{G(-^Z{el}{NF*M z)zAUs(BHqk32};#v*!xkxUvJa_BMm}wd%7sQh`W`#p@FN`M_Y3xdUWiz6z+w)+lnJ zediJdfKl_RDEtD@&q^*)`F75CXD>W{N!d`o4m-Fu1lwtW?oIr>{%8OF96$dL z%^%x$D=BDA$e$?#ZtcZeqA{p><2-f47%A{e)duWEK`8(Wr2tsyz>%LW{4u%b<%ttq zRFas_nCCjhvRx8`ZUPInqS2{!S=nxQtKa*`_*%WAmv^(T&~Yd=J?<5r#`gQ192c%U z_A>P++xf|Me=a*em)$=~>b5_LWhSs;Ea6qH}EDZE$7V< zz!7jg^k4dMV>$u2h0}}FS(CmfZb&061tjvjMVHZ7DYov*9IDOR&;`RcNI1c^ANtnx zbz`@A->;!Leb&`fCU{lD5GpOuOY!)MyHH;<2Ckeu73-VAjTNaNlfz)KgUgnYl3#8Z zaAO?-dH{uyz@IbTExa_49lN=4ys!goi;1b*&AG;5|ylA zkLpgzs{CInpwa@w=DP^cVISlY*PwQV`FQk8{>_d?pNoxS`W^UGr8?tFq91FZao_Bg zo4=d~;(VBZw|~vYu~38G+z6KK+mMhV^1fiW1dupRbFNBUNKo9cR zy6ohX9=)!RF-x0ldc^ zbQCBKm{zc$K;ZbjT<}Na(93g^T_DxNUkgQ8fBIkZMH-*vu;OtkmuWUKFq+-f-oAz( z4GE#tIkd7fS#Q5|3kEW-#s=V>$W@e_q3S_r0V@F(WS)Ewwub*z1s=U%lM4j_!5vTS zlmMAdHu%3fv4{=+=sNg#3));^orbgX&t1-;+Hz)_wtrC1D7q*ujjNrbCa=1HUJPyK z&xU@aYk^;uoM;|GYap{>0I>um+63Xhf5X_n@%xYM$#?dGs_+Vl7{{o^)V+BhXz9)S zC~^*KI{zksI)>a-K!3CRP-c@3{eSwLmf-`# zEAc8-DOQBf=qBlC&|F^&58o@mE{2DhyXd zND}dJog9b3YjfaX#OeBHBo{s(fG!_GfMi2I{)TM!&H7wkS#oFwuLJCu*@}RXtO!~F zJ{$yJvMK?o)-n?LEnpdy%!wc|yX*qtkFa}V)918VE{IEJCE`~2(X#-|?V z{<90-4lVdjNH3Zj-FgSirk*gq6Z!O=?``SA9m-QHFj(P#o5Pb~0|DYxg|epkB0xh| zp5{zMVclJ;a(FP}dA+Ji1scTw#zax*Q~T)d@YjN?MD?~bcN!vIw>nCIgI!qJhBuewUlPNev=DR!e>#yTpduTJ*)z*yxBDWqAp z+Zu`*e0)f;or($ZJuBe@RX(b86GCQago?FE+E6btDO?NZ$3)bXC9Vr8CVi1N4o^6C zh>JE~w-JY@-0KM)?9h>AHf^uDn*Knlb4&GA^>Z~t*h%B!AWI1c^qI(`kjjWnK>`Mi z8QYryscXDbck?r*E~lVYt$J_S-|?)zGpOD}FJQ2yXe|qw>di0C29M7uRD_Wd;nTN9 zP^+}yhK^BMi4B`vbX5bnrajKS%QqO%6yRyuII2tgp1G%L6fPHNOvo$e$wbpHdgd zN|`D~2zHAFTbnU7p-0D4_Jn{?kDDK@u|9NwM#pWf1HLZW-|}kwLlfk`k$-;}Cin*y zrauI2Z-pNAnOu@xwf^<|{O{ZUKm3mVt&I8|v*G(y#vKiQ4th1TtJrXHz&BS6cxN&` zSnK$IFPnmX;7Y$L7jD^I>H(KW10nPpK*W(~B&dr19 z6nY!CYNb_0U3YY?GXhv`4Yc1)*(YY05nhdBcM&0x8S5mx(SqCXWhP-(vGQ5B6i6Sd zsGw2xnp83>>MjX$8ug)VD2Vl4+bbtFdL!A|MJ6A)&dcE_G7XO>)1;A7M+JXLJA>{K z1}_9wLq*s@-iBOxg~_26ybf3*vsDd#-8VmYKajrR)B`^>`8T)I_~Tr^=x(!nd*Dmg zL?D%i46tl`zs~GiGL@Qs?t@^>lcI9nu_Kt}oEIOu0hKx(swt@mHLy#f@8*A>>k znr}bMN0jecrvJS(^P3v|PkX}uUv`P#7%0DKPe@OPwl|m@_CgNyim>{>9ie}7))W6G z&-(k^v1Ak9i6wml&`+snp9SIZ;=i}_5(oIxo#^@Pke=96Kc&d6p&xeKlB77$g#dfk zfSX|l!d`X=5OM|p23Z60jYZ9yoKZIL13M|GL-*W}px-J?MhOLbC@q`;QVX+q3Z5Ts zXw`<#)7MBVBGu77R!u8_?Ur7!0Vy~WgJ8R?TyV|+5iB-9KmDOfXmk5+$tCVx04U#- z3p=R;t+5pL3VwLVzd<~3xW#lNDK<`5l|-6#FH#>r3KV1D_N!I$kMnDjeJj0;e8-HWcpNti)w7s1idGiRog!h4Tqt-YNb)iIJ-beeP?sCM|r%bcrz zFgf7x@&q;{Spq;NB4W;f1+E*w=U<1OxmRZ;8ocU>hT7T)yw{VVbj@R5|Crt>VSC6f zKb@OAICB{k4V&<11wbiwK(ahAkdKdckV^S46%N56zf@S6ZR?@}>#eDLWp|3nhl0)e zBKm-R)~yu$uq^u|&<6YFFvs$SWJzShgW`qWh9-!C9j;k)b zpx0K#^Li+m&oLt7NAm^M7G23NdeK8%MfEagq2%m(gD5ah_M!V!+7){l3R^39ocz2Q zhV2yfGmK9=vgh~PC6^-V^`lU!D|vu$5C!X&!qH}eUfZF{iY6%rjweU4W~b7EWDc1n zV&vJ&>wuiM84I;JDS!u-0IC1xd{ZxiHBX?ex+D&)>mt6_%Ucm3(-hk0b)B!gl1W$0 z!}rUOj?tu?7acg6oW(yhanEzUkfGI1P^r;d(V{8eF=Ani^dgP|QYq;e)|MC(+|qOz zpsVAFemg$NwL=$;jEVj65n!NO33l2Stz*e}@%RU`H5U0wF?-QUd^%4^rk`XpuGqX2 znGoKSh_QAVedT=T?+10RaI8r5lmXjnXB8bayvMv;F7R6Tms|9`C#N-S__Y?)Ul0T8qV; zYmPbQ=uk&|SyMg4(jf;lW*549;Z0dwE$7wqV=FjUu!~SVH@)dF(exn(5Z3^^iENx( z;jRvexWv4VP^pqSX(T4a3Ho+rJJS={q6g2nln67DLLutXr1{;YiKanYcTX2ZdEE~O z4N@ogPgBwac+S>yTeY?OI$eh59{^jx^&U`HQbZ1MBjF^5r=>bJNWeZ@nlIzW+$X!Q z$#5p=p{jKZA7xMS843P*2CD;yQ#GxLniT_>)L-Op(FD>(kB`zXFZXkt4fJi4--PW$ zp>rVR%k1R9Cnip}hhJo=f-S{3u^0r&E$$aR7RnXB5_myljhcv5>rvB7{y8ZQviJ*p6(f_xYKvmeiYA|ExcUYzG9JFP-4Ql zWum7@E9oU<+)9p_9Z`;e;;9YK%fpOinU*{p^x8|kgETX4bFokbWX9Y%+aMh1jDCzM z+Vp$-6o@@+e^AO3_eh2BE2(d`rG^kziJ?5zO^@44>p@QVBTG;M*yjRJs}m;-X~=jz zH6i9=+m6m$Xut8s(la4;^PtKlSR-OZHAdrbgDp zJpx^Ts9?uOnmvINSqsi>y`vFg7%@``I%jQy1)Hv0!!by6XU*^+KGOJJ!tO1aTIYkY zRV1Wqt4dU_TnVBzPYv`vBZT_NOi>o+Zx0?lEYhx2>?Rg@&&kM!bjh$_f5bS(lIX)A zgPx!tVSTiiqRR9FrDul5OWFD!}fFGiY9xzF5jM#3JlTB8!?m`p$^Bs?~Q9z9`Q z`TSlRrMdp1_wuEn@~>5McR>@YV^l)f4&qa)#h#}rTsv?UUeHb%be&`{19y7xG^J~6 z;`th~)ib7!2gb&coI^s^jP=)wLWh+@d5S|iEqyyL&AcBI4R+|E3f{Q~`HO?uQ4MI# zb&uikX-U^i`9!=3pPDhb{t3(%>w}{!=g{v4*V9e}WIa|NHg2CPV2jIbG}X1?^qiC= zxlD$=%GXMV4nGdI`Phu{I6U0S^!avQuN$Vn z8N{R4OokbH)71GgL7(a?M~#Pt-NdoW&`nWZ(HP$v`$KtZ>m7IQ*Ah$10}W;^i%Vb4 z)HTgbI4ZHz-`6aZTzqUFh40oOPWLw3#Qr6st22K=w7&WApg_*6iF}uaRztBz=RfLA zBXozFU>#HgMcePbp=7j}yh3n?PhdE{Hu!QT(JGu`xZ`S8tlG*%$dmPza|{C&FKjB< z2SaKZ6=4>v)n>T^=U;~l7bopPi{rwbS{L_nc?Iuk%8F*d?!`MLpB?3C{%Bs~5+OU{ z=+$p-X6W+p{U;?kUoM~R)N}HI72@9~ zd6}?K$x)w5?bnrG*d<@rUir?*%s;pwv*VV6MS{!|iXCzvB`DpsHxxMZ_&}Kg2HxtJ z=pbl*R$(fnxCEJ-r()Nm8nUCEEbt6sD)0>@X3GSc56c&7fjw|b9)R_h53|2=Ya5y% zb?M0lXTa+Zs@T!eEB{Ep|416Lag8VU5xiUn=gV4#?!^?f#ce6F)aVY? zvx%W;>0;Z|^3r^ZsPqLO^YEh!*rK-cEwzn8e=Hz za;{rjROO0Xxfu@-1fFZjF^B0$U6u+A?(up#pe1#=nTq!9PY zkN%_}?fCc%eDwz&lL|X@<9wgh&Ab@8iEXQ0^%_H`w{9ARHDBN#PMi?lTWe*J9Lw)v zkJmC4km!{75+A%6pg2s=Cg8)<-my*-2~$W7V23vH@d zX3I;woJ2kwM?ZL;Ue;=8K0*KmS z1IuX}bYqqFlWwqcS!s^;2k`J{i%#$$a_5v4KfL6VZcM1{NBhd0YB&fcvuls{V_O03x3 zO~}3qk$mxv^-2Au8KQ>zwA85`SECK_sjnekl0ow_XWvlq?sGTT%nX!gV`&Ayc#cnz zBnuSl<2w%>6aE65@dBaX$PTndaXCAcdPTbgPC5#o0Y_8AmejMV*I>&Zy1Ke?OVQ%N}it3RwU z>(HGVP*nDE;W3&oY@=%M_kHedT<-+q^ zldDm8b+I=Kd7Dw-Lc3QN2jz3AlM z_vSx~B@c4_Z1V-p?=#ryeQ?O*+OOu+^X=7xbz(B>-t>_ zRhjTfJ{x(dJ+BCFdfbZTwySdmWt#?dIA-H3&W(;t_t68`CbbG|LGIeJWmCa!+SkC$?v<^v1N|xh_La(q0V2`W40U zNpE$(TGPBi5k^6=PwcV9Fh1{};Z@w3!>YyvTG;qh1sWRCpW@OlC6)pH~`s2tPvtG z20_03Jap`QEDs}@s(Q~C-mrDbnMsW&Z*W}8U zc<~yGEV@$m;QRx`ZRW-m&dSFif;^)C_K5tAOu?fx?7!mrXFVchZNb5NY==c4k?Bh! zeypMS{2oizrYyx<(sD_&=b254Qd%4@LOIT|H@sQ>ShBLC>}-61FpJwEwF4BBnDSiQ#%?xj)B?~>NCJXDCkkL^^bF$65NvG^C3jk3S{ZiYZ-MnzH5t}64e}HJbjb@EpoYq^VY)xN(wn55*++fp1%2>3$-zECFP&rKR*R!J zS{90V`yV@|9G5Osr1>B-1-7dFu7vERIyE$&U0JO0G{HQ?N*-9)Zd3Gc37T;{opsHS z%?8jcVLOK?>Kj)#7~uzu6`TkdciX}FQgHG%VIMQTKxa0zz`+~HK|n<>3pEKf0m6MQ z=QcP%KmHiLa|l^Y-)!4G=z*^CEC7N3GkP#bFh>RuE|2{+$VNOiII2E4oPb6h|Ks*Q zjEByfiZM5dfc~59ZBS9CETM_Pjp{wIq zD-I0ON4=du#?3LaI%F)*xT{PSq*;9atYabhT9eZAkK&f|g6E=i7d3&BT0oIN%5zF9;a)=qvt?QP*-stw zB6C!EcDe+TCXAUOtqg`k=;gO~<=DgVPlvx2-5;tGTqgSPn%ZqFyFez!3*`e|12yVp z#l%qw|IXB}=>j?4ORPg0nq@vo3h(>X{18*m{QBgZoX|xlaRVk5fi-h#3SKdb(>$rx zejp}XqsUdLh@l$MFL)D$Gpp=5>R|6+FJed6Rf&RrjjT`)!niM+rw&=n8ye1589IGo z@CntUmN#yDq1CtihIwS%t}ig_OfC1O*+q}}(u!z3tPg%3Y|1UmDwx9@cx%32YG6ra z<3pZci#eR5DS%%ETCMU8r3tvvpIUwXRJx`-X-4d=)M4yd6!kTgWzzBOgQhW!tI6h; zjm^Y70s6#TxsHb~LTvObQPfBTV=k-64EXO7ix#p@cvRWd@i)%JSR~v67*8Pbj)quQ zhzRCHI^pfzG_W4>VSU?WJiU5!NQ6TurnvyE*(mrCi29*tCAqH3Z><07BL7^6=gh_? z0-hbexr^60(VO6OSrcnFinooi#z&;h%7V;b#V9hg^4?s)CR#uY!-SbihzgV7w1jnX zz4NI>UOJXuD381HN*?j3vcqbDzfgdsC9l+b%};2oxU3P^Tyu-w1?Y#3aKDPZTrAyL z?LgAc{PZp^F^7&}(EuV*g5RcXZ(JCkg!)U&%tFuVf!H?`hfgCZs1p3ZU;FT%^Tvlc0oLLk>&8qqldZMHM{4l{P0I!@QE&O(R_h;oP!E31 zUOyhw^<5eNx7pyo$wcw3_GDyvc`aG z0MF#PetHC2?KhMfRUjEWLXvr;Q}cSEFR~yRYz_Z^>RULTv6sn(*y7PTajgh31}3vX zMOK4r>DZJs_Vj~aX5){WJ5Pp7{Mr4{q=pQMV?~bt5F7coj9O^Nvl>3dAVh$!nGIk& z+hF!5Vf%mfE&s=!asEd^sqKFq(0am)cj{k#e+*Infoj+%@FefJP4<629RAgC2lHY7 z$Dx0J9k}$jj_|+acmHO?|7Y0nKg!OT0*#G( zKU3RQ2g2U0sfHF$nxQ^fHp;!p#&&H_1pYuPSY7`gFoN;`mUNAj!H9z+Pp*6vxL z7D{@3ys422T3z(`yPFQhxC2H?#$l+P0~5HtLT3EP-_oz zcs@ciV4ru#arVE0&|hR>mSgt?W#ViWY%}-&fe#Bl@u5Wz5(Z>;dmm-j5gt(Q6&>Ql zf+9|EmAC_c$rJaQ`3g%(2aEiw`dG)|^#|}>MM94(BNqtzXAxN-9Bjr1y3&;b9P&U# zKJlb`3E#y8CU`-)_am_R!GOm0cB2NeJ^uytPDXl0jz2N8_Y=;CzxHNayng~Te*!9s ze%(*i;r7?yV~{TRtm_)a;T|xbOlm+++z-VE|5pLEo}JD&%~uIRV&>^5nDilNfSsz` z>1_N6(evkblw!}Eo#8q8aTRQPn@GtBHfycCXPF6q?cw(`YyIDb7M%#{9`qNq5t@ds znb$B&rIsfizX@2n9gAZ+k?BsSMSQjt-Vvaq_i@rgq|I_njJ3q%<a+Q(7kJE({Wa7TgUk=4Q%v~Xc z`K17kZKir>F6qIXK_ZoQbEtdo&2?+Cd$}L(K9P%sfqcryz5S2P?|Dz6@X7lOvxx|)~)D?a1~5tHlnF~?!Mq2L-VB} zarhDskEf_a>&&jAP25Ih3v-zh!gJ*W%{WOz-rIgd@pHVbTxC&nF0SffEyMC)@^4PMHACWdLx_fapDgHeGjv>7#fDteYA zmuzRFh5|m1l(8a@iy>LXdpMx~uWIm;;lbj_&+&b;pA@DF{#?rY6YS`3{%K(feCAIH zQ}6#SVM_h)5~hHF@sq+-_fHE`{|4&6f%-FI|NlBnEiqg1bvPx;Vzn7U_;QW%oLt}q^3r14uo`!KP|IMheU8<;t)!^PJyo`9S{!(5Zn`K}7}qU+2H^twYV$WG z!l=wp?>6~ubWb%+>?R{KdE?MntgCQD{TW4GR2`V`{u7y3o z3IW~Zof^=h8+t0Kn%><+T+WkeOvG_5{BjE0p6Ax>n9mf%QfCD%h36RBc1P~_+3Faz z{gobIGodN2CL5TwwBG_Z|FUFpDk7p!39qGtn!c)cYnWpPg zujgJ$LDS0?Z&8$KPQW{JG3Rz{a*z`M=`s*Eok^j8QyWl-9H)J8WhKAMQa@1PtJ^KU z9;0ZZ0LbRsVzOsfUi<7zYAHpITwGk5vKxj)s;xZA3f zvAHOu#Z-VUIbCRk#4POm+8fEBfpe`KkHuuHTW)&r*GXOp@B;xzCxr5@CEaD5y*Xsz zC*2ez*VX!IoxcJwp5TA;=o99RKR0;%n@69(yFV&}NGsC+I(7ndjsNA+B)?`Fw+r!7 z(N2P5WstN+-E{vn9}0Wci+j^wGZklZ)JLJ~r;bGEyV+jVF z>g@%FX=YRL0uG6K&#POAS@BeWi`R@EMhf7p#lcCDp+9kd1QYkMQ z<|R|J^{U6ZIv-hrZedZUecjW@)Hr>vL!$iGB2L2y$!1<%==YmV(lOC^m09G1pSZ_K zU4wvFNDL(eEm`#WHH5vl#Lef(aBa8LS{?{4XW~>?jmUDcqH&HWNpc;aDU2R&f1z29 z=XJPfA!zLWSsd67$c3MI3X)!k;D+eb#GKCB*GfgAMhSC@`r&8a}gIo{xpc%SSMurWM*o<`oc*FSH z9fNxq`%Id#cyx&24h=&NH?MK2TgAmr5auF&{p}YX&Rt(uD^uy!B`S<(@JZ}b;YNa1 zSNx3bZy9X7Pr8BI%(s;t?Z+RdI<=$5GIa>{E2^f?mA^b+nS|FTVpxvB)@(QS{Kt7B zb-#S}6;ci1rGwkTVj10)C|=n9GWBYRmP%qT9<7%hcz|_RO2}BwJ^2cJ=45fI3x}>B zSV!2Z4?^mO4uoQri|(eY#b3`ACukaQ-_`g+yw9={v+n=+nnc}1cNyc=ctsdcQ62G? z5EtY97@4pAar=J?NB-7JOmS-?2TzwlLdvk!A-(DBiThMa&g9(vr)waZCr~YY3;NI< zx`&%Vu=EmO;g2F$HVDC^jS;ocPdpGM!QF(&&D}{1cqkIr5lJxCJA3YGEfEr-{n!B_ zC*bP=ESI=i3$Qyt0g3uV2}qP@mq4PrUI6kO{HtCcw?dE)NwY4vY4j;IY$s7LzdXI) z)^uaT>k15qY$kvr=4QwFSBzdTzQC4_rMeB~XRA@dm|wZy`mt*hn6+jo#l~d$J#tfT znybX?%A&C`%$k$H2>&Wg8PV?lrr0%HCWLR652N{jA)#vfR+!|OB9giF-Igtj3p#x( z)y55F7tUOkpg|)R&eJx!TC49cb&v>32Fd;6)Nk$1Z#g3UbAkq1oawM5C&djq?^ z3fjUV6Hj2ztck|YJEh2R8Qs7e>i4C*ILt>&`OabVy6AxKBLRb_s`qyE&8E+kmxr9H zE46rC7_BqJa><%4_evN-$Kc8Y9}&58kG>zfq~OZ5AenY>b&Nl^|2{+qR~jeABBfD? zw#&A;5p{i;dILX>CiTOGluo4{ku&h;ZFxF{YRi`zx~O?}p{Dz+t=&1(0jE&-C`%uj zW!DlVPVT|!Fzvre65FiK+vCwDm)|RR$?V*k`|R?o`g3o2Y*t8JcRJC+UF~Z%Dp$|7 zMBa+_j$p+$Pcd@;SlCWALF(mT{td;b^p%32>k9nqA?4L<|IgEw<)mCaCR{~Z?9W6D zu9LdGZzYV7XwF!(k)PJoN`_@^M*^W^TO6=F9VB2$55Iet-c#su&Dl-eb9s;uTz!Am`uC3o zqo4Dsvq^{YtvOiU4(@<%%CPE&d^{94nHPvJO(p3L6EW~PdmjSgSQAqQ4<~?6!M3|q zBycgRX=12i@h*r%b{NaqBjAD@V1Q-#g6QR=ts7I;l2(iIUPetk3*V=);ji+N3B@PW z55j#(QSfoNe^#OXlvw%>CY2M(`1IE+V(5b^7gvj{fy&0o9E8JxpeP`MPrC(VO@I3A zD!e*;O^E63#0tUsrBGps;m){|4Jo-jt;RA)eR~h%J}&8>k~CebcypDwvtcPE_}b|W zg3cKn1Xn^gTWv#ejCiN2>)qO4wkhU;X6noO$n?Vqg>QeY?@l!CqV$r2Z1^n-&61H#n;{H0#oJs8h7aIIoc5 zp*vGBHM4#tEm>X)tb0p&!-hL6{IODRZtvWB#_r*(`@8_tCQo3R^p5rUV}u+7c;AAlQ;j$4lV&!NYy9o<@+AVA!Rk`aE&p zIS}~lKdm61#Q~XWLT0NbS5iA3xH3&Lb{!Rg2j4~xu2Kg$Of%QLZ@I0zaQ zi038K(#)q#R5>J4KSX1Q^P|2E@ouWQkm!64y3{q2_ViV0>ef}*M`Ms(cwNpHwvwTX zkOrwog77`O-x_erV$_^&Y44xi3$Oe5ZfICS57Tr#6$*`F49h)Bf7UGx)a9#YWM<8> zB2OeS@Wu9XZ>E%>|1|K*=|SRzU$*Wtm0M;R>m+aG)ru%lxigNQQU z?z8xeQ0Q)EVRxkz1`{W0MUeY^gjSq&Pyq;~_Q@Zx__(5&uTDUM(9~XlFRn4rWDAf^}SJN@HPN9@^iEF@|@coce^Zw%&$rXG9eae!N01qbWx;;eXVH`h6-RnXr zqhL80x3%l^WugN9$x!P$lhkdG#ShAEAwx8N)mI-0LXrgDyoX%*o|46`o^SUZ)tUZh z90jzfHM!q;vf-cc?W|<2NYWa&;tluLvTQ{$ONbq8`>p~3In8+(Hs?!3VgNi-1yy@ zAAbngb9@z$zJY#;coM9%Q z?y0!(-hGK`mpV6vM%$eE@EY5elk&T4BdBA}wyfUV9?Rr5Z}OL#=p+x{4jzx8E0nz^ z_T{;;g#1?~R#2BTPBfo#kf4Ym>sUAHZsJj4JD`e=JH*ieYBSvad+^Zld%3VyTzxap z&yEm*D=UZa&H>R+BV|8gua4h`wW0@Ry)e(zJ<(0-WOu0`Ij+kLJ6YB&afhzFh#1z4 z^xB7|%l=MQ!ck>wbZPFDE_Ls;Xi%uhd1k_|UH86%?KUo)QJTq=733#{gj&hsgZ}`8 ze<#HM>s|*M8f1;_SGQ`$o8xZQ^!O*QX@AXgRQ-*6<=m?RMu+cJ=6>jiInafE*dd+s zFDm1&w}cFDzU0 z_Ah@?RdD?N{s7zFt`$;%mehg=*kNfJ=UGUs_xIyIavkt}$yi%%zlkV(j zI{nRo%XWHP7Id)T+o!+q5N{1ZM=0*v&TR*3e4aRLZ&665i4w}6qZmlz3mAO}7u(EC z<6c26p|jBaaHl3Rq+bowLBH!|>~z+^&d5jhtCuSoR?DSCCKU#6o-zQkn%A)x%^P!+W=>Ci-U z44+MW6e7)1*=Y-7a35=+wnABzyO9eDv0;D!xJ^Dsn_nuir2>KX=@@7TCIoyn$VzO= zT9vv(^izkEHazZloirg`7FloeB|L_QO|URZo=S={Qu-U6Y7}v|m69B~v3+rE zP~*DK3U_uC*`z;Li72MmmW+`Q&jHTWi#SamOW`|eB7}h9R9DCC5P%B;$pdBx7GQ8= zV{HfL{J)|2r5JZP@A|SfH5FDTYpTDqEq$FJQhf$bd6v&U76~X5UneK}{hdc9wv%H!{CaHZ_vME->~S&^zdE(m47f z_P@)Hb62x{x?xRa7srFF5SPkw_V9!N61nw*WHMRE>gyrc=Md0Va2X`GhMFbD#}&bv zaUW5K$Bf?&3BTmXS#zt!wOG}y=+mGBp~zR>6JuLc_cyJ7LouTrv>aJu`J!}l#@w20 z*)!aU?Mjxl*{1}0~91(%%S`mi0SdE(W-#H z+mETLIbTIShg}d}D6GX-QKon6SX5H|u1S5W{Rz(h6EHt2DExC@*V+!MKaly|JZW~^ zTxoqtKoIiFIm*%B#sDJDTasLz5}#kq_o~Nxn0`KfzloXx5!*z(m^c5ytQvBG@&9kz z+y9m=^*5vZKj$ToW9;*SIP*O!I9Ha?WkLsSbVIXf%yP`hc|v;|iEk)Yd8JQ{^k3A> zKYE`K!1d_beu3?Fr!2`g6l1yFX?Qr~#}AMUwHmMhntLw5w`+@j36}l@E^Z715x`Xw zgrD1O)R#n3cDlWW&O{@We*92w22tajAjXp4}c@9^)Nzd&ehS>#6Qz5uL^`yeB3ZSpMFLOD1l_2o6z zUk=IB;Rn=5KeqsV+rv)qJduaX#9(JZO{<6B)uf+u$owOFPuAuK?@@>K03tY-JzqvLQLcf$IpY=Ob(`y`waGDj&MD`#X)k@6($a)2Sf-kOUn` z%H=_;Aqb)bWaK8$W_-O4+1dHtZ6qKf`qUxiJ%Q)KoHFXX-4A7j^yY^dR1Jb~tFByg z+(VnYu6-!lxk0$Uu-iV(hU~GVyBcf~w|NdoAC(w8fEAzJiu#5kngQ7#g?V1q?j>}s z{ob_6AKA1i@_@SE`0!LFY~=|8WIzfh!#*?CBX%HT;*s{~BkVBHbc#X`5M!7?((!>n z1j~_042PaLwCJuNdq2TJx2m+GBZ2tr-=|P_xTpR7TRVso$PL7nqCx(^(eIPb{cOAC zAcHzT`!-l7#M-4T7~x#M>n8+~pl32+FVmr`fpf4;tULfhbjXow06w?cl^-8) z_17tYO!tu&faf!78)63l@%L+Whx^-v<-ZJ?@XI6#V8z3cU`NWJ`=iM1`TfRl$a_$w zoAw3`Q3%corqCvZ`ho_+6}Hh0ZBd4RwmR@V^gcihKt(@^&0nrhr46*bs~q2sgB*Mf z-oSTS1J$$CzM-%y!Ny2CfJ{bc45$of;&bFChIJA4U%TXI?XjVhdnCHw@#lWyo4IjY ztP~A&2I}_~L`JH?#1vK0@ZkdSEuD~ z5AIy~6!a&x2~^Ydel^hm)9;bGw6@1@QA{QHkUq~^9+9VWhYVd)q)0hS{<~=OT~-FsU3iqcIrxyc+W)Q{Oi1>-dE7SVw#^b?{B*puG?gYpbu0AvaKDl>@3 z4&P8-!44k9vAxl1uO-S{S<;N#Lmfd_gDO5v&;m=?ECy^B5b*k|Q=3@PdN$~ zCklMDpP&eS$*rumLzI*c|Z{@sa5BR{h~7!Oc!IQEB-{vzlm z8vFpz!-*G<_Rw3&{`S`f>57&l__3?A<+Nnt&lc@Ba8McY-=r4uUX)6KnFH|}L;m2) zHx&PrrUOr#yZCzVzo8Ub!e`M^-GTeNw*4^A4lIHE#)ce%6**KI7z#GPtGkKX3FSf- z7f1Ag+AMD_yxj$~oKO;grW1e$z7&(QhcXX|2F1pYPLcqYWU3dSqPx}FbBJPx(+b@w zg&v)*d6tlyU4n^i-)I5xSipNa?m!!IbT%YpUnUR)0?8bI-!I$KT?>^u`|gw~J*0N< z=^ex%(%1_7z97GZ@Llv)R|UU@<4^Y=tsp!Pk?Ua$Qk^8^UXx&=KJqMhsTsaU_!aqO z>HNCSwR*s6jy{7Hu>!iP`(yE`Q|@9mx&UU!pB|s^KlK^$a(IL6RKjNt{o+{V&m9CP zQ8;Z<1xZd4@&f3P?mKTFJcn*<=&mIkxeNj81@6~6#4w1jf9oKB&~xzM==CJ{SYv#> zTzF9qbXL0)%KZ(61bXC}AM#wQ4=mSeX`yY85Nr;tF8KFLo$!ZFTZU>une&rA=+Iu?x5%fw)ksrHS-0JgT zz%xry-OVI_f3e}fV|w^%tsd;-4Hw`Qn0~vP1v&B}^*UCJV*-Kik@1eaiJX|On3bh5 zy8nS%yc6y~Q{rRo-K#gSFB6gD+{#Vpzr`!GQCBA)DM8ff=_UIr96ctIsO?U8aP|V> zqmNDf1dE!vcn!T{QFVNfVIk!*S<@{pWvdG#q4+n|a2v(RMG7)1igX_bc>@qa$0#cR zjBVr(x`TJ5tYEWR0Gyd6kmt)5;K2R^OTSO=n=NyZ3u|cyYD ztJHfMJ|T&O0U#}bhZRl$Ld$P=b9UN~UL!&H2}Cf!taMhzfnckHRfG=8VK2ba}kHL{%i84fUsZ z!97bzhjbi^0<#yS5-^t>Z(yR*?y@JS-^n?&h&*(KBBGZw-eoU})I9>SMG?)fmhQj$ z$rK5?bo`bF9^R?S23mOh8VtyUEm3=O7&-A6*N@PLzh&>r|Lnh$Ip@816STaNJG{X7 zTWMf=gf{{18Nh@=<1Vk0VnpT=m+Jl@cjMV_ z(#9_$2x?UNPDEX6xRu6g!&p+0*D$7manPv}IzC*Vv)WEqE|^9h&_`Px?Ck(sEqV{^ zKrdo(LID^Ia$Ir_ufER?Zplu!4bv#R5dws#k4~U?Mq7>#d{rBWCUsYVn|4DMR6^4Q zr36cXpb?-dJ+0!hAXoB?#Bgz6%1ioU-I* z5SLm(O-@%}=<`^BBiOZxUO-C4$i>J%Y$k0m?4u7~pWfuh6uPfxsG=N?SR+h6!9f%K z^64alpoSKz^;RURdlLy|S&N>?tZ9e8Zjod3O_>_s8!}X_SP2$B2IH9Fa&qProdQ@H zkuN*TG~aW;kAoKIi^unn=~hpT{kr*ZnAkKfMcnigM9fRxX_my*OTyL-B7GejS8WMZ zDH*nkYydz{Y&K9PPr^An4Aits=w)5MV08mWZp}T$hOU7G!S5IIa=f%K8p?CEPmG;- z;`XAE&a+rEeS((xrPmSzh+<&;nv;EP+tsRaxqqq_iT5h{zsC=uk=|VkiZY>VE~+#s z^e^-S&I+Mo10$4%dx4-MD5CeVx&t~B3s|Jbehz|NnKeZ%C!0jHRs|TQusYMV zbRaJv_f=;qVrf};f?ZSJG&32ogp56vU!4Mtq12mz&=LE%TWLs}V+Kt@1 zzM(KOY41$Ph9t1x$R?2B{3ILLFhK0<-GnW4&>~>4Jr@nm78Z^aFfKT6Be0g?JGIx$ zwsu{`p^>Cqghh^|76G_tXdC&fK%MkfX{T&8O`q1O{+sVP`qd2}Bdt);bc{8Z#~98I zh=uiC?*dp8Fu;3yC&JoXC+kw9+Iaoy$Wd?s;^-BhGK^t)9=y2t#)cfOHy@T6b>2Y z2wu^fe*7H#-j5SH$4iwBp|&1^xWgqlq$zvoJ&^T}R)-h6I{Vyy)O5?3nl!uPFmwq? z!l*_6DIq*s+rbzo?7}lg!dQV_nCVaK!f&7dtX(*RXcQLPxp-H976h%n*14aGbV8h@ zqbPcL1#kCre~l9St)nP1afR3h^&rv&?0vkE`FKtTpdP=YQ;KtnJ(gSc9I z@8omnn4Y69!W-uTsDr0_piGvNhXy?V?@m01tmX=_0b8)QHx$`f3FsqzPn_=~LO=t$ zF!0zf-&*TcrO@hF6tS!F8={Xwinm#*YaU6hjdCu}kCHi$c8%<)#S#KJ^fzyxEa-GV zx|2Zg^C!Owc!ShVel0-kIqmNT~0hg5Pu8Y({+|E;(b@QoHE+!1{W!Xy}e)7Dim zcf7}}x65_Ms+=!c>Wu~~loepwiz2lQj00vltfTJD1jJ=}&!gVRyHjp2e;Oo@kQ=XJ zA1&epUw8w;${go|Pfn1oA|kXpE|jcG@ZfCbxEgUb^{EFnS2>AU8nDmqeUaYM6KMGv z%+bopBmTRfigOa&s$3)ZvpoT-Qa!dA^=Pf3OeP_I5@)AEFh}vO7KNe7{QzNJzQR5* zWNOob)p&zb@}s#J8{&m9*O~89%JE>mNn561{1MGs#svzJXEG$ZnP)!Toy45LI3rgO zu=t7dN!+c^h&IrK2b+Qz906k3E=S=OTZ2~Z&;$2H(6Jr9`IbqN;FDauV}yc#Agp@e z5uJ8~BHHxLs(>(C$H6m>leW}ZGKX=X%My_gCn&wg0o;6sPy=9kZ~^B7mUo~G5Ff(} zwt7YvaXU5twWbmw$BoRky6v4Z$FLoB;8D_EF>|OL^>;9 zBEuA~q6y$4Lg>Fo#oma>xBjg`D)jJzMtjN?F{JbJdxXs&BVyIR;B5LJyF(xoIug`> zX(EP{2d#gIfLDHJf=8gnd5jK`fsQ5Lo7W>jA@LH4>xxHTKDHg;!`Rra6^v<7|_grKD!1fPuKpET*H)_t$!UP*ZBXET%*Fh#Yne=pRbCk zrywJaV$D-Y{@Ie1O}9osB=Dh%$O{2s3aPrEHv%7JJ z3?gG2q$&H!rLTrxrI|Nne~Dv%N_-GHs`OV!GfRRS|qZd<8+Tvh%=5cu6a4Cr8Z= zk2Q7G)2mHBx)zs5yE*mthl6PYmTgHQyZQ>Ag*t}??5xWbMCEvH5ev6qERx=tp2H*T z-Y;68T)r@Up?s2+0S;XaEw7Lzx2Y~A53G%9w{@edv*AqO&VLZdQv4;G15@+@n#I;9 zrm`GJ?DD!vfx9wz)d}#fGtzmODcNRHu|4T9X8e=~Qbu2JgViJE*`O*}V9P zO|pbyIiB~yec*nx{mYCtAc>Coxl_AjY@I5ei1cjy z^Jda<+s~h1Q%}P-6ZgGaEaR4==WU!HCA~N3v)g2beJoi`Im8?WhSaJD!0s6>?TS9e zo-aG5djV%x-!kyD>sLM>g1uNqc%Wg}V*UMB;+5=aM0v#~!_F%MMX#LHKk?U@#g#n0 z`CP6x>B>FK#h;Yo>Plf_KCsn0DF}i#Pw4EO)fEJqB&hWH zg?1I=*+nBO%pD{45RyF2I*#RsD74PGd<3-vJ3TtFQes{C8A6GQZ%XXMvRXE-S>qcK z(u_%*Y9u~AIjJ~bNmUw62<`W^am}lvUL7FnRNEB@^=!Z@+ioI^&`aS*Q9!uDePGqE zd7m*`ETxpo3Up&VxNJSC@$sz+dB0nlh?dM_UUvEG5BHomOiR28VzL^(pC=HkC6B?MN@jW)L};u4xiMjJ!KEeJ zMVYUY1yCr@9z<|nRxsyq+3cb*Ra=xA`>BprfATxJ!;C8)@^4`AwI6i3`5|(31+Hz* z39P~9Ev=PbiG7^P(^Rw+fI7MyjBQSj@BIYz8T?9IN}Cu zvlD6#5gM6i=FIbNI2WBB)YSI9$db`)nJV!nsA^oegj9K*uPWQ?Qxg&DJ~UV;`sWCO=*0%fA(s< z{l<*5InyVb5JeLmloGXDLvxW!Ox*d-nW|@cYtxbnnj#&$QLqec!mbQgKMm6fnRaQP zcIn#N%Y z1StzU^=w#sB0P`q_AOHB=kIcz=*}f6ky+T1UvpM+Zu4GdRd8^WQ!0HX$sHhIx49-w zo3%J~t9e>h&;#GVxOEWzkzIQxYDF??<%ael4C~Z7AL&Qe8`ZOonAuP{VBofM+NibPo;a~HI^p0APDf?RS+on1{oNLGHw^kY6V?ry0k0f zqH6bo3KKT2p2fC2xZ?By)2EF!)_T+pr{k3cbu?nkShk_N@N-kt{#r%tEH!nf@~#k@ z(WtLM=a3Y8BdJ!)O`qxnhOpu+e%DBSRx6$HdA(6_`Yl%x^L?Uz@#jK)TV&^3M5l5) zpJ>Szd9zLw2C^JLbDpUL39HnNPZ7=Yz-c^9=5GJMoG@?z9oq^Q`5spyGh9E;zq_d6l|SaMItb7jq#;s zW|F7}!Tnr)258Oi9UdzAy9QkJkG1(^Qba*ex*M3|)uK{6_GDA)_ATR%(ZJqR`7x)` z=gXv3_i*H$Hr--7&9~mNv55+~)VO1p1U1>f5;gLz2U=}X1`Kb_^$_Oe;hN*fE$%2k z6ea)YteV}+dhwB*`QB)B^;$nNy&-tl0jT=Y{YB#KFOpK6 z`ui_z5JDhx@Hd~E_IaCOiMI|5S+!`DrCCi)hphnk0zd`=fwQjJ`Zl_hkN) z2qhK!e5gHiAyIcvK0HCae`N1Br7qp?(sxBJxf&^W#aG!Nu(2j973B70XJ}xZiq5mw z;s)iKN^&qNDZ>zzR?y8kVOt7AXLb(Sk1%T}VkT?bYwx$ekGxp0<7to__=NFzVmyn8`H zA}4pI``smdJZ7uIx@*CcX3^o&ZmC(>{wB7YtYX=7iVf`prq1R?SS?%D4N0SD2nT@(Rq%a|0n&XpAaKEIy;5B;9?IM3FCo>@q zem!|h6sgu?dv4(rZ#$X7mm^wO53oPa*P)?qux49iUE%kbi$ihBc(!Gsl ziE80f$ixz#o+yL|wMO)COuo%-98=ymCnxe!Cdrq9%xsIueGY0L%KQ*gt9~3oBAdq3 zMsZ(v2KLt9!E}KtmlHK#-%PHIGA~Vz@-?}Zh86W$&Ai0Uq}Ijx>hyPC392;e9p6(e z@Wx&#)n(+{jCq;x8gG2AXjvc;H_St#?Q04o$V|7&nnoogy*gc-D*b~K!A#7{Wkv4O zVq3vu7|A1H`}u4;XC;-NA;#U6?jzgoiG!vY@|dP-&A278AF2N-1@+{Vo-2<&X7AYEMZaJN;_^5k3j zkTnN<4feFVEn_Rtl@rX-*;E_IXv#t6E1g}d_TDY)6zSy z@6TWqg(P|3FZLKoo@VZ~erH*&mv7s9AklMWK_E8abb?t@zWnWW?GIb*AzLrPnu%i^ z)V62dejrFXfCKX(T9+N+0SBVIO`@WcIqP|0f{lsA#rh~~LB>p%AQ2~0w6GQNh_{B1 z-sUgF$h-{36vEET30^LpN$D;x$!|5kK~iJqOCH)L|7zIjy}yMl+w)w5koP=n%x_CD!EqLN)?G`7)@hPfa#omGlBrl^%x{&MFVSM3s!Lhn^1I^@^y1KUyi&J2j&%(5 z@NB#LJ7pmk;RW{mKDWg0xwkp^b4%68ni9sf{lTf?j=w=ai1acVlzDqhNh3I-ijb4|WEG z_`w%q#<;~$LDiR<_2XKDxM}kqi_8lIPdqF_(dZk@S7<^Knj{0uaHSCtz9}m&35i3{7OCKdE<9{;+&42n z?Xa6SoaahS@rG?opcawDTsN#>XJv!k#A4~$TDU@`=}X4@5|~w03(lNDX=QxvK6MDw z^sfLY0wv{W~(KXAX^~ zAc0JCv3!4Gw#5Xt_JrR>UIxk0Gs2#heZx(3%KL5y4GPnC#XhV(ffH!WR9uVo-6b&W z7RBzG{L*JqEH`Dj^TiwNgGNw0K?J8GTCeSbW<-&Q!MuKP7rg?R&x#GE*d?Kmd(=c> zf>k0FOm9lRnEE571*;wKuwj{4i85D(H;d!-5*=G9Ti#uHg;~`wO%xG6< zZ+Va{Qm=@Y)qk3)v25CK=4|hZUuRc7eyPEOm6gmC(e@h-=Bf^1JRF%IWRzdteOZE! zDy@Fhg8yPBo4t=B6A!94rasgEqwcNaqS~T1U=S4%6hXSBq`PZCq(r2Y?hp_G=@1wY z5v4;~L0YAe1_9}i?w0Ou7{+f8Hut{w-uL~!f4)EbF>{=A&W^R$Ui(>VJ&WzybD_p% z+gEdijPIObu)S*suI0Y{@z_|#Hwue#)q;dZ#syM`rwl$acFPjBey=|lJv9cnlvEUrh3Lm+1l;A;ikKmpnOk^&mIcrp?zH%aP4NL^1 zZ@uTqtYFMb9o~%JX*&T{>P*BzqSH^UC;49bBp(NC+^Xzmlb2kUoV#GcN#%^xrFKg4 zPK#Z!j6OGXXbK9fLvJwYk>JzMfR1NRkZ3oqci+)xcma%_V-h{fF8uk$P zDSLxJXj|q*lCarqrCPV4g5*V;+vI;&PyB;#U^8p3#@-g)@jo|2xnyIsR;f5lrikYq zmkUYc4cl4ax=Bf~z|Rf-^uZ>3C5zS?m{XagvOX2|17yz0>=k{1JupP&VB$uhD=E*{ zG#ISmx*V2`@IN~!T2qHH(dIR=-b^%VaP%kKs}^ivfv247iAK?z8a>^ zxIv#pu{dO3P>>MnCW2l(%d}`WMXNE{-K=$9t$oz7fiPuxY5>H|h|B-Wt6HZyd%(5mlvplFMTm0KAUyn+^*M9H1Kd$#9u^t`{3e%nF4n?2Wg1LZ8478gy(p$ z^M>B-LTBi972&!Rl~I)s5rx9t5vT*AP>dMp>V3hKxn%_%JCI%Uk&s?_Rq&n4y zUd?f=r9My1d+WP_IfRrsG19E0F|37JlxIS?^H6eMkyr3#rG3saZ(xlD2l;G2`D6Z1 z;%VeFq-_BNY-deSXUWBv?$k-4j*^SP-rt(cz5lyC?AzA&6{$Dq8zGlzuNnfsM5JZp z>;%{x(kBKdD@x4oIDbQM|aPO%r(MG0oX4U7f;wi=_H zQ7N*{d8$yuM|l_QmV(D_FTWwDZ$!m- z&JC?Fh8c*t3NkhucIj)p@a-PP-G4~DI6@Lj0`c*Mt8_wYef z9Igu1w|q{{s13d2l^?MT*;(Rs@k z30I`Bomo=oZay#TqxMBlb9pmeU+c5`hVE+2T%>GS#OnIczK>F_t^gNXRZj3SSBs@u zD{w$IC8Ta zg}m7^hAquwj#Xkmar;TqTL-RlVi-#oE{qQr3B7wp&5sh8{8%-mpO&Kdg#%a>%~J{FGf z;~{W3;yyJLJyP-~m{LFcvFAHz#|k2iqf8ernRM!@qIfU{TieILLDK+_%{0%*VyueT zlwux;+kKpRHK3ov`x1-Yk#0pUL(og>>L8bu^k-SKAs}Uqksb6N2a&ZYN}}qU??+rV zY}{*iBwJj|tCYd{MlTO7lmBAXCNfw2x`&eq+*=s+D-tp|f=oW>tFU&nK!87$+itIk zo?_CrMifROYqo`s*?LFczQZr5x%vTR&pa=-dsOEsM>dQC;ps_`7Xzx)2?5|fS*s?) zEYcd^ht}XN>wVx<~tcx$E&@nwHi!& zlC%YS8a!sV&zn(gMW{7S&R&tGkH3K_u8IfmvFMOh zQ5YXm4Pm{cyy8&w`S>qVCYKWSb*_ueX)`vUu2OMu%#7NIY#wfeydq;L+vhmI$$aTz zP+N_{azM^wWym7!!I69I2>Xkd45k-1-M~vXVYpF6fck({#MrJXI>msKU060BRRS(_ zeVh_H(Fp|o!rqe$+A+LO#~(49;_*Sds_l>X8u&!QW##hLwYzTija}(_(p=w1H#S6J zks=+PYg0TmqcgY?$e*rZ^2{>vWs^;xXY~CoO8-#inUB#Iu-FxYah>@Hh2JNOpnrUk z*_tw%p?`%o)rVSmn&+YKZVk!tGRYJL<}ID{w$UQ;w8SlzRPQe;N`_r9vc_ZyuJ^%{ z__kFc9$#`(ylUX6k&ydcu2l3WE0?kP?lh|IM$u&kzQR#67c>_*QL-xfb$|UJ8V)FJ0LWoID1c6+wGlU zcR3CL^Pcy%AffNaroyr(H0*VjRoD$7Uay`IJmCW&I$$PsFk?dG)kSS*vRYQr0Do!n{AbH57J{3RBRb=_(Qp-$PzYz!*sT=xwHCG zt)&zD8GZ~mdXx2$6{kF(!p&#nqoIx{Bv)CRiyPEYp&GMk9royYl(ILAS$FleD5WJz zJ`^_%QUqDzIv>2guzZPpy%93e7SS!*&9p-R$>WMe7w(XsJC5Vl6*O*56>5FsHWIVV zFi8lYTacHDz;5%iCX1I=Pq5nDUs&x_mJoN!_ybPp!}&wE)nRihsulKhXTen~&Y3k- z;v7aPIBuGE<-EfB-gmbMH}h3B{7Woe@66UC1BC^^mVy37Lx%o5t$NbYm>H^9SJI{{ zh~^UuLfA`JfpXKftCr31pDqKRtMk{3jxUmt{cz_%CN!Kh;og{-&@Wt2n4H-3egoW# z3}JU&2RlNkP&@&EJq&?ee)cO8Eb`vx%BVOMd5~<~T|K@{=LGZ~auQHVz%%4+Heq#$ zBP0xb!kr)njXUfFdNoXVTGnP z%ZK!Q@rupeQ^V?d-M{6GN)J8NVeq_D?|XoGy&ken0L&g_0Ql2%o@%vL%Yj#Tv<}z4 z+eGn0%b5P^Ard7f?AEiLRUS2zqO}Agtmot$9CT0k*s?V5b-+}eF+#@7HLm#HG$(!* z*y_ckoPgSFXy=Ty@##=i-JF=gW67&cDpk(-UUpu~lT}%;alQEI=lMUQw?Dz!zo54u zh2q)YrBEaq{kIefbEysh-U@_%%b=JW==fU(fs7TaV>M9MBm}x}LnYkA9J<(WZ0GkC z=@#}Yu^1es&RgF&2lydqB9uSySu5x8YSTD^{MW{2Sv$#wwvHtf<*#updQ!=$v83M^ zU2f*=>5GS5b07x=mmx3$ZRp10+KcEOXK>VO0n&#L&??9n6^H@z?gyokli*j%FhMD0 zaySM{<^B#EH}kgh+VUE8<)Ne5IuMf z%p1lyV6(E+z@g>9Tj+(J4Hv#0R4wq>#A5BmGt7wL?5z4bs3XjDjh_}d7z}ZDl~CR@ zVU8gMJ|&wPQN9+)*Mshq6o7)=Hpkf-S0BG zIfznR-O7m!M70qX=ms`7dJc#|UBd#(qk0L13@Dr(<8rO4+}QxzO&Xnfy4PyZ8~D9h zIOTd>GFE-Z=+d3)$^HlO&Vuho-&Tt_(S&$b34dx()CsfNlj?vn%w^q`>IClVfg~P~ z6d87sBAL*l!5xnZb8Y&@tb)K*A6@~r(07T$F1ETbz!jllfxFZDAv6CGW9`+sKvP3% zwh-dd%hhG?w=gd_-D;L)G^Cj=Pp-l7&mGsIQ!!ON){>z^!W2a!O?P2@oM_~rVAhsJ zG^JEtqL*of-Ar|cEBxiF3!N@6NoCUE#x`J>{~YhXOqMp9!_C*%d?`Q05cqo#Bt?0? z3}|dr-8MKUGpl+X)tjqH(qad4rF6Ph-5x!QjE5pit%kSo>+uQwUWyTAGkDcn0!>f=f18>}!rFaCkmMRAwW69i`1bH=A zf;~w>Jvb?^@m+>LmuX0ORNsFCJ({)Lgn)^8GEio%MxI{D`dk^?^^0f|cLaO=n2B!| zHw@ZaVdVRx`Hlosb;=YtTwddo>hyI*b-5j3~Lu|xZ zF0&83a!mW{8hvva)I4|C`L&CEcndu(BKH`D@zAv;F+a$^ZHl@+z8m|(Xt;2;`&c(_ z#ec4lb1d=kB{FZIH0um%Gghu1s{^GI3XTfmec>ji@r&)pc9B5qkVO&wQaUF@CuI5) znAl@9;W9>VvUg_5c2}EU$-$nkMG}FtDKhwssB5`dT!!^R;z;J*bUw1m22r%aG6Zj zd_?wb(n+=5c@$nacG=n?HcSHC4wAg(RM-0wm=2%TPu>2QCn8sFfc_-f7+ZT2gJlX8 zGS*&T;g*2NwY_f|NURupmV89>GGr-pMndjcU>`8`ed`dmz8b~=bZYWP#9W^%`Nr1I zFekH|8^8s~h!px7h+6uG)qV^D=7%N~~=ii)+llB71k+T_*8` z=a*f>K%bZ~PY%I$gn$L@%jb_D?13=VGhosBgFO>%Hx>kKAMU}CfEJEfpbqDLJ{j@o za5lu$G5vz2)aR-piDvkQ6GXl~(^S>(T2#ttLDd!#{uQ@Dc60oZgV@#Wqx!edYBxlT zdc{YuujA{&?w@*1pJG}T+_3ThtNjbQ%InlXS-WzM)HL(QGiUlXq%P724D&NGFgg-k zr!cxFT|rpo$5BHYn$FOI!+WF0dAEM&g^2yUbuq0xG0qgB&^>TE`R6|LI=fth)&!QW z8{GPARB=s1ZAZ%gxS@=y?k?1gs*+Oc&7j_@??S0z;kB~CD<(?&pWc6+%roRE zoqRLD*W#>R!L&n44%4iOLaIV7$uqL3C3OXu@Z+Ze*%sT4bLVY#9oLx}gLOyoKZ!2+ z_!|aK+mrNF{@aVl*XPd`uiJgTE^BdTj8VpmaHafJLH_0qe4cI}B)Xx?7$zN9!|tCf zLy&q{EaqNXQ+L!W>c&razuxeK4`z`6%e+7)yx=4Yu;w|ThX+Nvhx-6a>VCyd{%51i z$!jZEa!Ufai+og7dGX3__k|?}l=@$vjZu4f8P$PsoMrKiqiPxCrxZsW6W3xfVV&RL^+}}UQpWMHeEPfr+kM{#kPc-sV@vXMI$PqF zClAz`m=pNi+s(+{m$w@~nD|X-MtR{*=HKVl+{JFCzY#39=sR;&_*bKe_U?6mZl8I9 z$7qnNm6;48%4@58nq?14J{?bP+zFcKxxt5<-6>S$oOKqhdX#@J~IXLYX z!;cz3O7?)1#1Va8xsVBAkj?Sz#|kXa(Mfc7_YsD8QRb8unp>xGaMxy&_*vo^A4vqX zU|G8p&)yS8jljGe=DTxi%T21bFVYdu+?*^qgVtFlZpgI0Gj-&6kTyWl#>IqtfxA`R zVVecAjtE_-S-;gu*V=~5k%sC4_YKe|1D^78?jg0z?r@xX&V0|!dY4h z*)TZ-lu-L8oT}Q|b`F#X#)bb4Yz9n(e}K)J3u|6fO5muH`T-=)54mboB+bOuM!Ci% zV8li`vajfh5CxaH@x?1GOmA(niJ@R04SAruO|ulgw>b>>XBaCI3-6H|52)~w?@Jf3 z9%Apb9~~fe1CYic0Z^XEEa-TP6 zf@3qw!k>P$g~P#4CE?hkyqleOS=sY1PXKwE8j;6nE_27QLU6Y8U3;4}RME(P2l7cl z+o#z4Sj1eMy3+i~n97Z6+yYOVSz7&;1USPoU1DC?Di=6+$o(QtXLA*s;B?veSdk7j z=F(r8iWqM>p5~Q6!)D5@+>rc;l+nH~3dWa|d%PK>3x%ZTCT7ZP>l+4wHlZWNuUi|I z`4#DaDCqRh;sxRQYEzXHXL>5uYmsf$T@C;B|iON*)-|(S0uLo|Ndyk zt`bG=>=I31$y;6N_kAJE4H0MAc8MOB-)`ZeNXq!s<=ZDxC#D-vYxFVH4gPE z0Yw~L$McE%6b)RNPn0jXWT7f5&qs8>a|q?5^u1A(qgh{jpd?+%exIQd8l)kQ18vBU z2LNEg#gA#w_wwJc?{pWtWkx*HMBnBb#A5naviyJj5lAb6Op`hSj{Ys^f}pDSpWl_A zlV188Vm#5$KhgyMnHaDCJ29T2C!icE&LRe+D*)vG8+vmUhoYb1+aP!&Gida?^M&iF zX{RJz9V5mG2{dxezS#x|u(UvX)A-*TR0$qu%k|Ek^U{>DV!Nm2nmlFl>NN@PdJom7 zAsEJ#Y~OY+x(rJaw%midB;F4ng1gYe+v;sZ=F_0n{F9Z3mrbGj=f`1@+SniVcK0(sr zZltiu;HVS`sdI#`2RdcLy<*7W$Y6QV0JHJJoG(!N{0ZRrM-1K6Hft+8aOZ_rez|J3 zbO^85is*q|w`FL{o2T5ok72>BPA$JfJ8({t`iZo)KQ0 zoYw@KRH-O(bVL;7q^!QYNK%|JW1~)F6eB)UBD-YP6r66dcD7#Lx{9_GRN@g*1!K~R z3G6Mz1~3m4kZm1wn*=z4)-P2auy}KK?!wMa!6nIkgm~?(_{|5hpT>XO%0?H@+qoY} zb*!<*r{%V_xlNe$8Vl+?qwakBj)rdJF+VJYI4>;++4<8{H?Hzu<_Pk~941ef0orT_ zKx_TFW0_lRrPk$HY~~0u=0I{@>0?E7j{5Vx5f~N31cdEJIt93G-tTU)A4k8FG0nWx zq95+^?ImUi)#Y1gi;;R+Y%zjiDAwWD^O)h55N_@|-(OT2D5G4{u?emR6< z);1r`vC=+%rr00!KwDS#Nt;}Mj9c0+G=@f&$F!F^BqO(&+CPb&LReb3Ue5ksg+n%U zzF&V}E>TLGr$^e~=ko^|%=I}%pLZg?i;vtox5=A}9|xUxdghj-*k@Pt!pIjcJyBq6 zCiiOb3sZp2z(_OdDECP9Q@RnhM>s(@&Y7rZdHIrq5(c;dzMLR?Cny>e=Qv3yQt!ar z{`tk%;sRm`hd=vP1cA|OT^SHq0JEw8Lgn_2erMk=TwjsS?niWS1-9#U4$<{KTp3*+ zW(7#g)`e1%VBvEXGFcfBevk6}k3Y!t)4H`)tED09(1sT-%L}_m1x?_Z-{ClW470s9 zvK-PpXgXo0X&Um$@HwVjOPtuAh80DmB@5lYIOF( z9`+FBf`;q5Kt5-K3EFe+WQVN;O47Oe28sBg9`UDK+Hu5xj^ zd$pZSOnnQ?SqlCGAJgd$pV{t2+h~UPCoF<6u z>@0lpLuIo&r`1DB7wmd^O0#VGB9AJu;&OuT*qKiklSDErl25@$~w z6H7UB1AnEm)vDhYQkxfC#0U(9HBkRHARk^7()H_WAbmbXqQ9cA3V|yAgioyv2r!$2 zznabJ#{IN!a}SM0UFuM7oP6(UOkv{ffQX){v)+L#je^vhlMWZ^#6H<6i7b#Vtm`C4 zZ^Ej?Hj|~4Qix3<9DJmA1AA{uFnl1^HdsZfm7|uXqH>ZTrw`>3dLOubWQ4WKp(7)h zyOk0lSHgrPg^Vk8F{!|e%&MTp@=13}vyD^VAZhq=c6B-^Tp>J$Z!%Q=ri!&aK3bY^ z*nj;2&Bn+%+@!7o$x*`In-o%|#JCOZbR1ATC!~no_aXc08Ztyj3NP!sK(f2$kYr1d zWAJ;7lG`&Egw79lgebR8m`mPND?lIMX*doxdJ)FU<3!F>7rfJ;fD>4IFI&(KR@uJ3 zg}<{8>OW6Si&<|#ZhPbuhbMnxCeZftv-9N)HhyW@24_Pd^K@#8RovLNZlE$d)IJ`f zpw@b$9l&vu7(@06TUyqL1FFzHS=I|rO{|KVjIZ674v6*g!;`L3C%P*X#6*Tf^@jVw zQguY$fybiDQ)`)$EM_YEi`}w#U4smFtlQ9W+xc1{l~xUhFxRJ*6CgZg=|(bKxZHol z&ySCCAd@9f6Ry#E?mZ{XSRWN*G1fCe!iL*@8Do5Tf%-TbpQ%BRHNB5D+CwJIJ)1XM zGv4il?;|U&MYIPy;&* zxkB)$bODDT+;nKtqUtl&=!Crc+7b08O`Gd))@}Vi7#1jR9$e_-4emTUcnl`w@*689De`g|Z{|?$^EAGr&&J|+kx}&@_GO(YWp^>gScr9s@d8c&! zSv=RR&{6HP%GAxxEusBoTg5AI(m4`0+uIUhAl1i$NGI8n*DZ2cRH}IL%5af$RF(KK zY`6YFYC(FPvl;p@_4^?1|kg~D@+p_>m4 z!q!*>5_T!mbq3rb+AfUQhlFbKX@5FeF7@Xhj(5>ruMy_JEEVxOxEoGde1Jgr!*J^i z#RWCLBB}h!02nwP0BYpKs}x8-Acm+(l);uItNTz_6XdV}!!l%fDYMRSDGn>Q=OS^Z zT^{XpQ4E^Vjga;tihP!G{(Fn^w~9q3jiCV71YCsK0R7kk2kxrjcsK-TzGGfEl)D{v zsRZD4J4N|AMgwIa-1{Eu{=Gvh7~DL5pV$_7Pk^cCt&4yzXTk40iy$!fAk*^dx=Yqu z!tuwB&|{vFerK(Z*)?uF_^N>xk}_AKnf>>!@_CP5pfQM0A*8Fd%Syrxmm2O!Mij4M z6#RBy|M-b;E?wQuw%YC^I!gzygmy}*8M?8`C!)W53IykQ@<7@ZzuZBFd-t- z|C$~9uNPxa_$QN2h#)0A9O&wJf8&JoLt0k!wTeQ}Lk6Aj0^%VLB;kzzPBF=Zk}FAH zVQ>PtV{``QQEWFQRte%5M9aKhz56(dA$p_}|qv_kp`#0|bxW* zozYVC^;>xaCcPH2*OBz|Q(_gU?V;$FMSigF13$$1`9TfMT9Sdapa%FPuYmZT8$rK5 z`XRH>)k*9YL+2*RkLH!!3diB@dWhHIZJv3k==WqqMdsrX(I|LAEw95qJToUH#F9qWKF>?~Dz|?+c^FcBwStG;TkJJXIhw|~mJG~wK!c*-B zs6W25vx@&Keh*A|w~JedE-Q`o(?OZ)~DO0fny#Vo-3mOgp+&%|a$r_Cdsp8wiF$20Cbx?(}_G@t`(P#TSG%?fSbl4M5^dMDWbv zbvO#pXtk>HAeMLh5r5GBy$U=4uIb(cdz4e#(%TgPd^{G zd(vOgapbb$pY8t3;}B?475r=}JQ-^}zAOG!8@Yi8^N3m})Q5*%_Fm_SNN;J<* zzxWfpmOsyn)+=Y{gg8eaW1aCh|42kJUR1EF69@*z?_nYVCgz5FhTjXlY4D|sS{&q33Bs{jIpLl>kiBK7H#oWiVrH~l;9oF=F#>{7zlvpywS6hB z_QSKlsv6Hl@I3Pao@d$y_;JvBCW)di%TW$z#g;5@=9-mo(ti?bk@VhGK@y$T%`cmoY@ZAOgTiVYXOu?Aw-U4Hy zop!vX5p{Bk2L7yS))Z(5OE>%gH2BAB0PCru7@AO2gC9ZKA2@jbZ_0BsO0lRug*U_X)O zmfvSi>eqY&5=Vs4#dQfm(getPFA32=?wo%+c?7 zjhR8LRoU75VE8ywz$7qyqXPf=88-!hH-F0Vd;G)mud*>CQ-|nSlq4>S*k9qV!F-F` zG5Nv%+EF89DFN{HIMb&d<>3G0@{!3AWDUL(xi$G+FT9Twxc7?Vh6Ph*g2fDBk^-9Uho+t&myx>rze$Bcd@PD2qWGN( z!S_mdz!-uy3j8R*m*t1s?z9fAE&XvJ;TrMJDz-X5;}grIf2Kvu!5qILQ2_SY-FTow z;z}=`y5Pa{jT21nq@L|--KQDiTX-S0_u4n*Jy}>3?gHcKgclCnvd8@Iy$xXK)j0y z?8ph&o+regh)}8agWU~$IC>TcZK?w#a_FxwaUYUz4FMuKk#5M`@DGMgoPeoOwm{}` ziFwGRHdsRSbb$0ss|)a>f=s1vrh-;#^pxNQ1Bv4NjWeb1KQUx_cV3)N64chG_;QFX zjHt@<$ID~=mOpVOB$lk5Y6Lk5e~RB)`AHQDXv{#PaN7}aUeNZU=f6>renq;yW-&?r zol_Jr<>3nuF?@WMWMxnE@o5VaOS-KU&_od-x88Vx&DU9a5jmXz)cI(Og^K`FC(8yp zZ>{gT&sD*fAv&n)&YRfYfN`5>B%6Yf?n@tqe{ z_T+v4J`4Y2AMQqs@paAEi`w%U*%%Za$t7=ObWuO7W$La?x`y-0vYkW`A$(;B72six zNN-d8O=jF0P(dJ%0Dv~6{ElnEwsww|Tnt30(hPRk}@ZFKzR zYw5q9=G0t|OF7wHd$BIg{!H~eeAP@XP~~c`^d2cDH>gVW$E3*B?dnDU&3a8P+^COa ze2?<3hAIrVXvpGv!2J-a``7Nr(GXrpo^o)SjAUG{o?S6{pu0o?po>CXP@?mK_&DvQGaOh=LIogo6wX5a~`_2^W?hJa|*m(dUo?&%->Nhi=E+ zY6n&UCh%YZfxZg;QojatBEoLOi*nx?f3CJ8X>nsdsy*Z3{V!92Y}O68a3Ne^J)bO_ zzq#vF!;((khEQ=7E{-su%woSHo#%zZTtEQN_Syl+_uz$NSc2<2WbLiz+MWSB0wfUr zG$b;D@SIeJy4ogXFUi;DehzMNHow-x5){eBmU}kow%AZjF;!oFxiJ+_w4K)Uahz*> zGUiZ9!)F$|2*^o}Mmp{Fivh@RHy{sH} z&2)HTsJmA+&zq{>5vo<*E3=iO5V&8rHdh5HEJ#`(-+3D9b&4PJp?faEAtnk+#DYzo1l2t0&Nv%x}SmaY$ctFT5G4T|7D$$#Od26CL&t!=lUgI z_gom?0qUN{>NyDsYogTP7}wpj+dcN5%UexsN$W;7nL0qRv=JU6!fE}Q z#JK3mGMDI^`XIV-;LNuf(>mG*DiY(<`CNJxa~U0U#z;l3%i?Ea_@qTNpYR#Ba+OgC zTs#r0uSmc){&VAoNB&`BB}F!QepA_px__Ej+m*kYSQWP~pKKtIE`Y)RGOwW3P;jjK z&Age})U)G`1!uG$Ryz2IcIut)U99|Dt_E z7)p3Cgoy)5OiGFEE)nx6vcpLoHpYnljJnpDa@(;7iZ=kMRH&f(bWm#yTBaz6(B4x+5eLO#{Vw_H39SY3?K%uIFY*rwfCQs1yJ;`FYb|dP%4i1#Q*xJ{ou3D~{VUu}xkI(RXDyL+{io@Kg88 zDRcmRbh?_I?H-(>_gsxc;{1?XliE~|C2dKG={n2IOJwY14il@FwvEZ~4g{fv4k>_$ z5rh`8mIFNiG0QgBJ!bd_PP!Zg{;GEwqjZPJ5IiX6KY37&6A+Xs<$~WSQ!GLD*UJM{ zy%O(J|3QB0#_p89)GccAp%}Rwl`9P-i?RawbT;xaA7!!j9`uF1Yhr`)O!ir1Pg8eb zFugYr@A%->RqM9c#u3;gQd1NkEq^4Apl)#jdl$+yh&mL2wd@KrD?qVCNtx%4PA((u|Ye11( zY|Kn4nIS5H0!TWYDf4Hv%R92+;#tFWSKnfrl9BtL*Yv2~6_4=#gkm*_I!;CEwB*&5 zc52{KgX#q|@i$jTGW6OV?WmwE)b~)~5S|rkdQ`xfm~m7|n(k~UmM{A*PJX%m$#N6s zAc^LOSz{;l3L_neqgUJ|k$c0RRkxU-rU*un?91O7MWl9p0FQ>o4;~GB)!X|ascn@D zlA6vqLXq#W2AR5sq?C**ZVnd=@qD6@S>~)$_o;W_%tL3~xm{8ahyL71)o_{#k)BOP7GHuU2|dl$P!aCgAHR_{rCCsyokNkCQk)FmHJ)`OY&gnbvNh*w^s6GHxyrLd|(FWcJrf%AR1T$NytC{{`BcmLI z#-T&J2iIhs`R)Z{e%x37iu6rr#=i?q#**gV6WOV&)jlh1b+flb)FLcIK4X8u+Cy$v zRGsdpl`FGHS!*)-O{}$tB8*bA$>4eBR(}@?!<%~ba|!ip?+$y{u9$ZX)|C!*3BEvYFveh+5tp&& zcsov~Ql&I_^z5yM)9R({<4okDXli(K#MrQ1rD^e|7c}9(lrWdD>3Dz&mCCnQ!eIwq zVZiiFR(`V2C{(`K@pIPKwi4^U=BsK>Fjr7&!hS2F3(|@{+)%@0>K=1G`ZShTc_P>0tIF^Y+LiqX@*Ss;jiBnxrg6zK^gH##i+xL!Nv$uUH5Tb| z+@17|&#u;sD7B1>yi|M8w?{`-Z^gkGLi{CQn80f@hxCGQ`m4UAioi+whg^eJ;Y!*f zk4<0WMy^~U#CWEn=uPjnh0>1H&xq<_b~7eTvrdgh(t~%I z^zR6jhjd(wJ%Fl!tOgUaWT$S~3JSA+&IrccVinV5`TXHf5p!z}7FB8+4h9R|T6)u~ z$JncjQdW5y8pA82T(JbNxcuLomAD>3{@S@W`-%O)#6-JSn zvqq+kxIAbLX{0JqhC#Gk6lWjzhoyNIAhEc%Xv?j>W}$dC&0XxLB%3BEF5pS4_~`sr zf%8RcRV&y9_nv2$L{bT4}lMa=Qq?ORW7fY1m_jJ(T9nKTPa(~y0`+RvJX&!`P*L(kdE6sB_yvf z)3!4pq|inYfQ5sTUYALx^fZDX)m-{^R?Koh{D%eJ&A0cxJ}Z-vCfHo==t9}^TxRHv zc=Lfpg`R3A!E~HZ%DYjpFqBX4am-x)4ihnvd*<~uS~4Tfb1HS+$F*CLX-A3KrkF?B zC6w?@{oJ-&28(w{^PI_*ciyI4hdO6XIn4XXPFe`P&l{Z~5>L4?tT|UMLwIY7^tE)m zyi4a6V_W3S-oSyth!$)unalv?&vId!O-%lHd_|Tc>Q(%rNm=GR5TsU|YpOTG?|wq6 zEX?18bQL@{L!(_pdwnlYWLN&P0Lf&LeChUf5e)K0b`xGuG-I+Cmp!XuH%8k%<((3< zfj7vD{$kx-93}XXhtbL-DWtgq=dFElr5IC9mG0FfMG~y47^}hRc}Jc$S)}Xd!qqIk zBHf)1*?i@HH+WweC~sAh#38k?M~8(e8Mi|69^^C#1razUhHFhkyYG$|7B50rMR#;e z-lUcp)!lS7tqWe{*>7L7P_|T;e>1{hZXrn@qSFZ*7?h~JT)ElDs}=BOY7H~R`D5hM zoeObT@8=&qpuZA(JFi5HjF~Dya+n_GAx5Hd{W_l3^>#=O)2(x&NH@+g1ZlOM((`U=14o&>;XnO&|lr5z!523w&`d5E3 z;cu3@$T8LB2XM^I-QBt_l*MfD#eJoia3@`Z+JKWy)7%Lu7?YN~jLgE|D4t!R`pn{jn0jL1gdb9}ZPbUxs?4tCvge4iRf5&pPS7@F$!cTUx-jCCA3x?ETCT_h8O#aY7~ zX(nN7Om8@XK5$9}bQxg;ZZFBH>OiSl`XBbY_10zFkd9h@f|(C1a*B2|G_B{cXb``l zBU`ky=LJB&W48uif&UvUs761DzVKNNN)}GZwKbs5Q2S{auZz*M__h&0$5ZmE;I0`o z7a+HP>90uK^|Xb^ zC!-;(53kF4(Q3^|%Otmb3X~3ljN(W*=#Bwwu@TrP4|Jes%&JIq_hWmYwI@)f(mvjy z^RmUzt}|_L4NlnYIa*b7JL)o*T<*NhNAB@mIU)$<3~FE10DpIrdXJ8{WW`_6YAJ1C z|2RWOpvOqP)APU;-CRQ|fuoeu=5U;Q!qW3`9R5=M-T?Q3kwS;*P#6_5lU!7Vk#)m) z9T1ZxS)TwDn$DgfBFngkh~w&6wQlaz;~~-oKIAQenX7Fi zm=`51j-4>NIS2T7bVks`OO)}zt;>73jy5a`Y4GkOBoq}OKkCATlMYS??x>7c6|Dn~ zdgCra7tRAKB8R!Hp*f+!7&FJhcG2iGA!DWu*E zttNaob&M`AD{XAj&9XhY^c4v^;PONVtPG9tMz%+?XJz0y6Y+`1ews@TJW3s@pu66F%8ED%itM~QUN%g^vQa;<#>w%MZh3Wu20iU<2R8)B2(9S&5Roh6I z@ukSWNVH4dMZ`cDZ9C;-S4sr0S~>5;yn1+oOrLlZVUPb?ys1?(7vFpI<7u*I+&;>E zv=Mx#7h*SDSNQ5(VBbvOS?ruI5v2TU{(-%9*?w6oI1Q(=J0l`>oNZA;PxctP82md!=Ws+@7W`8=pU*AzR|!BC@SKr}+-T6iwnGGnE2a+JJvNckC`jDio74 zvOA~Ky-XF#Rop|JA44&zZzUwCF+?5xr0m+4gHVgPOc}$eY%E!%P;H+2QEIkJEHgd0 z{^NJv-wdvMR9Bv&2b5;V+pN59*<260-0qCbYOhPBwZ1~nr}dJ!CIgA*y>Ip<yRFldgceGVy23EK4^wsv?X*&g<( z(Ww27K>yuC$+#{wnrKOE(_@bd$TP2a1VH2Zhka$8n1~F&55^skrKp$78rL^2L8k~0y1B2y=7a^Xi^6# zxzGXIM7A@CiIMG*hhOOIRy+Py?k(fq;~%xxIzXy82=xU2K=6AYKw(J1?{&HXZwhC> z*k3MnobPc%Jy^Mu{LR^+Z}2qBv9@8aPj_c?{Ls8CE3l*z=asB6NY-Zt43uT1)>t1a z0(LGR^7d8Jj%)QsM1-DaPBgn3MqSm)eh`l@52nFkRKRUY^JwXHkmPH0s}4KjSLKoD z){Mbj)ZOf41_zh+a6I<{^mXt-cyxd+rbn)x1c{!|Tgp2j7Nud&_eoegRPcSEUA(Ps z?;c#T$!mT1uy&OyU(;EOf!jAnIjV}EL2ZtIK{H19Rj?$U=@;>m+06ugH5IdHj{x87 z5hc`7oS-*m7Oc^a)=1u2EFvT@Q8Rv zTP`WBn}KZUBn(uwPB9D4=MMB5Q1%(NoW>Q*gF}Y02Vb}esPiB_EVy8S9s<( zeXBU%P$_2r#>_S`b2TVU9@}uaaI-eWqA*Y>YCz9|%tQH^PwETTPst0DbF0V2l4ZLq zAlJrZb)zpcYs}2q0S5UjdkC-0YPf1Xg^8Wa(_~DVnqm)-w=t`T^ZQBCaP`|o^bz+h z)z}+gTgkDtL!VXg$uvjU!n?)0GTT3MxhZJW+OWf@1#?$6kNS1SusfPppqJ-Y$fg{p zqpp&h>hBd=EJ}g$1vpn4;wdjAF}V)(Aat==tZcRN944ZOGA_+O(v=EsnYm2zle{|?W*5XW?pht*d$&g%8rN2e6P$MR%t=W+_|hR#i2O1tH5Y8dm-!s^h} zw*O4o$DJ^Xi4_LiGwqVy`l90&fpm!qR3#{Dly8r!9G5hR7hXWCfH;C(nix*g58YYg zg@+YbSY=?6^8Qw_@VuSM569ro=xjX&Kn5b=@r&q;-|7qmCc6Sz8Y4fxt}*Z0JOjf3 z4h>citB?g;;`82FUY|3Yn4H7?-fL!jkR)nuo0|@=Ro>Q;!DQSlq7n&DnN?AFr%#~f!uEWI`7Pwnn$r*!{}NKwC=#;$L!F8dDtG} zzUsD^TE-}EkD-d+@6h)-bTp?ZB+2~$Y45GWvf8@0QA$D(1VKPL1u04Ck`$4Ul$1sU zq??Blq)R%b8|iN85-9=cmhOJ`nYcq?zvtb*@A}R;*LALM|DmuR*0W-+HOCy|9%J11 zTGqXX*y>^m=kI#HqM>XxX0Mm7DrvV%eOVu(m?)lLrnZZir?B4*-$dZ+f6)NRP}L}y zd@fU36U=iS=cT04Qs0i0E{!*lnczL06x#nP@qT>~E9%{f*zqZZp?h4OY*D*XOYU(a zA=+euk`F%Zb>!^Yw||mr^-ti&+Z^j!H6j;g+6cS#sg%y)?e5OdH^LzQ@#<){2^w#P zJO*-&l%W(-n2GjyS{Uo6@#r2o7&liEHJfHHNILq*r3*vi(7v8cDSa~}+KC-L5fE0+ zJkX8d=NR&dW3v?0R+C_l`jQ~Yz~0;ivEV;|L4>DF)k7b?o0?}*LJzO{9T?#nRxAF4?{HHlL}Zu?3=2v@7EE&syk zg?=Smi^O355OcLJnXiH<5ABT*8p2{M)=|Reu2Q`Yub7g;&+;s7>nV0__&s4qEYtU3 z+7PdZ#|=}ciZu0S->oEB8A#dWA>rMd%6sIub=O*2e)>smDB+We$d1Mb(l1$crZ{X{ z3VK}TZYFxNkHp!dP);np?4V2_kbr1TG7j~aNsdlL$by^j?I2Gp!BSRpBuH6r~ z`E}5&%*t`iCTC3YUMpJEL;9x(U%K|J4A3&oYy%b~<85$0koc6oM<*Mw{-i1}e{q)* z?yT_K*^TSF<5DCE#;V+Vj#G}fJ8fu6ER;`fy*H2dw}p2b<71XtT;9d)`3lJ09y9=k zFToxRoO1nQu*P@;E*_0xo8dP5m=gA=ADvGc%EqcaMqs97ef$JyU+CeKxd44T$V-Bj z&V>5~VO3hlKMDWT5&Dt_J|)48baE2iEw(SSPcZgzlTD;JcO#j4{GRf*6xlPro3Zsd&#-`QCX0CHfqc^kh-@ zi;bc86hQ*v1XYz}0lNV6P4#p?LKi=Fov}*JzJ;e~yCx#P!NheojBcKbjGBk8Oo7X` zFOQj(I`dZm(stBInBEv0c$goMK7~5*z4+d}ff`QeH@({${M68|`{TC8E{g*{{#~<_DIzh@S?0|XFTrj+0G9$nHl?kVWbzl;Q)+2OF> zxrva;l}CHlzLkk z(P4~b939N;?0x1Zc-B^0>aXm? z55SFl0l&-DtNWrMQWS+D-gZE}J%cY7$(RvO5Pj85Du~4HG5-C6?;b6!j$Slh)XMzS z(i7^_tV06J^dbPB6fF7ZJSPopk#NSgpz+vFk}=O(<6&3wV-t%->NTSfZDhSRLAiFs zcx%3g5e#Xotpl#zhGf20Ca`!D@Vaiw0cbaI&qZKKJ+{sxl+C`$oH_OgYBqGdhUet!SL4mjO|39U9Z0e*n# zidN;4!u2jJP)_r|B;pozTbzIWiWPuoWrffPO{M7=^`PuRHP!Dd7X>_rlcuI6>xa9Y zflABhIuTsC0t}94Kq}i=3}Gkk4)pq?kL3t8w;Oc~-g0N|_~^H=$qbrIz$W5yqbsQ}YhV#ped> z((yoVJ7t{=mUVo9OgC!GOhSFK`fCI0wNE~{`ef$B7G2gh0{{9i`oPPA)n9J(g`!I@0|G+P&Q^Y>%X_~g@A@Na^UNT)Afd-~n&58_> z-eUOF6yC23f-+s!#qoirhBC$mb!9+~yuxopLBac5$3|7GyySvY&sk@K@!}RPPQx zf2*y1pJRjUxl!Bm3WAgVn8dF+4Obuab%wz$s7}QRk-#MlXZux#Jfpu|Bs{lrxaU4J zB5->RDs(t~&_;4W{Uim-H~7W^v2GPq4B~1g9kdnx$ZpvDncYay6_){An+e`PT24-z z6D1RcYL!*=Hm+@-e)wkdjr3p^OHQq<)8UB=OIkRu9dw^JPea_zVF=P%zqs^IRZOlO zNgHJP<})yEDShXYjP4~&ZZc(aqy4f`zaP@p!bQXyTLs>ZP4IT`vj0h&xG2-#p$r&q zo@)(|50Q^q4xBj6S49xPql8WA>lETs_zKUT-do<}zo&+cYD}H@F)crP)mHiL?0o5+ zw#Ss^XHld@l-k*vp6<%m*zQ0P^{>o(`KD0w(-Y)EyBSFp%$HeT$Hi80GSW?nD!S%+ zI}w}iicZu}YHyK@@*lN~-i^Aed-jaWRPL*Xc7HyKMTxT<}b+q>QVcm{Ad6B-vAsfsbdcqGoEVV&Pt7B1q(y?GI zu!+JMz*xHh_hN^AKz|I&`qCW)9g^;s+62-_e`ph2zQCw00{ah)1dcHPjC+r*%t){Ps&61#iZW4Hvkr3Wxc->i0$L9MpHyEJI{OfF6T}yb6mpA5f`V?}|cc~@)C2#C!;*jzN2@z-?{+TMY zCuZ#yFYIhQ+VRiZ7>SN4y6`axFP0YO4QHja!^+yD)Oq%G zxRD?_ybVwC}WyVe8ijD3tt71U>vhA(j?y7KHSE#k8Zll7-?h4-(%5-gTiZ_FEHz6 z3;lsHTNt(^BHs`iIH$yinuzSq_I|z(RY9`~UyXHXcw39l$}(=`iW4h3H-|U(E*e>2 zcNk_K(T#`Xhw4UU?)0r=VPs92W6@IlIl(Va$vnsXpCXDy28t$ zk76=~Lpng(M^}5#( zD0fT)U^_}N@)XxyQ85i@Hx!kN*5-xGxgTV7HDrkhdF)VIZ#LO0P-M9+HCF2=jg z1pEY6xMus$;Xq`UggGu|ut_Rig9x@i5 z&sB}@xfJPU8kZ~eEcaB~>nc8CWbNrmHpJ&MxpVDES2vTZ1k&}Kxk+}IfahQE z5FoiMN=_5UsYu+*phgN^2KpqQ#0MCTpMSMM40N%Eq;^B+0b+$%NIC;rF8-Fp>d-B^ zB=_LbFq(sc444LF<&4|f5hn+REJ|J!Mx4;Z>LF%IkY9?-EKbt=E%LVShhsJx{9iVi zZw=+5t>Dpnm^>5y$m=EzQY%-iXqlge{2gu{`*~kQZRxD!$5@7&mwf!EH^cu2Cf!8n zPao&H3BP8$KO@O3DGSVT^o&3bfF0c*vyuhn^Rr2(IBX>6NWs81=S}pZt=^5|Fii)p zf10P1&X#x z*C6{Q5P^+{B_~O%kL-63rHGmP3tY0H;=W*rAAv$W_{-UmU48iBQ0mAej!1FN$(~^* zc4|r$Ug}0`Cs{1^Yi#s7i;+~Y*p2iibOO#dMU1QagQnrD#}mBcKn$iz@@384<@=P{u_JJScqzH(W(nC<1Wy1HA_yPQ_XW578%!YJ`v2d&1qIlcxnpM$`U2PCJR=#BaN1bT4ayty zyK3ZIx4N}Mr;Xb`6y&zfL#gbv4z>iKzK#p$(sL>WriM~{te=?ZTB-7D4ccbRBURqP z)QBKa9+4`m%>k;|8N{kg1BK#bNh;n9v6cUHKB{g=L31G_Bt-{tf2VDKrJzP+0lBzI!g|6#e)z{7%0l7UjRTy(HsT z0RNVlx;HpxA<*ge`SN;txx)tztNSi78zaU0GMKM&K2nvZ>%R8j)EuGx%5?Z4_Hm6K zu~hgVp6VU*=fdEXqXXrdlP*!M0{cYU(@Vil$ZmALf;t+Wuw4G?J@0{HxEiZq0%$`?fx$nk6jO!5Lq+~GT zXlI`z?Af>Z%yckp(U2CRq-$4y{cbdE_g*yJ2_#>Zs*LK0;;!>na?%R~K!@*Q)nqvJ zL#f+M)ihjf7i}f>105|&X9^}3w*rF}-eq~cd$y<@A4UJn%Ke=4L&F}##S@B8#B}X! zDv8V$JETQbXG$f>ysl3(?B`2E*g{VjLJ7SWKT2$s&VL?pJWf&!q&QQmB2^_Xudl7Q z4uBY-R!QjMb_QU&?;*CoD6z}wwMy3{@ZTzX$(XNQHI9^k@L=}YZP>1$WUG;!=>@28 z!|HKvVw4WQ5a<>X^KOOP7yg8+zTcN(c_j#c0E zP{UA2;ygM4v(uQ2xqYDkAq+L56TW^RNk~o0a7X+CiI)q!fbxLAR%j*@^!u0nnf1xN zy@tu}yoG6Gn}|H4HouvhSRe+_hWVA zPR8g&xG@JL5~3ZjH+IkSNr)|ts^5|JPvxuc0KtV412q|5vaACPMs&zzPWT3t64+*# zb!h)w@F}{z75F{v$IQF7-8js?w&s8@RzeyoA}}@*RJ5#VoJLl0%k4ZhINWS1qd2ct zCKsQh1p>GSEE%*zasY!NQe6m92tBF!t`nCWLUml1jCRX6XN*S8j2w}Y^o z%zB)nLWT8Vh;3h`{ZK(}I_qSSwsGuY*UpAePf^c-A;faaoc*gcpKCYdZtmc!#l7Xv zm|G$cO~qqKw7~IwtE-OLH9u_>$7a4x^l744F5V4B;*t9_FWQzygi3kInLSG^S|rH; zuc_QY!V7!?vuwW4s=vXM=#*OrxMXnAKRRE3hpzOv4SBx6SnC{2>;#Of&gC^D9vIfhT+_%YuE~-z&{bevA1cknZFt%jQcp#6_Rx`h2jD^js;C8`!HVx8g z`0jo`;lg0l`R(9yV1fSYDbzirQX~;PFpeMZg9c&))%{T{Z_x<*p}8PVkT36b8+)xC zAF8-BlBV)!=U(MqUe4<<&4##Fgdb<%0J5fe{@{Y@eNYM0E5Am8OS|BEE z@|;Bfz5=zeZje-53AR)ChO#Ui*$F4C%IRr*sHDr>q!?9*bRm0@XcdPYedzM@sy z#aVXr>e*GnC!p77TpkXJu=?s4yZ<7la2H$4Tn;qz8f6s;|33YmDwE8Lf0F+*Rn%77 zF1qdQV@YKy-ZC!Tld-hblV~Jc8fQc6_H7+wQuc;|h#mhQQj^zo3@@<)cz_kquKa-& zC;>mvY2>vlNvR+L%Xf)nH6O_PX&` zH&pXYW~4toPPR8tlr8Rk6WUZv#`gBj7c4GeE+Q8e`)p$ysSfnhDHihP6t0ZX7YMf!5vY&6jQQF|{ctq-HXfTJGl0m9EGc z`bckG3I9O=QsIl+#O}Wz2+1VF9{pvUDMfRDq?3K>?ku7)!&eUqc^=FYEBWyie&pyZ zf06CX*hY!+4`lQ#Zu74UQ{uNJHqmL|EB5%-C>lw=>j6`Hq;+alnI|QHcKl!_^kvGi z{7jIZimq=t2up9vI*l~6fMb{Im-}(fs}|^ZQ{rKY#lAmAPA&F}fgPO#hFicaN+HEtqDLcS$IKWD4F$&oFT4Y z!!#nU!^s!APAamT6yv%h%YUGF_SSFuszJYI-+5mRYzd*)q-mPz-f1!8HyYNlN~AJ_ zmE~3>xnqI>FDOt}-*l(uv4fS@iLR6##d3rSS|w4I*Qm%Dyw;N1e>b-N5TfsbVtPZm z@7z%*Mae|Zta0yzXpk`%QFJYY?Btvcaf~WE7?h6|IIqmt#VmZ%OKovXqxX{y!1NsC z_d-*IG&OXhI5<%4@f4OEr$Rjw2|*Y^D{#UXe04LAVdW)e?P6ZsBSLJ z&Bv!3Kp{5%svMgfKIu^g9{SgO$W43ixjA+Iio=Cn-MXknp+l2SjS9woTj! zwN{W9^TXmjX{4rU1=>vrt$3GNqTd}7&Nc70)JGRiYLHdMMYUKc8!1aqkC3&*Ky-vK z%ade26r3a%QVlWnk0dK2U;8gyG!;t73~rfcNt?~Ekwf-PsV^ggI zH|7$xNArh)J4CYtEKj zG@R%C2(~GY&eR(~bL_*xp5l7WGVL~0o)a8ZdL0{7Xq?rX9N`H>i*tH(30b~Z`Td_v z@FdRU`;l8j8A{#Z#ci-VYF=28%5^(NwDb5lG|b``A$Q;Uv;()6)k@B?^u-<%W|sxI zIS2hiNuLROEk3~$R83Anv`%|Mhr+CGZjRj=j=(sW6(K@x^zw#T=+<7tjLhT(L~4gE zzn)aJ59!b);$o1fpY7pm>Tym&ICY<oT@FBn5(=a}X8J_KkTRLmY*BAyg(-+dKs#pTtEV28 zOvpIrbhGS!kTym+5$p5lEofhm2#Rlk2<-OTG$P$)O4teZ_(ZtDk%ytL9K$j?=?zT3 zzgU{u6#gVdLAKJKHSQvrJ2FLB8jyXa-xE*_G4`=+s7+d*((1zzzri(w?o#;y(&7S~ zz()%pV7gQKmIgnaAmYCE6ZqE^((X$leJG>{|x6 zSbs^D$hlvoYvYtfe#=weaic6C8Qv`!-77$`a2>0dNA=kAdHGcH_qi!%l;`Aaxw|ps zx_b|T=T4t%wY;gpDE)r=egN@IPl<&EC+Kw;Gj;FRfJE33_x<$M6#$U0Es%U6^_)YB zK`|ICBnuIat?P~uQ?sdj?uPvYWxDi;ctJ7vScOCI4tr$kJsojxCB@c3Rmn212L;ch z5?NsQ%dm+tizO0n9W40mWJFQaP|HtE+j8ItvV17|JjmosVX$NB=YR^!GO_grDaM6* zPQwEPnUC5y=PTJ37k9DtPU5)j-eIlvkm%Nwhp~`VdcUc2 zy!J;Uk@m_x)82;I@q}?n`T*+JoTmPS4^ml>=LzRaUkN0bUrobhJQfE8ky4_f-oKj= z^n0y4HckL;22kFhM*b^@_ph`t*t%n0h?|PxlVDhD1AgCKF?S)Oxd<_lSE-waAd#4B z-G6dEDzMD~u$kcD4DwNsHB^MmDy=5%ofJT3O#1@pPb8_3U`+QE&+ zs5nk6ISHI@g7&4?RryTEiq(ccsgb{{$#_@4W-KJE_V4iOd~H}6^NDcOjt52uj!I1sqnVaxS2x5;>0D;1Ro-4AJq^wld44d&AJ6?@|0 zddMejA}1=?Tw(x56O!nGUh6&)e%7QXdY&CfpGRr$ zxA>3BQ}1|}u82obnw5Xz#vFJ*euQH^ekN>E^sMi6hhYyfJG-EFg!Yv`fsUH$&6oHL zWACQwZ0`g~q;HRunK;3mvDbZRgeiOXER(e{H#p(&E#*h9@g5}nCQdApw=9^Ra~dL9 za5o+k72Ks#!h>J0gR4QaZlb8l9-JNC4KHcq{u1WgslrgPMM#5hb*R||bE@c+WI&wg zm3wr+RmqE=-G*y3T$@MGN%~|(?OBCa4n}EPRTq|uyPG5hXNGa&tzpwxYK)AIojlum z)zHQmZEyYiJ-hv~-z_}98CHF7nAQ3&u+P2L5YYg7JAh+-^EVjq|A)~(bgF{%r-y8R zgQ2vHbcL%4HXpC=ev?k-vEq`Vf158gJbGikQG2Z8n=;Z!xwXdK!zp?72~krYl-FUb zn~|zQJyPUwZUGBO`u$IJO8@apdUwf2=o!s6G6EP%Evq|C5%D(Q1O-_*WyNMa-eeM$ zsLC3}z6%_Y=6Uv}NpZHOHqp9T@nwY3vQUNNatJ|Uj)^%G2MVz1#|1SfYCnYSw+jzQ zPKj)Om*UFSaP_P>iT_57H6)w;PNmuXe5G`NEgbgl~uVFc*fNU>rKG#Y)DkFN~+%|gBkaW&G2DsECynnE(WvyuK zZ2dvUUVHI_pPlLW=uZkPu6(|tA9i>Um^a(fF{WgPcsAvVmx|ae#@yMZ?@N|9Fdedw zh6*^@m3GQ_q;kVayblN}7eblx%}DKGj7GY!$s$!l7BxAb_d3c=HEAD-&zfqx>2d6Y zo9#?NWGx}2Fogk(2 z9n9weo5FE5C%2%V!r!5g zcE^5K(u_0zU6{6(68;hAx98^FB?9c$Bon7ezsS2eXG74x|5iAkKxUqU4H0X)AF zZX6X}TKu5HEqy9>H)=_r>stt89Q)#fm=>6>Psa2v;)L;V;B?ijsGbLd_E!$e?dc=(ss>Ll$B~Y!xQ7 zU*L0X#N_((USZMRv8U5`AQadb`Bh)V_NApjf&y9+Y`q#rZPGF8@$EyTctt3`@e8|I z5wDB!&8*ZIw_g*0U-BlUF7!waK#j*LZv>4&1h(9hM)o z_p%5O1AnN!=*i8?w`tpd7l#TPmSijiu=!%T3I~^fEFUlV`CCblP(3tiSoYEiNnIa+ z^dmQr$;%01Uc@q;%;GN4{D;Fe?Tou;YHY|NjV(12H4IE77x-PHN6T=V{0sHY`HNt+ zitK-_{b&7$G~W92-x*eAVf_}Jbw5Rd_8-VTNcSpQCb9_t*YMiKx?sv?%I+`EoSyd`#LbXPx=!g@*r7XQs@3yk!&9{BiHq(nKLmwyQz?SD} zmM(*3iTD_ubD6rj?!ID}iAv&`?CqM@duD=i%MyC<1S*)&5c?VQ21ayR0E9s7!`H2O zR;JZ40y0X}vII)=odviZp5Ks`7kpQ^^cb2y{%DzGJ&0%cmd1V%zW#Pe;d?Bi2fAm) zIlw(4C0Io5<`9~|=Ys!`4%r2eL5E?+R;r7`NKDRD>6y-Oq4qQ<>sZI_vh>13Bkf8( zN;8Xq_+=!*g(0OE&@=>ZhR0nJV`#QT?Rcv71KCgVmu6Y_NQscS7UBnWp6=&^;ldT! zVfZ$RnK#}ZtMY90)NBZ(YOE%@K8Ps_;XR-9Z3c@79@6BN z>C`H==KDP5u?2TYf`O8S;P~;L3-eQQr%R>;EeszR#|BU+LX2JHentOxlq%1gTwoz8fl<-;FJYS{#pT4 z3E%+!;^%ae;!q!r-z8RGylXOxir!jYu-ZLlF^qjo7C2{Ta=eMQ>uEyKRIyN`_5M9y z=W5%7;$xoYmJP>|+fF`k{fu!g7b;Ov9ZRI!-i3H%Tlvex##Q~XD}&>x zilQvv#Hzll%-0TDr7N5m&joz@c^(n)(t^c zY<|emih^)^^B4D;0r!IB+g%VeL|1Q%PH^dS>>=*WIa%=*z4hL8X)F=un)k?rIb zAlPVWY+V`r(kplL0n&s7QjwnqotYi(gufYa68@$p*!3wA_lT^?<^gl59-mOPt02t&ug@Y1mD}S<^t-_&u!p75P~hDLie(i7=AE@}oT>{^1%=wU+-v6xY!)2w z#Ez0zi|B|InRz$yfj#cJMTymRn7(EnlH=s+LqjvR`78Upx?fM3R%}jw_H3-$OgrfP zVbuP=G*St6&-t8j3LG())U3gR=a;HI%JC^q2L9OJ0`5_m)H}R)^L=n^QPOT{iHJ8G zBe2!cl^Z#fA2y0!3Zyq*USy61{~#Mp;*{Agh=YZqbgE{miP|0*$t z4bDA&B-WrkUhkhVDS;GDSn?@AiFY6UyFEfISS;Tv&uX3Gl>VW!QUF$vMezI;kCmZs zP4E07tMcz|zYGXna>?Lqg=~3Ij@ZLcv1C{*8W;pwq?<_TD*yLlT^^@f9f1?whU57b zi-oGZW%p5`hjcuTcgQuPF#W~GaRSPB&6W0~-l(VS*0^BE$u1Qd95}XOr<^i9f7CjE z^b@nIlEM33eGF6;UA6<-K|H|k`xC_L!2Aq^B18=y{<4(G0ZFs#E(Y5F z@WVW*U}AgAyL5JQ`EdBy(U~4n?^+&{CyKmN^T-_chpq7IjfbQGk4AmrH<*D?p!}vX z1x)aVc2JOogZmo{u7du~mUque_gn);bThB~Q%2oSmJ&NNJe%KVpYgph0x97NY#qSC zu4}Ib^&z>e7E;hU*N`-y??->yWXh|UEKPxleOufD-#AUTF%aHT;@_wDGiovecOH?HC!AJCm&GchdA=xgv6z6;#3?9Mu112aVfVHn) zHc;7`{GlY16XYQ<06vb>ftEv{E2g zb_CcX_zk8sUb70nmGS@)sBQB|G@grD)uLd<{H~WXsBh z$KOuYl~TkMP;2Mj)$bwbEv9V|gKP$?gEZn*>$YYgMh6eQ`v~YkS%6Zs z8z7o%1^&Xd!>m+<5FDrC#AF=jiq+~=^Vg+KRT94rReKsB|4^L%UAvn^J~urq5LCea zWhnlzn#;A0zjOEhR6mFOR700_`}Q9~ypJA#>iz)~g$RTk+M6%_`{>RXp#T3MvaVrcDGGWgZu%7S z9NZp+0dhhe;r2Z@a;GkRo}tG0)OysLwtm9O{0^x(S>E!~4-xO*>@w}hLz=BXRzg_d zUBmBgHW(I^-mME{DEV(N4UrA!;i7J>SH0n@j(C3I@iTMCiuexh#rdTZ4kUND>cDIy z`J{EUd+AFXyZ39n!W{&xaTo=hXcf%C9A8Z%?;;R0Lf-lej$~dvwh|CBc+{{@aqJI; zUV7P}RV022xT?W(OlK#TaR(cu#pj&a|H{gpddWE^CRFj-Xx;OvrS%7F05&(MI8)Pk0wT zC#6d3A6{Ogk3@<%U7&9JA1BH8tODh0(=Yhi!Re6{MJ*ft>D?UA=FXvuxOPjRi}1?K z_WyUZ{xDbnj@A#W`|rE;*K+mmOoR#h*KYmcKm7mP$_x0LZQ&@sp07h5bMp5$S}+J` zUJ-VOr-ic!dFJ@$;WHB?nYtl{Wg+u46Xw*{k~20j^8%*3W0RYdA#NjmS|9nW!bE}F z^iRvzGwJaGQyW(UOP?dpHj=f!L^n0wIC^KhK-kNjS#wmy3G*RV7M9!EVy`m=F<-{? zsV>%Qb-de;Per4W}*n z@#-tQk)aX(#p(Fb({>3*y#y3@{l2E@T(9ua`NXf?K>CuIbhBkS6E9zFV__78Rhg^Vbp3sR0plQh zqkMi*D;cUt{eTBj-5_+H^TgfzFMR0N@P{tyPV3zdZ$=Ri)YOdAbXbe9mX3Hagfv9o zoDR+{?Llil2)wTta&$}@Xm zQOb4N^1WAP&eI4c*V?}@t`|Si{N^@YBj9o#>gJldrsS+%+-b-?@tCrhO$I?u426X) zG}KFOE!OY3;~v!{dUt;bN8m;DMD^T|`3e1Q%LT1p_&YvJw?x)eK+oj00j9sIAbn6>+YGLPozkR$LxB=i^YG#0|6cuE;Y=GkgoG<{|=x zVL8cB3}O`T=&_)(Ujz)UmKCfiVr~FtB_W{s@<={lZ0c zRLyUvA7K*ToIyppP(nIY%7*GB+NaiGqk`am<@z^6&<)C`|iw=~Yg%!1DeUrAb9GKDQe&CKp`KNxxz!m+9Y>g>4+zRR2^4-Sf+=weL zxVB_^kSY(dHxE|l#EcFmZ_4KwNC*>lb!5K%)V}3%OJphP6UZAvMW)C3AAsQS7ln(| zD+(7HBkby83vhsZbhUlhg%2R-xOW9t+G0>XRM}t3XyG86%dDzeo+r zeK--slQ^6owF1&6o=0~JsdhwGI`8|O3*7tokT=(bjF~P#Uv?aA<1{$`X|<1^&v~~i z(SHBL!ZOL>vZTrU#yuSb+^sMryhrV%xWo=*Ptm@!6hCa#ezF{}pU%%a&;on7eBW+t zERySH3u$!bsmO;n9~R|dbzlXoV{LbLg)W#OrOt{Ve*RM$BlS%Ds&qzQ`Of43Ss|N| zP6;cAFV2G1U85x_Z$UHD026mMPePt~3U)^sl9j9;$|3wGiyA%VW#ji@z3yzZIMBPA z=7FlCyEKy4LZH@P;QEnmgXeh048s_7pOluxVDT)N829+oD@)Uy#LNZXKodWf(JYPP z=NgzrGaOPtuq~==F4`?1^>l*6k@@z{aIiv?j-=&uGJh$ZtH`+H_JmqjSli0L6UrLS zFnmRcu8#tCpo1h9uT9e||MU*LkfNjZJQ6!RVPH&$8{ zrYO{pVh_+!Q!tMtwiI~ZKn8p+oIyX&>c~wGx@4-jM~?3y+~*&KRY>+#sw;g@&LKB_ zI}63&Q;aBN zYLn!L^^#&821tYK=^W7Eh74K<;?P})g}?)Tna%r)nmVTJ`Un>_pJeg*M{lh+)Q7yt zQFq8w8Dvg2>xuV5DJxQ2Q7Qqmfpa2XU zNzl00FdI}4HHwq3*wv&aCx~8Dq&PA^jHB>@uSYIu!CB(~GoV^+B<@ zOOLo_Bfuz?Ye=|1dCvZQmfe9=voTQSnjL_Kf_iK%6u|Bh_he-)VSDS`Sqn1S3|YrnJBPHAyNB?=CT4imxDOR1(ds|qE<0#zHuR%K&~^wU zU{vc4l)2enr}aAr6-PT1QVYO9_alKzt-i;vA|KDydJKTA&JWGw9LoMlNO1Kp*T1O%`p{(6 ziIXuudwz5B157iwihwxT7El#+0jV!ypv*Qwasmaau1J^F*56^`TkpNP+YH!tgl>GY z5OIUWV(3kTqghX>iC2y@9%s8-9Ux$kBp3crre@<2R%eCjaOPdT?!FqY+Oq3+BE_X{ZjqRR)!zq|pe>xQd! zZtyowrUmk>V+boX6MGRwno0UfNjv&rCOr!s-P4-BC2V+XK`=$gWHWK zM?68!A2$NX&%*tZu8z$me0b%|peTauH<*@~qH{*s{3R0>i7nKx{bT_;(!whVgV?u* zhvxBT?DB~a+q;GtWnyZal`8PsPwP?^E#i;H5{DYL6IUDdTK?pOle5=S^4OA1$d}(x zcx;Y&r-jn+P1si2^9S+T2W>P_NjWzbR{^;{1WXwm(jPAZ;b;(eWxqm3oi10{r`*mT zqQ}3Fj-0)VRY}DRU7~+grNzR*n-jF3bbD60glt?C(L`b_^xcE}>?UY|D5(dZ5Q1&q zwb`Ckd?wX%YmH9kzU^A}vaNZkG<}Vwidb%Apu(FR9>pYgL1`uWHUDY$@=8| z6>vrz0nP~iWsr}O1Eu$-!JuO5l2rnJ6LNg;km1?bkSSP~-nK&{R7Xwy_Dp%iJVxbw z)(5|{7@!=vWX!2@Y*d#5L6Bu0U9OFQqe97S?dx9Y4|fAinP-0XvIV2z^e7H!w~SXm zSat>mn)I&^+&I=@`3ye(BDTB z-MTEA1dSelNN|GR{(~kI+*O^}%b5!RBw6zEXjSZ!kofut_ODFg3~Jwv%6D z>ArIm=tzY9nGh*zZu%6)Nb4Af={FeifyLtrsM|eU=ndf8ca%*J2wvM^*kqF6(~;WU zEy;nI0I6I1U)n7wSlSIOgWt_@tcA@oAH8)H#fBw>d5e!g2qUyExFrvi1TLK+m1`Gk z5ep5>&mW5tD;Z?ewND*f2y)OsV|gLX+<}4?gHA=%{$zb60}1xZ^^`ief^=>&;#;u1 z%7aW5gWbOD|3kYVr5laUYqV1rz090w3+>eLH>ax#-8Ar8JZd3^Lk_kYsp+Cg2Dk8w z4k0?@PEl4jh)GALPZb>i4QA4dZH@#NQm1ey!U@sTZiL;;IE2@qQ10U6@~g4hAmtl^ zl|Bz>kngF3g?=IlD)1DQA8@(>)Av>tD1k45Rnxsf;M_I%STXjO-l0`@!%H^c>Fr#$ zUs{tu&hTc*Q?N|-0?z{8403z{qk2h2Tyg%OmlXn_Xacy# zxXQMz)&ph+7`OK6SZ@~-&{a;Oea{n*z8zd`62E&6Rv5uss355fkdB2HTPqoEGrSF; zaNsk%Fc^bu$jRMcrq+gin9mK{545171yDc0R`*Xk?B^4xn^Z20(6gP{f8nB+GhMV} z;p_PvUw^FID1^D`IO_1b|D6Yz{N=QND5yQBuJmK4o->*g+T#rpL>3s=mC1>Xj3FA* z*N-%6q9gCdgiW!JzbzZ$x(55z&)Dw7_ry5}tL3?`fn>U9&~SXO`5PseEvi{WXc-HzH8%GicID`!tGuq7gYsRDutQvF~tIi7n zn54|}Fk+P_LPtw+^8_>-`?>GEszk~n$H|u|)0FZM4-ZHc#89-xgs65HG#l*SgYjbG z!~B`d`$eMwNGj9(kJ%3YPv5t|PIepT?Wce_7x^i1a;b(Ajb|PXx`7I~e)tM{VmbU< zuU4{>(UqY%bx{{Lcz^iqT9-3W=}>DQ`_ki_gzTJt|92M<&-^ -# -# -# $Id: plugin.properties,v 1.1 2011/04/06 13:07:28 nlepine Exp $ - -pluginName = Mbot Model -providerName = www.example.org diff --git a/plugins/org.eclipse.emf.eef.modelingbot/plugin.xml b/plugins/org.eclipse.emf.eef.modelingbot/plugin.xml deleted file mode 100644 index 3359a657b..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/plugin.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot/pom.xml b/plugins/org.eclipse.emf.eef.modelingbot/pom.xml deleted file mode 100644 index c12d3712e..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/pom.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.modelingbot - eclipse-plugin - - EEF ModelingBot Model Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot/representations.aird b/plugins/org.eclipse.emf.eef.modelingbot/representations.aird deleted file mode 100644 index bfb1a8dda..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/representations.aird +++ /dev/null @@ -1,7574 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - routingStyle - - - - - - - - - - - - - routingStyle - - - - - - - - - - - - - routingStyle - - - - - - - - - - - - - routingStyle - - - - - - - - - - - - - routingStyle - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Action.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Action.java deleted file mode 100755 index b16333ef5..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Action.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - - -/** - * - * A representation of the model object 'Action'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getAction() - * @model abstract="true" - * @generated - */ -public interface Action extends DocumentedElement, Processing { -} // Action diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/DetailsPage.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/DetailsPage.java deleted file mode 100755 index 1fa23017c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/DetailsPage.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - - -/** - * - * A representation of the model object 'Details Page'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getDetailsPage() - * @model - * @generated - */ -public interface DetailsPage extends Sequence { -} // DetailsPage diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/DocumentedElement.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/DocumentedElement.java deleted file mode 100755 index f617c5671..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/DocumentedElement.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Documented Element'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.DocumentedElement#getName Name}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.DocumentedElement#getDocumentation Documentation}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getDocumentedElement() - * @model abstract="true" - * @generated - */ -public interface DocumentedElement extends EObject { - /** - * Returns the value of the 'Name' attribute. - * - *

- * If the meaning of the 'Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Name' attribute. - * @see #setName(String) - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getDocumentedElement_Name() - * @model - * @generated - */ - String getName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.DocumentedElement#getName Name}' attribute. - * - * - * @param value the new value of the 'Name' attribute. - * @see #getName() - * @generated - */ - void setName(String value); - - /** - * Returns the value of the 'Documentation' attribute. - * - *

- * If the meaning of the 'Documentation' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Documentation' attribute. - * @see #setDocumentation(String) - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getDocumentedElement_Documentation() - * @model - * @generated - */ - String getDocumentation(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.DocumentedElement#getDocumentation Documentation}' attribute. - * - * - * @param value the new value of the 'Documentation' attribute. - * @see #getDocumentation() - * @generated - */ - void setDocumentation(String value); - -} // DocumentedElement diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Add.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Add.java deleted file mode 100755 index 814f30a3c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Add.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; - - -/** - * - * A representation of the model object 'Add'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.Add#getType Type}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.Add#getEContainingFeature EContaining Feature}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getAdd() - * @model - * @generated - */ -public interface Add extends EditAction { - - /** - * Returns the value of the 'Type' reference. - * - *

- * If the meaning of the 'Type' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Type' reference. - * @see #setType(EClass) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getAdd_Type() - * @model - * @generated - */ - EClass getType(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Add#getType Type}' reference. - * - * - * @param value the new value of the 'Type' reference. - * @see #getType() - * @generated - */ - void setType(EClass value); - - /** - * Returns the value of the 'EContaining Feature' reference. - * - *

- * If the meaning of the 'EContaining Feature' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'EContaining Feature' reference. - * @see #setEContainingFeature(EStructuralFeature) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getAdd_EContainingFeature() - * @model - * @generated - */ - EStructuralFeature getEContainingFeature(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Add#getEContainingFeature EContaining Feature}' reference. - * - * - * @param value the new value of the 'EContaining Feature' reference. - * @see #getEContainingFeature() - * @generated - */ - void setEContainingFeature(EStructuralFeature value); -} // Add diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Cancel.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Cancel.java deleted file mode 100755 index 743afb121..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Cancel.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.eef.modelingBot.Processing; -import org.eclipse.emf.eef.modelingBot.Action; - - -/** - * - * A representation of the model object 'Cancel'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.Cancel#getProcessing Processing}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getCancel() - * @model - * @generated - */ -public interface Cancel extends EEFAction { - - /** - * Returns the value of the 'Processing' reference. - * - *

- * If the meaning of the 'Processing' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Processing' reference. - * @see #setProcessing(Processing) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getCancel_Processing() - * @model - * @generated - */ - Processing getProcessing(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Cancel#getProcessing Processing}' reference. - * - * - * @param value the new value of the 'Processing' reference. - * @see #getProcessing() - * @generated - */ - void setProcessing(Processing value); -} // Cancel diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Check.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Check.java deleted file mode 100755 index 8a670c8ad..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Check.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - - -/** - * - * A representation of the model object 'Check'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getCheck() - * @model - * @generated - */ -public interface Check extends EEFAction { -} // Check diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFAction.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFAction.java deleted file mode 100755 index 73c1e4ee3..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFAction.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.eef.modelingBot.Action; - -/** - * - * A representation of the model object 'EEF Action'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getEEFAction() - * @model abstract="true" - * @generated - */ -public interface EEFAction extends Action { -} // EEFAction diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFActionsFactory.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFActionsFactory.java deleted file mode 100755 index 48cd7b74c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFActionsFactory.java +++ /dev/null @@ -1,149 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage - * @generated - */ -public interface EEFActionsFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - EEFActionsFactory eINSTANCE = org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsFactoryImpl.init(); - - /** - * Returns a new object of class 'Add'. - * - * - * @return a new object of class 'Add'. - * @generated - */ - Add createAdd(); - - /** - * Returns a new object of class 'Remove'. - * - * - * @return a new object of class 'Remove'. - * @generated - */ - Remove createRemove(); - - /** - * Returns a new object of class 'Set Attribute'. - * - * - * @return a new object of class 'Set Attribute'. - * @generated - */ - SetAttribute createSetAttribute(); - - /** - * Returns a new object of class 'Unset Attribute'. - * - * - * @return a new object of class 'Unset Attribute'. - * @generated - */ - UnsetAttribute createUnsetAttribute(); - - /** - * Returns a new object of class 'Unset'. - * - * - * @return a new object of class 'Unset'. - * @generated - */ - Unset createUnset(); - - /** - * Returns a new object of class 'Cancel'. - * - * - * @return a new object of class 'Cancel'. - * @generated - */ - Cancel createCancel(); - - /** - * Returns a new object of class 'Check'. - * - * - * @return a new object of class 'Check'. - * @generated - */ - Check createCheck(); - - /** - * Returns a new object of class 'Open EEF Editor'. - * - * - * @return a new object of class 'Open EEF Editor'. - * @generated - */ - OpenEEFEditor createOpenEEFEditor(); - - /** - * Returns a new object of class 'Set Reference'. - * - * - * @return a new object of class 'Set Reference'. - * @generated - */ - SetReference createSetReference(); - - /** - * Returns a new object of class 'Unset Reference'. - * - * - * @return a new object of class 'Unset Reference'. - * @generated - */ - UnsetReference createUnsetReference(); - - /** - * Returns a new object of class 'Move Up'. - * - * - * @return a new object of class 'Move Up'. - * @generated - */ - MoveUp createMoveUp(); - - /** - * Returns a new object of class 'Move Down'. - * - * - * @return a new object of class 'Move Down'. - * @generated - */ - MoveDown createMoveDown(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - EEFActionsPackage getEEFActionsPackage(); - -} //EEFActionsFactory diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFActionsPackage.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFActionsPackage.java deleted file mode 100755 index e7db11efd..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EEFActionsPackage.java +++ /dev/null @@ -1,1475 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsFactory - * @model kind="package" - * @generated - */ -public interface EEFActionsPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "EEFActions"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/test/EEFActions/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-test"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - EEFActionsPackage eINSTANCE = org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl.init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionImpl EEF Action}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getEEFAction() - * @generated - */ - int EEF_ACTION = 0; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int EEF_ACTION__NAME = ModelingBotPackage.ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int EEF_ACTION__DOCUMENTATION = ModelingBotPackage.ACTION__DOCUMENTATION; - - /** - * The number of structural features of the 'EEF Action' class. - * - * - * @generated - * @ordered - */ - int EEF_ACTION_FEATURE_COUNT = ModelingBotPackage.ACTION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.EditActionImpl Edit Action}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EditActionImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getEditAction() - * @generated - */ - int EDIT_ACTION = 1; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int EDIT_ACTION__NAME = EEF_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int EDIT_ACTION__DOCUMENTATION = EEF_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Properties Edition Element' reference. - * - * - * @generated - * @ordered - */ - int EDIT_ACTION__PROPERTIES_EDITION_ELEMENT = EEF_ACTION_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int EDIT_ACTION__REFERENCEABLE_OBJECT = EEF_ACTION_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Edit Action' class. - * - * - * @generated - * @ordered - */ - int EDIT_ACTION_FEATURE_COUNT = EEF_ACTION_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.AddImpl Add}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.AddImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getAdd() - * @generated - */ - int ADD = 2; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int ADD__NAME = EDIT_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int ADD__DOCUMENTATION = EDIT_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Properties Edition Element' reference. - * - * - * @generated - * @ordered - */ - int ADD__PROPERTIES_EDITION_ELEMENT = EDIT_ACTION__PROPERTIES_EDITION_ELEMENT; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int ADD__REFERENCEABLE_OBJECT = EDIT_ACTION__REFERENCEABLE_OBJECT; - - /** - * The feature id for the 'Type' reference. - * - * - * @generated - * @ordered - */ - int ADD__TYPE = EDIT_ACTION_FEATURE_COUNT + 0; - - /** - * The feature id for the 'EContaining Feature' reference. - * - * - * @generated - * @ordered - */ - int ADD__ECONTAINING_FEATURE = EDIT_ACTION_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Add' class. - * - * - * @generated - * @ordered - */ - int ADD_FEATURE_COUNT = EDIT_ACTION_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.RemoveImpl Remove}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.RemoveImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getRemove() - * @generated - */ - int REMOVE = 3; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int REMOVE__NAME = EDIT_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int REMOVE__DOCUMENTATION = EDIT_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Properties Edition Element' reference. - * - * - * @generated - * @ordered - */ - int REMOVE__PROPERTIES_EDITION_ELEMENT = EDIT_ACTION__PROPERTIES_EDITION_ELEMENT; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int REMOVE__REFERENCEABLE_OBJECT = EDIT_ACTION__REFERENCEABLE_OBJECT; - - /** - * The number of structural features of the 'Remove' class. - * - * - * @generated - * @ordered - */ - int REMOVE_FEATURE_COUNT = EDIT_ACTION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetAttributeImpl Set Attribute}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetAttributeImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getSetAttribute() - * @generated - */ - int SET_ATTRIBUTE = 4; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int SET_ATTRIBUTE__NAME = EDIT_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int SET_ATTRIBUTE__DOCUMENTATION = EDIT_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Properties Edition Element' reference. - * - * - * @generated - * @ordered - */ - int SET_ATTRIBUTE__PROPERTIES_EDITION_ELEMENT = EDIT_ACTION__PROPERTIES_EDITION_ELEMENT; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int SET_ATTRIBUTE__REFERENCEABLE_OBJECT = EDIT_ACTION__REFERENCEABLE_OBJECT; - - /** - * The feature id for the 'Values' attribute list. - * - * - * @generated - * @ordered - */ - int SET_ATTRIBUTE__VALUES = EDIT_ACTION_FEATURE_COUNT + 0; - - /** - * The feature id for the 'EContaining Feature' reference. - * - * - * @generated - * @ordered - */ - int SET_ATTRIBUTE__ECONTAINING_FEATURE = EDIT_ACTION_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Set Attribute' class. - * - * - * @generated - * @ordered - */ - int SET_ATTRIBUTE_FEATURE_COUNT = EDIT_ACTION_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetAttributeImpl Unset Attribute}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetAttributeImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getUnsetAttribute() - * @generated - */ - int UNSET_ATTRIBUTE = 5; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int UNSET_ATTRIBUTE__NAME = EDIT_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int UNSET_ATTRIBUTE__DOCUMENTATION = EDIT_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Properties Edition Element' reference. - * - * - * @generated - * @ordered - */ - int UNSET_ATTRIBUTE__PROPERTIES_EDITION_ELEMENT = EDIT_ACTION__PROPERTIES_EDITION_ELEMENT; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int UNSET_ATTRIBUTE__REFERENCEABLE_OBJECT = EDIT_ACTION__REFERENCEABLE_OBJECT; - - /** - * The feature id for the 'Values' attribute list. - * - * - * @generated - * @ordered - */ - int UNSET_ATTRIBUTE__VALUES = EDIT_ACTION_FEATURE_COUNT + 0; - - /** - * The feature id for the 'EContaining Feature' reference. - * - * - * @generated - * @ordered - */ - int UNSET_ATTRIBUTE__ECONTAINING_FEATURE = EDIT_ACTION_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Unset Attribute' class. - * - * - * @generated - * @ordered - */ - int UNSET_ATTRIBUTE_FEATURE_COUNT = EDIT_ACTION_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetImpl Unset}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getUnset() - * @generated - */ - int UNSET = 6; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int UNSET__NAME = EDIT_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int UNSET__DOCUMENTATION = EDIT_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Properties Edition Element' reference. - * - * - * @generated - * @ordered - */ - int UNSET__PROPERTIES_EDITION_ELEMENT = EDIT_ACTION__PROPERTIES_EDITION_ELEMENT; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int UNSET__REFERENCEABLE_OBJECT = EDIT_ACTION__REFERENCEABLE_OBJECT; - - /** - * The feature id for the 'Feature' reference. - * - * - * @generated - * @ordered - */ - int UNSET__FEATURE = EDIT_ACTION_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Unset' class. - * - * - * @generated - * @ordered - */ - int UNSET_FEATURE_COUNT = EDIT_ACTION_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.CancelImpl Cancel}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.CancelImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getCancel() - * @generated - */ - int CANCEL = 7; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int CANCEL__NAME = EEF_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int CANCEL__DOCUMENTATION = EEF_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Processing' reference. - * - * - * @generated - * @ordered - */ - int CANCEL__PROCESSING = EEF_ACTION_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Cancel' class. - * - * - * @generated - * @ordered - */ - int CANCEL_FEATURE_COUNT = EEF_ACTION_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.CheckImpl Check}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.CheckImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getCheck() - * @generated - */ - int CHECK = 8; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int CHECK__NAME = EEF_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int CHECK__DOCUMENTATION = EEF_ACTION__DOCUMENTATION; - - /** - * The number of structural features of the 'Check' class. - * - * - * @generated - * @ordered - */ - int CHECK_FEATURE_COUNT = EEF_ACTION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.OpenEEFEditorImpl Open EEF Editor}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.OpenEEFEditorImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getOpenEEFEditor() - * @generated - */ - int OPEN_EEF_EDITOR = 9; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_EEF_EDITOR__NAME = EEF_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_EEF_EDITOR__DOCUMENTATION = EEF_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Editor Name' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_EEF_EDITOR__EDITOR_NAME = EEF_ACTION_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Open EEF Editor' class. - * - * - * @generated - * @ordered - */ - int OPEN_EEF_EDITOR_FEATURE_COUNT = EEF_ACTION_FEATURE_COUNT + 1; - - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetReferenceImpl Set Reference}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetReferenceImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getSetReference() - * @generated - */ - int SET_REFERENCE = 10; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int SET_REFERENCE__NAME = EDIT_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int SET_REFERENCE__DOCUMENTATION = EDIT_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Properties Edition Element' reference. - * - * - * @generated - * @ordered - */ - int SET_REFERENCE__PROPERTIES_EDITION_ELEMENT = EDIT_ACTION__PROPERTIES_EDITION_ELEMENT; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int SET_REFERENCE__REFERENCEABLE_OBJECT = EDIT_ACTION__REFERENCEABLE_OBJECT; - - /** - * The feature id for the 'Values' reference list. - * - * - * @generated - * @ordered - */ - int SET_REFERENCE__VALUES = EDIT_ACTION_FEATURE_COUNT + 0; - - /** - * The feature id for the 'EContaining Feature' reference. - * - * - * @generated - * @ordered - */ - int SET_REFERENCE__ECONTAINING_FEATURE = EDIT_ACTION_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Set Reference' class. - * - * - * @generated - * @ordered - */ - int SET_REFERENCE_FEATURE_COUNT = EDIT_ACTION_FEATURE_COUNT + 2; - - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetReferenceImpl Unset Reference}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetReferenceImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getUnsetReference() - * @generated - */ - int UNSET_REFERENCE = 11; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int UNSET_REFERENCE__NAME = EDIT_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int UNSET_REFERENCE__DOCUMENTATION = EDIT_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Properties Edition Element' reference. - * - * - * @generated - * @ordered - */ - int UNSET_REFERENCE__PROPERTIES_EDITION_ELEMENT = EDIT_ACTION__PROPERTIES_EDITION_ELEMENT; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int UNSET_REFERENCE__REFERENCEABLE_OBJECT = EDIT_ACTION__REFERENCEABLE_OBJECT; - - /** - * The feature id for the 'Feature' reference. - * - * - * @generated - * @ordered - */ - int UNSET_REFERENCE__FEATURE = EDIT_ACTION_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Values' reference list. - * - * - * @generated - * @ordered - */ - int UNSET_REFERENCE__VALUES = EDIT_ACTION_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Unset Reference' class. - * - * - * @generated - * @ordered - */ - int UNSET_REFERENCE_FEATURE_COUNT = EDIT_ACTION_FEATURE_COUNT + 2; - - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.MoveUpImpl Move Up}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.MoveUpImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getMoveUp() - * @generated - */ - int MOVE_UP = 12; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int MOVE_UP__NAME = EDIT_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int MOVE_UP__DOCUMENTATION = EDIT_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Properties Edition Element' reference. - * - * - * @generated - * @ordered - */ - int MOVE_UP__PROPERTIES_EDITION_ELEMENT = EDIT_ACTION__PROPERTIES_EDITION_ELEMENT; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int MOVE_UP__REFERENCEABLE_OBJECT = EDIT_ACTION__REFERENCEABLE_OBJECT; - - /** - * The number of structural features of the 'Move Up' class. - * - * - * @generated - * @ordered - */ - int MOVE_UP_FEATURE_COUNT = EDIT_ACTION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.MoveDownImpl Move Down}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.MoveDownImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getMoveDown() - * @generated - */ - int MOVE_DOWN = 13; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int MOVE_DOWN__NAME = EDIT_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int MOVE_DOWN__DOCUMENTATION = EDIT_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Properties Edition Element' reference. - * - * - * @generated - * @ordered - */ - int MOVE_DOWN__PROPERTIES_EDITION_ELEMENT = EDIT_ACTION__PROPERTIES_EDITION_ELEMENT; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int MOVE_DOWN__REFERENCEABLE_OBJECT = EDIT_ACTION__REFERENCEABLE_OBJECT; - - /** - * The number of structural features of the 'Move Down' class. - * - * - * @generated - * @ordered - */ - int MOVE_DOWN_FEATURE_COUNT = EDIT_ACTION_FEATURE_COUNT + 0; - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.EEFAction EEF Action}'. - * - * - * @return the meta object for class 'EEF Action'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFAction - * @generated - */ - EClass getEEFAction(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.EditAction Edit Action}'. - * - * - * @return the meta object for class 'Edit Action'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EditAction - * @generated - */ - EClass getEditAction(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EEFActions.EditAction#getPropertiesEditionElement Properties Edition Element}'. - * - * - * @return the meta object for the reference 'Properties Edition Element'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EditAction#getPropertiesEditionElement() - * @see #getEditAction() - * @generated - */ - EReference getEditAction_PropertiesEditionElement(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EEFActions.EditAction#getReferenceableObject Referenceable Object}'. - * - * - * @return the meta object for the reference 'Referenceable Object'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EditAction#getReferenceableObject() - * @see #getEditAction() - * @generated - */ - EReference getEditAction_ReferenceableObject(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Add Add}'. - * - * - * @return the meta object for class 'Add'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Add - * @generated - */ - EClass getAdd(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Add#getType Type}'. - * - * - * @return the meta object for the reference 'Type'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Add#getType() - * @see #getAdd() - * @generated - */ - EReference getAdd_Type(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Add#getEContainingFeature EContaining Feature}'. - * - * - * @return the meta object for the reference 'EContaining Feature'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Add#getEContainingFeature() - * @see #getAdd() - * @generated - */ - EReference getAdd_EContainingFeature(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Remove Remove}'. - * - * - * @return the meta object for class 'Remove'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Remove - * @generated - */ - EClass getRemove(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute Set Attribute}'. - * - * - * @return the meta object for class 'Set Attribute'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute - * @generated - */ - EClass getSetAttribute(); - - /** - * Returns the meta object for the attribute list '{@link org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute#getValues Values}'. - * - * - * @return the meta object for the attribute list 'Values'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute#getValues() - * @see #getSetAttribute() - * @generated - */ - EAttribute getSetAttribute_Values(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute#getEContainingFeature EContaining Feature}'. - * - * - * @return the meta object for the reference 'EContaining Feature'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute#getEContainingFeature() - * @see #getSetAttribute() - * @generated - */ - EReference getSetAttribute_EContainingFeature(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute Unset Attribute}'. - * - * - * @return the meta object for class 'Unset Attribute'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute - * @generated - */ - EClass getUnsetAttribute(); - - /** - * Returns the meta object for the attribute list '{@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute#getValues Values}'. - * - * - * @return the meta object for the attribute list 'Values'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute#getValues() - * @see #getUnsetAttribute() - * @generated - */ - EAttribute getUnsetAttribute_Values(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute#getEContainingFeature EContaining Feature}'. - * - * - * @return the meta object for the reference 'EContaining Feature'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute#getEContainingFeature() - * @see #getUnsetAttribute() - * @generated - */ - EReference getUnsetAttribute_EContainingFeature(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Unset Unset}'. - * - * - * @return the meta object for class 'Unset'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Unset - * @generated - */ - EClass getUnset(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Unset#getFeature Feature}'. - * - * - * @return the meta object for the reference 'Feature'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Unset#getFeature() - * @see #getUnset() - * @generated - */ - EReference getUnset_Feature(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Cancel Cancel}'. - * - * - * @return the meta object for class 'Cancel'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Cancel - * @generated - */ - EClass getCancel(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Cancel#getProcessing Processing}'. - * - * - * @return the meta object for the reference 'Processing'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Cancel#getProcessing() - * @see #getCancel() - * @generated - */ - EReference getCancel_Processing(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Check Check}'. - * - * - * @return the meta object for class 'Check'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Check - * @generated - */ - EClass getCheck(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor Open EEF Editor}'. - * - * - * @return the meta object for class 'Open EEF Editor'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor - * @generated - */ - EClass getOpenEEFEditor(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor#getEditorName Editor Name}'. - * - * - * @return the meta object for the attribute 'Editor Name'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor#getEditorName() - * @see #getOpenEEFEditor() - * @generated - */ - EAttribute getOpenEEFEditor_EditorName(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.SetReference Set Reference}'. - * - * - * @return the meta object for class 'Set Reference'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.SetReference - * @generated - */ - EClass getSetReference(); - - /** - * Returns the meta object for the reference list '{@link org.eclipse.emf.eef.modelingBot.EEFActions.SetReference#getValues Values}'. - * - * - * @return the meta object for the reference list 'Values'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.SetReference#getValues() - * @see #getSetReference() - * @generated - */ - EReference getSetReference_Values(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EEFActions.SetReference#getEContainingFeature EContaining Feature}'. - * - * - * @return the meta object for the reference 'EContaining Feature'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.SetReference#getEContainingFeature() - * @see #getSetReference() - * @generated - */ - EReference getSetReference_EContainingFeature(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference Unset Reference}'. - * - * - * @return the meta object for class 'Unset Reference'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference - * @generated - */ - EClass getUnsetReference(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference#getFeature Feature}'. - * - * - * @return the meta object for the reference 'Feature'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference#getFeature() - * @see #getUnsetReference() - * @generated - */ - EReference getUnsetReference_Feature(); - - /** - * Returns the meta object for the reference list '{@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference#getValues Values}'. - * - * - * @return the meta object for the reference list 'Values'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference#getValues() - * @see #getUnsetReference() - * @generated - */ - EReference getUnsetReference_Values(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp Move Up}'. - * - * - * @return the meta object for class 'Move Up'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp - * @generated - */ - EClass getMoveUp(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown Move Down}'. - * - * - * @return the meta object for class 'Move Down'. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown - * @generated - */ - EClass getMoveDown(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - EEFActionsFactory getEEFActionsFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionImpl EEF Action}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getEEFAction() - * @generated - */ - EClass EEF_ACTION = eINSTANCE.getEEFAction(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.EditActionImpl Edit Action}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EditActionImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getEditAction() - * @generated - */ - EClass EDIT_ACTION = eINSTANCE.getEditAction(); - - /** - * The meta object literal for the 'Properties Edition Element' reference feature. - * - * - * @generated - */ - EReference EDIT_ACTION__PROPERTIES_EDITION_ELEMENT = eINSTANCE.getEditAction_PropertiesEditionElement(); - - /** - * The meta object literal for the 'Referenceable Object' reference feature. - * - * - * @generated - */ - EReference EDIT_ACTION__REFERENCEABLE_OBJECT = eINSTANCE.getEditAction_ReferenceableObject(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.AddImpl Add}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.AddImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getAdd() - * @generated - */ - EClass ADD = eINSTANCE.getAdd(); - - /** - * The meta object literal for the 'Type' reference feature. - * - * - * @generated - */ - EReference ADD__TYPE = eINSTANCE.getAdd_Type(); - - /** - * The meta object literal for the 'EContaining Feature' reference feature. - * - * - * @generated - */ - EReference ADD__ECONTAINING_FEATURE = eINSTANCE.getAdd_EContainingFeature(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.RemoveImpl Remove}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.RemoveImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getRemove() - * @generated - */ - EClass REMOVE = eINSTANCE.getRemove(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetAttributeImpl Set Attribute}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetAttributeImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getSetAttribute() - * @generated - */ - EClass SET_ATTRIBUTE = eINSTANCE.getSetAttribute(); - - /** - * The meta object literal for the 'Values' attribute list feature. - * - * - * @generated - */ - EAttribute SET_ATTRIBUTE__VALUES = eINSTANCE.getSetAttribute_Values(); - - /** - * The meta object literal for the 'EContaining Feature' reference feature. - * - * - * @generated - */ - EReference SET_ATTRIBUTE__ECONTAINING_FEATURE = eINSTANCE.getSetAttribute_EContainingFeature(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetAttributeImpl Unset Attribute}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetAttributeImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getUnsetAttribute() - * @generated - */ - EClass UNSET_ATTRIBUTE = eINSTANCE.getUnsetAttribute(); - - /** - * The meta object literal for the 'Values' attribute list feature. - * - * - * @generated - */ - EAttribute UNSET_ATTRIBUTE__VALUES = eINSTANCE.getUnsetAttribute_Values(); - - /** - * The meta object literal for the 'EContaining Feature' reference feature. - * - * - * @generated - */ - EReference UNSET_ATTRIBUTE__ECONTAINING_FEATURE = eINSTANCE.getUnsetAttribute_EContainingFeature(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetImpl Unset}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getUnset() - * @generated - */ - EClass UNSET = eINSTANCE.getUnset(); - - /** - * The meta object literal for the 'Feature' reference feature. - * - * - * @generated - */ - EReference UNSET__FEATURE = eINSTANCE.getUnset_Feature(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.CancelImpl Cancel}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.CancelImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getCancel() - * @generated - */ - EClass CANCEL = eINSTANCE.getCancel(); - - /** - * The meta object literal for the 'Processing' reference feature. - * - * - * @generated - */ - EReference CANCEL__PROCESSING = eINSTANCE.getCancel_Processing(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.CheckImpl Check}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.CheckImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getCheck() - * @generated - */ - EClass CHECK = eINSTANCE.getCheck(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.OpenEEFEditorImpl Open EEF Editor}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.OpenEEFEditorImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getOpenEEFEditor() - * @generated - */ - EClass OPEN_EEF_EDITOR = eINSTANCE.getOpenEEFEditor(); - - /** - * The meta object literal for the 'Editor Name' attribute feature. - * - * - * @generated - */ - EAttribute OPEN_EEF_EDITOR__EDITOR_NAME = eINSTANCE.getOpenEEFEditor_EditorName(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetReferenceImpl Set Reference}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetReferenceImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getSetReference() - * @generated - */ - EClass SET_REFERENCE = eINSTANCE.getSetReference(); - - /** - * The meta object literal for the 'Values' reference list feature. - * - * - * @generated - */ - EReference SET_REFERENCE__VALUES = eINSTANCE.getSetReference_Values(); - - /** - * The meta object literal for the 'EContaining Feature' reference feature. - * - * - * @generated - */ - EReference SET_REFERENCE__ECONTAINING_FEATURE = eINSTANCE.getSetReference_EContainingFeature(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetReferenceImpl Unset Reference}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetReferenceImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getUnsetReference() - * @generated - */ - EClass UNSET_REFERENCE = eINSTANCE.getUnsetReference(); - - /** - * The meta object literal for the 'Feature' reference feature. - * - * - * @generated - */ - EReference UNSET_REFERENCE__FEATURE = eINSTANCE.getUnsetReference_Feature(); - - /** - * The meta object literal for the 'Values' reference list feature. - * - * - * @generated - */ - EReference UNSET_REFERENCE__VALUES = eINSTANCE.getUnsetReference_Values(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.MoveUpImpl Move Up}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.MoveUpImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getMoveUp() - * @generated - */ - EClass MOVE_UP = eINSTANCE.getMoveUp(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.MoveDownImpl Move Down}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.MoveDownImpl - * @see org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl#getMoveDown() - * @generated - */ - EClass MOVE_DOWN = eINSTANCE.getMoveDown(); - - } - -} //EEFActionsPackage diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EditAction.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EditAction.java deleted file mode 100755 index 3b8250295..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/EditAction.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.eef.components.PropertiesEditionElement; - -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; - -/** - * - * A representation of the model object 'Edit Action'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.EditAction#getPropertiesEditionElement Properties Edition Element}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.EditAction#getReferenceableObject Referenceable Object}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getEditAction() - * @model abstract="true" - * @generated - */ -public interface EditAction extends EEFAction, ReferenceableObject { - /** - * Returns the value of the 'Properties Edition Element' reference. - * - *

- * If the meaning of the 'Properties Edition Element' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Properties Edition Element' reference. - * @see #setPropertiesEditionElement(PropertiesEditionElement) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getEditAction_PropertiesEditionElement() - * @model - * @generated - */ - PropertiesEditionElement getPropertiesEditionElement(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.EditAction#getPropertiesEditionElement Properties Edition Element}' reference. - * - * - * @param value the new value of the 'Properties Edition Element' reference. - * @see #getPropertiesEditionElement() - * @generated - */ - void setPropertiesEditionElement(PropertiesEditionElement value); - - /** - * Returns the value of the 'Referenceable Object' reference. - * - *

- * If the meaning of the 'Referenceable Object' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Referenceable Object' reference. - * @see #setReferenceableObject(ReferenceableObject) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getEditAction_ReferenceableObject() - * @model - * @generated - */ - ReferenceableObject getReferenceableObject(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.EditAction#getReferenceableObject Referenceable Object}' reference. - * - * - * @param value the new value of the 'Referenceable Object' reference. - * @see #getReferenceableObject() - * @generated - */ - void setReferenceableObject(ReferenceableObject value); - -} // EditAction diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/MoveDown.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/MoveDown.java deleted file mode 100644 index 7c8e26642..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/MoveDown.java +++ /dev/null @@ -1,21 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions; - - -/** - * - * A representation of the model object 'Move Down'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getMoveDown() - * @model - * @generated - */ -public interface MoveDown extends EditAction { -} // MoveDown diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/MoveUp.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/MoveUp.java deleted file mode 100644 index d3b34c504..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/MoveUp.java +++ /dev/null @@ -1,21 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions; - - -/** - * - * A representation of the model object 'Move Up'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getMoveUp() - * @model - * @generated - */ -public interface MoveUp extends EditAction { -} // MoveUp diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/OpenEEFEditor.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/OpenEEFEditor.java deleted file mode 100755 index e4e81c30c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/OpenEEFEditor.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - - -/** - * - * A representation of the model object 'Open EEF Editor'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor#getEditorName Editor Name}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getOpenEEFEditor() - * @model - * @generated - */ -public interface OpenEEFEditor extends EEFAction { - /** - * Returns the value of the 'Editor Name' attribute. - * - *

- * If the meaning of the 'Editor Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Editor Name' attribute. - * @see #setEditorName(String) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getOpenEEFEditor_EditorName() - * @model - * @generated - */ - String getEditorName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor#getEditorName Editor Name}' attribute. - * - * - * @param value the new value of the 'Editor Name' attribute. - * @see #getEditorName() - * @generated - */ - void setEditorName(String value); - -} // OpenEEFEditor diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Remove.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Remove.java deleted file mode 100755 index 45a3bccc1..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Remove.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - - -/** - * - * A representation of the model object 'Remove'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getRemove() - * @model - * @generated - */ -public interface Remove extends EditAction { -} // Remove diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/SetAttribute.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/SetAttribute.java deleted file mode 100755 index 8c4d975c4..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/SetAttribute.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EStructuralFeature; - - -/** - * - * A representation of the model object 'Set Attribute'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute#getValues Values}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute#getEContainingFeature EContaining Feature}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getSetAttribute() - * @model - * @generated - */ -public interface SetAttribute extends EditAction { - /** - * Returns the value of the 'Values' attribute list. - * The list contents are of type {@link java.lang.String}. - * - *

- * If the meaning of the 'Values' attribute list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Values' attribute list. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getSetAttribute_Values() - * @model - * @generated - */ - EList getValues(); - - /** - * Returns the value of the 'EContaining Feature' reference. - * - *

- * If the meaning of the 'EContaining Feature' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'EContaining Feature' reference. - * @see #setEContainingFeature(EStructuralFeature) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getSetAttribute_EContainingFeature() - * @model - * @generated - */ - EStructuralFeature getEContainingFeature(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute#getEContainingFeature EContaining Feature}' reference. - * - * - * @param value the new value of the 'EContaining Feature' reference. - * @see #getEContainingFeature() - * @generated - */ - void setEContainingFeature(EStructuralFeature value); - -} // SetAttribute diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/SetReference.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/SetReference.java deleted file mode 100755 index 885806ca9..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/SetReference.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; - -/** - * - * A representation of the model object 'Set Reference'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.SetReference#getValues Values}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.SetReference#getEContainingFeature EContaining Feature}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getSetReference() - * @model - * @generated - */ -public interface SetReference extends EditAction { - /** - * Returns the value of the 'Values' reference list. - * The list contents are of type {@link org.eclipse.emf.eef.extended.editor.ReferenceableObject}. - * - *

- * If the meaning of the 'Values' reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Values' reference list. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getSetReference_Values() - * @model - * @generated - */ - EList getValues(); - - /** - * Returns the value of the 'EContaining Feature' reference. - * - *

- * If the meaning of the 'EContaining Feature' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'EContaining Feature' reference. - * @see #setEContainingFeature(EStructuralFeature) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getSetReference_EContainingFeature() - * @model - * @generated - */ - EStructuralFeature getEContainingFeature(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.SetReference#getEContainingFeature EContaining Feature}' reference. - * - * - * @param value the new value of the 'EContaining Feature' reference. - * @see #getEContainingFeature() - * @generated - */ - void setEContainingFeature(EStructuralFeature value); - -} // SetReference diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Unset.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Unset.java deleted file mode 100755 index ab110cf77..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/Unset.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.ecore.EStructuralFeature; - - -/** - * - * A representation of the model object 'Unset'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.Unset#getFeature Feature}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getUnset() - * @model - * @generated - */ -public interface Unset extends EditAction { - - /** - * Returns the value of the 'Feature' reference. - * - *

- * If the meaning of the 'Feature' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Feature' reference. - * @see #setFeature(EStructuralFeature) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getUnset_Feature() - * @model - * @generated - */ - EStructuralFeature getFeature(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Unset#getFeature Feature}' reference. - * - * - * @param value the new value of the 'Feature' reference. - * @see #getFeature() - * @generated - */ - void setFeature(EStructuralFeature value); -} // Unset diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/UnsetAttribute.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/UnsetAttribute.java deleted file mode 100644 index 55f09929c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/UnsetAttribute.java +++ /dev/null @@ -1,73 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EStructuralFeature; - -/** - * - * A representation of the model object 'Unset Attribute'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute#getValues Values}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute#getEContainingFeature EContaining Feature}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getUnsetAttribute() - * @model - * @generated - */ -public interface UnsetAttribute extends EditAction { - /** - * Returns the value of the 'Values' attribute list. - * The list contents are of type {@link java.lang.String}. - * - *

- * If the meaning of the 'Values' attribute list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Values' attribute list. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getUnsetAttribute_Values() - * @model - * @generated - */ - EList getValues(); - - /** - * Returns the value of the 'EContaining Feature' reference. - * - *

- * If the meaning of the 'EContaining Feature' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'EContaining Feature' reference. - * @see #setEContainingFeature(EStructuralFeature) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getUnsetAttribute_EContainingFeature() - * @model - * @generated - */ - EStructuralFeature getEContainingFeature(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute#getEContainingFeature EContaining Feature}' reference. - * - * - * @param value the new value of the 'EContaining Feature' reference. - * @see #getEContainingFeature() - * @generated - */ - void setEContainingFeature(EStructuralFeature value); - -} // UnsetAttribute diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/UnsetReference.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/UnsetReference.java deleted file mode 100644 index 39016ae72..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/UnsetReference.java +++ /dev/null @@ -1,74 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EStructuralFeature; - -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; - -/** - * - * A representation of the model object 'Unset Reference'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference#getFeature Feature}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference#getValues Values}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getUnsetReference() - * @model - * @generated - */ -public interface UnsetReference extends EditAction { - /** - * Returns the value of the 'Feature' reference. - * - *

- * If the meaning of the 'Feature' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Feature' reference. - * @see #setFeature(EStructuralFeature) - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getUnsetReference_Feature() - * @model - * @generated - */ - EStructuralFeature getFeature(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference#getFeature Feature}' reference. - * - * - * @param value the new value of the 'Feature' reference. - * @see #getFeature() - * @generated - */ - void setFeature(EStructuralFeature value); - - /** - * Returns the value of the 'Values' reference list. - * The list contents are of type {@link org.eclipse.emf.eef.extended.editor.ReferenceableObject}. - * - *

- * If the meaning of the 'Values' reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Values' reference list. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#getUnsetReference_Values() - * @model - * @generated - */ - EList getValues(); - -} // UnsetReference diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/AddImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/AddImpl.java deleted file mode 100755 index afc377502..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/AddImpl.java +++ /dev/null @@ -1,222 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.modelingBot.EEFActions.Add; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; - -/** - * - * An implementation of the model object 'Add'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.AddImpl#getType Type}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.AddImpl#getEContainingFeature EContaining Feature}
  • - *
- *

- * - * @generated - */ -public class AddImpl extends EditActionImpl implements Add { - /** - * The cached value of the '{@link #getType() Type}' reference. - * - * - * @see #getType() - * @generated - * @ordered - */ - protected EClass type; - - /** - * The cached value of the '{@link #getEContainingFeature() EContaining Feature}' reference. - * - * - * @see #getEContainingFeature() - * @generated - * @ordered - */ - protected EStructuralFeature eContainingFeature; - - /** - * - * - * @generated - */ - protected AddImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.ADD; - } - - /** - * - * - * @generated - */ - public EClass getType() { - if (type != null && type.eIsProxy()) { - InternalEObject oldType = (InternalEObject)type; - type = (EClass)eResolveProxy(oldType); - if (type != oldType) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFActionsPackage.ADD__TYPE, oldType, type)); - } - } - return type; - } - - /** - * - * - * @generated - */ - public EClass basicGetType() { - return type; - } - - /** - * - * - * @generated - */ - public void setType(EClass newType) { - EClass oldType = type; - type = newType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.ADD__TYPE, oldType, type)); - } - - /** - * - * - * @generated - */ - public EStructuralFeature getEContainingFeature() { - if (eContainingFeature != null && eContainingFeature.eIsProxy()) { - InternalEObject oldEContainingFeature = (InternalEObject)eContainingFeature; - eContainingFeature = (EStructuralFeature)eResolveProxy(oldEContainingFeature); - if (eContainingFeature != oldEContainingFeature) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFActionsPackage.ADD__ECONTAINING_FEATURE, oldEContainingFeature, eContainingFeature)); - } - } - return eContainingFeature; - } - - /** - * - * - * @generated - */ - public EStructuralFeature basicGetEContainingFeature() { - return eContainingFeature; - } - - /** - * - * - * @generated - */ - public void setEContainingFeature(EStructuralFeature newEContainingFeature) { - EStructuralFeature oldEContainingFeature = eContainingFeature; - eContainingFeature = newEContainingFeature; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.ADD__ECONTAINING_FEATURE, oldEContainingFeature, eContainingFeature)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFActionsPackage.ADD__TYPE: - if (resolve) return getType(); - return basicGetType(); - case EEFActionsPackage.ADD__ECONTAINING_FEATURE: - if (resolve) return getEContainingFeature(); - return basicGetEContainingFeature(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFActionsPackage.ADD__TYPE: - setType((EClass)newValue); - return; - case EEFActionsPackage.ADD__ECONTAINING_FEATURE: - setEContainingFeature((EStructuralFeature)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFActionsPackage.ADD__TYPE: - setType((EClass)null); - return; - case EEFActionsPackage.ADD__ECONTAINING_FEATURE: - setEContainingFeature((EStructuralFeature)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFActionsPackage.ADD__TYPE: - return type != null; - case EEFActionsPackage.ADD__ECONTAINING_FEATURE: - return eContainingFeature != null; - } - return super.eIsSet(featureID); - } - -} //AddImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/CancelImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/CancelImpl.java deleted file mode 100755 index bc288484c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/CancelImpl.java +++ /dev/null @@ -1,162 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.EEFActions.Cancel; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.Processing; - -/** - * - * An implementation of the model object 'Cancel'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.CancelImpl#getProcessing Processing}
  • - *
- *

- * - * @generated - */ -public class CancelImpl extends EEFActionImpl implements Cancel { - /** - * The cached value of the '{@link #getProcessing() Processing}' reference. - * - * - * @see #getProcessing() - * @generated - * @ordered - */ - protected Processing processing; - /** - * - * - * @generated - */ - protected CancelImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.CANCEL; - } - - /** - * - * - * @generated - */ - public Processing getProcessing() { - if (processing != null && processing.eIsProxy()) { - InternalEObject oldProcessing = (InternalEObject)processing; - processing = (Processing)eResolveProxy(oldProcessing); - if (processing != oldProcessing) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFActionsPackage.CANCEL__PROCESSING, oldProcessing, processing)); - } - } - return processing; - } - - /** - * - * - * @generated - */ - public Processing basicGetProcessing() { - return processing; - } - - /** - * - * - * @generated - */ - public void setProcessing(Processing newProcessing) { - Processing oldProcessing = processing; - processing = newProcessing; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.CANCEL__PROCESSING, oldProcessing, processing)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFActionsPackage.CANCEL__PROCESSING: - if (resolve) return getProcessing(); - return basicGetProcessing(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFActionsPackage.CANCEL__PROCESSING: - setProcessing((Processing)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFActionsPackage.CANCEL__PROCESSING: - setProcessing((Processing)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFActionsPackage.CANCEL__PROCESSING: - return processing != null; - } - return super.eIsSet(featureID); - } - -} //CancelImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/CheckImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/CheckImpl.java deleted file mode 100755 index 40279e98f..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/CheckImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.EEFActions.Check; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; - -/** - * - * An implementation of the model object 'Check'. - * - *

- *

- * - * @generated - */ -public class CheckImpl extends EEFActionImpl implements Check { - /** - * - * - * @generated - */ - protected CheckImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.CHECK; - } - -} //CheckImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionImpl.java deleted file mode 100755 index 1b4740beb..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionImpl.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFAction; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; - -import org.eclipse.emf.eef.modelingBot.impl.ActionImpl; - -/** - * - * An implementation of the model object 'EEF Action'. - * - *

- *

- * - * @generated - */ -public abstract class EEFActionImpl extends ActionImpl implements EEFAction { - /** - * - * - * @generated - */ - protected EEFActionImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.EEF_ACTION; - } - -} //EEFActionImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionsFactoryImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionsFactoryImpl.java deleted file mode 100755 index 51207b87a..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionsFactoryImpl.java +++ /dev/null @@ -1,224 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.impl.EFactoryImpl; - -import org.eclipse.emf.ecore.plugin.EcorePlugin; - -import org.eclipse.emf.eef.modelingBot.EEFActions.*; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class EEFActionsFactoryImpl extends EFactoryImpl implements EEFActionsFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static EEFActionsFactory init() { - try { - EEFActionsFactory theEEFActionsFactory = (EEFActionsFactory)EPackage.Registry.INSTANCE.getEFactory("http://www.eclipse.org/emf/eef/test/EEFActions/1.0.0"); - if (theEEFActionsFactory != null) { - return theEEFActionsFactory; - } - } - catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new EEFActionsFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public EEFActionsFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case EEFActionsPackage.ADD: return createAdd(); - case EEFActionsPackage.REMOVE: return createRemove(); - case EEFActionsPackage.SET_ATTRIBUTE: return createSetAttribute(); - case EEFActionsPackage.UNSET_ATTRIBUTE: return createUnsetAttribute(); - case EEFActionsPackage.UNSET: return createUnset(); - case EEFActionsPackage.CANCEL: return createCancel(); - case EEFActionsPackage.CHECK: return createCheck(); - case EEFActionsPackage.OPEN_EEF_EDITOR: return createOpenEEFEditor(); - case EEFActionsPackage.SET_REFERENCE: return createSetReference(); - case EEFActionsPackage.UNSET_REFERENCE: return createUnsetReference(); - case EEFActionsPackage.MOVE_UP: return createMoveUp(); - case EEFActionsPackage.MOVE_DOWN: return createMoveDown(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public Add createAdd() { - AddImpl add = new AddImpl(); - return add; - } - - /** - * - * - * @generated - */ - public Remove createRemove() { - RemoveImpl remove = new RemoveImpl(); - return remove; - } - - /** - * - * - * @generated - */ - public SetAttribute createSetAttribute() { - SetAttributeImpl setAttribute = new SetAttributeImpl(); - return setAttribute; - } - - /** - * - * - * @generated - */ - public UnsetAttribute createUnsetAttribute() { - UnsetAttributeImpl unsetAttribute = new UnsetAttributeImpl(); - return unsetAttribute; - } - - /** - * - * - * @generated - */ - public Unset createUnset() { - UnsetImpl unset = new UnsetImpl(); - return unset; - } - - /** - * - * - * @generated - */ - public Cancel createCancel() { - CancelImpl cancel = new CancelImpl(); - return cancel; - } - - /** - * - * - * @generated - */ - public Check createCheck() { - CheckImpl check = new CheckImpl(); - return check; - } - - /** - * - * - * @generated - */ - public OpenEEFEditor createOpenEEFEditor() { - OpenEEFEditorImpl openEEFEditor = new OpenEEFEditorImpl(); - return openEEFEditor; - } - - /** - * - * - * @generated - */ - public SetReference createSetReference() { - SetReferenceImpl setReference = new SetReferenceImpl(); - return setReference; - } - - /** - * - * - * @generated - */ - public UnsetReference createUnsetReference() { - UnsetReferenceImpl unsetReference = new UnsetReferenceImpl(); - return unsetReference; - } - - /** - * - * - * @generated - */ - public MoveUp createMoveUp() { - MoveUpImpl moveUp = new MoveUpImpl(); - return moveUp; - } - - /** - * - * - * @generated - */ - public MoveDown createMoveDown() { - MoveDownImpl moveDown = new MoveDownImpl(); - return moveDown; - } - - /** - * - * - * @generated - */ - public EEFActionsPackage getEEFActionsPackage() { - return (EEFActionsPackage)getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static EEFActionsPackage getPackage() { - return EEFActionsPackage.eINSTANCE; - } - -} //EEFActionsFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionsPackageImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionsPackageImpl.java deleted file mode 100755 index d4bd4a8c6..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EEFActionsPackageImpl.java +++ /dev/null @@ -1,649 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.impl.EPackageImpl; -import org.eclipse.emf.eef.components.ComponentsPackage; -import org.eclipse.emf.eef.extended.editor.EditorPackage; -import org.eclipse.emf.eef.extended.query.QueryPackage; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.Add; -import org.eclipse.emf.eef.modelingBot.EEFActions.Cancel; -import org.eclipse.emf.eef.modelingBot.EEFActions.Check; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFAction; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsFactory; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.EditAction; -import org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown; -import org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp; -import org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor; -import org.eclipse.emf.eef.modelingBot.EEFActions.Remove; -import org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute; -import org.eclipse.emf.eef.modelingBot.EEFActions.SetReference; -import org.eclipse.emf.eef.modelingBot.EEFActions.Unset; -import org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute; -import org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl; -import org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class EEFActionsPackageImpl extends EPackageImpl implements EEFActionsPackage { - /** - * - * - * @generated - */ - private EClass eefActionEClass = null; - - /** - * - * - * @generated - */ - private EClass editActionEClass = null; - - /** - * - * - * @generated - */ - private EClass addEClass = null; - - /** - * - * - * @generated - */ - private EClass removeEClass = null; - - /** - * - * - * @generated - */ - private EClass setAttributeEClass = null; - - /** - * - * - * @generated - */ - private EClass unsetAttributeEClass = null; - - /** - * - * - * @generated - */ - private EClass unsetEClass = null; - - /** - * - * - * @generated - */ - private EClass cancelEClass = null; - - /** - * - * - * @generated - */ - private EClass checkEClass = null; - - /** - * - * - * @generated - */ - private EClass openEEFEditorEClass = null; - - /** - * - * - * @generated - */ - private EClass setReferenceEClass = null; - - /** - * - * - * @generated - */ - private EClass unsetReferenceEClass = null; - - /** - * - * - * @generated - */ - private EClass moveUpEClass = null; - - /** - * - * - * @generated - */ - private EClass moveDownEClass = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage#eNS_URI - * @see #init() - * @generated - */ - private EEFActionsPackageImpl() { - super(eNS_URI, EEFActionsFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link EEFActionsPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static EEFActionsPackage init() { - if (isInited) return (EEFActionsPackage)EPackage.Registry.INSTANCE.getEPackage(EEFActionsPackage.eNS_URI); - - // Obtain or create and register package - EEFActionsPackageImpl theEEFActionsPackage = (EEFActionsPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof EEFActionsPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new EEFActionsPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - EditorPackage.eINSTANCE.eClass(); - QueryPackage.eINSTANCE.eClass(); - - // Obtain or create and register interdependencies - ModelingBotPackageImpl theModelingBotPackage = (ModelingBotPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(ModelingBotPackage.eNS_URI) instanceof ModelingBotPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(ModelingBotPackage.eNS_URI) : ModelingBotPackage.eINSTANCE); - EclipseActionsPackageImpl theEclipseActionsPackage = (EclipseActionsPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(EclipseActionsPackage.eNS_URI) instanceof EclipseActionsPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(EclipseActionsPackage.eNS_URI) : EclipseActionsPackage.eINSTANCE); - - // Create package meta-data objects - theEEFActionsPackage.createPackageContents(); - theModelingBotPackage.createPackageContents(); - theEclipseActionsPackage.createPackageContents(); - - // Initialize created meta-data - theEEFActionsPackage.initializePackageContents(); - theModelingBotPackage.initializePackageContents(); - theEclipseActionsPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theEEFActionsPackage.freeze(); - - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(EEFActionsPackage.eNS_URI, theEEFActionsPackage); - return theEEFActionsPackage; - } - - /** - * - * - * @generated - */ - public EClass getEEFAction() { - return eefActionEClass; - } - - /** - * - * - * @generated - */ - public EClass getEditAction() { - return editActionEClass; - } - - /** - * - * - * @generated - */ - public EReference getEditAction_PropertiesEditionElement() { - return (EReference)editActionEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getEditAction_ReferenceableObject() { - return (EReference)editActionEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getAdd() { - return addEClass; - } - - /** - * - * - * @generated - */ - public EReference getAdd_Type() { - return (EReference)addEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getAdd_EContainingFeature() { - return (EReference)addEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getRemove() { - return removeEClass; - } - - /** - * - * - * @generated - */ - public EClass getSetAttribute() { - return setAttributeEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getSetAttribute_Values() { - return (EAttribute)setAttributeEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getSetAttribute_EContainingFeature() { - return (EReference)setAttributeEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getUnsetAttribute() { - return unsetAttributeEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getUnsetAttribute_Values() { - return (EAttribute)unsetAttributeEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getUnsetAttribute_EContainingFeature() { - return (EReference)unsetAttributeEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getUnset() { - return unsetEClass; - } - - /** - * - * - * @generated - */ - public EReference getUnset_Feature() { - return (EReference)unsetEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getCancel() { - return cancelEClass; - } - - /** - * - * - * @generated - */ - public EReference getCancel_Processing() { - return (EReference)cancelEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getCheck() { - return checkEClass; - } - - /** - * - * - * @generated - */ - public EClass getOpenEEFEditor() { - return openEEFEditorEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getOpenEEFEditor_EditorName() { - return (EAttribute)openEEFEditorEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getSetReference() { - return setReferenceEClass; - } - - /** - * - * - * @generated - */ - public EReference getSetReference_Values() { - return (EReference)setReferenceEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getSetReference_EContainingFeature() { - return (EReference)setReferenceEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getUnsetReference() { - return unsetReferenceEClass; - } - - /** - * - * - * @generated - */ - public EReference getUnsetReference_Feature() { - return (EReference)unsetReferenceEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getUnsetReference_Values() { - return (EReference)unsetReferenceEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getMoveUp() { - return moveUpEClass; - } - - /** - * - * - * @generated - */ - public EClass getMoveDown() { - return moveDownEClass; - } - - /** - * - * - * @generated - */ - public EEFActionsFactory getEEFActionsFactory() { - return (EEFActionsFactory)getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) return; - isCreated = true; - - // Create classes and their features - eefActionEClass = createEClass(EEF_ACTION); - - editActionEClass = createEClass(EDIT_ACTION); - createEReference(editActionEClass, EDIT_ACTION__PROPERTIES_EDITION_ELEMENT); - createEReference(editActionEClass, EDIT_ACTION__REFERENCEABLE_OBJECT); - - addEClass = createEClass(ADD); - createEReference(addEClass, ADD__TYPE); - createEReference(addEClass, ADD__ECONTAINING_FEATURE); - - removeEClass = createEClass(REMOVE); - - setAttributeEClass = createEClass(SET_ATTRIBUTE); - createEAttribute(setAttributeEClass, SET_ATTRIBUTE__VALUES); - createEReference(setAttributeEClass, SET_ATTRIBUTE__ECONTAINING_FEATURE); - - unsetAttributeEClass = createEClass(UNSET_ATTRIBUTE); - createEAttribute(unsetAttributeEClass, UNSET_ATTRIBUTE__VALUES); - createEReference(unsetAttributeEClass, UNSET_ATTRIBUTE__ECONTAINING_FEATURE); - - unsetEClass = createEClass(UNSET); - createEReference(unsetEClass, UNSET__FEATURE); - - cancelEClass = createEClass(CANCEL); - createEReference(cancelEClass, CANCEL__PROCESSING); - - checkEClass = createEClass(CHECK); - - openEEFEditorEClass = createEClass(OPEN_EEF_EDITOR); - createEAttribute(openEEFEditorEClass, OPEN_EEF_EDITOR__EDITOR_NAME); - - setReferenceEClass = createEClass(SET_REFERENCE); - createEReference(setReferenceEClass, SET_REFERENCE__VALUES); - createEReference(setReferenceEClass, SET_REFERENCE__ECONTAINING_FEATURE); - - unsetReferenceEClass = createEClass(UNSET_REFERENCE); - createEReference(unsetReferenceEClass, UNSET_REFERENCE__FEATURE); - createEReference(unsetReferenceEClass, UNSET_REFERENCE__VALUES); - - moveUpEClass = createEClass(MOVE_UP); - - moveDownEClass = createEClass(MOVE_DOWN); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - ModelingBotPackage theModelingBotPackage = (ModelingBotPackage)EPackage.Registry.INSTANCE.getEPackage(ModelingBotPackage.eNS_URI); - EditorPackage theEditorPackage = (EditorPackage)EPackage.Registry.INSTANCE.getEPackage(EditorPackage.eNS_URI); - ComponentsPackage theComponentsPackage = (ComponentsPackage)EPackage.Registry.INSTANCE.getEPackage(ComponentsPackage.eNS_URI); - EcorePackage theEcorePackage = (EcorePackage)EPackage.Registry.INSTANCE.getEPackage(EcorePackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - eefActionEClass.getESuperTypes().add(theModelingBotPackage.getAction()); - editActionEClass.getESuperTypes().add(this.getEEFAction()); - editActionEClass.getESuperTypes().add(theEditorPackage.getReferenceableObject()); - addEClass.getESuperTypes().add(this.getEditAction()); - removeEClass.getESuperTypes().add(this.getEditAction()); - setAttributeEClass.getESuperTypes().add(this.getEditAction()); - unsetAttributeEClass.getESuperTypes().add(this.getEditAction()); - unsetEClass.getESuperTypes().add(this.getEditAction()); - cancelEClass.getESuperTypes().add(this.getEEFAction()); - checkEClass.getESuperTypes().add(this.getEEFAction()); - openEEFEditorEClass.getESuperTypes().add(this.getEEFAction()); - setReferenceEClass.getESuperTypes().add(this.getEditAction()); - unsetReferenceEClass.getESuperTypes().add(this.getEditAction()); - moveUpEClass.getESuperTypes().add(this.getEditAction()); - moveDownEClass.getESuperTypes().add(this.getEditAction()); - - // Initialize classes and features; add operations and parameters - initEClass(eefActionEClass, EEFAction.class, "EEFAction", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(editActionEClass, EditAction.class, "EditAction", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getEditAction_PropertiesEditionElement(), theComponentsPackage.getPropertiesEditionElement(), null, "propertiesEditionElement", null, 0, 1, EditAction.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getEditAction_ReferenceableObject(), theEditorPackage.getReferenceableObject(), null, "referenceableObject", null, 0, 1, EditAction.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(addEClass, Add.class, "Add", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getAdd_Type(), theEcorePackage.getEClass(), null, "type", null, 0, 1, Add.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getAdd_EContainingFeature(), theEcorePackage.getEStructuralFeature(), null, "eContainingFeature", null, 0, 1, Add.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(removeEClass, Remove.class, "Remove", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(setAttributeEClass, SetAttribute.class, "SetAttribute", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getSetAttribute_Values(), theEcorePackage.getEString(), "values", null, 0, -1, SetAttribute.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getSetAttribute_EContainingFeature(), theEcorePackage.getEStructuralFeature(), null, "eContainingFeature", null, 0, 1, SetAttribute.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(unsetAttributeEClass, UnsetAttribute.class, "UnsetAttribute", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getUnsetAttribute_Values(), theEcorePackage.getEString(), "values", null, 0, -1, UnsetAttribute.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getUnsetAttribute_EContainingFeature(), theEcorePackage.getEStructuralFeature(), null, "eContainingFeature", null, 0, 1, UnsetAttribute.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(unsetEClass, Unset.class, "Unset", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getUnset_Feature(), theEcorePackage.getEStructuralFeature(), null, "feature", null, 0, 1, Unset.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(cancelEClass, Cancel.class, "Cancel", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getCancel_Processing(), theModelingBotPackage.getProcessing(), null, "processing", null, 0, 1, Cancel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(checkEClass, Check.class, "Check", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(openEEFEditorEClass, OpenEEFEditor.class, "OpenEEFEditor", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getOpenEEFEditor_EditorName(), theEcorePackage.getEString(), "editorName", null, 0, 1, OpenEEFEditor.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(setReferenceEClass, SetReference.class, "SetReference", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getSetReference_Values(), theEditorPackage.getReferenceableObject(), null, "values", null, 0, -1, SetReference.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getSetReference_EContainingFeature(), theEcorePackage.getEStructuralFeature(), null, "eContainingFeature", null, 0, 1, SetReference.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(unsetReferenceEClass, UnsetReference.class, "UnsetReference", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getUnsetReference_Feature(), theEcorePackage.getEStructuralFeature(), null, "feature", null, 0, 1, UnsetReference.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getUnsetReference_Values(), theEditorPackage.getReferenceableObject(), null, "values", null, 0, -1, UnsetReference.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(moveUpEClass, MoveUp.class, "MoveUp", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(moveDownEClass, MoveDown.class, "MoveDown", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - } - -} //EEFActionsPackageImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EditActionImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EditActionImpl.java deleted file mode 100755 index 896eb9967..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/EditActionImpl.java +++ /dev/null @@ -1,227 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.components.PropertiesEditionElement; - -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.EditAction; - -/** - * - * An implementation of the model object 'Edit Action'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.EditActionImpl#getPropertiesEditionElement Properties Edition Element}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.EditActionImpl#getReferenceableObject Referenceable Object}
  • - *
- *

- * - * @generated - */ -public abstract class EditActionImpl extends EEFActionImpl implements EditAction { - /** - * The cached value of the '{@link #getPropertiesEditionElement() Properties Edition Element}' reference. - * - * - * @see #getPropertiesEditionElement() - * @generated - * @ordered - */ - protected PropertiesEditionElement propertiesEditionElement; - - /** - * The cached value of the '{@link #getReferenceableObject() Referenceable Object}' reference. - * - * - * @see #getReferenceableObject() - * @generated - * @ordered - */ - protected ReferenceableObject referenceableObject; - - /** - * - * - * @generated - */ - protected EditActionImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.EDIT_ACTION; - } - - /** - * - * - * @generated - */ - public PropertiesEditionElement getPropertiesEditionElement() { - if (propertiesEditionElement != null && propertiesEditionElement.eIsProxy()) { - InternalEObject oldPropertiesEditionElement = (InternalEObject)propertiesEditionElement; - propertiesEditionElement = (PropertiesEditionElement)eResolveProxy(oldPropertiesEditionElement); - if (propertiesEditionElement != oldPropertiesEditionElement) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFActionsPackage.EDIT_ACTION__PROPERTIES_EDITION_ELEMENT, oldPropertiesEditionElement, propertiesEditionElement)); - } - } - return propertiesEditionElement; - } - - /** - * - * - * @generated - */ - public PropertiesEditionElement basicGetPropertiesEditionElement() { - return propertiesEditionElement; - } - - /** - * - * - * @generated - */ - public void setPropertiesEditionElement(PropertiesEditionElement newPropertiesEditionElement) { - PropertiesEditionElement oldPropertiesEditionElement = propertiesEditionElement; - propertiesEditionElement = newPropertiesEditionElement; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.EDIT_ACTION__PROPERTIES_EDITION_ELEMENT, oldPropertiesEditionElement, propertiesEditionElement)); - } - - /** - * - * - * @generated - */ - public ReferenceableObject getReferenceableObject() { - if (referenceableObject != null && referenceableObject.eIsProxy()) { - InternalEObject oldReferenceableObject = (InternalEObject)referenceableObject; - referenceableObject = (ReferenceableObject)eResolveProxy(oldReferenceableObject); - if (referenceableObject != oldReferenceableObject) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFActionsPackage.EDIT_ACTION__REFERENCEABLE_OBJECT, oldReferenceableObject, referenceableObject)); - } - } - return referenceableObject; - } - - /** - * - * - * @generated - */ - public ReferenceableObject basicGetReferenceableObject() { - return referenceableObject; - } - - /** - * - * - * @generated - */ - public void setReferenceableObject(ReferenceableObject newReferenceableObject) { - ReferenceableObject oldReferenceableObject = referenceableObject; - referenceableObject = newReferenceableObject; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.EDIT_ACTION__REFERENCEABLE_OBJECT, oldReferenceableObject, referenceableObject)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFActionsPackage.EDIT_ACTION__PROPERTIES_EDITION_ELEMENT: - if (resolve) return getPropertiesEditionElement(); - return basicGetPropertiesEditionElement(); - case EEFActionsPackage.EDIT_ACTION__REFERENCEABLE_OBJECT: - if (resolve) return getReferenceableObject(); - return basicGetReferenceableObject(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFActionsPackage.EDIT_ACTION__PROPERTIES_EDITION_ELEMENT: - setPropertiesEditionElement((PropertiesEditionElement)newValue); - return; - case EEFActionsPackage.EDIT_ACTION__REFERENCEABLE_OBJECT: - setReferenceableObject((ReferenceableObject)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFActionsPackage.EDIT_ACTION__PROPERTIES_EDITION_ELEMENT: - setPropertiesEditionElement((PropertiesEditionElement)null); - return; - case EEFActionsPackage.EDIT_ACTION__REFERENCEABLE_OBJECT: - setReferenceableObject((ReferenceableObject)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFActionsPackage.EDIT_ACTION__PROPERTIES_EDITION_ELEMENT: - return propertiesEditionElement != null; - case EEFActionsPackage.EDIT_ACTION__REFERENCEABLE_OBJECT: - return referenceableObject != null; - } - return super.eIsSet(featureID); - } - -} //EditActionImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/MoveDownImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/MoveDownImpl.java deleted file mode 100644 index fa669621b..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/MoveDownImpl.java +++ /dev/null @@ -1,43 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown; - -/** - * - * An implementation of the model object 'Move Down'. - * - *

- *

- * - * @generated - */ -public class MoveDownImpl extends EditActionImpl implements MoveDown { - /** - * - * - * @generated - */ - protected MoveDownImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.MOVE_DOWN; - } - -} //MoveDownImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/MoveUpImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/MoveUpImpl.java deleted file mode 100644 index a88f2c480..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/MoveUpImpl.java +++ /dev/null @@ -1,43 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp; - -/** - * - * An implementation of the model object 'Move Up'. - * - *

- *

- * - * @generated - */ -public class MoveUpImpl extends EditActionImpl implements MoveUp { - /** - * - * - * @generated - */ - protected MoveUpImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.MOVE_UP; - } - -} //MoveUpImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/OpenEEFEditorImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/OpenEEFEditorImpl.java deleted file mode 100755 index d45df9511..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/OpenEEFEditorImpl.java +++ /dev/null @@ -1,170 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor; - -/** - * - * An implementation of the model object 'Open EEF Editor'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.OpenEEFEditorImpl#getEditorName Editor Name}
  • - *
- *

- * - * @generated - */ -public class OpenEEFEditorImpl extends EEFActionImpl implements OpenEEFEditor { - /** - * The default value of the '{@link #getEditorName() Editor Name}' attribute. - * - * - * @see #getEditorName() - * @generated - * @ordered - */ - protected static final String EDITOR_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getEditorName() Editor Name}' attribute. - * - * - * @see #getEditorName() - * @generated - * @ordered - */ - protected String editorName = EDITOR_NAME_EDEFAULT; - - /** - * - * - * @generated - */ - protected OpenEEFEditorImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.OPEN_EEF_EDITOR; - } - - /** - * - * - * @generated - */ - public String getEditorName() { - return editorName; - } - - /** - * - * - * @generated - */ - public void setEditorName(String newEditorName) { - String oldEditorName = editorName; - editorName = newEditorName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.OPEN_EEF_EDITOR__EDITOR_NAME, oldEditorName, editorName)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFActionsPackage.OPEN_EEF_EDITOR__EDITOR_NAME: - return getEditorName(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFActionsPackage.OPEN_EEF_EDITOR__EDITOR_NAME: - setEditorName((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFActionsPackage.OPEN_EEF_EDITOR__EDITOR_NAME: - setEditorName(EDITOR_NAME_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFActionsPackage.OPEN_EEF_EDITOR__EDITOR_NAME: - return EDITOR_NAME_EDEFAULT == null ? editorName != null : !EDITOR_NAME_EDEFAULT.equals(editorName); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (editorName: "); - result.append(editorName); - result.append(')'); - return result.toString(); - } - -} //OpenEEFEditorImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/RemoveImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/RemoveImpl.java deleted file mode 100755 index 0ea3ed0df..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/RemoveImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.Remove; - -/** - * - * An implementation of the model object 'Remove'. - * - *

- *

- * - * @generated - */ -public class RemoveImpl extends EditActionImpl implements Remove { - /** - * - * - * @generated - */ - protected RemoveImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.REMOVE; - } - -} //RemoveImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/SetAttributeImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/SetAttributeImpl.java deleted file mode 100755 index 9c291b90b..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/SetAttributeImpl.java +++ /dev/null @@ -1,218 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import java.util.Collection; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.ecore.util.EDataTypeUniqueEList; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute; - -/** - * - * An implementation of the model object 'Set Attribute'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetAttributeImpl#getValues Values}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetAttributeImpl#getEContainingFeature EContaining Feature}
  • - *
- *

- * - * @generated - */ -public class SetAttributeImpl extends EditActionImpl implements SetAttribute { - /** - * The cached value of the '{@link #getValues() Values}' attribute list. - * - * - * @see #getValues() - * @generated - * @ordered - */ - protected EList values; - - /** - * The cached value of the '{@link #getEContainingFeature() EContaining Feature}' reference. - * - * - * @see #getEContainingFeature() - * @generated - * @ordered - */ - protected EStructuralFeature eContainingFeature; - - /** - * - * - * @generated - */ - protected SetAttributeImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.SET_ATTRIBUTE; - } - - /** - * - * - * @generated - */ - public EList getValues() { - if (values == null) { - values = new EDataTypeUniqueEList(String.class, this, EEFActionsPackage.SET_ATTRIBUTE__VALUES); - } - return values; - } - - /** - * - * - * @generated - */ - public EStructuralFeature getEContainingFeature() { - if (eContainingFeature != null && eContainingFeature.eIsProxy()) { - InternalEObject oldEContainingFeature = (InternalEObject)eContainingFeature; - eContainingFeature = (EStructuralFeature)eResolveProxy(oldEContainingFeature); - if (eContainingFeature != oldEContainingFeature) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFActionsPackage.SET_ATTRIBUTE__ECONTAINING_FEATURE, oldEContainingFeature, eContainingFeature)); - } - } - return eContainingFeature; - } - - /** - * - * - * @generated - */ - public EStructuralFeature basicGetEContainingFeature() { - return eContainingFeature; - } - - /** - * - * - * @generated - */ - public void setEContainingFeature(EStructuralFeature newEContainingFeature) { - EStructuralFeature oldEContainingFeature = eContainingFeature; - eContainingFeature = newEContainingFeature; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.SET_ATTRIBUTE__ECONTAINING_FEATURE, oldEContainingFeature, eContainingFeature)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFActionsPackage.SET_ATTRIBUTE__VALUES: - return getValues(); - case EEFActionsPackage.SET_ATTRIBUTE__ECONTAINING_FEATURE: - if (resolve) return getEContainingFeature(); - return basicGetEContainingFeature(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFActionsPackage.SET_ATTRIBUTE__VALUES: - getValues().clear(); - getValues().addAll((Collection)newValue); - return; - case EEFActionsPackage.SET_ATTRIBUTE__ECONTAINING_FEATURE: - setEContainingFeature((EStructuralFeature)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFActionsPackage.SET_ATTRIBUTE__VALUES: - getValues().clear(); - return; - case EEFActionsPackage.SET_ATTRIBUTE__ECONTAINING_FEATURE: - setEContainingFeature((EStructuralFeature)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFActionsPackage.SET_ATTRIBUTE__VALUES: - return values != null && !values.isEmpty(); - case EEFActionsPackage.SET_ATTRIBUTE__ECONTAINING_FEATURE: - return eContainingFeature != null; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (values: "); - result.append(values); - result.append(')'); - return result.toString(); - } - -} //SetAttributeImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/SetReferenceImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/SetReferenceImpl.java deleted file mode 100755 index 750bca622..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/SetReferenceImpl.java +++ /dev/null @@ -1,204 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import java.util.Collection; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.ecore.util.EObjectResolvingEList; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.SetReference; - -/** - * - * An implementation of the model object 'Set Reference'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetReferenceImpl#getValues Values}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.SetReferenceImpl#getEContainingFeature EContaining Feature}
  • - *
- *

- * - * @generated - */ -public class SetReferenceImpl extends EditActionImpl implements SetReference { - /** - * The cached value of the '{@link #getValues() Values}' reference list. - * - * - * @see #getValues() - * @generated - * @ordered - */ - protected EList values; - - /** - * The cached value of the '{@link #getEContainingFeature() EContaining Feature}' reference. - * - * - * @see #getEContainingFeature() - * @generated - * @ordered - */ - protected EStructuralFeature eContainingFeature; - - /** - * - * - * @generated - */ - protected SetReferenceImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.SET_REFERENCE; - } - - /** - * - * - * @generated - */ - public EList getValues() { - if (values == null) { - values = new EObjectResolvingEList(ReferenceableObject.class, this, EEFActionsPackage.SET_REFERENCE__VALUES); - } - return values; - } - - /** - * - * - * @generated - */ - public EStructuralFeature getEContainingFeature() { - if (eContainingFeature != null && eContainingFeature.eIsProxy()) { - InternalEObject oldEContainingFeature = (InternalEObject)eContainingFeature; - eContainingFeature = (EStructuralFeature)eResolveProxy(oldEContainingFeature); - if (eContainingFeature != oldEContainingFeature) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFActionsPackage.SET_REFERENCE__ECONTAINING_FEATURE, oldEContainingFeature, eContainingFeature)); - } - } - return eContainingFeature; - } - - /** - * - * - * @generated - */ - public EStructuralFeature basicGetEContainingFeature() { - return eContainingFeature; - } - - /** - * - * - * @generated - */ - public void setEContainingFeature(EStructuralFeature newEContainingFeature) { - EStructuralFeature oldEContainingFeature = eContainingFeature; - eContainingFeature = newEContainingFeature; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.SET_REFERENCE__ECONTAINING_FEATURE, oldEContainingFeature, eContainingFeature)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFActionsPackage.SET_REFERENCE__VALUES: - return getValues(); - case EEFActionsPackage.SET_REFERENCE__ECONTAINING_FEATURE: - if (resolve) return getEContainingFeature(); - return basicGetEContainingFeature(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFActionsPackage.SET_REFERENCE__VALUES: - getValues().clear(); - getValues().addAll((Collection)newValue); - return; - case EEFActionsPackage.SET_REFERENCE__ECONTAINING_FEATURE: - setEContainingFeature((EStructuralFeature)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFActionsPackage.SET_REFERENCE__VALUES: - getValues().clear(); - return; - case EEFActionsPackage.SET_REFERENCE__ECONTAINING_FEATURE: - setEContainingFeature((EStructuralFeature)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFActionsPackage.SET_REFERENCE__VALUES: - return values != null && !values.isEmpty(); - case EEFActionsPackage.SET_REFERENCE__ECONTAINING_FEATURE: - return eContainingFeature != null; - } - return super.eIsSet(featureID); - } - -} //SetReferenceImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetAttributeImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetAttributeImpl.java deleted file mode 100644 index 0a87b69bb..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetAttributeImpl.java +++ /dev/null @@ -1,217 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.ecore.util.EDataTypeUniqueEList; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute; - -/** - * - * An implementation of the model object 'Unset Attribute'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetAttributeImpl#getValues Values}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetAttributeImpl#getEContainingFeature EContaining Feature}
  • - *
- *

- * - * @generated - */ -public class UnsetAttributeImpl extends EditActionImpl implements UnsetAttribute { - /** - * The cached value of the '{@link #getValues() Values}' attribute list. - * - * - * @see #getValues() - * @generated - * @ordered - */ - protected EList values; - - /** - * The cached value of the '{@link #getEContainingFeature() EContaining Feature}' reference. - * - * - * @see #getEContainingFeature() - * @generated - * @ordered - */ - protected EStructuralFeature eContainingFeature; - - /** - * - * - * @generated - */ - protected UnsetAttributeImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.UNSET_ATTRIBUTE; - } - - /** - * - * - * @generated - */ - public EList getValues() { - if (values == null) { - values = new EDataTypeUniqueEList(String.class, this, EEFActionsPackage.UNSET_ATTRIBUTE__VALUES); - } - return values; - } - - /** - * - * - * @generated - */ - public EStructuralFeature getEContainingFeature() { - if (eContainingFeature != null && eContainingFeature.eIsProxy()) { - InternalEObject oldEContainingFeature = (InternalEObject)eContainingFeature; - eContainingFeature = (EStructuralFeature)eResolveProxy(oldEContainingFeature); - if (eContainingFeature != oldEContainingFeature) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFActionsPackage.UNSET_ATTRIBUTE__ECONTAINING_FEATURE, oldEContainingFeature, eContainingFeature)); - } - } - return eContainingFeature; - } - - /** - * - * - * @generated - */ - public EStructuralFeature basicGetEContainingFeature() { - return eContainingFeature; - } - - /** - * - * - * @generated - */ - public void setEContainingFeature(EStructuralFeature newEContainingFeature) { - EStructuralFeature oldEContainingFeature = eContainingFeature; - eContainingFeature = newEContainingFeature; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.UNSET_ATTRIBUTE__ECONTAINING_FEATURE, oldEContainingFeature, eContainingFeature)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFActionsPackage.UNSET_ATTRIBUTE__VALUES: - return getValues(); - case EEFActionsPackage.UNSET_ATTRIBUTE__ECONTAINING_FEATURE: - if (resolve) return getEContainingFeature(); - return basicGetEContainingFeature(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFActionsPackage.UNSET_ATTRIBUTE__VALUES: - getValues().clear(); - getValues().addAll((Collection)newValue); - return; - case EEFActionsPackage.UNSET_ATTRIBUTE__ECONTAINING_FEATURE: - setEContainingFeature((EStructuralFeature)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFActionsPackage.UNSET_ATTRIBUTE__VALUES: - getValues().clear(); - return; - case EEFActionsPackage.UNSET_ATTRIBUTE__ECONTAINING_FEATURE: - setEContainingFeature((EStructuralFeature)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFActionsPackage.UNSET_ATTRIBUTE__VALUES: - return values != null && !values.isEmpty(); - case EEFActionsPackage.UNSET_ATTRIBUTE__ECONTAINING_FEATURE: - return eContainingFeature != null; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (values: "); - result.append(values); - result.append(')'); - return result.toString(); - } - -} //UnsetAttributeImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetImpl.java deleted file mode 100755 index 05f28b134..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetImpl.java +++ /dev/null @@ -1,162 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.Unset; - -/** - * - * An implementation of the model object 'Unset'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetImpl#getFeature Feature}
  • - *
- *

- * - * @generated - */ -public class UnsetImpl extends EditActionImpl implements Unset { - /** - * The cached value of the '{@link #getFeature() Feature}' reference. - * - * - * @see #getFeature() - * @generated - * @ordered - */ - protected EStructuralFeature feature; - - /** - * - * - * @generated - */ - protected UnsetImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.UNSET; - } - - /** - * - * - * @generated - */ - public EStructuralFeature getFeature() { - if (feature != null && feature.eIsProxy()) { - InternalEObject oldFeature = (InternalEObject)feature; - feature = (EStructuralFeature)eResolveProxy(oldFeature); - if (feature != oldFeature) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFActionsPackage.UNSET__FEATURE, oldFeature, feature)); - } - } - return feature; - } - - /** - * - * - * @generated - */ - public EStructuralFeature basicGetFeature() { - return feature; - } - - /** - * - * - * @generated - */ - public void setFeature(EStructuralFeature newFeature) { - EStructuralFeature oldFeature = feature; - feature = newFeature; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.UNSET__FEATURE, oldFeature, feature)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFActionsPackage.UNSET__FEATURE: - if (resolve) return getFeature(); - return basicGetFeature(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFActionsPackage.UNSET__FEATURE: - setFeature((EStructuralFeature)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFActionsPackage.UNSET__FEATURE: - setFeature((EStructuralFeature)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFActionsPackage.UNSET__FEATURE: - return feature != null; - } - return super.eIsSet(featureID); - } - -} //UnsetImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetReferenceImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetReferenceImpl.java deleted file mode 100644 index 89f1a7596..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/impl/UnsetReferenceImpl.java +++ /dev/null @@ -1,200 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EEFActions.impl; - -import java.util.Collection; -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.ecore.util.EObjectResolvingEList; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; -import org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference; - -/** - * - * An implementation of the model object 'Unset Reference'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetReferenceImpl#getFeature Feature}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EEFActions.impl.UnsetReferenceImpl#getValues Values}
  • - *
- *

- * - * @generated - */ -public class UnsetReferenceImpl extends EditActionImpl implements UnsetReference { - /** - * The cached value of the '{@link #getFeature() Feature}' reference. - * - * - * @see #getFeature() - * @generated - * @ordered - */ - protected EStructuralFeature feature; - - /** - * The cached value of the '{@link #getValues() Values}' reference list. - * - * - * @see #getValues() - * @generated - * @ordered - */ - protected EList values; - - /** - * - * - * @generated - */ - protected UnsetReferenceImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EEFActionsPackage.Literals.UNSET_REFERENCE; - } - - /** - * - * - * @generated - */ - public EStructuralFeature getFeature() { - if (feature != null && feature.eIsProxy()) { - InternalEObject oldFeature = (InternalEObject)feature; - feature = (EStructuralFeature)eResolveProxy(oldFeature); - if (feature != oldFeature) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EEFActionsPackage.UNSET_REFERENCE__FEATURE, oldFeature, feature)); - } - } - return feature; - } - - /** - * - * - * @generated - */ - public EStructuralFeature basicGetFeature() { - return feature; - } - - /** - * - * - * @generated - */ - public void setFeature(EStructuralFeature newFeature) { - EStructuralFeature oldFeature = feature; - feature = newFeature; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EEFActionsPackage.UNSET_REFERENCE__FEATURE, oldFeature, feature)); - } - - /** - * - * - * @generated - */ - public EList getValues() { - if (values == null) { - values = new EObjectResolvingEList(ReferenceableObject.class, this, EEFActionsPackage.UNSET_REFERENCE__VALUES); - } - return values; - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EEFActionsPackage.UNSET_REFERENCE__FEATURE: - if (resolve) return getFeature(); - return basicGetFeature(); - case EEFActionsPackage.UNSET_REFERENCE__VALUES: - return getValues(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EEFActionsPackage.UNSET_REFERENCE__FEATURE: - setFeature((EStructuralFeature)newValue); - return; - case EEFActionsPackage.UNSET_REFERENCE__VALUES: - getValues().clear(); - getValues().addAll((Collection)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EEFActionsPackage.UNSET_REFERENCE__FEATURE: - setFeature((EStructuralFeature)null); - return; - case EEFActionsPackage.UNSET_REFERENCE__VALUES: - getValues().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EEFActionsPackage.UNSET_REFERENCE__FEATURE: - return feature != null; - case EEFActionsPackage.UNSET_REFERENCE__VALUES: - return values != null && !values.isEmpty(); - } - return super.eIsSet(featureID); - } - -} //UnsetReferenceImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/util/EEFActionsAdapterFactory.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/util/EEFActionsAdapterFactory.java deleted file mode 100755 index 2d529f592..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/util/EEFActionsAdapterFactory.java +++ /dev/null @@ -1,439 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; - -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.DocumentedElement; - -import org.eclipse.emf.eef.modelingBot.EEFActions.*; -import org.eclipse.emf.eef.modelingBot.Processing; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage - * @generated - */ -public class EEFActionsAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static EEFActionsPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public EEFActionsAdapterFactory() { - if (modelPackage == null) { - modelPackage = EEFActionsPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject)object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected EEFActionsSwitch modelSwitch = - new EEFActionsSwitch() { - @Override - public Adapter caseEEFAction(EEFAction object) { - return createEEFActionAdapter(); - } - @Override - public Adapter caseEditAction(EditAction object) { - return createEditActionAdapter(); - } - @Override - public Adapter caseAdd(Add object) { - return createAddAdapter(); - } - @Override - public Adapter caseRemove(Remove object) { - return createRemoveAdapter(); - } - @Override - public Adapter caseSetAttribute(SetAttribute object) { - return createSetAttributeAdapter(); - } - @Override - public Adapter caseUnsetAttribute(UnsetAttribute object) { - return createUnsetAttributeAdapter(); - } - @Override - public Adapter caseUnset(Unset object) { - return createUnsetAdapter(); - } - @Override - public Adapter caseCancel(Cancel object) { - return createCancelAdapter(); - } - @Override - public Adapter caseCheck(Check object) { - return createCheckAdapter(); - } - @Override - public Adapter caseOpenEEFEditor(OpenEEFEditor object) { - return createOpenEEFEditorAdapter(); - } - @Override - public Adapter caseSetReference(SetReference object) { - return createSetReferenceAdapter(); - } - @Override - public Adapter caseUnsetReference(UnsetReference object) { - return createUnsetReferenceAdapter(); - } - @Override - public Adapter caseMoveUp(MoveUp object) { - return createMoveUpAdapter(); - } - @Override - public Adapter caseMoveDown(MoveDown object) { - return createMoveDownAdapter(); - } - @Override - public Adapter caseDocumentedElement(DocumentedElement object) { - return createDocumentedElementAdapter(); - } - @Override - public Adapter caseProcessing(Processing object) { - return createProcessingAdapter(); - } - @Override - public Adapter caseAction(Action object) { - return createActionAdapter(); - } - @Override - public Adapter caseReferenceableObject(ReferenceableObject object) { - return createReferenceableObjectAdapter(); - } - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject)target); - } - - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.EEFAction EEF Action}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFAction - * @generated - */ - public Adapter createEEFActionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.EditAction Edit Action}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EditAction - * @generated - */ - public Adapter createEditActionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Add Add}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Add - * @generated - */ - public Adapter createAddAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Remove Remove}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Remove - * @generated - */ - public Adapter createRemoveAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute Set Attribute}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute - * @generated - */ - public Adapter createSetAttributeAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute Unset Attribute}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute - * @generated - */ - public Adapter createUnsetAttributeAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Unset Unset}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Unset - * @generated - */ - public Adapter createUnsetAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Cancel Cancel}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Cancel - * @generated - */ - public Adapter createCancelAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.Check Check}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.Check - * @generated - */ - public Adapter createCheckAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor Open EEF Editor}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor - * @generated - */ - public Adapter createOpenEEFEditorAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.SetReference Set Reference}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.SetReference - * @generated - */ - public Adapter createSetReferenceAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference Unset Reference}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference - * @generated - */ - public Adapter createUnsetReferenceAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp Move Up}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp - * @generated - */ - public Adapter createMoveUpAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown Move Down}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown - * @generated - */ - public Adapter createMoveDownAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.DocumentedElement Documented Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.DocumentedElement - * @generated - */ - public Adapter createDocumentedElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.Processing Processing}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.Processing - * @generated - */ - public Adapter createProcessingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.Action Action}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.Action - * @generated - */ - public Adapter createActionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.ReferenceableObject Referenceable Object}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.ReferenceableObject - * @generated - */ - public Adapter createReferenceableObjectAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //EEFActionsAdapterFactory diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/util/EEFActionsSwitch.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/util/EEFActionsSwitch.java deleted file mode 100755 index a129f3077..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EEFActions/util/EEFActionsSwitch.java +++ /dev/null @@ -1,546 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EEFActions.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.DocumentedElement; - -import org.eclipse.emf.eef.modelingBot.EEFActions.*; -import org.eclipse.emf.eef.modelingBot.Processing; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage - * @generated - */ -public class EEFActionsSwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static EEFActionsPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public EEFActionsSwitch() { - if (modelPackage == null) { - modelPackage = EEFActionsPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } - else { - List eSuperTypes = theEClass.getESuperTypes(); - return - eSuperTypes.isEmpty() ? - defaultCase(theEObject) : - doSwitch(eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case EEFActionsPackage.EEF_ACTION: { - EEFAction eefAction = (EEFAction)theEObject; - T result = caseEEFAction(eefAction); - if (result == null) result = caseAction(eefAction); - if (result == null) result = caseDocumentedElement(eefAction); - if (result == null) result = caseProcessing(eefAction); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.EDIT_ACTION: { - EditAction editAction = (EditAction)theEObject; - T result = caseEditAction(editAction); - if (result == null) result = caseEEFAction(editAction); - if (result == null) result = caseReferenceableObject(editAction); - if (result == null) result = caseAction(editAction); - if (result == null) result = caseDocumentedElement(editAction); - if (result == null) result = caseProcessing(editAction); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.ADD: { - Add add = (Add)theEObject; - T result = caseAdd(add); - if (result == null) result = caseEditAction(add); - if (result == null) result = caseEEFAction(add); - if (result == null) result = caseReferenceableObject(add); - if (result == null) result = caseAction(add); - if (result == null) result = caseDocumentedElement(add); - if (result == null) result = caseProcessing(add); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.REMOVE: { - Remove remove = (Remove)theEObject; - T result = caseRemove(remove); - if (result == null) result = caseEditAction(remove); - if (result == null) result = caseEEFAction(remove); - if (result == null) result = caseReferenceableObject(remove); - if (result == null) result = caseAction(remove); - if (result == null) result = caseDocumentedElement(remove); - if (result == null) result = caseProcessing(remove); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.SET_ATTRIBUTE: { - SetAttribute setAttribute = (SetAttribute)theEObject; - T result = caseSetAttribute(setAttribute); - if (result == null) result = caseEditAction(setAttribute); - if (result == null) result = caseEEFAction(setAttribute); - if (result == null) result = caseReferenceableObject(setAttribute); - if (result == null) result = caseAction(setAttribute); - if (result == null) result = caseDocumentedElement(setAttribute); - if (result == null) result = caseProcessing(setAttribute); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.UNSET_ATTRIBUTE: { - UnsetAttribute unsetAttribute = (UnsetAttribute)theEObject; - T result = caseUnsetAttribute(unsetAttribute); - if (result == null) result = caseEditAction(unsetAttribute); - if (result == null) result = caseEEFAction(unsetAttribute); - if (result == null) result = caseReferenceableObject(unsetAttribute); - if (result == null) result = caseAction(unsetAttribute); - if (result == null) result = caseDocumentedElement(unsetAttribute); - if (result == null) result = caseProcessing(unsetAttribute); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.UNSET: { - Unset unset = (Unset)theEObject; - T result = caseUnset(unset); - if (result == null) result = caseEditAction(unset); - if (result == null) result = caseEEFAction(unset); - if (result == null) result = caseReferenceableObject(unset); - if (result == null) result = caseAction(unset); - if (result == null) result = caseDocumentedElement(unset); - if (result == null) result = caseProcessing(unset); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.CANCEL: { - Cancel cancel = (Cancel)theEObject; - T result = caseCancel(cancel); - if (result == null) result = caseEEFAction(cancel); - if (result == null) result = caseAction(cancel); - if (result == null) result = caseDocumentedElement(cancel); - if (result == null) result = caseProcessing(cancel); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.CHECK: { - Check check = (Check)theEObject; - T result = caseCheck(check); - if (result == null) result = caseEEFAction(check); - if (result == null) result = caseAction(check); - if (result == null) result = caseDocumentedElement(check); - if (result == null) result = caseProcessing(check); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.OPEN_EEF_EDITOR: { - OpenEEFEditor openEEFEditor = (OpenEEFEditor)theEObject; - T result = caseOpenEEFEditor(openEEFEditor); - if (result == null) result = caseEEFAction(openEEFEditor); - if (result == null) result = caseAction(openEEFEditor); - if (result == null) result = caseDocumentedElement(openEEFEditor); - if (result == null) result = caseProcessing(openEEFEditor); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.SET_REFERENCE: { - SetReference setReference = (SetReference)theEObject; - T result = caseSetReference(setReference); - if (result == null) result = caseEditAction(setReference); - if (result == null) result = caseEEFAction(setReference); - if (result == null) result = caseReferenceableObject(setReference); - if (result == null) result = caseAction(setReference); - if (result == null) result = caseDocumentedElement(setReference); - if (result == null) result = caseProcessing(setReference); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.UNSET_REFERENCE: { - UnsetReference unsetReference = (UnsetReference)theEObject; - T result = caseUnsetReference(unsetReference); - if (result == null) result = caseEditAction(unsetReference); - if (result == null) result = caseEEFAction(unsetReference); - if (result == null) result = caseReferenceableObject(unsetReference); - if (result == null) result = caseAction(unsetReference); - if (result == null) result = caseDocumentedElement(unsetReference); - if (result == null) result = caseProcessing(unsetReference); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.MOVE_UP: { - MoveUp moveUp = (MoveUp)theEObject; - T result = caseMoveUp(moveUp); - if (result == null) result = caseEditAction(moveUp); - if (result == null) result = caseEEFAction(moveUp); - if (result == null) result = caseReferenceableObject(moveUp); - if (result == null) result = caseAction(moveUp); - if (result == null) result = caseDocumentedElement(moveUp); - if (result == null) result = caseProcessing(moveUp); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EEFActionsPackage.MOVE_DOWN: { - MoveDown moveDown = (MoveDown)theEObject; - T result = caseMoveDown(moveDown); - if (result == null) result = caseEditAction(moveDown); - if (result == null) result = caseEEFAction(moveDown); - if (result == null) result = caseReferenceableObject(moveDown); - if (result == null) result = caseAction(moveDown); - if (result == null) result = caseDocumentedElement(moveDown); - if (result == null) result = caseProcessing(moveDown); - if (result == null) result = defaultCase(theEObject); - return result; - } - default: return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'EEF Action'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EEF Action'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEEFAction(EEFAction object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Edit Action'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Edit Action'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEditAction(EditAction object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Add'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Add'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAdd(Add object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Remove'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Remove'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseRemove(Remove object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Set Attribute'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Set Attribute'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseSetAttribute(SetAttribute object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Unset Attribute'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Unset Attribute'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseUnsetAttribute(UnsetAttribute object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Unset'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Unset'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseUnset(Unset object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Cancel'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Cancel'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCancel(Cancel object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Check'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Check'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCheck(Check object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Open EEF Editor'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Open EEF Editor'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseOpenEEFEditor(OpenEEFEditor object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Set Reference'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Set Reference'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseSetReference(SetReference object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Unset Reference'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Unset Reference'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseUnsetReference(UnsetReference object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Move Up'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Move Up'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseMoveUp(MoveUp object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Move Down'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Move Down'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseMoveDown(MoveDown object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Documented Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Documented Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDocumentedElement(DocumentedElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Processing'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Processing'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseProcessing(Processing object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Action'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Action'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAction(Action object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Referenceable Object'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Referenceable Object'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseReferenceableObject(ReferenceableObject object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //EEFActionsSwitch diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CloseEditor.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CloseEditor.java deleted file mode 100755 index b41e9e159..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CloseEditor.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - - -/** - * - * A representation of the model object 'Close Editor'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor#getPath Path}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getCloseEditor() - * @model - * @generated - */ -public interface CloseEditor extends EclipseAction { - - /** - * Returns the value of the 'Path' attribute. - * - *

- * If the meaning of the 'Path' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Path' attribute. - * @see #setPath(String) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getCloseEditor_Path() - * @model - * @generated - */ - String getPath(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor#getPath Path}' attribute. - * - * - * @param value the new value of the 'Path' attribute. - * @see #getPath() - * @generated - */ - void setPath(String value); -} // CloseEditor diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CloseProject.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CloseProject.java deleted file mode 100755 index 27a2f0f84..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CloseProject.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - - -/** - * - * A representation of the model object 'Close Project'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject#getProjectName Project Name}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getCloseProject() - * @model - * @generated - */ -public interface CloseProject extends EclipseAction { - /** - * Returns the value of the 'Project Name' attribute. - * - *

- * If the meaning of the 'Project Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Project Name' attribute. - * @see #setProjectName(String) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getCloseProject_ProjectName() - * @model - * @generated - */ - String getProjectName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject#getProjectName Project Name}' attribute. - * - * - * @param value the new value of the 'Project Name' attribute. - * @see #getProjectName() - * @generated - */ - void setProjectName(String value); - -} // CloseProject diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CreateModel.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CreateModel.java deleted file mode 100755 index 3e3df2a39..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CreateModel.java +++ /dev/null @@ -1,114 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; - - -/** - * - * A representation of the model object 'Create Model'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getModelName Model Name}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getPath Path}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getRoot Root}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getCreateModel() - * @model - * @generated - */ -public interface CreateModel extends EclipseAction, ReferenceableObject { - /** - * Returns the value of the 'Model Name' attribute. - * - *

- * If the meaning of the 'Model Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Model Name' attribute. - * @see #setModelName(String) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getCreateModel_ModelName() - * @model - * @generated - */ - String getModelName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getModelName Model Name}' attribute. - * - * - * @param value the new value of the 'Model Name' attribute. - * @see #getModelName() - * @generated - */ - void setModelName(String value); - - /** - * Returns the value of the 'Path' attribute. - * - *

- * If the meaning of the 'Path' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Path' attribute. - * @see #setPath(String) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getCreateModel_Path() - * @model - * @generated - */ - String getPath(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getPath Path}' attribute. - * - * - * @param value the new value of the 'Path' attribute. - * @see #getPath() - * @generated - */ - void setPath(String value); - - /** - * Returns the value of the 'Root' reference. - * - *

- * If the meaning of the 'Root' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Root' reference. - * @see #setRoot(EClass) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getCreateModel_Root() - * @model - * @generated - */ - EClass getRoot(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getRoot Root}' reference. - * - * - * @param value the new value of the 'Root' reference. - * @see #getRoot() - * @generated - */ - void setRoot(EClass value); - -} // CreateModel diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CreateProject.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CreateProject.java deleted file mode 100755 index 0203393a6..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/CreateProject.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - - -/** - * - * A representation of the model object 'Create Project'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject#getProjectName Project Name}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getCreateProject() - * @model - * @generated - */ -public interface CreateProject extends EclipseAction { - /** - * Returns the value of the 'Project Name' attribute. - * - *

- * If the meaning of the 'Project Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Project Name' attribute. - * @see #setProjectName(String) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getCreateProject_ProjectName() - * @model - * @generated - */ - String getProjectName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject#getProjectName Project Name}' attribute. - * - * - * @param value the new value of the 'Project Name' attribute. - * @see #getProjectName() - * @generated - */ - void setProjectName(String value); - -} // CreateProject diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseAction.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseAction.java deleted file mode 100755 index 6f92d38e7..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseAction.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - -import org.eclipse.emf.eef.modelingBot.Action; - -/** - * - * A representation of the model object 'Eclipse Action'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getEclipseAction() - * @model abstract="true" - * @generated - */ -public interface EclipseAction extends Action { -} // EclipseAction diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseActionsFactory.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseActionsFactory.java deleted file mode 100755 index de631a124..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseActionsFactory.java +++ /dev/null @@ -1,140 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage - * @generated - */ -public interface EclipseActionsFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - EclipseActionsFactory eINSTANCE = org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsFactoryImpl.init(); - - /** - * Returns a new object of class 'Create Project'. - * - * - * @return a new object of class 'Create Project'. - * @generated - */ - CreateProject createCreateProject(); - - /** - * Returns a new object of class 'Open Perspective'. - * - * - * @return a new object of class 'Open Perspective'. - * @generated - */ - OpenPerspective createOpenPerspective(); - - /** - * Returns a new object of class 'Close Project'. - * - * - * @return a new object of class 'Close Project'. - * @generated - */ - CloseProject createCloseProject(); - - /** - * Returns a new object of class 'Save'. - * - * - * @return a new object of class 'Save'. - * @generated - */ - Save createSave(); - - /** - * Returns a new object of class 'Undo'. - * - * - * @return a new object of class 'Undo'. - * @generated - */ - Undo createUndo(); - - /** - * Returns a new object of class 'Redo'. - * - * - * @return a new object of class 'Redo'. - * @generated - */ - Redo createRedo(); - - /** - * Returns a new object of class 'Open Project'. - * - * - * @return a new object of class 'Open Project'. - * @generated - */ - OpenProject createOpenProject(); - - /** - * Returns a new object of class 'Remove Project'. - * - * - * @return a new object of class 'Remove Project'. - * @generated - */ - RemoveProject createRemoveProject(); - - /** - * Returns a new object of class 'Close Editor'. - * - * - * @return a new object of class 'Close Editor'. - * @generated - */ - CloseEditor createCloseEditor(); - - /** - * Returns a new object of class 'Open Editor'. - * - * - * @return a new object of class 'Open Editor'. - * @generated - */ - OpenEditor createOpenEditor(); - - /** - * Returns a new object of class 'Create Model'. - * - * - * @return a new object of class 'Create Model'. - * @generated - */ - CreateModel createCreateModel(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - EclipseActionsPackage getEclipseActionsPackage(); - -} //EclipseActionsFactory diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseActionsPackage.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseActionsPackage.java deleted file mode 100755 index 58cf70086..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/EclipseActionsPackage.java +++ /dev/null @@ -1,1086 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsFactory - * @model kind="package" - * @generated - */ -public interface EclipseActionsPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "EclipseActions"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/test/EclipseActions/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-test"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - EclipseActionsPackage eINSTANCE = org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl.init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionImpl Eclipse Action}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getEclipseAction() - * @generated - */ - int ECLIPSE_ACTION = 0; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int ECLIPSE_ACTION__NAME = ModelingBotPackage.ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int ECLIPSE_ACTION__DOCUMENTATION = ModelingBotPackage.ACTION__DOCUMENTATION; - - /** - * The number of structural features of the 'Eclipse Action' class. - * - * - * @generated - * @ordered - */ - int ECLIPSE_ACTION_FEATURE_COUNT = ModelingBotPackage.ACTION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateProjectImpl Create Project}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateProjectImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getCreateProject() - * @generated - */ - int CREATE_PROJECT = 1; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int CREATE_PROJECT__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int CREATE_PROJECT__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Project Name' attribute. - * - * - * @generated - * @ordered - */ - int CREATE_PROJECT__PROJECT_NAME = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Create Project' class. - * - * - * @generated - * @ordered - */ - int CREATE_PROJECT_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenPerspectiveImpl Open Perspective}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenPerspectiveImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getOpenPerspective() - * @generated - */ - int OPEN_PERSPECTIVE = 2; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_PERSPECTIVE__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_PERSPECTIVE__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Type' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_PERSPECTIVE__TYPE = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Open Perspective' class. - * - * - * @generated - * @ordered - */ - int OPEN_PERSPECTIVE_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CloseProjectImpl Close Project}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CloseProjectImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getCloseProject() - * @generated - */ - int CLOSE_PROJECT = 3; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int CLOSE_PROJECT__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int CLOSE_PROJECT__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Project Name' attribute. - * - * - * @generated - * @ordered - */ - int CLOSE_PROJECT__PROJECT_NAME = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Close Project' class. - * - * - * @generated - * @ordered - */ - int CLOSE_PROJECT_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.SaveImpl Save}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.SaveImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getSave() - * @generated - */ - int SAVE = 4; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int SAVE__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int SAVE__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The number of structural features of the 'Save' class. - * - * - * @generated - * @ordered - */ - int SAVE_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.UndoImpl Undo}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.UndoImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getUndo() - * @generated - */ - int UNDO = 5; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int UNDO__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int UNDO__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The number of structural features of the 'Undo' class. - * - * - * @generated - * @ordered - */ - int UNDO_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.RedoImpl Redo}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.RedoImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getRedo() - * @generated - */ - int REDO = 6; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int REDO__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int REDO__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The number of structural features of the 'Redo' class. - * - * - * @generated - * @ordered - */ - int REDO_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenProjectImpl Open Project}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenProjectImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getOpenProject() - * @generated - */ - int OPEN_PROJECT = 7; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_PROJECT__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_PROJECT__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Project Name' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_PROJECT__PROJECT_NAME = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Open Project' class. - * - * - * @generated - * @ordered - */ - int OPEN_PROJECT_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.RemoveProjectImpl Remove Project}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.RemoveProjectImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getRemoveProject() - * @generated - */ - int REMOVE_PROJECT = 8; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int REMOVE_PROJECT__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int REMOVE_PROJECT__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Project Name' attribute. - * - * - * @generated - * @ordered - */ - int REMOVE_PROJECT__PROJECT_NAME = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Remove Project' class. - * - * - * @generated - * @ordered - */ - int REMOVE_PROJECT_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CloseEditorImpl Close Editor}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CloseEditorImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getCloseEditor() - * @generated - */ - int CLOSE_EDITOR = 9; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int CLOSE_EDITOR__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int CLOSE_EDITOR__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Path' attribute. - * - * - * @generated - * @ordered - */ - int CLOSE_EDITOR__PATH = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Close Editor' class. - * - * - * @generated - * @ordered - */ - int CLOSE_EDITOR_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 1; - - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenEditorImpl Open Editor}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenEditorImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getOpenEditor() - * @generated - */ - int OPEN_EDITOR = 10; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_EDITOR__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_EDITOR__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Editor Name' attribute. - * - * - * @generated - * @ordered - */ - int OPEN_EDITOR__EDITOR_NAME = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Root' reference. - * - * - * @generated - * @ordered - */ - int OPEN_EDITOR__ROOT = ECLIPSE_ACTION_FEATURE_COUNT + 1; - - /** - * The number of structural features of the 'Open Editor' class. - * - * - * @generated - * @ordered - */ - int OPEN_EDITOR_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateModelImpl Create Model}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateModelImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getCreateModel() - * @generated - */ - int CREATE_MODEL = 11; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int CREATE_MODEL__NAME = ECLIPSE_ACTION__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int CREATE_MODEL__DOCUMENTATION = ECLIPSE_ACTION__DOCUMENTATION; - - /** - * The feature id for the 'Model Name' attribute. - * - * - * @generated - * @ordered - */ - int CREATE_MODEL__MODEL_NAME = ECLIPSE_ACTION_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Path' attribute. - * - * - * @generated - * @ordered - */ - int CREATE_MODEL__PATH = ECLIPSE_ACTION_FEATURE_COUNT + 1; - - /** - * The feature id for the 'Root' reference. - * - * - * @generated - * @ordered - */ - int CREATE_MODEL__ROOT = ECLIPSE_ACTION_FEATURE_COUNT + 2; - - /** - * The number of structural features of the 'Create Model' class. - * - * - * @generated - * @ordered - */ - int CREATE_MODEL_FEATURE_COUNT = ECLIPSE_ACTION_FEATURE_COUNT + 3; - - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseAction Eclipse Action}'. - * - * - * @return the meta object for class 'Eclipse Action'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseAction - * @generated - */ - EClass getEclipseAction(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject Create Project}'. - * - * - * @return the meta object for class 'Create Project'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject - * @generated - */ - EClass getCreateProject(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject#getProjectName Project Name}'. - * - * - * @return the meta object for the attribute 'Project Name'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject#getProjectName() - * @see #getCreateProject() - * @generated - */ - EAttribute getCreateProject_ProjectName(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective Open Perspective}'. - * - * - * @return the meta object for class 'Open Perspective'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective - * @generated - */ - EClass getOpenPerspective(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective#getType Type}'. - * - * - * @return the meta object for the attribute 'Type'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective#getType() - * @see #getOpenPerspective() - * @generated - */ - EAttribute getOpenPerspective_Type(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject Close Project}'. - * - * - * @return the meta object for class 'Close Project'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject - * @generated - */ - EClass getCloseProject(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject#getProjectName Project Name}'. - * - * - * @return the meta object for the attribute 'Project Name'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject#getProjectName() - * @see #getCloseProject() - * @generated - */ - EAttribute getCloseProject_ProjectName(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.Save Save}'. - * - * - * @return the meta object for class 'Save'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.Save - * @generated - */ - EClass getSave(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.Undo Undo}'. - * - * - * @return the meta object for class 'Undo'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.Undo - * @generated - */ - EClass getUndo(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.Redo Redo}'. - * - * - * @return the meta object for class 'Redo'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.Redo - * @generated - */ - EClass getRedo(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject Open Project}'. - * - * - * @return the meta object for class 'Open Project'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject - * @generated - */ - EClass getOpenProject(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject#getProjectName Project Name}'. - * - * - * @return the meta object for the attribute 'Project Name'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject#getProjectName() - * @see #getOpenProject() - * @generated - */ - EAttribute getOpenProject_ProjectName(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject Remove Project}'. - * - * - * @return the meta object for class 'Remove Project'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject - * @generated - */ - EClass getRemoveProject(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject#getProjectName Project Name}'. - * - * - * @return the meta object for the attribute 'Project Name'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject#getProjectName() - * @see #getRemoveProject() - * @generated - */ - EAttribute getRemoveProject_ProjectName(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor Close Editor}'. - * - * - * @return the meta object for class 'Close Editor'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor - * @generated - */ - EClass getCloseEditor(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor#getPath Path}'. - * - * - * @return the meta object for the attribute 'Path'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor#getPath() - * @see #getCloseEditor() - * @generated - */ - EAttribute getCloseEditor_Path(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor Open Editor}'. - * - * - * @return the meta object for class 'Open Editor'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor - * @generated - */ - EClass getOpenEditor(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor#getEditorName Editor Name}'. - * - * - * @return the meta object for the attribute 'Editor Name'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor#getEditorName() - * @see #getOpenEditor() - * @generated - */ - EAttribute getOpenEditor_EditorName(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor#getRoot Root}'. - * - * - * @return the meta object for the reference 'Root'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor#getRoot() - * @see #getOpenEditor() - * @generated - */ - EReference getOpenEditor_Root(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel Create Model}'. - * - * - * @return the meta object for class 'Create Model'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel - * @generated - */ - EClass getCreateModel(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getModelName Model Name}'. - * - * - * @return the meta object for the attribute 'Model Name'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getModelName() - * @see #getCreateModel() - * @generated - */ - EAttribute getCreateModel_ModelName(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getPath Path}'. - * - * - * @return the meta object for the attribute 'Path'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getPath() - * @see #getCreateModel() - * @generated - */ - EAttribute getCreateModel_Path(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getRoot Root}'. - * - * - * @return the meta object for the reference 'Root'. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel#getRoot() - * @see #getCreateModel() - * @generated - */ - EReference getCreateModel_Root(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - EclipseActionsFactory getEclipseActionsFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionImpl Eclipse Action}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getEclipseAction() - * @generated - */ - EClass ECLIPSE_ACTION = eINSTANCE.getEclipseAction(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateProjectImpl Create Project}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateProjectImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getCreateProject() - * @generated - */ - EClass CREATE_PROJECT = eINSTANCE.getCreateProject(); - - /** - * The meta object literal for the 'Project Name' attribute feature. - * - * - * @generated - */ - EAttribute CREATE_PROJECT__PROJECT_NAME = eINSTANCE.getCreateProject_ProjectName(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenPerspectiveImpl Open Perspective}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenPerspectiveImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getOpenPerspective() - * @generated - */ - EClass OPEN_PERSPECTIVE = eINSTANCE.getOpenPerspective(); - - /** - * The meta object literal for the 'Type' attribute feature. - * - * - * @generated - */ - EAttribute OPEN_PERSPECTIVE__TYPE = eINSTANCE.getOpenPerspective_Type(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CloseProjectImpl Close Project}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CloseProjectImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getCloseProject() - * @generated - */ - EClass CLOSE_PROJECT = eINSTANCE.getCloseProject(); - - /** - * The meta object literal for the 'Project Name' attribute feature. - * - * - * @generated - */ - EAttribute CLOSE_PROJECT__PROJECT_NAME = eINSTANCE.getCloseProject_ProjectName(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.SaveImpl Save}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.SaveImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getSave() - * @generated - */ - EClass SAVE = eINSTANCE.getSave(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.UndoImpl Undo}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.UndoImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getUndo() - * @generated - */ - EClass UNDO = eINSTANCE.getUndo(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.RedoImpl Redo}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.RedoImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getRedo() - * @generated - */ - EClass REDO = eINSTANCE.getRedo(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenProjectImpl Open Project}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenProjectImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getOpenProject() - * @generated - */ - EClass OPEN_PROJECT = eINSTANCE.getOpenProject(); - - /** - * The meta object literal for the 'Project Name' attribute feature. - * - * - * @generated - */ - EAttribute OPEN_PROJECT__PROJECT_NAME = eINSTANCE.getOpenProject_ProjectName(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.RemoveProjectImpl Remove Project}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.RemoveProjectImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getRemoveProject() - * @generated - */ - EClass REMOVE_PROJECT = eINSTANCE.getRemoveProject(); - - /** - * The meta object literal for the 'Project Name' attribute feature. - * - * - * @generated - */ - EAttribute REMOVE_PROJECT__PROJECT_NAME = eINSTANCE.getRemoveProject_ProjectName(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CloseEditorImpl Close Editor}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CloseEditorImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getCloseEditor() - * @generated - */ - EClass CLOSE_EDITOR = eINSTANCE.getCloseEditor(); - - /** - * The meta object literal for the 'Path' attribute feature. - * - * - * @generated - */ - EAttribute CLOSE_EDITOR__PATH = eINSTANCE.getCloseEditor_Path(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenEditorImpl Open Editor}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenEditorImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getOpenEditor() - * @generated - */ - EClass OPEN_EDITOR = eINSTANCE.getOpenEditor(); - - /** - * The meta object literal for the 'Editor Name' attribute feature. - * - * - * @generated - */ - EAttribute OPEN_EDITOR__EDITOR_NAME = eINSTANCE.getOpenEditor_EditorName(); - - /** - * The meta object literal for the 'Root' reference feature. - * - * - * @generated - */ - EReference OPEN_EDITOR__ROOT = eINSTANCE.getOpenEditor_Root(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateModelImpl Create Model}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateModelImpl - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl#getCreateModel() - * @generated - */ - EClass CREATE_MODEL = eINSTANCE.getCreateModel(); - - /** - * The meta object literal for the 'Model Name' attribute feature. - * - * - * @generated - */ - EAttribute CREATE_MODEL__MODEL_NAME = eINSTANCE.getCreateModel_ModelName(); - - /** - * The meta object literal for the 'Path' attribute feature. - * - * - * @generated - */ - EAttribute CREATE_MODEL__PATH = eINSTANCE.getCreateModel_Path(); - - /** - * The meta object literal for the 'Root' reference feature. - * - * - * @generated - */ - EReference CREATE_MODEL__ROOT = eINSTANCE.getCreateModel_Root(); - - } - -} //EclipseActionsPackage diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenEditor.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenEditor.java deleted file mode 100644 index e2d932f71..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenEditor.java +++ /dev/null @@ -1,82 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - -import org.eclipse.emf.ecore.EClass; - - -/** - * - * A representation of the model object 'Open Editor'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor#getEditorName Editor Name}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor#getRoot Root}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getOpenEditor() - * @model - * @generated - */ -public interface OpenEditor extends EclipseAction { - /** - * Returns the value of the 'Editor Name' attribute. - * - *

- * If the meaning of the 'Editor Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Editor Name' attribute. - * @see #setEditorName(String) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getOpenEditor_EditorName() - * @model - * @generated - */ - String getEditorName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor#getEditorName Editor Name}' attribute. - * - * - * @param value the new value of the 'Editor Name' attribute. - * @see #getEditorName() - * @generated - */ - void setEditorName(String value); - - /** - * Returns the value of the 'Root' reference. - * - *

- * If the meaning of the 'Root' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Root' reference. - * @see #setRoot(EClass) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getOpenEditor_Root() - * @model - * @generated - */ - EClass getRoot(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor#getRoot Root}' reference. - * - * - * @param value the new value of the 'Root' reference. - * @see #getRoot() - * @generated - */ - void setRoot(EClass value); - -} // OpenEditor diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenPerspective.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenPerspective.java deleted file mode 100755 index e2bc972b4..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenPerspective.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - - -/** - * - * A representation of the model object 'Open Perspective'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective#getType Type}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getOpenPerspective() - * @model - * @generated - */ -public interface OpenPerspective extends EclipseAction { - /** - * Returns the value of the 'Type' attribute. - * - *

- * If the meaning of the 'Type' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Type' attribute. - * @see #setType(String) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getOpenPerspective_Type() - * @model - * @generated - */ - String getType(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective#getType Type}' attribute. - * - * - * @param value the new value of the 'Type' attribute. - * @see #getType() - * @generated - */ - void setType(String value); - -} // OpenPerspective diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenProject.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenProject.java deleted file mode 100755 index f3daafb14..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/OpenProject.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - - -/** - * - * A representation of the model object 'Open Project'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject#getProjectName Project Name}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getOpenProject() - * @model - * @generated - */ -public interface OpenProject extends EclipseAction { - /** - * Returns the value of the 'Project Name' attribute. - * - *

- * If the meaning of the 'Project Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Project Name' attribute. - * @see #setProjectName(String) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getOpenProject_ProjectName() - * @model - * @generated - */ - String getProjectName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject#getProjectName Project Name}' attribute. - * - * - * @param value the new value of the 'Project Name' attribute. - * @see #getProjectName() - * @generated - */ - void setProjectName(String value); - -} // OpenProject diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Redo.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Redo.java deleted file mode 100755 index 037f48948..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Redo.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - - -/** - * - * A representation of the model object 'Redo'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getRedo() - * @model - * @generated - */ -public interface Redo extends EclipseAction { -} // Redo diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/RemoveProject.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/RemoveProject.java deleted file mode 100755 index 9312ce9e2..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/RemoveProject.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - - -/** - * - * A representation of the model object 'Remove Project'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject#getProjectName Project Name}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getRemoveProject() - * @model - * @generated - */ -public interface RemoveProject extends EclipseAction { - /** - * Returns the value of the 'Project Name' attribute. - * - *

- * If the meaning of the 'Project Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Project Name' attribute. - * @see #setProjectName(String) - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getRemoveProject_ProjectName() - * @model - * @generated - */ - String getProjectName(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject#getProjectName Project Name}' attribute. - * - * - * @param value the new value of the 'Project Name' attribute. - * @see #getProjectName() - * @generated - */ - void setProjectName(String value); - -} // RemoveProject diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Save.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Save.java deleted file mode 100755 index 4930edae6..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Save.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - - -/** - * - * A representation of the model object 'Save'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getSave() - * @model - * @generated - */ -public interface Save extends EclipseAction { -} // Save diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Undo.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Undo.java deleted file mode 100755 index 96eb16642..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/Undo.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions; - - -/** - * - * A representation of the model object 'Undo'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#getUndo() - * @model - * @generated - */ -public interface Undo extends EclipseAction { -} // Undo diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CloseEditorImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CloseEditorImpl.java deleted file mode 100755 index d4ed62314..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CloseEditorImpl.java +++ /dev/null @@ -1,167 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; - -/** - * - * An implementation of the model object 'Close Editor'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CloseEditorImpl#getPath Path}
  • - *
- *

- * - * @generated - */ -public class CloseEditorImpl extends EclipseActionImpl implements CloseEditor { - /** - * The default value of the '{@link #getPath() Path}' attribute. - * - * - * @see #getPath() - * @generated - * @ordered - */ - protected static final String PATH_EDEFAULT = null; - /** - * The cached value of the '{@link #getPath() Path}' attribute. - * - * - * @see #getPath() - * @generated - * @ordered - */ - protected String path = PATH_EDEFAULT; - - /** - * - * - * @generated - */ - protected CloseEditorImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.CLOSE_EDITOR; - } - - /** - * - * - * @generated - */ - public String getPath() { - return path; - } - - /** - * - * - * @generated - */ - public void setPath(String newPath) { - String oldPath = path; - path = newPath; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.CLOSE_EDITOR__PATH, oldPath, path)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EclipseActionsPackage.CLOSE_EDITOR__PATH: - return getPath(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EclipseActionsPackage.CLOSE_EDITOR__PATH: - setPath((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EclipseActionsPackage.CLOSE_EDITOR__PATH: - setPath(PATH_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EclipseActionsPackage.CLOSE_EDITOR__PATH: - return PATH_EDEFAULT == null ? path != null : !PATH_EDEFAULT.equals(path); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (path: "); - result.append(path); - result.append(')'); - return result.toString(); - } - -} //CloseEditorImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CloseProjectImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CloseProjectImpl.java deleted file mode 100755 index 001d480f7..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CloseProjectImpl.java +++ /dev/null @@ -1,170 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; - -/** - * - * An implementation of the model object 'Close Project'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CloseProjectImpl#getProjectName Project Name}
  • - *
- *

- * - * @generated - */ -public class CloseProjectImpl extends EclipseActionImpl implements CloseProject { - /** - * The default value of the '{@link #getProjectName() Project Name}' attribute. - * - * - * @see #getProjectName() - * @generated - * @ordered - */ - protected static final String PROJECT_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getProjectName() Project Name}' attribute. - * - * - * @see #getProjectName() - * @generated - * @ordered - */ - protected String projectName = PROJECT_NAME_EDEFAULT; - - /** - * - * - * @generated - */ - protected CloseProjectImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.CLOSE_PROJECT; - } - - /** - * - * - * @generated - */ - public String getProjectName() { - return projectName; - } - - /** - * - * - * @generated - */ - public void setProjectName(String newProjectName) { - String oldProjectName = projectName; - projectName = newProjectName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.CLOSE_PROJECT__PROJECT_NAME, oldProjectName, projectName)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EclipseActionsPackage.CLOSE_PROJECT__PROJECT_NAME: - return getProjectName(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EclipseActionsPackage.CLOSE_PROJECT__PROJECT_NAME: - setProjectName((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EclipseActionsPackage.CLOSE_PROJECT__PROJECT_NAME: - setProjectName(PROJECT_NAME_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EclipseActionsPackage.CLOSE_PROJECT__PROJECT_NAME: - return PROJECT_NAME_EDEFAULT == null ? projectName != null : !PROJECT_NAME_EDEFAULT.equals(projectName); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (projectName: "); - result.append(projectName); - result.append(')'); - return result.toString(); - } - -} //CloseProjectImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CreateModelImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CreateModelImpl.java deleted file mode 100755 index 05ee392f6..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CreateModelImpl.java +++ /dev/null @@ -1,285 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; - -/** - * - * An implementation of the model object 'Create Model'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateModelImpl#getModelName Model Name}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateModelImpl#getPath Path}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateModelImpl#getRoot Root}
  • - *
- *

- * - * @generated - */ -public class CreateModelImpl extends EclipseActionImpl implements CreateModel { - /** - * The default value of the '{@link #getModelName() Model Name}' attribute. - * - * - * @see #getModelName() - * @generated - * @ordered - */ - protected static final String MODEL_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getModelName() Model Name}' attribute. - * - * - * @see #getModelName() - * @generated - * @ordered - */ - protected String modelName = MODEL_NAME_EDEFAULT; - - /** - * The default value of the '{@link #getPath() Path}' attribute. - * - * - * @see #getPath() - * @generated - * @ordered - */ - protected static final String PATH_EDEFAULT = null; - - /** - * The cached value of the '{@link #getPath() Path}' attribute. - * - * - * @see #getPath() - * @generated - * @ordered - */ - protected String path = PATH_EDEFAULT; - - /** - * The cached value of the '{@link #getRoot() Root}' reference. - * - * - * @see #getRoot() - * @generated - * @ordered - */ - protected EClass root; - - /** - * - * - * @generated - */ - protected CreateModelImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.CREATE_MODEL; - } - - /** - * - * - * @generated - */ - public String getModelName() { - return modelName; - } - - /** - * - * - * @generated - */ - public void setModelName(String newModelName) { - String oldModelName = modelName; - modelName = newModelName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.CREATE_MODEL__MODEL_NAME, oldModelName, modelName)); - } - - /** - * - * - * @generated - */ - public String getPath() { - return path; - } - - /** - * - * - * @generated - */ - public void setPath(String newPath) { - String oldPath = path; - path = newPath; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.CREATE_MODEL__PATH, oldPath, path)); - } - - /** - * - * - * @generated - */ - public EClass getRoot() { - if (root != null && root.eIsProxy()) { - InternalEObject oldRoot = (InternalEObject)root; - root = (EClass)eResolveProxy(oldRoot); - if (root != oldRoot) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EclipseActionsPackage.CREATE_MODEL__ROOT, oldRoot, root)); - } - } - return root; - } - - /** - * - * - * @generated - */ - public EClass basicGetRoot() { - return root; - } - - /** - * - * - * @generated - */ - public void setRoot(EClass newRoot) { - EClass oldRoot = root; - root = newRoot; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.CREATE_MODEL__ROOT, oldRoot, root)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EclipseActionsPackage.CREATE_MODEL__MODEL_NAME: - return getModelName(); - case EclipseActionsPackage.CREATE_MODEL__PATH: - return getPath(); - case EclipseActionsPackage.CREATE_MODEL__ROOT: - if (resolve) return getRoot(); - return basicGetRoot(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EclipseActionsPackage.CREATE_MODEL__MODEL_NAME: - setModelName((String)newValue); - return; - case EclipseActionsPackage.CREATE_MODEL__PATH: - setPath((String)newValue); - return; - case EclipseActionsPackage.CREATE_MODEL__ROOT: - setRoot((EClass)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EclipseActionsPackage.CREATE_MODEL__MODEL_NAME: - setModelName(MODEL_NAME_EDEFAULT); - return; - case EclipseActionsPackage.CREATE_MODEL__PATH: - setPath(PATH_EDEFAULT); - return; - case EclipseActionsPackage.CREATE_MODEL__ROOT: - setRoot((EClass)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EclipseActionsPackage.CREATE_MODEL__MODEL_NAME: - return MODEL_NAME_EDEFAULT == null ? modelName != null : !MODEL_NAME_EDEFAULT.equals(modelName); - case EclipseActionsPackage.CREATE_MODEL__PATH: - return PATH_EDEFAULT == null ? path != null : !PATH_EDEFAULT.equals(path); - case EclipseActionsPackage.CREATE_MODEL__ROOT: - return root != null; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (modelName: "); - result.append(modelName); - result.append(", path: "); - result.append(path); - result.append(')'); - return result.toString(); - } - -} //CreateModelImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CreateProjectImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CreateProjectImpl.java deleted file mode 100755 index e18a57974..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/CreateProjectImpl.java +++ /dev/null @@ -1,170 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; - -/** - * - * An implementation of the model object 'Create Project'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.CreateProjectImpl#getProjectName Project Name}
  • - *
- *

- * - * @generated - */ -public class CreateProjectImpl extends EclipseActionImpl implements CreateProject { - /** - * The default value of the '{@link #getProjectName() Project Name}' attribute. - * - * - * @see #getProjectName() - * @generated - * @ordered - */ - protected static final String PROJECT_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getProjectName() Project Name}' attribute. - * - * - * @see #getProjectName() - * @generated - * @ordered - */ - protected String projectName = PROJECT_NAME_EDEFAULT; - - /** - * - * - * @generated - */ - protected CreateProjectImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.CREATE_PROJECT; - } - - /** - * - * - * @generated - */ - public String getProjectName() { - return projectName; - } - - /** - * - * - * @generated - */ - public void setProjectName(String newProjectName) { - String oldProjectName = projectName; - projectName = newProjectName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.CREATE_PROJECT__PROJECT_NAME, oldProjectName, projectName)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EclipseActionsPackage.CREATE_PROJECT__PROJECT_NAME: - return getProjectName(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EclipseActionsPackage.CREATE_PROJECT__PROJECT_NAME: - setProjectName((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EclipseActionsPackage.CREATE_PROJECT__PROJECT_NAME: - setProjectName(PROJECT_NAME_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EclipseActionsPackage.CREATE_PROJECT__PROJECT_NAME: - return PROJECT_NAME_EDEFAULT == null ? projectName != null : !PROJECT_NAME_EDEFAULT.equals(projectName); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (projectName: "); - result.append(projectName); - result.append(')'); - return result.toString(); - } - -} //CreateProjectImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionImpl.java deleted file mode 100755 index 2b643d309..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionImpl.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseAction; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; - -import org.eclipse.emf.eef.modelingBot.impl.ActionImpl; - -/** - * - * An implementation of the model object 'Eclipse Action'. - * - *

- *

- * - * @generated - */ -public abstract class EclipseActionImpl extends ActionImpl implements EclipseAction { - /** - * - * - * @generated - */ - protected EclipseActionImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.ECLIPSE_ACTION; - } - -} //EclipseActionImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionsFactoryImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionsFactoryImpl.java deleted file mode 100755 index cefd29f75..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionsFactoryImpl.java +++ /dev/null @@ -1,213 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.impl.EFactoryImpl; - -import org.eclipse.emf.ecore.plugin.EcorePlugin; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.*; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class EclipseActionsFactoryImpl extends EFactoryImpl implements EclipseActionsFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static EclipseActionsFactory init() { - try { - EclipseActionsFactory theEclipseActionsFactory = (EclipseActionsFactory)EPackage.Registry.INSTANCE.getEFactory("http://www.eclipse.org/emf/eef/test/EclipseActions/1.0.0"); - if (theEclipseActionsFactory != null) { - return theEclipseActionsFactory; - } - } - catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new EclipseActionsFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public EclipseActionsFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case EclipseActionsPackage.CREATE_PROJECT: return createCreateProject(); - case EclipseActionsPackage.OPEN_PERSPECTIVE: return createOpenPerspective(); - case EclipseActionsPackage.CLOSE_PROJECT: return createCloseProject(); - case EclipseActionsPackage.SAVE: return createSave(); - case EclipseActionsPackage.UNDO: return createUndo(); - case EclipseActionsPackage.REDO: return createRedo(); - case EclipseActionsPackage.OPEN_PROJECT: return createOpenProject(); - case EclipseActionsPackage.REMOVE_PROJECT: return createRemoveProject(); - case EclipseActionsPackage.CLOSE_EDITOR: return createCloseEditor(); - case EclipseActionsPackage.OPEN_EDITOR: return createOpenEditor(); - case EclipseActionsPackage.CREATE_MODEL: return createCreateModel(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public CreateProject createCreateProject() { - CreateProjectImpl createProject = new CreateProjectImpl(); - return createProject; - } - - /** - * - * - * @generated - */ - public OpenPerspective createOpenPerspective() { - OpenPerspectiveImpl openPerspective = new OpenPerspectiveImpl(); - return openPerspective; - } - - /** - * - * - * @generated - */ - public CloseProject createCloseProject() { - CloseProjectImpl closeProject = new CloseProjectImpl(); - return closeProject; - } - - /** - * - * - * @generated - */ - public Save createSave() { - SaveImpl save = new SaveImpl(); - return save; - } - - /** - * - * - * @generated - */ - public Undo createUndo() { - UndoImpl undo = new UndoImpl(); - return undo; - } - - /** - * - * - * @generated - */ - public Redo createRedo() { - RedoImpl redo = new RedoImpl(); - return redo; - } - - /** - * - * - * @generated - */ - public OpenProject createOpenProject() { - OpenProjectImpl openProject = new OpenProjectImpl(); - return openProject; - } - - /** - * - * - * @generated - */ - public RemoveProject createRemoveProject() { - RemoveProjectImpl removeProject = new RemoveProjectImpl(); - return removeProject; - } - - /** - * - * - * @generated - */ - public CloseEditor createCloseEditor() { - CloseEditorImpl closeEditor = new CloseEditorImpl(); - return closeEditor; - } - - /** - * - * - * @generated - */ - public OpenEditor createOpenEditor() { - OpenEditorImpl openEditor = new OpenEditorImpl(); - return openEditor; - } - - /** - * - * - * @generated - */ - public CreateModel createCreateModel() { - CreateModelImpl createModel = new CreateModelImpl(); - return createModel; - } - - /** - * - * - * @generated - */ - public EclipseActionsPackage getEclipseActionsPackage() { - return (EclipseActionsPackage)getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static EclipseActionsPackage getPackage() { - return EclipseActionsPackage.eINSTANCE; - } - -} //EclipseActionsFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionsPackageImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionsPackageImpl.java deleted file mode 100755 index 2f334bbdc..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/EclipseActionsPackageImpl.java +++ /dev/null @@ -1,567 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.impl.EPackageImpl; - -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -import org.eclipse.emf.eef.extended.query.QueryPackage; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; - -import org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor; -import org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel; -import org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseAction; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsFactory; -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor; -import org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective; -import org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.Redo; -import org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.Save; -import org.eclipse.emf.eef.modelingBot.EclipseActions.Undo; - -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; - -import org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class EclipseActionsPackageImpl extends EPackageImpl implements EclipseActionsPackage { - /** - * - * - * @generated - */ - private EClass eclipseActionEClass = null; - - /** - * - * - * @generated - */ - private EClass createProjectEClass = null; - - /** - * - * - * @generated - */ - private EClass openPerspectiveEClass = null; - - /** - * - * - * @generated - */ - private EClass closeProjectEClass = null; - - /** - * - * - * @generated - */ - private EClass saveEClass = null; - - /** - * - * - * @generated - */ - private EClass undoEClass = null; - - /** - * - * - * @generated - */ - private EClass redoEClass = null; - - /** - * - * - * @generated - */ - private EClass openProjectEClass = null; - - /** - * - * - * @generated - */ - private EClass removeProjectEClass = null; - - /** - * - * - * @generated - */ - private EClass closeEditorEClass = null; - - /** - * - * - * @generated - */ - private EClass openEditorEClass = null; - - /** - * - * - * @generated - */ - private EClass createModelEClass = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage#eNS_URI - * @see #init() - * @generated - */ - private EclipseActionsPackageImpl() { - super(eNS_URI, EclipseActionsFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link EclipseActionsPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static EclipseActionsPackage init() { - if (isInited) return (EclipseActionsPackage)EPackage.Registry.INSTANCE.getEPackage(EclipseActionsPackage.eNS_URI); - - // Obtain or create and register package - EclipseActionsPackageImpl theEclipseActionsPackage = (EclipseActionsPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof EclipseActionsPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new EclipseActionsPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - EditorPackage.eINSTANCE.eClass(); - QueryPackage.eINSTANCE.eClass(); - - // Obtain or create and register interdependencies - ModelingBotPackageImpl theModelingBotPackage = (ModelingBotPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(ModelingBotPackage.eNS_URI) instanceof ModelingBotPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(ModelingBotPackage.eNS_URI) : ModelingBotPackage.eINSTANCE); - EEFActionsPackageImpl theEEFActionsPackage = (EEFActionsPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(EEFActionsPackage.eNS_URI) instanceof EEFActionsPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(EEFActionsPackage.eNS_URI) : EEFActionsPackage.eINSTANCE); - - // Create package meta-data objects - theEclipseActionsPackage.createPackageContents(); - theModelingBotPackage.createPackageContents(); - theEEFActionsPackage.createPackageContents(); - - // Initialize created meta-data - theEclipseActionsPackage.initializePackageContents(); - theModelingBotPackage.initializePackageContents(); - theEEFActionsPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theEclipseActionsPackage.freeze(); - - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(EclipseActionsPackage.eNS_URI, theEclipseActionsPackage); - return theEclipseActionsPackage; - } - - /** - * - * - * @generated - */ - public EClass getEclipseAction() { - return eclipseActionEClass; - } - - /** - * - * - * @generated - */ - public EClass getCreateProject() { - return createProjectEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getCreateProject_ProjectName() { - return (EAttribute)createProjectEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getOpenPerspective() { - return openPerspectiveEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getOpenPerspective_Type() { - return (EAttribute)openPerspectiveEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getCloseProject() { - return closeProjectEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getCloseProject_ProjectName() { - return (EAttribute)closeProjectEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getSave() { - return saveEClass; - } - - /** - * - * - * @generated - */ - public EClass getUndo() { - return undoEClass; - } - - /** - * - * - * @generated - */ - public EClass getRedo() { - return redoEClass; - } - - /** - * - * - * @generated - */ - public EClass getOpenProject() { - return openProjectEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getOpenProject_ProjectName() { - return (EAttribute)openProjectEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getRemoveProject() { - return removeProjectEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getRemoveProject_ProjectName() { - return (EAttribute)removeProjectEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getCloseEditor() { - return closeEditorEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getCloseEditor_Path() { - return (EAttribute)closeEditorEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getOpenEditor() { - return openEditorEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getOpenEditor_EditorName() { - return (EAttribute)openEditorEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getOpenEditor_Root() { - return (EReference)openEditorEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getCreateModel() { - return createModelEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getCreateModel_ModelName() { - return (EAttribute)createModelEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EAttribute getCreateModel_Path() { - return (EAttribute)createModelEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EReference getCreateModel_Root() { - return (EReference)createModelEClass.getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EclipseActionsFactory getEclipseActionsFactory() { - return (EclipseActionsFactory)getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) return; - isCreated = true; - - // Create classes and their features - eclipseActionEClass = createEClass(ECLIPSE_ACTION); - - createProjectEClass = createEClass(CREATE_PROJECT); - createEAttribute(createProjectEClass, CREATE_PROJECT__PROJECT_NAME); - - openPerspectiveEClass = createEClass(OPEN_PERSPECTIVE); - createEAttribute(openPerspectiveEClass, OPEN_PERSPECTIVE__TYPE); - - closeProjectEClass = createEClass(CLOSE_PROJECT); - createEAttribute(closeProjectEClass, CLOSE_PROJECT__PROJECT_NAME); - - saveEClass = createEClass(SAVE); - - undoEClass = createEClass(UNDO); - - redoEClass = createEClass(REDO); - - openProjectEClass = createEClass(OPEN_PROJECT); - createEAttribute(openProjectEClass, OPEN_PROJECT__PROJECT_NAME); - - removeProjectEClass = createEClass(REMOVE_PROJECT); - createEAttribute(removeProjectEClass, REMOVE_PROJECT__PROJECT_NAME); - - closeEditorEClass = createEClass(CLOSE_EDITOR); - createEAttribute(closeEditorEClass, CLOSE_EDITOR__PATH); - - openEditorEClass = createEClass(OPEN_EDITOR); - createEAttribute(openEditorEClass, OPEN_EDITOR__EDITOR_NAME); - createEReference(openEditorEClass, OPEN_EDITOR__ROOT); - - createModelEClass = createEClass(CREATE_MODEL); - createEAttribute(createModelEClass, CREATE_MODEL__MODEL_NAME); - createEAttribute(createModelEClass, CREATE_MODEL__PATH); - createEReference(createModelEClass, CREATE_MODEL__ROOT); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - ModelingBotPackage theModelingBotPackage = (ModelingBotPackage)EPackage.Registry.INSTANCE.getEPackage(ModelingBotPackage.eNS_URI); - EcorePackage theEcorePackage = (EcorePackage)EPackage.Registry.INSTANCE.getEPackage(EcorePackage.eNS_URI); - EditorPackage theEditorPackage = (EditorPackage)EPackage.Registry.INSTANCE.getEPackage(EditorPackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - eclipseActionEClass.getESuperTypes().add(theModelingBotPackage.getAction()); - createProjectEClass.getESuperTypes().add(this.getEclipseAction()); - openPerspectiveEClass.getESuperTypes().add(this.getEclipseAction()); - closeProjectEClass.getESuperTypes().add(this.getEclipseAction()); - saveEClass.getESuperTypes().add(this.getEclipseAction()); - undoEClass.getESuperTypes().add(this.getEclipseAction()); - redoEClass.getESuperTypes().add(this.getEclipseAction()); - openProjectEClass.getESuperTypes().add(this.getEclipseAction()); - removeProjectEClass.getESuperTypes().add(this.getEclipseAction()); - closeEditorEClass.getESuperTypes().add(this.getEclipseAction()); - openEditorEClass.getESuperTypes().add(this.getEclipseAction()); - createModelEClass.getESuperTypes().add(this.getEclipseAction()); - createModelEClass.getESuperTypes().add(theEditorPackage.getReferenceableObject()); - - // Initialize classes and features; add operations and parameters - initEClass(eclipseActionEClass, EclipseAction.class, "EclipseAction", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(createProjectEClass, CreateProject.class, "CreateProject", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getCreateProject_ProjectName(), ecorePackage.getEString(), "projectName", null, 0, 1, CreateProject.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(openPerspectiveEClass, OpenPerspective.class, "OpenPerspective", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getOpenPerspective_Type(), ecorePackage.getEString(), "type", null, 0, 1, OpenPerspective.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(closeProjectEClass, CloseProject.class, "CloseProject", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getCloseProject_ProjectName(), ecorePackage.getEString(), "projectName", null, 0, 1, CloseProject.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(saveEClass, Save.class, "Save", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(undoEClass, Undo.class, "Undo", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(redoEClass, Redo.class, "Redo", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(openProjectEClass, OpenProject.class, "OpenProject", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getOpenProject_ProjectName(), ecorePackage.getEString(), "projectName", null, 0, 1, OpenProject.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(removeProjectEClass, RemoveProject.class, "RemoveProject", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getRemoveProject_ProjectName(), ecorePackage.getEString(), "projectName", null, 0, 1, RemoveProject.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(closeEditorEClass, CloseEditor.class, "CloseEditor", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getCloseEditor_Path(), ecorePackage.getEString(), "path", null, 0, 1, CloseEditor.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(openEditorEClass, OpenEditor.class, "OpenEditor", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getOpenEditor_EditorName(), theEcorePackage.getEString(), "editorName", null, 0, 1, OpenEditor.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getOpenEditor_Root(), theEcorePackage.getEClass(), null, "root", null, 0, 1, OpenEditor.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(createModelEClass, CreateModel.class, "CreateModel", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getCreateModel_ModelName(), ecorePackage.getEString(), "modelName", null, 0, 1, CreateModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getCreateModel_Path(), ecorePackage.getEString(), "path", null, 0, 1, CreateModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getCreateModel_Root(), theEcorePackage.getEClass(), null, "root", null, 0, 1, CreateModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - } - -} //EclipseActionsPackageImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenEditorImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenEditorImpl.java deleted file mode 100644 index 575da2126..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenEditorImpl.java +++ /dev/null @@ -1,227 +0,0 @@ -/** - * - * - * - * $Id$ - */ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor; - -/** - * - * An implementation of the model object 'Open Editor'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenEditorImpl#getEditorName Editor Name}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenEditorImpl#getRoot Root}
  • - *
- *

- * - * @generated - */ -public class OpenEditorImpl extends EclipseActionImpl implements OpenEditor { - /** - * The default value of the '{@link #getEditorName() Editor Name}' attribute. - * - * - * @see #getEditorName() - * @generated - * @ordered - */ - protected static final String EDITOR_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getEditorName() Editor Name}' attribute. - * - * - * @see #getEditorName() - * @generated - * @ordered - */ - protected String editorName = EDITOR_NAME_EDEFAULT; - - /** - * The cached value of the '{@link #getRoot() Root}' reference. - * - * - * @see #getRoot() - * @generated - * @ordered - */ - protected EClass root; - - /** - * - * - * @generated - */ - protected OpenEditorImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.OPEN_EDITOR; - } - - /** - * - * - * @generated - */ - public String getEditorName() { - return editorName; - } - - /** - * - * - * @generated - */ - public void setEditorName(String newEditorName) { - String oldEditorName = editorName; - editorName = newEditorName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.OPEN_EDITOR__EDITOR_NAME, oldEditorName, editorName)); - } - - /** - * - * - * @generated - */ - public EClass getRoot() { - if (root != null && root.eIsProxy()) { - InternalEObject oldRoot = (InternalEObject)root; - root = (EClass)eResolveProxy(oldRoot); - if (root != oldRoot) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, EclipseActionsPackage.OPEN_EDITOR__ROOT, oldRoot, root)); - } - } - return root; - } - - /** - * - * - * @generated - */ - public EClass basicGetRoot() { - return root; - } - - /** - * - * - * @generated - */ - public void setRoot(EClass newRoot) { - EClass oldRoot = root; - root = newRoot; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.OPEN_EDITOR__ROOT, oldRoot, root)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EclipseActionsPackage.OPEN_EDITOR__EDITOR_NAME: - return getEditorName(); - case EclipseActionsPackage.OPEN_EDITOR__ROOT: - if (resolve) return getRoot(); - return basicGetRoot(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EclipseActionsPackage.OPEN_EDITOR__EDITOR_NAME: - setEditorName((String)newValue); - return; - case EclipseActionsPackage.OPEN_EDITOR__ROOT: - setRoot((EClass)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EclipseActionsPackage.OPEN_EDITOR__EDITOR_NAME: - setEditorName(EDITOR_NAME_EDEFAULT); - return; - case EclipseActionsPackage.OPEN_EDITOR__ROOT: - setRoot((EClass)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EclipseActionsPackage.OPEN_EDITOR__EDITOR_NAME: - return EDITOR_NAME_EDEFAULT == null ? editorName != null : !EDITOR_NAME_EDEFAULT.equals(editorName); - case EclipseActionsPackage.OPEN_EDITOR__ROOT: - return root != null; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (editorName: "); - result.append(editorName); - result.append(')'); - return result.toString(); - } - -} //OpenEditorImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenPerspectiveImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenPerspectiveImpl.java deleted file mode 100755 index 5ceac9f33..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenPerspectiveImpl.java +++ /dev/null @@ -1,170 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective; - -/** - * - * An implementation of the model object 'Open Perspective'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenPerspectiveImpl#getType Type}
  • - *
- *

- * - * @generated - */ -public class OpenPerspectiveImpl extends EclipseActionImpl implements OpenPerspective { - /** - * The default value of the '{@link #getType() Type}' attribute. - * - * - * @see #getType() - * @generated - * @ordered - */ - protected static final String TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getType() Type}' attribute. - * - * - * @see #getType() - * @generated - * @ordered - */ - protected String type = TYPE_EDEFAULT; - - /** - * - * - * @generated - */ - protected OpenPerspectiveImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.OPEN_PERSPECTIVE; - } - - /** - * - * - * @generated - */ - public String getType() { - return type; - } - - /** - * - * - * @generated - */ - public void setType(String newType) { - String oldType = type; - type = newType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.OPEN_PERSPECTIVE__TYPE, oldType, type)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EclipseActionsPackage.OPEN_PERSPECTIVE__TYPE: - return getType(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EclipseActionsPackage.OPEN_PERSPECTIVE__TYPE: - setType((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EclipseActionsPackage.OPEN_PERSPECTIVE__TYPE: - setType(TYPE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EclipseActionsPackage.OPEN_PERSPECTIVE__TYPE: - return TYPE_EDEFAULT == null ? type != null : !TYPE_EDEFAULT.equals(type); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (type: "); - result.append(type); - result.append(')'); - return result.toString(); - } - -} //OpenPerspectiveImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenProjectImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenProjectImpl.java deleted file mode 100755 index 879ee3cad..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/OpenProjectImpl.java +++ /dev/null @@ -1,170 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject; - -/** - * - * An implementation of the model object 'Open Project'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.OpenProjectImpl#getProjectName Project Name}
  • - *
- *

- * - * @generated - */ -public class OpenProjectImpl extends EclipseActionImpl implements OpenProject { - /** - * The default value of the '{@link #getProjectName() Project Name}' attribute. - * - * - * @see #getProjectName() - * @generated - * @ordered - */ - protected static final String PROJECT_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getProjectName() Project Name}' attribute. - * - * - * @see #getProjectName() - * @generated - * @ordered - */ - protected String projectName = PROJECT_NAME_EDEFAULT; - - /** - * - * - * @generated - */ - protected OpenProjectImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.OPEN_PROJECT; - } - - /** - * - * - * @generated - */ - public String getProjectName() { - return projectName; - } - - /** - * - * - * @generated - */ - public void setProjectName(String newProjectName) { - String oldProjectName = projectName; - projectName = newProjectName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.OPEN_PROJECT__PROJECT_NAME, oldProjectName, projectName)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EclipseActionsPackage.OPEN_PROJECT__PROJECT_NAME: - return getProjectName(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EclipseActionsPackage.OPEN_PROJECT__PROJECT_NAME: - setProjectName((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EclipseActionsPackage.OPEN_PROJECT__PROJECT_NAME: - setProjectName(PROJECT_NAME_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EclipseActionsPackage.OPEN_PROJECT__PROJECT_NAME: - return PROJECT_NAME_EDEFAULT == null ? projectName != null : !PROJECT_NAME_EDEFAULT.equals(projectName); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (projectName: "); - result.append(projectName); - result.append(')'); - return result.toString(); - } - -} //OpenProjectImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/RedoImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/RedoImpl.java deleted file mode 100755 index 04a2ea35a..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/RedoImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.Redo; - -/** - * - * An implementation of the model object 'Redo'. - * - *

- *

- * - * @generated - */ -public class RedoImpl extends EclipseActionImpl implements Redo { - /** - * - * - * @generated - */ - protected RedoImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.REDO; - } - -} //RedoImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/RemoveProjectImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/RemoveProjectImpl.java deleted file mode 100755 index 06ca4896b..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/RemoveProjectImpl.java +++ /dev/null @@ -1,170 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject; - -/** - * - * An implementation of the model object 'Remove Project'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.EclipseActions.impl.RemoveProjectImpl#getProjectName Project Name}
  • - *
- *

- * - * @generated - */ -public class RemoveProjectImpl extends EclipseActionImpl implements RemoveProject { - /** - * The default value of the '{@link #getProjectName() Project Name}' attribute. - * - * - * @see #getProjectName() - * @generated - * @ordered - */ - protected static final String PROJECT_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getProjectName() Project Name}' attribute. - * - * - * @see #getProjectName() - * @generated - * @ordered - */ - protected String projectName = PROJECT_NAME_EDEFAULT; - - /** - * - * - * @generated - */ - protected RemoveProjectImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.REMOVE_PROJECT; - } - - /** - * - * - * @generated - */ - public String getProjectName() { - return projectName; - } - - /** - * - * - * @generated - */ - public void setProjectName(String newProjectName) { - String oldProjectName = projectName; - projectName = newProjectName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseActionsPackage.REMOVE_PROJECT__PROJECT_NAME, oldProjectName, projectName)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case EclipseActionsPackage.REMOVE_PROJECT__PROJECT_NAME: - return getProjectName(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case EclipseActionsPackage.REMOVE_PROJECT__PROJECT_NAME: - setProjectName((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case EclipseActionsPackage.REMOVE_PROJECT__PROJECT_NAME: - setProjectName(PROJECT_NAME_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case EclipseActionsPackage.REMOVE_PROJECT__PROJECT_NAME: - return PROJECT_NAME_EDEFAULT == null ? projectName != null : !PROJECT_NAME_EDEFAULT.equals(projectName); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (projectName: "); - result.append(projectName); - result.append(')'); - return result.toString(); - } - -} //RemoveProjectImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/SaveImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/SaveImpl.java deleted file mode 100755 index 984c9ab83..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/SaveImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.Save; - -/** - * - * An implementation of the model object 'Save'. - * - *

- *

- * - * @generated - */ -public class SaveImpl extends EclipseActionImpl implements Save { - /** - * - * - * @generated - */ - protected SaveImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.SAVE; - } - -} //SaveImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/UndoImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/UndoImpl.java deleted file mode 100755 index d1f90d0aa..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/impl/UndoImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; -import org.eclipse.emf.eef.modelingBot.EclipseActions.Undo; - -/** - * - * An implementation of the model object 'Undo'. - * - *

- *

- * - * @generated - */ -public class UndoImpl extends EclipseActionImpl implements Undo { - /** - * - * - * @generated - */ - protected UndoImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return EclipseActionsPackage.Literals.UNDO; - } - -} //UndoImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/util/EclipseActionsAdapterFactory.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/util/EclipseActionsAdapterFactory.java deleted file mode 100755 index e92adf621..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/util/EclipseActionsAdapterFactory.java +++ /dev/null @@ -1,403 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; - -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.DocumentedElement; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.*; -import org.eclipse.emf.eef.modelingBot.Processing; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage - * @generated - */ -public class EclipseActionsAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static EclipseActionsPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public EclipseActionsAdapterFactory() { - if (modelPackage == null) { - modelPackage = EclipseActionsPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject)object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected EclipseActionsSwitch modelSwitch = - new EclipseActionsSwitch() { - @Override - public Adapter caseEclipseAction(EclipseAction object) { - return createEclipseActionAdapter(); - } - @Override - public Adapter caseCreateProject(CreateProject object) { - return createCreateProjectAdapter(); - } - @Override - public Adapter caseOpenPerspective(OpenPerspective object) { - return createOpenPerspectiveAdapter(); - } - @Override - public Adapter caseCloseProject(CloseProject object) { - return createCloseProjectAdapter(); - } - @Override - public Adapter caseSave(Save object) { - return createSaveAdapter(); - } - @Override - public Adapter caseUndo(Undo object) { - return createUndoAdapter(); - } - @Override - public Adapter caseRedo(Redo object) { - return createRedoAdapter(); - } - @Override - public Adapter caseOpenProject(OpenProject object) { - return createOpenProjectAdapter(); - } - @Override - public Adapter caseRemoveProject(RemoveProject object) { - return createRemoveProjectAdapter(); - } - @Override - public Adapter caseCloseEditor(CloseEditor object) { - return createCloseEditorAdapter(); - } - @Override - public Adapter caseOpenEditor(OpenEditor object) { - return createOpenEditorAdapter(); - } - @Override - public Adapter caseCreateModel(CreateModel object) { - return createCreateModelAdapter(); - } - @Override - public Adapter caseDocumentedElement(DocumentedElement object) { - return createDocumentedElementAdapter(); - } - @Override - public Adapter caseProcessing(Processing object) { - return createProcessingAdapter(); - } - @Override - public Adapter caseAction(Action object) { - return createActionAdapter(); - } - @Override - public Adapter caseReferenceableObject(ReferenceableObject object) { - return createReferenceableObjectAdapter(); - } - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject)target); - } - - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseAction Eclipse Action}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseAction - * @generated - */ - public Adapter createEclipseActionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject Create Project}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject - * @generated - */ - public Adapter createCreateProjectAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective Open Perspective}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.OpenPerspective - * @generated - */ - public Adapter createOpenPerspectiveAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject Close Project}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject - * @generated - */ - public Adapter createCloseProjectAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.Save Save}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.Save - * @generated - */ - public Adapter createSaveAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.Undo Undo}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.Undo - * @generated - */ - public Adapter createUndoAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.Redo Redo}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.Redo - * @generated - */ - public Adapter createRedoAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject Open Project}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.OpenProject - * @generated - */ - public Adapter createOpenProjectAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject Remove Project}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject - * @generated - */ - public Adapter createRemoveProjectAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor Close Editor}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor - * @generated - */ - public Adapter createCloseEditorAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor Open Editor}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor - * @generated - */ - public Adapter createOpenEditorAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel Create Model}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel - * @generated - */ - public Adapter createCreateModelAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.DocumentedElement Documented Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.DocumentedElement - * @generated - */ - public Adapter createDocumentedElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.Processing Processing}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.Processing - * @generated - */ - public Adapter createProcessingAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.Action Action}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.Action - * @generated - */ - public Adapter createActionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.extended.editor.ReferenceableObject Referenceable Object}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.extended.editor.ReferenceableObject - * @generated - */ - public Adapter createReferenceableObjectAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //EclipseActionsAdapterFactory diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/util/EclipseActionsSwitch.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/util/EclipseActionsSwitch.java deleted file mode 100755 index 868d3e79a..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/EclipseActions/util/EclipseActionsSwitch.java +++ /dev/null @@ -1,478 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.EclipseActions.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.DocumentedElement; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.*; -import org.eclipse.emf.eef.modelingBot.Processing; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage - * @generated - */ -public class EclipseActionsSwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static EclipseActionsPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public EclipseActionsSwitch() { - if (modelPackage == null) { - modelPackage = EclipseActionsPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } - else { - List eSuperTypes = theEClass.getESuperTypes(); - return - eSuperTypes.isEmpty() ? - defaultCase(theEObject) : - doSwitch(eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case EclipseActionsPackage.ECLIPSE_ACTION: { - EclipseAction eclipseAction = (EclipseAction)theEObject; - T result = caseEclipseAction(eclipseAction); - if (result == null) result = caseAction(eclipseAction); - if (result == null) result = caseDocumentedElement(eclipseAction); - if (result == null) result = caseProcessing(eclipseAction); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.CREATE_PROJECT: { - CreateProject createProject = (CreateProject)theEObject; - T result = caseCreateProject(createProject); - if (result == null) result = caseEclipseAction(createProject); - if (result == null) result = caseAction(createProject); - if (result == null) result = caseDocumentedElement(createProject); - if (result == null) result = caseProcessing(createProject); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.OPEN_PERSPECTIVE: { - OpenPerspective openPerspective = (OpenPerspective)theEObject; - T result = caseOpenPerspective(openPerspective); - if (result == null) result = caseEclipseAction(openPerspective); - if (result == null) result = caseAction(openPerspective); - if (result == null) result = caseDocumentedElement(openPerspective); - if (result == null) result = caseProcessing(openPerspective); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.CLOSE_PROJECT: { - CloseProject closeProject = (CloseProject)theEObject; - T result = caseCloseProject(closeProject); - if (result == null) result = caseEclipseAction(closeProject); - if (result == null) result = caseAction(closeProject); - if (result == null) result = caseDocumentedElement(closeProject); - if (result == null) result = caseProcessing(closeProject); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.SAVE: { - Save save = (Save)theEObject; - T result = caseSave(save); - if (result == null) result = caseEclipseAction(save); - if (result == null) result = caseAction(save); - if (result == null) result = caseDocumentedElement(save); - if (result == null) result = caseProcessing(save); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.UNDO: { - Undo undo = (Undo)theEObject; - T result = caseUndo(undo); - if (result == null) result = caseEclipseAction(undo); - if (result == null) result = caseAction(undo); - if (result == null) result = caseDocumentedElement(undo); - if (result == null) result = caseProcessing(undo); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.REDO: { - Redo redo = (Redo)theEObject; - T result = caseRedo(redo); - if (result == null) result = caseEclipseAction(redo); - if (result == null) result = caseAction(redo); - if (result == null) result = caseDocumentedElement(redo); - if (result == null) result = caseProcessing(redo); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.OPEN_PROJECT: { - OpenProject openProject = (OpenProject)theEObject; - T result = caseOpenProject(openProject); - if (result == null) result = caseEclipseAction(openProject); - if (result == null) result = caseAction(openProject); - if (result == null) result = caseDocumentedElement(openProject); - if (result == null) result = caseProcessing(openProject); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.REMOVE_PROJECT: { - RemoveProject removeProject = (RemoveProject)theEObject; - T result = caseRemoveProject(removeProject); - if (result == null) result = caseEclipseAction(removeProject); - if (result == null) result = caseAction(removeProject); - if (result == null) result = caseDocumentedElement(removeProject); - if (result == null) result = caseProcessing(removeProject); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.CLOSE_EDITOR: { - CloseEditor closeEditor = (CloseEditor)theEObject; - T result = caseCloseEditor(closeEditor); - if (result == null) result = caseEclipseAction(closeEditor); - if (result == null) result = caseAction(closeEditor); - if (result == null) result = caseDocumentedElement(closeEditor); - if (result == null) result = caseProcessing(closeEditor); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.OPEN_EDITOR: { - OpenEditor openEditor = (OpenEditor)theEObject; - T result = caseOpenEditor(openEditor); - if (result == null) result = caseEclipseAction(openEditor); - if (result == null) result = caseAction(openEditor); - if (result == null) result = caseDocumentedElement(openEditor); - if (result == null) result = caseProcessing(openEditor); - if (result == null) result = defaultCase(theEObject); - return result; - } - case EclipseActionsPackage.CREATE_MODEL: { - CreateModel createModel = (CreateModel)theEObject; - T result = caseCreateModel(createModel); - if (result == null) result = caseEclipseAction(createModel); - if (result == null) result = caseReferenceableObject(createModel); - if (result == null) result = caseAction(createModel); - if (result == null) result = caseDocumentedElement(createModel); - if (result == null) result = caseProcessing(createModel); - if (result == null) result = defaultCase(theEObject); - return result; - } - default: return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'Eclipse Action'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Eclipse Action'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEclipseAction(EclipseAction object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Create Project'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Create Project'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCreateProject(CreateProject object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Open Perspective'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Open Perspective'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseOpenPerspective(OpenPerspective object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Close Project'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Close Project'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCloseProject(CloseProject object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Save'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Save'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseSave(Save object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Undo'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Undo'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseUndo(Undo object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Redo'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Redo'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseRedo(Redo object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Open Project'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Open Project'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseOpenProject(OpenProject object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Remove Project'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Remove Project'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseRemoveProject(RemoveProject object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Close Editor'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Close Editor'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCloseEditor(CloseEditor object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Open Editor'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Open Editor'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseOpenEditor(OpenEditor object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Create Model'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Create Model'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCreateModel(CreateModel object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Documented Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Documented Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDocumentedElement(DocumentedElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Processing'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Processing'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseProcessing(Processing object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Action'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Action'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAction(Action object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Referenceable Object'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Referenceable Object'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseReferenceableObject(ReferenceableObject object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //EclipseActionsSwitch diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBot.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBot.java deleted file mode 100755 index 7cd3bcc2a..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBot.java +++ /dev/null @@ -1,79 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.components.PropertiesEditionContext; - -/** - * - * A representation of the model object 'Modeling Bot'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.ModelingBot#getPropertiesEditionContext Properties Edition Context}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.ModelingBot#getSequences Sequences}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getModelingBot() - * @model - * @generated - */ -public interface ModelingBot extends EObject { - /** - * Returns the value of the 'Properties Edition Context' reference. - * - *

- * If the meaning of the 'Properties Edition Context' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Properties Edition Context' reference. - * @see #setPropertiesEditionContext(PropertiesEditionContext) - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getModelingBot_PropertiesEditionContext() - * @model - * @generated - */ - PropertiesEditionContext getPropertiesEditionContext(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.ModelingBot#getPropertiesEditionContext Properties Edition Context}' reference. - * - * - * @param value the new value of the 'Properties Edition Context' reference. - * @see #getPropertiesEditionContext() - * @generated - */ - void setPropertiesEditionContext(PropertiesEditionContext value); - - /** - * Returns the value of the 'Sequences' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.modelingBot.Sequence}. - * - *

- * If the meaning of the 'Sequences' reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Sequences' containment reference list. - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getModelingBot_Sequences() - * @model containment="true" - * @generated - */ - EList getSequences(); - -} // ModelingBot diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBotFactory.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBotFactory.java deleted file mode 100755 index 61adf323d..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBotFactory.java +++ /dev/null @@ -1,86 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage - * @generated - */ -public interface ModelingBotFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - ModelingBotFactory eINSTANCE = org.eclipse.emf.eef.modelingBot.impl.ModelingBotFactoryImpl.init(); - - /** - * Returns a new object of class 'Scenario'. - * - * - * @return a new object of class 'Scenario'. - * @generated - */ - Scenario createScenario(); - - /** - * Returns a new object of class 'Wizard'. - * - * - * @return a new object of class 'Wizard'. - * @generated - */ - Wizard createWizard(); - - /** - * Returns a new object of class 'Modeling Bot'. - * - * - * @return a new object of class 'Modeling Bot'. - * @generated - */ - ModelingBot createModelingBot(); - - /** - * Returns a new object of class 'Details Page'. - * - * - * @return a new object of class 'Details Page'. - * @generated - */ - DetailsPage createDetailsPage(); - - /** - * Returns a new object of class 'Properties View'. - * - * - * @return a new object of class 'Properties View'. - * @generated - */ - PropertiesView createPropertiesView(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - ModelingBotPackage getModelingBotPackage(); - -} //ModelingBotFactory diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBotPackage.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBotPackage.java deleted file mode 100755 index aa8465c07..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/ModelingBotPackage.java +++ /dev/null @@ -1,944 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EEnum; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotFactory - * @model kind="package" - * @generated - */ -public interface ModelingBotPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "modelingBot"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "http://www.eclipse.org/emf/eef/mbot/1.0.0"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "eef-mbot"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - ModelingBotPackage eINSTANCE = org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl.init(); - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.impl.DocumentedElementImpl Documented Element}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.DocumentedElementImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getDocumentedElement() - * @generated - */ - int DOCUMENTED_ELEMENT = 4; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int DOCUMENTED_ELEMENT__NAME = 0; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int DOCUMENTED_ELEMENT__DOCUMENTATION = 1; - - /** - * The number of structural features of the 'Documented Element' class. - * - * - * @generated - * @ordered - */ - int DOCUMENTED_ELEMENT_FEATURE_COUNT = 2; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.impl.SequenceImpl Sequence}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.SequenceImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getSequence() - * @generated - */ - int SEQUENCE = 2; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int SEQUENCE__NAME = DOCUMENTED_ELEMENT__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int SEQUENCE__DOCUMENTATION = DOCUMENTED_ELEMENT__DOCUMENTATION; - - /** - * The feature id for the 'Actions' containment reference list. - * - * - * @generated - * @ordered - */ - int SEQUENCE__ACTIONS = DOCUMENTED_ELEMENT_FEATURE_COUNT + 0; - - /** - * The feature id for the 'Sequences' containment reference list. - * - * - * @generated - * @ordered - */ - int SEQUENCE__SEQUENCES = DOCUMENTED_ELEMENT_FEATURE_COUNT + 1; - - /** - * The feature id for the 'Processings' containment reference list. - * - * - * @generated - * @ordered - */ - int SEQUENCE__PROCESSINGS = DOCUMENTED_ELEMENT_FEATURE_COUNT + 2; - - /** - * The number of structural features of the 'Sequence' class. - * - * - * @generated - * @ordered - */ - int SEQUENCE_FEATURE_COUNT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 3; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.impl.ScenarioImpl Scenario}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.ScenarioImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getScenario() - * @generated - */ - int SCENARIO = 0; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int SCENARIO__NAME = SEQUENCE__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int SCENARIO__DOCUMENTATION = SEQUENCE__DOCUMENTATION; - - /** - * The feature id for the 'Actions' containment reference list. - * - * - * @generated - * @ordered - */ - int SCENARIO__ACTIONS = SEQUENCE__ACTIONS; - - /** - * The feature id for the 'Sequences' containment reference list. - * - * - * @generated - * @ordered - */ - int SCENARIO__SEQUENCES = SEQUENCE__SEQUENCES; - - /** - * The feature id for the 'Processings' containment reference list. - * - * - * @generated - * @ordered - */ - int SCENARIO__PROCESSINGS = SEQUENCE__PROCESSINGS; - - /** - * The number of structural features of the 'Scenario' class. - * - * - * @generated - * @ordered - */ - int SCENARIO_FEATURE_COUNT = SEQUENCE_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.impl.ActionImpl Action}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.ActionImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getAction() - * @generated - */ - int ACTION = 1; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int ACTION__NAME = DOCUMENTED_ELEMENT__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int ACTION__DOCUMENTATION = DOCUMENTED_ELEMENT__DOCUMENTATION; - - /** - * The number of structural features of the 'Action' class. - * - * - * @generated - * @ordered - */ - int ACTION_FEATURE_COUNT = DOCUMENTED_ELEMENT_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.impl.WizardImpl Wizard}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.WizardImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getWizard() - * @generated - */ - int WIZARD = 3; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int WIZARD__NAME = SEQUENCE__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int WIZARD__DOCUMENTATION = SEQUENCE__DOCUMENTATION; - - /** - * The feature id for the 'Actions' containment reference list. - * - * - * @generated - * @ordered - */ - int WIZARD__ACTIONS = SEQUENCE__ACTIONS; - - /** - * The feature id for the 'Sequences' containment reference list. - * - * - * @generated - * @ordered - */ - int WIZARD__SEQUENCES = SEQUENCE__SEQUENCES; - - /** - * The feature id for the 'Processings' containment reference list. - * - * - * @generated - * @ordered - */ - int WIZARD__PROCESSINGS = SEQUENCE__PROCESSINGS; - - /** - * The feature id for the 'Referenceable Object' reference. - * - * - * @generated - * @ordered - */ - int WIZARD__REFERENCEABLE_OBJECT = SEQUENCE_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Wizard' class. - * - * - * @generated - * @ordered - */ - int WIZARD_FEATURE_COUNT = SEQUENCE_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.impl.ModelingBotImpl Modeling Bot}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getModelingBot() - * @generated - */ - int MODELING_BOT = 5; - - /** - * The feature id for the 'Properties Edition Context' reference. - * - * - * @generated - * @ordered - */ - int MODELING_BOT__PROPERTIES_EDITION_CONTEXT = 0; - - /** - * The feature id for the 'Sequences' containment reference list. - * - * - * @generated - * @ordered - */ - int MODELING_BOT__SEQUENCES = 1; - - /** - * The number of structural features of the 'Modeling Bot' class. - * - * - * @generated - * @ordered - */ - int MODELING_BOT_FEATURE_COUNT = 2; - - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.impl.DetailsPageImpl Details Page}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.DetailsPageImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getDetailsPage() - * @generated - */ - int DETAILS_PAGE = 6; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int DETAILS_PAGE__NAME = SEQUENCE__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int DETAILS_PAGE__DOCUMENTATION = SEQUENCE__DOCUMENTATION; - - /** - * The feature id for the 'Actions' containment reference list. - * - * - * @generated - * @ordered - */ - int DETAILS_PAGE__ACTIONS = SEQUENCE__ACTIONS; - - /** - * The feature id for the 'Sequences' containment reference list. - * - * - * @generated - * @ordered - */ - int DETAILS_PAGE__SEQUENCES = SEQUENCE__SEQUENCES; - - /** - * The feature id for the 'Processings' containment reference list. - * - * - * @generated - * @ordered - */ - int DETAILS_PAGE__PROCESSINGS = SEQUENCE__PROCESSINGS; - - /** - * The number of structural features of the 'Details Page' class. - * - * - * @generated - * @ordered - */ - int DETAILS_PAGE_FEATURE_COUNT = SEQUENCE_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.impl.PropertiesViewImpl Properties View}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.PropertiesViewImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getPropertiesView() - * @generated - */ - int PROPERTIES_VIEW = 7; - - /** - * The feature id for the 'Name' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_VIEW__NAME = SEQUENCE__NAME; - - /** - * The feature id for the 'Documentation' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_VIEW__DOCUMENTATION = SEQUENCE__DOCUMENTATION; - - /** - * The feature id for the 'Actions' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_VIEW__ACTIONS = SEQUENCE__ACTIONS; - - /** - * The feature id for the 'Sequences' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_VIEW__SEQUENCES = SEQUENCE__SEQUENCES; - - /** - * The feature id for the 'Processings' containment reference list. - * - * - * @generated - * @ordered - */ - int PROPERTIES_VIEW__PROCESSINGS = SEQUENCE__PROCESSINGS; - - /** - * The feature id for the 'Id' attribute. - * - * - * @generated - * @ordered - */ - int PROPERTIES_VIEW__ID = SEQUENCE_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'Properties View' class. - * - * - * @generated - * @ordered - */ - int PROPERTIES_VIEW_FEATURE_COUNT = SEQUENCE_FEATURE_COUNT + 1; - - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.Processing Processing}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.Processing - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getProcessing() - * @generated - */ - int PROCESSING = 8; - - /** - * The number of structural features of the 'Processing' class. - * - * - * @generated - * @ordered - */ - int PROCESSING_FEATURE_COUNT = 0; - - - /** - * The meta object id for the '{@link org.eclipse.emf.eef.modelingBot.SequenceType Sequence Type}' enum. - * - * - * @see org.eclipse.emf.eef.modelingBot.SequenceType - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getSequenceType() - * @generated - */ - int SEQUENCE_TYPE = 9; - - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.Scenario Scenario}'. - * - * - * @return the meta object for class 'Scenario'. - * @see org.eclipse.emf.eef.modelingBot.Scenario - * @generated - */ - EClass getScenario(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.Action Action}'. - * - * - * @return the meta object for class 'Action'. - * @see org.eclipse.emf.eef.modelingBot.Action - * @generated - */ - EClass getAction(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.Sequence Sequence}'. - * - * - * @return the meta object for class 'Sequence'. - * @see org.eclipse.emf.eef.modelingBot.Sequence - * @generated - */ - EClass getSequence(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.modelingBot.Sequence#getActions Actions}'. - * - * - * @return the meta object for the containment reference list 'Actions'. - * @see org.eclipse.emf.eef.modelingBot.Sequence#getActions() - * @see #getSequence() - * @generated - */ - EReference getSequence_Actions(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.modelingBot.Sequence#getSequences Sequences}'. - * - * - * @return the meta object for the containment reference list 'Sequences'. - * @see org.eclipse.emf.eef.modelingBot.Sequence#getSequences() - * @see #getSequence() - * @generated - */ - EReference getSequence_Sequences(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.modelingBot.Sequence#getProcessings Processings}'. - * - * - * @return the meta object for the containment reference list 'Processings'. - * @see org.eclipse.emf.eef.modelingBot.Sequence#getProcessings() - * @see #getSequence() - * @generated - */ - EReference getSequence_Processings(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.Wizard Wizard}'. - * - * - * @return the meta object for class 'Wizard'. - * @see org.eclipse.emf.eef.modelingBot.Wizard - * @generated - */ - EClass getWizard(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.Wizard#getReferenceableObject Referenceable Object}'. - * - * - * @return the meta object for the reference 'Referenceable Object'. - * @see org.eclipse.emf.eef.modelingBot.Wizard#getReferenceableObject() - * @see #getWizard() - * @generated - */ - EReference getWizard_ReferenceableObject(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.DocumentedElement Documented Element}'. - * - * - * @return the meta object for class 'Documented Element'. - * @see org.eclipse.emf.eef.modelingBot.DocumentedElement - * @generated - */ - EClass getDocumentedElement(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.DocumentedElement#getName Name}'. - * - * - * @return the meta object for the attribute 'Name'. - * @see org.eclipse.emf.eef.modelingBot.DocumentedElement#getName() - * @see #getDocumentedElement() - * @generated - */ - EAttribute getDocumentedElement_Name(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.DocumentedElement#getDocumentation Documentation}'. - * - * - * @return the meta object for the attribute 'Documentation'. - * @see org.eclipse.emf.eef.modelingBot.DocumentedElement#getDocumentation() - * @see #getDocumentedElement() - * @generated - */ - EAttribute getDocumentedElement_Documentation(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.ModelingBot Modeling Bot}'. - * - * - * @return the meta object for class 'Modeling Bot'. - * @see org.eclipse.emf.eef.modelingBot.ModelingBot - * @generated - */ - EClass getModelingBot(); - - /** - * Returns the meta object for the reference '{@link org.eclipse.emf.eef.modelingBot.ModelingBot#getPropertiesEditionContext Properties Edition Context}'. - * - * - * @return the meta object for the reference 'Properties Edition Context'. - * @see org.eclipse.emf.eef.modelingBot.ModelingBot#getPropertiesEditionContext() - * @see #getModelingBot() - * @generated - */ - EReference getModelingBot_PropertiesEditionContext(); - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.emf.eef.modelingBot.ModelingBot#getSequences Sequences}'. - * - * - * @return the meta object for the containment reference list 'Sequences'. - * @see org.eclipse.emf.eef.modelingBot.ModelingBot#getSequences() - * @see #getModelingBot() - * @generated - */ - EReference getModelingBot_Sequences(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.DetailsPage Details Page}'. - * - * - * @return the meta object for class 'Details Page'. - * @see org.eclipse.emf.eef.modelingBot.DetailsPage - * @generated - */ - EClass getDetailsPage(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.PropertiesView Properties View}'. - * - * - * @return the meta object for class 'Properties View'. - * @see org.eclipse.emf.eef.modelingBot.PropertiesView - * @generated - */ - EClass getPropertiesView(); - - /** - * Returns the meta object for the attribute '{@link org.eclipse.emf.eef.modelingBot.PropertiesView#getId Id}'. - * - * - * @return the meta object for the attribute 'Id'. - * @see org.eclipse.emf.eef.modelingBot.PropertiesView#getId() - * @see #getPropertiesView() - * @generated - */ - EAttribute getPropertiesView_Id(); - - /** - * Returns the meta object for class '{@link org.eclipse.emf.eef.modelingBot.Processing Processing}'. - * - * - * @return the meta object for class 'Processing'. - * @see org.eclipse.emf.eef.modelingBot.Processing - * @generated - */ - EClass getProcessing(); - - /** - * Returns the meta object for enum '{@link org.eclipse.emf.eef.modelingBot.SequenceType Sequence Type}'. - * - * - * @return the meta object for enum 'Sequence Type'. - * @see org.eclipse.emf.eef.modelingBot.SequenceType - * @generated - */ - EEnum getSequenceType(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - ModelingBotFactory getModelingBotFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
    - *
  • each class,
  • - *
  • each feature of each class,
  • - *
  • each enum,
  • - *
  • and each data type
  • - *
- * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.impl.ScenarioImpl Scenario}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.ScenarioImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getScenario() - * @generated - */ - EClass SCENARIO = eINSTANCE.getScenario(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.impl.ActionImpl Action}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.ActionImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getAction() - * @generated - */ - EClass ACTION = eINSTANCE.getAction(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.impl.SequenceImpl Sequence}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.SequenceImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getSequence() - * @generated - */ - EClass SEQUENCE = eINSTANCE.getSequence(); - - /** - * The meta object literal for the 'Actions' containment reference list feature. - * - * - * @generated - */ - EReference SEQUENCE__ACTIONS = eINSTANCE.getSequence_Actions(); - - /** - * The meta object literal for the 'Sequences' containment reference list feature. - * - * - * @generated - */ - EReference SEQUENCE__SEQUENCES = eINSTANCE.getSequence_Sequences(); - - /** - * The meta object literal for the 'Processings' containment reference list feature. - * - * - * @generated - */ - EReference SEQUENCE__PROCESSINGS = eINSTANCE.getSequence_Processings(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.impl.WizardImpl Wizard}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.WizardImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getWizard() - * @generated - */ - EClass WIZARD = eINSTANCE.getWizard(); - - /** - * The meta object literal for the 'Referenceable Object' reference feature. - * - * - * @generated - */ - EReference WIZARD__REFERENCEABLE_OBJECT = eINSTANCE.getWizard_ReferenceableObject(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.impl.DocumentedElementImpl Documented Element}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.DocumentedElementImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getDocumentedElement() - * @generated - */ - EClass DOCUMENTED_ELEMENT = eINSTANCE.getDocumentedElement(); - - /** - * The meta object literal for the 'Name' attribute feature. - * - * - * @generated - */ - EAttribute DOCUMENTED_ELEMENT__NAME = eINSTANCE.getDocumentedElement_Name(); - - /** - * The meta object literal for the 'Documentation' attribute feature. - * - * - * @generated - */ - EAttribute DOCUMENTED_ELEMENT__DOCUMENTATION = eINSTANCE.getDocumentedElement_Documentation(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.impl.ModelingBotImpl Modeling Bot}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getModelingBot() - * @generated - */ - EClass MODELING_BOT = eINSTANCE.getModelingBot(); - - /** - * The meta object literal for the 'Properties Edition Context' reference feature. - * - * - * @generated - */ - EReference MODELING_BOT__PROPERTIES_EDITION_CONTEXT = eINSTANCE.getModelingBot_PropertiesEditionContext(); - - /** - * The meta object literal for the 'Sequences' containment reference list feature. - * - * - * @generated - */ - EReference MODELING_BOT__SEQUENCES = eINSTANCE.getModelingBot_Sequences(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.impl.DetailsPageImpl Details Page}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.DetailsPageImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getDetailsPage() - * @generated - */ - EClass DETAILS_PAGE = eINSTANCE.getDetailsPage(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.impl.PropertiesViewImpl Properties View}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.impl.PropertiesViewImpl - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getPropertiesView() - * @generated - */ - EClass PROPERTIES_VIEW = eINSTANCE.getPropertiesView(); - - /** - * The meta object literal for the 'Id' attribute feature. - * - * - * @generated - */ - EAttribute PROPERTIES_VIEW__ID = eINSTANCE.getPropertiesView_Id(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.Processing Processing}' class. - * - * - * @see org.eclipse.emf.eef.modelingBot.Processing - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getProcessing() - * @generated - */ - EClass PROCESSING = eINSTANCE.getProcessing(); - - /** - * The meta object literal for the '{@link org.eclipse.emf.eef.modelingBot.SequenceType Sequence Type}' enum. - * - * - * @see org.eclipse.emf.eef.modelingBot.SequenceType - * @see org.eclipse.emf.eef.modelingBot.impl.ModelingBotPackageImpl#getSequenceType() - * @generated - */ - EEnum SEQUENCE_TYPE = eINSTANCE.getSequenceType(); - - } - -} //ModelingBotPackage diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Processing.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Processing.java deleted file mode 100755 index e634c6855..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Processing.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'Processing'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getProcessing() - * @model interface="true" abstract="true" - * @generated - */ -public interface Processing extends EObject { -} // Processing diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/PropertiesView.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/PropertiesView.java deleted file mode 100755 index 7dd61e358..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/PropertiesView.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - - -/** - * - * A representation of the model object 'Properties View'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.PropertiesView#getId Id}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getPropertiesView() - * @model - * @generated - */ -public interface PropertiesView extends Sequence { - /** - * Returns the value of the 'Id' attribute. - * - *

- * If the meaning of the 'Id' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Id' attribute. - * @see #setId(String) - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getPropertiesView_Id() - * @model - * @generated - */ - String getId(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.PropertiesView#getId Id}' attribute. - * - * - * @param value the new value of the 'Id' attribute. - * @see #getId() - * @generated - */ - void setId(String value); - -} // PropertiesView diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Scenario.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Scenario.java deleted file mode 100755 index 8d2186e47..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Scenario.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - - -/** - * - * A representation of the model object 'Scenario'. - * - * - * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getScenario() - * @model - * @generated - */ -public interface Scenario extends Sequence { -} // Scenario diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Sequence.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Sequence.java deleted file mode 100755 index 9d98e88ca..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Sequence.java +++ /dev/null @@ -1,82 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - -import org.eclipse.emf.common.util.EList; - -/** - * - * A representation of the model object 'Sequence'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.Sequence#getActions Actions}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.Sequence#getSequences Sequences}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.Sequence#getProcessings Processings}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getSequence() - * @model abstract="true" - * @generated - */ -public interface Sequence extends DocumentedElement, Processing { - /** - * Returns the value of the 'Actions' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.modelingBot.Action}. - * - *

- * If the meaning of the 'Actions' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Actions' containment reference list. - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getSequence_Actions() - * @model containment="true" transient="true" derived="true" - * @generated - */ - EList getActions(); - - /** - * Returns the value of the 'Sequences' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.modelingBot.Sequence}. - * - *

- * If the meaning of the 'Sequences' reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Sequences' containment reference list. - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getSequence_Sequences() - * @model containment="true" transient="true" derived="true" - * @generated - */ - EList getSequences(); - - /** - * Returns the value of the 'Processings' containment reference list. - * The list contents are of type {@link org.eclipse.emf.eef.modelingBot.Processing}. - * - *

- * If the meaning of the 'Processings' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Processings' containment reference list. - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getSequence_Processings() - * @model containment="true" - * @generated - */ - EList getProcessings(); - -} // Sequence diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/SequenceType.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/SequenceType.java deleted file mode 100755 index 1939b8b13..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/SequenceType.java +++ /dev/null @@ -1,243 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; - -import org.eclipse.emf.common.util.Enumerator; - -/** - * - * A representation of the literals of the enumeration 'Sequence Type', - * and utility methods for working with them. - * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getSequenceType() - * @model - * @generated - */ -public enum SequenceType implements Enumerator { - /** - * The 'DETAILS PAGE' literal object. - * - * - * @see #DETAILS_PAGE_VALUE - * @generated - * @ordered - */ - DETAILS_PAGE(0, "DETAILS_PAGE", "DETAILS_PAGE"), - - /** - * The 'WIZARD' literal object. - * - * - * @see #WIZARD_VALUE - * @generated - * @ordered - */ - WIZARD(1, "WIZARD", "WIZARD"), - - /** - * The 'PROPERTIES VIEW' literal object. - * - * - * @see #PROPERTIES_VIEW_VALUE - * @generated - * @ordered - */ - PROPERTIES_VIEW(2, "PROPERTIES_VIEW", "PROPERTIES_VIEW"); - - /** - * The 'DETAILS PAGE' literal value. - * - *

- * If the meaning of 'DETAILS PAGE' literal object isn't clear, - * there really should be more of a description here... - *

- * - * @see #DETAILS_PAGE - * @model - * @generated - * @ordered - */ - public static final int DETAILS_PAGE_VALUE = 0; - - /** - * The 'WIZARD' literal value. - * - *

- * If the meaning of 'WIZARD' literal object isn't clear, - * there really should be more of a description here... - *

- * - * @see #WIZARD - * @model - * @generated - * @ordered - */ - public static final int WIZARD_VALUE = 1; - - /** - * The 'PROPERTIES VIEW' literal value. - * - *

- * If the meaning of 'PROPERTIES VIEW' literal object isn't clear, - * there really should be more of a description here... - *

- * - * @see #PROPERTIES_VIEW - * @model - * @generated - * @ordered - */ - public static final int PROPERTIES_VIEW_VALUE = 2; - - /** - * An array of all the 'Sequence Type' enumerators. - * - * - * @generated - */ - private static final SequenceType[] VALUES_ARRAY = - new SequenceType[] { - DETAILS_PAGE, - WIZARD, - PROPERTIES_VIEW, - }; - - /** - * A public read-only list of all the 'Sequence Type' enumerators. - * - * - * @generated - */ - public static final List VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the 'Sequence Type' literal with the specified literal value. - * - * - * @generated - */ - public static SequenceType get(String literal) { - for (int i = 0; i < VALUES_ARRAY.length; ++i) { - SequenceType result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) { - return result; - } - } - return null; - } - - /** - * Returns the 'Sequence Type' literal with the specified name. - * - * - * @generated - */ - public static SequenceType getByName(String name) { - for (int i = 0; i < VALUES_ARRAY.length; ++i) { - SequenceType result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) { - return result; - } - } - return null; - } - - /** - * Returns the 'Sequence Type' literal with the specified integer value. - * - * - * @generated - */ - public static SequenceType get(int value) { - switch (value) { - case DETAILS_PAGE_VALUE: return DETAILS_PAGE; - case WIZARD_VALUE: return WIZARD; - case PROPERTIES_VIEW_VALUE: return PROPERTIES_VIEW; - } - return null; - } - - /** - * - * - * @generated - */ - private final int value; - - /** - * - * - * @generated - */ - private final String name; - - /** - * - * - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * - * - * @generated - */ - private SequenceType(int value, String name, String literal) { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * - * - * @generated - */ - public int getValue() { - return value; - } - - /** - * - * - * @generated - */ - public String getName() { - return name; - } - - /** - * - * - * @generated - */ - public String getLiteral() { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * - * - * @generated - */ - @Override - public String toString() { - return literal; - } - -} //SequenceType diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Wizard.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Wizard.java deleted file mode 100755 index 59ff8b8a7..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/Wizard.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; - - -/** - * - * A representation of the model object 'Wizard'. - * - * - *

- * The following features are supported: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.Wizard#getReferenceableObject Referenceable Object}
  • - *
- *

- * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getWizard() - * @model - * @generated - */ -public interface Wizard extends Sequence { - - /** - * Returns the value of the 'Referenceable Object' reference. - * - *

- * If the meaning of the 'Referenceable Object' reference isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Referenceable Object' reference. - * @see #setReferenceableObject(ReferenceableObject) - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#getWizard_ReferenceableObject() - * @model - * @generated - */ - ReferenceableObject getReferenceableObject(); - - /** - * Sets the value of the '{@link org.eclipse.emf.eef.modelingBot.Wizard#getReferenceableObject Referenceable Object}' reference. - * - * - * @param value the new value of the 'Referenceable Object' reference. - * @see #getReferenceableObject() - * @generated - */ - void setReferenceableObject(ReferenceableObject value); -} // Wizard diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ActionImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ActionImpl.java deleted file mode 100755 index 34f29019c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ActionImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; - -/** - * - * An implementation of the model object 'Action'. - * - *

- *

- * - * @generated - */ -public abstract class ActionImpl extends DocumentedElementImpl implements Action { - /** - * - * - * @generated - */ - protected ActionImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModelingBotPackage.Literals.ACTION; - } - -} //ActionImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/DetailsPageImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/DetailsPageImpl.java deleted file mode 100755 index f8ad40824..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/DetailsPageImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.DetailsPage; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; - -/** - * - * An implementation of the model object 'Details Page'. - * - *

- *

- * - * @generated - */ -public class DetailsPageImpl extends SequenceImpl implements DetailsPage { - /** - * - * - * @generated - */ - protected DetailsPageImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModelingBotPackage.Literals.DETAILS_PAGE; - } - -} //DetailsPageImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/DocumentedElementImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/DocumentedElementImpl.java deleted file mode 100755 index 13d61bc43..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/DocumentedElementImpl.java +++ /dev/null @@ -1,225 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; - -import org.eclipse.emf.eef.modelingBot.DocumentedElement; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; - -/** - * - * An implementation of the model object 'Documented Element'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.impl.DocumentedElementImpl#getName Name}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.impl.DocumentedElementImpl#getDocumentation Documentation}
  • - *
- *

- * - * @generated - */ -public abstract class DocumentedElementImpl extends EObjectImpl implements DocumentedElement { - /** - * The default value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The default value of the '{@link #getDocumentation() Documentation}' attribute. - * - * - * @see #getDocumentation() - * @generated - * @ordered - */ - protected static final String DOCUMENTATION_EDEFAULT = null; - - /** - * The cached value of the '{@link #getDocumentation() Documentation}' attribute. - * - * - * @see #getDocumentation() - * @generated - * @ordered - */ - protected String documentation = DOCUMENTATION_EDEFAULT; - - /** - * - * - * @generated - */ - protected DocumentedElementImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModelingBotPackage.Literals.DOCUMENTED_ELEMENT; - } - - /** - * - * - * @generated - */ - public String getName() { - return name; - } - - /** - * - * - * @generated - */ - public void setName(String newName) { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, ModelingBotPackage.DOCUMENTED_ELEMENT__NAME, oldName, name)); - } - - /** - * - * - * @generated - */ - public String getDocumentation() { - return documentation; - } - - /** - * - * - * @generated - */ - public void setDocumentation(String newDocumentation) { - String oldDocumentation = documentation; - documentation = newDocumentation; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, ModelingBotPackage.DOCUMENTED_ELEMENT__DOCUMENTATION, oldDocumentation, documentation)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ModelingBotPackage.DOCUMENTED_ELEMENT__NAME: - return getName(); - case ModelingBotPackage.DOCUMENTED_ELEMENT__DOCUMENTATION: - return getDocumentation(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ModelingBotPackage.DOCUMENTED_ELEMENT__NAME: - setName((String)newValue); - return; - case ModelingBotPackage.DOCUMENTED_ELEMENT__DOCUMENTATION: - setDocumentation((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ModelingBotPackage.DOCUMENTED_ELEMENT__NAME: - setName(NAME_EDEFAULT); - return; - case ModelingBotPackage.DOCUMENTED_ELEMENT__DOCUMENTATION: - setDocumentation(DOCUMENTATION_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ModelingBotPackage.DOCUMENTED_ELEMENT__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); - case ModelingBotPackage.DOCUMENTED_ELEMENT__DOCUMENTATION: - return DOCUMENTATION_EDEFAULT == null ? documentation != null : !DOCUMENTATION_EDEFAULT.equals(documentation); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(", documentation: "); - result.append(documentation); - result.append(')'); - return result.toString(); - } - -} //DocumentedElementImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotFactoryImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotFactoryImpl.java deleted file mode 100755 index 1dcc6da9a..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotFactoryImpl.java +++ /dev/null @@ -1,198 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EDataType; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.impl.EFactoryImpl; - -import org.eclipse.emf.ecore.plugin.EcorePlugin; - -import org.eclipse.emf.eef.modelingBot.*; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class ModelingBotFactoryImpl extends EFactoryImpl implements ModelingBotFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static ModelingBotFactory init() { - try { - ModelingBotFactory theModelingBotFactory = (ModelingBotFactory)EPackage.Registry.INSTANCE.getEFactory("http://www.eclipse.org/emf/eef/mbot/1.0.0"); - if (theModelingBotFactory != null) { - return theModelingBotFactory; - } - } - catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new ModelingBotFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public ModelingBotFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case ModelingBotPackage.SCENARIO: return createScenario(); - case ModelingBotPackage.WIZARD: return createWizard(); - case ModelingBotPackage.MODELING_BOT: return createModelingBot(); - case ModelingBotPackage.DETAILS_PAGE: return createDetailsPage(); - case ModelingBotPackage.PROPERTIES_VIEW: return createPropertiesView(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - @Override - public Object createFromString(EDataType eDataType, String initialValue) { - switch (eDataType.getClassifierID()) { - case ModelingBotPackage.SEQUENCE_TYPE: - return createSequenceTypeFromString(eDataType, initialValue); - default: - throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - @Override - public String convertToString(EDataType eDataType, Object instanceValue) { - switch (eDataType.getClassifierID()) { - case ModelingBotPackage.SEQUENCE_TYPE: - return convertSequenceTypeToString(eDataType, instanceValue); - default: - throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public Scenario createScenario() { - ScenarioImpl scenario = new ScenarioImpl(); - return scenario; - } - - /** - * - * - * @generated - */ - public Wizard createWizard() { - WizardImpl wizard = new WizardImpl(); - return wizard; - } - - /** - * - * - * @generated - */ - public ModelingBot createModelingBot() { - ModelingBotImpl modelingBot = new ModelingBotImpl(); - return modelingBot; - } - - /** - * - * - * @generated - */ - public DetailsPage createDetailsPage() { - DetailsPageImpl detailsPage = new DetailsPageImpl(); - return detailsPage; - } - - /** - * - * - * @generated - */ - public PropertiesView createPropertiesView() { - PropertiesViewImpl propertiesView = new PropertiesViewImpl(); - return propertiesView; - } - - /** - * - * - * @generated - */ - public SequenceType createSequenceTypeFromString(EDataType eDataType, String initialValue) { - SequenceType result = SequenceType.get(initialValue); - if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - return result; - } - - /** - * - * - * @generated - */ - public String convertSequenceTypeToString(EDataType eDataType, Object instanceValue) { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * - * - * @generated - */ - public ModelingBotPackage getModelingBotPackage() { - return (ModelingBotPackage)getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static ModelingBotPackage getPackage() { - return ModelingBotPackage.eINSTANCE; - } - -} //ModelingBotFactoryImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotImpl.java deleted file mode 100755 index 1b7653f10..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotImpl.java +++ /dev/null @@ -1,224 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; - -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.InternalEList; - -import org.eclipse.emf.eef.components.PropertiesEditionContext; - -import org.eclipse.emf.eef.modelingBot.ModelingBot; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.Sequence; - -/** - * - * An implementation of the model object 'Modeling Bot'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.impl.ModelingBotImpl#getPropertiesEditionContext Properties Edition Context}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.impl.ModelingBotImpl#getSequences Sequences}
  • - *
- *

- * - * @generated - */ -public class ModelingBotImpl extends EObjectImpl implements ModelingBot { - /** - * The cached value of the '{@link #getPropertiesEditionContext() Properties Edition Context}' reference. - * - * - * @see #getPropertiesEditionContext() - * @generated - * @ordered - */ - protected PropertiesEditionContext propertiesEditionContext; - - /** - * The cached value of the '{@link #getSequences() Sequences}' containment reference list. - * - * - * @see #getSequences() - * @generated - * @ordered - */ - protected EList sequences; - - /** - * - * - * @generated - */ - protected ModelingBotImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModelingBotPackage.Literals.MODELING_BOT; - } - - /** - * - * - * @generated - */ - public PropertiesEditionContext getPropertiesEditionContext() { - if (propertiesEditionContext != null && propertiesEditionContext.eIsProxy()) { - InternalEObject oldPropertiesEditionContext = (InternalEObject)propertiesEditionContext; - propertiesEditionContext = (PropertiesEditionContext)eResolveProxy(oldPropertiesEditionContext); - if (propertiesEditionContext != oldPropertiesEditionContext) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, ModelingBotPackage.MODELING_BOT__PROPERTIES_EDITION_CONTEXT, oldPropertiesEditionContext, propertiesEditionContext)); - } - } - return propertiesEditionContext; - } - - /** - * - * - * @generated - */ - public PropertiesEditionContext basicGetPropertiesEditionContext() { - return propertiesEditionContext; - } - - /** - * - * - * @generated - */ - public void setPropertiesEditionContext(PropertiesEditionContext newPropertiesEditionContext) { - PropertiesEditionContext oldPropertiesEditionContext = propertiesEditionContext; - propertiesEditionContext = newPropertiesEditionContext; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, ModelingBotPackage.MODELING_BOT__PROPERTIES_EDITION_CONTEXT, oldPropertiesEditionContext, propertiesEditionContext)); - } - - /** - * - * - * @generated - */ - public EList getSequences() { - if (sequences == null) { - sequences = new EObjectContainmentEList(Sequence.class, this, ModelingBotPackage.MODELING_BOT__SEQUENCES); - } - return sequences; - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ModelingBotPackage.MODELING_BOT__SEQUENCES: - return ((InternalEList)getSequences()).basicRemove(otherEnd, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ModelingBotPackage.MODELING_BOT__PROPERTIES_EDITION_CONTEXT: - if (resolve) return getPropertiesEditionContext(); - return basicGetPropertiesEditionContext(); - case ModelingBotPackage.MODELING_BOT__SEQUENCES: - return getSequences(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ModelingBotPackage.MODELING_BOT__PROPERTIES_EDITION_CONTEXT: - setPropertiesEditionContext((PropertiesEditionContext)newValue); - return; - case ModelingBotPackage.MODELING_BOT__SEQUENCES: - getSequences().clear(); - getSequences().addAll((Collection)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ModelingBotPackage.MODELING_BOT__PROPERTIES_EDITION_CONTEXT: - setPropertiesEditionContext((PropertiesEditionContext)null); - return; - case ModelingBotPackage.MODELING_BOT__SEQUENCES: - getSequences().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ModelingBotPackage.MODELING_BOT__PROPERTIES_EDITION_CONTEXT: - return propertiesEditionContext != null; - case ModelingBotPackage.MODELING_BOT__SEQUENCES: - return sequences != null && !sequences.isEmpty(); - } - return super.eIsSet(featureID); - } - -} //ModelingBotImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotPackageImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotPackageImpl.java deleted file mode 100755 index 2293ea67b..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ModelingBotPackageImpl.java +++ /dev/null @@ -1,516 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.impl; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EEnum; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.ecore.impl.EPackageImpl; - -import org.eclipse.emf.eef.components.ComponentsPackage; - -import org.eclipse.emf.eef.extended.editor.EditorPackage; - -import org.eclipse.emf.eef.extended.query.QueryPackage; - -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.DetailsPage; -import org.eclipse.emf.eef.modelingBot.DocumentedElement; - -import org.eclipse.emf.eef.modelingBot.EEFActions.EEFActionsPackage; - -import org.eclipse.emf.eef.modelingBot.EEFActions.impl.EEFActionsPackageImpl; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.EclipseActionsPackage; - -import org.eclipse.emf.eef.modelingBot.EclipseActions.impl.EclipseActionsPackageImpl; - -import org.eclipse.emf.eef.modelingBot.ModelingBot; -import org.eclipse.emf.eef.modelingBot.ModelingBotFactory; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.Processing; -import org.eclipse.emf.eef.modelingBot.PropertiesView; -import org.eclipse.emf.eef.modelingBot.Scenario; -import org.eclipse.emf.eef.modelingBot.Sequence; -import org.eclipse.emf.eef.modelingBot.SequenceType; -import org.eclipse.emf.eef.modelingBot.Wizard; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class ModelingBotPackageImpl extends EPackageImpl implements ModelingBotPackage { - /** - * - * - * @generated - */ - private EClass scenarioEClass = null; - - /** - * - * - * @generated - */ - private EClass actionEClass = null; - - /** - * - * - * @generated - */ - private EClass sequenceEClass = null; - - /** - * - * - * @generated - */ - private EClass wizardEClass = null; - - /** - * - * - * @generated - */ - private EClass documentedElementEClass = null; - - /** - * - * - * @generated - */ - private EClass modelingBotEClass = null; - - /** - * - * - * @generated - */ - private EClass detailsPageEClass = null; - - /** - * - * - * @generated - */ - private EClass propertiesViewEClass = null; - - /** - * - * - * @generated - */ - private EClass processingEClass = null; - - /** - * - * - * @generated - */ - private EEnum sequenceTypeEEnum = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage#eNS_URI - * @see #init() - * @generated - */ - private ModelingBotPackageImpl() { - super(eNS_URI, ModelingBotFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

This method is used to initialize {@link ModelingBotPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static ModelingBotPackage init() { - if (isInited) return (ModelingBotPackage)EPackage.Registry.INSTANCE.getEPackage(ModelingBotPackage.eNS_URI); - - // Obtain or create and register package - ModelingBotPackageImpl theModelingBotPackage = (ModelingBotPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof ModelingBotPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new ModelingBotPackageImpl()); - - isInited = true; - - // Initialize simple dependencies - EditorPackage.eINSTANCE.eClass(); - QueryPackage.eINSTANCE.eClass(); - - // Obtain or create and register interdependencies - EEFActionsPackageImpl theEEFActionsPackage = (EEFActionsPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(EEFActionsPackage.eNS_URI) instanceof EEFActionsPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(EEFActionsPackage.eNS_URI) : EEFActionsPackage.eINSTANCE); - EclipseActionsPackageImpl theEclipseActionsPackage = (EclipseActionsPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(EclipseActionsPackage.eNS_URI) instanceof EclipseActionsPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(EclipseActionsPackage.eNS_URI) : EclipseActionsPackage.eINSTANCE); - - // Create package meta-data objects - theModelingBotPackage.createPackageContents(); - theEEFActionsPackage.createPackageContents(); - theEclipseActionsPackage.createPackageContents(); - - // Initialize created meta-data - theModelingBotPackage.initializePackageContents(); - theEEFActionsPackage.initializePackageContents(); - theEclipseActionsPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theModelingBotPackage.freeze(); - - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(ModelingBotPackage.eNS_URI, theModelingBotPackage); - return theModelingBotPackage; - } - - /** - * - * - * @generated - */ - public EClass getScenario() { - return scenarioEClass; - } - - /** - * - * - * @generated - */ - public EClass getAction() { - return actionEClass; - } - - /** - * - * - * @generated - */ - public EClass getSequence() { - return sequenceEClass; - } - - /** - * - * - * @generated - */ - public EReference getSequence_Actions() { - return (EReference)sequenceEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getSequence_Sequences() { - return (EReference)sequenceEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EReference getSequence_Processings() { - return (EReference)sequenceEClass.getEStructuralFeatures().get(2); - } - - /** - * - * - * @generated - */ - public EClass getWizard() { - return wizardEClass; - } - - /** - * - * - * @generated - */ - public EReference getWizard_ReferenceableObject() { - return (EReference)wizardEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getDocumentedElement() { - return documentedElementEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getDocumentedElement_Name() { - return (EAttribute)documentedElementEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EAttribute getDocumentedElement_Documentation() { - return (EAttribute)documentedElementEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getModelingBot() { - return modelingBotEClass; - } - - /** - * - * - * @generated - */ - public EReference getModelingBot_PropertiesEditionContext() { - return (EReference)modelingBotEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getModelingBot_Sequences() { - return (EReference)modelingBotEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getDetailsPage() { - return detailsPageEClass; - } - - /** - * - * - * @generated - */ - public EClass getPropertiesView() { - return propertiesViewEClass; - } - - /** - * - * - * @generated - */ - public EAttribute getPropertiesView_Id() { - return (EAttribute)propertiesViewEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getProcessing() { - return processingEClass; - } - - /** - * - * - * @generated - */ - public EEnum getSequenceType() { - return sequenceTypeEEnum; - } - - /** - * - * - * @generated - */ - public ModelingBotFactory getModelingBotFactory() { - return (ModelingBotFactory)getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) return; - isCreated = true; - - // Create classes and their features - scenarioEClass = createEClass(SCENARIO); - - actionEClass = createEClass(ACTION); - - sequenceEClass = createEClass(SEQUENCE); - createEReference(sequenceEClass, SEQUENCE__ACTIONS); - createEReference(sequenceEClass, SEQUENCE__SEQUENCES); - createEReference(sequenceEClass, SEQUENCE__PROCESSINGS); - - wizardEClass = createEClass(WIZARD); - createEReference(wizardEClass, WIZARD__REFERENCEABLE_OBJECT); - - documentedElementEClass = createEClass(DOCUMENTED_ELEMENT); - createEAttribute(documentedElementEClass, DOCUMENTED_ELEMENT__NAME); - createEAttribute(documentedElementEClass, DOCUMENTED_ELEMENT__DOCUMENTATION); - - modelingBotEClass = createEClass(MODELING_BOT); - createEReference(modelingBotEClass, MODELING_BOT__PROPERTIES_EDITION_CONTEXT); - createEReference(modelingBotEClass, MODELING_BOT__SEQUENCES); - - detailsPageEClass = createEClass(DETAILS_PAGE); - - propertiesViewEClass = createEClass(PROPERTIES_VIEW); - createEAttribute(propertiesViewEClass, PROPERTIES_VIEW__ID); - - processingEClass = createEClass(PROCESSING); - - // Create enums - sequenceTypeEEnum = createEEnum(SEQUENCE_TYPE); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - EEFActionsPackage theEEFActionsPackage = (EEFActionsPackage)EPackage.Registry.INSTANCE.getEPackage(EEFActionsPackage.eNS_URI); - EclipseActionsPackage theEclipseActionsPackage = (EclipseActionsPackage)EPackage.Registry.INSTANCE.getEPackage(EclipseActionsPackage.eNS_URI); - EditorPackage theEditorPackage = (EditorPackage)EPackage.Registry.INSTANCE.getEPackage(EditorPackage.eNS_URI); - ComponentsPackage theComponentsPackage = (ComponentsPackage)EPackage.Registry.INSTANCE.getEPackage(ComponentsPackage.eNS_URI); - EcorePackage theEcorePackage = (EcorePackage)EPackage.Registry.INSTANCE.getEPackage(EcorePackage.eNS_URI); - - // Add subpackages - getESubpackages().add(theEEFActionsPackage); - getESubpackages().add(theEclipseActionsPackage); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - scenarioEClass.getESuperTypes().add(this.getSequence()); - actionEClass.getESuperTypes().add(this.getDocumentedElement()); - actionEClass.getESuperTypes().add(this.getProcessing()); - sequenceEClass.getESuperTypes().add(this.getDocumentedElement()); - sequenceEClass.getESuperTypes().add(this.getProcessing()); - wizardEClass.getESuperTypes().add(this.getSequence()); - detailsPageEClass.getESuperTypes().add(this.getSequence()); - propertiesViewEClass.getESuperTypes().add(this.getSequence()); - - // Initialize classes and features; add operations and parameters - initEClass(scenarioEClass, Scenario.class, "Scenario", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(actionEClass, Action.class, "Action", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(sequenceEClass, Sequence.class, "Sequence", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getSequence_Actions(), this.getAction(), null, "actions", null, 0, -1, Sequence.class, IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED); - initEReference(getSequence_Sequences(), this.getSequence(), null, "sequences", null, 0, -1, Sequence.class, IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED); - initEReference(getSequence_Processings(), this.getProcessing(), null, "processings", null, 0, -1, Sequence.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(wizardEClass, Wizard.class, "Wizard", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getWizard_ReferenceableObject(), theEditorPackage.getReferenceableObject(), null, "referenceableObject", null, 0, 1, Wizard.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(documentedElementEClass, DocumentedElement.class, "DocumentedElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getDocumentedElement_Name(), ecorePackage.getEString(), "name", null, 0, 1, DocumentedElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getDocumentedElement_Documentation(), ecorePackage.getEString(), "documentation", null, 0, 1, DocumentedElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(modelingBotEClass, ModelingBot.class, "ModelingBot", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getModelingBot_PropertiesEditionContext(), theComponentsPackage.getPropertiesEditionContext(), null, "propertiesEditionContext", null, 0, 1, ModelingBot.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getModelingBot_Sequences(), this.getSequence(), null, "sequences", null, 0, -1, ModelingBot.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(detailsPageEClass, DetailsPage.class, "DetailsPage", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(propertiesViewEClass, PropertiesView.class, "PropertiesView", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getPropertiesView_Id(), theEcorePackage.getEString(), "id", null, 0, 1, PropertiesView.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(processingEClass, Processing.class, "Processing", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - // Initialize enums and add enum literals - initEEnum(sequenceTypeEEnum, SequenceType.class, "SequenceType"); - addEEnumLiteral(sequenceTypeEEnum, SequenceType.DETAILS_PAGE); - addEEnumLiteral(sequenceTypeEEnum, SequenceType.WIZARD); - addEEnumLiteral(sequenceTypeEEnum, SequenceType.PROPERTIES_VIEW); - - // Create resource - createResource(eNS_URI); - } - -} //ModelingBotPackageImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/PropertiesViewImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/PropertiesViewImpl.java deleted file mode 100755 index 07ab9f850..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/PropertiesViewImpl.java +++ /dev/null @@ -1,170 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.impl; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.PropertiesView; - -/** - * - * An implementation of the model object 'Properties View'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.impl.PropertiesViewImpl#getId Id}
  • - *
- *

- * - * @generated - */ -public class PropertiesViewImpl extends SequenceImpl implements PropertiesView { - /** - * The default value of the '{@link #getId() Id}' attribute. - * - * - * @see #getId() - * @generated - * @ordered - */ - protected static final String ID_EDEFAULT = null; - - /** - * The cached value of the '{@link #getId() Id}' attribute. - * - * - * @see #getId() - * @generated - * @ordered - */ - protected String id = ID_EDEFAULT; - - /** - * - * - * @generated - */ - protected PropertiesViewImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModelingBotPackage.Literals.PROPERTIES_VIEW; - } - - /** - * - * - * @generated - */ - public String getId() { - return id; - } - - /** - * - * - * @generated - */ - public void setId(String newId) { - String oldId = id; - id = newId; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, ModelingBotPackage.PROPERTIES_VIEW__ID, oldId, id)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ModelingBotPackage.PROPERTIES_VIEW__ID: - return getId(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ModelingBotPackage.PROPERTIES_VIEW__ID: - setId((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ModelingBotPackage.PROPERTIES_VIEW__ID: - setId(ID_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ModelingBotPackage.PROPERTIES_VIEW__ID: - return ID_EDEFAULT == null ? id != null : !ID_EDEFAULT.equals(id); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (id: "); - result.append(id); - result.append(')'); - return result.toString(); - } - -} //PropertiesViewImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ScenarioImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ScenarioImpl.java deleted file mode 100755 index 630e841bb..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/ScenarioImpl.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.impl; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.Scenario; - -/** - * - * An implementation of the model object 'Scenario'. - * - *

- *

- * - * @generated - */ -public class ScenarioImpl extends SequenceImpl implements Scenario { - /** - * - * - * @generated - */ - protected ScenarioImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModelingBotPackage.Literals.SCENARIO; - } - -} //ScenarioImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/SequenceImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/SequenceImpl.java deleted file mode 100755 index 265428af4..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/SequenceImpl.java +++ /dev/null @@ -1,231 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.impl; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.NotificationChain; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.InternalEList; - -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.Processing; -import org.eclipse.emf.eef.modelingBot.Sequence; - -/** - * - * An implementation of the model object 'Sequence'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.impl.SequenceImpl#getActions Actions}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.impl.SequenceImpl#getSequences Sequences}
  • - *
  • {@link org.eclipse.emf.eef.modelingBot.impl.SequenceImpl#getProcessings Processings}
  • - *
- *

- * - * @generated - */ -public abstract class SequenceImpl extends DocumentedElementImpl implements Sequence { - /** - * The cached value of the '{@link #getActions() Actions}' containment reference list. - * - * - * @see #getActions() - * @generated - * @ordered - */ - protected EList actions; - - /** - * The cached value of the '{@link #getSequences() Sequences}' containment reference list. - * - * - * @see #getSequences() - * @generated - * @ordered - */ - protected EList sequences; - - /** - * The cached value of the '{@link #getProcessings() Processings}' containment reference list. - * - * - * @see #getProcessings() - * @generated - * @ordered - */ - protected EList processings; - - /** - * - * - * @generated - */ - protected SequenceImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModelingBotPackage.Literals.SEQUENCE; - } - - /** - * - * - * @generated - */ - public EList getActions() { - if (actions == null) { - actions = new EObjectContainmentEList(Action.class, this, ModelingBotPackage.SEQUENCE__ACTIONS); - } - return actions; - } - - /** - * - * - * @generated - */ - public EList getSequences() { - if (sequences == null) { - sequences = new EObjectContainmentEList(Sequence.class, this, ModelingBotPackage.SEQUENCE__SEQUENCES); - } - return sequences; - } - - /** - * - * - * @generated - */ - public EList getProcessings() { - if (processings == null) { - processings = new EObjectContainmentEList(Processing.class, this, ModelingBotPackage.SEQUENCE__PROCESSINGS); - } - return processings; - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case ModelingBotPackage.SEQUENCE__ACTIONS: - return ((InternalEList)getActions()).basicRemove(otherEnd, msgs); - case ModelingBotPackage.SEQUENCE__SEQUENCES: - return ((InternalEList)getSequences()).basicRemove(otherEnd, msgs); - case ModelingBotPackage.SEQUENCE__PROCESSINGS: - return ((InternalEList)getProcessings()).basicRemove(otherEnd, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ModelingBotPackage.SEQUENCE__ACTIONS: - return getActions(); - case ModelingBotPackage.SEQUENCE__SEQUENCES: - return getSequences(); - case ModelingBotPackage.SEQUENCE__PROCESSINGS: - return getProcessings(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ModelingBotPackage.SEQUENCE__ACTIONS: - getActions().clear(); - getActions().addAll((Collection)newValue); - return; - case ModelingBotPackage.SEQUENCE__SEQUENCES: - getSequences().clear(); - getSequences().addAll((Collection)newValue); - return; - case ModelingBotPackage.SEQUENCE__PROCESSINGS: - getProcessings().clear(); - getProcessings().addAll((Collection)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ModelingBotPackage.SEQUENCE__ACTIONS: - getActions().clear(); - return; - case ModelingBotPackage.SEQUENCE__SEQUENCES: - getSequences().clear(); - return; - case ModelingBotPackage.SEQUENCE__PROCESSINGS: - getProcessings().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ModelingBotPackage.SEQUENCE__ACTIONS: - return actions != null && !actions.isEmpty(); - case ModelingBotPackage.SEQUENCE__SEQUENCES: - return sequences != null && !sequences.isEmpty(); - case ModelingBotPackage.SEQUENCE__PROCESSINGS: - return processings != null && !processings.isEmpty(); - } - return super.eIsSet(featureID); - } - -} //SequenceImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/WizardImpl.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/WizardImpl.java deleted file mode 100755 index ecb3ac585..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/impl/WizardImpl.java +++ /dev/null @@ -1,162 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.impl; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.ModelingBotPackage; -import org.eclipse.emf.eef.modelingBot.Wizard; - -/** - * - * An implementation of the model object 'Wizard'. - * - *

- * The following features are implemented: - *

    - *
  • {@link org.eclipse.emf.eef.modelingBot.impl.WizardImpl#getReferenceableObject Referenceable Object}
  • - *
- *

- * - * @generated - */ -public class WizardImpl extends SequenceImpl implements Wizard { - /** - * The cached value of the '{@link #getReferenceableObject() Referenceable Object}' reference. - * - * - * @see #getReferenceableObject() - * @generated - * @ordered - */ - protected ReferenceableObject referenceableObject; - - /** - * - * - * @generated - */ - protected WizardImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModelingBotPackage.Literals.WIZARD; - } - - /** - * - * - * @generated - */ - public ReferenceableObject getReferenceableObject() { - if (referenceableObject != null && referenceableObject.eIsProxy()) { - InternalEObject oldReferenceableObject = (InternalEObject)referenceableObject; - referenceableObject = (ReferenceableObject)eResolveProxy(oldReferenceableObject); - if (referenceableObject != oldReferenceableObject) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, ModelingBotPackage.WIZARD__REFERENCEABLE_OBJECT, oldReferenceableObject, referenceableObject)); - } - } - return referenceableObject; - } - - /** - * - * - * @generated - */ - public ReferenceableObject basicGetReferenceableObject() { - return referenceableObject; - } - - /** - * - * - * @generated - */ - public void setReferenceableObject(ReferenceableObject newReferenceableObject) { - ReferenceableObject oldReferenceableObject = referenceableObject; - referenceableObject = newReferenceableObject; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, ModelingBotPackage.WIZARD__REFERENCEABLE_OBJECT, oldReferenceableObject, referenceableObject)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case ModelingBotPackage.WIZARD__REFERENCEABLE_OBJECT: - if (resolve) return getReferenceableObject(); - return basicGetReferenceableObject(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case ModelingBotPackage.WIZARD__REFERENCEABLE_OBJECT: - setReferenceableObject((ReferenceableObject)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case ModelingBotPackage.WIZARD__REFERENCEABLE_OBJECT: - setReferenceableObject((ReferenceableObject)null); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case ModelingBotPackage.WIZARD__REFERENCEABLE_OBJECT: - return referenceableObject != null; - } - return super.eIsSet(featureID); - } - -} //WizardImpl diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/util/ModelingBotAdapterFactory.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/util/ModelingBotAdapterFactory.java deleted file mode 100755 index 372270116..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/util/ModelingBotAdapterFactory.java +++ /dev/null @@ -1,272 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.util; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; - -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; - -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.modelingBot.*; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage - * @generated - */ -public class ModelingBotAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static ModelingBotPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public ModelingBotAdapterFactory() { - if (modelPackage == null) { - modelPackage = ModelingBotPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject)object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected ModelingBotSwitch modelSwitch = - new ModelingBotSwitch() { - @Override - public Adapter caseScenario(Scenario object) { - return createScenarioAdapter(); - } - @Override - public Adapter caseAction(Action object) { - return createActionAdapter(); - } - @Override - public Adapter caseSequence(Sequence object) { - return createSequenceAdapter(); - } - @Override - public Adapter caseWizard(Wizard object) { - return createWizardAdapter(); - } - @Override - public Adapter caseDocumentedElement(DocumentedElement object) { - return createDocumentedElementAdapter(); - } - @Override - public Adapter caseModelingBot(ModelingBot object) { - return createModelingBotAdapter(); - } - @Override - public Adapter caseDetailsPage(DetailsPage object) { - return createDetailsPageAdapter(); - } - @Override - public Adapter casePropertiesView(PropertiesView object) { - return createPropertiesViewAdapter(); - } - @Override - public Adapter caseProcessing(Processing object) { - return createProcessingAdapter(); - } - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject)target); - } - - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.Scenario Scenario}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.Scenario - * @generated - */ - public Adapter createScenarioAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.Action Action}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.Action - * @generated - */ - public Adapter createActionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.Sequence Sequence}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.Sequence - * @generated - */ - public Adapter createSequenceAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.Wizard Wizard}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.Wizard - * @generated - */ - public Adapter createWizardAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.DocumentedElement Documented Element}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.DocumentedElement - * @generated - */ - public Adapter createDocumentedElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.ModelingBot Modeling Bot}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.ModelingBot - * @generated - */ - public Adapter createModelingBotAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.DetailsPage Details Page}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.DetailsPage - * @generated - */ - public Adapter createDetailsPageAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.PropertiesView Properties View}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.PropertiesView - * @generated - */ - public Adapter createPropertiesViewAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.eef.modelingBot.Processing Processing}'. - * - * 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. - * - * @return the new adapter. - * @see org.eclipse.emf.eef.modelingBot.Processing - * @generated - */ - public Adapter createProcessingAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //ModelingBotAdapterFactory diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/util/ModelingBotSwitch.java b/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/util/ModelingBotSwitch.java deleted file mode 100755 index 25bf2ce9b..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src-gen/org/eclipse/emf/eef/modelingBot/util/ModelingBotSwitch.java +++ /dev/null @@ -1,318 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.util; - -import java.util.List; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; - -import org.eclipse.emf.eef.modelingBot.*; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see org.eclipse.emf.eef.modelingBot.ModelingBotPackage - * @generated - */ -public class ModelingBotSwitch { - /** - * The cached model package - * - * - * @generated - */ - protected static ModelingBotPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public ModelingBotSwitch() { - if (modelPackage == null) { - modelPackage = ModelingBotPackage.eINSTANCE; - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - public T doSwitch(EObject theEObject) { - return doSwitch(theEObject.eClass(), theEObject); - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(EClass theEClass, EObject theEObject) { - if (theEClass.eContainer() == modelPackage) { - return doSwitch(theEClass.getClassifierID(), theEObject); - } - else { - List eSuperTypes = theEClass.getESuperTypes(); - return - eSuperTypes.isEmpty() ? - defaultCase(theEObject) : - doSwitch(eSuperTypes.get(0), theEObject); - } - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case ModelingBotPackage.SCENARIO: { - Scenario scenario = (Scenario)theEObject; - T result = caseScenario(scenario); - if (result == null) result = caseSequence(scenario); - if (result == null) result = caseDocumentedElement(scenario); - if (result == null) result = caseProcessing(scenario); - if (result == null) result = defaultCase(theEObject); - return result; - } - case ModelingBotPackage.ACTION: { - Action action = (Action)theEObject; - T result = caseAction(action); - if (result == null) result = caseDocumentedElement(action); - if (result == null) result = caseProcessing(action); - if (result == null) result = defaultCase(theEObject); - return result; - } - case ModelingBotPackage.SEQUENCE: { - Sequence sequence = (Sequence)theEObject; - T result = caseSequence(sequence); - if (result == null) result = caseDocumentedElement(sequence); - if (result == null) result = caseProcessing(sequence); - if (result == null) result = defaultCase(theEObject); - return result; - } - case ModelingBotPackage.WIZARD: { - Wizard wizard = (Wizard)theEObject; - T result = caseWizard(wizard); - if (result == null) result = caseSequence(wizard); - if (result == null) result = caseDocumentedElement(wizard); - if (result == null) result = caseProcessing(wizard); - if (result == null) result = defaultCase(theEObject); - return result; - } - case ModelingBotPackage.DOCUMENTED_ELEMENT: { - DocumentedElement documentedElement = (DocumentedElement)theEObject; - T result = caseDocumentedElement(documentedElement); - if (result == null) result = defaultCase(theEObject); - return result; - } - case ModelingBotPackage.MODELING_BOT: { - ModelingBot modelingBot = (ModelingBot)theEObject; - T result = caseModelingBot(modelingBot); - if (result == null) result = defaultCase(theEObject); - return result; - } - case ModelingBotPackage.DETAILS_PAGE: { - DetailsPage detailsPage = (DetailsPage)theEObject; - T result = caseDetailsPage(detailsPage); - if (result == null) result = caseSequence(detailsPage); - if (result == null) result = caseDocumentedElement(detailsPage); - if (result == null) result = caseProcessing(detailsPage); - if (result == null) result = defaultCase(theEObject); - return result; - } - case ModelingBotPackage.PROPERTIES_VIEW: { - PropertiesView propertiesView = (PropertiesView)theEObject; - T result = casePropertiesView(propertiesView); - if (result == null) result = caseSequence(propertiesView); - if (result == null) result = caseDocumentedElement(propertiesView); - if (result == null) result = caseProcessing(propertiesView); - if (result == null) result = defaultCase(theEObject); - return result; - } - case ModelingBotPackage.PROCESSING: { - Processing processing = (Processing)theEObject; - T result = caseProcessing(processing); - if (result == null) result = defaultCase(theEObject); - return result; - } - default: return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'Scenario'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Scenario'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseScenario(Scenario object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Action'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Action'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseAction(Action object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Sequence'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Sequence'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseSequence(Sequence object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Wizard'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Wizard'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseWizard(Wizard object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Documented Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Documented Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDocumentedElement(DocumentedElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Modeling Bot'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Modeling Bot'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseModelingBot(ModelingBot object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Details Page'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Details Page'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseDetailsPage(DetailsPage object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Properties View'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Properties View'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T casePropertiesView(PropertiesView object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Processing'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Processing'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseProcessing(Processing object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - public T defaultCase(EObject object) { - return null; - } - -} //ModelingBotSwitch diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/IModelingBot.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/IModelingBot.java deleted file mode 100755 index ea03b35f9..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/IModelingBot.java +++ /dev/null @@ -1,254 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot; - -import java.io.IOException; -import java.util.Collection; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter; - -/** - * Interface for modeling bot : define the actions modelised in modeling bot resource. - * - * @author Nathalie Lepine - */ -public interface IModelingBot { - - /** - * Run the scenarios of the modeling bot. - * - * @param path - * the path - * @throws CoreException - * @throws IOException - */ - void runModelingBot(String path) throws CoreException, IOException; - - /** - * Create a new java project. - * - * @param projectName - */ - void createProject(String projectName); - - /** - * Open a project. - * - * @param projectName - */ - void openProject(String projectName); - - /** - * Close a project. - * - * @param projectName - */ - void closeProject(String projectName); - - /** - * Remove a project. - * - * @param projectName - */ - void removeProject(String projectName); - - /** - * Open a perspective. - * - * @param name - */ - void openPerspective(String name); - - /** - * Open an editor with EEF Reflexive editor. - * - * @param path - * editor path from its project - */ - void openEEFEditor(String path); - - /** - * Open an editor. - * - * @param path - * editor path from its project. - * @return: {@link EObject} - */ - EObject openEditor(String path); - - /** - * Close an editor. - * - * @param path - * editor path from its project - */ - void closeEditor(String path); - - /** - * Save an editor. - */ - void save(); - - /** - * Add an element. - * - * @param propertiesEditionElement - * @param referenceableObject - * @param eContainingFeature - * @return - */ - EObject add(org.eclipse.emf.eef.components.PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObjectContainer, ReferenceableObject referenceableObject, - EStructuralFeature eContainingFeature, EClass type); - - /** - * Remove an element. - * - * @param propertiesEditionElement - * @param referenceableObject - * @param eContainingFeature - */ - void remove(PropertiesEditionElement propertiesEditionElement, ReferenceableObject referenceableObject); - - /** - * moves up an element. - * - * @param propertiesEditionElement - * @param referenceableObject - */ - void moveUp(PropertiesEditionElement propertiesEditionElement, ReferenceableObject referenceableObject); - - - /** - * moves down an element. - * - * @param propertiesEditionElement - * @param referenceableObject - */ - void moveDown(PropertiesEditionElement propertiesEditionElement, ReferenceableObject referenceableObject); - - /** - * Set an attribute. - * - * @param propertiesEditionElement - * @param referenceableObject - * @param eContainingFeature - * @param values - */ - void setAttribute(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values); - - /** - * Set a reference. - * - * @param propertiesEditionElement - * @param referenceableObject - * @param eContainingFeature - */ - void setReference(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values); - - /** - * Unset all the values of an attribute or a reference. - * - * @param propertiesEditionElement - * @param referenceableObject - * @param eContainingFeature - */ - void unset(PropertiesEditionElement propertiesEditionElement, ReferenceableObject referenceableObject, - EStructuralFeature eContainingFeature); - - /** - * Unset a reference. - * - * @param propertiesEditionElement - * @param referenceableObject - * @param eContainingFeature - */ - void unsetAttribute(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values); - - /** - * Unset a reference. - * - * @param propertiesEditionElement - * @param referenceableObject - * @param eContainingFeature - */ - void unsetReference(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values); - - /** - * Create a new resource. - * - * @param modelName - * @return - */ - EObject createModel(String path, String modelName, EClass eClass); - - /** - * Cancel. - */ - void cancel(Processing processing); - - /** - * Set the sequence type : wizard, details page, properties view... - * - * @param sequenceType - */ - void setSequenceType(SequenceType sequenceType); - - /** - * Validate batch editing. - */ - void validateBatchEditing(); - - /** - * Check. - */ - void check(); - - /** - * Undo. - */ - void undo(Action action); - - /** - * Redo. - */ - void redo(Action action); - - /** - * @return the test model resource. - */ - Resource getActiveResource(); - - /** - * @return the modeling bot interpreter - */ - IModelingBotInterpreter getModelingBotInterpreter(); - - void initWizard(Wizard wizard); - - void closeWizard(Wizard wizard); - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/batch/BatchModelingBot.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/batch/BatchModelingBot.java deleted file mode 100755 index c36a27501..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/batch/BatchModelingBot.java +++ /dev/null @@ -1,557 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.batch; - -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertTrue; -import static org.junit.Assert.fail; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collection; -import java.util.HashSet; -import java.util.Iterator; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.command.AddCommand; -import org.eclipse.emf.edit.command.RemoveCommand; -import org.eclipse.emf.edit.command.SetCommand; -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.IModelingBot; -import org.eclipse.emf.eef.modelingBot.Processing; -import org.eclipse.emf.eef.modelingBot.SequenceType; -import org.eclipse.emf.eef.modelingBot.Wizard; -import org.eclipse.emf.eef.modelingBot.helper.EEFModelingBotHelper; -import org.eclipse.emf.eef.modelingBot.helper.EMFHelper; -import org.eclipse.emf.eef.modelingBot.interpreter.EEFInterpreter; -import org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter; - -/** - * @author Goulwen Le Fur - */ -public class BatchModelingBot implements IModelingBot { - - private EditingDomain editingDomain; - - private AdapterFactory adapterFactory; - - private Resource activeResource; - - private EEFInterpreter interpreter; - - private Collection resources; - - /** - * Constructor. - */ - public BatchModelingBot() { - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - editingDomain = new AdapterFactoryEditingDomain(adapterFactory, new BasicCommandStack()); - interpreter = new EEFInterpreter(this, editingDomain); - resources = new HashSet(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#runModelingBot(java.lang.String) - */ - public void runModelingBot(String path) throws CoreException, IOException { - interpreter.runModelingBot(path); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#createProject(java.lang.String) - */ - public void createProject(String projectName) { - // try { - // IProject project = - // ResourcesPlugin.getWorkspace().getRoot().getProject(projectName); - // project.create(new NullProgressMonitor()); - // } catch (CoreException e) { - // e.printStackTrace(); - // } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#openProject(java.lang.String) - */ - public void openProject(String projectName) { - // try { - // IProject project = - // ResourcesPlugin.getWorkspace().getRoot().getProject(projectName); - // project.open(monitor); - // } catch (CoreException e) { - // e.printStackTrace(); - // } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#closeProject(java.lang.String) - */ - public void closeProject(String projectName) { - // try { - // IProject project = - // ResourcesPlugin.getWorkspace().getRoot().getProject(projectName); - // project.open(monitor); - // } catch (CoreException e) { - // e.printStackTrace(); - // } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#removeProject(java.lang.String) - */ - public void removeProject(String projectName) { - // try { - // IProject project = - // ResourcesPlugin.getWorkspace().getRoot().getProject(projectName); - // project.delete(true, monitor); - // } catch (CoreException e) { - // e.printStackTrace(); - // } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#openPerspective(java.lang.String) - */ - public void openPerspective(String name) { - // Nothing to do - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#openEEFEditor(java.lang.String) - */ - public void openEEFEditor(String path) { - final URI uri = URI.createPlatformResourceURI(path, true); - final Resource activeResource = editingDomain.getResourceSet().getResource(uri, true); - if (activeResource == null) { - for (Resource resource : resources) { - if (uri.equals(resource.getURI())) { - this.activeResource = resource; - editingDomain.getResourceSet().getResources().add(resource); - } - } - } else { - this.activeResource = activeResource; - } - } - - public EObject openEditor(String path) { - final URI uri = URI.createPlatformResourceURI(path, true); - final Resource activeResource = editingDomain.getResourceSet().getResource(uri, true); - if (activeResource == null) { - for (Resource resource : resources) { - if (uri.equals(resource.getURI())) { - this.activeResource = resource; - editingDomain.getResourceSet().getResources().add(resource); - } - } - } else { - this.activeResource = activeResource; - } - Collection contents = this.activeResource.getContents(); - Iterator it = contents.iterator(); - assertTrue("Can't find the active resource in order to simulate the editor openning in batch mode.", it.hasNext()); - return it.next(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#closeEditor(java.lang.String) - */ - public void closeEditor(String path) { - activeResource.unload(); - if (!resources.contains(activeResource)) { - resources.add(activeResource); - } - activeResource = null; - editingDomain.getResourceSet().getResources().remove(activeResource); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#save() - */ - public void save() { - if (!resources.contains(activeResource)) { - resources.add(activeResource); - } - // if (activeResource != null) { - // try { - // activeResource.save(Collections.EMPTY_MAP); - // } catch (IOException e) { - // e.printStackTrace(); - // } - // } else { - // //TODO: Error - // } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#add(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * org.eclipse.emf.ecore.EClass) - */ - public EObject add(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, EClass type) { - final EObject eObjectFromReferenceableEObject = interpreter - .getEObjectFromReferenceableEObject(referenceableObject); - assertNotNull("the eObjectFromReferenceableEObject is null", eObjectFromReferenceableEObject); - activeResource = eObjectFromReferenceableEObject.eResource(); - EClass mappedType = EMFHelper.map(EMFHelper.findInRegistry(type.getEPackage()), type); - EStructuralFeature mappedContainingFeature = EMFHelper.map( - EMFHelper.findInRegistry(type.getEPackage()), eContainingFeature); - final EObject value = EcoreUtil.create(mappedType); - final Command command = AddCommand.create(editingDomain, eObjectFromReferenceableEObject, - mappedContainingFeature, value); - assertNotNull("The command is null", command); - editingDomain.getCommandStack().execute(command); - return value; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#remove(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject) - */ - public void remove(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject) { - final EObject eObjectFromReferenceableEObject = interpreter - .getEObjectFromReferenceableEObject(referenceableObject); - activeResource = eObjectFromReferenceableEObject.eResource(); - EcoreUtil.remove(eObjectFromReferenceableEObject); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#setAttribute(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * java.lang.String) - */ - @SuppressWarnings("unchecked") - public void setAttribute(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - final EObject eObjectFromReferenceableEObject = interpreter - .getEObjectFromReferenceableEObject(referenceableObject); - EStructuralFeature mappedFeature = EMFHelper.map( - EMFHelper.findInRegistry(((EClass)eContainingFeature.eContainer()).getEPackage()), - eContainingFeature); - if (mappedFeature instanceof EAttribute) { - activeResource = eObjectFromReferenceableEObject.eResource(); - Object createFromString = null; - if (eContainingFeature.isMany()) { - createFromString = new ArrayList(); - for (String value : values) { - ((ArrayList)createFromString).add(EcoreUtil.createFromString( - ((EAttribute)mappedFeature).getEAttributeType(), value)); - } - } else { - createFromString = EcoreUtil.createFromString( - ((EAttribute)mappedFeature).getEAttributeType(), values.iterator().next()); - } - final Command command = SetCommand.create(editingDomain, eObjectFromReferenceableEObject, - mappedFeature, createFromString); - assertNotNull("The command is null", command); - editingDomain.getCommandStack().execute(command); - } else { - fail("Cannot set without a eContainingFeature attribute"); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#set(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject) - */ - @SuppressWarnings("unchecked") - public void setReference(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - final EObject eObjectFromReferenceableEObject = interpreter - .getEObjectFromReferenceableEObject(referenceableObject); - EStructuralFeature mappedFeature = EMFHelper.map( - EMFHelper.findInRegistry(((EClass)eContainingFeature.eContainer()).getEPackage()), - eContainingFeature); - if (mappedFeature instanceof EReference) { - activeResource = eObjectFromReferenceableEObject.eResource(); - Object refValue = null; - if (eContainingFeature.isMany()) { - refValue = new ArrayList(); - for (ReferenceableObject ref : values) { - ((ArrayList)refValue).add(interpreter.getEObjectFromReferenceableEObject(ref)); - } - } else { - refValue = interpreter.getEObjectFromReferenceableEObject(values.iterator().next()); - } - final Command command = SetCommand.create(editingDomain, eObjectFromReferenceableEObject, - mappedFeature, refValue); - assertNotNull("The command is null", command); - editingDomain.getCommandStack().execute(command); - } else { - fail("Cannot set without a eContainingFeature reference"); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#unset(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature) - */ - public void unset(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature) { - final EObject eObjectFromReferenceableEObject = interpreter - .getEObjectFromReferenceableEObject(referenceableObject); - EStructuralFeature mappedFeature = EMFHelper.map( - EMFHelper.findInRegistry(((EClass)eContainingFeature.eContainer()).getEPackage()), - eContainingFeature); - activeResource = eObjectFromReferenceableEObject.eResource(); - if (mappedFeature instanceof EStructuralFeature) { - if (mappedFeature.isMany()) { - Collection valuesToRemove = RemoveCommand.getOwnerList( - eObjectFromReferenceableEObject, mappedFeature); - final Command command = RemoveCommand.create(editingDomain, eObjectFromReferenceableEObject, - mappedFeature, valuesToRemove); - assertNotNull("The command is null", command); - editingDomain.getCommandStack().execute(command); - } else { - final Command command = SetCommand.create(editingDomain, eObjectFromReferenceableEObject, - mappedFeature, null); - assertNotNull("The command is null", command); - editingDomain.getCommandStack().execute(command); - } - } else { - fail("Cannot unset without a eContainingFeature attribute/reference"); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#createModel(java.lang.String, java.lang.String, - * org.eclipse.emf.ecore.EClass) - */ - public EObject createModel(String path, String modelName, EClass eClass) { - // try { - final URI uri = URI.createPlatformResourceURI(path + "/" + modelName, true); - final Resource activeResource = editingDomain.getResourceSet().createResource(uri); - EClass mappedType = EMFHelper.map(EMFHelper.findInRegistry(eClass.getEPackage()), eClass); - final EObject create = EcoreUtil.create(mappedType); - activeResource.getContents().add(create); - // activeResource.save(Collections.EMPTY_MAP); - this.activeResource = activeResource; - resources.add(activeResource); - return create; - // } catch (IOException e) { - // e.printStackTrace(); - // } - // return null; - } - - public void cancel(Processing processing) { - if (processing instanceof Wizard) { - int numberOfActionsToCancel = EEFModelingBotHelper.getNumberOfActionToCancel(processing); - for (int i = 0; i < numberOfActionsToCancel; i++) { - editingDomain.getCommandStack().undo(); - } - } else { - editingDomain.getCommandStack().undo(); - } - } - - public void setSequenceType(SequenceType detailsPage) { - - } - - public void validateBatchEditing() { - - } - - public void check() { - - } - - public Resource getActiveResource() { - return activeResource; - } - - public IModelingBotInterpreter getModelingBotInterpreter() { - return interpreter; - } - - public EObject add(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObjectContainer, ReferenceableObject referenceableObject, - EStructuralFeature eContainingFeature, EClass type) { - if (referenceableObjectContainer == null) { - return add(propertiesEditionElement, referenceableObject, eContainingFeature, type); - } - final EObject container = interpreter - .getEObjectFromReferenceableEObject(referenceableObjectContainer); - assertNotNull("No container is found.", container); - activeResource = container.eResource(); - EClass mappedType = EMFHelper.map(EMFHelper.findInRegistry(type.getEPackage()), type); - EStructuralFeature mappedContainingFeature = EMFHelper.map( - EMFHelper.findInRegistry(type.getEPackage()), eContainingFeature); - final EObject value = EcoreUtil.create(mappedType); - final Command command = AddCommand.create(editingDomain, container, mappedContainingFeature, value); - assertNotNull("The command is null", command); - editingDomain.getCommandStack().execute(command); - return value; - } - - public void unsetAttribute(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - final EObject eObjectFromReferenceableEObject = interpreter - .getEObjectFromReferenceableEObject(referenceableObject); - EStructuralFeature mappedFeature = EMFHelper.map( - EMFHelper.findInRegistry(((EClass)eContainingFeature.eContainer()).getEPackage()), - eContainingFeature); - if (mappedFeature instanceof EAttribute) { - activeResource = eObjectFromReferenceableEObject.eResource(); - if (mappedFeature.isMany()) { - final Command command = RemoveCommand.create(editingDomain, eObjectFromReferenceableEObject, - mappedFeature, values); - assertNotNull("The command is null", command); - editingDomain.getCommandStack().execute(command); - } else { - final Command command = SetCommand.create(editingDomain, eObjectFromReferenceableEObject, - mappedFeature, null); - assertNotNull("The command is null", command); - editingDomain.getCommandStack().execute(command); - } - } else { - fail("Cannot unset without a eContainingFeature attribute"); - } - - } - - public void unsetReference(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - final EObject eObjectFromReferenceableEObject = interpreter - .getEObjectFromReferenceableEObject(referenceableObject); - EStructuralFeature mappedFeature = EMFHelper.map( - EMFHelper.findInRegistry(((EClass)eContainingFeature.eContainer()).getEPackage()), - eContainingFeature); - if (mappedFeature instanceof EReference) { - activeResource = eObjectFromReferenceableEObject.eResource(); - if (mappedFeature.isMany()) { - Collection valuesToUnset = new ArrayList(); - for (ReferenceableObject value : values) { - valuesToUnset.add(interpreter.getEObjectFromReferenceableEObject(value)); - } - final Command command = RemoveCommand.create(editingDomain, eObjectFromReferenceableEObject, - mappedFeature, valuesToUnset); - assertNotNull("The command is null", command); - editingDomain.getCommandStack().execute(command); - } else { - final Command command = SetCommand.create(editingDomain, eObjectFromReferenceableEObject, - mappedFeature, null); - assertNotNull("The command is null", command); - editingDomain.getCommandStack().execute(command); - } - } else { - fail("Cannot unset without a eContainingFeature reference"); - } - - } - - public void undo(Action action) { - Processing precedingEditActionOrSequence = EEFModelingBotHelper - .getPrecedingEditActionOrSequence(action); - if (EEFModelingBotHelper.isWizard(precedingEditActionOrSequence)) { - int numberOfActionToUndo = EEFModelingBotHelper - .getNumberOfActionToUndo(precedingEditActionOrSequence); - for (int i = 0; i < numberOfActionToUndo; i++) { - editingDomain.getCommandStack().undo(); - } - } else { - editingDomain.getCommandStack().undo(); - } - - } - - public void redo(Action action) { - Processing precedingEditActionOrSequence = EEFModelingBotHelper - .getPrecedingEditActionOrSequence(action); - if (EEFModelingBotHelper.isWizard(precedingEditActionOrSequence)) { - int numberOfActionToRedo = EEFModelingBotHelper - .getNumberOfActionToUndo(precedingEditActionOrSequence); - for (int i = 0; i < numberOfActionToRedo; i++) { - editingDomain.getCommandStack().redo(); - } - } else { - editingDomain.getCommandStack().redo(); - } - - } - - - public void initWizard(Wizard wizard) { - // do nothing - } - - public void closeWizard(Wizard wizard) { - // do nothing - } - - public void moveUp(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject) { - // do nothing - } - - public void moveDown(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject) { - // do nothing - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/exception/InputModelInvalidException.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/exception/InputModelInvalidException.java deleted file mode 100755 index d0720b02e..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/exception/InputModelInvalidException.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.exception; - -/** - * @author Goulwen Le Fur - */ -public class InputModelInvalidException extends Exception { - - /** - * Serialization. - */ - private static final long serialVersionUID = 5938605662196039272L; - - private String messageInfo; - - /** - * default constructor. - */ - public InputModelInvalidException() { - super(); - } - - /** - * constructor with info. - * - * @param info - * the info - */ - public InputModelInvalidException(String info) { - super(); - this.messageInfo = "The input model doesn't contain enough instance of " + info + " EClass"; - } - - /** - * {@inheritDoc} - * - * @see java.lang.Throwable#getMessage() - */ - @Override - public String getMessage() { - final String message = "The input model is invalid for test"; - if (messageInfo != null) { - final StringBuilder builder = new StringBuilder(message); - builder.append(" : "); - builder.append(messageInfo); - return builder.toString(); - } - return message; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/exception/WidgetInvalidException.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/exception/WidgetInvalidException.java deleted file mode 100755 index c5f43c53b..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/exception/WidgetInvalidException.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.exception; - -/** - * @author Nathalie Lepine - */ -public class WidgetInvalidException extends Exception { - - /** - * Serialization. - */ - private static final long serialVersionUID = 5938605662196039272L; - - private String messageInfo; - - /** - * default constructor. - */ - public WidgetInvalidException() { - super(); - } - - /** - * constructor with info. - * - * @param info - * the info - */ - public WidgetInvalidException(String info) { - super(); - this.messageInfo = "The widget doesn't contain elements " + info; - } - - /** - * {@inheritDoc} - * - * @see java.lang.Throwable#getMessage() - */ - @Override - public String getMessage() { - final String message = "The widget is invalid for test"; - if (messageInfo != null) { - final StringBuilder builder = new StringBuilder(message); - builder.append(" : "); - builder.append(messageInfo); - return builder.toString(); - } - return message; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EEFModelHelper.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EEFModelHelper.java deleted file mode 100755 index 500e835d7..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EEFModelHelper.java +++ /dev/null @@ -1,96 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.modelingBot.helper; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.View; - -public class EEFModelHelper { - - /** - * Get the object from the feature. - * - * @param container - * @param eContainingFeature - * @return the object from the feature. - */ - public static Object eGet(EObject container, EStructuralFeature eContainingFeature) { - final Object eGet = container.eGet(container.eClass().getEStructuralFeature(eContainingFeature.getName())); - if (eGet instanceof EList) { - if (!((EList) eGet).isEmpty()) { - return (EObject) ((EList) eGet).get(((EList) eGet).size() - 1); - } else { - return null; - } - - } - return (EObject) eGet; - } - - /** - * @param modelElement - * the element to process - * @return a list containing the element to expand - */ - public static List getExpansionPath(EObject modelElement) { - final List result = new ArrayList(); - result.add(modelElement); - EObject container = modelElement.eContainer(); - while (container != null) { - result.add(0, container); - container = container.eContainer(); - } - return result; - } - - /** - * @param obj - * @return the view corresponding to the ElementEditor. - */ - public static View getView(ElementEditor obj) { - EObject container = obj.eContainer(); - while (container != null) { - if (container instanceof View) { - - return (View) container; - } - container = container.eContainer(); - } - return null; - } - - /** - * @param editingElement - * @return the {@link PropertiesEditionComponent} containing the given - * editingElement - */ - public static PropertiesEditionComponent getComponent(PropertiesEditionElement editingElement) { - EObject container = editingElement.eContainer(); - while (container != null) { - if (container instanceof PropertiesEditionComponent) { - - return (PropertiesEditionComponent) container; - } - container = container.eContainer(); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EEFModelingBotHelper.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EEFModelingBotHelper.java deleted file mode 100644 index e028f361c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EEFModelingBotHelper.java +++ /dev/null @@ -1,93 +0,0 @@ -package org.eclipse.emf.eef.modelingBot.helper; - -import java.util.Collection; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.Processing; -import org.eclipse.emf.eef.modelingBot.Sequence; -import org.eclipse.emf.eef.modelingBot.Wizard; -import org.eclipse.emf.eef.modelingBot.EEFActions.Cancel; -import org.eclipse.emf.eef.modelingBot.EEFActions.EditAction; - -public class EEFModelingBotHelper { - - - public static boolean isFollowingByCancel(Action action) { - Collection followingSiblings = EMFHelper.followingSiblings(action); - if (followingSiblings != null && !followingSiblings.isEmpty()) { - EObject next = followingSiblings.iterator().next(); - if (next instanceof Cancel) { - return true; - } - } - return false; - - } - - public static Cancel getFollowingCancelAction(Action action) { - Collection followingSiblings = EMFHelper.followingSiblings(action); - if (followingSiblings != null && !followingSiblings.isEmpty()) { - EObject next = followingSiblings.iterator().next(); - if (next instanceof Cancel) { - return (Cancel) next; - } - } - return null; - - } - - public static EditAction getCancelPrecedingAction(Cancel action) { - Collection precedingSiblings = EMFHelper.precedingSiblings(action); - if (precedingSiblings != null && !precedingSiblings.isEmpty()) { - EObject prev = precedingSiblings.iterator().next(); - if (prev instanceof EditAction) { - return (EditAction) prev; - } - } - return null; - - } - - public static Processing getPrecedingEditActionOrSequence(Action action) { - Collection precedingSiblings = EMFHelper.precedingSiblings(action); - if (precedingSiblings != null && !precedingSiblings.isEmpty()) { - for (EObject prev : precedingSiblings) { - if (prev instanceof EditAction || prev instanceof Sequence) { - return (Processing) prev; - } - } - } - return null; - } - - public static boolean isWizard(Processing processing) { - return processing != null && processing instanceof Wizard; - } - - public static int getNumberOfActionToUndo(Processing processing) { - EList eContents = processing.eContents(); - int actionstoUndo = 0; - for (EObject eObject : eContents) { - if (eObject instanceof EditAction && !(eObject instanceof Cancel)) { - actionstoUndo++; - } else if (eObject instanceof Wizard) { - actionstoUndo += getNumberOfActionToUndo((Processing) eObject); - } - } - return actionstoUndo; - } - - public static int getNumberOfActionToCancel(Processing processing) { - EList eContents = processing.eContents(); - int actionstoCancel = 0; - for (EObject eObject : eContents) { - if (eObject instanceof EditAction && !(eObject instanceof Cancel)) { - actionstoCancel++; - } - } - return actionstoCancel; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EMFHelper.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EMFHelper.java deleted file mode 100644 index fffec3132..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/EMFHelper.java +++ /dev/null @@ -1,148 +0,0 @@ -package org.eclipse.emf.eef.modelingBot.helper; - -import static org.junit.Assert.assertFalse; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.List; - -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.command.CommandActionDelegate; -import org.eclipse.emf.edit.command.CommandParameter; -import org.eclipse.emf.edit.command.CreateChildCommand; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.modelingBot.SequenceType; -import org.eclipse.emf.eef.modelingBot.EEFActions.EditAction; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; - -public class EMFHelper { - - public static EPackage findInRegistry(EPackage ePackage) { - return EPackage.Registry.INSTANCE.getEPackage(ePackage.getNsURI()); - } - - public static EClass map(EPackage ePackage, EClass clazz) { - TreeIterator eAllContents = ePackage.eAllContents(); - while (eAllContents.hasNext()) { - EObject next = eAllContents.next(); - if (next instanceof EClass && uniqueId(clazz).equals(uniqueId((EClass) next))) { - return (EClass) next; - } - } - return null; - } - - public static EStructuralFeature map(EPackage ePackage, EStructuralFeature feature) { - TreeIterator eAllContents = ePackage.eAllContents(); - while (eAllContents.hasNext()) { - EObject next = eAllContents.next(); - if (next instanceof EStructuralFeature && uniqueId(feature).equals(uniqueId((EStructuralFeature) next))) { - return (EStructuralFeature) next; - } - } - return null; - } - - private static String uniqueId(EClass clazz) { - return clazz.getName() + clazz.getEPackage().getName(); - } - - private static String uniqueId(EStructuralFeature feature) { - return feature.getName() + ((EClass)feature.eContainer()).getName() + ((EClass)feature.eContainer()).getEPackage().getName(); - } - - public static Collection followingSiblings(EObject eObject) { - Collection followingSiblings = new ArrayList(); - if (eObject.eContainingFeature()!=null && eObject.eContainingFeature().isMany()) { - @SuppressWarnings("unchecked") - List siblings = (List) eObject.eContainer().eGet(eObject.eContainingFeature()); - int indexOf = siblings.indexOf(eObject); - if (indexOf != -1) { - for (int i = indexOf + 1; i < siblings.size(); i++) { - followingSiblings.add(siblings.get(i)); - } - } - } - return followingSiblings; - } - - public static Collection precedingSiblings(EObject eObject) { - Collection precedingSiblings = new ArrayList(); - if (eObject.eContainingFeature()!=null && eObject.eContainingFeature().isMany()) { - @SuppressWarnings("unchecked") - List siblings = (List) eObject.eContainer().eGet(eObject.eContainingFeature()); - int indexOf = siblings.indexOf(eObject); - if (indexOf != -1) { - for (int i = indexOf - 1; i >= 0; i--) { - precedingSiblings.add(siblings.get(i)); - } - } - } - return precedingSiblings; - } - - @SuppressWarnings("unchecked") - public static String getCreateChildLabel(EditingDomain editingDomain, EClass type, final EObject container) { - Collection newChildDescriptors = editingDomain.getNewChildDescriptors(container, null); - CommandParameter next = null; - for (CommandParameter param : ((Collection)newChildDescriptors)) { - if (param.getEValue() != null && type.getName().equals(param.getEValue().eClass().getName())) { - next = param; - break; - } - } - String text = type.getName(); - if (next != null) { - Command create = CreateChildCommand.create(editingDomain, container, next, Collections.emptyList()); - if (create instanceof CommandActionDelegate) { - text = ((CommandActionDelegate) create).getText(); - } - - } - return text; - } - - public static String getEditorLabel(PropertiesEditionElement propertiesEditionElement, EObject referenceableObject, EObject container, SequenceType sequenceType) { - AdapterFactory adapterFactory = EEFRuntimePlugin.getDefault().getAdapterFactory(); - EObject target = null; - if (SequenceType.DETAILS_PAGE == sequenceType) { - target = container; - } else if (SequenceType.WIZARD == sequenceType) { - if (((EditAction)referenceableObject).getPropertiesEditionElement() != null) { - target = (EObject)EEFModelHelper.eGet(container, ((EditAction)referenceableObject).getPropertiesEditionElement().getModel()); - } else { - target = container; - - } - }else if (SequenceType.PROPERTIES_VIEW == sequenceType) { - target = container; - } - assertFalse(target == null); - EStructuralFeature model = EMFHelper.map(target.eClass().getEPackage(), propertiesEditionElement.getModel()); - return getEditorLabel(adapterFactory, target, model); - } - - private static String getEditorLabel(AdapterFactory factory, EObject target, EStructuralFeature feature) { - IItemPropertySource adapt = (IItemPropertySource) factory.adapt(target, IItemPropertySource.class); - IItemPropertyDescriptor propertyDescriptor = adapt.getPropertyDescriptor(target, feature); - String displayName; - if (propertyDescriptor != null) { - displayName = propertyDescriptor.getDisplayName(target); - } else { - displayName = feature.getName(); - } - return displayName; - } - - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/PropertiesEditionHelper.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/PropertiesEditionHelper.java deleted file mode 100755 index 62bb7a095..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/PropertiesEditionHelper.java +++ /dev/null @@ -1,671 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.helper; - -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNotNull; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.SequenceType; -import org.eclipse.emf.eef.modelingBot.Wizard; -import org.eclipse.emf.eef.modelingBot.EEFActions.Add; -import org.eclipse.emf.eef.modelingBot.interpreter.EEFInterpreter; -import org.eclipse.emf.eef.modelingBot.swtbot.SWTEEFBot; -import org.eclipse.emf.eef.modelingBot.ui.utils.WrappedSWTBotRadio; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotButton; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotCheckBox; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotCombo; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotRadio; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTable; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotText; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem; - -/** - * @author Nathalie Lepine - */ -public class PropertiesEditionHelper { - - /** - * SWT EEF Bot. - */ - private SWTEEFBot bot; - - /** - * Create a PropertiesEditionHelper. - * - * @param bot - * SWTEEFBot - */ - public PropertiesEditionHelper(SWTEEFBot bot) { - this.bot = bot; - } - - /** - * Update an attribute. - * - * @param selectNode - * @param propertiesEditionElement - * @param value - * @param container - * @param containerOfcontainer - * @param sequenceType - */ - public void updateAttribute(SWTBotTreeItem selectNode, - PropertiesEditionElement propertiesEditionElement, - EObject referenceableObject, EObject container, - Collection values, SequenceType sequenceType) { - assertFalse(propertiesEditionElement.getViews().isEmpty()); - assertFalse(values == null); - assertFalse(values.isEmpty()); - - final ElementEditor elementEditor = propertiesEditionElement.getViews() - .get(0); - final String representationName = elementEditor.getRepresentation() - .getName(); - if ("Text".equals(representationName) - || "Textarea".equals(representationName)) { - updateText(propertiesEditionElement, referenceableObject, - container, values.iterator().next(), sequenceType); - } else if ("EMFComboViewer".equals(representationName)) { - updateEMFComboViewer(propertiesEditionElement, referenceableObject, - container, values.iterator().next(), sequenceType); - } else if ("Radio".equals(representationName)) { - updateRadio(elementEditor, values.iterator().next(), sequenceType); - } else if ("Checkbox".equals(representationName)) { - AdapterFactory adapterFactory = EEFRuntimePlugin.getDefault() - .getAdapterFactory(); - EStructuralFeature model = EMFHelper.map(container.eClass() - .getEPackage(), propertiesEditionElement.getModel()); - IItemPropertySource adapt = (IItemPropertySource) adapterFactory - .adapt(container, IItemPropertySource.class); - String value = null; - if (adapt != null) { - value = adapt.getPropertyDescriptor(container, model) - .getDisplayName(container); - } - updateCheckbox(elementEditor, value, sequenceType); - } else if ("MultiValuedEditor".equals(representationName)) { - updateMultiValuedEditor(propertiesEditionElement, values, - sequenceType); - } else { - System.out.println("Case not managed in updateAttribute : " - + representationName); - } - } - - /** - * - * @param elementEditor - * @param value - * @param sequenceType - */ - private void updateRadio(ElementEditor elementEditor, String value, - SequenceType sequenceType) { - SWTBotHelper.waitAllUiEvents(); - final SWTBotRadio radio = bot.radioWithIdAndMnemonic( - elementEditor.getQualifiedIdentifier(), value); - WrappedSWTBotRadio wrappedRadio = new WrappedSWTBotRadio(radio); - wrappedRadio.click(); - SWTBotHelper.sendFocusLost(radio.widget); - SWTBotHelper.waitAllUiEvents(); - - } - - /** - * Update a feature. - * - * @param selectNode - * @param propertiesEditionElement - * @param referenceableObject - * the container of the reference to set - * @param value - * the value to set - * @param sequenceType - */ - public void updateFeature(SWTBotTreeItem selectNode, - PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, - Collection values, SequenceType sequenceType) { - assertFalse(propertiesEditionElement.getViews().isEmpty()); - final ElementEditor elementEditor = propertiesEditionElement.getViews() - .get(0); - final String representationName = elementEditor.getRepresentation() - .getName(); - if ("ReferencesTable".equals(representationName)) { - updateReferencesTable(propertiesEditionElement, values); - } else if ("AdvancedReferencesTable".equals(representationName)) { - updateAdvancedReferencesTable(propertiesEditionElement, values); - } else if ("FlatReferencesTable".equals(representationName)) { - updateFlatReferencesTable(propertiesEditionElement, values); - } else if ("EObjectFlatComboViewer".equals(representationName)) { - updateEObjectFlatComboViewer(propertiesEditionElement, values); - } else if ("AdvancedEObjectFlatComboViewer".equals(representationName)) { - updateAdvancedEObjectFlatComboViewer(propertiesEditionElement, - values); - } else if ("Combo".equals(representationName)) { - final EObject container = bot - .getEObjectFromReferenceableEObject((ReferenceableObject) referenceableObject); - assertNotNull("No container is found to launch add action.", - container); - updateCombo(selectNode, propertiesEditionElement, - referenceableObject, container, sequenceType); - } else { - System.out.println("Case not managed in updateFeature : " - + representationName); - } - - } - - /** - * Update widget Combo. - * - * @param propertiesEditionElement - * @param value - * @param value - */ - private void updateCombo(SWTBotTreeItem selectNode, - PropertiesEditionElement propertiesEditionElement, - EObject referenceableObject, EObject container, - SequenceType sequenceType) { - SWTBotHelper.waitAllUiEvents(); - String realLabel = EMFHelper.getEditorLabel(propertiesEditionElement, - referenceableObject, container, sequenceType); - final SWTBotCombo comboBoxWithLabel = bot.comboBoxWithLabel(realLabel - + ": "); - comboBoxWithLabel.setSelection(0); - SWTBotHelper.sendFocusLost(comboBoxWithLabel.widget); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Update widget ReferencesTable. - * - * @param propertiesEditionElement - * @param value - */ - private void updateReferencesTable( - PropertiesEditionElement propertiesEditionElement, - Collection values) { - SWTBotHelper.waitAllUiEvents(); - String label = ((ElementEditor) propertiesEditionElement.getViews() - .get(0)).getQualifiedIdentifier(); - bot.addButtonReferencesTable(label).click(); - bot.selectInActiveTable(values); - clickOkOrCancel(propertiesEditionElement); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Update widget AdvancedReferencesTable. - * - * @param propertiesEditionElement - * @param value - */ - private void updateAdvancedReferencesTable( - PropertiesEditionElement propertiesEditionElement, - Collection values) { - SWTBotHelper.waitAllUiEvents(); - String label = ((ElementEditor) propertiesEditionElement.getViews() - .get(0)).getQualifiedIdentifier(); - // TODO manage this case with selectInActiveTree(Collection) - // when EEF will allowed to select multiple elements in a tree - for (EObject value : values) { - bot.addButtonAdvancedReferencesTable(label).click(); - bot.selectInActiveTree(value); - clickOkOrCancel(propertiesEditionElement); - } - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Update widget FlatReferencesTable. - * - * @param propertiesEditionElement - * @param value - */ - private void updateFlatReferencesTable( - PropertiesEditionElement propertiesEditionElement, - Collection values) { - SWTBotHelper.waitAllUiEvents(); - String label = ((ElementEditor) propertiesEditionElement.getViews() - .get(0)).getQualifiedIdentifier(); - bot.browseButtonFlatReferencesTable(label).click(); - final SWTBotTable table = bot.table(1); - int rowCount = table.rowCount(); - for (int i = 0; i < rowCount; i++) { - SWTBotButton buttonRemove = bot.button(1); - buttonRemove.click(); - SWTBotHelper.waitAllUiEvents(); - } - bot.selectInActiveTable(values); - SWTBotButton buttonAdd = bot.button(0); - buttonAdd.click(); - clickOkOrCancel(propertiesEditionElement); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Unset widget FlatReferencesTable. - * - * @param propertiesEditionElement - * @param values - */ - public void unsetFlatReferencesTable( - PropertiesEditionElement propertiesEditionElement, - Collection values) { - SWTBotHelper.waitAllUiEvents(); - String label = ((ElementEditor) propertiesEditionElement.getViews() - .get(0)).getQualifiedIdentifier(); - bot.browseButtonFlatReferencesTable(label).click(); - if (values == null || values.isEmpty()) { - final SWTBotTable table = bot.table(1); - int rowCount = table.rowCount(); - for (int i = 0; i < rowCount; i++) { - SWTBotButton buttonRemove = bot.button(1); - buttonRemove.click(); - SWTBotHelper.waitAllUiEvents(); - } - } else { - for (EObject value : values) { - bot.selectInRightTableOfActiveEditor(value); - SWTBotButton buttonRemove = bot.button(1); - buttonRemove.click(); - SWTBotHelper.waitAllUiEvents(); - } - } - clickOkOrCancel(propertiesEditionElement); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Update widget EObjectFlatComboViewer. - * - * @param propertiesEditionElement - * @param value - */ - private void updateEObjectFlatComboViewer( - PropertiesEditionElement propertiesEditionElement, - Collection values) { - SWTBotHelper.waitAllUiEvents(); - String label = ((ElementEditor) propertiesEditionElement.getViews() - .get(0)).getQualifiedIdentifier(); - bot.editButtonEObjectFlatComboViewer(label).click(); - bot.selectInActiveTable(values); - clickOkOrCancel(propertiesEditionElement); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Update widget AdvancedEObjectFlatComboViewer. - * - * @param propertiesEditionElement - * @param value - */ - private void updateAdvancedEObjectFlatComboViewer( - PropertiesEditionElement propertiesEditionElement, - Collection values) { - SWTBotHelper.waitAllUiEvents(); - String label = ((ElementEditor) propertiesEditionElement.getViews() - .get(0)).getQualifiedIdentifier(); - bot.browseButtonAdvancedEObjectFlatComboViewer(label).click(); - bot.selectInActiveTree(values); - clickOkOrCancel(propertiesEditionElement); - SWTBotHelper.waitAllUiEvents(); - - } - - /** - * Update widget text. - * - * @param selectNode - * @param propertiesEditionElement - * @param value - * @param container - * @param sequenceType - */ - private void updateText(PropertiesEditionElement propertiesEditionElement, - EObject referenceableObject, EObject container, String value, - SequenceType sequenceType) { - SWTBotHelper.waitAllUiEvents(); - String realLabel = EMFHelper.getEditorLabel(propertiesEditionElement, - referenceableObject, container, sequenceType); - final SWTBotText textWithLabel = bot.textWithLabel(realLabel + ": "); - textWithLabel.setText(value); - SWTBotHelper.pressEnterKey(textWithLabel.widget); - SWTBotHelper.sendFocusLost(textWithLabel.widget); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Update widget EMFComboViewer. - * - * @param propertiesEditionElement - * @param value - * @param sequenceType - */ - private void updateEMFComboViewer( - PropertiesEditionElement propertiesEditionElement, - EObject referenceableObject, EObject container, String value, - SequenceType sequenceType) { - SWTBotHelper.waitAllUiEvents(); - String realLabel = EMFHelper.getEditorLabel(propertiesEditionElement, - referenceableObject, container, sequenceType); - final SWTBotCombo comboBoxWithLabel = bot.comboBoxWithLabel(realLabel - + ": "); - comboBoxWithLabel.setSelection(value); - SWTBotHelper.sendFocusLost(comboBoxWithLabel.widget); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Update widget Checkbox. - * - * @param elementEditor - * @param value - * the label of the Checkbox - * @param sequenceType - */ - private void updateCheckbox(ElementEditor elementEditor, String value, - SequenceType sequenceType) { - SWTBotHelper.waitAllUiEvents(); - final SWTBotCheckBox checkBox = bot.checkBox(value); - checkBox.click(); - SWTBotHelper.sendFocusLost(checkBox.widget); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Update widget MultiValuedEditor. - * - * @param propertiesEditionElement - * @param values - * @param sequenceType - */ - private void updateMultiValuedEditor( - PropertiesEditionElement propertiesEditionElement, - Collection values, SequenceType sequenceType) { - SWTBotHelper.waitAllUiEvents(); - String label = ((ElementEditor) propertiesEditionElement.getViews() - .get(0)).getQualifiedIdentifier(); - bot.browseButtonMultiValuedEditor(label).click(); - bot.addValuesInMultiValuedEditor(values); - clickOkOrCancel(propertiesEditionElement); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Unset values for widget MultiValuedEditor. - * - * @param propertiesEditionElement - * @param values - * @param sequenceType - */ - public void unsetMultiValuedEditor( - PropertiesEditionElement propertiesEditionElement, - Collection values, SequenceType sequenceType) { - SWTBotHelper.waitAllUiEvents(); - String label = ((ElementEditor) propertiesEditionElement.getViews() - .get(0)).getQualifiedIdentifier(); - bot.browseButtonMultiValuedEditor(label).click(); - if (values == null || values.isEmpty()) { - bot.removeAllValuesInMultiValuedEditor(); - } else { - bot.removeValuesInMultiValuedEditor(values); - } - clickOkOrCancel(propertiesEditionElement); - SWTBotHelper.waitAllUiEvents(); - } - - public void setBot(SWTEEFBot bot) { - this.bot = bot; - } - - public void addFeature(SWTBotTreeItem selectNode, - PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, SequenceType sequenceType) { - assertFalse(propertiesEditionElement.getViews().isEmpty()); - final ElementEditor elementEditor = propertiesEditionElement.getViews() - .get(0); - final String representationName = elementEditor.getRepresentation() - .getName(); - if ("TableComposition".equals(representationName)) { - bot.addButtonTableComposition( - elementEditor.getQualifiedIdentifier()).click(); - } else if ("AdvancedTableComposition".equals(representationName)) { - bot.addButtonAdvancedTableComposition( - elementEditor.getQualifiedIdentifier()).click(); - } - // Execute the Action of each following siblings of the Add Action in - // the Wizard of ModelingBot model - if (referenceableObject != null) { - if (referenceableObject instanceof Add - && referenceableObject.eContainer() instanceof Wizard) { - EStructuralFeature feature = ((Add) referenceableObject) - .getEContainingFeature(); - EClassifier type = feature.getEType(); - if (type != null && type instanceof EClass - && ((EClass) type).isAbstract()) { - SWTBotRadio radio = bot.radio(((Add) referenceableObject).getType().getName()); - WrappedSWTBotRadio wrappedRadio = new WrappedSWTBotRadio(radio); - wrappedRadio.click(); - bot.button(UIConstants.NEXT_BUTTON).click(); - } -// Collection settings = EMFHelper -// .followingSiblings(referenceableObject); -// for (EObject setting : settings) { -// if (setting instanceof Action) { -// bot.getModelingBotInterpreter().runAction( -// (Action) setting); -// if (setting instanceof Cancel) { -// EditAction prev = EEFModelingBotHelper -// .getCancelPrecedingAction((Cancel) setting); -// clickCancel(prev.getPropertiesEditionElement()); -// return; -// } -// } -// } - } - } - //bot.button(UIConstants.FINISH_BUTTON).click(); - SWTBotHelper.waitAllUiEvents(); - } - - public void removeFeature(EObject remove, - PropertiesEditionElement propertiesEditionElement, - SequenceType sequenceType) { - assertFalse(propertiesEditionElement.getViews().isEmpty()); - final ElementEditor elementEditor = propertiesEditionElement.getViews() - .get(0); - removeFeature(remove, elementEditor); - } - - private void removeFeature(EObject remove, ElementEditor elementEditor) { - bot.selectInTableWithId( - org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, - elementEditor.getQualifiedIdentifier(), remove); - final String representationName = elementEditor.getRepresentation() - .getName(); - if ("TableComposition".equals(representationName)) { - bot.removeButtonTableComposition( - elementEditor.getQualifiedIdentifier()).click(); - } else if ("AdvancedTableComposition".equals(representationName)) { - bot.removeButtonAdvancedTableComposition( - elementEditor.getQualifiedIdentifier()).click(); - } - } - - public void unsetReference( - PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, - Collection objectsToUnset, SequenceType sequenceType) { - final ElementEditor elementEditor = propertiesEditionElement.getViews() - .get(0); - final String representationName = elementEditor.getRepresentation() - .getName(); - if ("ReferencesTable".equals(representationName)) { - unsetReferencesTable(elementEditor, objectsToUnset); - } else if ("AdvancedReferencesTable".equals(representationName)) { - unsetAdvancedReferencesTable(elementEditor, objectsToUnset); - } else if ("FlatReferencesTable".equals(representationName)) { - unsetFlatReferencesTable(propertiesEditionElement, objectsToUnset); - } else if ("EObjectFlatComboViewer".equals(representationName)) { - unsetEObjectFlatComboViewer(elementEditor, objectsToUnset); - } else if ("AdvancedEObjectFlatComboViewer".equals(representationName)) { - unsetAdvancedEObjectFlatComboViewer(elementEditor); - } else if ("Combo".equals(representationName)) { - final EObject container = bot - .getEObjectFromReferenceableEObject((ReferenceableObject) referenceableObject); - assertNotNull("No container is found to launch add action.", - container); - unsetCombo(propertiesEditionElement, referenceableObject, - container, sequenceType); - } else { - System.out.println("Case not managed in unset : " - + representationName); - } - } - - /** - * Unset widget EOFCV. - * - * @param elementEditor - */ - public void unsetEObjectFlatComboViewer(ElementEditor elementEditor, - Collection values) { - bot.editButtonEObjectFlatComboViewer( - elementEditor.getQualifiedIdentifier()).click(); - bot.selectInActiveTable(""); - bot.button(UIConstants.OK_BUTTON).click(); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Unset widget Combo. - * - * @param propertiesEditionElement - * @param referenceableObject - * @param container - * @param sequenceType - */ - public void unsetCombo(PropertiesEditionElement propertiesEditionElement, - EObject referenceableObject, EObject container, - SequenceType sequenceType) { - SWTBotHelper.waitAllUiEvents(); - String realLabel = EMFHelper.getEditorLabel(propertiesEditionElement, - referenceableObject, container, sequenceType); - final SWTBotCombo comboBoxWithLabel = bot.comboBoxWithLabel(realLabel - + ": "); - comboBoxWithLabel.setSelection(""); - SWTBotHelper.sendFocusLost(comboBoxWithLabel.widget); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Unset widget AdvancedEOFCV. - * - * @param elementEditor - */ - public void unsetAdvancedEObjectFlatComboViewer(ElementEditor elementEditor) { - bot.removeButtonAdvancedEObjectFlatComboViewer( - elementEditor.getQualifiedIdentifier()).click(); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Unset widget ReferenceTable. - * - * @param elementEditor - * @param objectsToUnset - */ - public void unsetReferencesTable(ElementEditor elementEditor, - Collection objectsToUnset) { - bot.selectInTableWithId( - org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, - elementEditor.getQualifiedIdentifier(), objectsToUnset); - bot.removeButtonReferencesTable(elementEditor.getQualifiedIdentifier()) - .click(); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Unset widget AdvancedRefrencesTable. - * - * @param elementEditor - * @param objectsToUnset - */ - public void unsetAdvancedReferencesTable(ElementEditor elementEditor, - Collection objectsToUnset) { - bot.selectInTableWithId( - org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, - elementEditor.getQualifiedIdentifier(), objectsToUnset); - bot.removeButtonAdvancedReferencesTable( - elementEditor.getQualifiedIdentifier()).click(); - SWTBotHelper.waitAllUiEvents(); - } - - private void clickOkOrCancel( - PropertiesEditionElement propertiesEditionElement) { - SWTBotHelper.waitAllUiEvents(); - // bot.sleep(1000); - if (((EEFInterpreter) bot.getModelingBotInterpreter()) - .getActionsToCancel().contains(propertiesEditionElement)) { - bot.cancel(null); - ((EEFInterpreter) bot.getModelingBotInterpreter()) - .getActionsToCancel().remove(propertiesEditionElement); - } else { - bot.button(UIConstants.OK_BUTTON).click(); - } - } - - private void clickCancel(PropertiesEditionElement propertiesEditionElement) { - SWTBotHelper.waitAllUiEvents(); - // bot.sleep(1000); - if (((EEFInterpreter) bot.getModelingBotInterpreter()) - .getActionsToCancel().contains(propertiesEditionElement)) { - bot.cancel(null); - ((EEFInterpreter) bot.getModelingBotInterpreter()) - .getActionsToCancel().remove(propertiesEditionElement); - } - } - - public void unsetAttribute( - PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EObject container, - Collection values, SequenceType sequenceType) { - final ElementEditor elementEditor = propertiesEditionElement.getViews() - .get(0); - final String representationName = elementEditor.getRepresentation() - .getName(); - if ("Text".equals(representationName) - || "Textarea".equals(representationName)) { - updateText(propertiesEditionElement, referenceableObject, - container, "", sequenceType); - } else if ("MultiValuedEditor".equals(representationName)) { - unsetMultiValuedEditor(propertiesEditionElement, values, - sequenceType); - } else { - System.out.println("Case not managed in unset : " - + representationName); - } - - } -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/SWTBotHelper.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/SWTBotHelper.java deleted file mode 100755 index c9355f495..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/SWTBotHelper.java +++ /dev/null @@ -1,278 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.modelingBot.helper; - -import java.util.List; - -import org.eclipse.emf.eef.modelingBot.menu.SWTBotContextMenu; -import org.eclipse.swt.SWT; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Event; -import org.eclipse.swt.widgets.Text; -import org.eclipse.swt.widgets.Widget; -import org.eclipse.swtbot.eclipse.finder.SWTWorkbenchBot; -import org.eclipse.swtbot.eclipse.finder.matchers.WidgetMatcherFactory; -import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable; -import org.eclipse.swtbot.swt.finder.results.VoidResult; -import org.eclipse.swtbot.swt.finder.utils.SWTUtils; -import org.eclipse.swtbot.swt.finder.waits.Conditions; -import org.eclipse.swtbot.swt.finder.waits.WaitForObjectCondition; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem; -import org.eclipse.ui.internal.views.properties.tabbed.view.TabbedPropertyList; -import org.eclipse.ui.internal.views.properties.tabbed.view.TabbedPropertyList.ListElement; -import org.hamcrest.Matcher; - -/** - * @author Nathalie Lepine - */ -public class SWTBotHelper { - /** - * SWTWorkbenchBot. - */ - private static SWTWorkbenchBot bot = new SWTWorkbenchBot(); - - /** - * Press the enter key. - * - * @param widget - * @throws Exception - */ - public static void pressEnterKey(final Widget widget) { - UIThreadRunnable.asyncExec(new VoidResult() { - public void run() { - widget.notifyListeners(SWT.KeyDown, keyEvent(SWT.NONE, SWT.CR, SWT.Selection, widget)); - } - }); - } - - public static void sendFocusLost(final Widget widget) { - UIThreadRunnable.asyncExec(new VoidResult() { - public void run() { - Event event = createEvent(widget); - event.type = SWT.FocusOut; - - widget.notifyListeners(SWT.FocusOut, event); - } - }); - } - - /** - * Press the enter key. - * - * @param widget - * @throws Exception - */ - public static void pressEnterKeyInTabContainer(final Widget widget) { - UIThreadRunnable.asyncExec(new VoidResult() { - public void run() { - searchTabContainer(widget).notifyListeners(SWT.Traverse, - keyEvent(SWT.NONE, SWT.CR, SWT.Selection, widget)); - } - }); - } - - private static Composite searchTabContainer(final Widget wid) { - Composite parent = ((Text)wid).getParent(); - while (parent != null) { - if (parent instanceof Composite) - return parent; - parent = parent.getParent(); - } - return null; - } - - /** - * @param modificationKey - * the modification key. - * @param c - * the character. - * @param keyCode - * the keycode. - * @return a key event with the specified keys. - * @see Event#keyCode - * @see Event#character - * @see Event#stateMask - * @since 1.2 - */ - private static Event keyEvent(int modificationKey, char c, int keyCode, Widget widget) { - Event keyEvent = createEvent(widget); - keyEvent.stateMask = modificationKey; - keyEvent.character = c; - keyEvent.keyCode = keyCode; - - return keyEvent; - } - - private static Event createEvent(Widget widget) { - Event event = new Event(); - event.time = (int)System.currentTimeMillis(); - event.widget = widget; - event.display = bot.getDisplay(); - return event; - } - - /** - * Select the tab with the name label in the property views. - * - * @param label - * Label to find. - */ - // CHECKSTYLE:OFF - @SuppressWarnings({"restriction", "unchecked"}) - // CHECKSTYLE:ON - public static void selectPropertyTabItem(final String label) { - final Matcher matcher = WidgetMatcherFactory.allOf(WidgetMatcherFactory - .widgetOfType(TabbedPropertyList.class)); - final List widgets = widget(matcher); - - UIThreadRunnable.syncExec(SWTUtils.display(), new VoidResult() { - public void run() { - for (final TabbedPropertyList tabbedProperty : widgets) { - final ListElement tabItem = getTabItem(label, tabbedProperty); - if (tabItem != null) { - final Event mouseEvent = createEvent(tabItem, tabItem.getBounds().x, tabItem.getBounds().y, 1, - SWT.BUTTON1, 1); - tabItem.notifyListeners(SWT.MouseUp, mouseEvent); - } - } - } - }); - } - - /** - * Find widget. - * - * @param matcher - * the matcher used to match widgets. - * @return all the widgets matching the matcher. - */ - @SuppressWarnings("restriction") - public static List widget(final Matcher matcher) { - final WaitForObjectCondition waitForWidget = Conditions.waitForWidget(matcher); - bot.waitUntilWidgetAppears(waitForWidget); - return waitForWidget.getAllMatches(); - } - - /** - * Create a event
- * - * @param x - * the x coordinate of the mouse event. - * @param y - * the y coordinate of the mouse event. - * @param button - * the mouse button that was clicked. - * @param stateMask - * the state of the keyboard modifier keys. - * @param count - * the number of times the mouse was clicked. - * @return an event that encapsulates {@link #widget} and {@link #display} - */ - private static Event createEvent(final Widget widget, final int x, final int y, final int button, - final int stateMask, final int count) { - final Event event = new Event(); - event.time = (int)System.currentTimeMillis(); - event.widget = widget; - event.display = bot.getDisplay(); - event.x = x; - event.y = y; - event.button = button; - event.stateMask = stateMask; - event.count = count; - return event; - } - - /** - * Select the tab with the name label in the property views - * - * @param label - */ - @SuppressWarnings("restriction") - private static ListElement getTabItem(final String label, final TabbedPropertyList tabbedProperty) { - for (final Object listElement : tabbedProperty.getTabList()) { - if (listElement instanceof ListElement && ((ListElement)listElement).getTabItem().getText().equals(label)) { - return (ListElement)listElement; - } - } - return null; - } - - /** - * WARNING this class should move in SWTBot one day. WARNING if the text is not found it will not failed - * this method to get disposed elements with the current click on context menu SWTBot method - * - * @param treeItem - * the current item - * @param text - * the menu text - */ - public static void clickContextMenu(final SWTBotTreeItem treeItem, final String text) { - UIThreadRunnable.asyncExec(new VoidResult() { - - public void run() { - final SWTBotContextMenu menu = new SWTBotContextMenu(treeItem); - menu.click(text); - } - }); - } - - /** - * WARNING this class should move in SWTBot one day. WARNING if the text is not found it will not failed - * this method to get disposed elements with the current click on context menu SWTBot method - * - * @param tree - * the tree - * @param text - * the menu text - */ - public static void clickContextMenu(final SWTBotTree tree, final String text) { - UIThreadRunnable.asyncExec(new VoidResult() { - public void run() { - final SWTBotContextMenu menu = new SWTBotContextMenu(tree); - menu.click(text); - } - }); - } - - /** - * Hack method to ensure that previous call was processed fully. - */ - public static void waitAllUiEvents() { - // use another sync exec to ensure that previous call was processed - // fully - UIThreadRunnable.syncExec(new VoidResult() { - public void run() { - // do nothing, just wait for all events to be processed - } - }); - } - - /** - * WARNING this class should move in SWTBot one day. WARNING if the text is not found it will not failed - * this method to get disposed elements with the current click on context menu SWTBot method - * - * @param treeItem - * the current item - * @param text - * the menu text - */ - public static void doubleClickContextMenu(final SWTBotTreeItem treeItem, final String text) { - UIThreadRunnable.asyncExec(new VoidResult() { - - public void run() { - treeItem.doubleClick(); - } - }); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/SWTEEFBotHelper.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/SWTEEFBotHelper.java deleted file mode 100755 index 5e2755ed8..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/SWTEEFBotHelper.java +++ /dev/null @@ -1,178 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.helper; - -import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.allOf; -import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.widgetOfType; -import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.withId; -import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.withMnemonic; -import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.withStyle; - -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.runtime.ui.UIConstants; -import org.eclipse.swt.SWT; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Widget; -import org.eclipse.swtbot.swt.finder.SWTBot; -import org.eclipse.swtbot.swt.finder.exceptions.WidgetNotFoundException; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotButton; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotRadio; -import org.hamcrest.Matcher; - -/** - * @author Goulwen Le Fur - */ -public class SWTEEFBotHelper { - - private SWTBot bot; - - /** - * @param bot - */ - public SWTEEFBotHelper(SWTBot bot) { - super(); - this.bot = bot; - } - - /** - * @param viewID - * the edited advEOFCV - * @return the browse button of the given advEOFCV - */ - public SWTBotButton browseButtonAdvancedEObjectFlatComboViewer(String viewID) { - return new SWTBotButton((Button) bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedEObjectFlatComboViewer::browsebutton")))); - } - - /** - * @param viewID - * the edited EOFCV - * @return the edit button of the given EOFCV - */ - public SWTBotButton editButtonEObjectFlatComboViewer(String viewID) { - return new SWTBotButton((Button) bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::EObjectFlatComboViewer::editbutton")))); - } - - /** - * @param viewID - * the edited FlatReferencesTable - * @return the browse button of the given FlatReferencesTable - */ - public SWTBotButton browseButtonFlatReferencesTable(String viewID) { - return new SWTBotButton((Button) bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::FlatReferencesTable::browsebutton")))); - } - - /** - * @param viewID - * the edited advEOFCV - * @return the remove button of the given advEOFCV - */ - public SWTBotButton removeButtonAdvancedEObjectFlatComboViewer(String viewID) { - return new SWTBotButton((Button) bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedEObjectFlatComboViewer::removebutton")))); - } - - /** - * @param viewID - * the edited AdvancedReferencesTable - * @return the add button of the given AdvancedReferencesTable - */ - public SWTBotButton addButtonAdvancedReferencesTable(String viewID) { - return new SWTBotButton((Button) bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedReferencesTable::addbutton")))); - } - - /** - * @param viewID - * the edited AdvancedReferencesTable - * @return the remove button of the given AdvancedReferencesTable - */ - public SWTBotButton removeButtonAdvancedReferencesTable(String viewID) { - return new SWTBotButton((Button) bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedReferencesTable::removebutton")))); - } - - /** - * @param viewID - * the edited AdvancedTableComposition - * @return the add button of the given AdvancedTableComposition - */ - public SWTBotButton addButtonAdvancedTableComposition(String viewID) { - Matcher allOf = allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedTableComposition::addbutton")); - return new SWTBotButton((Button) bot.widget(allOf)); - } - - /** - * @param viewID - * the edited advTableComposition - * @return the remove button of the given advTableComposition - */ - public SWTBotButton removeButtonAdvancedTableComposition(String viewID) { - return new SWTBotButton((Button) bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedTableComposition::removebutton")))); - } - - /** - * @param viewID - * the edited MultiValuedEditor - * @return the browse button of the given MultiValuedEditor - */ - public SWTBotButton browseButtonMultiValuedEditor(String viewID) { - Matcher allOf = allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::MultiValuedEditor::browsebutton")); - return new SWTBotButton((Button) bot.widget(allOf)); - } - - /** - * @param viewID - * the edited radio - * @param mnemonicText - * the mnemonic to select - * @return the radio to select - */ - public SWTBotRadio radioWithIdAndMnemonic(String viewID, String mnemonicText) { - Matcher matcher = allOf(withId(UIConstants.EEF_WIDGET_ID_KEY, viewID), widgetOfType(Button.class), withMnemonic(mnemonicText), withStyle(SWT.RADIO, "SWT.RADIO")); - return new SWTBotRadio((Button) bot.widget(matcher), matcher); - } - - /** - * @param viewID - * the edited ReferencesTable - * @return the browse button of the given ReferencesTable - */ - public SWTBotButton addButtonReferencesTable(String viewID) { - return new SWTBotButton((Button) bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::ReferencesTable::addbutton")))); - } - - /** - * @param viewID - * the edited ReferencesTable - * @return the remove button of the given ReferencesTable - */ - public SWTBotButton removeButtonReferencesTable(String viewID) { - return new SWTBotButton((Button) bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::ReferencesTable::removebutton")))); - } - - /** - * @param viewID - * the edited ReferencesTable - * @return the add button of the given ReferencesTable - */ - public SWTBotButton addButtonTableComposition(String viewID) { - Matcher allOf = allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::TableComposition::addbutton")); - return new SWTBotButton((Button) bot.widget(allOf)); - } - - /** - * @param viewID - * the edited ReferencesTable - * @return the remove button of the given ReferencesTable - */ - public SWTBotButton removeButtonTableComposition(String viewID) { - Matcher allOf = allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::TableComposition::removebutton")); - return new SWTBotButton((Button) bot.widget(allOf)); - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/StringHelper.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/StringHelper.java deleted file mode 100755 index 1f9d4b9b0..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/StringHelper.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.modelingBot.helper; - - -/** - * Utility class for Styring Manipulations. - * - * @author Nathalie Lepine - */ -public final class StringHelper { - - /** - * Constructor. - */ - private StringHelper() { - // avoid instanciation - } - - /** - * Return the string with the firstChar Uppercased. - * - * @param from - * the string to modify - * @return the String with the first char uppercased. - */ - public static String toU1Case(String from) { - if (from.length() > 0) { - final StringBuilder sb = new StringBuilder(from.length()); - sb.append(Character.toUpperCase(from.charAt(0))).append(from.substring(1)); - return sb.toString(); - } - return ""; //$NON-NLS-1$ - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/UIConstants.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/UIConstants.java deleted file mode 100755 index 7290a1171..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/helper/UIConstants.java +++ /dev/null @@ -1,74 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.modelingBot.helper; - -/** - * Regroups the UI label constants from the Eclipse UI perspective The resource - * perspective is used for all the tests. - * - * @author Nathalie Lepine - * - */ -public class UIConstants { - - /***************************************************************************** - * * UI Constants * * - *****************************************************************************/ - - /***************************************************************************** - * * UI Menus * * - *****************************************************************************/ - public static final String GENERAL_MENU = "General"; - public static final String OPEN_PERSPECTIVE_MENU = "Open Perspective"; - public static final String OTHER_MENU = "Other..."; - public static final String SHOW_VIEW_MENU = "Show View"; - public static final String WINDOW_MENU = "Window"; - public static final String FILE_MENU = "File"; - public static final String SAVE_MENU = "Save"; - public static final String NAVIGATE_MENU = "Navigate"; - public static final String OPEN_MENU = "Open"; - public static final String OPEN_WITH_INTERACTIVE_EEF_EDITOR_MENU = "Open With Interactive EEF Editor"; - public static final String CLOSE_MENU = "Close"; - public static final String INTERACTIVE_EEF_EDITOR_MENU = "Interactive EEF Editor"; - public static final String DELETE_MENU = "Delete"; - public static final String CLOSE_PROJECT_MENU = "Close Project"; - public static final String OPEN_PROJECT_MENU = "Open Project"; - public static final String PROJECT_CREATION_MENU = "Project"; - public static final String NEW_PROJECT_MENU = "New Project"; - public static final String PROJECT_MENU = "Project..."; - public static final String EDIT_MENU = "Edit"; - - /***************************************************************************** - * * UI Views * * - *****************************************************************************/ - public static final String PACKAGE_EXPLORER_VIEW_NAME = "Package Explorer"; - public static final String PROPERTIES_VIEW_NAME = "Properties"; - public static final String JAVA_LABEL = "Java"; - public static final String JAVA_DEFAULT_LABEL = "Java (default)"; - public static final String WELCOME_LABEL = "Welcome"; - public static final String NEW = "New"; - - public static final String DELETE_RESOURCES_DIALOG = "Delete Resources"; - - /***************************************************************************** - * * UI Buttons * * - *****************************************************************************/ - public static final String OK_BUTTON = "OK"; - public static final String FINISH_BUTTON = "Finish"; - public static final String ADD_BUTTON = "Add"; - public static final String CANCEL_BUTTON = "Cancel"; - public static final String NEXT_BUTTON = "Next >"; - public static final String UP_BUTTON = "Up"; - public static final String DOWN_BUTTON = "Down"; - - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/ComposedEEFInterpreter.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/ComposedEEFInterpreter.java deleted file mode 100755 index 9df82a908..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/ComposedEEFInterpreter.java +++ /dev/null @@ -1,223 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.interpreter; - -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertTrue; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.DetailsPage; -import org.eclipse.emf.eef.modelingBot.IModelingBot; -import org.eclipse.emf.eef.modelingBot.ModelingBot; -import org.eclipse.emf.eef.modelingBot.Processing; -import org.eclipse.emf.eef.modelingBot.PropertiesView; -import org.eclipse.emf.eef.modelingBot.Scenario; -import org.eclipse.emf.eef.modelingBot.Sequence; -import org.eclipse.emf.eef.modelingBot.SequenceType; -import org.eclipse.emf.eef.modelingBot.Wizard; -import org.eclipse.emf.eef.modelingBot.EEFActions.Check; -import org.eclipse.emf.eef.modelingBot.swtbot.ComposedEEFBot; - -/** - * Interpreter for a list of modeling bots. - * - * @author Nathalie Lepine - */ -public class ComposedEEFInterpreter implements IModelingBotInterpreter { - - /** - * Editing domain. - */ - private EditingDomain editingDomain; - - /** - * List of modeling bots. - */ - private Collection modelingBots = new ArrayList(); - - /** - * Map Bot <-> interpreter. - */ - // private Map - // mapModelingBotInterpreter = new HashMap(); - /** - * ComposedEEFBot. - */ - private IModelingBot composedEEFBot; - - /** - * Create the interpreter. - * - * @param editingDomain - * editing domain - */ - public ComposedEEFInterpreter(Collection modelingBots, EditingDomain editingDomain) { - super(); - this.editingDomain = editingDomain; - initInterpreter(modelingBots); - } - - private void initInterpreter(Collection collection) { - for (IModelingBot iModelingBot : collection) { - if (iModelingBot instanceof ComposedEEFBot) { - this.composedEEFBot = iModelingBot; - } else { - this.modelingBots.add(iModelingBot); - } - } - } - - public void dispose() { - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#runModelingBot(java.lang.String, - * org.eclipse.emf.eef.modelingBot.IModelingBot) - */ - public void runModelingBot(String path) throws CoreException, IOException { - final Resource modelingBotResource = loadModel(path); - EcoreUtil.resolveAll(modelingBotResource.getResourceSet()); - assertFalse("The modeling bot resource is empty.", modelingBotResource.getContents().isEmpty()); - assertTrue("The modeling bot model contains errors, correct them first", modelingBotResource.getErrors() - .isEmpty()); - final ModelingBot mbot = (ModelingBot)modelingBotResource.getContents().get(0); - final Diagnostic diag = Diagnostician.INSTANCE.validate(mbot); - assertTrue("The modeling bot model contains errors, correct them first", diag.getSeverity() == Diagnostic.OK); - - assertNotNull("The modeling bot resource is empty.", mbot); - for (IModelingBot bot : modelingBots) { - bot.getModelingBotInterpreter().setPropertiesEditionContext(mbot.getPropertiesEditionContext()); - } - for (Sequence sequence : mbot.getSequences()) { - if (sequence instanceof Scenario) { - final Scenario scenario = (Scenario)sequence; - runSequence(scenario); - } - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#runSequence(org.eclipse.emf.eef.modelingBot.Sequence) - */ - public void runSequence(Sequence sequence) { - preProcessing(sequence); - for (Processing processing : sequence.getProcessings()) { - if (processing instanceof Action) { - runAction((Action)processing); - } else if (processing instanceof DetailsPage) { - setSequenceType(SequenceType.DETAILS_PAGE); - runSequence((DetailsPage)processing); - } else if (processing instanceof PropertiesView) { - setSequenceType(SequenceType.PROPERTIES_VIEW); - runSequence((PropertiesView)processing); - } else if (processing instanceof Wizard) { - setSequenceType(SequenceType.WIZARD); - runSequence((Wizard)processing); - } - } - postProcessing(sequence); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#preProcessing(org.eclipse.emf.eef.modelingBot.Sequence) - */ - public void preProcessing(Sequence sequence) { - for (IModelingBot iModelingBot : modelingBots) { - iModelingBot.getModelingBotInterpreter().preProcessing(sequence); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#postProcessing(org.eclipse.emf.eef.modelingBot.Sequence) - */ - public void postProcessing(Sequence sequence) { - for (IModelingBot iModelingBot : modelingBots) { - iModelingBot.getModelingBotInterpreter().postProcessing(sequence); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#runAction(org.eclipse.emf.eef.modelingBot.Action) - */ - public void runAction(Action action) { - for (IModelingBot iModelingBot : modelingBots) { - if (action instanceof Check) { - composedEEFBot.check(); - } else { - iModelingBot.getModelingBotInterpreter().runAction(action); - } - } - } - - private void setSequenceType(SequenceType sequenceType) { - for (IModelingBot iModelingBot : modelingBots) { - iModelingBot.setSequenceType(sequenceType); - } - } - - /** - * Get the loaded resource. - * - * @param path - * path of the model - * @return the resource loaded - * @throws IOException - * @throws CoreException - */ - public Resource loadModel(String path) throws IOException, CoreException { - final URI fileURI = URI.createPlatformPluginURI(path, true); - final Resource resource = editingDomain.getResourceSet().getResource(fileURI, true); - assertNotNull("The modeling bot resource can not be loaded.", resource); - return resource; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#getPropertiesEditionContext() - */ - public PropertiesEditionContext getPropertiesEditionContext() { - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#setPropertiesEditionContext(org.eclipse.emf.eef.components.PropertiesEditionContext) - */ - public void setPropertiesEditionContext(PropertiesEditionContext context) { - - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/EEFInterpreter.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/EEFInterpreter.java deleted file mode 100755 index baba016c1..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/EEFInterpreter.java +++ /dev/null @@ -1,404 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.interpreter; - -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertTrue; - -import java.io.IOException; -import java.util.Collection; -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; -import java.util.Set; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.DetailsPage; -import org.eclipse.emf.eef.modelingBot.IModelingBot; -import org.eclipse.emf.eef.modelingBot.ModelingBot; -import org.eclipse.emf.eef.modelingBot.Processing; -import org.eclipse.emf.eef.modelingBot.PropertiesView; -import org.eclipse.emf.eef.modelingBot.Scenario; -import org.eclipse.emf.eef.modelingBot.Sequence; -import org.eclipse.emf.eef.modelingBot.SequenceType; -import org.eclipse.emf.eef.modelingBot.Wizard; -import org.eclipse.emf.eef.modelingBot.EEFActions.Add; -import org.eclipse.emf.eef.modelingBot.EEFActions.Cancel; -import org.eclipse.emf.eef.modelingBot.EEFActions.EditAction; -import org.eclipse.emf.eef.modelingBot.EEFActions.MoveDown; -import org.eclipse.emf.eef.modelingBot.EEFActions.MoveUp; -import org.eclipse.emf.eef.modelingBot.EEFActions.OpenEEFEditor; -import org.eclipse.emf.eef.modelingBot.EEFActions.Remove; -import org.eclipse.emf.eef.modelingBot.EEFActions.SetAttribute; -import org.eclipse.emf.eef.modelingBot.EEFActions.SetReference; -import org.eclipse.emf.eef.modelingBot.EEFActions.Unset; -import org.eclipse.emf.eef.modelingBot.EEFActions.UnsetAttribute; -import org.eclipse.emf.eef.modelingBot.EEFActions.UnsetReference; -import org.eclipse.emf.eef.modelingBot.EclipseActions.CloseEditor; -import org.eclipse.emf.eef.modelingBot.EclipseActions.CloseProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.CreateModel; -import org.eclipse.emf.eef.modelingBot.EclipseActions.CreateProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.OpenEditor; -import org.eclipse.emf.eef.modelingBot.EclipseActions.Redo; -import org.eclipse.emf.eef.modelingBot.EclipseActions.RemoveProject; -import org.eclipse.emf.eef.modelingBot.EclipseActions.Save; -import org.eclipse.emf.eef.modelingBot.EclipseActions.Undo; -import org.eclipse.emf.eef.modelingBot.helper.EEFModelingBotHelper; -import org.eclipse.swtbot.swt.finder.exceptions.WidgetNotFoundException; - -/** - * Interpreter for SWTEEFBot or BatchModelingBot. - * - * @author Nathalie Lepine - */ -public class EEFInterpreter implements IModelingBotInterpreter { - - /** - * Editing domain. - */ - private EditingDomain editingDomain; - - /** - * Map ReFerenceableObject -> EObject created. - */ - private Map refObjectToEObjectMap = new HashMap(); - - /** - * Map Sequence -> boolean to know if the sequence has been canceled. - */ - private Map mapSequenceToCancel = new HashMap(); - - /** - * Set Action to know if the action has to be canceled. - */ - private Set actionsToCancel = new HashSet(); - - /** - * Modeling bot. - */ - private IModelingBot bot; - - /** - * PropertiesEditionContext. - */ - private PropertiesEditionContext propertiesEditionContext; - - /** - * Collection of Actions already processed. - */ - private Collection processedActions = new HashSet(); - - /** - * Create the interpreter. - * - * @param editingDomain - * editing domain - * @param bot - * the modelingbot - */ - public EEFInterpreter(IModelingBot bot, EditingDomain editingDomain) { - super(); - this.editingDomain = editingDomain; - this.bot = bot; - } - - /** - * @return the map of ReferenceableObject - */ - public Map getRefObjectToEObject() { - return refObjectToEObjectMap; - } - - /** - * Set the object corresponding to the referenceable object. - * - * @param refObjectToEObject - * ReferenceableObject - */ - public void setRefObjectToEObject(Map refObjectToEObject) { - this.refObjectToEObjectMap = refObjectToEObject; - } - - /** - * Returns the referenced object. - * - * @param ref - * ReferenceableObject - * @return the object corresponding to the referenceable object - */ - public EObject getEObjectFromReferenceableEObject(ReferenceableObject ref) { - return refObjectToEObjectMap.get(ref); - } - - /** - * @return - */ - public Set getActionsToCancel() { - return actionsToCancel; - } - - public Map getMapSequenceToCancel() { - return mapSequenceToCancel; - } - - /** - * Dispose the maps of the interpreter. - */ - public void dispose() { - refObjectToEObjectMap.clear(); - mapSequenceToCancel.clear(); - refObjectToEObjectMap = null; - mapSequenceToCancel = null; - } - - /** - * Get the loaded resource. - * - * @param path - * path of the model - * @return the resource loaded - */ - public Resource loadModel(String path) { - final URI fileURI = URI.createPlatformPluginURI(path, true); - final Resource resource = editingDomain.getResourceSet().getResource(fileURI, true); - assertNotNull("The modeling bot resource can not be loaded.", resource); - return resource; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#runModelingBot(java.lang.String, - * org.eclipse.emf.eef.modelingBot.IModelingBot) - */ - public void runModelingBot(String path) throws CoreException, IOException { - final Resource modelingBotResource = loadModel(path); - EcoreUtil.resolveAll(modelingBotResource.getResourceSet()); - assertFalse("The modeling bot resource is empty.", modelingBotResource.getContents().isEmpty()); - assertTrue("The modeling bot model contains errors, correct them first", modelingBotResource - .getErrors().isEmpty()); - final ModelingBot mbot = (ModelingBot)modelingBotResource.getContents().get(0); - final Diagnostic diag = Diagnostician.INSTANCE.validate(mbot); - if (diag.getSeverity() != Diagnostic.OK) { - displayDiag(diag); - } - assertTrue("The modeling bot model contains errors, correct them first", - diag.getSeverity() == Diagnostic.OK); - assertNotNull("The modeling bot resource is empty.", mbot); - propertiesEditionContext = mbot.getPropertiesEditionContext(); - for (Sequence sequence : mbot.getSequences()) { - if (sequence instanceof Scenario) { - final Scenario scenario = (Scenario)sequence; - runSequence(scenario); - } - } - } - - private void displayDiag(final Diagnostic diag) { - System.out.println("Source: " + diag.getSource() + " - Message: " + diag.getMessage() + " - Ex:" + diag.getException()); - for (Diagnostic subDiag : diag.getChildren()) { - displayDiag(subDiag); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#runSequence(org.eclipse.emf.eef.modelingBot.Sequence) - */ - public void runSequence(Sequence sequence) { - preProcessing(sequence); - for (Processing processing : sequence.getProcessings()) { - if (processing instanceof Action) { - runAction((Action)processing); - } else if (processing instanceof DetailsPage) { - bot.setSequenceType(SequenceType.DETAILS_PAGE); - runSequence((DetailsPage)processing); - } else if (processing instanceof PropertiesView) { - bot.setSequenceType(SequenceType.PROPERTIES_VIEW); - runSequence((PropertiesView)processing); - } else if (processing instanceof Wizard) { - bot.setSequenceType(SequenceType.WIZARD); - runSequence((Wizard)processing); - } - - } - postProcessing(sequence); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#preProcessing(org.eclipse.emf.eef.modelingBot.Sequence) - */ - public void preProcessing(Sequence sequence) { - if (sequence instanceof Wizard) { - bot.initWizard((Wizard)sequence); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#postProcessing(org.eclipse.emf.eef.modelingBot.Sequence) - */ - public void postProcessing(Sequence sequence) { - if (sequence instanceof Wizard) { - final Boolean hasCanceled = mapSequenceToCancel.get(sequence); - if (hasCanceled == null || !hasCanceled) { - try { - bot.validateBatchEditing(); - } catch (WidgetNotFoundException e) { - // Cancel has been done - } - } - mapSequenceToCancel.remove(sequence); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#runAction(org.eclipse.emf.eef.modelingBot.Action) - */ - public void runAction(Action action) { - if (!processedActions.contains(action)) { - - if (action instanceof EditAction && EEFModelingBotHelper.isFollowingByCancel(action)) { - actionsToCancel.add(((EditAction)action).getPropertiesEditionElement()); -// if (bot instanceof SWTEEFBot) { -// processedActions.add(EEFModelingBotHelper.getFollowingCancelAction(action)); -// } - } - if (action instanceof CreateProject) { - bot.createProject(((CreateProject)action).getProjectName()); - } else if (action instanceof OpenEEFEditor) { - bot.openEEFEditor(((OpenEEFEditor)action).getEditorName()); - } else if (action instanceof OpenEditor) { - final EObject root = bot.openEditor(((OpenEditor)action).getEditorName()); - for (ReferenceableObject refObj : refObjectToEObjectMap.keySet()) { - if (refObj instanceof CreateModel) { - refObjectToEObjectMap.put(refObj, root); - } - } - } else if (action instanceof CreateModel) { - final EObject addedObject = bot.createModel(((CreateModel)action).getPath(), - ((CreateModel)action).getModelName(), ((CreateModel)action).getRoot()); - addModelMap((CreateModel)action, addedObject); - } else if (action instanceof Add) { - PropertiesEditionElement propertiesEditionElement = ((Add)action) - .getPropertiesEditionElement(); - if (propertiesEditionElement != null) { - final EObject addedObject = bot.add(propertiesEditionElement, - ((Add)action).getReferenceableObject(), (ReferenceableObject)action, - ((Add)action).getEContainingFeature(), ((Add)action).getType()); - if (addedObject != null) { - addActionMap((Add)action, addedObject); - } - } else { - final EObject addedObject = bot.add(propertiesEditionElement, null, - ((Add)action).getReferenceableObject(), ((Add)action).getEContainingFeature(), - ((Add)action).getType()); - if (addedObject != null) { - addActionMap((Add)action, addedObject); - } - } - } else if (action instanceof MoveDown) { - bot.moveDown(((MoveDown)action).getPropertiesEditionElement(), - ((MoveDown)action).getReferenceableObject()); - } else if (action instanceof MoveUp) { - bot.moveUp(((MoveUp)action).getPropertiesEditionElement(), - ((MoveUp)action).getReferenceableObject()); - } else if (action instanceof SetAttribute) { - bot.setAttribute(((SetAttribute)action).getPropertiesEditionElement(), - ((SetAttribute)action).getReferenceableObject(), - ((SetAttribute)action).getEContainingFeature(), ((SetAttribute)action).getValues()); - } else if (action instanceof SetReference) { - bot.setReference(((SetReference)action).getPropertiesEditionElement(), - ((SetReference)action).getReferenceableObject(), - ((SetReference)action).getEContainingFeature(), ((SetReference)action).getValues()); - } else if (action instanceof Save) { - bot.save(); - } else if (action instanceof CloseEditor) { - bot.closeEditor(((CloseEditor)action).getPath()); - } else if (action instanceof CloseProject) { - bot.closeProject(((CloseProject)action).getProjectName()); - } else if (action instanceof RemoveProject) { - bot.removeProject(((RemoveProject)action).getProjectName()); - } else if (action instanceof Cancel) { - Sequence eContainerSequence = (Sequence)action.eContainer(); - mapSequenceToCancel.put(eContainerSequence, true); - if (eContainerSequence instanceof Wizard || - ((eContainerSequence instanceof DetailsPage - || eContainerSequence instanceof PropertiesView) && !actionsToCancel.isEmpty())) { - bot.cancel(((Cancel)action).getProcessing()); - } - } else if (action instanceof Unset) { - bot.unset(((Unset)action).getPropertiesEditionElement(), - ((Unset)action).getReferenceableObject(), ((Unset)action).getFeature()); - } else if (action instanceof UnsetAttribute) { - bot.unsetAttribute(((UnsetAttribute)action).getPropertiesEditionElement(), - ((UnsetAttribute)action).getReferenceableObject(), - ((UnsetAttribute)action).getEContainingFeature(), - ((UnsetAttribute)action).getValues()); - } else if (action instanceof UnsetReference) { - bot.unsetReference(((UnsetReference)action).getPropertiesEditionElement(), - ((UnsetReference)action).getReferenceableObject(), - ((UnsetReference)action).getFeature(), ((UnsetReference)action).getValues()); - } else if (action instanceof Remove) { - bot.remove(((Remove)action).getPropertiesEditionElement(), - ((Remove)action).getReferenceableObject()); - refObjectToEObjectMap.remove(((Remove)action).getReferenceableObject()); - } else if (action instanceof Undo) { - bot.undo(action); - } else if (action instanceof Redo) { - bot.redo(action); - } - processedActions.add(action); - } - } - - private void addActionMap(ReferenceableObject action, EObject obj) { - refObjectToEObjectMap.put(action, obj); - } - - private void addModelMap(CreateModel action, EObject obj) { - refObjectToEObjectMap.put(action, obj); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter#getPropertiesEditionContext() - */ - public PropertiesEditionContext getPropertiesEditionContext() { - return propertiesEditionContext; - } - - /** - * @param pec - * the propertiesEditionContext to set - */ - public void setPropertiesEditionContext(PropertiesEditionContext pec) { - this.propertiesEditionContext = pec; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/IModelingBotInterpreter.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/IModelingBotInterpreter.java deleted file mode 100755 index 028e2d68d..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/interpreter/IModelingBotInterpreter.java +++ /dev/null @@ -1,73 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.interpreter; - -import java.io.IOException; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.eef.components.PropertiesEditionContext; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.Processing; -import org.eclipse.emf.eef.modelingBot.Sequence; - -/** - * @author Stephane Bouchet - */ -public interface IModelingBotInterpreter { - - /** - * Run the modeling bot : interprete the sequence and actions of the model. - * - * @param path - * @throws CoreException - * @throws IOException - */ - void runModelingBot(String path) throws CoreException, IOException; - - /** - * Run an action. - * - * @param action - * Action - */ - void runAction(Action action); - - /** - * Run a sequence. - * - * @param sequence - * Sequence - */ - void runSequence(Sequence sequence); - - /** - * Prepares the processing of a sequence. - * @param sequence {@link Sequence} to process. - */ - void preProcessing(Sequence sequence); - - /** - * Finishes the processing of a sequence. - * @param sequence {@link Sequence} to process. - */ - void postProcessing(Sequence sequence); - - /** - * @return the PropertiesEditionContext - */ - PropertiesEditionContext getPropertiesEditionContext(); - - /** - * @param context propertiesEditionContext to set - */ - void setPropertiesEditionContext(PropertiesEditionContext context); - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/menu/FirstContextMenuFinder.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/menu/FirstContextMenuFinder.java deleted file mode 100755 index 0d9f20053..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/menu/FirstContextMenuFinder.java +++ /dev/null @@ -1,119 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.modelingBot.menu; - -import java.util.ArrayList; -import java.util.LinkedHashSet; -import java.util.List; - -import org.eclipse.swt.SWT; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Event; -import org.eclipse.swt.widgets.Menu; -import org.eclipse.swt.widgets.MenuItem; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.swtbot.swt.finder.finders.ContextMenuFinder; -import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable; -import org.eclipse.swtbot.swt.finder.results.ListResult; -import org.hamcrest.Matcher; - -/** - * A context menu finder, which stops to search when he found one result. - * - * @author Nathalie Lepine - */ -public class FirstContextMenuFinder extends ContextMenuFinder { - - /** - * Constructs the context menu finder for the given control to be searched. - * - * @param control - * the control that has a context menu. - */ - public FirstContextMenuFinder(Control control) { - super(control); - } - - /** - * Finds all the menus using the given matcher in the set of shells - * provided. If recursive is set, it will attempt to find the controls - * recursively in each of the menus it that is found. - * - * @param shells - * the shells to probe for menus. - * @param matcher - * the matcher that can match menus and menu items. - * @param recursive - * if set to true, will find sub-menus as well. - * @return all menus in the specified shells that match the matcher. - */ - public List findMenus(Shell[] shells, Matcher matcher, boolean recursive) { - LinkedHashSet result = new LinkedHashSet(); - for (Shell shell : shells) { - result.addAll(findMenus(shell, matcher, recursive)); - if (!result.isEmpty()) - break; - } - return new ArrayList(result); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.swtbot.swt.finder.finders.MenuFinder#findMenus(org.eclipse.swt.widgets.Menu, - * org.hamcrest.Matcher, boolean) - */ - public List findMenus(final Menu bar, final Matcher matcher, final boolean recursive) { - return UIThreadRunnable.syncExec(display, new ListResult() { - public List run() { - return findMenuInternal(bar, matcher, recursive); - } - }); - } - - /** - * @param bar - * @param matcher - * @param recursive - * @return - */ - private List findMenuInternal(final Menu bar, final Matcher matcher, final boolean recursive) { - LinkedHashSet result = new LinkedHashSet(); - if (bar != null) { - bar.notifyListeners(SWT.Show, new Event()); - MenuItem[] items = bar.getItems(); - for (MenuItem menuItem : items) { - if (isSeparator(menuItem)) { - continue; - } - if (matcher.matches(menuItem)) { - result.add(menuItem); - /* we found one, do not continue */ - break; - } - if (recursive) { - result.addAll(findMenuInternal(menuItem.getMenu(), matcher, recursive)); - if (!result.isEmpty()) - break; - } - - } - bar.notifyListeners(SWT.Hide, new Event()); - } - return new ArrayList(result); - } - - private boolean isSeparator(MenuItem menuItem) { - return (menuItem.getStyle() & SWT.SEPARATOR) != 0; - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/menu/SWTBotContextMenu.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/menu/SWTBotContextMenu.java deleted file mode 100755 index b83ece126..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/menu/SWTBotContextMenu.java +++ /dev/null @@ -1,93 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.modelingBot.menu; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.MenuItem; -import org.eclipse.swtbot.swt.finder.SWTBot; -import org.eclipse.swtbot.swt.finder.finders.ContextMenuFinder; -import org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory; -import org.eclipse.swtbot.swt.finder.waits.DefaultCondition; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotMenu; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem; -import org.hamcrest.Matcher; - -/** - * A context menu wrapper to handle click correctly. - * - * @author Nathalie Lepine - */ -public class SWTBotContextMenu { - - private Control control; - - /** - * . - * - * @param treeItem - * . - */ - public SWTBotContextMenu(final SWTBotTreeItem treeItem) { - this.control = treeItem.widget.getParent(); - - } - - /** - * . - * - * @param tree - * . - */ - public SWTBotContextMenu(final SWTBotTree tree) { - this.control = tree.widget; - } - - /** - * Click on the first menu item matching the text. - * - * @param text - * the text on the context menu. - * @return the context menu - */ - @SuppressWarnings("unchecked") - // varargs and generics doesn't mix well! - public SWTBotContextMenu click(final String text) { - Matcher withMnemonic = WidgetMatcherFactory.withMnemonic(text); - final Matcher matcher = WidgetMatcherFactory.allOf(WidgetMatcherFactory.widgetOfType(MenuItem.class), withMnemonic); - final ContextMenuFinder menuFinder = new FirstContextMenuFinder(control); - - final List items = new ArrayList(); - - new SWTBot().waitUntil(new DefaultCondition() { - public String getFailureMessage() { - return "Could not find context menu with text: " + text; //$NON-NLS-1$ - } - - public boolean test() throws Exception { - items.addAll(menuFinder.findMenus(matcher)); - return !items.isEmpty(); - } - }); - - MenuItem menuItem = items.get(0); - if (!menuItem.isDisposed()) { - new SWTBotMenu(menuItem, matcher).click(); - } else { - // do nothing or print something in debug - } - return this; - } -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/swtbot/ComposedEEFBot.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/swtbot/ComposedEEFBot.java deleted file mode 100755 index 2a2b45ecf..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/swtbot/ComposedEEFBot.java +++ /dev/null @@ -1,392 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.swtbot; - -import static org.junit.Assert.assertTrue; -import static org.junit.Assert.fail; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collection; -import java.util.HashMap; -import java.util.HashSet; -import java.util.List; -import java.util.Map; -import java.util.Set; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.compare.diff.metamodel.DiffGroup; -import org.eclipse.emf.compare.diff.metamodel.DiffModel; -import org.eclipse.emf.compare.diff.service.DiffService; -import org.eclipse.emf.compare.match.metamodel.MatchModel; -import org.eclipse.emf.compare.match.service.MatchService; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.IModelingBot; -import org.eclipse.emf.eef.modelingBot.Processing; -import org.eclipse.emf.eef.modelingBot.SequenceType; -import org.eclipse.emf.eef.modelingBot.Wizard; -import org.eclipse.emf.eef.modelingBot.interpreter.ComposedEEFInterpreter; -import org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter; -import org.eclipse.emf.eef.modelingBot.uri.EEFURIConverter; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -/** - * Composed eef bot : SWTEEFbot and BatchModeling bot. - * - * @author Nathalie Lepine - */ -public class ComposedEEFBot implements IModelingBot { - - /** - * The ResourceSet where to operate. - */ - protected EditingDomain editingDomain = new AdapterFactoryEditingDomain(EEFRuntimePlugin.getDefault() - .getAdapterFactory(), new BasicCommandStack()); - - /** - * Composed eef interpreter. - */ - private ComposedEEFInterpreter interpreter; - - /** - * Bots Collection. - */ - private Collection bots; - - public ComposedEEFBot(Collection bots) { - super(); - this.bots = bots; - editingDomain.getResourceSet().setURIConverter(new EEFURIConverter()); - final List list = new ArrayList(); - list.addAll(bots); - list.add(this); - interpreter = new ComposedEEFInterpreter(list, editingDomain); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#runModelingBot(java.lang.String) - */ - public void runModelingBot(String path) throws CoreException, IOException { - interpreter.runModelingBot(path); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#createProject(java.lang.String) - */ - public void createProject(String projectName) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#openProject(java.lang.String) - */ - public void openProject(String projectName) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#closeProject(java.lang.String) - */ - public void closeProject(String projectName) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#removeProject(java.lang.String) - */ - public void removeProject(String projectName) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#openPerspective(java.lang.String) - */ - public void openPerspective(String name) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#openEEFEditor(java.lang.String) - */ - public void openEEFEditor(String path) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#closeEditor(java.lang.String) - */ - public void closeEditor(String path) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#save() - */ - public void save() { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#add(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * org.eclipse.emf.ecore.EClass) - */ - public EObject add(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, EClass type) { - // do nothing - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#remove(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject) - */ - public void remove(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#setAttribute(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * java.util.Collection) - */ - public void setAttribute(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#setReference(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * java.util.Collection) - */ - public void setReference(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#unset(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature) - */ - public void unset(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#createModel(java.lang.String, java.lang.String, - * org.eclipse.emf.ecore.EClass) - */ - public EObject createModel(String path, String modelName, EClass eClass) { - // do nothing - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#cancel() - */ - public void cancel(Processing processing) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#setSequenceType(org.eclipse.emf.eef.modelingBot.SequenceType) - */ - public void setSequenceType(SequenceType sequenceType) { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#validateBatchEditing() - */ - public void validateBatchEditing() { - // do nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#check() - */ - public void check() { - for (IModelingBot bot : bots) { - bot.check(); - } - for (int i = 0; i < bots.size(); i++) { - for (int j = i + 1; j < bots.size(); j++) { - try { - assertExpectedModelReached(((IModelingBot)bots.toArray()[i]).getActiveResource(), - ((IModelingBot)bots.toArray()[j]).getActiveResource()); - } catch (InterruptedException e) { - fail("Error during model comparison."); - } - } - } - } - - public void assertExpectedModelReached(Resource expectedModel, Resource batchModel) - throws InterruptedException { - final Map options = new HashMap(); - options.put(org.eclipse.emf.compare.match.MatchOptions.OPTION_IGNORE_XMI_ID, Boolean.TRUE); - options.put(org.eclipse.emf.compare.match.MatchOptions.OPTION_DISTINCT_METAMODELS, Boolean.TRUE); - final MatchModel match = MatchService.doResourceMatch(batchModel, expectedModel, options); - final DiffModel diff = DiffService.doDiff(match); - final List diffList = EEFUtils.asEObjectList(diff.eAllContents()); - final Collection result = filterAbnormalDiffElement(diffList); - if (!result.isEmpty()) { - System.out.println(result); - } - assertTrue("The active model isn't the same that the expected model.", result.isEmpty()); - } - - /** - * TODO: check this with the EMF Compare team - * - * @param diffList - * the list to filter - * @return the list of "good" diff - */ - private Collection filterAbnormalDiffElement(List diffList) { - final Set result = new HashSet(); - for (EObject object : diffList) { - if (!(object instanceof DiffGroup)) - result.add(object); - else if (object.eContents().size() > 0) - result.addAll(filterAbnormalDiffElement(object.eContents())); - } - return result; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#getActiveResource() - */ - public Resource getActiveResource() { - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#getModelingBotInterpreter() - */ - public IModelingBotInterpreter getModelingBotInterpreter() { - return interpreter; - } - - public EObject add(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObjectContainer, ReferenceableObject referenceableObject, - EStructuralFeature eContainingFeature, EClass type) { - // do nothing - return null; - } - - public void unsetAttribute(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - // do nothing - - } - - public void unsetReference(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - // do nothing - - } - - public EObject openEditor(String path) { - // nothing to do - return null; - } - - public void undo(Action action) { - // do nothing - - } - - public void redo(Action action) { - // do nothing - - } - - public void initWizard(Wizard wizard) { - // do nothing - - } - - public void closeWizard(Wizard wizard) { - // do nothing - - } - - public void moveUp(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject) { - // do nothing - } - - public void moveDown(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject) { - // do nothing - } - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/swtbot/SWTEEFBot.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/swtbot/SWTEEFBot.java deleted file mode 100755 index 3d77160fe..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/swtbot/SWTEEFBot.java +++ /dev/null @@ -1,1456 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.modelingBot.swtbot; - -import static org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable.syncExec; -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNotNull; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.eef.components.PropertiesEditionComponent; -import org.eclipse.emf.eef.components.PropertiesEditionElement; -import org.eclipse.emf.eef.extended.editor.ReferenceableObject; -import org.eclipse.emf.eef.modelingBot.Action; -import org.eclipse.emf.eef.modelingBot.IModelingBot; -import org.eclipse.emf.eef.modelingBot.Processing; -import org.eclipse.emf.eef.modelingBot.SequenceType; -import org.eclipse.emf.eef.modelingBot.Wizard; -import org.eclipse.emf.eef.modelingBot.EEFActions.EditAction; -import org.eclipse.emf.eef.modelingBot.helper.EEFModelHelper; -import org.eclipse.emf.eef.modelingBot.helper.EMFHelper; -import org.eclipse.emf.eef.modelingBot.helper.PropertiesEditionHelper; -import org.eclipse.emf.eef.modelingBot.helper.SWTBotHelper; -import org.eclipse.emf.eef.modelingBot.helper.SWTEEFBotHelper; -import org.eclipse.emf.eef.modelingBot.helper.StringHelper; -import org.eclipse.emf.eef.modelingBot.helper.UIConstants; -import org.eclipse.emf.eef.modelingBot.interpreter.EEFInterpreter; -import org.eclipse.emf.eef.modelingBot.interpreter.IModelingBotInterpreter; -import org.eclipse.emf.eef.modelingBot.uri.EEFURIConverter; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.views.ElementEditor; -import org.eclipse.emf.eef.views.View; -import org.eclipse.swt.SWT; -import org.eclipse.swt.widgets.Table; -import org.eclipse.swt.widgets.TableItem; -import org.eclipse.swtbot.eclipse.finder.SWTWorkbenchBot; -import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotEditor; -import org.eclipse.swtbot.swt.finder.SWTBot; -import org.eclipse.swtbot.swt.finder.keyboard.KeyboardFactory; -import org.eclipse.swtbot.swt.finder.results.IntResult; -import org.eclipse.swtbot.swt.finder.results.Result; -import org.eclipse.swtbot.swt.finder.waits.Conditions; -import org.eclipse.swtbot.swt.finder.waits.DefaultCondition; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotButton; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotCTabItem; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotMenu; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotRadio; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotShell; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTable; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTableItem; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotText; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.internal.ide.IDEWorkbenchMessages; - -/** - * SWTBot bor for EEF editor. - * - * @author Nathalie Lepine - */ -public class SWTEEFBot extends SWTWorkbenchBot implements IModelingBot { - - /** - * The ResourceSet where to operate. - */ - protected EditingDomain editingDomain = new AdapterFactoryEditingDomain(EEFRuntimePlugin.getDefault() - .getAdapterFactory(), new BasicCommandStack()); - - /** - * EEF Interpreter. - */ - private EEFInterpreter interpreter; - - /** - * The swtbot editor. - */ - private SWTBotEditor editor; - - /** - * The test model resource. - */ - private Resource testModelResource; - - /** - * Helper to edit feature. - */ - private PropertiesEditionHelper propertiesEdition; - - /** - * Sequence type : wizard, detail page, properties view... - */ - private SequenceType sequenceType; - - /** - * Bot Helper. - */ - private SWTEEFBotHelper helper; - - /** - * Editor editing domain - */ - private EditingDomain editorEditingDomain; - - /** - * Create a SWTEEFBot. - */ - public SWTEEFBot() { - super(); - editingDomain.getResourceSet().setURIConverter(new EEFURIConverter()); - interpreter = new EEFInterpreter(this, editingDomain); - propertiesEdition = new PropertiesEditionHelper(this); - helper = new SWTEEFBotHelper(this); - } - - /** - * Open the properties view. - */ - public void openPropertiesView() { - menu(UIConstants.WINDOW_MENU).menu(UIConstants.SHOW_VIEW_MENU).menu(UIConstants.OTHER_MENU).click(); - - final SWTBotShell shell = shell(UIConstants.SHOW_VIEW_MENU); - activateShell(shell); - - final SWTBotTree viewSelectionTree = tree(); - viewSelectionTree.expandNode(UIConstants.GENERAL_MENU).select(UIConstants.PROPERTIES_VIEW_NAME); - button(UIConstants.OK_BUTTON).click(); - waitUntil(Conditions.shellCloses(shell)); - } - - /** - * Open Java Perspective. - */ - public void openJavaPerspective() { - menu(UIConstants.WINDOW_MENU) - .menu(UIConstants.OPEN_PERSPECTIVE_MENU) - .menu(UIConstants.OTHER_MENU) - .click(); - final SWTBotShell openPerspectiveShell = shell(UIConstants.OPEN_PERSPECTIVE_MENU); - activateShell(openPerspectiveShell); - - try { - table().select(UIConstants.JAVA_LABEL); - } catch (IllegalArgumentException e) { - table().select(UIConstants.JAVA_DEFAULT_LABEL); - } - button(UIConstants.OK_BUTTON).click(); - } - - /** - * Activate the shell. - * - * @param shell - * SWTBotShell - */ - public void activateShell(SWTBotShell shell) { - shell.activate(); - } - - /** - * This method close the welcome page if we use the workspace of test for the first time. - */ - public void closeWelcomePage() { - closeAllEditors(); - assertNotNull(activeView()); - if (UIConstants.WELCOME_LABEL.equals(activeView().getTitle())) - viewByTitle(UIConstants.WELCOME_LABEL).close(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#createProject(java.lang.String) - */ - public void createProject(String projectName) { - activateShell(shells()[0]); - menu(UIConstants.FILE_MENU).menu(UIConstants.PROJECT_MENU).click(); - final SWTBotShell openProjectShell = shell(UIConstants.NEW_PROJECT_MENU); - activateShell(openProjectShell); - - tree().expandNode(UIConstants.GENERAL_MENU).select(UIConstants.PROJECT_CREATION_MENU); - button(UIConstants.NEXT_BUTTON).click(); - text().setText(projectName); - button(UIConstants.FINISH_BUTTON).click(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#openProject(java.lang.String) - */ - public void openProject(String projectName) { - final SWTBotTreeItem treeItem = selectInProjectExplorer(projectName); - SWTBotHelper.clickContextMenu(treeItem, UIConstants.OPEN_PROJECT_MENU); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#closeProject(java.lang.String) - */ - public void closeProject(String projectName) { - final SWTBotTreeItem treeItem = selectInProjectExplorer(projectName); - SWTBotHelper.clickContextMenu(treeItem, UIConstants.CLOSE_PROJECT_MENU); - editorEditingDomain = null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#removeProject(java.lang.String) - */ - public void removeProject(String projectName) { - final SWTBotTreeItem treeItem = selectInProjectExplorer(projectName); - SWTBotHelper.clickContextMenu(treeItem, UIConstants.DELETE_MENU); - waitUntil(Conditions.shellIsActive(UIConstants.DELETE_RESOURCES_DIALOG)); - final SWTBotShell deleteResourcesShell = shell(UIConstants.DELETE_RESOURCES_DIALOG); - SWTBot deleteResourcesBot = deleteResourcesShell.bot(); - deleteResourcesBot.checkBox().select(); - deleteResourcesBot.button(UIConstants.OK_BUTTON).click(); - waitUntil(Conditions.shellCloses(deleteResourcesShell)); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#openPerspective(java.lang.String) - */ - public void openPerspective(String name) { - menu(UIConstants.WINDOW_MENU).menu(UIConstants.OPEN_PERSPECTIVE_MENU).menu(UIConstants.OTHER_MENU) - .click(); - final SWTBotShell openPerspectiveShell = shell(UIConstants.OPEN_PERSPECTIVE_MENU); - activateShell(openPerspectiveShell); - - try { - table().select(name); - } catch (IllegalArgumentException e) { - table().select(UIConstants.JAVA_DEFAULT_LABEL); - } - button(UIConstants.OK_BUTTON).click(); - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#openEEFEditor(java.lang.String) - */ - public void openEEFEditor(String path) { - final SWTBotTreeItem treeItem = selectInProjectExplorer(path); - SWTBotHelper.clickContextMenu(treeItem, UIConstants.INTERACTIVE_EEF_EDITOR_MENU); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#openEditor(java.lang.String) - */ - public EObject openEditor(String path) { - final SWTBotTreeItem treeItem = selectInProjectExplorer(path); - SWTBotHelper.clickContextMenu(treeItem, "Open"); - String splittedPath[] = path.split("/"); - editor = editorByTitle(splittedPath[1]); - getEditorEditingDomain(); - return getRoot(splittedPath[0], splittedPath[1]); - } - - private SWTBotTreeItem selectInProjectExplorer(String path) { - final SWTBotTree wizardTree = viewByTitle(UIConstants.PACKAGE_EXPLORER_VIEW_NAME).bot().tree(); - final String[] split = path.split("/"); - SWTBotTreeItem treeItem = wizardTree.expandNode(split[0]).select(); - for (int i = 1; i < split.length; i++) { - treeItem = treeItem.expandNode(split[i]).select(); - } - return treeItem; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#closeEditor(java.lang.String) - */ - public void closeEditor(String path) { - selectInProjectExplorer(path); - menu(UIConstants.FILE_MENU).menu(UIConstants.CLOSE_MENU).click(); - editorEditingDomain = null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#save() - */ - public void save() { - SWTBotHelper.waitAllUiEvents(); - // sleep(1000); - // (UIConstants.FILE_MENU).menu(UIConstants.SAVE_MENU).click(); - KeyboardFactory.getSWTKeyboard().pressShortcut(SWT.CTRL, 's'); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#add(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * org.eclipse.emf.ecore.EClass) - */ - public EObject add(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObjectContainer, ReferenceableObject referenceableObject, - final EStructuralFeature eContainingFeature, EClass type) { - if (propertiesEditionElement != null) { - // work on table composition - return add(propertiesEditionElement, referenceableObjectContainer, referenceableObject); - } else { - // work on context menu - return add(referenceableObject, eContainingFeature, type); - } - - } - - /** - * Add PropertiesEditionElement. - * - * @param propertiesEditionElement - * @param referenceableObject - * @return - */ - private EObject add(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObjectContainer, ReferenceableObject referenceableObject) { - SWTBotHelper.waitAllUiEvents(); - assertNotNull("The editor is not opened.", editor); - EObject container = null; - container = getEObjectFromReferenceableEObject(referenceableObjectContainer); - assertNotNull("No container is found to launch wizard.", container); - SWTBotHelper.waitAllUiEvents(); - assertFalse("The set action must be define in a sequence.", sequenceType == null); - if (sequenceType.equals(SequenceType.PROPERTIES_VIEW)) { - final SWTBotTreeItem selectNode = selectNode(editor, container); - assertNotNull("No element is selected in the editor", selectNode); - initPropertiesViewTab(propertiesEditionElement, selectNode); - } else if (sequenceType.equals(SequenceType.WIZARD)) { - initTab(propertiesEditionElement); - } - propertiesEdition.addFeature(null, propertiesEditionElement, referenceableObject, sequenceType); - SWTBotHelper.waitAllUiEvents(); - return (EObject)EEFModelHelper.eGet(container, propertiesEditionElement.getModel()); - } - - /** - * Add ReferenceableObject. - * - * @param referenceableObject - * @param eContainingFeature - * @return - */ - private EObject add(ReferenceableObject referenceableObject, final EStructuralFeature eContainingFeature, - EClass type) { - assertNotNull("The editeur is not opened.", editor); - final EObject container = getEObjectFromReferenceableEObject(referenceableObject); - assertNotNull("No container is found to launch add action.", container); - final SWTBotTreeItem selectNode = selectNode(editor, container); - assertNotNull("No element is selected in the editor", selectNode); - String text = EMFHelper.getCreateChildLabel(editingDomain, type, container); - SWTBotHelper.clickContextMenu(selectNode, text); - SWTBotHelper.waitAllUiEvents(); - return (EObject)EEFModelHelper.eGet(container, eContainingFeature); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#remove(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject) - */ - public void remove(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject) { - if (propertiesEditionElement != null) { - // work on table composition - removePropertiesEditionElement(propertiesEditionElement, referenceableObject); - } else { - // work on context menu - remove(referenceableObject); - } - } - - /** - * Remove propertiesEditionElement. - * - * @param propertiesEditionElement - * @param referenceableObject - */ - private void removePropertiesEditionElement(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject) { - SWTBotHelper.waitAllUiEvents(); - assertNotNull("The editor is not opened.", editor); - final EObject remove = getEObjectFromReferenceableEObject(referenceableObject); - assertNotNull("Element to remove does not exist.", remove); - final EObject container = remove.eContainer(); - assertNotNull("The container of the element to remove does not exist.", container); - SWTBotHelper.waitAllUiEvents(); - final SWTBotTreeItem selectNode = selectNode(editor, container); - assertNotNull("No element is selected in the editor", selectNode); - initTab(propertiesEditionElement); - assertFalse("The set action must be define in a sequence.", sequenceType == null); - propertiesEdition.removeFeature(remove, propertiesEditionElement, sequenceType); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * Remove referenceableObject. - * - * @param referenceableObject - */ - private void remove(ReferenceableObject referenceableObject) { - assertNotNull("The editor is not opened.", editor); - final EObject container = getEObjectFromReferenceableEObject(referenceableObject); - assertNotNull("No container is found to launch add action.", container); - final SWTBotTreeItem selectNode = selectNode(editor, container); - assertNotNull("No element is selected in the editor", selectNode); - SWTBotHelper.clickContextMenu(selectNode, UIConstants.DELETE_MENU); - SWTBotHelper.waitAllUiEvents(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#setAttribute(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * java.util.Collection) - */ - public void setAttribute(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - SWTBotHelper.waitAllUiEvents(); - assertNotNull("The properties edition element is not set.", propertiesEditionElement); - assertNotNull("The editor is not opened.", editor); - SWTBotHelper.waitAllUiEvents(); - assertNotNull("The set action must be define in a sequence.", sequenceType); - if (sequenceType.equals(SequenceType.DETAILS_PAGE)) { - final EObject container = getEObjectFromReferenceableEObject(referenceableObject); - assertNotNull("No container is found to launch add action.", container); - final SWTBotTreeItem selectNode = selectNode(editor, container); - assertNotNull("No element is selected in the editor", selectNode); - initTab(propertiesEditionElement); - propertiesEdition.updateAttribute(selectNode, propertiesEditionElement, referenceableObject, - container, values, sequenceType); - } else if (sequenceType.equals(SequenceType.WIZARD)) { - EObject containerOfcontainer = null; - if (((EditAction)referenceableObject).getPropertiesEditionElement() != null) { - containerOfcontainer = getEObjectFromReferenceableEObject(((EditAction)referenceableObject) - .getReferenceableObject()); - } else { - containerOfcontainer = getEObjectFromReferenceableEObject(referenceableObject); - } - assertNotNull("No container is found to launch add action.", containerOfcontainer); - initTab(propertiesEditionElement); - propertiesEdition.updateAttribute(null, propertiesEditionElement, referenceableObject, - containerOfcontainer, values, sequenceType); - } - } - - /** - * Select the tab defined in the PEE. - * - * @param propertiesEditionElement - * PropertiesEditionElement - */ - protected void initPropertiesViewTab(PropertiesEditionElement propertiesEditionElement, - SWTBotTreeItem selectNode) { - assertFalse(propertiesEditionElement.getViews().isEmpty()); - if (EEFModelHelper.getComponent(propertiesEditionElement).getViews().size() > 1) { - final ElementEditor elementEditor = propertiesEditionElement.getViews().get(0); - final View view = EEFModelHelper.getView(elementEditor); - if (view.getName() != null) { - if (selectNode.getText().equals(view.getName())) { - SWTBotHelper.selectPropertyTabItem("Base"); - } else { - SWTBotHelper.selectPropertyTabItem(view.getName()); - } - } - } - } - - /** - * Select the tab defined in the PEE. - * - * @param propertiesEditionElement - * PropertiesEditionElement - */ - protected void initTab(PropertiesEditionElement propertiesEditionElement) { - assertFalse(propertiesEditionElement.getViews().isEmpty()); - if (EEFModelHelper.getComponent(propertiesEditionElement).getViews().size() > 1) { - final ElementEditor elementEditor = propertiesEditionElement.getViews().get(0); - final View view = EEFModelHelper.getView(elementEditor); - if (view.getName() != null) { - String tabToSearch = view.getName(); - if (view.getName().equals(((PropertiesEditionComponent)propertiesEditionElement.eContainer()).getName())) { - tabToSearch = "Base"; - } - SWTBotCTabItem cTabItem = cTabItem(tabToSearch); - cTabItem.activate(); - cTabItem.setFocus(); - } - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#setReference(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * java.util.Collection) - */ - public void setReference(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - SWTBotHelper.waitAllUiEvents(); - assertNotNull("The properties edition element is not set.", propertiesEditionElement); - assertNotNull("The editor is not opened.", editor); - SWTBotHelper.waitAllUiEvents(); - assertFalse("The set action must be define in a sequence.", sequenceType == null); - if (sequenceType.equals(SequenceType.DETAILS_PAGE)) { - final EObject container = getEObjectFromReferenceableEObject(referenceableObject); - assertNotNull("No container is found to launch set ref action.", container); - final SWTBotTreeItem selectNode = selectNode(editor, container); - assertNotNull("No element is selected in the editor", selectNode); - final Collection objectsToSet = new ArrayList(); - for (ReferenceableObject value : values) { - objectsToSet.add(getEObjectFromReferenceableEObject(value)); - } - initTab(propertiesEditionElement); - propertiesEdition.updateFeature(selectNode, propertiesEditionElement, referenceableObject, - objectsToSet, sequenceType); - } else if (sequenceType.equals(SequenceType.WIZARD)) { - final Collection objectsToSet = new ArrayList(); - for (ReferenceableObject value : values) { - objectsToSet.add(getEObjectFromReferenceableEObject(value)); - } - initTab(propertiesEditionElement); - propertiesEdition.updateFeature(null, propertiesEditionElement, referenceableObject, - objectsToSet, sequenceType); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#unset(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature) - */ - public void unset(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature) { - SWTBotHelper.waitAllUiEvents(); - assertNotNull("The properties edition element is not set.", propertiesEditionElement); - assertNotNull("The editor is not opened.", editor); - assertFalse(propertiesEditionElement.getViews().isEmpty()); - final ElementEditor elementEditor = propertiesEditionElement.getViews().get(0); - final String representationName = elementEditor.getRepresentation().getName(); - if ("Text".equals(representationName) || "Textarea".equals(representationName)) { - setAttribute(propertiesEditionElement, referenceableObject, eContainingFeature, - Collections.singletonList("")); - } else if ("EObjectFlatComboViewer".equals(representationName)) { - propertiesEdition.unsetEObjectFlatComboViewer(elementEditor, Collections. emptyList()); - } else if ("MultiValuedEditor".equals(representationName)) { - propertiesEdition.unsetMultiValuedEditor(propertiesEditionElement, null, sequenceType); - } else if ("AdvancedEObjectFlatComboViewer".equals(representationName)) { - propertiesEdition.unsetAdvancedEObjectFlatComboViewer(elementEditor); - } else if ("ReferencesTable".equals(representationName)) { - propertiesEdition.unsetReferencesTable(elementEditor, null); - } else if ("AdvancedReferencesTable".equals(representationName)) { - unsetAdvancedReferencesTable(propertiesEditionElement, referenceableObject, eContainingFeature); - } else if ("FlatReferencesTable".equals(representationName)) { - propertiesEdition.unsetFlatReferencesTable(propertiesEditionElement, null); - } else if ("Combo".equals(representationName)) { - final EObject container = getEObjectFromReferenceableEObject((ReferenceableObject)referenceableObject); - assertNotNull("No container is found to launch add action.", container); - propertiesEdition.unsetCombo(propertiesEditionElement, referenceableObject, container, - sequenceType); - } else { - System.out.println("Case not managed in unset : " + representationName); - } - SWTBotHelper.waitAllUiEvents(); - - } - - /** - * unsets AdvancedReferencesTable. - * - * @param propertiesEditionElement - * @param referenceableObject - * @param eContainingFeature - */ - public void unsetAdvancedReferencesTable(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature) { - final ElementEditor elementEditor = propertiesEditionElement.getViews().get(0); - if (sequenceType.equals(SequenceType.DETAILS_PAGE)) { - propertiesEdition.unsetAdvancedReferencesTable(elementEditor, null); - } else if (sequenceType.equals(SequenceType.WIZARD)) { - initTab(propertiesEditionElement); - propertiesEdition.unsetAdvancedReferencesTable(elementEditor, null); - } - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#unsetAttribute(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * java.util.Collection) - */ - public void unsetAttribute(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - SWTBotHelper.waitAllUiEvents(); - assertNotNull("The properties edition element is not set.", propertiesEditionElement); - assertNotNull("The editor is not opened.", editor); - assertFalse(propertiesEditionElement.getViews().isEmpty()); - if (sequenceType.equals(SequenceType.DETAILS_PAGE)) { - final EObject container = getEObjectFromReferenceableEObject(referenceableObject); - assertNotNull("No container is found to launch add action.", container); - final SWTBotTreeItem selectNode = selectNode(editor, container); - assertNotNull("No element is selected in the editor", selectNode); - initTab(propertiesEditionElement); - propertiesEdition.unsetAttribute(propertiesEditionElement, referenceableObject, container, - values, sequenceType); - } else if (sequenceType.equals(SequenceType.WIZARD)) { - EObject containerOfcontainer = null; - if (((EditAction)referenceableObject).getPropertiesEditionElement() != null) { - containerOfcontainer = getEObjectFromReferenceableEObject(((EditAction)referenceableObject) - .getReferenceableObject()); - } else { - containerOfcontainer = getEObjectFromReferenceableEObject(referenceableObject); - } - assertNotNull("No container is found to launch unset attribute action.", containerOfcontainer); - initTab(propertiesEditionElement); - propertiesEdition.unsetAttribute(propertiesEditionElement, referenceableObject, - containerOfcontainer, values, sequenceType); - } - SWTBotHelper.waitAllUiEvents(); - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#unsetReference(org.eclipse.emf.eef.components.PropertiesEditionElement, - * org.eclipse.emf.eef.extended.editor.ReferenceableObject, org.eclipse.emf.ecore.EStructuralFeature, - * java.util.Collection) - */ - public void unsetReference(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject, EStructuralFeature eContainingFeature, - Collection values) { - SWTBotHelper.waitAllUiEvents(); - assertNotNull("The properties edition element is not set.", propertiesEditionElement); - assertNotNull("The editor is not opened.", editor); - assertFalse(propertiesEditionElement.getViews().isEmpty()); - if (sequenceType.equals(SequenceType.DETAILS_PAGE)) { - final Collection objectsToUnset = new ArrayList(); - for (ReferenceableObject value : values) { - objectsToUnset.add(getEObjectFromReferenceableEObject(value)); - } - initTab(propertiesEditionElement); - propertiesEdition.unsetReference(propertiesEditionElement, referenceableObject, objectsToUnset, - sequenceType); - } else if (sequenceType.equals(SequenceType.WIZARD)) { - Collection objectsToUnset = new ArrayList(); - for (ReferenceableObject value : values) { - objectsToUnset.add(getEObjectFromReferenceableEObject(value)); - } - initTab(propertiesEditionElement); - propertiesEdition.unsetReference(propertiesEditionElement, referenceableObject, objectsToUnset, - sequenceType); - } - SWTBotHelper.waitAllUiEvents(); - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#runModelingBot(java.lang.String) - */ - public void runModelingBot(String path) throws CoreException, IOException { - interpreter.runModelingBot(path); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#createModel(java.lang.String, java.lang.String, - * org.eclipse.emf.ecore.EClass) - */ - public EObject createModel(String path, String modelName, EClass root) { - final String[] split = modelName.split("\\."); - final String extension = split[split.length - 1]; - - selectInProjectExplorer(path); - - menu(UIConstants.FILE_MENU).menu(UIConstants.OTHER_MENU).click(); - final SWTBotShell newFileShell = shell(UIConstants.NEW); - activateShell(newFileShell); - - createModel(modelName, root, extension); - - // close the default editor - menu(UIConstants.FILE_MENU).menu(UIConstants.CLOSE_MENU).click(); - - // open with EEF Editor - openWithEEFEditor(path, modelName); - - editor = editorByTitle(modelName); - getEditorEditingDomain(); - - return getRoot(path, modelName); - } - - protected EditingDomain getEditorEditingDomain() { - if (editor != null) { - IEditorPart editorPart = editor.getReference().getEditor(true); - if (editorPart instanceof IEditingDomainProvider) { - editorEditingDomain = ((IEditingDomainProvider) editorPart).getEditingDomain(); - } - } - return editorEditingDomain; - } - - /** - * @param path - * @param modelName - * @return the root of the new resource - */ - private EObject getRoot(String path, String modelName) { - final URI fileURI = URI.createPlatformResourceURI(path + "/" + modelName, true); - Resource resource = editingDomain.getResourceSet().getResource(fileURI, true); - setTestModelResource(resource); - final SWTBotTreeItem modelTreeItem = editor.bot().tree() - .getTreeItem(testModelResource.getURI().toString()); - - resource = (Resource)syncExec(new Result() { - - public Object run() { - return modelTreeItem.widget.getData(); - } - }); - setTestModelResource(resource); - assertFalse("The model is empty.", resource.getContents().isEmpty()); - return resource.getContents().get(0); - } - - /** - * Open eef editor. - * - * @param path - * @param modelName - */ - private void openWithEEFEditor(String path, String modelName) { - final SWTBotTree wizardTree = viewByTitle(UIConstants.PACKAGE_EXPLORER_VIEW_NAME).bot().tree(); - final SWTBotTreeItem treeItem = wizardTree.expandNode(path).expandNode(modelName).select(); - SWTBotHelper.clickContextMenu(treeItem, UIConstants.OPEN_WITH_INTERACTIVE_EEF_EDITOR_MENU); - } - - /** - * Create the new model. - * - * @param modelName - * @param root - * @param extension - */ - private void createModel(String modelName, EClass root, final String extension) { - final String modelType = StringHelper.toU1Case(extension) + " Model"; - final SWTBotTreeItem item = tree().expandNode("EMF Editing Framework").expandNode("EMF Model") - .select(); - assertNotNull("The model " + modelType + " can not be created.", item); - button(UIConstants.NEXT_BUTTON).click(); - - button("Browse Registered Packages...").click(); - final String nsURI = interpreter.getPropertiesEditionContext().getModel().getEcorePackage() - .getNsURI(); - table().getTableItem(nsURI).select(); - button(UIConstants.OK_BUTTON).click(); - button(UIConstants.NEXT_BUTTON).click(); - - textWithLabel(IDEWorkbenchMessages.WizardNewFileCreationPage_fileLabel).setText(modelName); - button(UIConstants.NEXT_BUTTON).click(); - assertNotNull("The class " + root.toString() + " can not be loaded", root.getName()); - - comboBox().setSelection(root.getName()); - button(UIConstants.FINISH_BUTTON).click(); - } - - /** - * @param ref - * ReferenceableObject - * @return the object corresponding to the ReferenceableObject - */ - public EObject getEObjectFromReferenceableEObject(ReferenceableObject ref) { - return interpreter.getEObjectFromReferenceableEObject(ref); - } - - /** - * Select the given element in the given editor. - * - * @param editor - * the editor where the bot must process - * @param element - * the element to select - * @return the selected node - */ - public SWTBotTreeItem selectNode(SWTBotEditor editor, EObject element) { - assertNotNull("The model has not been initialized.", testModelResource); - final List expansionPath = EEFModelHelper.getExpansionPath(element); - final Iterator iterator = expansionPath.iterator(); - Object next = null; - SWTBotTreeItem node2 = editor.bot().tree().getTreeItem(testModelResource.getURI().toString()); - while (iterator.hasNext()) { - SWTBotHelper.waitAllUiEvents(); - sleep(1000); - node2.expand(); - next = iterator.next(); - node2 = selectSubNode(node2, next); - } - return node2; - } - - /** - * Select the given element in the given editor. - * - * @param editor - * the editor where the bot must process - * @param element - * the element to select - * @return the selected node - */ - public SWTBotTreeItem selectNode(SWTBotTree tree, EObject element) { - assertNotNull("The model has not been initialized.", testModelResource); - final List expansionPath = EEFModelHelper.getExpansionPath(element); - final Iterator iterator = expansionPath.iterator(); - Object next = null; - SWTBotTreeItem node2 = tree.getTreeItem(testModelResource.getURI().toString()); - while (iterator.hasNext()) { - node2.expand(); - next = iterator.next(); - node2 = selectSubNode(node2, next); - } - return node2; - } - - /** - * Select the object next as a subnode of the currentNode. - * - * @param currentNode - * the currentNode - * @param next - * the subnode to select - * @return the selected node - */ - private SWTBotTreeItem selectSubNode(SWTBotTreeItem currentNode, Object next) { - final AdapterFactory adapterFactory = EEFRuntimePlugin.getDefault().getAdapterFactory(); - final IItemLabelProvider labelProvider = (IItemLabelProvider)adapterFactory.adapt(next, - IItemLabelProvider.class); - final String text = labelProvider.getText(next); - final SWTBotTreeItem node2 = currentNode.getNode(text); - node2.select(); - return node2; - } - - /** - * Set the test model resource. - * - * @param resource - * Resource - */ - public void setTestModelResource(Resource resource) { - this.testModelResource = resource; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#getActiveResource() - */ - public Resource getActiveResource() { - return testModelResource; - } - - /** - * @param viewID - * the edited Radio ID - * @param mnemonicText - * the mnemonicText - * @return a {@link SWTBotRadio} with the specified viewID and mnemonicText. - */ - public SWTBotRadio radioWithIdAndMnemonic(String viewID, String mnemonicText) { - return helper.radioWithIdAndMnemonic(viewID, mnemonicText); - } - - /** - * @param viewID - * the edited MultiValuedEditor - * @return the browse button of the given MultiValuedEditor - */ - public SWTBotButton browseButtonMultiValuedEditor(String viewID) { - return helper.browseButtonMultiValuedEditor(viewID); - } - - /** - * @param viewID - * the edited AdvancedTableComposition - * @return the add button of the given AdvancedTableComposition - */ - public SWTBotButton addButtonAdvancedTableComposition(String viewID) { - return helper.addButtonAdvancedTableComposition(viewID); - } - - /** - * @param viewID - * the edited TableComposition - * @return the add button of the given TableComposition - */ - public SWTBotButton addButtonTableComposition(String viewID) { - return helper.addButtonTableComposition(viewID); - } - - /** - * @param viewID - * the edited AdvancedEOFCV - * @return the browse button of the given AdvancedEOFCV - */ - public SWTBotButton browseButtonAdvancedEObjectFlatComboViewer(String viewID) { - return helper.browseButtonAdvancedEObjectFlatComboViewer(viewID); - } - - /** - * @param viewID - * the edited EOFCV - * @return the edit button of the given EOFCV - */ - public SWTBotButton editButtonEObjectFlatComboViewer(String viewID) { - return helper.editButtonEObjectFlatComboViewer(viewID); - } - - /** - * @param viewID - * the edited AdvancedReferencesTable - * @return the add button of the given AdvancedReferencesTable - */ - public SWTBotButton addButtonAdvancedReferencesTable(String viewID) { - return helper.addButtonAdvancedReferencesTable(viewID); - } - - /** - * @param viewID - * the edited ReferencesTable - * @return the add button of the given ReferencesTable - */ - public SWTBotButton addButtonReferencesTable(String viewID) { - return helper.addButtonReferencesTable(viewID); - } - - /** - * @param viewID - * the edited FlatReferencesTable - * @return the browse button of the given FlatReferencesTable - */ - public SWTBotButton browseButtonFlatReferencesTable(String viewID) { - return helper.browseButtonFlatReferencesTable(viewID); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#cancel() - */ - public void cancel(Processing processing) { - button(UIConstants.CANCEL_BUTTON).click(); - } - - /** - * Dispose the interpreter. - */ - public void dispose() { - interpreter.dispose(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#validateBatchEditing() - */ - public void validateBatchEditing() { - button(UIConstants.FINISH_BUTTON).click(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#setSequenceType(org.eclipse.emf.eef.modelingBot.SequenceType) - */ - public void setSequenceType(SequenceType sequenceType) { - this.sequenceType = sequenceType; - } - - /** - * @param viewID - * the edited AdvancedTableComposition - * @return the remove button of the given AdvancedTableComposition - */ - public SWTBotButton removeButtonAdvancedTableComposition(String viewID) { - return helper.removeButtonAdvancedTableComposition(viewID); - } - - /** - * @param viewID - * the edited TableComposition - * @return the remove button of the given TableComposition - */ - public SWTBotButton removeButtonTableComposition(String viewID) { - return helper.removeButtonTableComposition(viewID); - } - - /** - * @param viewID - * the edited AdvancedReferencesTable - * @return the remove button of the given AdvancedReferencesTable - */ - public SWTBotButton removeButtonAdvancedReferencesTable(String viewID) { - return helper.removeButtonAdvancedReferencesTable(viewID); - } - - /** - * @param viewID - * the edited ReferencesTable - * @return the remove button of the given ReferencesTable - */ - public SWTBotButton removeButtonReferencesTable(String viewID) { - return helper.removeButtonReferencesTable(viewID); - } - - /** - * @param viewID - * the edited AdvancedEObjectFlatComboViewer - * @return the remove button of the given AdvancedEObjectFlatComboViewer - */ - public SWTBotButton removeButtonAdvancedEObjectFlatComboViewer(String viewID) { - return helper.removeButtonAdvancedEObjectFlatComboViewer(viewID); - } - - /** - * Select the object in the advanced table composition. - * - * @param eefWidgetIdKey - * widget key - * @param qualifiedIdentifier - * identifier of the PEE - * @param selected - * object to select - */ - public void selectInTableWithId(String eefWidgetIdKey, String qualifiedIdentifier, EObject selected) { - final SWTBotTable table = tableWithId(eefWidgetIdKey, qualifiedIdentifier); - final SWTBotTableItem tableItem = getTableItem(table, selected); - assertNotNull("No table item is found.", tableItem); - tableItem.select(); - } - - /** - * Select the objects in the (advanced) references table. - * - * @param eefWidgetIdKey - * widget key - * @param qualifiedIdentifier - * identifier of the PEE - * @param selected - * objects to select or null if you want to select all objects in the table - */ - public void selectInTableWithId(String eefWidgetIdKey, String qualifiedIdentifier, - Collection selected) { - final SWTBotTable table = tableWithId(eefWidgetIdKey, qualifiedIdentifier); - Collection items = new ArrayList(); - if (selected == null || selected.isEmpty()) { - int rowCount = table.rowCount(); - for (int i = 0; i < rowCount; i++) { - final SWTBotTableItem tableItem = table.getTableItem(i); - assertNotNull("No table item is found.", tableItem); - items.add(tableItem.getText()); - } - } else { - for (EObject eObject : selected) { - final SWTBotTableItem tableItem = getTableItem(table, eObject); - assertNotNull("No table item is found.", tableItem); - items.add(tableItem.getText()); - } - } - table.select(items.toArray(new String[0])); - } - - /** - * Select the object in the tree. - * - * @param selected - * object to select - */ - public void selectInActiveTree(EObject selected) { - final SWTBotTree tree = tree(0); - final SWTBotTreeItem treeItem = getTreeItem(tree, selected); - assertNotNull("No tree item is found.", treeItem); - treeItem.select(); - } - - /** - * Select the objects in the tree. - * - * @param selected - * objects to select - */ - public void selectInActiveTree(Collection selected) { - // TODO manage this case when EEF will allowed to select multiple - // elements in a tree - final SWTBotTree tree = tree(0); - final SWTBotTreeItem treeItem = getTreeItem(tree, selected.iterator().next()); - assertNotNull("No tree item is found.", treeItem); - treeItem.select(); - } - - /** - * Select the object in the table. - * - * @param selected - * object to select - */ - public void selectInActiveTable(Object selected) { - final SWTBotTable table = table(0); - final SWTBotTableItem tableItem = getTableItem(table, selected); - assertNotNull("No table item is found.", tableItem); - tableItem.select(); - } - - /** - * Select the objects in the table. - * - * @param selected - * objects to select - */ - public void selectInActiveTable(Collection selected) { - final SWTBotTable table = table(0); - int[] indices = new int[selected.size()]; - Iterator it = selected.iterator(); - for (int i = 0; i < selected.size(); i++) { - EObject eObject = it.next(); - final SWTBotTableItem tableItem = getTableItem(table, eObject); - assertNotNull("No table item is found.", tableItem); - indices[i] = indexOf(table, tableItem); - } - table.select(indices); - } - - /** - * Select the object in the flat references table. - * - * @param selected - * object to select - */ - public void selectInRightTableOfActiveEditor(Object selected) { - final SWTBotTable table = table(1); - final SWTBotTableItem tableItem = getTableItem(table, selected); - assertNotNull("No table item is found.", tableItem); - tableItem.select(); - } - - /** - * @param table - * @param object - * @return the table item corresponding to the object - */ - private int indexOf(final SWTBotTable table, final SWTBotTableItem tableItem) { - return syncExec(new IntResult() { - public Integer run() { - Table widgetTable = table.widget; - TableItem widgetItem = tableItem.widget; - return widgetTable.indexOf(widgetItem); - } - }); - } - - /** - * @param table - * @param object - * @return the table item corresponding to the object - */ - private SWTBotTableItem getTableItem(SWTBotTable table, Object object) { - for (int i = 0; i < table.rowCount(); i++) { - final SWTBotTableItem tableItem = table.getTableItem(i); - final Object data = syncExec(new Result() { - - public Object run() { - return tableItem.widget.getData(); - } - }); - if (data.equals(object)) { - return table.getTableItem(i); - } - } - return null; - } - - /** - * @param tree - * @param object - * @return the tree item corresponding to the object - */ - private SWTBotTreeItem getTreeItem(SWTBotTree tree, EObject object) { - SWTBotTreeItem[] rootItems = tree.getAllItems(); - for (final SWTBotTreeItem rootSwtBotTreeItem : rootItems) { - SWTBotTreeItem found = getTreeItem(rootSwtBotTreeItem, object); - if (found != null) { - return found; - } - } - return null; - } - - private SWTBotTreeItem getTreeItem(SWTBotTreeItem treeItem, EObject object) { - treeItem.select(); - treeItem.expand(); - SWTBotTreeItem[] items = treeItem.getItems(); - for (final SWTBotTreeItem swtBotTreeItem : items) { - final Object data = syncExec(new Result() { - - public Object run() { - return swtBotTreeItem.widget.getData(); - } - }); - if (data != null && data.equals(object)) { - return swtBotTreeItem; - } else { - SWTBotTreeItem found = getTreeItem(swtBotTreeItem, object); - if (found != null) { - return found; - } - } - } - - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#check() - */ - public void check() { - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#getModelingBotInterpreter() - */ - public IModelingBotInterpreter getModelingBotInterpreter() { - return interpreter; - } - - /** - * Add the given values to the text field of the MVE and click on Add button. - * - * @param value - * the given String value to add in the MVE. - */ - public void addValuesInMultiValuedEditor(Collection values) { - SWTBotText text = text(0); - for (String val : values) { - text.setText(val); - SWTBotButton buttonAdd = button(0); - buttonAdd.click(); - } - } - - /** - * Add the given values to the text field of the MVE and click on Add button. - * - * @param value - * the given String value to add in the MVE. - */ - public void removeValuesInMultiValuedEditor(Collection values) { - final SWTBotTable table = table(0); - for (String val : values) { - final SWTBotTableItem tableItem = getTableItem(table, val); - assertNotNull("No table item is found.", tableItem); - tableItem.select(); - SWTBotButton buttonRemove = button(1); - buttonRemove.click(); - SWTBotHelper.waitAllUiEvents(); - } - } - - /** - * Remove all values of the MVE by clicking on Remove button each time necessary. - */ - public void removeAllValuesInMultiValuedEditor() { - final SWTBotTable table = table(0); - int rowCount = table.rowCount(); - for (int i = 0; i < rowCount; i++) { - SWTBotButton buttonRemove = button(1); - buttonRemove.click(); - SWTBotHelper.waitAllUiEvents(); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#undo() - */ - public void undo(Action action) { - SWTBotHelper.waitAllUiEvents(); - if (editorEditingDomain != null && editorEditingDomain.getCommandStack().getUndoCommand() != null) { - final String cmdName = editorEditingDomain.getCommandStack().getUndoCommand().getLabel(); - EditMenuWaiterCondition condition = new EditMenuWaiterCondition(editor, "Undo " + cmdName ); - waitUntil(condition); - condition.getResultMenu().click(); - } else { - editor.setFocus(); - KeyboardFactory.getSWTKeyboard().pressShortcut(SWT.CTRL, 'z'); - } - SWTBotHelper.waitAllUiEvents(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.modelingBot.IModelingBot#redo() - */ - public void redo(Action action) { - SWTBotHelper.waitAllUiEvents(); - if (editorEditingDomain != null && editorEditingDomain.getCommandStack().getRedoCommand() != null) { - final String cmdName = editorEditingDomain.getCommandStack().getRedoCommand().getLabel(); - EditMenuWaiterCondition condition = new EditMenuWaiterCondition(editor, "Redo " + cmdName ); - waitUntil(condition); - condition.getResultMenu().click(); - } else { - editor.setFocus(); - KeyboardFactory.getSWTKeyboard().pressShortcut(SWT.CTRL, 'y'); - } - SWTBotHelper.waitAllUiEvents(); - } - - public void initWizard(Wizard wizard) { - if (wizard.getReferenceableObject() != null) { - assertNotNull("The editeur is not opened.", editor); - final EObject container = getEObjectFromReferenceableEObject(wizard.getReferenceableObject()); - assertNotNull("No container is found to launch add action.", container); - final SWTBotTreeItem selectNode = selectNode(editor, container); - assertNotNull("No element is selected in the editor", selectNode); - SWTBotHelper.doubleClickContextMenu(selectNode, selectNode.getText()); - } - - } - - public void closeWizard(Wizard wizard) { - if (wizard.getReferenceableObject() != null) { - button(UIConstants.FINISH_BUTTON).click(); - } - } - - public void moveUp(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject) { - assertNotNull(referenceableObject); - EObject eObject = getEObjectFromReferenceableEObject(referenceableObject); - assertNotNull(eObject); - selectInActiveTable(eObject); - buttonWithTooltip(UIConstants.UP_BUTTON).click(); - } - - public void moveDown(PropertiesEditionElement propertiesEditionElement, - ReferenceableObject referenceableObject) { - assertNotNull(referenceableObject); - EObject eObject = getEObjectFromReferenceableEObject(referenceableObject); - assertNotNull(eObject); - selectInActiveTable(eObject); - buttonWithTooltip(UIConstants.DOWN_BUTTON).click(); - } - - - private static class EditMenuWaiterCondition extends DefaultCondition { - - private SWTBotEditor editor; - private String menuName; - private SWTBotMenu resultMenu; - - /** - * @param editor - * @param menuName - */ - public EditMenuWaiterCondition(SWTBotEditor editor, String menuName) { - this.editor = editor; - this.menuName = menuName; - } - - /** - * @return the resultMenu - */ - public SWTBotMenu getResultMenu() { - return resultMenu; - } - - /** - * {@inheritDoc} - * @see org.eclipse.swtbot.swt.finder.waits.ICondition#test() - */ - public boolean test() throws Exception { - editor.bot().sleep(150); - resultMenu = editor.bot().menu("Edit").menu(menuName); - return resultMenu != null; - } - - /** - * {@inheritDoc} - * @see org.eclipse.swtbot.swt.finder.waits.ICondition#getFailureMessage() - */ - public String getFailureMessage() { - return "The menu 'Edit > " + menuName + "' never appears."; - } - - - - } -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractBatchModelingBotTestCase.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractBatchModelingBotTestCase.java deleted file mode 100644 index 1b482cc5c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractBatchModelingBotTestCase.java +++ /dev/null @@ -1,51 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.testcase; - -import junit.framework.TestCase; - -import org.eclipse.emf.eef.modelingBot.batch.BatchModelingBot; -import org.eclipse.swtbot.eclipse.finder.SWTBotEclipseTestCase; - -/** - * Batch modeling test case with BatchModelingBot. - * - * @author arichard - */ -public abstract class AbstractBatchModelingBotTestCase extends TestCase { - - /** - * An instance of SWTEclipseBot. - */ - protected BatchModelingBot bot = new BatchModelingBot(); - - /** - * {@inheritDoc} - * - * @see junit.framework.TestCase#setUp() - */ - public void setUp() throws Exception { - - } - - @Override - protected void tearDown() throws Exception { - super.tearDown(); - } - - /** - * Test method. call bot.runModelingBot("project/path.to/model.modelingbot"); - * - * @throws Exception if any exception is thrown - */ - public abstract void testModelingBot() throws Exception; - -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractComposedModelingBotTestCase.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractComposedModelingBotTestCase.java deleted file mode 100644 index 52e62ba8a..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractComposedModelingBotTestCase.java +++ /dev/null @@ -1,132 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.testcase; - -import java.io.File; -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.IWorkspaceRoot; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.eef.modelingBot.IModelingBot; -import org.eclipse.emf.eef.modelingBot.batch.BatchModelingBot; -import org.eclipse.emf.eef.modelingBot.helper.SWTBotHelper; -import org.eclipse.emf.eef.modelingBot.swtbot.ComposedEEFBot; -import org.eclipse.emf.eef.modelingBot.swtbot.SWTEEFBot; -import org.eclipse.swtbot.eclipse.finder.SWTBotEclipseTestCase; -import org.eclipse.ui.PlatformUI; - -/** - * SwtBot modeling test case with SWTEEFBot. - * - * @author Nathalie Lepine - */ -public abstract class AbstractComposedModelingBotTestCase extends SWTBotEclipseTestCase { - - /** - * An instance of composed bot. - */ - protected ComposedEEFBot bot; - - /** - * An instance of swt eef bot. - */ - private SWTEEFBot swtEEFBot; - - /** - * {@inheritDoc} - * - * @see junit.framework.TestCase#setUp() - */ - public void setUp() throws Exception { - super.setUp(); - - // remove existants projects - clearWorkspaceProjects(); - File file = ResourcesPlugin.getWorkspace().getRoot().getLocation().toFile(); - if (file.isDirectory()) { - deleteFolder(file); - } - - PlatformUI.getWorkbench().getDisplay().syncExec(new Runnable() { - - public void run() { - PlatformUI.getWorkbench().getWorkbenchWindows()[0].getShell().setFullScreen(true); - } - }); - - final List bots = new ArrayList(2); - swtEEFBot = new SWTEEFBot(); - swtEEFBot.closeWelcomePage(); - swtEEFBot.openJavaPerspective(); - swtEEFBot.openPropertiesView(); - final BatchModelingBot batchModeling = new BatchModelingBot(); - bots.add(swtEEFBot); - bots.add(batchModeling); - bot = new ComposedEEFBot(bots); - } - - private void clearWorkspaceProjects() throws CoreException { - IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot(); - NullProgressMonitor monitor = new NullProgressMonitor(); - root.refreshLocal(IResource.DEPTH_INFINITE, monitor); - IProject[] projects = root.getProjects(); - for (int i = 0; i < projects.length; i++) { - projects[i].delete(true, monitor); - } - } - - public static void deleteFolder(File folder) { - File[] files = folder.listFiles(); - if (files != null) { // some JVMs return null for empty dirs - for (File f : files) { - if (f.isDirectory()) { - if (f.getName() != null && f.getName().length() > 0) { - if (!f.getName().startsWith(".")) { - deleteFolder(f); - } - } - } else { - f.delete(); - } - } - } - folder.delete(); - } - @Override - protected void tearDown() throws Exception { - // Close an eventual popup if the test failed and a popup remain opened - swtEEFBot.closeAllShells(); - SWTBotHelper.waitAllUiEvents(); - - swtEEFBot.closeAllEditors(); - swtEEFBot.dispose(); - SWTBotHelper.waitAllUiEvents(); - - IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot(); - IProject[] projects = root.getProjects(); - for (int i = 0; i < projects.length; i++) { - projects[i].delete(true, new NullProgressMonitor()); - } - super.tearDown(); - } - - /** - * Test method. call bot.runModelingBot("project/path.to/model.modelingbot"); - * - * @throws Exception if any exception is thrown - */ - public abstract void testModelingBot() throws Exception; -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractSWTBotModelingBotTestCase.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractSWTBotModelingBotTestCase.java deleted file mode 100755 index f4a86051c..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/testcase/AbstractSWTBotModelingBotTestCase.java +++ /dev/null @@ -1,79 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.testcase; - -import org.eclipse.emf.eef.modelingBot.helper.SWTBotHelper; -import org.eclipse.emf.eef.modelingBot.swtbot.SWTEEFBot; -import org.eclipse.swtbot.eclipse.finder.SWTBotEclipseTestCase; -import org.eclipse.swtbot.swt.finder.waits.DefaultCondition; -import org.eclipse.ui.PlatformUI; - -/** - * SwtBot modeling test case with SWTEEFBot. - * - * @author Nathalie Lepine - */ -public abstract class AbstractSWTBotModelingBotTestCase extends SWTBotEclipseTestCase { - - /** - * An instance of SWTEclipseBot. - */ - protected SWTEEFBot bot = new SWTEEFBot(); - - /** - * {@inheritDoc} - * - * @see junit.framework.TestCase#setUp() - */ - public void setUp() throws Exception { - super.setUp(); - bot.waitUntil(new DefaultCondition() { - - public boolean test() throws Exception { - return PlatformUI.getWorkbench().getWorkbenchWindows().length > 0; - } - - public String getFailureMessage() { - return "Unable to find a workbench window"; - } - }); - PlatformUI.getWorkbench().getDisplay().syncExec(new Runnable() { - - public void run() { - PlatformUI.getWorkbench().getWorkbenchWindows()[0].getShell().setFullScreen(true); - } - }); - bot.closeWelcomePage(); - bot.openJavaPerspective(); - bot.openPropertiesView(); - } - - @Override - protected void tearDown() throws Exception { - // Close an eventual popup if the test failed and a popup remain opened - bot.closeAllShells(); - SWTBotHelper.waitAllUiEvents(); - - bot.closeAllEditors(); - bot.dispose(); - SWTBotHelper.waitAllUiEvents(); - - super.tearDown(); - } - - /** - * Test method. call bot.runModelingBot("project/path.to/model.modelingbot"); - * - * @throws Exception - * if any exception is thrown - */ - public abstract void testModelingBot() throws Exception; -} diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/ui/utils/WrappedSWTBotRadio.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/ui/utils/WrappedSWTBotRadio.java deleted file mode 100644 index b4b235751..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/ui/utils/WrappedSWTBotRadio.java +++ /dev/null @@ -1,73 +0,0 @@ -package org.eclipse.emf.eef.modelingBot.ui.utils; - -import org.eclipse.swt.SWT; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Widget; -import org.eclipse.swtbot.swt.finder.results.VoidResult; -import org.eclipse.swtbot.swt.finder.utils.MessageFormat; -import org.eclipse.swtbot.swt.finder.utils.SWTUtils; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotRadio; - -/** - * A temporary class used to work around a bug. - * - * @author alagarde - */ -public class WrappedSWTBotRadio extends SWTBotRadio { - - /** - * Default constructor. - * - * @param wrapped - * The wrapped SWTBot radio to override click method. - */ - public WrappedSWTBotRadio(SWTBotRadio wrapped) { - super(wrapped.widget); - } - - /** - * Selects the radio button. - */ - public SWTBotRadio click() { - if (isSelected()) { - log.debug(MessageFormat.format("Widget {0} is already selected, not clicking again.", this)); //$NON-NLS-1$ - return this; - } - waitForEnabled(); - log.debug(MessageFormat.format("Clicking on {0}", this)); //$NON-NLS-1$ - asyncExec(new VoidResult() { - public void run() { - deselectOtherRadioButtons(); - log.debug(MessageFormat.format("Clicking on {0}", this)); //$NON-NLS-1$ - widget.setSelection(true); - } - - /** - * @see "http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet224.java?view=co" - */ - private void deselectOtherRadioButtons() { - if (hasStyle(widget.getParent(), SWT.NO_RADIO_GROUP)) - return; - Widget[] siblings = SWTUtils.siblings(widget); - for (Widget widget : siblings) { - if ((widget instanceof Button) && hasStyle(widget, SWT.RADIO)) - ((Button) widget).setSelection(false); - } - } - }); - notify(SWT.MouseEnter); - notify(SWT.MouseMove); - notify(SWT.Activate); - notify(SWT.FocusIn); - notify(SWT.MouseDown); - notify(SWT.MouseUp); - notify(SWT.Selection); - notify(SWT.MouseHover); - notify(SWT.MouseMove); - notify(SWT.MouseExit); - notify(SWT.Deactivate); - notify(SWT.FocusOut); - log.debug(MessageFormat.format("Clicked on {0}", this)); //$NON-NLS-1$ - return this; - } -} \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/uri/EEFURIConverter.java b/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/uri/EEFURIConverter.java deleted file mode 100755 index 88a452f80..000000000 --- a/plugins/org.eclipse.emf.eef.modelingbot/src/org/eclipse/emf/eef/modelingBot/uri/EEFURIConverter.java +++ /dev/null @@ -1,65 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.modelingBot.uri; - -import java.io.IOException; -import java.util.Collections; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.Path; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ExtensibleURIConverterImpl; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; - -/** - * @author Goulwen Le Fur - * - */ -public class EEFURIConverter extends ExtensibleURIConverterImpl { - - private ResourceSet myResourceSet; - - public EEFURIConverter() { - super(); - myResourceSet = new ResourceSetImpl(); - myResourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(Resource.Factory.Registry.DEFAULT_EXTENSION, new XMIResourceFactoryImpl()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.ecore.resource.impl.ExtensibleURIConverterImpl#normalize(org.eclipse.emf.common.util.URI) - */ - public URI normalize(URI uri) { - URI result = super.normalize(uri); - if (result.isPlatformResource()) { - final IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(new Path(result.toPlatformString(true))); - if (!file.isAccessible()) { - final URI pluginURI = URI.createPlatformPluginURI(uri.toPlatformString(true), true); - try { - final Resource resource = myResourceSet.getResource(pluginURI, true); - resource.load(Collections.EMPTY_MAP); - if (resource.getContents() != null && !resource.getContents().isEmpty()) { - result = pluginURI; - } - } catch (IOException e) { - // silent catch - } - } - } - return result; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/.checkstyle b/plugins/org.eclipse.emf.eef.runtime.extended/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/.classpath b/plugins/org.eclipse.emf.eef.runtime.extended/.classpath deleted file mode 100644 index 64c5e31b7..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/.gitignore b/plugins/org.eclipse.emf.eef.runtime.extended/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/.project b/plugins/org.eclipse.emf.eef.runtime.extended/.project deleted file mode 100644 index 784cd69c3..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.runtime.extended - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.runtime.extended/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index 6a6b6e697..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,8 +0,0 @@ -#Tue Nov 16 09:51:02 CET 2010 -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.runtime.extended/META-INF/MANIFEST.MF deleted file mode 100644 index e19fd7505..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/META-INF/MANIFEST.MF +++ /dev/null @@ -1,37 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Extended Runtime -Bundle-SymbolicName: org.eclipse.emf.eef.runtime.extended;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Vendor: Eclipse Modeling Project -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Require-Bundle: org.eclipse.core.runtime;bundle-version="3.3.0", - org.eclipse.emf.ecore;bundle-version="2.3.0";visibility:=reexport, - org.eclipse.emf.ecore.xmi;bundle-version="2.3.0", - org.eclipse.ui;bundle-version="3.3.0", - org.eclipse.emf.edit.ui;bundle-version="2.3.0";visibility:=reexport, - org.eclipse.ui.forms;bundle-version="3.3.0";visibility:=reexport, - org.eclipse.emf.eef.runtime;bundle-version="1.0.0";visibility:=reexport, - org.eclipse.ocl.ecore;bundle-version="1.0.0", - org.eclipse.core.resources;bundle-version="3.3.0", - org.eclipse.ui.ide;bundle-version="3.3.0" -Export-Package: org.eclipse.emf.eef.runtime.query, - org.eclipse.emf.eef.runtime.query.compound, - org.eclipse.emf.eef.runtime.query.explicitpath, - org.eclipse.emf.eef.runtime.query.explicitpath.exception, - org.eclipse.emf.eef.runtime.query.explicitpath.path, - org.eclipse.emf.eef.runtime.query.ocl, - org.eclipse.emf.eef.runtime.ui, - org.eclipse.emf.eef.runtime.ui.editor, - org.eclipse.emf.eef.runtime.ui.editor.messages, - org.eclipse.emf.eef.runtime.ui.editors.pages, - org.eclipse.emf.eef.runtime.ui.editors.pages.eefviewer, - org.eclipse.emf.eef.runtime.ui.editors.pages.tree, - org.eclipse.emf.eef.runtime.ui.layout, - org.eclipse.emf.eef.runtime.ui.views, - org.eclipse.emf.eef.runtime.ui.widgets.masterdetails, - org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.eefviewer, - org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.tree -Bundle-Activator: org.eclipse.emf.eef.runtime.ui.EEFExtendedRuntime$Implementation -Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/about.html b/plugins/org.eclipse.emf.eef.runtime.extended/about.html deleted file mode 100755 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/build.properties b/plugins/org.eclipse.emf.eef.runtime.extended/build.properties deleted file mode 100644 index 48b5ac05d..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/build.properties +++ /dev/null @@ -1,19 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ - icons/,\ - plugin.properties,\ - about.html -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/icons/full/obj16/InteractiveEditor.gif b/plugins/org.eclipse.emf.eef.runtime.extended/icons/full/obj16/InteractiveEditor.gif deleted file mode 100644 index b709469c20aea3ea0d9b3f031506071f02aeb055..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1045 zcmeH`TThY!0ERz@ZB)2Eb$M9Yuvt3GyH>g`QbL6bC)jK*+bTnIrHz)uvjQ>|Q^Nyb zW}YzA07W^eC<9T%AifU-L@*Di8LhT(IdxuG{)p~+|G=~7+1?a$xPIHYgL$?E2nr8dw-r9$$?;%r*y!|vXBR*Ool`C>LX z)4DS5urpG)1k-rW!opgq@FlAPy~yHEu|vzCxiQa*PL8oMLfOk zbp3qWp|#pPbMxyHllDdH*WOYB1a0aU)>~TDZik7(o!Qy(Zn(W>%g)5)QgO)u3~g~( zQ)%59uSors6yeC5{6Y#}IBYsNJlfkkJU%|QY9-p)mD&pFgwjsR<)v_ml~n2IsM%oL z6bPXaF>JGYoG#Btp)s4(J3L~cmWaipFe!&uRw3R$I4ZA{>K8UFkc-Wkkx1=0F0qxZ zo>V%fRW9B9+OzyY9EYgZEW4LXO%Ebj&C@1mTOfd?vc*Z|Qbm;n`s`+NHD;5ekEfr} zuGEwWrlyx_>c%NWgD|`~ty*!qzH{0&^7i8L$}z>bePGC7GT4+;%T+XKZXRDIx6&E% zF^LU=w++VihDN1Ip}L1-$JQqORRjL-9~X!?^z{J%CUEV9bMgrQxeEk_lBs$c4U6=P z1;lC)gQx>>*g_bjB0_xP`qcmei9$t3-beS4@NrD=ROUng@e)v*t@CB&QJc?X#V|ry z(JAz9q8;r`2h5Dqao~9z=^Lx*LSdWukTs|V0uY=lVcFVhHiiJ!7xYl6^x)L=HXlS{ zwFB#i%oKx+a~)^H>&c#7PC^Z;I1(oK^K^lM{;M%)35Jdi%DC~XeHTbt3orPM+V$C* z@4Wp&H5FccxiJJ2%m91)bokc_3WwCZ83i>bfEUR~ZxDzIF2ersMC4#QZ$_=!<9Q#_ Q7+3K|g`QbL6bC)jK*+bTnIrHz)uvjQ>|Q^Nyb zW}YzA07W^eC<9T%AifU-L@*Di8LhT(IdxuG{)p~+|G=~7+1?a$xPIHYgL$?E2nr8dw-r9$$?;%r*y!|vXBR*Ool`C>LX z)4DS5urpG)1k-rW!opgq@FlAPy~yHEu|vzCxiQa*PL8oMLfOk zbp3qWp|#pPbMxyHllDdH*WOYB1a0aU)>~TDZik7(o!Qy(Zn(W>%g)5)QgO)u3~g~( zQ)%59uSors6yeC5{6Y#}IBYsNJlfkkJU%|QY9-p)mD&pFgwjsR<)v_ml~n2IsM%oL z6bPXaF>JGYoG#Btp)s4(J3L~cmWaipFe!&uRw3R$I4ZA{>K8UFkc-Wkkx1=0F0qxZ zo>V%fRW9B9+OzyY9EYgZEW4LXO%Ebj&C@1mTOfd?vc*Z|Qbm;n`s`+NHD;5ekEfr} zuGEwWrlyx_>c%NWgD|`~ty*!qzH{0&^7i8L$}z>bePGC7GT4+;%T+XKZXRDIx6&E% zF^LU=w++VihDN1Ip}L1-$JQqORRjL-9~X!?^z{J%CUEV9bMgrQxeEk_lBs$c4U6=P z1;lC)gQx>>*g_bjB0_xP`qcmei9$t3-beS4@NrD=ROUng@e)v*t@CB&QJc?X#V|ry z(JAz9q8;r`2h5Dqao~9z=^Lx*LSdWukTs|V0uY=lVcFVhHiiJ!7xYl6^x)L=HXlS{ zwFB#i%oKx+a~)^H>&c#7PC^Z;I1(oK^K^lM{;M%)35Jdi%DC~XeHTbt3orPM+V$C* z@4Wp&H5FccxiJJ2%m91)bokc_3WwCZ83i>bfEUR~ZxDzIF2ersMC4#QZ$_=!<9Q#_ Q7+3K| - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/pom.xml b/plugins/org.eclipse.emf.eef.runtime.extended/pom.xml deleted file mode 100644 index 93616a819..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/pom.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.runtime.extended - eclipse-plugin - - EEF Extended Runtime Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/EEFQuery.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/EEFQuery.java deleted file mode 100644 index 1d5a386ea..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/EEFQuery.java +++ /dev/null @@ -1,62 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query; - -import org.eclipse.ui.plugin.AbstractUIPlugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle - * @author Goulwen Le Fur - */ -public class EEFQuery extends AbstractUIPlugin { - - // The plug-in ID - public static final String PLUGIN_ID = "org.eclipse.emf.eef.query"; //$NON-NLS-1$ - - // The shared instance - private static EEFQuery plugin; - - /** - * The constructor - */ - public EEFQuery() { - } - - /* - * (non-Javadoc) - * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - /* - * (non-Javadoc) - * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * - * Returns the shared instance - * - * @return the shared instance - */ - public static EEFQuery getInstance() { - return plugin; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryProcessor.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryProcessor.java deleted file mode 100644 index 904822212..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryProcessor.java +++ /dev/null @@ -1,34 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query; - -import org.eclipse.emf.ecore.EObject; - -/** - * @author Goulwen Le Fur - */ -public interface QueryProcessor { - - /** - * Evaluate a query on a given object. - * @param context the object to process - * @param query the query to evaluate - * @return the result of evaluation - */ - QueryResult evaluate(EObject context, QueryWrapper query); - - /** - * Defines if a query can be evaluated by the current processor. - * @param query the query to evaluate - * @return true if the query can be evaluated - */ - boolean canEvaluate(QueryWrapper query); -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryResult.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryResult.java deleted file mode 100644 index 7f7d67cd4..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryResult.java +++ /dev/null @@ -1,35 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query; - -import org.eclipse.core.runtime.IStatus; - -/** - * @author Goulwen Le Fur - */ -public class QueryResult { - - public IStatus evaluationStatus; - public Object evaluationResult; - - - /** - * Constructor - * @param evaluationStatus - * @param evaluationResult - */ - public QueryResult(IStatus evaluationStatus, Object evaluationResult) { - this.evaluationStatus = evaluationStatus; - this.evaluationResult = evaluationResult; - } - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryWrapper.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryWrapper.java deleted file mode 100644 index 60bc23801..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/QueryWrapper.java +++ /dev/null @@ -1,20 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query; - -/** - * @author Goulwen Le Fur - */ -public interface QueryWrapper { - - String getKind(); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/compound/CompoundProcessor.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/compound/CompoundProcessor.java deleted file mode 100644 index e3fd8ba69..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/compound/CompoundProcessor.java +++ /dev/null @@ -1,88 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query.compound; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.query.EEFQuery; -import org.eclipse.emf.eef.runtime.query.QueryProcessor; -import org.eclipse.emf.eef.runtime.query.QueryResult; -import org.eclipse.emf.eef.runtime.query.QueryWrapper; - -/** - * @author Goulwen Le Fur - */ -public class CompoundProcessor implements QueryProcessor { - - private List processors; - - /** - * Empty constructor. - */ - public CompoundProcessor() { - super(); - processors = new ArrayList(); - } - - /** - * Parameterized constructor. - * @param processors the processors to use. - */ - public CompoundProcessor(QueryProcessor[] processors) { - this.processors = Arrays.asList(processors); - } - - /** - * Add a processor to the list of managed processors. - * @param processor the processor to add. - */ - public void addProcessor(QueryProcessor processor) { - this.processors.add(processor); - } - - /** - * Remove a processor to the list of managed processors. - * @param processor the processor to remove. - */ - public void removeProcessor(QueryProcessor processor) { - this.processors.remove(processor); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.query.QueryProcessor#evaluate(org.eclipse.emf.ecore.EObject, org.eclipse.emf.eef.runtime.query.QueryWrapper) - */ - public QueryResult evaluate(EObject context, QueryWrapper query) { - for (QueryProcessor processor : processors) { - if (processor.canEvaluate(query)) - return processor.evaluate(context, query); - } - return new QueryResult(new Status(IStatus.ERROR, EEFQuery.PLUGIN_ID, "No processor can evaluate this query."), null); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.query.QueryProcessor#canEvaluate(org.eclipse.emf.eef.runtime.query.QueryWrapper) - */ - public boolean canEvaluate(QueryWrapper query) { - for (QueryProcessor processor : processors) { - if (processor.canEvaluate(query)) - return true; - } - return false; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/ExplicitPathProcessor.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/ExplicitPathProcessor.java deleted file mode 100644 index 98ddd6888..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/ExplicitPathProcessor.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query.explicitpath; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.query.EEFQuery; -import org.eclipse.emf.eef.runtime.query.QueryProcessor; -import org.eclipse.emf.eef.runtime.query.QueryResult; -import org.eclipse.emf.eef.runtime.query.QueryWrapper; - -/** - * @author Goulwen Le Fur - */ -public class ExplicitPathProcessor implements QueryProcessor { - - public static final String EXPLICITPATH_KIND = "explicit path"; - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.query.QueryProcessor#evaluate(org.eclipse.emf.ecore.EObject, org.eclipse.emf.eef.runtime.query.QueryWrapper) - */ - public QueryResult evaluate(EObject context, QueryWrapper query) { - try { - ExplicitPathQuery pathQuery = (ExplicitPathQuery)query; - return new QueryResult(Status.OK_STATUS, pathQuery.getModelNavigation().evaluate(context)); - } catch (Exception e) { - return new QueryResult(new Status(IStatus.ERROR, EEFQuery.PLUGIN_ID, "Error during evaluating model navigation.", e), null); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.query.QueryProcessor#canEvaluate(org.eclipse.emf.eef.runtime.query.QueryWrapper) - */ - public boolean canEvaluate(QueryWrapper query) { - return query.getKind() == EXPLICITPATH_KIND; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/ExplicitPathQuery.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/ExplicitPathQuery.java deleted file mode 100644 index 4f5b22ec5..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/ExplicitPathQuery.java +++ /dev/null @@ -1,46 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query.explicitpath; - -import org.eclipse.emf.eef.runtime.query.QueryWrapper; -import org.eclipse.emf.eef.runtime.query.explicitpath.path.ModelNavigation; - -/** - * @author Goulwen Le Fur - */ -public class ExplicitPathQuery implements QueryWrapper { - - private ModelNavigation modelNavigation; - - /** - * @param modelNavigation - */ - public ExplicitPathQuery(ModelNavigation modelNavigation) { - super(); - this.modelNavigation = modelNavigation; - } - - /** - * @return the modelNavigation - */ - public ModelNavigation getModelNavigation() { - return modelNavigation; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.query.QueryWrapper#getKind() - */ - public String getKind() { - return ExplicitPathProcessor.EXPLICITPATH_KIND; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/exception/EvaluationException.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/exception/EvaluationException.java deleted file mode 100644 index a70818778..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/exception/EvaluationException.java +++ /dev/null @@ -1,62 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query.explicitpath.exception; - -/** - * @author Goulwen Le Fur - */ -public class EvaluationException extends Exception { - - /** - * - */ - private static final long serialVersionUID = 800645398898568026L; - - /** - * - */ - public EvaluationException() { - super(); - } - - /** - * @param message - * @param cause - */ - public EvaluationException(String message, Throwable cause) { - super(message, cause); - } - - /** - * @param message - */ - public EvaluationException(String message) { - super(message); - } - - /** - * @param cause - */ - public EvaluationException(Throwable cause) { - super(cause); - } - - /** - * {@inheritDoc} - * @see java.lang.Throwable#getMessage() - */ - public String getMessage() { - return "Error during model navigation : " + super.getMessage(); - } - - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/AttributeModelNavigation.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/AttributeModelNavigation.java deleted file mode 100644 index 7849f1d67..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/AttributeModelNavigation.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query.explicitpath.path; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.query.explicitpath.exception.EvaluationException; - -/** - * @author Goulwen Le Fur - */ -public class AttributeModelNavigation implements ModelNavigation { - - /** - * the feature to navigate - */ - public EAttribute feature; - - /** - * the index for multivalued attributes - */ - public int index; - - /** - * @param feature the feature to navigate - */ - public AttributeModelNavigation(EAttribute feature) { - super(); - this.feature = feature; - this.index = -1; - } - - /** - * @param feature the feature to navigate - * @param index the index of the object in feature to get - */ - public AttributeModelNavigation(EAttribute feature, int index) { - super(); - assert feature.isMany():"Index defined for a not multi-valued attribute"; - this.feature = feature; - this.index = index; - } - - - /** - * @param value the EObject to process - * @return the result of ModelNavigation evaluation - * @throws EvaluationException - */ - public Object evaluate(EObject value) throws EvaluationException { - try { - Object eGet = value.eGet(feature); - if (index < 0) { - return eGet; - } - else { - if (eGet instanceof EList) { - return ((EList)eGet).get(index); - } - else - throw new EvaluationException("Index used on non many reference."); - } - } catch (Exception e) { - throw new EvaluationException(e); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ChainedModelNavigation.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ChainedModelNavigation.java deleted file mode 100644 index 10c72de65..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ChainedModelNavigation.java +++ /dev/null @@ -1,75 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query.explicitpath.path; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.query.explicitpath.exception.EvaluationException; - -/** - * @author Goulwen Le Fur - */ -public class ChainedModelNavigation implements ModelNavigation { - - private List navigations; - - /** - * Empty constructor. - */ - public ChainedModelNavigation() { - super(); - this.navigations = new ArrayList(); - } - - - /** - * Parameterized constructor. - * @param navigations the ModelNavigation to chain - */ - public ChainedModelNavigation(ModelNavigation[] navigations) { - this.navigations = Arrays.asList(navigations); - } - - /** - * Add a ModelNavigation to the list - * @param navigation the ModelNavigation to add - */ - public void addModelNavigation(ModelNavigation navigation) { - navigations.add(navigation); - } - - /** - * Remove a ModelNavigation to the list - * @param navigation the ModelNavigation to remove - */ - public void removeModelNavigation(ModelNavigation navigation) { - navigations.remove(navigation); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.query.explicitpath.path.ModelNavigation#evaluate(org.eclipse.emf.ecore.EObject) - */ - public Object evaluate(EObject value) throws EvaluationException { - Object result = value; - for (ModelNavigation navigation : navigations) { - if (result instanceof EObject) - result = navigation.evaluate((EObject) result); - else - throw new EvaluationException("Bad return type during ModelNavigation evaluation"); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ModelNavigation.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ModelNavigation.java deleted file mode 100644 index c441f4c87..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ModelNavigation.java +++ /dev/null @@ -1,23 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query.explicitpath.path; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.query.explicitpath.exception.EvaluationException; - -/** - * @author Goulwen Le Fur - */ -public interface ModelNavigation { - - public Object evaluate(EObject value) throws EvaluationException; - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ReferenceModelNavigation.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ReferenceModelNavigation.java deleted file mode 100644 index ac9bfc924..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/explicitpath/path/ReferenceModelNavigation.java +++ /dev/null @@ -1,115 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query.explicitpath.path; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.eef.runtime.query.explicitpath.exception.EvaluationException; - -/** - * @author glefur - * - */ -public class ReferenceModelNavigation implements ModelNavigation { - - public EReference feature; - - public int index; - - public EClass discriminatorType; - - /** - * @param feature the feature to navigate - * @param index the index of the object to navigate - * @param discriminatorType the discriminator - */ - public ReferenceModelNavigation(EReference feature, int index, EClass discriminatorType) { - assert feature.isMany() : "Index defined for a not multi-valued attribute"; - assert feature.getEReferenceType().isSuperTypeOf(discriminatorType) : "Discriminator invalid"; - this.feature = feature; - this.index = index; - this.discriminatorType = discriminatorType; - } - - /** - * @param feature the feature to navigate - * @param discriminatorType the discriminator - */ - public ReferenceModelNavigation(EReference feature, EClass discriminatorType) { - assert feature.getEReferenceType().isSuperTypeOf(discriminatorType) : "Discriminator invalid"; - this.feature = feature; - this.index = -1; - this.discriminatorType = discriminatorType; - } - - /** - * @param feature the feature to navigate - * @param index the index of the object to navigate - */ - public ReferenceModelNavigation(EReference feature, int index) { - assert feature.isMany() : "Index defined for a not multi-valued attribute"; - this.feature = feature; - this.index = index; - this.discriminatorType = null; - } - - /** - * @param feature the feature to navigate - */ - public ReferenceModelNavigation(EReference feature) { - this.feature = feature; - this.index = -1; - this.discriminatorType = null; - } - - /** - * @param value the EObject to process - * @return the result of ModelNavigation evaluation - * @throws EvaluationException - */ - public Object evaluate(EObject value) throws EvaluationException { - try { - Object eGet = value.eGet(feature); - if (discriminatorType != null) { - if (eGet instanceof EList) { - List tmp = new ArrayList(); - EList eList = (EList)eGet; - for (EObject eObject : eList) { - if (eObject.eClass().equals(discriminatorType)) - tmp.add(eObject); - } - if (index >= 0) - return tmp.get(index); - else - return tmp; - } - else - throw new EvaluationException("Discriminator type used on non many reference."); - } - else if (index >= 0) { - if (eGet instanceof EList) { - return ((EList)eGet).get(index); - } - else - throw new EvaluationException("Index used on non many reference."); - } - else - return eGet; - } catch (Exception e) { - throw new EvaluationException(e); - } - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/ocl/OCLProcessor.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/ocl/OCLProcessor.java deleted file mode 100644 index 7702ad11e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/ocl/OCLProcessor.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query.ocl; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EEnumLiteral; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EOperation; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EParameter; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.eef.runtime.query.EEFQuery; -import org.eclipse.emf.eef.runtime.query.QueryProcessor; -import org.eclipse.emf.eef.runtime.query.QueryResult; -import org.eclipse.emf.eef.runtime.query.QueryWrapper; -import org.eclipse.ocl.OCL; -import org.eclipse.ocl.ParserException; -import org.eclipse.ocl.ecore.CallOperationAction; -import org.eclipse.ocl.ecore.Constraint; -import org.eclipse.ocl.ecore.EcoreEnvironmentFactory; -import org.eclipse.ocl.ecore.SendSignalAction; -import org.eclipse.ocl.expressions.OCLExpression; -import org.eclipse.ocl.helper.OCLHelper; - -/** - * @author Goulwen Le Fur - */ -public class OCLProcessor implements QueryProcessor { - - public static final String OCL_KIND = "ocl"; - - private OCL oclEnvironment; - - /** - * Constructor. - */ - public OCLProcessor() { - super(); - oclEnvironment = OCL.newInstance(EcoreEnvironmentFactory.INSTANCE); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.query.QueryProcessor#canEvaluate(org.eclipse.emf.eef.runtime.query.QueryWrapper) - */ - public boolean canEvaluate(QueryWrapper query) { - return query.getKind() == OCLProcessor.OCL_KIND; - } - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.query.QueryProcessor#evaluate(org.eclipse.emf.ecore.EObject, org.eclipse.emf.eef.runtime.query.QueryWrapper) - */ - public QueryResult evaluate(EObject context, QueryWrapper query) { - try { - OCLQuery oclQuery = (OCLQuery)query; - OCLHelper oclHelper = oclEnvironment.createOCLHelper(); - oclHelper.setContext(oclQuery.getContext()); - String queryBody = oclQuery.getOclQuery(); - if (queryBody != null && !queryBody.equals("")) { - OCLExpression parsedException = oclHelper.createQuery(queryBody); - Object evaluationResult = oclEnvironment.evaluate(context, parsedException); - return new QueryResult(Status.OK_STATUS, evaluationResult); - } else { - return new QueryResult(Status.OK_STATUS, null); - } - } catch (ParserException e) { - return new QueryResult(new Status(IStatus.ERROR, EEFQuery.PLUGIN_ID, "Error parsing ocl query.", e), null); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/ocl/OCLQuery.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/ocl/OCLQuery.java deleted file mode 100644 index 4cf077c3b..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/query/ocl/OCLQuery.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.query.ocl; - -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.eef.runtime.query.QueryWrapper; - -/** - * @author Goulwen Le Fur - */ -public class OCLQuery implements QueryWrapper { - - private String oclQuery; - private EClassifier context; - - /** - * @param oclQuery the query to evaluate - */ - public OCLQuery(EClassifier context, String oclQuery) { - super(); - this.oclQuery = oclQuery; - this.context = context; - } - - /* (non-Javadoc) - * @see org.eclipse.emf.eef.query.QueryWrapper#getKind() - */ - public String getKind() { - return OCLProcessor.OCL_KIND; - } - - /** - * @return the context - */ - public EClassifier getContext() { - return context; - } - - /** - * @return the querto evaluate - */ - public String getOclQuery() { - return oclQuery; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/EEFExtendedRuntime.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/EEFExtendedRuntime.java deleted file mode 100644 index eefd1f76a..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/EEFExtendedRuntime.java +++ /dev/null @@ -1,119 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui; - -import org.eclipse.emf.common.EMFPlugin; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; -import org.eclipse.emf.eef.runtime.query.QueryProcessor; -import org.eclipse.emf.eef.runtime.query.compound.CompoundProcessor; -import org.eclipse.emf.eef.runtime.query.explicitpath.ExplicitPathProcessor; -import org.eclipse.emf.eef.runtime.query.ocl.OCLProcessor; - -/** - * This is the central singleton for the Extended edit plugin. - * - */ -public final class EEFExtendedRuntime extends EMFPlugin { - - /** - * ID of the Extended Runtime plugin - */ - public static final String PLUGIN_ID = "org.eclipse.emf.eef.runtime.extended"; - - /** - * Keep track of the singleton. - * - */ - public static final EEFExtendedRuntime INSTANCE = new EEFExtendedRuntime(); - - /** - * Keep track of the singleton. - * - */ - private static Implementation plugin; - - /** - * The Query Processor - */ - private QueryProcessor processor; - - /** - * @return the processor - */ - public QueryProcessor getProcessor() { - return processor; - } - - /** - * Create the instance. - * - */ - public EEFExtendedRuntime() { - super(new ResourceLocator [] { }); - processor = new CompoundProcessor(); - ((CompoundProcessor)processor).addProcessor(new OCLProcessor()); - ((CompoundProcessor)processor).addProcessor(new ExplicitPathProcessor()); - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * @return the singleton instance. - * - */ - @Override - public ResourceLocator getPluginResourceLocator() { - return plugin; - } - - /** - * @param modelURI the model URI - * @return the associated resource - */ - public Resource getResource(URI modelURI) { - ResourceSet resourceSet = new ResourceSetImpl(); - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(Resource.Factory.Registry.DEFAULT_EXTENSION, new XMIResourceFactoryImpl()); - Resource resource = resourceSet.getResource(modelURI, true); - return resource; - } - - /** - * Returns the singleton instance of the Eclipse plugin. - * @return the singleton instance. - * - */ - public static Implementation getPlugin() { - return plugin; - } - - /** - * The actual implementation of the Eclipse Plugin. - * - */ - public static class Implementation extends EclipsePlugin { - /** - * Creates an instance. - * - */ - public Implementation() { - super(); - - // Remember the static instance. - // - plugin = this; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/InteractiveEEFEditor.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/InteractiveEEFEditor.java deleted file mode 100644 index becbbbeb2..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/InteractiveEEFEditor.java +++ /dev/null @@ -1,1344 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editor; - -import java.io.File; -import java.io.IOException; -import java.io.InputStream; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.EventObject; -import java.util.HashMap; -import java.util.Iterator; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.resources.IMarker; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.resources.IResourceChangeEvent; -import org.eclipse.core.resources.IResourceChangeListener; -import org.eclipse.core.resources.IResourceDelta; -import org.eclipse.core.resources.IResourceDeltaVisitor; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.command.CommandStack; -import org.eclipse.emf.common.command.CommandStackListener; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.ui.URIEditorInput; -import org.eclipse.emf.common.ui.editor.ProblemEditorPart; -import org.eclipse.emf.common.ui.viewer.IViewerProvider; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EValidator; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.EContentAdapter; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; -import org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory; -import org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory; -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; -import org.eclipse.emf.edit.ui.dnd.EditingDomainViewerDropAdapter; -import org.eclipse.emf.edit.ui.dnd.LocalTransfer; -import org.eclipse.emf.edit.ui.dnd.ViewerDragAdapter; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.edit.ui.provider.UnwrappingSelectionProvider; -import org.eclipse.emf.edit.ui.util.EditUIUtil; -import org.eclipse.emf.eef.runtime.ui.EEFExtendedRuntime; -import org.eclipse.emf.eef.runtime.ui.editor.messages.MessageProcessor; -import org.eclipse.emf.eef.runtime.ui.editors.pages.tree.EEFTreeMDFormPage; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IStatusLineManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.dialogs.MessageDialog; -import org.eclipse.jface.dialogs.ProgressMonitorDialog; -import org.eclipse.jface.operation.IRunnableWithProgress; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.jface.viewers.TreeViewer; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.swt.SWT; -import org.eclipse.swt.custom.CTabFolder; -import org.eclipse.swt.dnd.DND; -import org.eclipse.swt.dnd.Transfer; -import org.eclipse.swt.events.ControlAdapter; -import org.eclipse.swt.events.ControlEvent; -import org.eclipse.swt.graphics.Point; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.FileDialog; -import org.eclipse.swt.widgets.Menu; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.IActionBars; -import org.eclipse.ui.IEditorInput; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IEditorSite; -import org.eclipse.ui.IPartListener; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.PartInitException; -import org.eclipse.ui.actions.ActionFactory; -import org.eclipse.ui.forms.editor.FormEditor; -import org.eclipse.ui.forms.editor.FormPage; -import org.eclipse.ui.ide.IGotoMarker; -import org.eclipse.ui.views.contentoutline.ContentOutline; -import org.eclipse.ui.views.contentoutline.ContentOutlinePage; -import org.eclipse.ui.views.contentoutline.IContentOutlinePage; - -/** - * - */ -public class InteractiveEEFEditor extends FormEditor implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker { - - public static final String EDITOR_ID = "org.eclipse.emf.eef.runtime.ui.editor.InteractiveEEFEditorID"; - - /** - * This keeps track of the editing domain that is used to track all changes to the model. - */ - protected EditingDomain editingDomain; - - /** - * This is the one adapter factory used for providing views of the model. - */ - protected AdapterFactory adapterFactory; - - /** - * This is the content outline page. - */ - protected IContentOutlinePage contentOutlinePage; - - /** - * This is a kludge... - */ - protected IStatusLineManager contentOutlineStatusLineManager; - - /** - * This is the content outline page's viewer. - */ - protected TreeViewer contentOutlineViewer; - - /** - * This is the viewer that shadows the selection in the content outline. The parent relation must be - * correctly defined for this to work. - */ - protected TreeViewer selectionViewer; - - /** - * This keeps track of the active content viewer, which may be either one of the viewers in the pages or - * the content outline viewer. - */ - protected Viewer currentViewer; - - /** - * This listens to which ever viewer is active. - */ - protected ISelectionChangedListener selectionChangedListener; - - /** - * This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are - * listening to this editor. - */ - protected Collection selectionChangedListeners = new ArrayList(); - - /** - * This keeps track of the selection of the editor as a whole. - */ - protected ISelection editorSelection = StructuredSelection.EMPTY; - - /** - * This listens for when the outline becomes active - */ - protected IPartListener partListener = new IPartListener() { - public void partActivated(IWorkbenchPart p) { - if (p instanceof ContentOutline) { - if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) { - getActionBarContributor().setActiveEditor(InteractiveEEFEditor.this); - - setCurrentViewer(contentOutlineViewer); - } - } else if (p == InteractiveEEFEditor.this) { - handleActivate(); - } - } - - public void partBroughtToTop(IWorkbenchPart p) { - // Ignore. - } - - public void partClosed(IWorkbenchPart p) { - // Ignore. - } - - public void partDeactivated(IWorkbenchPart p) { - // Ignore. - } - - public void partOpened(IWorkbenchPart p) { - // Ignore. - } - }; - - /** - * Resources that have been removed since last activation. - */ - protected Collection removedResources = new ArrayList(); - - /** - * Resources that have been changed since last activation. - */ - protected Collection changedResources = new ArrayList(); - - /** - * Resources that have been saved. - */ - protected Collection savedResources = new ArrayList(); - - /** - * Map to store the diagnostic associated with a resource. - */ - protected Map resourceToDiagnosticMap = new LinkedHashMap(); - - /** - * Controls whether the problem indication should be updated. - */ - protected boolean updateProblemIndication = true; - - /** - * Adapter used to update the problem indication when resources are demanded loaded. - */ - protected EContentAdapter problemIndicationAdapter = new EContentAdapter() { - @Override - public void notifyChanged(Notification notification) { - if (notification.getNotifier() instanceof Resource) { - switch (notification.getFeatureID(Resource.class)) { - case Resource.RESOURCE__IS_LOADED: - case Resource.RESOURCE__ERRORS: - case Resource.RESOURCE__WARNINGS: { - Resource resource = (Resource)notification.getNotifier(); - Diagnostic diagnostic = analyzeResourceProblems(resource, null); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, diagnostic); - } else { - resourceToDiagnosticMap.remove(resource); - } - - if (updateProblemIndication) { - getSite().getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - } - break; - } - } - } else { - super.notifyChanged(notification); - } - } - - @Override - protected void setTarget(Resource target) { - basicSetTarget(target); - } - - @Override - protected void unsetTarget(Resource target) { - basicUnsetTarget(target); - } - }; - - private IResourceChangeListener resourceChangeListener = null; - - /** - * This listens for workspace changes. - */ - private IResourceChangeListener initResourceChangeListener() { - IResourceChangeListener resourceChangeListner = new IResourceChangeListener() { - public void resourceChanged(IResourceChangeEvent event) { - IResourceDelta delta = event.getDelta(); - try { - class ResourceDeltaVisitor implements IResourceDeltaVisitor { - protected ResourceSet resourceSet = editingDomain.getResourceSet(); - - protected Collection changedResources = new ArrayList(); - - protected Collection removedResources = new ArrayList(); - - public boolean visit(IResourceDelta delta) { - if (delta.getResource().getType() == IResource.FILE) { - if (delta.getKind() == IResourceDelta.REMOVED - || delta.getKind() == IResourceDelta.CHANGED - && delta.getFlags() != IResourceDelta.MARKERS) { - Resource resource = resourceSet.getResource( - URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false); - if (resource != null) { - if (delta.getKind() == IResourceDelta.REMOVED) { - removedResources.add(resource); - } else if (!savedResources.remove(resource)) { - changedResources.add(resource); - } - } - } - } - - return true; - } - - public Collection getChangedResources() { - return changedResources; - } - - public Collection getRemovedResources() { - return removedResources; - } - } - - final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor(); - delta.accept(visitor); - - if (!visitor.getRemovedResources().isEmpty()) { - getSite().getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - removedResources.addAll(visitor.getRemovedResources()); - if (!isDirty()) { - getSite().getPage().closeEditor(InteractiveEEFEditor.this, false); - } - } - }); - } - - if (!visitor.getChangedResources().isEmpty()) { - getSite().getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - changedResources.addAll(visitor.getChangedResources()); - if (getSite().getPage().getActiveEditor() == InteractiveEEFEditor.this) { - handleActivate(); - } - } - }); - } - } catch (CoreException exception) { - EEFExtendedRuntime.INSTANCE.log(exception); - } - } - }; - return resourceChangeListner; - } - - protected MessageProcessor messageProcessor; - - /** - * Determines if the current edited resource is saving. - */ - private boolean isSaving = false; - - private IAction cutAction; - - private IAction copyAction; - - private IAction pasteAction; - - /** - * Handles activation of the editor or it's associated views. - */ - protected void handleActivate() { - // Recompute the read only state. - // - if (editingDomain instanceof AdapterFactoryEditingDomain - && ((AdapterFactoryEditingDomain)editingDomain).getResourceToReadOnlyMap() != null) { - ((AdapterFactoryEditingDomain)editingDomain).getResourceToReadOnlyMap().clear(); - - // Refresh any actions that may become enabled or disabled. - // - setSelection(getSelection()); - } - - if (!removedResources.isEmpty()) { - if (handleDirtyConflict()) { - getSite().getPage().closeEditor(InteractiveEEFEditor.this, false); - } else { - removedResources.clear(); - changedResources.clear(); - savedResources.clear(); - } - } else if (!changedResources.isEmpty()) { - changedResources.removeAll(savedResources); - handleChangedResources(); - changedResources.clear(); - savedResources.clear(); - } - } - - /** - * Handles what to do with changed resources on activation. - */ - protected void handleChangedResources() { - if (!changedResources.isEmpty() && (!isDirty() || (!isSaving && handleDirtyConflict()))) { - if (isDirty()) { - changedResources.addAll(editingDomain.getResourceSet().getResources()); - } - editingDomain.getCommandStack().flush(); - - updateProblemIndication = false; - for (Resource resource : changedResources) { - if (resource.isLoaded()) { - resource.unload(); - try { - resource.load(Collections.EMPTY_MAP); - } catch (IOException exception) { - if (!resourceToDiagnosticMap.containsKey(resource)) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - } - } - } - - if (AdapterFactoryEditingDomain.isStale(editorSelection)) { - setSelection(StructuredSelection.EMPTY); - } - - updateProblemIndication = true; - updateProblemIndication(); - } - } - - /** - * Updates the problems indication with the information described in the specified diagnostic. - */ - protected void updateProblemIndication() { - if (updateProblemIndication) { - BasicDiagnostic diagnostic = new BasicDiagnostic(Diagnostic.OK, EEFExtendedRuntime.PLUGIN_ID, 0, null, - new Object[] {editingDomain.getResourceSet()}); - for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) { - if (childDiagnostic.getSeverity() != Diagnostic.OK) { - diagnostic.add(childDiagnostic); - } - } - - int lastEditorPage = getPageCount() - 1; - if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) { - ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic); - if (diagnostic.getSeverity() != Diagnostic.OK) { - setActivePage(lastEditorPage); - } - } else if (diagnostic.getSeverity() != Diagnostic.OK) { - ProblemEditorPart problemEditorPart = new ProblemEditorPart(); - problemEditorPart.setDiagnostic(diagnostic); - try { - addPage(++lastEditorPage, problemEditorPart, getEditorInput()); - setPageText(lastEditorPage, problemEditorPart.getPartName()); - setActivePage(lastEditorPage); - showTabs(); - } catch (PartInitException exception) { - EEFExtendedRuntime.INSTANCE.log(exception); - } - } - } - } - - /** - * Shows a dialog that asks if conflicting changes should be discarded. - */ - protected boolean handleDirtyConflict() { - return MessageDialog.openQuestion(getSite().getShell(), - getString("UI_InteractiveEEFEditor_FileConflict_label"), - getString("WARN_InteractiveEEFEditor_FileConflict")); - } - - /** - * This creates a model editor. - */ - public InteractiveEEFEditor() { - super(); - initializeEditingDomain(); - messageProcessor = new MessageProcessor(); - } - - /** - * This sets up the editing domain for the model editor. - */ - protected void initializeEditingDomain() { - // Create an adapter factory that yields item providers. - // - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - ((ComposedAdapterFactory)adapterFactory).addAdapterFactory(new ResourceItemProviderAdapterFactory()); - ((ComposedAdapterFactory)adapterFactory).addAdapterFactory(new ReflectiveItemProviderAdapterFactory()); - resourceChangeListener = initResourceChangeListener(); - ResourcesPlugin.getWorkspace().addResourceChangeListener(resourceChangeListener, - IResourceChangeEvent.POST_CHANGE); - } - - /** - * This returns the editing domain as required by the {@link IEditingDomainProvider} interface. This is - * important for implementing the static methods of {@link AdapterFactoryEditingDomain} and for supporting - * {@link org.eclipse.emf.edit.ui.action.CommandAction}. - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * This makes sure that one content viewer, either for the current page or the outline view, if it has - * focus, is the current one. - */ - public void setCurrentViewer(Viewer viewer) { - // If it is changing... - // - if (currentViewer != viewer) { - if (selectionChangedListener == null) { - // Create the listener on demand. - // - selectionChangedListener = new ISelectionChangedListener() { - // This just notifies those things that are affected by the section. - // - public void selectionChanged(SelectionChangedEvent selectionChangedEvent) { - setSelection(selectionChangedEvent.getSelection()); - } - }; - } - - // Stop listening to the old one. - // - if (currentViewer != null) { - currentViewer.removeSelectionChangedListener(selectionChangedListener); - } - - // Start listening to the new one. - // - if (viewer != null) { - viewer.addSelectionChangedListener(selectionChangedListener); - } - - // Remember it. - // - currentViewer = viewer; - - // Set the editors selection based on the current viewer's selection. - // - setSelection(currentViewer == null ? StructuredSelection.EMPTY : currentViewer.getSelection()); - } - } - - /** - * This returns the viewer as required by the {@link IViewerProvider} interface. - */ - public Viewer getViewer() { - return currentViewer; - } - - /** - * This creates a context menu for the viewer and adds a listener as well registering the menu for - * extension. - */ - protected void createContextMenuFor(StructuredViewer viewer) { - MenuManager contextMenu = new MenuManager("#PopUp"); - contextMenu.add(new Separator("additions")); - contextMenu.setRemoveAllWhenShown(true); - contextMenu.addMenuListener(this); - Menu menu = contextMenu.createContextMenu(viewer.getControl()); - viewer.getControl().setMenu(menu); - getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer)); - - int dndOperations = DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK; - Transfer[] transfers = new Transfer[] {LocalTransfer.getInstance()}; - viewer.addDragSupport(dndOperations, transfers, new ViewerDragAdapter(viewer)); - viewer.addDropSupport(dndOperations, transfers, new EditingDomainViewerDropAdapter(editingDomain, viewer)); - } - - /** - * This is the method called to load a resource into the editing domain's resource set based on the - * editor's input. - */ - public void createModel() { - initializeWorkspaceEditingDomain(initializeCommandStack()); - editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter); - } - - /** - * @return - */ - protected BasicCommandStack initializeCommandStack() { - // Create the command stack that will notify this editor as commands are executed. - // - BasicCommandStack commandStack = new BasicCommandStack(); - // Add a listener to set the most recent command's affected objects to be the selection of the viewer - // with focus. - // - commandStack.addCommandStackListener(new CommandStackListener() { - public void commandStackChanged(final EventObject event) { - getContainer().getDisplay().asyncExec(new Runnable() { - public void run() { - firePropertyChange(IEditorPart.PROP_DIRTY); - - // Try to select the affected objects. - // - Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand(); - if (mostRecentCommand != null) { - setSelectionToViewer(mostRecentCommand.getAffectedObjects()); - } - } - }); - } - }); - - // Create the editing domain with a special command stack. - // - return commandStack; - } - - /** - * @param commandStack - */ - protected void initializeWorkspaceEditingDomain(BasicCommandStack commandStack) { - ResourceSet resourceSet = initializeResourceSet(); - if (resourceSet != null) { - editingDomain = new AdapterFactoryEditingDomain(adapterFactory, commandStack, resourceSet); - } else { - editingDomain = new AdapterFactoryEditingDomain(adapterFactory, commandStack); - } - URI resourceURI = EditUIUtil.getURI(getEditorInput()); - Exception exception = null; - Resource resource = null; - try { - // Load the resource through the editing domain. - // - resource = editingDomain.getResourceSet().getResource(resourceURI, true); - } catch (Exception e) { - exception = e; - resource = editingDomain.getResourceSet().getResource(resourceURI, false); - } - - Diagnostic diagnostic = analyzeResourceProblems(resource, exception); - if (diagnostic.getSeverity() != Diagnostic.OK) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter); - } - - /** - * @return the {@link ResourceSet} to use in the {@link EditingDomain}. If null then use the - * standard ResourceSet. - */ - protected ResourceSet initializeResourceSet() { - return null; - } - - /** - * Returns a diagnostic describing the errors and warnings listed in the resource and the specified - * exception (if any). - */ - public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) { - if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) { - BasicDiagnostic basicDiagnostic = new BasicDiagnostic(Diagnostic.ERROR, EEFExtendedRuntime.PLUGIN_ID, 0, - getString("UI_InteractiveEEFEditor_CreateModelError_message", resource.getURI()), - new Object[] {exception == null ? (Object)resource : exception}); - basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true)); - return basicDiagnostic; - } else if (exception != null) { - return new BasicDiagnostic(Diagnostic.ERROR, EEFExtendedRuntime.PLUGIN_ID, 0, getString( - "UI_InteractiveEEFEditor_CreateModelError_message", resource.getURI()), new Object[] {exception}); - } else { - return Diagnostic.OK_INSTANCE; - } - } - - /** - * This is the method used by the framework to install your own controls. - */ - @Override - public void addPages() { - // Creates the model from the editor input - // - createModel(); - - contributePages(); - - // Ensures that this editor will only display the page's tab - // area if there are more than one page - // - getContainer().addControlListener(new ControlAdapter() { - boolean guard = false; - - public void controlResized(ControlEvent event) { - if (!guard) { - guard = true; - hideTabs(); - guard = false; - } - } - }); - - getSite().getShell().getDisplay().asyncExec(new Runnable() { - public void run() { - updateProblemIndication(); - } - }); - - } - - protected void contributePages() { - try { - addDefaultPage(); - } catch (PartInitException e) { - EEFExtendedRuntime.getPlugin().log(e); - } - } - - /** - * @throws PartInitException - */ - protected void addDefaultPage() throws PartInitException { - EEFTreeMDFormPage mainPage = new EEFTreeMDFormPage(this, "main") { - - public void createPartControl(Composite parent) { - super.createPartControl(parent); - setPageTitle("main"); - getModelViewer().addSelectionChangedListener(new ISelectionChangedListener() { - // This just notifies those things that are affected by the section. - // - public void selectionChanged(SelectionChangedEvent selectionChangedEvent) { - setSelection(selectionChangedEvent.getSelection()); - } - }); - - } - }; - mainPage.setAdapterFactory(adapterFactory); - mainPage.setEditingDomain(editingDomain); - mainPage.setInput(editingDomain.getResourceSet()); - addPage(mainPage); - } - - public List getPages() { - List result = new ArrayList(); - for (Object page : pages) { - if (page instanceof FormPage) { - FormPage formPage = (FormPage)page; - result.add(formPage); - } - } - return result; - } - - /** - * If there is just one page in the multi-page editor part, this hides the single tab at the bottom. - */ - protected void hideTabs() { - if (getPageCount() <= 1) { - setPageText(0, ""); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(1); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y + 6); - } - } - } - - /** - * If there is more than one page in the multi-page editor part, this shows the tabs at the bottom. - */ - protected void showTabs() { - if (getPageCount() > 1) { - setPageText(0, getString("UI_SelectionPage_label")); - if (getContainer() instanceof CTabFolder) { - ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT); - Point point = getContainer().getSize(); - getContainer().setSize(point.x, point.y - 6); - } - } - } - - /** - * This is used to track the active viewer. - */ - @Override - protected void pageChange(int pageIndex) { - super.pageChange(pageIndex); - messageProcessor.init(this); - if (contentOutlinePage != null) { - handleContentOutlineSelection(contentOutlinePage.getSelection()); - } - - } - - /** - * This is how the framework determines which interfaces we implement. - */ - @SuppressWarnings("rawtypes") - @Override - public Object getAdapter(Class key) { - if (key.equals(IContentOutlinePage.class)) { - return showOutlineView() ? getContentOutlinePage() : null; - } else { - return super.getAdapter(key); - } - } - - /** - * This accesses a cached version of the content outliner. - */ - public IContentOutlinePage getContentOutlinePage() { - if (contentOutlinePage == null) { - // The content outline is just a tree. - // - class MyContentOutlinePage extends ContentOutlinePage { - @Override - public void createControl(Composite parent) { - super.createControl(parent); - contentOutlineViewer = getTreeViewer(); - contentOutlineViewer.addSelectionChangedListener(this); - - // Set up the tree viewer. - // - contentOutlineViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); - contentOutlineViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory)); - contentOutlineViewer.setInput(editingDomain.getResourceSet()); - - // Make sure our popups work. - // - createContextMenuFor(contentOutlineViewer); - - if (!editingDomain.getResourceSet().getResources().isEmpty()) { - // Select the root object in the view. - // - contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet() - .getResources().get(0)), true); - } - } - - @Override - public void makeContributions(IMenuManager menuManager, IToolBarManager toolBarManager, - IStatusLineManager statusLineManager) { - super.makeContributions(menuManager, toolBarManager, statusLineManager); - contentOutlineStatusLineManager = statusLineManager; - } - - @Override - public void setActionBars(IActionBars actionBars) { - super.setActionBars(actionBars); - getActionBarContributor().shareGlobalActions(this, actionBars); - } - } - - contentOutlinePage = new MyContentOutlinePage(); - - // Listen to selection so that we can handle it is a special way. - // - contentOutlinePage.addSelectionChangedListener(new ISelectionChangedListener() { - // This ensures that we handle selections correctly. - // - public void selectionChanged(SelectionChangedEvent event) { - handleContentOutlineSelection(event.getSelection()); - } - }); - } - - return contentOutlinePage; - } - - /** - * This deals with how we want selection in the outliner to affect the other views. - */ - public void handleContentOutlineSelection(ISelection selection) { - if (selectionViewer != null && !selection.isEmpty() && selection instanceof IStructuredSelection) { - Iterator selectedElements = ((IStructuredSelection)selection).iterator(); - if (selectedElements.hasNext()) { - // Get the first selected element. - // - Object selectedElement = selectedElements.next(); - - ArrayList selectionList = new ArrayList(); - selectionList.add(selectedElement); - while (selectedElements.hasNext()) { - selectionList.add(selectedElements.next()); - } - - // Set the selection to the widget. - // - selectionViewer.setSelection(new StructuredSelection(selectionList)); - } - } - } - - /** - * This is for implementing {@link IEditorPart} and simply tests the command stack. - */ - @Override - public boolean isDirty() { - return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded(); - } - - /** - * This is for implementing {@link IEditorPart} and simply saves the model file. - */ - @Override - public void doSave(IProgressMonitor progressMonitor) { - // Save only resources that have actually changed. - // - final Map saveOptions = new HashMap(); - saveOptions.put(Resource.OPTION_SAVE_ONLY_IF_CHANGED, Resource.OPTION_SAVE_ONLY_IF_CHANGED_MEMORY_BUFFER); - - // Do the work within an operation because this is a long running activity that modifies the - // workbench. - // - IRunnableWithProgress operation = new IRunnableWithProgress() { - // This is the method that gets invoked when the operation runs. - // - public void run(IProgressMonitor monitor) { - // Save the resources to the file system. - // - boolean first = true; - for (Resource resource : editingDomain.getResourceSet().getResources()) { - if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) - && !editingDomain.isReadOnly(resource)) { - try { - long timeStamp = resource.getTimeStamp(); - resource.save(saveOptions); - if (resource.getTimeStamp() != timeStamp) { - savedResources.add(resource); - } - } catch (Exception exception) { - resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); - } - first = false; - } - } - } - }; - - updateProblemIndication = false; - try { - // This runs the options, and shows progress. - // - isSaving = true; - new ProgressMonitorDialog(getSite().getShell()).run(true, false, operation); - isSaving = false; - - // Refresh the necessary state. - // - ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone(); - firePropertyChange(IEditorPart.PROP_DIRTY); - } catch (Exception exception) { - // Something went wrong that shouldn't. - // - EEFExtendedRuntime.INSTANCE.log(exception); - } - updateProblemIndication = true; - updateProblemIndication(); - } - - /** - * This returns whether something has been persisted to the URI of the specified resource. The - * implementation uses the URI converter from the editor's resource set to try to open an input stream. - */ - protected boolean isPersisted(Resource resource) { - boolean result = false; - try { - InputStream stream = editingDomain.getResourceSet().getURIConverter().createInputStream(resource.getURI()); - if (stream != null) { - result = true; - stream.close(); - } - } catch (IOException e) { - // Ignore - } - return result; - } - - /** - * This always returns true because it is not currently supported. - */ - @Override - public boolean isSaveAsAllowed() { - return true; - } - - /** - * This also changes the editor's input. - */ - @Override - public void doSaveAs() { - String[] files = openFilePathDialog(getSite().getShell(), SWT.SAVE, new String[0]); - if (files.length > 0) { - URI uri = URI.createFileURI(files[0]); - doSaveAs(uri, new URIEditorInput(uri)); - } - } - - /** - */ - public static String[] openFilePathDialog(Shell shell, int style, String[] fileExtensionFilters) { - return openFilePathDialog(shell, style, fileExtensionFilters, (style & SWT.OPEN) != 0, (style & SWT.OPEN) != 0, - (style & SWT.SAVE) != 0); - } - - /** - */ - public static String[] openFilePathDialog(Shell shell, int style, String[] fileExtensionFilters, - boolean includeGroupFilter, boolean includeAllFilter, boolean addExtension) { - FileDialog fileDialog = new FileDialog(shell, style); - - // If requested, augment the file extension filters by adding a group of all the other filters - // (*.ext1;*.ext2;...) - // at the beginning and/or an all files wildcard (*.*) at the end. - // - includeGroupFilter &= fileExtensionFilters.length > 1; - int offset = includeGroupFilter ? 1 : 0; - - if (includeGroupFilter || includeAllFilter) { - int size = fileExtensionFilters.length + offset + (includeAllFilter ? 1 : 0); - String[] allFilters = new String[size]; - StringBuilder group = includeGroupFilter ? new StringBuilder() : null; - - for (int i = 0; i < fileExtensionFilters.length; i++) { - if (includeGroupFilter) { - if (i != 0) { - group.append(';'); - } - group.append(fileExtensionFilters[i]); - } - allFilters[i + offset] = fileExtensionFilters[i]; - } - - if (includeGroupFilter) { - allFilters[0] = group.toString(); - } - if (includeAllFilter) { - allFilters[allFilters.length - 1] = "*.*"; - } - - fileDialog.setFilterExtensions(allFilters); - } else { - fileDialog.setFilterExtensions(fileExtensionFilters); - } - fileDialog.open(); - - String[] filenames = fileDialog.getFileNames(); - String[] result = new String[filenames.length]; - String path = fileDialog.getFilterPath() + File.separator; - String extension = null; - - // If extension adding requested, get the dotted extension corresponding to the selected filter. - // - if (addExtension) { - int i = fileDialog.getFilterIndex(); - if (i != -1 && (!includeAllFilter || i != fileExtensionFilters.length)) { - i = includeGroupFilter && i == 0 ? 0 : i - offset; - String filter = fileExtensionFilters[i]; - int dot = filter.lastIndexOf('.'); - if (dot == 1 && filter.charAt(0) == '*') { - extension = filter.substring(dot); - } - } - } - - // Build the result by adding the selected path and, if needed, auto-appending the extension. - // - for (int i = 0; i < filenames.length; i++) { - String filename = path + filenames[i]; - if (extension != null) { - int dot = filename.lastIndexOf('.'); - if (dot == -1 || !Arrays.asList(fileExtensionFilters).contains("*" + filename.substring(dot))) { - filename += extension; - } - } - result[i] = filename; - } - return result; - } - - /** - */ - protected void doSaveAs(URI uri, IEditorInput editorInput) { - (editingDomain.getResourceSet().getResources().get(0)).setURI(uri); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - IActionBars actionBars = getActionBars(); - IProgressMonitor progressMonitor = actionBars != null && actionBars.getStatusLineManager() != null ? actionBars - .getStatusLineManager().getProgressMonitor() : new NullProgressMonitor(); - doSave(progressMonitor); - } - - /** - * This is called during startup. - */ - @Override - public void init(IEditorSite site, IEditorInput editorInput) { - setSite(site); - setInputWithNotify(editorInput); - setPartName(editorInput.getName()); - site.setSelectionProvider(this); - site.getPage().addPartListener(partListener); - } - - /** - */ - @Override - public void setFocus() { - getControl(getActivePage()).setFocus(); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - */ - public void addSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.add(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. - */ - public void removeSelectionChangedListener(ISelectionChangedListener listener) { - selectionChangedListeners.remove(listener); - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall - * selection. - */ - public ISelection getSelection() { - return editorSelection; - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to set this editor's overall - * selection. Calling this result will notify the listeners. - */ - public void setSelection(ISelection selection) { - editorSelection = selection; - - for (ISelectionChangedListener listener : selectionChangedListeners) { - listener.selectionChanged(new SelectionChangedEvent(this, selection)); - } - setStatusLineManager(selection); - } - - /** - */ - public void setStatusLineManager(ISelection selection) { - IActionBars actionBars = getActionBars(); - if (actionBars != null) { - IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ? contentOutlineStatusLineManager - : actionBars.getStatusLineManager(); - - if (statusLineManager != null) { - if (selection instanceof IStructuredSelection) { - Collection collection = ((IStructuredSelection)selection).toList(); - switch (collection.size()) { - case 0: { - statusLineManager.setMessage(getString("UI_InteractiveEEFEditor_NoObjectSelected")); - break; - } - case 1: { - String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator() - .next()); - statusLineManager - .setMessage(getString("UI_InteractiveEEFEditor_SingleObjectSelected", text)); - break; - } - default: { - statusLineManager.setMessage(getString("UI_InteractiveEEFEditor_MultiObjectSelected", - Integer.toString(collection.size()))); - break; - } - } - } else { - statusLineManager.setMessage(""); - } - } - } - } - - /** - * This looks up a string in the plugin's plugin.properties file. - */ - private static String getString(String key) { - return EEFExtendedRuntime.INSTANCE.getString(key); - } - - /** - * This looks up a string in plugin.properties, making a substitution. - */ - private static String getString(String key, Object s1) { - return EEFExtendedRuntime.INSTANCE.getString(key, new Object[] {s1}); - } - - /** - * This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with - * contributions from the Edit menu. - */ - public void menuAboutToShow(IMenuManager menuManager) { - ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager); - } - - /** - */ - public EditingDomainActionBarContributor getActionBarContributor() { - return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor(); - } - - /** - */ - public IActionBars getActionBars() { - if (getActionBarContributor() != null) { - if (cutAction == null) - cutAction = getActionBarContributor().getActionBars().getGlobalActionHandler(ActionFactory.CUT.getId()); - if (copyAction == null) - copyAction = getActionBarContributor().getActionBars().getGlobalActionHandler( - ActionFactory.COPY.getId()); - if (pasteAction == null) - pasteAction = getActionBarContributor().getActionBars().getGlobalActionHandler( - ActionFactory.PASTE.getId()); - return getActionBarContributor().getActionBars(); - } else { - return null; - } - } - - /** - */ - public AdapterFactory getAdapterFactory() { - return adapterFactory; - } - - /** - */ - @Override - public void dispose() { - updateProblemIndication = false; - - getSite().getPage().removePartListener(partListener); - - if (adapterFactory instanceof ComposedAdapterFactory) - ((ComposedAdapterFactory)adapterFactory).dispose(); - - if (getActionBarContributor().getActiveEditor() == this) { - getActionBarContributor().setActiveEditor(null); - } - - if (contentOutlinePage != null) { - contentOutlinePage.dispose(); - } - - if (resourceChangeListener != null) { - ResourcesPlugin.getWorkspace().removeResourceChangeListener(resourceChangeListener); - } - super.dispose(); - } - - /** - * Returns whether the outline view should be presented to the user. - */ - protected boolean showOutlineView() { - return false; - } - - public void gotoMarker(IMarker marker) { - try { - if (marker.getType().equals(EValidator.MARKER)) { - String uriAttribute = marker.getAttribute(EValidator.URI_ATTRIBUTE, null); - if (uriAttribute != null) { - URI uri = URI.createURI(uriAttribute); - EObject eObject = editingDomain.getResourceSet().getEObject(uri, true); - if (eObject != null) { - setSelectionToViewer(Collections.singleton(((AdapterFactoryEditingDomain)editingDomain) - .getWrapper(eObject))); - } - } - } - } catch (CoreException exception) { - EEFExtendedRuntime.INSTANCE.log(exception); - } - } - - /** - * This sets the selection into whichever viewer is active. - */ - public void setSelectionToViewer(Collection collection) { - final Collection theSelection = collection; - // Make sure it's okay. - // - if (theSelection != null && !theSelection.isEmpty()) { - Runnable runnable = new Runnable() { - public void run() { - // Try to select the items in the model content viewer of the editor. - // - Viewer modelViewer = getModelViewer(); - if (modelViewer != null) { - modelViewer.setSelection(new StructuredSelection(theSelection.toArray()), true); - } - } - }; - getSite().getShell().getDisplay().asyncExec(runnable); - } - } - - /** - * Returns the viewer showing model contents - * - * @return - */ - protected StructuredViewer getModelViewer() { - if (getPages() != null && getPages().size() > 0) { - if (getPages().get(0) instanceof EEFTreeMDFormPage) { - return ((EEFTreeMDFormPage)getPages().get(0)).getModelViewer(); - } - } - return null; - } - - /** - * used to activate global cut/copy/paste actions. - * - * @since 1.1 - */ - public void activateCCPActions() { - getActionBars().setGlobalActionHandler(ActionFactory.CUT.getId(), cutAction); - getActionBars().setGlobalActionHandler(ActionFactory.COPY.getId(), copyAction); - getActionBars().setGlobalActionHandler(ActionFactory.PASTE.getId(), pasteAction); - getActionBars().updateActionBars(); - } - - /** - * used to de-activate global cut/copy/paste actions. - * - * @since 1.1 - */ - public void deactivateCCPActions() { - getActionBars().setGlobalActionHandler(ActionFactory.CUT.getId(), null); - getActionBars().setGlobalActionHandler(ActionFactory.COPY.getId(), null); - getActionBars().setGlobalActionHandler(ActionFactory.PASTE.getId(), null); - getActionBars().updateActionBars(); - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/InteractiveEEFEditorActionBarContributor.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/InteractiveEEFEditorActionBarContributor.java deleted file mode 100644 index 8f61becfc..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/InteractiveEEFEditorActionBarContributor.java +++ /dev/null @@ -1,366 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editor; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.ui.viewer.IViewerProvider; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; -import org.eclipse.emf.edit.ui.action.ControlAction; -import org.eclipse.emf.edit.ui.action.CreateChildAction; -import org.eclipse.emf.edit.ui.action.CreateSiblingAction; -import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; -import org.eclipse.emf.edit.ui.action.LoadResourceAction; -import org.eclipse.emf.edit.ui.action.ValidateAction; -import org.eclipse.emf.eef.runtime.ui.EEFExtendedRuntime; -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.ActionContributionItem; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.action.IContributionItem; -import org.eclipse.jface.action.IContributionManager; -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.IMenuManager; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.action.SubContributionItem; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.ISelectionProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.PartInitException; - -/** - */ -public class InteractiveEEFEditorActionBarContributor extends EditingDomainActionBarContributor implements ISelectionChangedListener { - /** - * This keeps track of the active editor. - */ - protected IEditorPart activeEditorPart; - - /** - * This keeps track of the current selection provider. - */ - protected ISelectionProvider selectionProvider; - - /** - * This action opens the Properties view. - */ - protected IAction showPropertiesViewAction = new Action( - EEFExtendedRuntime.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) { - @Override - public void run() { - try { - getPage().showView("org.eclipse.ui.views.PropertySheet"); - } catch (PartInitException exception) { - EEFExtendedRuntime.INSTANCE.log(exception); - } - } - }; - - /** - * This action refreshes the viewer of the current editor if the editor implements - * {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}. - */ - protected IAction refreshViewerAction = new Action( - EEFExtendedRuntime.INSTANCE.getString("_UI_RefreshViewer_menu_item")) { - @Override - public boolean isEnabled() { - return activeEditorPart instanceof IViewerProvider; - } - - @Override - public void run() { - if (activeEditorPart instanceof IViewerProvider) { - Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer(); - if (viewer != null) { - viewer.refresh(); - } - } - } - }; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each - * descriptor generated for the current selection by the item provider. - */ - protected Collection createChildActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateChild actions. - */ - protected IMenuManager createChildMenuManager; - - /** - * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} corresponding to each - * descriptor generated for the current selection by the item provider. - */ - protected Collection createSiblingActions; - - /** - * This is the menu manager into which menu contribution items should be added for CreateSibling actions. - */ - protected IMenuManager createSiblingMenuManager; - - /** - * This creates an instance of the contributor. - */ - public InteractiveEEFEditorActionBarContributor() { - super(ADDITIONS_LAST_STYLE); - loadResourceAction = new LoadResourceAction(); - validateAction = new ValidateAction(); - controlAction = new ControlAction(); - } - - /** - * This adds Separators for editor additions to the tool bar. - */ - @Override - public void contributeToToolBar(IToolBarManager toolBarManager) { - toolBarManager.add(new Separator("interactive-eef-editor-settings")); - toolBarManager.add(new Separator("interactive-eef-editor-additions")); - } - - /** - * This adds to the menu bar a menu and some separators for editor additions, as well as the sub-menus for - * object creation items. - */ - @Override - public void contributeToMenu(IMenuManager menuManager) { - super.contributeToMenu(menuManager); - - IMenuManager submenuManager = new MenuManager( - EEFExtendedRuntime.INSTANCE.getString("UI_InteractiveEEFEditor_menu"), - "fr.obeo.eef.runtime.extended.InteractiveEEFEditorMenuID"); - menuManager.insertAfter("additions", submenuManager); - submenuManager.add(new Separator("settings")); - submenuManager.add(new Separator("actions")); - submenuManager.add(new Separator("additions")); - submenuManager.add(new Separator("additions-end")); - - // Prepare for CreateChild item addition or removal. - // - createChildMenuManager = new MenuManager( - EEFExtendedRuntime.INSTANCE.getString("_UI_CreateChild_menu_item")); - submenuManager.insertBefore("additions", createChildMenuManager); - - // Prepare for CreateSibling item addition or removal. - // - createSiblingMenuManager = new MenuManager( - EEFExtendedRuntime.INSTANCE.getString("_UI_CreateSibling_menu_item")); - submenuManager.insertBefore("additions", createSiblingMenuManager); - - // Force an update because Eclipse hides empty menus now. - // - submenuManager.addMenuListener(new IMenuListener() { - public void menuAboutToShow(IMenuManager menuManager) { - menuManager.updateAll(true); - } - }); - - addGlobalActions(submenuManager); - } - - /** - * When the active editor changes, this remembers the change and registers with it as a selection - * provider. - */ - @Override - public void setActiveEditor(IEditorPart part) { - super.setActiveEditor(part); - activeEditorPart = part; - - // Switch to the new selection provider. - // - if (selectionProvider != null) { - selectionProvider.removeSelectionChangedListener(this); - } - if (part == null) { - selectionProvider = null; - } else { - selectionProvider = part.getSite().getSelectionProvider(); - selectionProvider.addSelectionChangedListener(this); - - // Fake a selection changed event to update the menus. - // - if (selectionProvider.getSelection() != null) { - selectionChanged(new SelectionChangedEvent(selectionProvider, - selectionProvider.getSelection())); - } - } - } - - /** - * This implements {@link org.eclipse.jface.viewers.ISelectionChangedListener}, handling - * {@link org.eclipse.jface.viewers.SelectionChangedEvent}s by querying for the children and siblings that - * can be added to the selected object and updating the menus accordingly. - */ - public void selectionChanged(SelectionChangedEvent event) { - // Remove any menu items for old selection. - // - if (createChildMenuManager != null) { - depopulateManager(createChildMenuManager, createChildActions); - } - if (createSiblingMenuManager != null) { - depopulateManager(createSiblingMenuManager, createSiblingActions); - } - - // Query the new selection for appropriate new child/sibling descriptors - // - Collection newChildDescriptors = null; - Collection newSiblingDescriptors = null; - - ISelection selection = event.getSelection(); - if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) { - Object object = ((IStructuredSelection)selection).getFirstElement(); - - EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain(); - - newChildDescriptors = domain.getNewChildDescriptors(object, null); - newSiblingDescriptors = domain.getNewChildDescriptors(null, object); - } - - // Generate actions for selection; populate and redraw the menus. - // - createChildActions = generateCreateChildActions(newChildDescriptors, selection); - createSiblingActions = generateCreateSiblingActions(newSiblingDescriptors, selection); - - if (createChildMenuManager != null) { - populateManager(createChildMenuManager, createChildActions, null); - createChildMenuManager.update(true); - } - if (createSiblingMenuManager != null) { - populateManager(createSiblingMenuManager, createSiblingActions, null); - createSiblingMenuManager.update(true); - } - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateChildAction} for each object in - * descriptors, and returns the collection of these actions. - */ - protected Collection generateCreateChildActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateChildAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This generates a {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} for each object in - * descriptors, and returns the collection of these actions. - */ - protected Collection generateCreateSiblingActions(Collection descriptors, ISelection selection) { - Collection actions = new ArrayList(); - if (descriptors != null) { - for (Object descriptor : descriptors) { - actions.add(new CreateSiblingAction(activeEditorPart, selection, descriptor)); - } - } - return actions; - } - - /** - * This populates the specified manager with - * {@link org.eclipse.jface.action.ActionContributionItem}s based on the - * {@link org.eclipse.jface.action.IAction}s contained in the actions collection, by - * inserting them before the specified contribution item contributionID. If - * contributionID is null, they are simply added. - */ - protected void populateManager(IContributionManager manager, Collection actions, - String contributionID) { - if (actions != null) { - for (IAction action : actions) { - if (contributionID != null) { - manager.insertBefore(contributionID, action); - } else { - manager.add(action); - } - } - } - } - - /** - * This removes from the specified manager all - * {@link org.eclipse.jface.action.ActionContributionItem}s based on the - * {@link org.eclipse.jface.action.IAction}s contained in the actions collection. - */ - protected void depopulateManager(IContributionManager manager, Collection actions) { - if (actions != null) { - IContributionItem[] items = manager.getItems(); - for (int i = 0; i < items.length; i++) { - // Look into SubContributionItems - // - IContributionItem contributionItem = items[i]; - while (contributionItem instanceof SubContributionItem) { - contributionItem = ((SubContributionItem)contributionItem).getInnerItem(); - } - - // Delete the ActionContributionItems with matching action. - // - if (contributionItem instanceof ActionContributionItem) { - IAction action = ((ActionContributionItem)contributionItem).getAction(); - if (actions.contains(action)) { - manager.remove(contributionItem); - } - } - } - } - } - - /** - * This populates the pop-up menu before it appears. - */ - @Override - public void menuAboutToShow(IMenuManager menuManager) { - super.menuAboutToShow(menuManager); - MenuManager submenuManager = null; - - submenuManager = new MenuManager(EEFExtendedRuntime.INSTANCE.getString("_UI_CreateChild_menu_item")); - populateManager(submenuManager, createChildActions, null); - menuManager.insertBefore("edit", submenuManager); - - submenuManager = new MenuManager(EEFExtendedRuntime.INSTANCE.getString("_UI_CreateSibling_menu_item")); - populateManager(submenuManager, createSiblingActions, null); - menuManager.insertBefore("edit", submenuManager); - } - - /** - * This inserts global actions before the "additions-end" separator. - */ - @Override - protected void addGlobalActions(IMenuManager menuManager) { - menuManager.insertAfter("additions-end", new Separator("ui-actions")); - menuManager.insertAfter("ui-actions", showPropertiesViewAction); - - refreshViewerAction.setEnabled(refreshViewerAction.isEnabled()); - menuManager.insertAfter("ui-actions", refreshViewerAction); - - super.addGlobalActions(menuManager); - } - - /** - * This ensures that a delete action will clean up all references to deleted objects. - */ - @Override - protected boolean removeAllReferencesOnDelete() { - return true; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/messages/MessageHandler.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/messages/MessageHandler.java deleted file mode 100644 index 1fbd9489e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/messages/MessageHandler.java +++ /dev/null @@ -1,42 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editor.messages; - -import org.eclipse.ui.forms.events.HyperlinkEvent; - -/** - * @author glefur - * - */ -public abstract class MessageHandler { - - protected MessageProcessor processor; - - /** - * @param event the event to handle - * @return true if the handle have to be processed. - */ - public abstract boolean handle(HyperlinkEvent event); - - /** - * Process the given message. - * @param event the event to handle. - */ - public abstract void process(HyperlinkEvent event); - - /** - * @param superHandler the superHandler to set - */ - public void setProcessor(MessageProcessor superHandler) { - this.processor = superHandler; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/messages/MessageProcessor.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/messages/MessageProcessor.java deleted file mode 100644 index 242295886..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editor/messages/MessageProcessor.java +++ /dev/null @@ -1,110 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editor.messages; - -import java.util.Collection; -import java.util.HashSet; -import java.util.Iterator; - -import org.eclipse.emf.eef.runtime.ui.editor.InteractiveEEFEditor; -import org.eclipse.swt.widgets.Control; -import org.eclipse.ui.forms.IMessageManager; -import org.eclipse.ui.forms.editor.FormEditor; -import org.eclipse.ui.forms.editor.FormPage; -import org.eclipse.ui.forms.events.HyperlinkAdapter; -import org.eclipse.ui.forms.events.HyperlinkEvent; - - -/** - * @author glefur - * - */ -public class MessageProcessor extends HyperlinkAdapter { - - private FormEditor formEditor; - private Collection handlers; - - /** - * - */ - public MessageProcessor() { - handlers = new HashSet(); - } - - /** - * @param editor - */ - public void init(InteractiveEEFEditor editor) { - this.formEditor = editor; - for (@SuppressWarnings("rawtypes") Iterator iterator = editor.getPages().iterator(); iterator.hasNext();) { - Object page = iterator.next(); - //TODO: reactivate this -// if (page instanceof FormPage) -// ((FormPage)page).getManagedForm().getForm().getForm().addMessageHyperlinkListener(this); - } - } - - /** - * @param handler the handler to add. - */ - public void addHandler(MessageHandler handler) { - handler.setProcessor(this); - handlers.add(handler); - } - - /** - * @param handler the handler to remove. - */ - public void removeHandler(MessageHandler handler) { - handlers.remove(handler); - } - - /** - * {@inheritDoc} - * @see org.eclipse.ui.forms.events.HyperlinkAdapter#linkActivated(org.eclipse.ui.forms.events.HyperlinkEvent) - */ - public void linkActivated(HyperlinkEvent event) { - for (MessageHandler handler : handlers) { - if (handler.handle(event)) - handler.process(event); - } - } - - /** - * Add a message to the form editor header - * @param key a unique key to identify message - * @param message the message to display - * @param severity the message severity - */ - public void addMessage(final Object key, final String message, final int severity) { - if (formEditor.getSelectedPage() instanceof FormPage) { - final FormPage selectedPage = (FormPage) formEditor.getSelectedPage(); - selectedPage.getPartControl().getDisplay().asyncExec(new Runnable() { - - public void run() { - IMessageManager messageManager = selectedPage.getManagedForm().getMessageManager(); - messageManager.addMessage(key, message, null, severity); - } - }); - } - } - - /** - * Remove the messages associated to the given event. - * @param control the key control. - */ - public void removeAssociatedMessages(Control control) { - if (formEditor.getSelectedPage() instanceof FormPage) { - ((FormPage) formEditor.getSelectedPage()).getManagedForm().getMessageManager().removeMessages(control); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/AbstractEEFEditorPage.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/AbstractEEFEditorPage.java deleted file mode 100644 index cb457a01f..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/AbstractEEFEditorPage.java +++ /dev/null @@ -1,271 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editors.pages; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.IToolBarManager; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.graphics.Image; -import org.eclipse.ui.forms.editor.FormEditor; -import org.eclipse.ui.forms.editor.FormPage; -import org.eclipse.ui.forms.widgets.ScrolledForm; - -/** - * @author Goulwen Le Fur - */ - -public abstract class AbstractEEFEditorPage extends FormPage implements EEFEditorPage { - /** - * Form of this page - */ - protected ScrolledForm form; - - /** - * This keeps track of the editing domain that is used to track all changes to the model. - */ - protected EditingDomain editingDomain; - - /** - * AdapterFactory to use - */ - protected AdapterFactory adapterFactory; - - /** - * Page input - */ - protected Object input; - - /** - * Page title - */ - private String pageTitle; - - /** - * Page image - */ - private Image pageImage; - - /** - * Page filters - */ - protected List filters; - - /** - * Page actions - */ - protected List actions; - - /** - * @param editor - * containing editor - * @param id - * page id - * @param name - * page name - */ - public AbstractEEFEditorPage(FormEditor editor, String id, String name) { - super(editor, id, name); - this.filters = new ArrayList(); - this.actions = new ArrayList(); - } - - /** - * @return the editingDomain - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * @param editingDomain - * the editingDomain to set - */ - public void setEditingDomain(EditingDomain editingDomain) { - this.editingDomain = editingDomain; - } - - /** - * @return the adapterFactory - */ - public AdapterFactory getAdapterFactory() { - return adapterFactory; - } - - /** - * @param adapterFactory - * the adapterFactory to set - */ - public void setAdapterFactory(AdapterFactory adapterFactory) { - this.adapterFactory = adapterFactory; - } - - /** - * Defines the title of the page - * - * @param title - * the title to define - */ - public void setPageTitle(String title) { - if (title != null) { - this.pageTitle = title; - if (formInitialized()) - refreshFormTitle(); - } - } - - /** - * Sets the image to be rendered to the left of the title. - * - * @param image - * the title image - */ - public void setImage(Image image) { - if (image != null) { - this.pageImage = image; - if (formInitialized()) { - refreshFormImage(); - } - } - } - - /** - * @return true if the form is initialized - */ - protected boolean formInitialized() { - return form != null; - } - - /** - * @param input - * the input of the page - */ - public void setInput(Object newEObject) { - if (newEObject != input) { - input = newEObject; - refresh(); - } - } - - public void refresh() { - if (formInitialized()) { - refreshFilters(); - refreshFormContents(); - refreshFormTitle(); - refreshFormImage(); - refreshToolbar(); - } - } - - /** - * refresh page actions. - */ - protected void refreshToolbar() { - if (getManagedForm().getForm() != null) { - if (!actions.isEmpty()) { - IToolBarManager toolBarManager = getManagedForm().getForm().getToolBarManager(); - for (Action action : actions) { - toolBarManager.add(action); - } - toolBarManager.update(true); - } - } - } - - /** - * Refresh the form title - */ - protected void refreshFormTitle() { - if (pageTitle != null) { - form.setText(pageTitle); - } else { - Object titleProvider = null; - if (input instanceof ResourceSet) { - titleProvider = ((ResourceSet)input).getResources().get(0); - } else { - titleProvider = input; - } - if (adapterFactory != null) { - form.setText(new AdapterFactoryLabelProvider(adapterFactory).getText(titleProvider)); - } - } - } - - /** - * Refresh the image form - */ - protected void refreshFormImage() { - if (pageImage != null) { - form.setImage(pageImage); - } else { - Object imageProvider = null; - if (input instanceof ResourceSet) { - imageProvider = ((ResourceSet)input).getResources().get(0); - } else { - imageProvider = input; - } - if (adapterFactory != null) { - form.setImage(new AdapterFactoryLabelProvider(adapterFactory).getImage(imageProvider)); - } - } - } - - /** - * Graphical refresh of the page - */ - protected abstract void refreshFormContents(); - - /** - * Add the given filter to the page viewer - * - * @param filter - * the page viewer filter - */ - public void addFilter(ViewerFilter filter) { - filters.add(filter); - if (getModelViewer() != null) { - getModelViewer().addFilter(filter); - } - } - - /** - * Add the given action to the form page - * - * @param filter - * the action to add - */ - public void addAction(Action action) { - actions.add(action); - if (getManagedForm() != null && getManagedForm().getForm() != null) { - getManagedForm().getForm().getToolBarManager().add(action); - } - } - - /** - * refresh viewer filters. - */ - protected void refreshFilters() { - if (getModelViewer() != null) { - for (ViewerFilter filter : filters) { - getModelViewer().addFilter(filter); - } - } - } - - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/AbstractEEFMDFormPage.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/AbstractEEFMDFormPage.java deleted file mode 100644 index 83db3bcfb..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/AbstractEEFMDFormPage.java +++ /dev/null @@ -1,185 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editors.pages; - -import java.util.List; - -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.ui.dnd.EditingDomainViewerDropAdapter; -import org.eclipse.emf.edit.ui.dnd.LocalTransfer; -import org.eclipse.emf.edit.ui.dnd.ViewerDragAdapter; -import org.eclipse.emf.edit.ui.provider.UnwrappingSelectionProvider; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock; -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.IMenuListener; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.swt.dnd.DND; -import org.eclipse.swt.dnd.Transfer; -import org.eclipse.swt.widgets.Menu; -import org.eclipse.ui.forms.IManagedForm; -import org.eclipse.ui.forms.editor.FormEditor; - -/** - * @author Goulwen Le Fur - */ -public abstract class AbstractEEFMDFormPage extends AbstractEEFEditorPage { - - /** - * The page ID - */ - public static final String PAGE_ID = "EEF-md-form-page"; //$NON-NLS-1$ - - /** - * The form editor in which this page will be included - */ - private FormEditor editor; - - /** - * The master/details block for model edition - */ - protected AbstractEEFMasterDetailsBlock block; - - /** - * The managed form - */ - private IManagedForm managedForm; - - private EditingDomainViewerDropAdapter dropAdapter; - - /** - * @param editor - * the form editor in which this page will be included - */ - public AbstractEEFMDFormPage(FormEditor editor, String pageTitle) { - super(editor, PAGE_ID, pageTitle); - this.editor = editor; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.forms.editor.FormPage#createFormContent(org.eclipse.ui.forms.IManagedForm) - */ - protected void createFormContent(IManagedForm managedForm) { - super.createFormContent(managedForm); - block = createMasterDetailsBlock(); - block.setEditingDomain(editingDomain); - this.managedForm = managedForm; - form = managedForm.getForm(); - managedForm.getToolkit().decorateFormHeading(form.getForm()); - block.createContent(managedForm); - block.getMasterPart().addSelectionChangeListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - getManagedForm().fireSelectionChanged(block.getMasterPart(), event.getSelection()); - } - - }); - createContextMenuFor(block.getMasterPart().getModelViewer()); - refresh(); - } - - /** - * @return the MasterDetailsBlock to use for the page - */ - protected abstract AbstractEEFMasterDetailsBlock createMasterDetailsBlock(); - - /** - * This creates a context menu for the viewer and adds a listener as well registering the menu for - * extension. - */ - protected void createContextMenuFor(StructuredViewer viewer) { - MenuManager contextMenu = new MenuManager("#PopUp"); //$NON-NLS-1$ - contextMenu.add(new Separator("additions")); //$NON-NLS-1$ - contextMenu.setRemoveAllWhenShown(true); - contextMenu.addMenuListener((IMenuListener)editor); - Menu menu = contextMenu.createContextMenu(viewer.getControl()); - viewer.getControl().setMenu(menu); - getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer)); - - if (editingDomain != null) { - initDragnDrop(viewer); - } - } - - private void initDragnDrop(StructuredViewer viewer) { - int dndOperations = DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK; - Transfer[] transfers = new Transfer[] {LocalTransfer.getInstance()}; - viewer.addDragSupport(dndOperations, transfers, new ViewerDragAdapter(viewer)); - dropAdapter = new EditingDomainViewerDropAdapter(editingDomain, viewer); - viewer.addDropSupport(dndOperations, transfers, dropAdapter); - } - - /** - * @return the form - */ - public IManagedForm getManagedForm() { - return managedForm; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.editors.pages.EEFEditorPage#getModelViewer() - */ - public StructuredViewer getModelViewer() { - if (block != null && block.getMasterPart() != null) { - return block.getMasterPart().getModelViewer(); - } else { - return null; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.editors.pages.EEFEditorPage#getPropertiesViewer() - */ - public PropertiesEditionViewer getPropertiesViewer() { - if (block != null) { - if (block.getLastDetailsPage() != null) { - return block.getLastDetailsPage().getViewer(); - } - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.editors.pages.AbstractEEFEditorPage#refreshFormContents() - */ - protected void refreshFormContents() { - block.setAdapterFactory(adapterFactory); - block.setEditingDomain(editingDomain); - block.setInput(input); - } - - public void setEditingDomain(EditingDomain editingDomain) { - super.setEditingDomain(editingDomain); - if (dropAdapter == null && getModelViewer() != null) { - initDragnDrop(getModelViewer()); - } - } - - /** - * @return the list of actions to add to the form toolbar - */ - protected List additionalPageUserActions() { - // nothing to add - return null; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFDetailsPage.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFDetailsPage.java deleted file mode 100755 index 3fd7d7120..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFDetailsPage.java +++ /dev/null @@ -1,166 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editors.pages; - -import org.eclipse.core.runtime.IAdaptable; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.ui.editor.InteractiveEEFEditor; -import org.eclipse.emf.eef.runtime.ui.layout.EEFFormLayoutFactory; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionContentProvider; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionMessageManager; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionViewer; -import org.eclipse.jface.dialogs.IMessageProvider; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.AbstractFormPart; -import org.eclipse.ui.forms.IDetailsPage; -import org.eclipse.ui.forms.IFormPart; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * @author Goulwen Le Fur - */ -public class EEFDetailsPage extends AbstractFormPart implements IDetailsPage, IPropertiesEditionListener { - - private FormToolkit toolkit; - - private EditingDomain editingDomain; - - protected EObject eObject; - - protected IPropertiesEditionComponent propertiesEditionComponent; - - /** - * Manager for error message - */ - private PropertiesEditionMessageManager messageManager; - - protected PropertiesEditionViewer viewer; - - private AdapterFactory adapterFactory; - - public EEFDetailsPage(FormToolkit toolkit, EditingDomain editingDomain, AdapterFactory adapterFactory) { - super(); - this.toolkit = toolkit; - this.editingDomain = editingDomain; - this.adapterFactory = adapterFactory; - } - - public void createContents(Composite parent) { - toolkit = getManagedForm().getToolkit(); - parent.setLayout(EEFFormLayoutFactory.createDetailsGridLayout(false, 1)); - parent.setLayoutData(new GridData(GridData.FILL_BOTH)); - Composite container = toolkit.createComposite(parent, SWT.FLAT); - GridLayout containerLayout = new GridLayout(); - container.setLayout(containerLayout); - container.setLayoutData(new GridData(GridData.FILL_BOTH)); - messageManager = new PropertiesEditionMessageManager() { - - @Override - protected void updateStatus(String message) { - if (message != null && !"".equals(message)) - getManagedForm().getForm().setMessage(message, IMessageProvider.ERROR); - else - getManagedForm().getForm().setMessage(null, IMessageProvider.NONE); - } - }; - this.viewer = new PropertiesEditionViewer(container, null, SWT.NONE, 1); - viewer.setDynamicTabHeader(true); - viewer.setToolkit(getManagedForm().getToolkit()); - viewer.setContentProvider(new PropertiesEditionContentProvider(adapterFactory, - IPropertiesEditionComponent.LIVE_MODE, editingDomain)); - viewer.addPropertiesListener(this); - } - - public void selectionChanged(IFormPart part, ISelection selection) { - if (!(selection instanceof IStructuredSelection)) { - return; - } - EObject newEObject = getEObjectFromSelection(selection); - if (newEObject != null && newEObject != eObject) { - eObject = newEObject; - if (eObject != null) { - if (viewer.getToolkit() == null) - viewer.setToolkit(toolkit); - viewer.setInput(new DomainPropertiesEditionContext(null, null, editingDomain, adapterFactory, - eObject)); - viewer.addPropertiesListener(this); - } - } - } - - private EObject getEObjectFromSelection(ISelection selection) { - if (selection instanceof StructuredSelection - && (((StructuredSelection)selection).getFirstElement() instanceof EObject)) - return (EObject)((StructuredSelection)selection).getFirstElement(); - if (selection instanceof EObject) - return (EObject)selection; - if (selection instanceof IAdaptable && ((IAdaptable)selection).getAdapter(EObject.class) != null) - return (EObject)((IAdaptable)selection).getAdapter(EObject.class); - - return null; - } - - /** - * @return the viewer - */ - public PropertiesEditionViewer getViewer() { - return viewer; - } - - public void firePropertiesChanged(IPropertiesEditionEvent event) { - handleChange(event); - if (event.getState() == PropertiesEditionEvent.FOCUS_CHANGED - && event.getKind() == PropertiesEditionEvent.FOCUS_GAINED) { - // de-activate global actions - if (getEditor() instanceof InteractiveEEFEditor) { - ((InteractiveEEFEditor)getEditor()).deactivateCCPActions(); - } - } else if (event.getState() == PropertiesEditionEvent.FOCUS_CHANGED - && event.getKind() == PropertiesEditionEvent.FOCUS_LOST) { - // re-activate global actions - if (getEditor() instanceof InteractiveEEFEditor) { - ((InteractiveEEFEditor)getEditor()).activateCCPActions(); - } - } - } - - private void handleChange(IPropertiesEditionEvent event) { - // do not handle changes if you are in initialization. - if (viewer.isInitializing()) - return; - messageManager.processMessage(event); - } - - /** - * Retrieve the Editor from the form. - * - * @return The eef editor used to display this page. - */ - private Object getEditor() { - if (getManagedForm().getContainer() instanceof AbstractEEFMDFormPage) - return ((AbstractEEFMDFormPage)getManagedForm().getContainer()).getEditor(); - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFEditorPage.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFEditorPage.java deleted file mode 100644 index df36e90a5..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFEditorPage.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editors.pages; - -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionViewer; -import org.eclipse.jface.action.Action; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.jface.viewers.ViewerFilter; - -/** - * @author Goulwen Le Fur - * - */ -public interface EEFEditorPage { - - /** - * @return the main viewer of the page (where the filters are added). - */ - StructuredViewer getModelViewer(); - - /** - * Defines the page input. - * @param input page input - */ - void setInput(Object input); - - /** - * Add a filter to the most appropriated {@link PropertiesEditionViewer}. - * @param filter the filter to add - */ - void addFilter(ViewerFilter filter); - - /** - * Add an action to the page. - * @param action action to add. - */ - public void addAction(Action action); - - /** - * Defines the page title. - * @param pageTitle page title - */ - void setPageTitle(String pageTitle); - - /** - * @return the {@link PropertiesEditionViewer} dedicated to properties editing. - */ - PropertiesEditionViewer getPropertiesViewer(); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFStandardFormPage.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFStandardFormPage.java deleted file mode 100644 index d96b7ba1a..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/EEFStandardFormPage.java +++ /dev/null @@ -1,136 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editors.pages; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.ui.editor.InteractiveEEFEditor; -import org.eclipse.emf.eef.runtime.ui.layout.EEFFormLayoutFactory; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionContentProvider; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionViewer; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.IManagedForm; -import org.eclipse.ui.forms.editor.FormEditor; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * @author Goulwen Le Fur - */ -public class EEFStandardFormPage extends AbstractEEFEditorPage { - - /** - * The page ID - */ - public static final String PAGE_ID = "EEF-std-form-page"; //$NON-NLS-1$ - - /** - * The form toolkit to use - */ - private FormToolkit toolkit; - - /** - * The folder for the tab - */ - protected PropertiesEditionViewer viewer; - - /** - * @param editor - * editor including this page - * @param name - * page name - */ - public EEFStandardFormPage(FormEditor editor, String name) { - super(editor, PAGE_ID, name); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.forms.editor.FormPage#createFormContent(org.eclipse.ui.forms.IManagedForm) - */ - protected void createFormContent(IManagedForm managedForm) { - super.createFormContent(managedForm); - form = managedForm.getForm(); - toolkit = managedForm.getToolkit(); - toolkit.decorateFormHeading(form.getForm()); - form.getBody().setLayout(EEFFormLayoutFactory.createDetailsGridLayout(false, 1)); - this.viewer = new PropertiesEditionViewer(form.getBody(), null, SWT.NONE, 1); - viewer.getControl().setLayoutData(new GridData(GridData.FILL_BOTH)); - viewer.setDynamicTabHeader(true); - viewer.setToolkit(getManagedForm().getToolkit()); - viewer.setContentProvider(new PropertiesEditionContentProvider(adapterFactory, - IPropertiesEditionComponent.LIVE_MODE, editingDomain)); - refresh(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.editors.pages.AbstractEEFEditorPage#refreshFormContents() - */ - protected void refreshFormContents() { - if (viewer != null && input instanceof EObject) { - viewer.setInput(new DomainPropertiesEditionContext(null, null, editingDomain, adapterFactory, - (EObject)input)); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.editors.pages.EEFEditorPage#getModelViewer() - */ - public StructuredViewer getModelViewer() { - return viewer; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.editors.pages.EEFEditorPage#getPropertiesViewer() - */ - public PropertiesEditionViewer getPropertiesViewer() { - return viewer; - } - - /** - * @see org.eclipse.ui.forms.editor.FormPage#createPartControl(org.eclipse.swt.widgets.Composite) - */ - @Override - public void createPartControl(Composite parent) { - super.createPartControl(parent); - getPropertiesViewer().addPropertiesListener(new IPropertiesEditionListener() { - - public void firePropertiesChanged(IPropertiesEditionEvent event) { - if (event.getState() == PropertiesEditionEvent.FOCUS_CHANGED - && event.getKind() == PropertiesEditionEvent.FOCUS_GAINED) { - // de-activate global actions - if (getEditor() instanceof InteractiveEEFEditor) { - ((InteractiveEEFEditor)getEditor()).deactivateCCPActions(); - } - } else if (event.getState() == PropertiesEditionEvent.FOCUS_CHANGED - && event.getKind() == PropertiesEditionEvent.FOCUS_LOST) { - // re-activate global actions - if (getEditor() instanceof InteractiveEEFEditor) { - ((InteractiveEEFEditor)getEditor()).activateCCPActions(); - } - } - } - }); - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/eefviewer/EEFPropertiesViewerMDFormPage.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/eefviewer/EEFPropertiesViewerMDFormPage.java deleted file mode 100644 index bcdd12bfd..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/eefviewer/EEFPropertiesViewerMDFormPage.java +++ /dev/null @@ -1,102 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editors.pages.eefviewer; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.ui.editors.pages.AbstractEEFMDFormPage; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionContentProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.eefviewer.PropertiesViewerMasterDetailsBlock; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.ui.forms.editor.FormEditor; - -/** - * @author Goulwen Le Fur - * - */ -public class EEFPropertiesViewerMDFormPage extends AbstractEEFMDFormPage { - - /** - * The page ID - */ - public static final String PAGE_ID = "EEF-md-form-page"; //$NON-NLS-1$ - - private boolean orientable = true; - private boolean showValidateAction = true; - private List activatingKeys; - - /** - * @param editor the form editor in which this page will be included - * @param pageTitle the title of the page - */ - public EEFPropertiesViewerMDFormPage(FormEditor editor, String pageTitle) { - super(editor, pageTitle); - activatingKeys = new ArrayList(); - } - - /** - * @param editor the form editor in which this page will be included - * @param pageTitle the title of the page - */ - public EEFPropertiesViewerMDFormPage(FormEditor editor, String pageTitle, boolean isOrientable, boolean showValidatePage) { - this(editor, pageTitle); - this.orientable = isOrientable; - this.showValidateAction = showValidatePage; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.editors.pages.AbstractEEFMDFormPage#createMasterDetailsBlock() - */ - protected AbstractEEFMasterDetailsBlock createMasterDetailsBlock() { - return new PropertiesViewerMasterDetailsBlock(orientable, showValidateAction); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.editors.pages.AbstractEEFMDFormPage#refreshFormContents() - */ - protected void refreshFormContents() { - PropertiesEditionContentProvider contentProvider = new PropertiesEditionContentProvider(getAdapterFactory(), IPropertiesEditionComponent.LIVE_MODE, editingDomain); - getModelViewer().setContentProvider(contentProvider); - contentProvider.addPropertiesListener(new IPropertiesEditionListener() { - - public void firePropertiesChanged(IPropertiesEditionEvent event) { - if (event.getState() == PropertiesEditionEvent.CHANGE && event.getKind() == PropertiesEditionEvent.SELECTION_CHANGED && isAffectingEditor(event)) { - getManagedForm().fireSelectionChanged(block.getMasterPart(), new StructuredSelection(event.getNewValue())); - } - } - }); - super.refreshFormContents(); - } - - /** - * @param activatingKeys the activatingKeys to set - */ - public void setActivatingKeys(List activatingKeys) { - this.activatingKeys = activatingKeys; - } - - /** - * @param event - * @return - */ - protected boolean isAffectingEditor(IPropertiesEditionEvent event) { - return activatingKeys.isEmpty() || activatingKeys.contains(event.getAffectedEditor()); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/tree/EEFTreeMDFormPage.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/tree/EEFTreeMDFormPage.java deleted file mode 100644 index 1fd1fc82e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/editors/pages/tree/EEFTreeMDFormPage.java +++ /dev/null @@ -1,80 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.editors.pages.tree; - -import java.util.List; - -import org.eclipse.emf.eef.runtime.ui.editors.pages.AbstractEEFMDFormPage; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.tree.EEFTreeMasterDetailsBlock; -import org.eclipse.jface.action.Action; -import org.eclipse.ui.forms.editor.FormEditor; - -/** - * @author Goulwen Le Fur - */ -public class EEFTreeMDFormPage extends AbstractEEFMDFormPage { - - /** - * The page ID - */ - public static final String PAGE_ID = "EEF-md-form-page"; //$NON-NLS-1$ - - private boolean initialMasterPartToolBarVisibility = true; - - /** - * @param editor - * the form editor in which this page will be included - */ - public EEFTreeMDFormPage(FormEditor editor, String pageTitle) { - super(editor, pageTitle); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.editors.pages.AbstractEEFMDFormPage#createMasterDetailsBlock() - */ - @Override - protected AbstractEEFMasterDetailsBlock createMasterDetailsBlock() { - EEFTreeMasterDetailsBlock block = new EEFTreeMasterDetailsBlock() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock#additionalPageActions() - */ - protected List additionalPageActions() { - return EEFTreeMDFormPage.this.additionalPageUserActions(); - } - - }; - block.setInitialMasterPartToolBarVisibility(initialMasterPartToolBarVisibility); - return block; - } - - /** - * set the initial master part tool bar visibility - * - * @param value - */ - public void setInitialMasterPartToolBarVisibility(boolean value) { - initialMasterPartToolBarVisibility = value; - } - - /** - * @return value - */ - public boolean isInitialMasterPartToolBarVisibility() { - return initialMasterPartToolBarVisibility; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/layout/EEFFormLayoutFactory.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/layout/EEFFormLayoutFactory.java deleted file mode 100644 index 0d3203ec4..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/layout/EEFFormLayoutFactory.java +++ /dev/null @@ -1,177 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.layout; - -import org.eclipse.swt.layout.GridLayout; - -/** - * @author Goulwen Le Fur - */ -public class EEFFormLayoutFactory { - - // Used in place of 0. If 0 is used, widget borders will appear clipped - // on some platforms (e.g. Windows XP Classic Theme). - // Form tool kit requires parent composites containing the widget to have - // at least 1 pixel border margins in order to paint the flat borders. - // The form toolkit paints flat borders on a given widget when native - // borders are not painted by SWT. See FormToolkit#paintBordersFor() - public static final int DEFAULT_CLEAR_MARGIN = 2; - - // CLEAR - public static final int CLEAR_MARGIN_TOP = DEFAULT_CLEAR_MARGIN; - - public static final int CLEAR_MARGIN_BOTTOM = DEFAULT_CLEAR_MARGIN; - - public static final int CLEAR_MARGIN_LEFT = DEFAULT_CLEAR_MARGIN; - - public static final int CLEAR_MARGIN_RIGHT = DEFAULT_CLEAR_MARGIN; - - public static final int CLEAR_HORIZONTAL_SPACING = 0; - - public static final int CLEAR_VERTICAL_SPACING = 0; - - public static final int CLEAR_MARGIN_HEIGHT = 12; - - public static final int CLEAR_MARGIN_WIDTH = 7; - - public static final int FORM_BODY_HORIZONTAL_SPACING = 20; - - public static final int FORM_BODY_VERTICAL_SPACING = 17; - - // MASTER DETAILS - public static final int MASTER_DETAILS_MARGIN_RIGHT = 1; - - public static final int MASTER_DETAILS_MARGIN_TOP = 0; - - public static final int MASTER_DETAILS_MARGIN_BOTTOM = 0; - - // Used only by masters part. Details part margin dynamically calculated - public static final int MASTER_DETAILS_MARGIN_LEFT = 0; - - // Used only by details part. Masters part margin dynamically calculated - public static final int MASTER_DETAILS_HORIZONTAL_SPACING = FORM_BODY_HORIZONTAL_SPACING; - - public static final int MASTER_DETAILS_VERTICAL_SPACING = FORM_BODY_VERTICAL_SPACING; - - public static final int MASTER_DETAILS_MARGIN_HEIGHT = 12; - - public static final int MASTER_DETAILS_MARGIN_WIDTH = 7; - - /** - * For master sections belonging to a master details block. - * - * @param makeColumnsEqualWidth - * @param numColumns - * @return - */ - public static GridLayout createMasterGridLayout(boolean makeColumnsEqualWidth, int numColumns) { - GridLayout layout = new GridLayout(); - - layout.marginHeight = MASTER_DETAILS_MARGIN_HEIGHT; - layout.marginWidth = MASTER_DETAILS_MARGIN_WIDTH; - - layout.marginTop = MASTER_DETAILS_MARGIN_TOP; - layout.marginBottom = MASTER_DETAILS_MARGIN_BOTTOM; - layout.marginLeft = MASTER_DETAILS_MARGIN_LEFT; - // Cannot set layout on a sash form. - // In order to replicate the horizontal spacing between sections, - // divide the amount by 2 and set the master section right margin to - // half the amount and set the left details section margin to half - // the amount. The default sash width is currently set at 3. - // Minus 1 pixel from each half. Use the 1 left over pixel to separate - // the details section from the vertical scollbar. - int marginRight = MASTER_DETAILS_HORIZONTAL_SPACING; - if (marginRight > 0) { - marginRight = marginRight / 2; - if (marginRight > 0) { - marginRight--; - } - } - layout.marginRight = marginRight; - - layout.horizontalSpacing = MASTER_DETAILS_HORIZONTAL_SPACING; - layout.verticalSpacing = MASTER_DETAILS_VERTICAL_SPACING; - - layout.makeColumnsEqualWidth = makeColumnsEqualWidth; - layout.numColumns = numColumns; - - return layout; - } - - /** - * For miscellaneous grouping composites. For sections (as a whole - header plus client). - * - * @param makeColumnsEqualWidth - * @param numColumns - * @return - */ - public static GridLayout createClearGridLayout(boolean makeColumnsEqualWidth, int numColumns) { - GridLayout layout = new GridLayout(); - - layout.marginHeight = CLEAR_MARGIN_HEIGHT; - layout.marginWidth = CLEAR_MARGIN_WIDTH; - - layout.marginTop = CLEAR_MARGIN_TOP; - layout.marginBottom = CLEAR_MARGIN_BOTTOM; - layout.marginLeft = CLEAR_MARGIN_LEFT; - layout.marginRight = CLEAR_MARGIN_RIGHT; - - layout.horizontalSpacing = CLEAR_HORIZONTAL_SPACING; - layout.verticalSpacing = CLEAR_VERTICAL_SPACING; - - layout.makeColumnsEqualWidth = makeColumnsEqualWidth; - layout.numColumns = numColumns; - - return layout; - } - - /** - * For details sections belonging to a master details block. - * - * @param makeColumnsEqualWidth - * @param numColumns - * @return - */ - public static GridLayout createDetailsGridLayout(boolean makeColumnsEqualWidth, int numColumns) { - GridLayout layout = new GridLayout(); - - layout.marginHeight = MASTER_DETAILS_MARGIN_HEIGHT; - layout.marginWidth = MASTER_DETAILS_MARGIN_WIDTH; - - layout.marginTop = MASTER_DETAILS_MARGIN_TOP; - layout.marginBottom = MASTER_DETAILS_MARGIN_BOTTOM; - // Cannot set layout on a sash form. - // In order to replicate the horizontal spacing between sections, - // divide the amount by 2 and set the master section right margin to - // half the amount and set the left details section margin to half - // the amount. The default sash width is currently set at 3. - // Minus 1 pixel from each half. Use the 1 left over pixel to separate - // the details section from the vertical scollbar. - int marginLeft = MASTER_DETAILS_HORIZONTAL_SPACING; - if (marginLeft > 0) { - marginLeft = marginLeft / 2; - if (marginLeft > 0) { - marginLeft--; - } - } - layout.marginLeft = marginLeft; - layout.marginRight = MASTER_DETAILS_MARGIN_RIGHT; - - layout.horizontalSpacing = MASTER_DETAILS_HORIZONTAL_SPACING; - layout.verticalSpacing = MASTER_DETAILS_VERTICAL_SPACING; - - layout.makeColumnsEqualWidth = makeColumnsEqualWidth; - layout.numColumns = numColumns; - - return layout; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/views/EEFView.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/views/EEFView.java deleted file mode 100644 index 503952661..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/views/EEFView.java +++ /dev/null @@ -1,235 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.views; - -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.ui.provider.UnwrappingSelectionProvider; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.tree.EEFTreeMasterDetailsBlock; -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.MenuManager; -import org.eclipse.jface.action.Separator; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Display; -import org.eclipse.swt.widgets.Menu; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IPartListener2; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.IWorkbenchPartReference; -import org.eclipse.ui.forms.ManagedForm; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.part.ViewPart; - -/** - * @author Goulwen Le Fur - */ -public class EEFView extends ViewPart implements IEditingDomainProvider { - - /** - * The toolkit to use - */ - private FormToolkit toolkit; - - /** - * The view's form - */ - protected ManagedForm form; - - /** - * The master/details block for model edition - */ - protected AbstractEEFMasterDetailsBlock block; - - /** - * The editor/view sychronizer - */ - private IPartListener2 partListener; - - /** - * @return the toolkit - */ - public FormToolkit getToolkit() { - if (toolkit == null) - toolkit = new FormToolkit(Display.getCurrent()); - return toolkit; - } - - /** - * @param toolkit - * the toolkit to set - */ - public void setToolkit(FormToolkit toolkit) { - this.toolkit = toolkit; - } - - /** - * @return the adapterFactory - */ - public AdapterFactory getAdapterFactory() { - return block.getAdapterFactory(); - } - - /** - * @param adapterFactory - * the adapterFactory to set - */ - public void setAdapterFactory(ComposedAdapterFactory adapterFactory) { - block.setAdapterFactory(adapterFactory); - } - - /** - * @return the editingDomain - */ - public EditingDomain getEditingDomain() { - return block.getEditingDomain(); - } - - /** - * @param editingDomain - * the editingDomain to set - */ - public void setEditingDomain(EditingDomain editingDomain) { - block.setEditingDomain(editingDomain); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.part.WorkbenchPart#createPartControl(org.eclipse.swt.widgets.Composite) - */ - @Override - public void createPartControl(Composite parent) { - form = new ManagedForm(parent); - block = new EEFTreeMasterDetailsBlock() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock#additionalPageActions() - */ - protected List additionalPageActions() { - return EEFView.this.additionalPageUserActions(); - } - - }; - - block.createContent(form); - block.getMasterPart().addSelectionChangeListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - form.fireSelectionChanged(block.getMasterPart(), event.getSelection()); - } - - }); - createContextMenuFor(block.getMasterPart().getModelViewer()); - // Initialize the partListener and register it - getSite().getPage().addPartListener(getPartListener()); - } - - /** - * @return - */ - protected IPartListener2 getPartListener() { - partListener = new IPartListener2() { - - public void partVisible(IWorkbenchPartReference partRef) { - } - - public void partOpened(IWorkbenchPartReference partRef) { - } - - public void partInputChanged(IWorkbenchPartReference partRef) { - } - - public void partHidden(IWorkbenchPartReference partRef) { - } - - public void partDeactivated(IWorkbenchPartReference partRef) { - } - - public void partClosed(IWorkbenchPartReference partRef) { - } - - public void partBroughtToTop(IWorkbenchPartReference partRef) { - } - - public void partActivated(IWorkbenchPartReference partRef) { - IWorkbenchPart part = partRef.getPart(false); - if (part instanceof IEditorPart) { - if (part instanceof IEditingDomainProvider) { - IEditingDomainProvider editingDomainProvider = (IEditingDomainProvider)part; - EditingDomain editingDomain = editingDomainProvider.getEditingDomain(); - setEditingDomain(editingDomain); - editingDomainChanged(editingDomain); - } - } - } - }; - return partListener; - } - - /** - * This creates a context menu for the viewer and adds a listener as well registering the menu for - * extension. - */ - protected void createContextMenuFor(StructuredViewer viewer) { - MenuManager contextMenu = new MenuManager("#PopUp"); //$NON-NLS-1$ - contextMenu.add(new Separator("additions")); //$NON-NLS-1$ - contextMenu.setRemoveAllWhenShown(true); - Menu menu = contextMenu.createContextMenu(viewer.getControl()); - viewer.getControl().setMenu(menu); - getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer)); - } - - protected List additionalPageUserActions() { - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.part.WorkbenchPart#setFocus() - */ - @Override - public void setFocus() { - // TODO Auto-generated method stub - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.part.WorkbenchPart#dispose() - */ - @Override - public void dispose() { - if (partListener != null) - getSite().getPage().removePartListener(partListener); - super.dispose(); - } - - /** - * @param editingDomain - * the {@link EditingDomain} of the new selected part - */ - protected void editingDomainChanged(EditingDomain editingDomain) { - block.setInput(editingDomain.getResourceSet()); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/AbstractEEFMasterDetailsBlock.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/AbstractEEFMasterDetailsBlock.java deleted file mode 100644 index 15bd392fd..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/AbstractEEFMasterDetailsBlock.java +++ /dev/null @@ -1,255 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.masterdetails; - -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.ui.action.ValidateAction; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.ui.editors.pages.EEFDetailsPage; -import org.eclipse.emf.eef.runtime.ui.layout.EEFFormLayoutFactory; -import org.eclipse.emf.eef.runtime.ui.notify.OpenWizardOnDoubleClick; -import org.eclipse.emf.eef.runtime.ui.utils.EEFRuntimeUIMessages; -import org.eclipse.jface.action.Action; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.DetailsPart; -import org.eclipse.ui.forms.IDetailsPage; -import org.eclipse.ui.forms.IDetailsPageProvider; -import org.eclipse.ui.forms.IManagedForm; -import org.eclipse.ui.forms.MasterDetailsBlock; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; -import org.eclipse.ui.forms.widgets.Section; - -/** - * @author Goulwen Le Fur - * - */ -public abstract class AbstractEEFMasterDetailsBlock extends MasterDetailsBlock { - - protected FormToolkit toolkit; - protected AbstractEEFMasterPart masterPart; - protected EditingDomain editingDomain; - private AdapterFactory adapterFactory; - protected ValidateAction validateAction; - private EEFDetailsPage lastDetailsPage; - - private boolean orientable = true; - private boolean showValidateAction = true; - - /** - * Default constructor. - * The block is orientable. - */ - public AbstractEEFMasterDetailsBlock() { - super(); - } - - /** - * Constructor defining if the orientation of the block can be changed and if the validate action is visible. - * @param isOrientable the block is orientable or not. - * @param showValidationAction defining the visibility of the action. - */ - public AbstractEEFMasterDetailsBlock(boolean isOrientable, boolean showValidationAction) { - this(); - orientable = isOrientable; - this.showValidateAction = showValidationAction; - } - - /** - * {@inheritDoc} - * @see org.eclipse.ui.forms.MasterDetailsBlock#createMasterPart(org.eclipse.ui.forms.IManagedForm, org.eclipse.swt.widgets.Composite) - */ - protected final void createMasterPart(IManagedForm managedForm, Composite parent) { - this.toolkit = managedForm.getToolkit(); - Composite masterContainer = managedForm.getToolkit().createComposite(parent); - masterContainer.setLayout(EEFFormLayoutFactory.createMasterGridLayout(false, 1)); - masterContainer.setLayoutData(new GridData(GridData.FILL_BOTH)); - masterPart = createEEFMasterPart(masterContainer); - managedForm.addPart(masterPart); - Section section = masterPart.getSection(); - section.setLayout(EEFFormLayoutFactory.createClearGridLayout(false, 1)); - section.setLayoutData(new GridData(GridData.FILL_BOTH)); - masterPart.getModelViewer().addDoubleClickListener((new OpenWizardOnDoubleClick(editingDomain, getAdapterFactory()))); - if (showValidateAction) { - masterPart.addSelectionChangeListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - ISelection selection = event.getSelection(); - if (selection instanceof IStructuredSelection) - validateAction.updateSelection((IStructuredSelection) selection); - } - - }); - } - } - - /** - * Create contents of the Master part - * @param masterContainer the container of this contents - * @return an EEFMasterPart defining the contents of the MasterPart - */ - protected abstract AbstractEEFMasterPart createEEFMasterPart(Composite masterContainer); - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.forms.MasterDetailsBlock#createToolBarActions(org.eclipse.ui.forms.IManagedForm) - */ - protected void createToolBarActions(IManagedForm managedForm) { - final ScrolledForm form = managedForm.getForm(); - if (showValidateAction) { - validateAction = new ValidateAction(); - validateAction.setToolTipText(EEFRuntimeUIMessages.AbstractEEFMasterDetailsBlock_validate_action_tooltip); - validateAction.setImageDescriptor(EEFRuntimePlugin.getImageDescriptor(EEFRuntimePlugin.ICONS_16x16 + "validate.gif")); //$NON-NLS-1$ - form.getToolBarManager().add(validateAction); - } - if (orientable) { - Action haction = new Action("hor", IAction.AS_RADIO_BUTTON) { //$NON-NLS-1$ - public void run() { - sashForm.setOrientation(SWT.HORIZONTAL); - form.reflow(true); - } - }; - haction.setChecked(true); - haction.setToolTipText(EEFRuntimeUIMessages.AbstractEEFMasterDetailsBlock_horizontal_layout); - haction.setImageDescriptor(EEFRuntimePlugin.getImageDescriptor(EEFRuntimePlugin.ICONS_16x16 + "th_horizontal.gif")); //$NON-NLS-1$ - haction.setDisabledImageDescriptor(EEFRuntimePlugin.getImageDescriptor(EEFRuntimePlugin.ICONS_16x16 + "disabled/th_horizontal.gif")); //$NON-NLS-1$ - form.getToolBarManager().add(haction); - - Action vaction = new Action("ver", IAction.AS_RADIO_BUTTON) { //$NON-NLS-1$ - public void run() { - sashForm.setOrientation(SWT.VERTICAL); - form.reflow(true); - } - }; - vaction.setChecked(false); - vaction.setToolTipText(EEFRuntimeUIMessages.AbstractEEFMasterDetailsBlock_vertical_layout); - vaction.setImageDescriptor(EEFRuntimePlugin.getImageDescriptor(EEFRuntimePlugin.ICONS_16x16 + "th_vertical.gif")); //$NON-NLS-1$ - vaction.setDisabledImageDescriptor(EEFRuntimePlugin.getImageDescriptor(EEFRuntimePlugin.ICONS_16x16 + "disabled/th_vertical.gif")); //$NON-NLS-1$ - form.getToolBarManager().add(vaction); - } - if (additionalPageActions() != null) { - for (Action additionalAction : additionalPageActions()) { - form.getToolBarManager().add(additionalAction); - } - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.forms.MasterDetailsBlock#registerPages(org.eclipse.ui.forms.DetailsPart) - */ - protected void registerPages(DetailsPart detailsPart) { - detailsPart.setPageProvider(new IDetailsPageProvider() { - - public Object getPageKey(Object object) { - if (object instanceof EObject) - return EObject.class; - return object.getClass(); - } - - public IDetailsPage getPage(Object key) { - if (key.equals(EObject.class)) { - lastDetailsPage = new EEFDetailsPage(toolkit, editingDomain, adapterFactory); - return lastDetailsPage; - } - return null; - } - }); - } - - /** - * @return the master part of the block - */ - public AbstractEEFMasterPart getMasterPart() { - return masterPart; - } - - /** - * @return the lastDetailsPage - */ - public EEFDetailsPage getLastDetailsPage() { - return lastDetailsPage; - } - - /** - * Defines the orientation of the block. - * @param orientation the orientation to set - */ - public void setOrientation(int orientation) { - sashForm.setOrientation(orientation); - } - - /** - * @return the adapterFactory - */ - public AdapterFactory getAdapterFactory() { - return masterPart.getAdapterFactory(); - } - - /** - * @param adapterFactory the adapterFactory to set - */ - public void setAdapterFactory(AdapterFactory adapterFactory) { - this.adapterFactory = adapterFactory; - masterPart.setAdapterFactory(adapterFactory); - } - - /** - * @return the editingDomain - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * @param editingDomain the editingDomain to set - */ - public void setEditingDomain(EditingDomain editingDomain) { - this.editingDomain = editingDomain; - } - - /** - * @param input the input of the model viewer - */ - public void setInput(Object input) { - masterPart.setInput(input); - } - - /** - * @param filter add a filter to the model viewer - */ - public void addFilter(ViewerFilter filter) { - masterPart.addFilter(filter); - } - - /** - * @return the list of actions to add to the form toolbar - */ - protected List additionalPageActions() { - // nothing to add - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/AbstractEEFMasterPart.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/AbstractEEFMasterPart.java deleted file mode 100644 index 59d98e33c..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/AbstractEEFMasterPart.java +++ /dev/null @@ -1,165 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.masterdetails; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.eef.runtime.ui.utils.EEFRuntimeUIMessages; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.SectionPart; -import org.eclipse.ui.forms.widgets.ExpandableComposite; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * @author Goulwen Le Fur - */ -public abstract class AbstractEEFMasterPart extends SectionPart { - - protected StructuredViewer modelViewer; - - private AdapterFactory adapterFactory; - - private AbstractEEFMasterDetailsBlock block; - - /** - * @param toolkit - * the toolkit to use to create part widgets - * @param container - * the composite where to create the part - * @param block - * the AbstractEEFMasterDetailsBlock - */ - public AbstractEEFMasterPart(FormToolkit toolkit, Composite container, AbstractEEFMasterDetailsBlock block) { - super(container, toolkit, ExpandableComposite.TITLE_BAR); - this.block = block; - Composite sectionContainer = toolkit.createComposite(getSection()); - createSectionClient(sectionContainer, toolkit); - getSection().setText(EEFRuntimeUIMessages.AbstractEEFMasterPart_part_title); - getSection().setClient(sectionContainer); - - } - - /** - * Create the content of the master part - * - * @param sectionContainer - * the parent - * @param toolkit - * the toolkit to use - */ - protected void createSectionClient(Composite sectionContainer, FormToolkit toolkit) { - sectionContainer.setLayout(new GridLayout()); - modelViewer = null; - modelViewer = createSectionClientContents(sectionContainer, toolkit); - assert modelViewer != null : EEFRuntimeUIMessages.AbstractEEFMasterPart_part_cannot_be_null; - } - - /** - * Create the content of the master part - * - * @param sectionContainer - * the parent - * @param toolkit - * the toolkit to use - */ - protected abstract StructuredViewer createSectionClientContents(Composite sectionContainer, - FormToolkit toolkit); - - /** - * @return the adapterFactory - */ - public AdapterFactory getAdapterFactory() { - if (adapterFactory == null) - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - return adapterFactory; - } - - /** - * @param adapterFactory - * the adapterFactory to set - */ - public void setAdapterFactory(AdapterFactory adapterFactory) { - this.adapterFactory = adapterFactory; - } - - /** - * @param title - * the title to set - */ - public void setTitle(String title) { - getSection().setText(title); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.IEEFMasterPart#getModelViewer() - */ - public StructuredViewer getModelViewer() { - return modelViewer; - } - - /** - * @param input - * the input of the model viewer - */ - public void setInput(Object input) { - assert modelViewer != null : EEFRuntimeUIMessages.AbstractEEFMasterPart_viewer_not_defined_on_input_model_definition; - modelViewer.setInput(input); - } - - /** - * @param listener - * add a listener to the mode viewer - */ - public void addSelectionChangeListener(ISelectionChangedListener listener) { - assert modelViewer != null : EEFRuntimeUIMessages.AbstractEEFMasterPart_viewer_not_defined_on_selection_listener_adding; - modelViewer.addSelectionChangedListener(listener); - } - - /** - * @param listener - * remove a listener to the mode viewer - */ - public void removeSelectionChangeListener(ISelectionChangedListener listener) { - assert modelViewer != null : EEFRuntimeUIMessages.AbstractEEFMasterPart_viewer_not_defined_on_selection_listener_adding; - modelViewer.removeSelectionChangedListener(listener); - } - - /** - * @param filter - * add a filter to the model viewer - */ - public void addFilter(ViewerFilter filter) { - assert modelViewer != null : EEFRuntimeUIMessages.AbstractEEFMasterPart_viewer_not_defined_on_filter_adding; - modelViewer.addFilter(filter); - } - - /** - * @return the AbstractEEFMasterDetailsBlock - */ - public AbstractEEFMasterDetailsBlock getBlock() { - return block; - } - - /** - * @param block - * the AbstractEEFMasterDetailsBlock - */ - public void setBlock(AbstractEEFMasterDetailsBlock block) { - this.block = block; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/eefviewer/PropertiesViewerMasterDetailsBlock.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/eefviewer/PropertiesViewerMasterDetailsBlock.java deleted file mode 100644 index 5356696d4..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/eefviewer/PropertiesViewerMasterDetailsBlock.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.eefviewer; - -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterPart; -import org.eclipse.swt.widgets.Composite; - -/** - * @author Goulwen Le Fur - * - */ -public class PropertiesViewerMasterDetailsBlock extends - AbstractEEFMasterDetailsBlock { - - /** - * Default constructor. - * The block is orientable. - */ - public PropertiesViewerMasterDetailsBlock() { - super(); - } - - /** - * Constructor defining if the orientation of the block can be changed. - * @param isOrientable the block is orientable or not. - * @param showValidationAction defining the visibility of the action. - */ - public PropertiesViewerMasterDetailsBlock(boolean isOrientable, boolean showValidationAction) { - super(isOrientable, showValidationAction); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock#createEEFMasterPart(org.eclipse.swt.widgets.Composite) - */ - protected AbstractEEFMasterPart createEEFMasterPart(Composite masterContainer) { - return new PropertiesViewerMasterPart(toolkit, masterContainer, this); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/eefviewer/PropertiesViewerMasterPart.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/eefviewer/PropertiesViewerMasterPart.java deleted file mode 100644 index e9fa486cb..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/eefviewer/PropertiesViewerMasterPart.java +++ /dev/null @@ -1,66 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.eefviewer; - -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionMessageManager; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterPart; -import org.eclipse.jface.dialogs.IMessageProvider; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * @author Goulwen Le Fur - * - */ -public class PropertiesViewerMasterPart extends AbstractEEFMasterPart { - - /** - * @param toolkit the toolkit to use to create part widgets - * @param container the composite where to create the part - * @param block the AbstractEEFMasterDetailsBlock which will contain this part - */ - public PropertiesViewerMasterPart(FormToolkit toolkit, Composite container, AbstractEEFMasterDetailsBlock block) { - super(toolkit, container, block); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterPart#createSectionClientContents(org.eclipse.swt.widgets.Composite, org.eclipse.ui.forms.widgets.FormToolkit) - */ - protected StructuredViewer createSectionClientContents(Composite parent, FormToolkit toolkit) { - GridLayout containerLayout = new GridLayout(); - parent.setLayout(containerLayout); - new PropertiesEditionMessageManager() { - - @Override - protected void updateStatus(String message) { - if (message != null) - getManagedForm().getForm().setMessage(message, IMessageProvider.ERROR); - else - getManagedForm().getForm().setMessage(null, IMessageProvider.NONE); - } - }; - PropertiesEditionViewer viewer = new PropertiesEditionViewer(parent, null, SWT.NONE, 1); - viewer.setDynamicTabHeader(true); - viewer.setToolkit(toolkit); - GridData gridData = new GridData(GridData.FILL_BOTH); - gridData.widthHint = 80; - viewer.getControl().setLayoutData(gridData); - return viewer; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/tree/EEFTreeMasterDetailsBlock.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/tree/EEFTreeMasterDetailsBlock.java deleted file mode 100644 index 2f7de4a23..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/tree/EEFTreeMasterDetailsBlock.java +++ /dev/null @@ -1,69 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.tree; - -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterPart; -import org.eclipse.swt.widgets.Composite; -/** - * @author Goulwen Le Fur - * - */ -public class EEFTreeMasterDetailsBlock extends AbstractEEFMasterDetailsBlock { - - private boolean initialMasterPartToolBarVisibility = true; - - /** - * Default constructor. - * The block is orientable. - */ - public EEFTreeMasterDetailsBlock() { - super(); - } - - /** - * Constructor defining if the orientation of the block can be changed. - * @param isOrientable the block is orientable or not. - * @param showValidationAction defining the visibility of the action. - */ - public EEFTreeMasterDetailsBlock(boolean isOrientable, boolean showValidationAction) { - super(isOrientable, showValidationAction); - } - - - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock#createEEFMasterPart(org.eclipse.swt.widgets.Composite) - */ - protected AbstractEEFMasterPart createEEFMasterPart(Composite masterContainer) { - EEFTreeMasterPart masterPart = new EEFTreeMasterPart(toolkit, masterContainer, this); - masterPart.showToolBar(initialMasterPartToolBarVisibility); - return masterPart; - } - - /** - * set the tool bar visibility - * @param value - */ - public void setInitialMasterPartToolBarVisibility(boolean value) { - initialMasterPartToolBarVisibility = value; - } - - /** - * - * @return - */ - public boolean isInitialMasterPartToolBarVisibility() { - return initialMasterPartToolBarVisibility; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/tree/EEFTreeMasterPart.java b/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/tree/EEFTreeMasterPart.java deleted file mode 100755 index 43f3ae26b..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.extended/src/org/eclipse/emf/eef/runtime/ui/widgets/masterdetails/tree/EEFTreeMasterPart.java +++ /dev/null @@ -1,315 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.tree; - -import java.io.IOException; -import java.net.URL; -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; - -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.command.AddCommand; -import org.eclipse.emf.edit.command.RemoveCommand; -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.impl.utils.EEFCommandParameter; -import org.eclipse.emf.eef.runtime.ui.layout.EEFFormLayoutFactory; -import org.eclipse.emf.eef.runtime.ui.notify.DropDownSelectionListener; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterDetailsBlock; -import org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterPart; -import org.eclipse.jface.resource.ImageDescriptor; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.TreeViewer; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.MenuItem; -import org.eclipse.swt.widgets.Tree; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * @author Goulwen Le Fur - */ -public class EEFTreeMasterPart extends AbstractEEFMasterPart { - - private List commandParameters; - - private EObject modelRoot; - - private EditingDomain editingDomain; - - private Composite modelToolBar; - - private boolean showModelToolBar = true; - - /** - * @param managedForm - * the form where this part will be - * @param container - * the composite where to create the part - * @param block - * the AbstractEEFMasterDetailsBlock which will contain this part - */ - public EEFTreeMasterPart(FormToolkit toolkit, Composite container, AbstractEEFMasterDetailsBlock block) { - super(toolkit, container, block); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.ui.widgets.masterdetails.AbstractEEFMasterPart#createSectionClientContents(org.eclipse.swt.widgets.Composite, - * org.eclipse.ui.forms.widgets.FormToolkit) - */ - protected TreeViewer createSectionClientContents(Composite sectionContainer, FormToolkit toolkit) { - Tree tree = toolkit.createTree(sectionContainer, SWT.MULTI | SWT.BORDER); - TreeViewer result = new TreeViewer(tree); - result.setContentProvider(new AdapterFactoryContentProvider(getAdapterFactory())); - result.setLabelProvider(new AdapterFactoryLabelProvider(getAdapterFactory())); - GridData gd = new GridData(GridData.FILL_BOTH); - gd.widthHint = 80; - tree.setLayoutData(gd); - return result; - } - - /** - * @return the list of command parameters - */ - public List getCommandParameter() { - if (commandParameters == null) { - createCommandParameters(); - } - return commandParameters; - } - - /** - * initialize the command parameters. If this method is called whether command parameters are already - * initialized, old values will be erased - */ - private void createCommandParameters() { - if (modelRoot == null) { - commandParameters = new ArrayList(); - } else { - ViewerFilter[] filters = getModelViewer().getFilters(); - commandParameters = new ArrayList(); - for (EReference reference : modelRoot.eClass().getEAllReferences()) { - if (!reference.isContainment()) { - // Create command parameter for containment references only. - continue; - } else if (filters.length > 0) { - // if filters has been added - for (ViewerFilter filter : filters) { - if (filter.select(modelViewer, modelRoot, - EcoreUtil.create(reference.getEReferenceType()))) { - commandParameters.add(new EEFCommandParameter(reference, reference - .getEReferenceType())); - } - } - } else { - commandParameters.add(new EEFCommandParameter(reference, reference.getEReferenceType())); - } - } - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void createSectionClient(Composite sectionContainer, FormToolkit toolkit) { - sectionContainer.setLayout(new GridLayout()); - createModelRoot(); - if (modelRoot != null) { - createToolBar(sectionContainer, toolkit); - } - createModelViewer(sectionContainer, toolkit); - } - - /** - * initialize model root - */ - private void createModelRoot() { - editingDomain = getBlock().getEditingDomain(); - if (editingDomain instanceof AdapterFactoryEditingDomain) { - AdapterFactoryEditingDomain afed = (AdapterFactoryEditingDomain)editingDomain; - setAdapterFactory(afed.getAdapterFactory()); - EList resources = afed.getResourceSet().getResources(); - if (resources != null && resources.size() != 0) { - // Assuming the main resource is the first resource - Resource resource = resources.get(0); - if (resource.getContents() != null && resource.getContents().size() > 0) { - modelRoot = resource.getContents().get(0); - } - } - } - } - - /** - * create the tool bar (add button and delete button) - * - * @param sectionContainer - * @param toolkit - */ - private void createToolBar(Composite sectionContainer, FormToolkit toolkit) { - if (modelRoot != null) { - modelToolBar = new Composite(sectionContainer, SWT.NONE); - GridLayout layout = new GridLayout(); - layout.numColumns = 2; - layout.makeColumnsEqualWidth = true; - modelToolBar.setLayout(layout); - - // if the root element doesn't has any child, the toolbar (add and delete buttons) is hidden. - if (modelRoot.eClass().getEAllReferences().size() == 0) - modelToolBar.setVisible(false); - - // Add button - createAddButton(toolkit, modelToolBar); - - // delete button - createDeleteButton(toolkit, modelToolBar); - } - } - - /** - * Create the TreeView container - * - * @param sectionContainer - * @param toolkit - */ - private void createModelViewer(Composite sectionContainer, FormToolkit toolkit) { - Composite modelViewerComposite = new Composite(sectionContainer, SWT.NONE); - modelViewerComposite.setLayout(EEFFormLayoutFactory.createMasterGridLayout(false, 1)); - modelViewerComposite.setLayoutData(new GridData(GridData.FILL_BOTH)); - super.createSectionClient(modelViewerComposite, toolkit); - } - - /** - * initialize delete button - * - * @param toolkit - */ - private void createDeleteButton(FormToolkit toolkit, Composite modelToolBar) { - Button delete = toolkit.createButton(modelToolBar, "", SWT.PUSH); - delete.setImage(EEFRuntimePlugin.getImage(EEFRuntimePlugin.ICONS_16x16 + "Delete_16x16.gif")); - delete.addSelectionListener(new SelectionAdapter() { - - public void widgetSelected(SelectionEvent e) { - IStructuredSelection selection = (IStructuredSelection)getModelViewer().getSelection(); - for (Object object : selection.toList()) { - if (editingDomain != null) { - Command command = RemoveCommand.create(editingDomain, object); - editingDomain.getCommandStack().execute(command); - } - } - - } - - }); - } - - /** - * initialize add button - * - * @param toolkit - */ - private void createAddButton(FormToolkit toolkit, Composite modelToolBar) { - Button add = toolkit.createButton(modelToolBar, "", SWT.PUSH); - add.setImage(EEFRuntimePlugin.getImage(EEFRuntimePlugin.ICONS_16x16 + "Add_16x16.gif")); - - DropDownSelectionListener listenerAdd = new DropDownSelectionListener(add) { - boolean init = false; - - @Override - public void widgetSelected(SelectionEvent e) { - if (!init) { - // add every element into menu - for (EEFCommandParameter commandParameter : getCommandParameter()) { - add(commandParameter); - } - if (menu.getItemCount() == 0) { - ((Button)e.getSource()).setEnabled(false); - } - init = true; - } - super.widgetSelected(e); - } - - public void add(final EEFCommandParameter commandParameter) { - IItemLabelProvider adapte = (IItemLabelProvider)getAdapterFactory().adapt( - EcoreUtil.create(commandParameter.geteClass()), IItemLabelProvider.class); - URL image = (URL)adapte.getImage(EcoreUtil.create(commandParameter.geteClass())); - - MenuItem menuItem = new MenuItem(menu, SWT.NONE); - menuItem.setText(adapte.getText(EcoreUtil.create(commandParameter.geteClass()))); - menuItem.setImage(ImageDescriptor.createFromURL(image).createImage(menuItem.getDisplay())); - - menuItem.addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent e) { - - EObject value = EcoreUtil.create(commandParameter.geteClass()); - - if (editingDomain != null) { - Command command = AddCommand.create(editingDomain, modelRoot, null, value); - editingDomain.getCommandStack().execute(command); - } -// try { -// modelRoot.eResource().save(Collections.EMPTY_MAP); -// -// } catch (IOException e1) { -// e1.printStackTrace(); -// } - } - }); - } - }; - - add.addSelectionListener(listenerAdd); - } - - /** - * {@inheritDoc} - */ - @Override - public void addFilter(ViewerFilter filter) { - super.addFilter(filter); - createCommandParameters(); - if (modelToolBar != null) { - if (commandParameters.size() == 0) { - modelToolBar.setVisible(false); - } else if (showModelToolBar != false) { - modelToolBar.setVisible(true); - } - } - } - - public void showToolBar(boolean value) { - if (modelToolBar != null) { - modelToolBar.setVisible(value); - showModelToolBar = value; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/.checkstyle b/plugins/org.eclipse.emf.eef.runtime.tests/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/.classpath b/plugins/org.eclipse.emf.eef.runtime.tests/.classpath deleted file mode 100644 index 64c5e31b7..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/.gitignore b/plugins/org.eclipse.emf.eef.runtime.tests/.gitignore deleted file mode 100644 index d567ba01e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -bin -target diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/.project b/plugins/org.eclipse.emf.eef.runtime.tests/.project deleted file mode 100644 index 3f383c043..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.runtime.tests - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.runtime.tests/META-INF/MANIFEST.MF deleted file mode 100644 index 6d5053732..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/META-INF/MANIFEST.MF +++ /dev/null @@ -1,28 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Runtime dedicated for tests -Bundle-SymbolicName: org.eclipse.emf.eef.runtime.tests;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Vendor: Eclipse Modeling Project -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Eclipse-RegisterBuddy: org.eclipse.swtbot.swt.finder -Require-Bundle: org.eclipse.swtbot.eclipse.finder;visibility:=reexport, - org.eclipse.swtbot.swt.finder;visibility:=reexport, - org.eclipse.ui, - org.eclipse.emf.ecore, - org.eclipse.core.resources;visibility:=reexport, - org.eclipse.core.runtime, - org.eclipse.emf.ecore.xmi, - org.eclipse.emf.eef.runtime, - org.eclipse.emf.compare.match;visibility:=reexport, - org.eclipse.emf.compare.diff, - org.junit4, - org.eclipse.emf.ecore.editor, - org.apache.log4j -Export-Package: org.eclipse.emf.eef.runtime.tests, - org.eclipse.emf.eef.runtime.tests.exceptions, - org.eclipse.emf.eef.runtime.tests.swtbot.finder, - org.eclipse.emf.eef.runtime.tests.swtbot.utils, - org.eclipse.emf.eef.runtime.tests.ui.editors, - org.eclipse.emf.eef.runtime.tests.ui.properties.section, - org.eclipse.emf.eef.runtime.tests.utils diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/about.html b/plugins/org.eclipse.emf.eef.runtime.tests/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/build.properties b/plugins/org.eclipse.emf.eef.runtime.tests/build.properties deleted file mode 100644 index e502868ac..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/build.properties +++ /dev/null @@ -1,17 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ - about.html -src.includes = about.html diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/icons/full/obj16/EEFReflectiveEditor.gif b/plugins/org.eclipse.emf.eef.runtime.tests/icons/full/obj16/EEFReflectiveEditor.gif deleted file mode 100644 index 0b60dcc395e366a529ceabe8f059f7b4378999d0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 364 zcmZ?wbhEHb6krfwxXQp#Y}wl7x}e2rW}W?{2%WSA;oB#9uF5g1o8`NCZqU}nvAdS1 z?A=sx^!S{spT7S7`RmVzFTd}-`0?b;&*$%czWwy;^S9r3o`1jp^2fthKVE(K`Rv`# z4_|+O{qg(z&)>Uut*r4EuoSZ+g-lMnHYi_IS z^d`3r{dQ}59F})GE$VQ7aH4<91luc{GOldOytTLH>ZZ*9|Nk@K0E$0Z7#SGM8FWDM zAU`p%bsm^q;GrXwdP3!r#uVFm0ke8;zKU3HdV5R9BLRy9zcpsXg4~@f3b6${wDpx1 z9ptzmINOHB&BQ>Ay`D{^MMT?~g@KWsosp4&MRJmk3sXrM50lhvVNDn2dd7NYp`}7v xE?msa46C^$Hb|(t%89dx@7O7*=BgyN|G)utR~1Ehg=5F%Rg`_sIXf~~0{}e;no|G( diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/icons/sample.gif b/plugins/org.eclipse.emf.eef.runtime.tests/icons/sample.gif deleted file mode 100644 index 34fb3c9d8cb7d489681b7f7aee4bdcd7eaf53610..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 983 zcmZ?wbhEHb6krfw_|CxKYUg-n!?izO{@9*?jxd%4aX0yzy`dymabz zw#(eg=y~&N&n)dZv2xzduG}5lraiApo3(c4*{Ylg5#|$JO_EEZ<^|a2`Z*=9ns7DV zy=TR&gYw*7f%auV?ip3tvjRPmcdoho{K?x$_vR?C#t5&<;~V}S*>OMCr>h}%%bLZ9 zmo3`hYEwTICo-TTCZwgTsC&VjZRgJ1eE#fBa^%9R zmmfWS@;bnyJ27HWY}kxYzv(Hl>yu;FCPlAEh+34Muq-8Rb6C)<8qA3{r2e5 z`$vyngh#H=FWlqqvnapfc5%(!sQ4v?r7J61-&eJNEN^;KTK}T7{#i-gJh%G*9vcYdwv_*~xdw!Gz4Va?T!sXyyF@8?w<>X`X=#j%uHV4GRvj@+tE@ zQ%F!a)GKcn^~8abN>4la1UNXVL;{ZWi)lEwyeatDu%Lr6;aASiLrXXW zQm# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/pom.xml b/plugins/org.eclipse.emf.eef.runtime.tests/pom.xml deleted file mode 100644 index 2f8a97303..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/pom.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.runtime.tests - eclipse-plugin - - EEF Tests Runtime Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/SWTBotEEFTestCase.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/SWTBotEEFTestCase.java deleted file mode 100644 index 2a5016ebd..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/SWTBotEEFTestCase.java +++ /dev/null @@ -1,244 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.compare.diff.metamodel.DiffGroup; -import org.eclipse.emf.compare.diff.metamodel.DiffModel; -import org.eclipse.emf.compare.diff.service.DiffService; -import org.eclipse.emf.compare.match.metamodel.MatchModel; -import org.eclipse.emf.compare.match.service.MatchService; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.emf.eef.runtime.tests.swtbot.finder.SWTEEFBot; -import org.eclipse.emf.eef.runtime.tests.utils.EEFTestsResourceUtils; -import org.eclipse.swtbot.eclipse.finder.SWTBotEclipseTestCase; -import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotEditor; -import org.junit.Before; - -/** - * @author Nathalie Lepine - */ -public abstract class SWTBotEEFTestCase extends SWTBotEclipseTestCase { - - /** - * An instance of SWTEclipseBot. - * - * @since 1.1 - */ - protected SWTEEFBot bot = new SWTEEFBot(); - - /***************************************************************************** - * * Test members * * - *****************************************************************************/ - - /** - * the model editor - */ - protected SWTBotEditor editor; - - /** - * The ResourceSet where to operate - */ - protected AdapterFactoryEditingDomain editingDomain = new AdapterFactoryEditingDomain(EEFRuntimePlugin.getDefault().getAdapterFactory(), new BasicCommandStack()); - - /** - * The test project - */ - private IProject testProject; - - /** - * The workspace folder containing the input model - */ - private IFolder modelFolder; - - /** - * The expectedModel - */ - protected Resource expectedModel; - - /** - * @return The project that contains models for tests - */ - protected abstract String getTestsProjectName(); - - /** - * @return The folder that contains the input models for tests - */ - protected abstract String getInputModelFolder(); - - /** - * @return The folder that contains the expected models for tests - */ - protected abstract String getExpectedModelFolder(); - - /** - * @return The input model - */ - protected abstract String getInputModelName(); - - /** - * T@return he expected model - */ - protected abstract String getExpectedModelName(); - - /** - * - * @return the import models folder - */ - protected abstract String getImportModelsFolder(); - - /***************************************************************************** - * * Tests specialization * * - *****************************************************************************/ - - /** - * Process to initialize the workspace for the tests - * - * @throws CoreException - * an error occurred during the tests initialization - * @throws IOException - * an error occurred during the tests initialization - */ - protected void initWorkspaceForTests() throws CoreException, IOException { - List names = new ArrayList(); - names.add(getInputModelFolder()); - testProject = EEFTestsResourceUtils.createTestProject(getTestsProjectName(), names); - modelFolder = testProject.getFolder(getInputModelFolder()); - } - - /** - * Import the input model - * @throws CoreException error during model import - * @throws IOException error during model import - */ - protected void initializeInputModel() throws CoreException, IOException { - EEFTestsResourceUtils.importModel(getTestsProjectName(), getImportModelsFolder() + "/" + getInputModelFolder() + "/" + getInputModelName(), modelFolder); - URI fileURI = URI.createPlatformResourceURI(getTestsProjectName() + "/" + getInputModelFolder() + "/" + getInputModelName(), true); - Resource activeResource = editingDomain.getResourceSet().getResource(fileURI, true); - bot.defineActiveModel(activeResource); - } - - /** - * Delete the test models - * @throws CoreException error during model deleting - */ - protected void deleteModels() throws CoreException { - IFile inputFile = EEFTestsResourceUtils.workspaceFile(bot.getActiveResource()); - bot.unloadActiveModel(); - NullProgressMonitor monitor = new NullProgressMonitor(); - inputFile.delete(true, true, monitor); - IFile expectedFile = EEFTestsResourceUtils.workspaceFile(expectedModel); - expectedModel.unload(); - expectedFile.delete(true, true, monitor); - testProject.refreshLocal(IResource.DEPTH_INFINITE, monitor); - } - - protected void createExpectedModel() { - URI fileURI = URI.createPlatformResourceURI(getTestsProjectName() + "/" + getExpectedModelFolder() + "/" + getExpectedModelName(), true); - expectedModel = editingDomain.getResourceSet().createResource(fileURI); - expectedModel.getContents().addAll(EcoreUtil.copyAll(bot.getActiveResource().getContents())); - } - - /***************************************************************************** - * * Test lifecycle * * - *****************************************************************************/ - - /** - * @throws java.lang.Exception - */ - @Before - public void setUp() throws Exception { - super.setUp(); - bot.closeWelcomePage(); - bot.openJavaPerspective(); - bot.openPropertiesView(); - initWorkspaceForTests(); - } - - @Override - protected void tearDown() throws Exception { - bot.closeAllShells(); - super.tearDown(); - } - - /***************************************************************************** - * * Utils methods * * - *****************************************************************************/ - - /** - * @param the - * model to compare to the bot active model - * @return the comparison model - * @throws Exception - * something wrong during comparison - */ - private DiffModel compareToActiveModel(Resource expectedModel) throws Exception { - bot.reloadActiveModel(); - Map options = new HashMap(); - options.put(org.eclipse.emf.compare.match.MatchOptions.OPTION_IGNORE_XMI_ID, Boolean.TRUE); - MatchModel match = MatchService.doResourceMatch(bot.getActiveResource(), expectedModel, options); - DiffModel diff = DiffService.doDiff(match); - return diff; - } - - /** - * Check if the bot's active model is the same that the given model - * - * @param expectedModel - * the model to compare - */ - public void assertExpectedModelReached(Resource expectedModel) { - try { - DiffModel compareToActiveModel = compareToActiveModel(expectedModel); - List diffList = EEFUtils.asEObjectList(compareToActiveModel.eAllContents()); - List result = filterAbnormalDiffElement(diffList); - assertEquals("The active model isn't the same that the expected model", result.size(), 0); - } catch (Exception e) { - // How to do that ??? - assertTrue("Error during model comparison", false); - } - } - - /** - * TODO: check this with the EMF Compare team - * - * @param diffList - * the list to filter - * @return the list of "good" diff - */ - private List filterAbnormalDiffElement(List diffList) { - List result = new ArrayList(); - for (EObject object : diffList) { - if (!(object instanceof DiffGroup) || (((DiffGroup)object).eContents().size() > 0)) - result.add(object); - } - return result; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/exceptions/InputModelInvalidException.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/exceptions/InputModelInvalidException.java deleted file mode 100644 index c36a094a9..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/exceptions/InputModelInvalidException.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests.exceptions; - -/** - * @author Goulwen Le Fur - * - */ -public class InputModelInvalidException extends Exception { - - /** - * Serialization - */ - private static final long serialVersionUID = 5938605662196039272L; - - private String messageInfo; - - /** - * default constructor - */ - public InputModelInvalidException() { - super(); - } - - /** - * constructor with info - * @param info the info - */ - public InputModelInvalidException(String info) { - super(); - this.messageInfo = "The input model doesn't contain enough instance of " + info+ " EClass"; - } - - /** - * {@inheritDoc} - * @see java.lang.Throwable#getMessage() - */ - @Override - public String getMessage() { - String message = "The input model is invalid for test"; - if (messageInfo != null) { - StringBuilder builder = new StringBuilder(message); - builder.append(" : "); - builder.append(messageInfo); - return builder.toString(); - } - return message; - } - - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/exceptions/WidgetInvalidException.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/exceptions/WidgetInvalidException.java deleted file mode 100644 index 401e3ccc4..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/exceptions/WidgetInvalidException.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests.exceptions; - -/** - * @author Nathalie Lepine - * - */ -public class WidgetInvalidException extends Exception { - - /** - * Serialization - */ - private static final long serialVersionUID = 5938605662196039272L; - - private String messageInfo; - - /** - * default constructor - */ - public WidgetInvalidException() { - super(); - } - - /** - * constructor with info - * @param info the info - */ - public WidgetInvalidException(String info) { - super(); - this.messageInfo = "The widget doesn't contain elements " + info; - } - - /** - * {@inheritDoc} - * @see java.lang.Throwable#getMessage() - */ - @Override - public String getMessage() { - String message = "The widget is invalid for test"; - if (messageInfo != null) { - StringBuilder builder = new StringBuilder(message); - builder.append(" : "); - builder.append(messageInfo); - return builder.toString(); - } - return message; - } - - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/finder/SWTEEFBot.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/finder/SWTEEFBot.java deleted file mode 100644 index 1ba9c5020..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/finder/SWTEEFBot.java +++ /dev/null @@ -1,1233 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests.swtbot.finder; - -import static org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable.syncExec; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collections; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EEnum; -import org.eclipse.emf.ecore.EEnumLiteral; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.ui.EMFEditUIPlugin; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.tests.exceptions.WidgetInvalidException; -import org.eclipse.emf.eef.runtime.tests.swtbot.utils.SWTBotUtils; -import org.eclipse.emf.eef.runtime.tests.utils.EEFTestsResourceUtils; -import org.eclipse.emf.eef.runtime.tests.utils.UIConstants; -import org.eclipse.emf.eef.runtime.ui.utils.EEFRuntimeUIMessages; -import org.eclipse.swtbot.eclipse.finder.SWTWorkbenchBot; -import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotEditor; -import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotView; -import org.eclipse.swtbot.swt.finder.SWTBot; -import org.eclipse.swtbot.swt.finder.exceptions.WidgetNotFoundException; -import org.eclipse.swtbot.swt.finder.results.VoidResult; -import org.eclipse.swtbot.swt.finder.waits.Conditions; -import org.eclipse.swtbot.swt.finder.waits.DefaultCondition; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotButton; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotShell; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotText; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem; -import org.eclipse.ui.PlatformUI; - -/** - * @author Goulwen Le Fur - */ -public class SWTEEFBot extends SWTWorkbenchBot { - - private SWTEEFBotHelper helper; - - /** - * Default constructor - */ - public SWTEEFBot() { - super(); - this.helper = new SWTEEFBotHelper(this); - } - - /***************************************************************************** - * * Bot members * * - *****************************************************************************/ - - private Resource activeResource = null; - - /** - * @return the URI of the input model - */ - public String getInputModelURI() { - if (activeResource != null) - return activeResource.getURI().toString(); - return null; - } - - /** - * @return the active resource - */ - public Resource getActiveResource() { - return activeResource; - } - - /***************************************************************************** - * * Bot settings * * - *****************************************************************************/ - - public void defineActiveModel(Resource resource) { - this.activeResource = resource; - } - - public void unloadActiveModel() { - this.activeResource.unload(); - } - - public void reloadActiveModel() throws IOException { - this.activeResource.unload(); - this.activeResource.load(Collections.EMPTY_MAP); - } - - /***************************************************************************** - * * Bot operation * * - *****************************************************************************/ - - /** - * Get another literal value of the enumeration - */ - public Object changeEnumLiteralValue(EEnum enumeration, String text) { - for (EEnumLiteral eEnumLiteral : enumeration.getELiterals()) { - if (!eEnumLiteral.getLiteral().equals(text.toString())) { - return eEnumLiteral.getLiteral(); - } - } - return text; - } - - /** - * Get another reference value of the references list - */ - public Object changeReferenceValue(List eObjectList, EObject value) { - for (EObject eobj : eObjectList) { - if (!eobj.equals(value)) { - return eobj; - } - } - return value; - } - - /** - * Get another reference value of the references list - */ - public Object changeReferenceValue(List eObjectList, List values) { - for (EObject eobj : eObjectList) { - if (!values.contains(eobj)) { - return eobj; - } - } - if (!values.isEmpty()) { - return values.get(0); - } - return null; - } - - /** - * Must open the file with EEF Reflexive editor -> SWTBot pb with context menu - * @param file - * the file to open - * @return the editor editing the file - */ - public SWTBotEditor openFile(IFile file) { - SWTBotTree wizardTree = viewByTitle(UIConstants.PACKAGE_EXPLORER_VIEW_NAME).bot().tree(); - List expansionPath = getExpansionPath(file); - Iterator iter = expansionPath.iterator(); - if (iter.hasNext()) { - String text = getNodeText(iter.next()); - SWTBotTreeItem treeItem = wizardTree.expandNode(text).expand(); - while (iter.hasNext()) { - text = getNodeText(iter.next()); - treeItem = treeItem.getNode(text); - treeItem.expand(); - } - treeItem.select(); - menu(UIConstants.NAVIGATE_MENU).menu(UIConstants.OPEN_MENU).click(); - SWTBotEditor editor = editorByTitle(activeResource.getURI().lastSegment()); - return editor; - } - return null; - } - - /** - * Open the editor on the input model - * - * @return the associated editor - */ - public SWTBotEditor openActiveModel() { - IFile file = EEFTestsResourceUtils.workspaceFile(activeResource); - return openFile(file); - } - - /** - * Prepare the model editing - * - * @param elementType - * The EClass of the edited element - * @param element - * the element to edit - * @return the shell of the opened wizard - */ - public SWTBotShell prepareBatchEditing(SWTBotEditor editor, EClass elementType, EObject element, String tabName) { - SWTBotTreeItem node2 = selectNode(editor, element); - node2.doubleClick(); - if (tabName != null) { - cTabItem(tabName).activate(); - cTabItem(tabName).setFocus(); - } - return shell(elementType.getName()); - } - - /** - * Prepare the model editing - * - * @param editor - * The EClass of the edited element - * @param element - * the element to edit - * @return the shell of the opened wizard - */ - public SWTBotView prepareLiveEditing(SWTBotEditor editor, EObject element, String tabName) { - SWTBotTreeItem node2 = selectNode(editor, element); - node2.select(); - SWTBotUtils.selectPropertyTabItem(tabName); - return viewByTitle(UIConstants.PROPERTIES_VIEW_NAME); - } - - /** - * Select the given element in the given editor - * - * @param editor - * the editor where the bot must process - * @param element - * the element to select - * @return the selected node - */ - public SWTBotTreeItem selectNode(SWTBotEditor editor, EObject element) { - List expansionPath = getExpansionPath(element); - Iterator iterator = expansionPath.iterator(); - Object next = null; - SWTBotTreeItem node2 = editor.bot().tree().getTreeItem(getInputModelURI()); - while (iterator.hasNext()) { - node2.expand(); - next = iterator.next(); - node2 = selectSubNode(node2, next); - } - return node2; - } - - /** - * Select the given element in the given editor - * - * @param editor - * the editor where the bot must process - * @param element - * the element to select - * @return the selected node - */ - public SWTBotTreeItem selectNode(SWTBotTree tree, EObject element) { - List expansionPath = getExpansionPath(element); - Iterator iterator = expansionPath.iterator(); - Object next = null; - SWTBotTreeItem node2 = tree.getTreeItem(getInputModelURI()); - while (iterator.hasNext()) { - node2.expand(); - next = iterator.next(); - node2 = selectSubNode(node2, next); - } - return node2; - } - - /** - * This method save the model and close the editor - * - * @param editor - * the modelEditor - */ - public void finalizeEdition(final SWTBotEditor editor) { - activateEclipseShell(); - menu(UIConstants.FILE_MENU).menu(UIConstants.SAVE_MENU).click(); - this.waitUntil(new DefaultCondition() { - - public boolean test() throws Exception { - return !editor.isDirty(); - } - - public String getFailureMessage() { - return "the editor does not save in less than one minute"; - } - }, 60000); - editor.close(); - } - - /***************************************************************************** - * * EEF features editing testing * * - *****************************************************************************/ - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param feature - * the feature to edit - * @param newValue - * the new value to set to the feature - */ - public void editTextFeature(SWTBotShell shell, String feature, Object newValue) { - activateShell(shell); - editEEFText(feature, newValue); - closeShellWithFinishButton(shell); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - */ - public void editEMFComboViewerFeature(SWTBotShell shell, String viewID, Object newValue) { - activateShell(shell); - editEMFComboViewer(viewID, newValue); - closeShellWithFinishButton(shell); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - */ - public void editRadioFeature(SWTBotShell shell, String viewID, Object newValue) { - activateShell(shell); - editRadio(viewID, newValue); - closeShellWithFinishButton(shell); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - */ - public void editEMFComboViewer(String viewID, Object newValue) { - comboBoxWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).setSelection(newValue.toString()); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - */ - public void editRadio(String viewID, Object newValue) { - helper.radioWithIdAndMnemonic(viewID, newValue.toString()).click(); - } - - /** - * @param shell - */ - public void activateShell(SWTBotShell shell) { - shell.activate(); - } - - /** - * @param shell - */ - public void closeShellWithFinishButton(SWTBotShell shell) { - button(UIConstants.FINISH_BUTTON).click(); - waitUntil(Conditions.shellCloses(shell)); - } - - /** - * @param viewId the ID of the element editor - * @param newValue the new value to set - */ - public void editEEFText(String viewId, Object newValue) { - if (newValue != null) { - SWTBotText textWithId = textWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewId); - textWithId.setText(newValue.toString()); - /* our listener wait a focus lost to launch the command */ -// button(UIConstants.FINISH_BUTTON).setFocus(); - SWTBotUtils.pressEnterKey(textWithId.widget); - SWTBotUtils.sendFocusLost(textWithId.widget); - syncExec(new VoidResult() { - - public void run() { - synchronizationWithUIThread(); - } - }); - } - } - - /** - * Wait the end of the asynchronous calls waiting in UI thread. - */ - public void synchronizationWithUIThread() { - while (PlatformUI.getWorkbench().getDisplay().readAndDispatch()) { - // Do nothing, just wait - } - } - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param propertyView - * the properties view - * @param viewID - * the ID of the ElementEditor - * @param selectNode - * the SWTBotTreeItem in the treeview model - */ - public void editPropertyEEFText(SWTBotView propertyView, String viewID, Object newValue, SWTBotTreeItem selectNode) { - SWTBot propertyBot = propertyView.bot(); - SWTBotText elementEditor = propertyBot.textWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID); - elementEditor.setFocus(); - elementEditor.setText(newValue.toString()); - SWTBotUtils.pressEnterKey(propertyView.getWidget()); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param viewID - * the ID of the ElementEditor to edit - * @param newValue - * the new value to set to the feature - */ - public void editCheckboxFeature(SWTBotShell shell, String viewID) { - activateShell(shell); - editEEFCheckbox(viewID); - closeShellWithFinishButton(shell); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param tableIndex the new value to set to the feature - * @throws WidgetInvalidException - */ - public void editEObjectFlatComboViewerFeature(SWTBotShell shell, String viewID, int tableIndex) throws WidgetInvalidException { - activateShell(shell); - editEObjectFlatComboViewer(viewID, tableIndex); - closeShellWithFinishButton(shell); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - * @throws WidgetInvalidException - */ - public void editFlatReferencesTableFeature(SWTBotShell shell, String viewID, int newValue) throws WidgetInvalidException { - activateShell(shell); - editFlatReferencesTable(viewID, newValue); - closeShellWithFinishButton(shell); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param tableIndex the new value to set to the feature - * @throws WidgetInvalidException - */ - public void editFlatReferencesTable(String viewID, int tableIndex) throws WidgetInvalidException { - buttonWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).click(); - try { - table().select(tableIndex); - button(EMFEditUIPlugin.INSTANCE.getString("_UI_Add_label")).click(); - } catch (Exception e) { - // empty table - throw new WidgetInvalidException(); - } - button(UIConstants.OK_BUTTON).click(); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param tableIndex the element to select - * @throws WidgetInvalidException error during selection - */ - public void editEObjectFlatComboViewer(String viewID, int tableIndex) throws WidgetInvalidException { - buttonWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).click(); - try { - table().select(tableIndex); - } catch (Exception e) { - // empty table - throw new WidgetInvalidException(); - } - button(UIConstants.OK_BUTTON).click(); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param newValue the element to select - * @throws WidgetInvalidException error during selection - */ - public void editReferencesTableFeature(SWTBotShell shell, String viewID, int newValue) throws WidgetInvalidException { - activateShell(shell); - editReferencesTable(viewID, newValue); - closeShellWithFinishButton(shell); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param newValue the element to select - * @throws WidgetInvalidException error during selection - */ - public void editReferencesTable(String viewID, int newValue) throws WidgetInvalidException { - helper.addButtonReferencesTable(viewID).click(); - try { - table().select(newValue); - } catch (Exception e) { - // empty table - throw new WidgetInvalidException(); - } - button(UIConstants.OK_BUTTON).click(); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param newValue the element to select - * @throws WidgetInvalidException error during selection - */ - public void removeReferencesTableFeature(SWTBotShell shell, String viewID, int newValue) throws WidgetInvalidException { - activateShell(shell); - removeReferencesTable(viewID, newValue); - closeShellWithFinishButton(shell); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param newValue the element to select - * @throws WidgetInvalidException error during selection - */ - public void removeReferencesTable(String viewID, int tableIndex) throws WidgetInvalidException { - try { - tableWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).select(tableIndex); - helper.removeButtonReferencesTable(viewID).click(); - } catch (Exception e) { - // empty table - throw new WidgetInvalidException(); - } - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue - * the new value to set to the feature - */ - public void editAdvancedEObjectFlatComboViewerFeature(SWTBotShell shell, String viewID, Object value) { - activateShell(shell); - editAdvancedEObjectFlatComboViewer(viewID, value); - closeShellWithFinishButton(shell); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - */ - public void removeAdvancedEObjectFlatComboViewerFeature(SWTBotShell shell, String viewID) { - activateShell(shell); - removeAdvancedEObjectFlatComboViewer(viewID); - closeShellWithFinishButton(shell); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param tableIndex the element to select - * @throws WidgetInvalidException error during selection - */ - public void removeFlatReferencesTableFeature(SWTBotShell shell, String viewID) throws WidgetInvalidException { - activateShell(shell); - removeFlatReferencesTable(viewID); - closeShellWithFinishButton(shell); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @throws WidgetInvalidException error during selection - */ - public void removeFlatReferencesTable(String viewID) throws WidgetInvalidException { - buttonWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).click(); - try { - table(1).select(0); - button(EMFEditUIPlugin.INSTANCE.getString("_UI_Remove_label")).click(); - } catch (Exception e) { - // empty table - throw new WidgetInvalidException(); - } - button(UIConstants.OK_BUTTON).click(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @throws WidgetInvalidException - */ - public void removeEObjectFlatComboViewerFeature(SWTBotShell shell, String viewID) throws WidgetInvalidException { - activateShell(shell); - removeEObjectFlatComboViewer(viewID); - closeShellWithFinishButton(shell); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @throws WidgetInvalidException - */ - public void removeEObjectFlatComboViewer(String viewID) throws WidgetInvalidException { - buttonWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).click(); - try { - table().select(0); - } catch (Exception e) { - // empty table - throw new WidgetInvalidException(); - } - button(UIConstants.OK_BUTTON).click(); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param tableIndex the element to select - * @throws WidgetInvalidException error during selection - */ - public void removePropertyFlatReferencesTableFeature(SWTBotView propertyView, String viewID, SWTBotTreeItem selectNode) throws WidgetInvalidException { - removeFlatReferencesTable(viewID); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @throws WidgetInvalidException - */ - public void removePropertyEObjectFlatComboViewerFeature(SWTBotView propertyView, String viewID, SWTBotTreeItem selectNode) throws WidgetInvalidException { - removeEObjectFlatComboViewer(viewID); - selectNode.select(); - } - - /** - * @param viewID the edited advEOFCV - * @return the browse button of the given advEOFCV - */ - public SWTBotButton browseButtonAdvancedEObjectFlatComboViewer(String viewID) { - return helper.browseButtonAdvancedEObjectFlatComboViewer(viewID); - } - - /** - * @param viewID the edited advEOFCV - * @return the remove button of the given advEOFCV - */ - public SWTBotButton removeButtonAdvancedEObjectFlatComboViewer(String viewID) { - return helper.removeButtonAdvancedEObjectFlatComboViewer(viewID); - } - - /** - * @param viewID the edited advEOFCV - * @return the remove button of the given advEOFCV - */ - public void removeAdvancedEObjectFlatComboViewer(String viewID) { - removeButtonAdvancedEObjectFlatComboViewer(viewID).click(); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param newValue the newValue to set - */ - public void editAdvancedEObjectFlatComboViewer(String viewID, Object newValue) { - browseButtonAdvancedEObjectFlatComboViewer(viewID).click(); - cTabItem(EEFRuntimeUIMessages.TabElementTreeSelectionDialog_all_resources_tab_title).activate(); - cTabItem(EEFRuntimeUIMessages.TabElementTreeSelectionDialog_all_resources_tab_title).setFocus(); - selectNode(tree(), (EObject)newValue); - button(UIConstants.OK_BUTTON).click(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue the value to add to the feature - */ - public void editAdvancedReferencesTableFeature(SWTBotShell shell, String viewID, Object value) { - activateShell(shell); - editAdvancedReferencesTable(viewID, value); - closeShellWithFinishButton(shell); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue the value to add to the feature - */ - public void editMultiValuedEditorFeature(SWTBotShell shell, String viewID, String newValue) { - activateShell(shell); - editMultiValuedEditor(viewID, newValue); - closeShellWithFinishButton(shell); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue the value to add to the feature - */ - public void editMultiValuedEditor(String viewID, List values) { - buttonWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).click(); - for (String string : values) { - text().setText(string); - button(EMFEditUIPlugin.INSTANCE.getString("_UI_Add_label")).click(); - } - button(UIConstants.OK_BUTTON).click(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param viewID the ID of the ElementEditor to edit - * @param newValue the value to add to the feature - */ - public void editMultiValuedEditor(String viewID, String newValue) { - buttonWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).click(); - text().setText(newValue); - button(EMFEditUIPlugin.INSTANCE.getString("_UI_Add_label")).click(); - button(UIConstants.OK_BUTTON).click(); - } - - /** - * @param viewID the edited advEOFCV - * @return the browse button of the given advEOFCV - */ - public SWTBotButton addButtonAdvancedReferencesTable(String viewID) { - return helper.addButtonAdvancedReferencesTable(viewID); - } - - /** - * @param viewID the edited advEOFCV - * @return the remove button of the given advEOFCV - */ - public SWTBotButton removeButtonAdvancedReferencesTable(String viewID) { - return helper.removeButtonAdvancedReferencesTable(viewID); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param value the value to add - */ - public void editAdvancedReferencesTable(String viewID, Object value) { - addButtonAdvancedReferencesTable(viewID).click(); - cTabItem(EEFRuntimeUIMessages.TabElementTreeSelectionDialog_all_resources_tab_title).activate(); - cTabItem(EEFRuntimeUIMessages.TabElementTreeSelectionDialog_all_resources_tab_title).setFocus(); - selectNode(tree(), (EObject)value); - button(UIConstants.OK_BUTTON).click(); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param value the values to add - */ - public void editAdvancedReferencesTableValues(String viewID, List values) { - for (Object value : values) { - editAdvancedReferencesTable(viewID, value); - } - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - * @throws WidgetInvalidException - */ - public void removeAdvancedReferencesTableFeature(SWTBotShell shell, String viewID, Object value) throws WidgetInvalidException { - activateShell(shell); - removeAdvancedReferencesTable(viewID, value); - closeShellWithFinishButton(shell); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue - * the new value to set to the feature - * @throws WidgetInvalidException - */ - public void removeAdvancedTableCompositionFeature(SWTBotShell shell, String viewID) - throws WidgetInvalidException { - activateShell(shell); - removeAdvancedTableComposition(viewID); - closeShellWithFinishButton(shell); - } - - /** - * @param viewID the edited advEOFCV - * @return the browse button of the given advEOFCV - */ - public SWTBotButton addButtonTableComposition(String viewID) { - return helper.addButtonTableComposition(viewID); - } - - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @throws WidgetInvalidException - */ - public void removeTableCompositionFeature(SWTBotShell shell, String viewID) throws WidgetInvalidException { - activateShell(shell); - removeTableComposition(viewID); - closeShellWithFinishButton(shell); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @throws WidgetInvalidException - */ - public void removeTableComposition(String viewID) throws WidgetInvalidException { - try { - tableWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).select(0); - helper.removeButtonTableComposition(viewID).click(); - } catch (Exception e) { - // empty table - throw new WidgetInvalidException(); - } - } - - /** - * @param viewID the edited advEOFCV - * @return the browse button of the given advEOFCV - */ - public SWTBotButton addButtonAdvancedTableComposition(String viewID) { - return helper.addButtonAdvancedTableComposition(viewID); - } - - /** - * @param viewID the edited advEOFCV - * @return the remove button of the given advEOFCV - */ - public SWTBotButton removeButtonAdvancedTableComposition(String viewID) { - return helper.removeButtonAdvancedTableComposition(viewID); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue - * the new value to set to the feature - * @throws WidgetInvalidException - */ - public void removePropertyAdvancedTableCompositionFeature(SWTBotView propertyView, String viewID, - Object value, SWTBotTreeItem selectNode) throws WidgetInvalidException { - removeAdvancedTableComposition(viewID, value); - selectNode.select(); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param value the value to remove - * @throws WidgetInvalidException error during widget search - */ - public void removeAdvancedTableComposition(String viewID, Object value) throws WidgetInvalidException { - try { - tableWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).select(0); - removeButtonAdvancedTableComposition(viewID).click(); - } catch (Exception e) { - // empty table - throw new WidgetInvalidException(); - } - } - - /** - * Remove a value from a TableComposition - * @param viewID the ID of the ElementEditor to edit - * @throws WidgetInvalidException - */ - public void removeAdvancedTableComposition(String viewID) throws WidgetInvalidException { - try { - tableWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).select(0); - removeButtonAdvancedTableComposition(viewID).click(); - } catch (Exception e) { - // empty table - throw new WidgetInvalidException(); - } - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param value the value to remove - * @throws WidgetInvalidException error during widget search - */ - public void removeAdvancedReferencesTable(String viewID, Object value) throws WidgetInvalidException { - try { - tableWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).select(0); - removeButtonAdvancedReferencesTable(viewID).click(); - } catch (Exception e) { - // empty table - throw new WidgetInvalidException(); - } - } - - /** - * @param viewID the ID of the ElementEditor to edit - */ - private void editEEFCheckbox(String viewID) { - checkBoxWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).click(); - } - - /** - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set - */ - public void editCheckBox(String viewID, boolean newValue) { - if (newValue) { - checkBoxWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).select(); - } else { - checkBoxWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).deselect(); - } - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param propertyView the properties view - * @param viewID the ID of the ElementEditor to edit - * @param selectNode the SWTBotTreeItem in the treeview model - */ - public void editPropertyEEFCheckbox(SWTBotView propertyView, String viewID, SWTBotTreeItem selectNode) { - SWTBot propertyBot = propertyView.bot(); - propertyBot.checkBoxWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).click(); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param propertyView the properties view - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - * @param selectNode the SWTBotTreeItem in the treeview model - */ - public void editPropertyEMFComboViewerFeature(SWTBotView propertyView, String viewID, Object newValue, SWTBotTreeItem selectNode) { - SWTBot propertyBot = propertyView.bot(); - propertyBot.comboBoxWithId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID).setSelection(newValue.toString()); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param propertyView the properties view - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - * @param selectNode the SWTBotTreeItem in the treeview model - * @throws WidgetInvalidException - */ - public void editPropertyFlatReferencesTableFeature(SWTBotView propertyView, String viewID, int newValue, SWTBotTreeItem selectNode) throws WidgetInvalidException { - editFlatReferencesTable(viewID, newValue); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param tableIndex the new value to set to the feature - * @throws WidgetInvalidException - */ - public void editPropertyEObjectFlatComboViewerFeature(SWTBotView propertyView, String viewID, int tableIndex, SWTBotTreeItem selectNode) throws WidgetInvalidException { - editEObjectFlatComboViewer(viewID, tableIndex); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - * @throws WidgetInvalidException - */ - public void editPropertyReferencesTableFeature(SWTBotView propertyView, String viewID, int newValue, SWTBotTreeItem selectNode) throws WidgetInvalidException { - editReferencesTable(viewID, newValue); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param view the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - * @throws WidgetInvalidException - */ - public void removePropertyReferencesTableFeature(SWTBotView propertyView, String viewID, int newValue, SWTBotTreeItem selectNode) throws WidgetInvalidException { - removeReferencesTable(viewID, newValue); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @throws WidgetInvalidException - */ - public void removePropertyTableCompositionFeature(SWTBotView propertyView, String viewID, SWTBotTreeItem selectNode) throws WidgetInvalidException { - removeTableComposition(viewID); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - */ - public void editPropertyAdvancedEObjectFlatComboViewerFeature(SWTBotView propertyView, String viewID, Object value, SWTBotTreeItem selectNode) { - editAdvancedEObjectFlatComboViewer(viewID, value); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell - * the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue - * the new value to set to the feature - */ - public void removePropertyAdvancedEObjectFlatComboViewerFeature(SWTBotView propertyView, String viewID, SWTBotTreeItem selectNode) { - removeAdvancedEObjectFlatComboViewer(viewID); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param value the value to add to the feature - */ - public void editPropertyAdvancedReferencesTableFeature(SWTBotView propertyView, String viewID, Object value, SWTBotTreeItem selectNode) { - editAdvancedReferencesTable(viewID, value); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param shell the shell of the edited wizard - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - * @throws WidgetInvalidException - */ - public void removePropertyAdvancedReferencesTableFeature(SWTBotView propertyView, String viewID, Object value, SWTBotTreeItem selectNode) throws WidgetInvalidException { - removeAdvancedReferencesTable(viewID, value); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param propertyView the properties view - * @param viewID the ID of the ElementEditor to edit - * @param newValue the new value to set to the feature - * @param selectNode - * the SWTBotTreeItem in the treeview model - */ - public void editPropertyRadioFeature(SWTBotView propertyView, String viewID, Object newValue, SWTBotTreeItem selectNode) { - SWTEEFBotHelper propertyHelper = new SWTEEFBotHelper(propertyView.bot()); - propertyHelper.radioWithIdAndMnemonic(viewID, newValue.toString()).click(); - selectNode.select(); - } - - /** - * Edit the value of the EEF Wizard to give the feature the value newValue - * - * @param propertyView - * the properties view - * @param feature - * the feature to edit - * @param selectNode - * the SWTBotTreeItem in the treeview model - */ - public void editPropertyMultiValuedEditorFeature(SWTBotView propertyView, String label, String value, - SWTBotTreeItem selectNode) { - // SWTBot propertyBot = propertyView.bot(); - editMultiValuedEditor(label, value); - selectNode.select(); - } - - public void openPropertiesView() { - menu(UIConstants.WINDOW_MENU).menu(UIConstants.SHOW_VIEW_MENU).menu(UIConstants.OTHER_MENU).click(); - - SWTBotShell shell = shell(UIConstants.SHOW_VIEW_MENU); - activateShell(shell); - - SWTBotTree viewSelectionTree = tree(); - viewSelectionTree.expandNode(UIConstants.GENERAL_MENU).select(UIConstants.PROPERTIES_VIEW_NAME); - button(UIConstants.OK_BUTTON).click(); - waitUntil(Conditions.shellCloses(shell)); - } - - public void openJavaPerspective() { - menu(UIConstants.WINDOW_MENU).menu(UIConstants.OPEN_PERSPECTIVE_MENU).menu(UIConstants.OTHER_MENU) - .click(); - SWTBotShell openPerspectiveShell = shell(UIConstants.OPEN_PERSPECTIVE_MENU); - activateShell(openPerspectiveShell); - - try { - table().select(UIConstants.JAVA_LABEL); - } catch (IllegalArgumentException e) { - table().select(UIConstants.JAVA_DEFAULT_LABEL); - } - button(UIConstants.OK_BUTTON).click(); - } - - /** - * This method close the welcome page if we use the workspace of test for the first time - */ - public void closeWelcomePage() { - try { - viewByTitle(UIConstants.WELCOME_LABEL).close(); - } catch (WidgetNotFoundException e) { - // do nothing - } - } - - /***************************************************************************** - * * Bot utils * * - *****************************************************************************/ - - /** - * Active the main shell (Workbench shell) - */ - protected void activateEclipseShell() { - SWTBotShell[] shells = shells(); - if (shells.length > 0) - // Heuristic : the eclipse shell is the first shell - shells[0].activate(); - } - - /** - * @param modelElement - * the element to process - * @return a list containing the element to expand - */ - private List getExpansionPath(EObject modelElement) { - List result = new ArrayList(); - result.add(modelElement); - EObject container = modelElement.eContainer(); - while (container != null) { - result.add(0, container); - container = container.eContainer(); - } - return result; - } - - /** - * @param file - * the file to process - * @return a list containing the element to expand - */ - private List getExpansionPath(IFile file) { - List result = new ArrayList(); - result.add(file); - IContainer container = file.getParent(); - while (container != null && !(container instanceof IProject)) { - result.add(0, container); - container = container.getParent(); - } - if (container instanceof IProject) - result.add(0, container); - return result; - } - - /** - * Return the label of the given IResource - * - * @param resource - * the resource to process - * @return the label of the resource - */ - private String getNodeText(IResource resource) { - return resource.getName(); - } - - /** - * Select the object next as a subnode of the currentNode - * - * @param currentNode - * the currentNode - * @param next - * the subnode to select - * @return the selected node - */ - private SWTBotTreeItem selectSubNode(SWTBotTreeItem currentNode, Object next) { - AdapterFactory adapterFactory = EEFRuntimePlugin.getDefault().getAdapterFactory(); - IItemLabelProvider labelProvider = (IItemLabelProvider)adapterFactory.adapt(next, - IItemLabelProvider.class); - String text = labelProvider.getText(next); - SWTBotTreeItem node2 = currentNode.getNode(text); - node2.select(); - return node2; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/finder/SWTEEFBotHelper.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/finder/SWTEEFBotHelper.java deleted file mode 100644 index 47b19b8d2..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/finder/SWTEEFBotHelper.java +++ /dev/null @@ -1,141 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests.swtbot.finder; - -import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.allOf; -import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.widgetOfType; -import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.withId; -import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.withMnemonic; -import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.withStyle; - -import org.eclipse.emf.eef.runtime.ui.UIConstants; -import org.eclipse.swt.SWT; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Widget; -import org.eclipse.swtbot.swt.finder.SWTBot; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotButton; -import org.eclipse.swtbot.swt.finder.widgets.SWTBotRadio; -import org.hamcrest.Matcher; - -/** - * @author Goulwen Le Fur - */ -public class SWTEEFBotHelper { - - private SWTBot bot; - - /** - * @param bot - */ - public SWTEEFBotHelper(SWTBot bot) { - super(); - this.bot = bot; - } - - - /** - * @param viewID the edited advEOFCV - * @return the browse button of the given advEOFCV - */ - public SWTBotButton browseButtonAdvancedEObjectFlatComboViewer(String viewID) { - return new SWTBotButton((Button)bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedEObjectFlatComboViewer::browsebutton")))); - } - - /** - * @param viewID the edited advEOFCV - * @return the remove button of the given advEOFCV - */ - public SWTBotButton removeButtonAdvancedEObjectFlatComboViewer(String viewID) { - return new SWTBotButton((Button)bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedEObjectFlatComboViewer::removebutton")))); - } - - /** - * @param viewID the edited advReferencesTable - * @return the add button of the given advReferencesTable - */ - public SWTBotButton addButtonAdvancedReferencesTable(String viewID) { - return new SWTBotButton((Button)bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedReferencesTable::addbutton")))); - } - - /** - * @param viewID the edited advReferencesTable - * @return the remove button of the given advReferencesTable - */ - public SWTBotButton removeButtonAdvancedReferencesTable(String viewID) { - return new SWTBotButton((Button)bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedReferencesTable::removebutton")))); - } - - /** - * @param viewID the edited advTableComposition - * @return the add button of the given advTableComposition - */ - public SWTBotButton addButtonAdvancedTableComposition(String viewID) { - Matcher allOf = allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedTableComposition::addbutton")); - return new SWTBotButton((Button)bot.widget(allOf)); - } - - /** - * @param viewID the edited advTableComposition - * @return the remove button of the given advTableComposition - */ - public SWTBotButton removeButtonAdvancedTableComposition(String viewID) { - return new SWTBotButton((Button)bot.widget( - allOf(widgetOfType(Button.class), - withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), - withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::AdvancedTableComposition::removebutton")))); - } - - /** - * @param viewID the edited radio - * @param mnemonicText the mnemonic to select - * @return the radio to select - */ - public SWTBotRadio radioWithIdAndMnemonic(String viewID, String mnemonicText) { - Matcher matcher = allOf(withId(UIConstants.EEF_WIDGET_ID_KEY, viewID), widgetOfType(Button.class), withMnemonic(mnemonicText), withStyle(SWT.RADIO, "SWT.RADIO")); - return new SWTBotRadio((Button) bot.widget(matcher), matcher); - } - - /** - * @param viewID the edited ReferencesTable - * @return the browse button of the given ReferencesTable - */ - public SWTBotButton addButtonReferencesTable(String viewID) { - return new SWTBotButton((Button)bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::ReferencesTable::addbutton")))); - } - - /** - * @param viewID the edited ReferencesTable - * @return the remove button of the given ReferencesTable - */ - public SWTBotButton removeButtonReferencesTable(String viewID) { - return new SWTBotButton((Button)bot.widget(allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::ReferencesTable::removebutton")))); - } - - - /** - * @param viewID the edited ReferencesTable - * @return the add button of the given ReferencesTable - */ - public SWTBotButton addButtonTableComposition(String viewID) { - Matcher allOf = allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::TableComposition::addbutton")); - return new SWTBotButton((Button)bot.widget(allOf)); - } - - /** - * @param viewID the edited ReferencesTable - * @return the remove button of the given ReferencesTable - */ - public SWTBotButton removeButtonTableComposition(String viewID) { - Matcher allOf = allOf(widgetOfType(Button.class), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_ID_KEY, viewID), withId(org.eclipse.emf.eef.runtime.ui.UIConstants.EEF_WIDGET_TYPE_KEY, "eef::TableComposition::removebutton")); - return new SWTBotButton((Button)bot.widget(allOf)); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/utils/ModelHelper.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/utils/ModelHelper.java deleted file mode 100644 index c9a77bc20..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/utils/ModelHelper.java +++ /dev/null @@ -1,71 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests.swtbot.utils; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.EcorePackage; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; - -/** - * @author Goulwen Le Fur - * - */ -public class ModelHelper { - - private AdapterFactory adapterFactory; - - /** - * @param adapterFactory - */ - public ModelHelper(AdapterFactory adapterFactory) { - this.adapterFactory = adapterFactory; - } - - - - /** - * @param eObj - * @param feature - * @return - */ - public Object anotherValue(EObject eObj, EStructuralFeature feature) { - if (feature instanceof EReference) { - Object choiceOfValues = EEFUtils.choiceOfValues(adapterFactory, eObj, feature); - if (choiceOfValues instanceof Collection) { - for (Object next : (Collection)choiceOfValues) { - if (next != eObj.eGet(feature)) - return next; - } - } - return choiceOfValues; - } else if (feature instanceof EAttribute) { - if (feature.getEType().equals(EcorePackage.eINSTANCE.getEString())) { - return "a" + eObj.eGet(feature); - } else if (feature.getEType().equals(EcorePackage.eINSTANCE.getEInt()) || feature.getEType().equals(EcorePackage.eINSTANCE.getEIntegerObject())) { - return 1 + (Integer)eObj.eGet(feature); - } else if (feature.getEType().equals(EcorePackage.eINSTANCE.getEShort()) || feature.getEType().equals(EcorePackage.eINSTANCE.getEShortObject())) { - return 1 + (Short)eObj.eGet(feature); - } else if (feature.getEType().equals(EcorePackage.eINSTANCE.getEDouble()) || feature.getEType().equals(EcorePackage.eINSTANCE.getEDoubleObject())) { - return 1.0d + (Double)eObj.eGet(feature); - } else if (feature.getEType().equals(EcorePackage.eINSTANCE.getEBoolean()) || feature.getEType().equals(EcorePackage.eINSTANCE.getEBooleanObject())) { - return !(Boolean)eObj.eGet(feature); - } - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/utils/SWTBotUtils.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/utils/SWTBotUtils.java deleted file mode 100644 index ce2ae2f96..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/swtbot/utils/SWTBotUtils.java +++ /dev/null @@ -1,212 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.runtime.tests.swtbot.utils; - -import java.util.List; - -import org.eclipse.swt.SWT; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Event; -import org.eclipse.swt.widgets.Text; -import org.eclipse.swt.widgets.Widget; -import org.eclipse.swtbot.eclipse.finder.SWTWorkbenchBot; -import org.eclipse.swtbot.eclipse.finder.matchers.WidgetMatcherFactory; -import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable; -import org.eclipse.swtbot.swt.finder.results.VoidResult; -import org.eclipse.swtbot.swt.finder.utils.SWTUtils; -import org.eclipse.swtbot.swt.finder.waits.Conditions; -import org.eclipse.swtbot.swt.finder.waits.WaitForObjectCondition; -import org.eclipse.ui.internal.views.properties.tabbed.view.TabbedPropertyList; -import org.eclipse.ui.internal.views.properties.tabbed.view.TabbedPropertyList.ListElement; -import org.hamcrest.Matcher; - -/** - * @author Nathalie Lepine - * - */ -public class SWTBotUtils { - /** - * SWTWorkbenchBot - */ - private static SWTWorkbenchBot bot = new SWTWorkbenchBot(); - - - /** - * Press the enter key - * - * @param widget - * @throws Exception - */ - public static void pressEnterKey(final Widget widget) { - UIThreadRunnable.asyncExec(new VoidResult() { - public void run() { - widget.notifyListeners(SWT.KeyDown, keyEvent(SWT.NONE, SWT.CR, - SWT.Selection, widget)); - } - }); - } - - public static void sendFocusLost(final Widget widget) { - UIThreadRunnable.asyncExec(new VoidResult() { - public void run() { - Event event = createEvent(widget); - event.type = SWT.FocusOut; - - widget.notifyListeners(SWT.FocusOut, event); - } - }); - } - - - /** - * Press the enter key - * - * @param widget - * @throws Exception - */ - public static void pressEnterKeyInTabContainer(final Widget widget) { - UIThreadRunnable.asyncExec(new VoidResult() { - public void run() { - searchTabContainer(widget).notifyListeners(SWT.Traverse, keyEvent(SWT.NONE, SWT.CR, - SWT.Selection, widget)); - } - }); - } - - private static Composite searchTabContainer(final Widget wid) { - Composite parent = ((Text)wid).getParent(); - while (parent != null) { - if (parent instanceof Composite) - return parent; - parent = parent.getParent(); - } - return null; - } - - - /** - * @param c - * the character. - * @param modificationKey - * the modification key. - * @param keyCode - * the keycode. - * @return a key event with the specified keys. - * @see Event#keyCode - * @see Event#character - * @see Event#stateMask - * @since 1.2 - */ - private static Event keyEvent(int modificationKey, char c, int keyCode, - Widget widget) { - Event keyEvent = createEvent(widget); - keyEvent.stateMask = modificationKey; - keyEvent.character = c; - keyEvent.keyCode = keyCode; - - return keyEvent; - } - - private static Event createEvent(Widget widget) { - Event event = new Event(); - event.time = (int) System.currentTimeMillis(); - event.widget = widget; - event.display = bot.getDisplay(); - return event; - } - - - /** - * Select the tab with the name label in the property views. - * - * @param label - * Label to find. - */ - // CHECKSTYLE:OFF - @SuppressWarnings( { "restriction", "unchecked" }) - // CHECKSTYLE:ON - public static void selectPropertyTabItem(final String label) { - final Matcher matcher = WidgetMatcherFactory.allOf(WidgetMatcherFactory.widgetOfType(TabbedPropertyList.class)); - final List widgets = widget(matcher); - - UIThreadRunnable.syncExec(SWTUtils.display(), new VoidResult() { - public void run() { - for (final TabbedPropertyList tabbedProperty : widgets) { - final ListElement tabItem = getTabItem(label, tabbedProperty); - if (tabItem != null) { - final Event mouseEvent = createEvent(tabItem, tabItem.getBounds().x, tabItem.getBounds().y, 1, SWT.BUTTON1, 1); - tabItem.notifyListeners(SWT.MouseUp, mouseEvent); - } - } - } - }); - } - - /** - * Find widget. - * - * @param matcher - * the matcher used to match widgets. - * @return all the widgets matching the matcher. - */ - @SuppressWarnings("restriction") - public static List widget(final Matcher matcher) { - final WaitForObjectCondition waitForWidget = Conditions.waitForWidget(matcher); - bot.waitUntilWidgetAppears(waitForWidget); - return waitForWidget.getAllMatches(); - } - - /** - * Create a event
- * - * @param x - * the x coordinate of the mouse event. - * @param y - * the y coordinate of the mouse event. - * @param button - * the mouse button that was clicked. - * @param stateMask - * the state of the keyboard modifier keys. - * @param count - * the number of times the mouse was clicked. - * @return an event that encapsulates {@link #widget} and {@link #display} - */ - private static Event createEvent(final Widget widget, final int x, final int y, final int button, final int stateMask, final int count) { - final Event event = new Event(); - event.time = (int) System.currentTimeMillis(); - event.widget = widget; - event.display = bot.getDisplay(); - event.x = x; - event.y = y; - event.button = button; - event.stateMask = stateMask; - event.count = count; - return event; - } - - /** - * Select the tab with the name label in the property views - * - * @param label - */ - @SuppressWarnings("restriction") - private static ListElement getTabItem(final String label, final TabbedPropertyList tabbedProperty) { - for (final Object listElement : tabbedProperty.getTabList()) { - if (listElement instanceof ListElement && ((ListElement) listElement).getTabItem().getText().equals(label)) { - return (ListElement) listElement; - } - } - return null; - } - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/actions/OpenWithEEFReflectiveEditor.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/actions/OpenWithEEFReflectiveEditor.java deleted file mode 100644 index 63f5fdffa..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/actions/OpenWithEEFReflectiveEditor.java +++ /dev/null @@ -1,92 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests.ui.actions; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.jface.action.IAction; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.ui.IWorkbenchWindow; -import org.eclipse.ui.IWorkbenchWindowActionDelegate; -import org.eclipse.ui.PartInitException; -import org.eclipse.ui.PlatformUI; -import org.eclipse.ui.dialogs.ElementTreeSelectionDialog; -import org.eclipse.ui.model.WorkbenchContentProvider; -import org.eclipse.ui.model.WorkbenchLabelProvider; -import org.eclipse.ui.part.FileEditorInput; - -/** - * Our sample action implements workbench action delegate. The action proxy will be created by the workbench - * and shown in the UI. When the user tries to use the action, this delegate will be created and execution - * will be delegated to it. - * - * @see IWorkbenchWindowActionDelegate - */ -public class OpenWithEEFReflectiveEditor implements IWorkbenchWindowActionDelegate { - private IWorkbenchWindow window; - - /** - * The constructor. - */ - public OpenWithEEFReflectiveEditor() { - } - - /** - * The action has been activated. The argument of the method represents the 'real' action sitting in the - * workbench UI. - * - * @see IWorkbenchWindowActionDelegate#run - */ - public void run(IAction action) { - ElementTreeSelectionDialog workspaceJarSelectionDialog = new ElementTreeSelectionDialog(window - .getShell(), new WorkbenchLabelProvider(), new WorkbenchContentProvider()); - workspaceJarSelectionDialog.setInput(ResourcesPlugin.getWorkspace().getRoot()); - workspaceJarSelectionDialog.setTitle("Select the file to open with the EEF Reflective Editor"); - workspaceJarSelectionDialog.open(); - - Object firstResult = workspaceJarSelectionDialog.getFirstResult(); - - if (firstResult instanceof IFile) - try { - PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().openEditor( - new FileEditorInput((IFile)firstResult), "org.eclipse.emf.eef.reflect.editor"); - } catch (PartInitException e) { - EEFRuntimePlugin.getDefault().logError("Unable to open file with EEF Reflective Editor", e); - } - } - - /** - * Selection in the workbench has been changed. We can change the state of the 'real' action here if we - * want, but this can only happen after the delegate has been created. - * - * @see IWorkbenchWindowActionDelegate#selectionChanged - */ - public void selectionChanged(IAction action, ISelection selection) { - } - - /** - * We can use this method to dispose of any system resources we previously allocated. - * - * @see IWorkbenchWindowActionDelegate#dispose - */ - public void dispose() { - } - - /** - * We will cache window object in order to be able to provide parent shell for the message dialog. - * - * @see IWorkbenchWindowActionDelegate#init - */ - public void init(IWorkbenchWindow window) { - this.window = window; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/editors/EEFReflectiveEditor.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/editors/EEFReflectiveEditor.java deleted file mode 100644 index 704dbdcda..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/editors/EEFReflectiveEditor.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests.ui.editors; - -import org.eclipse.emf.ecore.presentation.EcoreEditor; -import org.eclipse.emf.eef.runtime.ui.notify.OpenWizardOnDoubleClick; -import org.eclipse.ui.views.properties.IPropertySheetPage; -import org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; - -/** - * @author Goulwen Le Fur - */ -public class EEFReflectiveEditor extends EcoreEditor implements ITabbedPropertySheetPageContributor { - - protected TabbedPropertySheetPage propertySheet; - - /* (non-Javadoc) - * @see org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor#getContributorId() - */ - public String getContributorId() { - return "org.eclipse.emf.eef.reflect.editor"; - } - - /* (non-Javadoc) - * @see org.eclipse.emf.ecore.presentation.EcoreEditor#createPages() - */ - @Override - public void createPages() { - super.createPages(); - selectionViewer.addDoubleClickListener(new OpenWizardOnDoubleClick(editingDomain, adapterFactory)); - } - - /* (non-Javadoc) - * @see org.eclipse.emf.ecore.presentation.EcoreEditor#getPropertySheetPage() - */ - @Override - public IPropertySheetPage getPropertySheetPage() { - if (propertySheet == null) - propertySheet = new TabbedPropertySheetPage(this); - return propertySheet; - } - - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/properties/section/EEFReflectiveEditionSection.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/properties/section/EEFReflectiveEditionSection.java deleted file mode 100644 index 948dc38ee..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/ui/properties/section/EEFReflectiveEditionSection.java +++ /dev/null @@ -1,247 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests.ui.properties.section; - -import java.util.List; - -import org.eclipse.core.runtime.IAdaptable; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.eef.runtime.api.adapters.SemanticAdapter; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionContentProvider; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionMessageManager; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionViewer; -import org.eclipse.jface.dialogs.IMessageProvider; -import org.eclipse.jface.viewers.IFilter; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.forms.widgets.Form; -import org.eclipse.ui.views.properties.tabbed.AbstractPropertySection; -import org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; - -/** - * @author Goulwen Le Fur - */ -public class EEFReflectiveEditionSection extends AbstractPropertySection implements IFilter, IPropertiesEditionListener { - - /** - * the property sheet page for this section. - */ -// private TabbedPropertySheetPage propertySheetPage; - - /** - * the section's parent - */ - protected Composite parent; - - /** - * The section's viewer - */ - protected PropertiesEditionViewer viewer; - - /** - * The editingDomain where the viewer must perform editing commands. - */ - private EditingDomain editingDomain; - - /** - * The current selected object or the first object in the selection when multiple objects are selected. - */ - protected EObject eObject; - - /** - * The list of current selected objects. - */ - protected List eObjectList; - - /** - * The form containing the viewer - */ - private Form scrolledForm; - - /** - * Manager for error message - */ - private PropertiesEditionMessageManager messageManager; - - /** - * global register edition provider - */ - private AdapterFactory adapterFactory; - - private IPropertiesEditionComponent propertiesEditionComponent; - - /** - * @return the associated ProviderEditionProvider - */ - public PropertiesEditingProvider getProvider(EObject eObject) { - return (PropertiesEditingProvider) getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); - } - - - /** - * - */ - private AdapterFactory getAdapterFactory() { - if (adapterFactory == null) - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - return adapterFactory; - } - - - /** - * @see org.eclipse.ui.views.properties.tabbed.ISection#createControls(org.eclipse.swt.widgets.Composite, - * org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage) - */ - public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) { - super.createControls(parent, aTabbedPropertySheetPage); -// this.propertySheetPage = aTabbedPropertySheetPage; - this.parent = parent; - scrolledForm = getWidgetFactory().createForm(parent); - scrolledForm.getBody().setLayout(new GridLayout()); - scrolledForm.getBody().setLayoutData(new GridData(GridData.FILL_BOTH)); - Composite container = getWidgetFactory().createComposite(scrolledForm.getBody()); - GridLayout containerLayout = new GridLayout(); - container.setLayout(containerLayout); - container.setLayoutData(new GridData(GridData.FILL_BOTH)); - getWidgetFactory().decorateFormHeading(scrolledForm); - viewer = new PropertiesEditionViewer(container, null, SWT.NONE, 1); - viewer.setToolkit(getWidgetFactory()); - viewer.setDynamicTabHeader(true); - getWidgetFactory().decorateFormHeading(scrolledForm); - messageManager = new PropertiesEditionMessageManager() { - - @Override - protected void updateStatus(String message) { - if (message != null) - scrolledForm.setMessage(message, IMessageProvider.ERROR); - else - scrolledForm.setMessage(""); //$NON-NLS-1$ - } - }; - } - - /** - * @see org.eclipse.ui.views.properties.tabbed.ISection#setInput(org.eclipse.ui.IWorkbenchPart, - * org.eclipse.jface.viewers.ISelection) - */ - public void setInput(IWorkbenchPart part, ISelection selection) { - super.setInput(part, selection); - initializeEditingDomain(part); - PropertiesEditionContentProvider propertiesEditionContentProvider = new PropertiesEditionContentProvider(getAdapterFactory(), IPropertiesEditionComponent.LIVE_MODE, editingDomain); - viewer.setContentProvider(propertiesEditionContentProvider); - if (!(selection instanceof IStructuredSelection)) { - return; - } - if (resolveSemanticObject(((IStructuredSelection)selection).getFirstElement()) != null) { - EObject newEObject = resolveSemanticObject(((IStructuredSelection)selection).getFirstElement()); - if (newEObject != eObject) { - eObject = newEObject; - if (eObject != null) { - disposeComponent(); - viewer.setInput(new DomainPropertiesEditionContext(null, null, editingDomain, adapterFactory, eObject)); - } - } - } - eObjectList = ((IStructuredSelection)selection).toList(); - } - - private void disposeComponent() { - if (propertiesEditionComponent != null) { - propertiesEditionComponent.dispose(); - } - } - - private void initializeEditingDomain(IWorkbenchPart part) { - if (part instanceof ITabbedPropertySheetPageContributor) { - ITabbedPropertySheetPageContributor editor = (ITabbedPropertySheetPageContributor)part; - if (editor instanceof IEditorPart) { - if (editor instanceof IEditingDomainProvider) - editingDomain = ((IEditingDomainProvider)editor).getEditingDomain(); - else if ((((IEditorPart)editor).getAdapter(IEditingDomainProvider.class)) != null) - editingDomain = ((IEditingDomainProvider)((IEditorPart)editor) - .getAdapter(IEditingDomainProvider.class)).getEditingDomain(); - else if ((((IEditorPart)editor).getAdapter(EditingDomain.class)) != null) - editingDomain = (EditingDomain)((IEditorPart)editor).getAdapter(EditingDomain.class); - } - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#dispose() - */ - public void dispose() { - super.dispose(); - disposeComponent(); - } - - /** - * @param object - * @return - */ - private EObject resolveSemanticObject(Object object) { - if (object instanceof EObject) { - return (EObject)object; - } else if (object instanceof IAdaptable) { - IAdaptable adaptable = (IAdaptable)object; - if (adaptable.getAdapter(SemanticAdapter.class) != null) { - SemanticAdapter semanticAdapter = (SemanticAdapter)adaptable - .getAdapter(SemanticAdapter.class); - return semanticAdapter.getEObject(); - } else if (adaptable.getAdapter(EObject.class) != null) { - return (EObject)adaptable.getAdapter(EObject.class); - } - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IFilter#select(java.lang.Object) - */ - public boolean select(Object toTest) { - EObject eObj = resolveSemanticObject(toTest); - if (eObj != null) { - return getProvider(eObj) != null; - } - return false; - } - - public void firePropertiesChanged(IPropertiesEditionEvent event) { - handleChange(event); - } - - private void handleChange(IPropertiesEditionEvent event) { - // do not handle changes if you are in initialization. -// if (viewer.isInitializing()) -// return; - messageManager.processMessage(event); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/EEFTestsModelsUtils.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/EEFTestsModelsUtils.java deleted file mode 100644 index db0c903b9..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/EEFTestsModelsUtils.java +++ /dev/null @@ -1,93 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests.utils; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.EcoreUtil; - -/** - * @author Goulwen Le Fur - * - */ -public class EEFTestsModelsUtils { - - /** - * Return the first EObject of the given type in the resource. - * @param resource the resource to process - * @param eClass the type to search - * @return the first founded EObject null otherwise. - */ - public static EObject getFirstInstanceOf(Resource resource, EClass eClass) { - if (resource != null && eClass != null) { - TreeIterator allContents = EcoreUtil.getAllContents(resource, true); - for (Iterator iterator = allContents; iterator.hasNext();) { - Object object = iterator.next(); - if (object instanceof EObject && eClass.isInstance(object)) - return (EObject) object; - } - } - return null; - } - - /** - * Return the first EObject of the given type in the resource. - * @param resource the resource to process - * @param eClass the type to search - * @return the first founded EObject null otherwise. - */ - public static EObject getFirstInstanceOf(List list, EClass eClass) { - if (list != null && eClass != null) { - if (!list.isEmpty()) { - return (EObject)list.get(0); - } - } - return null; - } - - /** - * Return the first EObject of the given type in the resource. - * @param resource the resource to process - * @param eClass the type to search - * @param index - * @return the first founded EObject null otherwise. - */ - public static EObject getInstanceOf(Resource resource, EClass eClass, int index) { - List allInstancesOf = getAllInstancesOf(resource, eClass); - if (index < allInstancesOf.size()) - return allInstancesOf.get(index); - return null; - } - - /** - * Return all the EObject of the given type in the resource. - * @param resource the resource to process - * @param eClass the type to search - * @return the list of founded EObject null otherwise. - */ - public static List getAllInstancesOf(Resource resource, EClass eClass) { - List list = new ArrayList(); - if (resource != null && eClass != null) { - for (Iterator iterator = EcoreUtil.getAllContents(resource, true); iterator.hasNext();) { - Object object = iterator.next(); - if (object instanceof EObject && eClass.isInstance(object)) - list.add((EObject) object); - } - } - return list; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/EEFTestsResourceUtils.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/EEFTestsResourceUtils.java deleted file mode 100644 index 61fa580e5..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/EEFTestsResourceUtils.java +++ /dev/null @@ -1,97 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.tests.utils; - -import java.io.IOException; -import java.io.InputStream; -import java.net.URL; -import java.util.Collections; -import java.util.List; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.ResourcesPlugin; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.FileLocator; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.resource.Resource; - -/** - * @author Goulwen Le Fur - * - */ -public class EEFTestsResourceUtils { - - /** - * Create the project for the tests - * @param projectName the name of the project - * @param folderNames the list of folder's name to initialize - * @return the created project - * @throws CoreException unable to create the project - */ - public static IProject createTestProject(String projectName, List folderNames) throws CoreException { - IProject testProject = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName); - NullProgressMonitor npm = new NullProgressMonitor(); - if (!testProject.exists()) - testProject.create(npm); - if (!testProject.isAccessible()) { - testProject.open(npm); - if (folderNames != null && folderNames.size() > 0) { - for (String folderName : folderNames) { - IFolder folder = testProject.getFolder(new Path(folderName)); - if (!folder.exists()) - folder.create(true, true, npm); - } - testProject.refreshLocal(IProject.DEPTH_INFINITE, npm); - } - } - return testProject; - } - - /** - * @param bundleID the bundle where to search the model - * @param modelPath the path of the model - * @param target the folder where to copy the model - * @throws IOException unable to create the file - * @throws CoreException unable to create the file - */ - public static void importModel(String bundleID, String modelPath, IFolder target) throws IOException, CoreException { - URL find = FileLocator.find(Platform.getBundle(bundleID), new Path(modelPath), Collections.EMPTY_MAP); - Path inputPath = new Path(modelPath); - Path targetPath = new Path(inputPath.lastSegment()); - IFile file = target.getFile(targetPath); - if (!file.exists()) { - InputStream openStream = find.openStream(); - file.create(openStream, true, new NullProgressMonitor()); - } - } - - /** - * Find the file corresponding to the given Resource in the workspace - * @param resource the resource to search - * @return the model file in the workspace - */ - public static IFile workspaceFile(Resource resource) { - URI uri = resource.getURI(); - if (uri.isPlatformResource()) { - IPath path = new Path(uri.toPlatformString(true)); - IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path); - return file; - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/UIConstants.java b/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/UIConstants.java deleted file mode 100644 index aca9c2933..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.tests/src/org/eclipse/emf/eef/runtime/tests/utils/UIConstants.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.runtime.tests.utils; - - -/** - * Regroups the UI label constants from the Eclipse UI perspective - * The resource perspective is used for all the tests. - * @author Nathalie Lepine - * - */ -public class UIConstants { - - /***************************************************************************** - * * UI Constants * * - *****************************************************************************/ - - /***************************************************************************** - * * UI Menus * * - *****************************************************************************/ - public static final String GENERAL_MENU = "General"; - public static final String OPEN_PERSPECTIVE_MENU = "Open Perspective"; - public static final String OTHER_MENU = "Other..."; - public static final String SHOW_VIEW_MENU = "Show View"; - public static final String WINDOW_MENU = "Window"; - public static final String FILE_MENU = "File"; - public static final String SAVE_MENU = "Save"; - public static final String NAVIGATE_MENU = "Navigate"; - public static final String OPEN_MENU = "Open"; - - /***************************************************************************** - * * UI Views * * - *****************************************************************************/ - public static final String PACKAGE_EXPLORER_VIEW_NAME = "Package Explorer"; - public static final String PROPERTIES_VIEW_NAME = "Properties"; - public static final String JAVA_LABEL = "Java"; - public static final String JAVA_DEFAULT_LABEL = "Java (default)"; - public static final String WELCOME_LABEL = "Welcome"; - - /***************************************************************************** - * * UI Buttons * * - *****************************************************************************/ - public static final String OK_BUTTON = "OK"; - public static final String FINISH_BUTTON = "Finish"; - public static final String ADD_BUTTON = "Add"; - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.classpath b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.classpath deleted file mode 100644 index 1544160dc..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.classpath +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.gitignore b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.gitignore deleted file mode 100644 index ba077a403..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.gitignore +++ /dev/null @@ -1 +0,0 @@ -bin diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.project b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.project deleted file mode 100644 index 6cac4911f..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.runtime.ui.gwt - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index a1be9020a..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,8 +0,0 @@ -#Thu Jun 23 15:47:25 CEST 2011 -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 -org.eclipse.jdt.core.compiler.compliance=1.6 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.6 diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/META-INF/MANIFEST.MF deleted file mode 100644 index 4048767eb..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/META-INF/MANIFEST.MF +++ /dev/null @@ -1,10 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: Gwt Runtime for Extended Editing Framework -Bundle-SymbolicName: org.eclipse.emf.eef.runtime.ui.gwt -Bundle-Version: 1.5.2.qualifier -Bundle-Vendor: Eclipse Modeling Project -Require-Bundle: org.eclipse.emf.gwt.edit;bundle-version="2.7.0";visibility:=reexport -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Bundle-ActivationPolicy: lazy -Export-Package: org.eclipse.emf.eef.runtime.ui.gwt diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/build.properties b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/build.properties deleted file mode 100644 index 5d6423210..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/build.properties +++ /dev/null @@ -1,15 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - icons/ diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/icons/full/dlcl16/LocateValue.gif b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/icons/full/dlcl16/LocateValue.gif deleted file mode 100644 index 4dfefdab49baec0ef06a3e67f2d87f53104118ec..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 149 zcmZ?wbhEHb6krfw*v!Ci?d+|0uRqLNwDRlMkH3EXc>Ct*>z9w7KDxPn#q2dpXD*vR z<1H|FfuUkGU$MKATt7!=H2{05P~rdp diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/EEFEditor.gwt.xml b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/EEFEditor.gwt.xml deleted file mode 100644 index a18be5eab..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/EEFEditor.gwt.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/EEFEditorEntryPoint.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/EEFEditorEntryPoint.java deleted file mode 100644 index de83b4245..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/EEFEditorEntryPoint.java +++ /dev/null @@ -1,119 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt; - -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.util.Callback; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EAnnotation; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.URIService; -import org.eclipse.emf.ecore.resource.URIServiceAsync; -import org.eclipse.emf.ecore.resource.URIServiceCallback; -import org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl; -import org.eclipse.emf.ecore.resource.impl.ResourceFactoryImpl; -import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory; -import org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.EEFEditor; - -import com.google.gwt.core.client.EntryPoint; -import com.google.gwt.core.client.GWT; -import com.google.gwt.dom.client.Style.Unit; -import com.google.gwt.user.client.ui.RootPanel; - -/** - * @author glefur - * - */ -public abstract class EEFEditorEntryPoint implements EntryPoint { - - private AdapterFactoryEditingDomain editingDomain; - private List originalResources; - - public AdapterFactoryEditingDomain initializeEditingDomain() { - ComposedAdapterFactory composedAdapterFactory = new ComposedAdapterFactory(); - composedAdapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory()); - configureItemProviderAdapterFactories(composedAdapterFactory); - composedAdapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory()); - - final BasicCommandStack commandStack = new BasicCommandStack(); - return new AdapterFactoryEditingDomain(composedAdapterFactory, commandStack); - } - - public void configureResourceSet(final ResourceSet resourceSet) { - resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(Resource.Factory.Registry.DEFAULT_EXTENSION, new ResourceFactoryImpl() { - @Override - public Resource createResource(URI uri) { - return new BinaryResourceImpl(uri); - } - }); - - final URIServiceAsync uriService = GWT.create(URIService.class); - URIServiceCallback uriServiceCallback = new URIServiceCallback(uriService); - resourceSet.getURIConverter().getURIHandlers().add(uriServiceCallback); - - originalResources = new ArrayList(); - - Resource listingResource = resourceSet.getResource(URI.createURI("datastore:/"), new Callback() { - public void onFailure(Throwable caught) { - System.err.println("Failed"); - caught.printStackTrace(); - } - - public void onSuccess(Resource result) { - EAnnotation eAnnotation = (EAnnotation) result.getContents().get(0); - for (Map.Entry entry : eAnnotation.getDetails()) { - resourceSet.createResource(URI.createURI(entry.getKey())); - } - originalResources.clear(); - originalResources.addAll(resourceSet.getResources()); - } - }); - resourceSet.getResources().remove(listingResource); - - registerPackages(resourceSet.getPackageRegistry()); - } - - public void onModuleLoad() { - editingDomain = initializeEditingDomain(); - configureResourceSet(editingDomain.getResourceSet()); - - EEFEditor mainPanel = new EEFEditor(editingDomain, editingDomain.getAdapterFactory(), getApplicationTitle(), Unit.PX); - mainPanel.setOriginalResources(originalResources); - - RootPanel.get("main").add(mainPanel); - - - - - } - - protected abstract void registerPackages(EPackage.Registry ePackageRegistry); - - protected void configureItemProviderAdapterFactories(ComposedAdapterFactory adapterFactory) { - // Do nothing. - } - - protected abstract String getApplicationTitle(); - - - - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/CreateObjectCommand.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/CreateObjectCommand.java deleted file mode 100644 index 126bbd32b..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/CreateObjectCommand.java +++ /dev/null @@ -1,74 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.command; - -import java.util.Collection; -import java.util.Collections; - -import org.eclipse.emf.common.command.AbstractCommand; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.domain.EditingDomain; - -/** - * @author glefur - * - */ -public class CreateObjectCommand extends AbstractCommand { - - EObject eObject; - Collection affectedObjects; - private EditingDomain editingDomain; - private Resource resource; - private String selection; - - /** - * @param editingDomain - * @param resource - * @param selection - */ - public CreateObjectCommand( EditingDomain editingDomain, Resource resource, String selection) { - super("Create Object"); - this.editingDomain = editingDomain; - this.resource = resource; - this.selection = selection; - } - - @Override - protected boolean prepare() { - return true; - } - - public void redo() { - resource.getContents().add(eObject); - affectedObjects = Collections.singleton(eObject); - } - - @Override - public void undo() { - resource.getContents().remove(eObject); - affectedObjects = Collections.singleton(resource); - } - - public void execute() { - eObject = EcoreUtil.create((EClass) editingDomain.getResourceSet().getEObject(URI.createURI(selection), false)); - resource.getContents().add(eObject); - affectedObjects = Collections.singleton(eObject); - } - - @Override - public Collection getAffectedObjects() { - return affectedObjects; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/CreateResourceCommand.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/CreateResourceCommand.java deleted file mode 100644 index 34fd87cfd..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/CreateResourceCommand.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.command; - -import java.util.Collection; -import java.util.Collections; - -import org.eclipse.emf.common.command.AbstractCommand; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.edit.domain.EditingDomain; - -/** - * @author glefur - * - */ -public class CreateResourceCommand extends AbstractCommand{ - - private Collection affectedObjects; - private Resource resource; - private EditingDomain editingDomain; - private String value; - - /** - * @param editingDomain - */ - public CreateResourceCommand(EditingDomain editingDomain, String value) { - super(); - this.editingDomain = editingDomain; - this.value = value; - } - - @Override - protected boolean prepare() { - return true; - } - - public void redo() { - editingDomain.getResourceSet().getResources().add(resource); - affectedObjects = Collections.singleton(resource); - } - - @Override - public void undo() { - editingDomain.getResourceSet().getResources().remove(resource); - affectedObjects = Collections.singleton(editingDomain.getResourceSet()); - } - - public void execute() { - resource = editingDomain.getResourceSet().createResource(URI.createURI(value)); - resource.getContents().clear(); - affectedObjects = Collections.singleton(resource); - } - - @Override - public Collection getAffectedObjects() { - return affectedObjects; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/SaveCommand.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/SaveCommand.java deleted file mode 100644 index 879a9b302..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/SaveCommand.java +++ /dev/null @@ -1,76 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.command; - -import java.io.IOException; -import java.util.Map; - -import org.eclipse.emf.common.command.AbstractCommand; -import org.eclipse.emf.common.util.Callback; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.eef.runtime.ui.gwt.dialog.ErrorDialog; - -/** - * @author glefur - * - */ -public class SaveCommand extends AbstractCommand { - - private Resource resourceToSave; - private Map options; - - /** - * - */ - public SaveCommand(Resource resourceToSave, Map options) { - super("Save Command"); - this.resourceToSave = resourceToSave; - this.options = options; - } - - /* (non-Javadoc) - * @see org.eclipse.emf.common.command.AbstractCommand#prepare() - */ - @Override - protected boolean prepare() { - return true; - } - - /* (non-Javadoc) - * @see org.eclipse.emf.common.command.Command#execute() - */ - @Override - public void execute() { - try { - resourceToSave.save(options, new Callback() { - public void onFailure(Throwable caught) { - final ErrorDialog dialogBox = new ErrorDialog("Save conflict", caught); - dialogBox.open(); - } - - public void onSuccess(Resource result) { - } - }); - } catch (IOException exception) { - System.err.println(exception); - } - } - - /* (non-Javadoc) - * @see org.eclipse.emf.common.command.Command#redo() - */ - @Override - public void redo() { - // TODO Auto-generated method stub - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/UpdateURIConverterCommand.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/UpdateURIConverterCommand.java deleted file mode 100644 index a4648c683..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/command/UpdateURIConverterCommand.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.command; - -import java.util.Map; - -import org.eclipse.emf.common.command.AbstractCommand; -import org.eclipse.emf.common.util.Callback; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.resource.URIConverter; -import org.eclipse.emf.eef.runtime.ui.gwt.dialog.ErrorDialog; - -/** - * @author glefur - * - */ -public class UpdateURIConverterCommand extends AbstractCommand { - - private URIConverter uriConverter; - private URI uri; - private Map options; - - /** - * @param uriConverter - * @param uri - * @param options - */ - public UpdateURIConverterCommand(URIConverter uriConverter, URI uri, Map options) { - super("Update URI Converter"); - this.uriConverter = uriConverter; - this.uri = uri; - this.options = options; - } - - /* (non-Javadoc) - * @see org.eclipse.emf.common.command.AbstractCommand#prepare() - */ - @Override - protected boolean prepare() { - return true; - } - - /* (non-Javadoc) - * @see org.eclipse.emf.common.command.Command#execute() - */ - @Override - public void execute() { - uriConverter.delete(uri, options, new Callback>() { - public void onFailure(Throwable caught) { - final ErrorDialog dialogBox = new ErrorDialog("Delete conflict", caught); - dialogBox.open(); - } - - public void onSuccess(Map result) { - // TODO Auto-generated method stub - } - }); - } - - /* (non-Javadoc) - * @see org.eclipse.emf.common.command.Command#redo() - */ - @Override - public void redo() { - // TODO Auto-generated method stub - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/CreateObjectDialog.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/CreateObjectDialog.java deleted file mode 100644 index c2810851e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/CreateObjectDialog.java +++ /dev/null @@ -1,125 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.dialog; - -import java.util.List; - -import org.eclipse.emf.eef.runtime.ui.gwt.editor.util.EventProcess; - -import com.google.gwt.event.dom.client.ClickEvent; -import com.google.gwt.event.dom.client.ClickHandler; -import com.google.gwt.user.client.ui.Button; -import com.google.gwt.user.client.ui.DialogBox; -import com.google.gwt.user.client.ui.Grid; -import com.google.gwt.user.client.ui.Label; -import com.google.gwt.user.client.ui.ListBox; -import com.google.gwt.user.client.ui.VerticalPanel; - -/** - * @author glefur - * - */ -public class CreateObjectDialog extends DialogBox { - - private List input; - private ListBox listBox; - private Object result; - - /** - * - */ - public CreateObjectDialog() { - super(); - this.setText("Create Object"); - listBox = new ListBox(); - listBox.setVisibleItemCount(1); - final Button okButton = new Button("OK"); - final Button cancelButton = new Button("Cancel"); - VerticalPanel verticalPanel = new VerticalPanel(); - Grid grid = new Grid(); - grid.setWidth("50em"); - grid.resize(2, 2); - grid.getColumnFormatter().setWidth(0, "15%"); - grid.getColumnFormatter().setWidth(1, "85%"); - Label classLabel = new Label(); - classLabel.setText("Class"); - grid.setWidget(0, 0, classLabel); - grid.setWidget(0, 1, listBox); - verticalPanel.add(grid); - // verticalPanel.add(okButton); - grid.setWidget(1, 0, okButton); - grid.setWidget(1, 1, cancelButton); - this.setWidget(verticalPanel); - open(); - okButton.addClickHandler(new ClickHandler() { - - public void onClick(ClickEvent event) { - hide(); - result = processOk(input.get(listBox.getSelectedIndex())); - } - }); - cancelButton.addClickHandler(new ClickHandler() { - public void onClick(ClickEvent event) { - hide(); - processCancel(); - } - }); - } - - /** - * @param input - */ - public void setInput(List input) { - for (Object object : input) { - listBox.addItem(getString(object)); - } - } - - /** - * open the dialog - */ - public void open() { - this.show(); - listBox.setFocus(true); - } - - /** - * @return the result - */ - public Object getResult() { - return result; - } - - /** - * Ok button pressed. - * - * @return - */ - protected Object processOk(Object selection) { - return null; - } - - /** - * Cancel button pressed. - */ - protected void processCancel() { - - } - - /** - * @param object - * @return - */ - public String getString(Object object) { - return object.toString(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/CreateResourceDialog.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/CreateResourceDialog.java deleted file mode 100644 index d8d445991..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/CreateResourceDialog.java +++ /dev/null @@ -1,123 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.dialog; - -import org.eclipse.emf.eef.runtime.ui.gwt.editor.util.EventProcess; - -import com.google.gwt.event.dom.client.ClickEvent; -import com.google.gwt.event.dom.client.ClickHandler; -import com.google.gwt.event.logical.shared.ValueChangeEvent; -import com.google.gwt.event.logical.shared.ValueChangeHandler; -import com.google.gwt.user.client.ui.Button; -import com.google.gwt.user.client.ui.DialogBox; -import com.google.gwt.user.client.ui.Grid; -import com.google.gwt.user.client.ui.Label; -import com.google.gwt.user.client.ui.TextBox; -import com.google.gwt.user.client.ui.VerticalPanel; - -/** - * @author glefur - * - */ -public class CreateResourceDialog extends DialogBox { - - private TextBox uriText; - private EventProcess result; - - /** - * - */ - public CreateResourceDialog() { - super(); - this.setText("Create Resource"); - final Button okButton = new Button("OK"); - final Button cancelButton = new Button("Cancel"); - VerticalPanel verticalPanel = new VerticalPanel(); - Grid grid = new Grid(); - grid.setWidth("50em"); - grid.resize(3, 2); - grid.getColumnFormatter().setWidth(0, "15%"); - grid.getColumnFormatter().setWidth(1, "85%"); - Label uriLabel = new Label(); - uriLabel.setText("URI"); - uriText = new TextBox(); - uriText.setWidth("90%"); - uriText.setValue(defaultValue()); - uriText.selectAll(); - final Label message = new Label(); - uriText.addValueChangeHandler(new ValueChangeHandler() { - public void onValueChange(ValueChangeEvent event) { - String value = event.getValue(); - if (valideValue(value)) { - message.setText(""); - okButton.setEnabled(true); - } else { - message.setText("Invalid value."); - okButton.setEnabled(false); - } - } - }); - grid.setWidget(0, 0, uriLabel); - grid.setWidget(0, 1, uriText); - verticalPanel.add(grid); - grid.setWidget(1, 1, message); - grid.setWidget(2, 0, okButton); - grid.setWidget(2, 1, cancelButton); - this.setWidget(verticalPanel); - okButton.addClickHandler(new ClickHandler() { - - public void onClick(ClickEvent event) { - hide(); - result = processOk(uriText.getValue()); - } - }); - cancelButton.addClickHandler(new ClickHandler() { - public void onClick(ClickEvent event) { - hide(); - processCancel(); - } - }); - open(); - // dialogBox.setWidth("50em"); - } - - /** - * @return the processOk - */ - public EventProcess getResult() { - return result; - } - - - - protected EventProcess processOk(Object value) { - return new EventProcess(null, null); - } - - protected void processCancel() { - - } - - protected String defaultValue() { - return ""; - } - - protected boolean valideValue(Object value) { - return true; - } - - public void open() { - show(); - uriText.setFocus(true); - } - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/ErrorDialog.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/ErrorDialog.java deleted file mode 100644 index 575506097..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/dialog/ErrorDialog.java +++ /dev/null @@ -1,111 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.dialog; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.util.Diagnostic; - -import com.google.gwt.event.dom.client.ClickEvent; -import com.google.gwt.event.dom.client.ClickHandler; -import com.google.gwt.user.client.ui.Button; -import com.google.gwt.user.client.ui.DialogBox; -import com.google.gwt.user.client.ui.Grid; -import com.google.gwt.user.client.ui.Tree; -import com.google.gwt.user.client.ui.TreeItem; - -/** - * @author glefur - * - */ -public class ErrorDialog extends DialogBox { - - private Tree tree; - private Object selection; - - public ErrorDialog(String errorText, Throwable caught) { - super(); - this.setText(errorText); - List throwables = new ArrayList(); - throwables.add(caught); - createDialogControl(); - tree.addItem(createTreeItems(caught)); - } - - public ErrorDialog(String errorText, Diagnostic diagnostic) { - this.setText(errorText); - createDialogControl(); - tree.addItem(createTreeItems(diagnostic)); - } - - public ErrorDialog(String errorText, List children) { - this.setText(errorText); - createDialogControl(); - for (Diagnostic diagnostic : children) { - tree.addItem(createTreeItems(diagnostic)); - } - } - - public void open() { - this.show(); - } - - protected void createDialogControl() { - final Button okButton = new Button("OK"); - tree = new Tree(); - Grid grid = new Grid(); - grid.setWidth("150em"); - grid.resize(2, 1); - grid.setWidget(0, 0, tree); - grid.setWidget(1, 0, okButton); - this.setWidget(grid); - okButton.addClickHandler(new ClickHandler() { - public void onClick(ClickEvent event) { - TreeItem selectedItem = tree.getSelectedItem(); - ErrorDialog.this.hide(); - processError(selectedItem); - } - }); - } - - private TreeItem createTreeItems(Throwable throwable) { - return new TreeItem(throwable.getLocalizedMessage()); - } - - private TreeItem createTreeItems(Diagnostic diagnostic) { - if (diagnostic.getSeverity() == Diagnostic.OK) { - return new TreeItem("No problems detected"); - } else { - TreeItem treeItem = new TreeItem(diagnostic.getMessage()); - List data = diagnostic.getData(); - if (!data.isEmpty()) { - treeItem.setUserObject(data.get(0)); - } - for (Diagnostic child : diagnostic.getChildren()) { - treeItem.addItem(createTreeItems(child)); - } - return treeItem; - } - } - - protected Object processError(TreeItem selection) { - return null; - } - - /** - * @return the selection - */ - public Object getSelection() { - return selection; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/EEFEditor.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/EEFEditor.java deleted file mode 100644 index ffb54ee93..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/EEFEditor.java +++ /dev/null @@ -1,215 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor; - -import java.util.Collection; -import java.util.Collections; -import java.util.EventObject; -import java.util.List; - -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.command.CommandStack; -import org.eclipse.emf.common.command.CommandStackListener; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator; -import org.eclipse.emf.edit.provider.ItemProvider; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.part.EEFEditorToolbar; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.part.EEFPropertiesPanel; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.util.EditorToolbarListener; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.util.NavigationManager; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.widget.EEFTreeViewer; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.widget.EEFTreeViewerContentProvider; - -import com.google.gwt.dom.client.Style.Unit; -import com.google.gwt.user.client.ui.DockLayoutPanel; -import com.google.gwt.user.client.ui.FlowPanel; -import com.google.gwt.user.client.ui.Label; -import com.google.gwt.user.client.ui.ScrollPanel; -import com.google.gwt.user.client.ui.SplitLayoutPanel; -import com.google.gwt.view.client.SelectionChangeEvent; - -/** - * @author glefur - * - */ -public class EEFEditor extends DockLayoutPanel { - - private EditingDomain editingDomain; - private AdapterFactory adapterFactory; - private List originalResources; - private NavigationManager navigationManager; - - private EEFEditorToolbar toolBar; - private EEFTreeViewer treeviewer; - private EEFPropertiesPanel propertiesPanel; - private AdapterFactoryItemDelegator itemDelegator; - - /** - * @param unit - */ - public EEFEditor(EditingDomain editingDomain, AdapterFactory adapterFactory, String applicationTitle, Unit unit) { - super(unit); - this.editingDomain = editingDomain; - this.adapterFactory = adapterFactory; - this.itemDelegator = new AdapterFactoryItemDelegator(adapterFactory); - headerPanel(applicationTitle); - bodyPanel(); - toolBar.setEnabledButton(false, EEFEditorToolbar.SAVE); - toolBar.setEnabledButton(false, EEFEditorToolbar.UNDO); - toolBar.setEnabledButton(false, EEFEditorToolbar.REDO); - final EditorToolbarListener listener = new EditorToolbarListener(this); - toolBar.addListener(listener); - treeviewer.addSelectionChangeHandler(new SelectionChangeEvent.Handler() { - - public void onSelectionChange(SelectionChangeEvent event) { - final Object object = ((EEFTreeViewerContentProvider)treeviewer.getTreeViewModel()).getTreeSelection(); - listener.update(object); - toolBar.setEnabledButton(object instanceof Resource || object instanceof ResourceSet || !EEFEditor.this.editingDomain.getNewChildDescriptors(object, null).isEmpty(), EEFEditorToolbar.CREATE); - propertiesPanel.updateProperties(object); - - } - }); - - editingDomain.getCommandStack().addCommandStackListener(new CommandStackListener() { - public void commandStackChanged(EventObject event) { - toolBar.setEnabledButton(((BasicCommandStack)EEFEditor.this.editingDomain.getCommandStack()).isSaveNeeded(), EEFEditorToolbar.SAVE); - toolBar.setEnabledButton(EEFEditor.this.editingDomain.getCommandStack().canUndo(), EEFEditorToolbar.UNDO); - toolBar.setEnabledButton(EEFEditor.this.editingDomain.getCommandStack().canRedo(), EEFEditorToolbar.REDO); - - Command mostRecentCommand = ((CommandStack) event.getSource()).getMostRecentCommand(); - if (mostRecentCommand != null) { - Collection affectedObjects = mostRecentCommand.getAffectedObjects(); - if (!affectedObjects.isEmpty()) { - Object newSelection = affectedObjects.iterator().next(); - navigationManager.setSelection(newSelection); - navigationManager.navigate(); - } - } - } - }); - - } - - /** - * @return the editingDomain - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * @return the adapterFactory - */ - public AdapterFactory getAdapterFactory() { - return adapterFactory; - } - - /** - * @param originalResources the originalResources to set - */ - public void setOriginalResources(List originalResources) { - this.originalResources = originalResources; - } - - /** - * @return the itemDelegator - */ - public AdapterFactoryItemDelegator getItemDelegator() { - return itemDelegator; - } - - /** - * @return - */ - public EEFEditorToolbar getToolbar() { - return toolBar; - } - - /** - * @return the propertiesPanel - */ - public EEFPropertiesPanel getPropertiesPanel() { - return propertiesPanel; - } - - /** - * @return - */ - public NavigationManager getNavigationManager() { - return navigationManager; - } - - - /** - * @return - */ - public List getOriginalResources() { - return originalResources; - } - - /** - * Create the editor header panel - * @param applicationTitle application title - */ - private void headerPanel(String applicationTitle) { - this.setStyleName("Main", true); - this.setHeight("100%"); - - FlowPanel headerPanel = new FlowPanel(); - headerPanel.setStyleName("Header", true); - - final Label header = new Label(applicationTitle); - header.setStyleName("HeaderLabel", true); - - headerPanel.add(header); - - this.addNorth(headerPanel, 56.0); - } - - /** - * Create the editor body panel - */ - private void bodyPanel() { - DockLayoutPanel bodyPanel = new DockLayoutPanel(Unit.PX); - bodyPanel.setStyleName("Body", true); - bodyPanel.setHeight("100%"); - - this.add(bodyPanel); - - toolBar = new EEFEditorToolbar(); - - SplitLayoutPanel contentPanel = new SplitLayoutPanel(); - contentPanel.setStyleName("Content", true); - - - EEFTreeViewerContentProvider contentProvider = new EEFTreeViewerContentProvider(this); - contentProvider.setEditingDomain(editingDomain); - contentProvider.setSelected(editingDomain.getResourceSet(), true); - treeviewer = new EEFTreeViewer(contentProvider, new ItemProvider(Collections.singleton(editingDomain.getResourceSet()))); - ScrollPanel treeScrollPanel = new ScrollPanel(); - treeScrollPanel.add(treeviewer); - navigationManager = new NavigationManager(editingDomain, treeviewer); - - propertiesPanel = new EEFPropertiesPanel(this, Unit.PX); - - contentPanel.addWest(treeScrollPanel, 400); - contentPanel.add(propertiesPanel); - - bodyPanel.addNorth(toolBar, 28.0); - bodyPanel.add(contentPanel); - } - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/part/EEFEditorToolbar.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/part/EEFEditorToolbar.java deleted file mode 100644 index ef79aebac..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/part/EEFEditorToolbar.java +++ /dev/null @@ -1,152 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor.part; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.HashMap; -import java.util.Map; - -import com.google.gwt.event.dom.client.ClickEvent; -import com.google.gwt.event.dom.client.ClickHandler; -import com.google.gwt.user.client.ui.Button; -import com.google.gwt.user.client.ui.FlowPanel; - -/** - * @author glefur - * - */ -public class EEFEditorToolbar extends FlowPanel { - - public final static int CREATE = 0; - public final static int DELETE = 1; - public final static int VALIDATE = 2; - public final static int SAVE = 3; - public final static int UNDO = 4; - public final static int REDO = 5; - public final static int CUT = 6; - public final static int COPY = 7; - public final static int PASTE = 8; - public final static int UP = 9; - public final static int DOWN = 10; - public final static int NAVIGATE = 11; - - private Collection listeners; - private Map buttons; - - /** - * - */ - public EEFEditorToolbar() { - super(); - - listeners = new ArrayList(); - buttons = new HashMap(); - - this.setStyleName("ToolBar", true); - - addButton(CREATE, "Create..."); - addButton(DELETE, "Delete"); - addButton(VALIDATE, "Validate"); - addButton(SAVE, "Save"); - addButton(UNDO, "Undo"); - addButton(REDO, "Redo"); - addButton(CUT, "Cut"); - addButton(COPY, "Copy"); - addButton(PASTE, "Paste"); - addButton(UP, "Up"); - addButton(DOWN, "Down"); - addButton(NAVIGATE, "Navigate"); - - - } - - - protected void addButton(final int id, final String buttonText) { - final Button button = new Button(); - button.setText(buttonText); - button.addClickHandler(new ClickHandler() { - - @Override - public void onClick(ClickEvent event) { - ToolbarEvent tbEvent = new ToolbarEvent(); - tbEvent.kind = id; - fireToolbarEvent(tbEvent); - } - }); - button.setStyleName("ToolBarButtonLeftMargin"); - - this.add(button); - buttons.put(id, button); - } - - - /** - * Add a toolbar listener. - * @param listener - */ - public void addListener(final ToolbarListener listener) { - listeners.add(listener); - } - - /** - * Remove a toolbar listener. - * @param listener - */ - public void removeListener(final ToolbarListener listener) { - listeners.remove(listener); - } - - /** - * @param id - */ - public void setEnabledButton(boolean state ,int... id) { - for (int i : id) { - if (buttons.get(i) != null) { - buttons.get(i).setEnabled(false); - } - } - } - - - /** - * Fire all the toolbar listeners for an event. - * @param event the event to propagate. - */ - private void fireToolbarEvent(final ToolbarEvent event) { - for (ToolbarListener listener : listeners) { - listener.fireToolbarEvent(event); - } - } - - /** - * Interface for toolbar listeners - * @author glefur - * - */ - public interface ToolbarListener { - - public void fireToolbarEvent(ToolbarEvent event); - - } - - /** - * Event throw by the toolbar. - * @author glefur - * - */ - public class ToolbarEvent { - - public int kind; - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/part/EEFPropertiesPanel.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/part/EEFPropertiesPanel.java deleted file mode 100644 index 12f2f41ab..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/part/EEFPropertiesPanel.java +++ /dev/null @@ -1,319 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor.part; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.Date; -import java.util.HashSet; -import java.util.List; - -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EDataType; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.EEFEditor; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.property.ItemPropertyDescriptorFeatureEditor; - -import com.google.gwt.dom.client.Style.Unit; -import com.google.gwt.event.dom.client.ChangeEvent; -import com.google.gwt.event.dom.client.ChangeHandler; -import com.google.gwt.event.logical.shared.ValueChangeEvent; -import com.google.gwt.event.logical.shared.ValueChangeHandler; -import com.google.gwt.user.client.ui.CheckBox; -import com.google.gwt.user.client.ui.DockLayoutPanel; -import com.google.gwt.user.client.ui.FlowPanel; -import com.google.gwt.user.client.ui.FocusWidget; -import com.google.gwt.user.client.ui.Grid; -import com.google.gwt.user.client.ui.Label; -import com.google.gwt.user.client.ui.ListBox; -import com.google.gwt.user.client.ui.ScrollPanel; -import com.google.gwt.user.client.ui.TextArea; -import com.google.gwt.user.client.ui.TextBox; -import com.google.gwt.user.client.ui.Widget; -import com.google.gwt.user.datepicker.client.DateBox; - -/** - * @author glefur - * - */ -public class EEFPropertiesPanel extends DockLayoutPanel { - - private Grid properties; - private Object oldSelection; - private Collection propertyUpdater; - private EEFEditor editor; - - /** - * @param unit - */ - public EEFPropertiesPanel(EEFEditor editor, Unit unit) { - super(unit); - this.editor = editor; - propertyUpdater = new HashSet(); - this.setStyleName("Properties", true); - this.setHeight("100%"); - - FlowPanel propertiesTitlePanel = new FlowPanel(); - propertiesTitlePanel.setStyleName("PropertiesTitle", true); - - final Label title = new Label("Properties"); - title.setStyleName("PropertiesTitleLabel", true); - - propertiesTitlePanel.add(title); - - this.addNorth(propertiesTitlePanel, 28.0); - - properties = new Grid(); - properties.setWidth("100%"); - ScrollPanel propertiesScrollPanel = new ScrollPanel(); - propertiesScrollPanel.add(properties); - - this.add(propertiesScrollPanel); - } - - /** - * @return the propertyUpdater - */ - public Collection getPropertyUpdater() { - return propertyUpdater; - } - - public void updateProperties(final Object newSelection) { - if (oldSelection == newSelection) { - for (Runnable runnable : propertyUpdater) { - runnable.run(); - } - } else { - editor.getNavigationManager().setSelection(null); - - oldSelection = newSelection; - - List propertyDescriptors = editor.getItemDelegator().getPropertyDescriptors(newSelection); - if (propertyDescriptors != null) { - properties.clear(); - propertyUpdater.clear(); - int size = propertyDescriptors.size(); - properties.resize(size, 2); - properties.getColumnFormatter().setWidth(0, "10%"); - properties.getColumnFormatter().setWidth(1, "90%"); - for (int i = 0; i < size; ++i) { - final IItemPropertyDescriptor propertyDescriptor = propertyDescriptors.get(i); - properties.setText(i, 0, propertyDescriptor.getDisplayName(newSelection)); - Widget widget = null; - final IItemLabelProvider itemLabelProvider = propertyDescriptor.getLabelProvider(newSelection); - final Object feature = propertyDescriptor.getFeature(newSelection); - if (feature instanceof EReference[]) { - final ItemPropertyDescriptorFeatureEditor dialog = new ItemPropertyDescriptorFeatureEditor(newSelection, true, propertyDescriptor) { - @Override - protected void hook(ListBox listBox, List values) { - editor.getNavigationManager().listenTo(listBox, values); - } - }; - dialog.update(); - widget = dialog; - propertyUpdater.add(new Runnable() { - public void run() { - dialog.update(); - } - }); - } else if (feature instanceof EStructuralFeature) { - final EStructuralFeature eStructureFeature = (EStructuralFeature) feature; - final EClassifier eType = eStructureFeature.getEType(); - final Collection choiceOfValues = propertyDescriptor.getChoiceOfValues(newSelection); - if (choiceOfValues != null) { - final List listOfValues = new ArrayList(propertyDescriptor.getChoiceOfValues(newSelection)); - if (propertyDescriptor.isMany(newSelection)) { - boolean valid = true; - for (Object choice : choiceOfValues) { - if (!eType.isInstance(choice)) { - valid = false; - break; - } - } - - if (valid) { - final ItemPropertyDescriptorFeatureEditor dialog = new ItemPropertyDescriptorFeatureEditor(newSelection, true, propertyDescriptor) { - @Override - protected void hook(ListBox listBox, List values) { - editor.getNavigationManager().listenTo(listBox, values); - } - }; - dialog.update(); - widget = dialog; - propertyUpdater.add(new Runnable() { - public void run() { - dialog.update(); - } - }); - } - } - if (widget == null) { - final ListBox listBox = new ListBox(); - widget = listBox; - listBox.setVisibleItemCount(1); - Runnable runnable = new Runnable() { - public void run() { - listBox.clear(); - editor.getNavigationManager().listenTo(listBox, listOfValues); - Object propertyValue = editor.getItemDelegator().getEditableValue(propertyDescriptor.getPropertyValue(newSelection)); - for (Object value : choiceOfValues) { - listBox.addItem(itemLabelProvider.getText(value)); - if (value == null ? propertyValue == null : value.equals(propertyValue)) { - listBox.setSelectedIndex(listBox.getItemCount() - 1); - } - } - } - }; - listBox.addChangeHandler(new ChangeHandler() { - public void onChange(ChangeEvent event) { - Object value = listOfValues.get(listBox.getSelectedIndex()); - propertyDescriptor.setPropertyValue(newSelection, value); - } - }); - runnable.run(); - propertyUpdater.add(runnable); - } - } else if (eType instanceof EDataType) { - final EDataType eDataType = (EDataType) eType; - if (eDataType.isSerializable()) { - if (propertyDescriptor.isMany(newSelection)) { - final ItemPropertyDescriptorFeatureEditor dialog = new ItemPropertyDescriptorFeatureEditor(newSelection, propertyDescriptor) { - @Override - protected void hook(ListBox listBox, List values) { - editor.getNavigationManager().listenTo(listBox, values); - } - }; - dialog.update(); - widget = dialog; - propertyUpdater.add(new Runnable() { - public void run() { - dialog.update(); - } - }); - } else { - if (eDataType.getInstanceClass() == Date.class) { - final DateBox dateBox = new DateBox(); - widget = dateBox; - Runnable runnable = new Runnable() { - public void run() { - Object propertyValue = editor.getItemDelegator().getEditableValue(propertyDescriptor.getPropertyValue(newSelection)); - dateBox.setValue((Date) propertyValue); - } - }; - dateBox.addValueChangeHandler(new ValueChangeHandler() { - public void onValueChange(ValueChangeEvent event) { - propertyDescriptor.setPropertyValue(newSelection, event.getValue()); - } - }); - runnable.run(); - propertyUpdater.add(runnable); - - } else if (eDataType.getInstanceClass() == Boolean.class || eDataType.getInstanceClass() == boolean.class) { - final CheckBox checkBox = new CheckBox(); - widget = checkBox; - Runnable runnable = new Runnable() { - public void run() { - Object propertyValue = editor.getItemDelegator().getEditableValue(propertyDescriptor.getPropertyValue(newSelection)); - checkBox.setValue(Boolean.TRUE.equals(propertyValue)); - } - }; - checkBox.addValueChangeHandler(new ValueChangeHandler() { - public void onValueChange(ValueChangeEvent event) { - propertyDescriptor.setPropertyValue(newSelection, event.getValue()); - } - }); - runnable.run(); - propertyUpdater.add(runnable); - } else if (propertyDescriptor.isMultiLine(newSelection)) { - final TextArea textArea = new TextArea(); - widget = textArea; - Runnable runnable = new Runnable() { - public void run() { - Object propertyValue = editor.getItemDelegator().getEditableValue(propertyDescriptor.getPropertyValue(newSelection)); - textArea.setText(EcoreUtil.convertToString(eDataType, propertyValue)); - } - }; - textArea.addValueChangeHandler(new ValueChangeHandler() { - public void onValueChange(ValueChangeEvent event) { - propertyDescriptor.setPropertyValue(newSelection, EcoreUtil.createFromString(eDataType, event.getValue())); - } - }); - runnable.run(); - propertyUpdater.add(runnable); - } else { - final TextBox textBox = new TextBox(); - widget = textBox; - textBox.addValueChangeHandler(new ValueChangeHandler() { - public void onValueChange(ValueChangeEvent event) { - String value = event.getValue(); - propertyDescriptor.setPropertyValue(newSelection, EcoreUtil.createFromString(eDataType, value)); - // TOD0 - // commandStack.execute(SetCommand.create(editingDomain, - // object, feature, - // EcoreUtil.createFromString(eDataType, - // value))); - } - }); - Runnable runnable = new Runnable() { - public void run() { - Object propertyValue = editor.getItemDelegator().getEditableValue(propertyDescriptor.getPropertyValue(newSelection)); - String stringValue = EcoreUtil.convertToString(eDataType, propertyValue); - if (!textBox.getText().equals(stringValue)) { - textBox.setText(stringValue); - } - } - }; - runnable.run(); - propertyUpdater.add(runnable); - } - } - } - } - } else { - final TextBox textBox = new TextBox(); - widget = textBox; - textBox.addValueChangeHandler(new ValueChangeHandler() { - public void onValueChange(ValueChangeEvent event) { - String value = event.getValue(); - propertyDescriptor.setPropertyValue(newSelection, value); - } - }); - Runnable runnable = new Runnable() { - public void run() { - Object propertyValue = editor.getItemDelegator().getEditableValue(propertyDescriptor.getPropertyValue(newSelection)); - String stringValue = propertyValue == null ? null : propertyDescriptor.getLabelProvider(newSelection).getText(propertyValue); - if (!textBox.getText().equals(stringValue)) { - textBox.setText(stringValue); - } - } - }; - runnable.run(); - propertyUpdater.add(runnable); - } - if (widget != null) { - widget.setWidth("95%"); - properties.setWidget(i, 1, widget); - if (!propertyDescriptor.canSetProperty(newSelection) && widget instanceof FocusWidget) { - ((FocusWidget) widget).setEnabled(false); - - } - } - } - } - } - } - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/property/FeatureEditor.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/property/FeatureEditor.java deleted file mode 100644 index 7db0edde4..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/property/FeatureEditor.java +++ /dev/null @@ -1,325 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor.property; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.util.BasicEList; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.common.util.UniqueEList; -import org.eclipse.emf.ecore.EDataType; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.provider.IItemLabelProvider; - -import com.google.gwt.event.dom.client.ClickEvent; -import com.google.gwt.event.dom.client.ClickHandler; -import com.google.gwt.user.client.ui.Button; -import com.google.gwt.user.client.ui.Composite; -import com.google.gwt.user.client.ui.Grid; -import com.google.gwt.user.client.ui.ListBox; -import com.google.gwt.user.client.ui.TextBox; - -public abstract class FeatureEditor extends Composite { - protected Object object; - protected boolean isSortChoices; - protected List values; - protected List choiceOfValues; - protected ListBox valueBox; - protected ListBox choiceBox; - protected EDataType eDataType; - protected TextBox textBox; - - protected FeatureEditor(Object object, boolean isSortChoices, final EDataType eDataType) { - this.object = object; - this.isSortChoices = isSortChoices; - this.eDataType = eDataType; - - Grid grid = new Grid(); - grid.resize(1, 3); - - grid.getColumnFormatter().setWidth(0, "40%"); - grid.getColumnFormatter().setWidth(1, "20%"); - grid.getColumnFormatter().setWidth(2, "40%"); - - valueBox = new ListBox(true); - valueBox.setVisibleItemCount(4); - valueBox.setWidth("100%"); - grid.setWidget(0, 0, valueBox); - - Grid buttonGrid = new Grid(); - buttonGrid.resize(2, 2); - Button upButton = new Button("Up ^"); - buttonGrid.setWidget(0, 0, upButton); - Button downButton = new Button("Down v"); - buttonGrid.setWidget(1, 0, downButton); - Button addButton = new Button("< Add"); - buttonGrid.setWidget(0, 1, addButton); - Button removeButton = new Button("Remove >"); - buttonGrid.setWidget(1, 1, removeButton); - grid.setWidget(0, 1, buttonGrid); - - if (eDataType != null) { - textBox = new TextBox(); - textBox.setWidth("100%"); - grid.setWidget(0, 2, textBox); - - /* - * textBox.addValueChangeHandler (new - * ValueChangeHandler() { public void - * onValueChange(ValueChangeEvent event) { List - * result = isUnique() ? new UniqueEList(values) : new - * ArrayList(values); try { Object value = - * EcoreUtil.createFromString(eDataType, event.getValue()); - * result.add(value); setValue(result); } catch - * (RuntimeException exception) { // Ignore for now } } }); - */ - } else { - choiceBox = new ListBox(true); - choiceBox.setVisibleItemCount(4); - choiceBox.setWidth("100%"); - grid.setWidget(0, 2, choiceBox); - } - - addButton.addClickHandler(new ClickHandler() { - public void onClick(ClickEvent event) { - List result = isUnique() ? new UniqueEList(values) : new ArrayList(values); - if (eDataType != null) { - try { - Object value = EcoreUtil.createFromString(eDataType, textBox.getValue()); - result.add(value); - } catch (RuntimeException exception) { - // Ignore for now - } - } else { - for (int i = 0, size = choiceBox.getItemCount(); i < size; ++i) { - if (choiceBox.isItemSelected(i)) { - result.add(choiceOfValues.get(i)); - } - } - } - setValue(result); - } - }); - - removeButton.addClickHandler(new ClickHandler() { - public void onClick(ClickEvent event) { - List result = isUnique() ? new UniqueEList(values) : new ArrayList(values); - for (int i = 0, size = valueBox.getItemCount(); i < size; ++i) { - if (valueBox.isItemSelected(i)) { - result.remove(values.get(i)); - } - } - setValue(result); - } - }); - upButton.addClickHandler(new ClickHandler() { - public void onClick(ClickEvent event) { - EList result = new BasicEList(values); - for (int i = 0, size = valueBox.getItemCount(); i < size; ++i) { - if (valueBox.isItemSelected(i)) { - if (i != 0) { - result.move(i, i - 1); - } - } - } - setValue(result); - } - }); - downButton.addClickHandler(new ClickHandler() { - public void onClick(ClickEvent event) { - EList result = new BasicEList(values); - for (int i = 0, size = valueBox.getItemCount(); i < size; ++i) { - if (valueBox.isItemSelected(i)) { - if (i + 1 < size) { - result.move(i, i + 1); - } - } - } - setValue(result); - } - }); - initWidget(grid); - } - - protected void hook(ListBox listBox, List values) { - // Do nothing. - - } - - public void update() { - IItemLabelProvider labelProvider = getLabelProvider(); - List oldValues = values; - values = new ArrayList(getValues()); - - List oldValueSelection = new ArrayList(); - int valueBoxItemCount = valueBox.getItemCount(); - if (valueBoxItemCount != 0) { - for (int i = 0; i < valueBoxItemCount; ++i) { - if (valueBox.isItemSelected(i)) { - oldValueSelection.add(oldValues.get(i)); - } - } - valueBox.clear(); - } - - for (Object value : values) { - valueBox.addItem(labelProvider.getText(value)); - if (oldValueSelection.contains(value) || oldValues != null && !oldValues.contains(value)) { - valueBox.setItemSelected(valueBox.getItemCount() - 1, true); - } - } - - hook(valueBox, values); - - if (eDataType != null) { - textBox.setValue(""); - } else { - List oldChoiceSelection = new ArrayList(); - int choiceBoxItemCount = choiceBox.getItemCount(); - if (choiceBoxItemCount != 0) { - for (int i = 0; i < choiceBoxItemCount; ++i) { - if (choiceBox.isItemSelected(i)) { - oldChoiceSelection.add(choiceOfValues.get(i)); - } - } - choiceBox.clear(); - } - - Collection basicChoices = getChoiceOfValues(); - if (basicChoices == null) { - choiceOfValues = null; - } else { - choiceOfValues = new ArrayList(basicChoices); - if (isSortChoices) { - createItems(choiceOfValues, labelProvider, null, true); - } - for (Object value : choiceOfValues) { - choiceBox.addItem(labelProvider.getText(value)); - if (oldChoiceSelection.contains(value) || oldValues != null && oldValues.contains(value) && !values.contains(value)) { - choiceBox.setItemSelected(choiceBox.getItemCount() - 1, true); - } - } - hook(choiceBox, choiceOfValues); - } - } - } - - public static String[] createItems(List list, IItemLabelProvider labelProvider, String filter, boolean sorted) { - String[] result; - - if (filter != null && filter.length() > 0) { - sorted = true; - } - - // If there are objects to populate... - // - if (list != null && list.size() > 0) { - if (sorted) { - List unsortedList = new ArrayList(list.size()); - if (filter != null && filter.length() > 0) { - for (int i = 0; i < list.size(); i++) { - if (select(filter, labelProvider.getText(list.get(i)))) { - unsortedList.add(list.get(i)); - } - } - } else { - unsortedList.addAll(list); - } - list.clear(); - - StringPositionPair[] pairs = new StringPositionPair[unsortedList.size()]; - - for (int i = 0, size = unsortedList.size(); i < size; ++i) { - Object object = unsortedList.get(i); - pairs[i] = new StringPositionPair(labelProvider.getText(object), i); - } - - Arrays.sort(pairs); - - // Create a new array. - // - result = new String[unsortedList.size()]; - // Fill in the result array with labels and re-populate the - // original list in order. - // - for (int i = 0, size = unsortedList.size(); i < size; ++i) { - result[i] = pairs[i].key; - list.add(unsortedList.get(pairs[i].position)); - } - } else { - // Create a new array. - // - result = new String[list.size()]; - // Fill in the array with labels. - // - for (int i = 0, size = list.size(); i < size; ++i) { - Object object = list.get(i); - result[i] = labelProvider.getText(object); - } - } - } else { - result = new String[] { "" }; - } - - return result; - } - - - protected abstract IItemLabelProvider getLabelProvider(); - - protected abstract List getValues(); - - protected abstract Collection getChoiceOfValues(); - - protected abstract boolean isMultiLine(); - - protected abstract boolean isUnique(); - - protected abstract void setValue(Object value); - - public static boolean select(String filter, String labelValue) { - if (filter != null && filter.length() > 0) { - if (filter.length() > labelValue.length()) { - return false; - } - for (int i = 0; i < filter.length(); i++) { - if (Character.toLowerCase(filter.charAt(i)) != Character.toLowerCase(labelValue.charAt(i))) { - return false; - } - } - } - return true; - } - - private static class StringPositionPair implements Comparable { - public String key; - public int position; - - StringPositionPair(String key, int position) { - this.key = key; - this.position = position; - } - - public int compareTo(StringPositionPair object) { - if (object == this || key == object.key) { - return 0; - } else if (key == null) { - return -1; - } else { - return key.compareTo(object.key); - } - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/property/ItemPropertyDescriptorFeatureEditor.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/property/ItemPropertyDescriptorFeatureEditor.java deleted file mode 100644 index 136e4a2d3..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/property/ItemPropertyDescriptorFeatureEditor.java +++ /dev/null @@ -1,69 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor.property; - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; - -public class ItemPropertyDescriptorFeatureEditor extends FeatureEditor { - protected IItemPropertyDescriptor propertyDescriptor; - - public ItemPropertyDescriptorFeatureEditor(Object object, IItemPropertyDescriptor propertyDescriptor) { - super(object, false, ((EAttribute) propertyDescriptor.getFeature(object)).getEAttributeType()); - this.propertyDescriptor = propertyDescriptor; - } - - public ItemPropertyDescriptorFeatureEditor(Object object, boolean isSortChoices, IItemPropertyDescriptor propertyDescriptor) { - super(object, isSortChoices, null); - this.propertyDescriptor = propertyDescriptor; - } - - @Override - protected IItemLabelProvider getLabelProvider() { - return propertyDescriptor.getLabelProvider(object); - } - - @Override - protected List getValues() { - Object propertyValue = propertyDescriptor.getPropertyValue(object); - if (propertyValue instanceof IItemPropertySource) { - propertyValue = ((IItemPropertySource) propertyValue).getEditableValue(propertyValue); - } - return (List) propertyValue; - } - - @Override - protected Collection getChoiceOfValues() { - return propertyDescriptor.getChoiceOfValues(object); - } - - @Override - protected boolean isMultiLine() { - return propertyDescriptor.isMultiLine(object); - } - - @Override - protected boolean isUnique() { - Object feature = propertyDescriptor.getFeature(object); - return !(feature instanceof EStructuralFeature) || ((EStructuralFeature) feature).isUnique(); - } - - @Override - protected void setValue(Object value) { - propertyDescriptor.setPropertyValue(object, value); - } - } diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/EditorToolbarListener.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/EditorToolbarListener.java deleted file mode 100644 index a834190f2..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/EditorToolbarListener.java +++ /dev/null @@ -1,471 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor.util; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.emf.common.command.BasicCommandStack; -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.command.CompoundCommand; -import org.eclipse.emf.common.command.UnexecutableCommand; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EPackage.Registry; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.resource.URIConverter; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.command.CopyToClipboardCommand; -import org.eclipse.emf.edit.command.CreateChildCommand; -import org.eclipse.emf.edit.command.CutToClipboardCommand; -import org.eclipse.emf.edit.command.DeleteCommand; -import org.eclipse.emf.edit.command.MoveCommand; -import org.eclipse.emf.edit.command.PasteFromClipboardCommand; -import org.eclipse.emf.edit.command.RemoveCommand; -import org.eclipse.emf.eef.runtime.ui.gwt.command.CreateObjectCommand; -import org.eclipse.emf.eef.runtime.ui.gwt.command.CreateResourceCommand; -import org.eclipse.emf.eef.runtime.ui.gwt.command.SaveCommand; -import org.eclipse.emf.eef.runtime.ui.gwt.command.UpdateURIConverterCommand; -import org.eclipse.emf.eef.runtime.ui.gwt.dialog.CreateObjectDialog; -import org.eclipse.emf.eef.runtime.ui.gwt.dialog.CreateResourceDialog; -import org.eclipse.emf.eef.runtime.ui.gwt.dialog.ErrorDialog; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.EEFEditor; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.part.EEFEditorToolbar; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.part.EEFEditorToolbar.ToolbarEvent; - -import com.google.gwt.user.client.ui.TreeItem; - -public class EditorToolbarListener implements EEFEditorToolbar.ToolbarListener { - - private EEFEditor editor; - private HashMap process; - - /** - * @param editor - */ - public EditorToolbarListener(EEFEditor editor) { - this.editor = editor; - this.process = new HashMap(); - } - - /** - * @param selection - */ - public void update(Object selection) { - updateDeleteProcess(selection); - updateToolbarButton(EEFEditorToolbar.DELETE); - updateCutProcess(selection); - updateToolbarButton(EEFEditorToolbar.CUT); - updateCopyProcess(selection); - updateToolbarButton(EEFEditorToolbar.COPY); - updatePasteProcess(selection); - updateToolbarButton(EEFEditorToolbar.PASTE); - updateUpProcess(selection); - updateToolbarButton(EEFEditorToolbar.UP); - updateDownProcess(selection); - updateToolbarButton(EEFEditorToolbar.DOWN); - } - - private void updateDeleteProcess(Object selection) { - if (selection instanceof Resource) { - final Resource resource = (Resource) selection; - final Command deleteContentsCommand = DeleteCommand.create(editor.getEditingDomain(), resource.getContents()); - final RemoveCommand removeResourceCommand = new RemoveCommand(editor.getEditingDomain(), editor.getEditingDomain().getResourceSet().getResources(), resource); - process.put(EEFEditorToolbar.DELETE, new EventProcess(new CompoundCommand() { - @Override - protected boolean prepare() { - return true; - } - - @Override - public void execute() { - appendAndExecute(deleteContentsCommand); - appendAndExecute(removeResourceCommand); - } - }, null)); - } else { - process.put(EEFEditorToolbar.DELETE, new EventProcess(DeleteCommand.create(editor.getEditingDomain(), selection), null)); - } - } - - private void updateCutProcess(Object selection) { - process.put(EEFEditorToolbar.CUT, new EventProcess(CutToClipboardCommand.create(editor.getEditingDomain(), selection), null)); - } - - private void updateCopyProcess(Object selection) { - process.put(EEFEditorToolbar.COPY, new EventProcess(selection instanceof EObject ? CopyToClipboardCommand.create(editor.getEditingDomain(), selection) : UnexecutableCommand.INSTANCE, null)); - } - - private void updatePasteProcess(Object selection) { - process.put(EEFEditorToolbar.PASTE, new EventProcess(PasteFromClipboardCommand.create(editor.getEditingDomain(), selection, null), null)); - } - - private void updateUpProcess(Object selection) { - Object owner = editor.getEditingDomain().getParent(selection); - if (owner != null) { - List children = new ArrayList(editor.getEditingDomain().getChildren(owner)); - int index = children.indexOf(selection); - if (index != -1) { - process.put(EEFEditorToolbar.UP, new EventProcess(MoveCommand.create(editor.getEditingDomain(), owner, null, selection, index - 1), null)); - return; - } - } - process.put(EEFEditorToolbar.UP, new EventProcess(UnexecutableCommand.INSTANCE, null)); - - } - - private void updateDownProcess(Object selection) { - Object owner = editor.getEditingDomain().getParent(selection); - if (owner != null) { - List children = new ArrayList(editor.getEditingDomain().getChildren(owner)); - int index = children.indexOf(selection); - if (index != -1) { - process.put(EEFEditorToolbar.DOWN, new EventProcess(MoveCommand.create(editor.getEditingDomain(), owner, null, selection, index + 1), null)); - return; - } - } - process.put(EEFEditorToolbar.DOWN, new EventProcess(UnexecutableCommand.INSTANCE, null)); - } - - - private void updateToolbarButton(int id) { - editor.getToolbar().setEnabledButton(process.get(id).canExecute(), id); - } - - @Override - public void fireToolbarEvent(ToolbarEvent event) { - EventProcess process = null; - switch (event.kind) { - case EEFEditorToolbar.CREATE: - process = processCreate(event); - break; - case EEFEditorToolbar.DELETE: - process = this.process.get(EEFEditorToolbar.DELETE); - break; - case EEFEditorToolbar.VALIDATE: - process = processValidate(event); - break; - case EEFEditorToolbar.SAVE: - process = processSave(event); - break; - case EEFEditorToolbar.UNDO: - process = processUndo(event); - break; - case EEFEditorToolbar.REDO: - process = processRedo(event); - break; - case EEFEditorToolbar.CUT: - process = this.process.get(EEFEditorToolbar.CUT); - break; - case EEFEditorToolbar.COPY: - process = this.process.get(EEFEditorToolbar.COPY); - break; - case EEFEditorToolbar.PASTE: - process = this.process.get(EEFEditorToolbar.PASTE); - break; - case EEFEditorToolbar.UP: - process = this.process.get(EEFEditorToolbar.UP); - break; - case EEFEditorToolbar.DOWN: - process = this.process.get(EEFEditorToolbar.DOWN); - break; - case EEFEditorToolbar.NAVIGATE: - process = processNavigate(event); - break; - - default: - break; - } - if (process.command != null) { - editor.getEditingDomain().getCommandStack().execute(process.command); - } - if (process.callback != null) { - process.callback.process(); - } - } - - private EventProcess processCreate(ToolbarEvent event) { - Object selection = editor.getNavigationManager().getSelection(); - EventProcess result = null; - if (selection instanceof ResourceSet) { - CreateResourceDialog dialog = new CreateResourceDialog() { - - /* - * (non-Javadoc) - * - * @see - * org.eclipse.emf.eef.runtime.ui.gwt.dialog.CreateResourceDialog - * #defaultValue() - */ - @Override - protected String defaultValue() { - int count = 1; - while (editor.getEditingDomain().getResourceSet().getResource(URI.createURI("datastore:/resource" + count), false) != null) { - ++count; - } - return "datastore:/resource" + count; - } - - @Override - protected boolean valideValue(Object value) { - return editor.getEditingDomain().getResourceSet().getResource(URI.createURI((String) value), false) == null; - } - - @Override - protected EventProcess processOk(final Object value) { - return new EventProcess(new CreateResourceCommand(editor.getEditingDomain(), (String) value), null); - } - - }; - dialog.open(); - result = dialog.getResult(); - } else if (selection instanceof Resource) { - List input = new ArrayList(); - final Resource resource = (Resource) selection; - Registry packageRegistry = editor.getEditingDomain().getResourceSet().getPackageRegistry(); - for (String nsURI : packageRegistry.keySet()) { - EPackage ePackage = packageRegistry.getEPackage(nsURI); - for (EClassifier eClassifier : ePackage.getEClassifiers()) { - if (eClassifier instanceof EClass) { - EClass eClass = (EClass) eClassifier; - if (!eClass.isAbstract()) { - EObject eObject = EcoreUtil.create(eClass); - input.add(eObject); - } - } - } - } - - CreateObjectDialog dialog = new CreateObjectDialog() { - - /* - * (non-Javadoc) - * - * @see - * org.eclipse.emf.eef.runtime.ui.gwt.dialog.CreateObjectDialog - * #getString(java.lang.Object) - */ - @Override - public String getString(Object object) { - return "New " + editor.getItemDelegator().getText(object); - } - - /* - * (non-Javadoc) - * - * @see - * org.eclipse.emf.eef.runtime.ui.gwt.dialog.CreateObjectDialog - * #processOk() - */ - @Override - protected Object processOk(final Object selection) { - return new EventProcess(new CreateObjectCommand(editor.getEditingDomain(), resource, (String) selection), null); - } - - }; - - dialog.setInput(input); - dialog.open(); - result = (EventProcess) dialog.getResult(); - - } else { - Collection newChildDescriptors = editor.getEditingDomain().getNewChildDescriptors(selection, null); - final List commands = new ArrayList(); - for (Object descriptor : newChildDescriptors) { - Command command = CreateChildCommand.create(editor.getEditingDomain(), selection, descriptor, Collections.singleton(selection)); - commands.add(command); - } - CreateObjectDialog dialog = new CreateObjectDialog() { - - /* - * (non-Javadoc) - * - * @see - * org.eclipse.emf.eef.runtime.ui.gwt.dialog.CreateObjectDialog - * #processOk(java.lang.Object) - */ - @Override - protected Object processOk(Object selection) { - return new EventProcess((Command) selection, null); - } - - /* - * (non-Javadoc) - * - * @see - * org.eclipse.emf.eef.runtime.ui.gwt.dialog.CreateObjectDialog - * #getString(java.lang.Object) - */ - @Override - public String getString(Object object) { - return ((Command) object).getLabel(); - } - - }; - dialog.setInput(commands); - dialog.open(); - result = (EventProcess) dialog.getResult(); - } - return result; - } - - private EventProcess processSave(ToolbarEvent event) { - CompoundCommand result = new CompoundCommand(); - EList resources = editor.getEditingDomain().getResourceSet().getResources(); - for (Resource resource : resources) { - if (resource.isLoaded()) { - Map options = null; - if (editor.getOriginalResources().contains(resource)) { - options = new HashMap(); - options.put(URIConverter.OPTION_UPDATE_ONLY_IF_TIME_STAMP_MATCHES, resource.getTimeStamp()); - } - result.append(new SaveCommand(resource, options)); - } - } - for (Resource resource : editor.getOriginalResources()) { - if (!resources.contains(resource)) { - Map options = null; - if (resource.isLoaded()) { - options = new HashMap(); - options.put(URIConverter.OPTION_UPDATE_ONLY_IF_TIME_STAMP_MATCHES, resource.getTimeStamp()); - } - result.append(new UpdateURIConverterCommand(editor.getEditingDomain().getResourceSet().getURIConverter(), resource.getURI(), options)); - } - } - return new EventProcess(result, new EventProcess.CallBack() { - - @Override - public void process() { - editor.getOriginalResources().clear(); - editor.getOriginalResources().addAll(editor.getEditingDomain().getResourceSet().getResources()); - ((BasicCommandStack) editor.getEditingDomain().getCommandStack()).saveIsDone(); - editor.getToolbar().setEnabledButton(false, EEFEditorToolbar.SAVE); - } - }); - } - - private EventProcess processUndo(ToolbarEvent event) { - return new EventProcess(null, new EventProcess.CallBack() { - - @Override - public void process() { - editor.getEditingDomain().getCommandStack().undo(); - } - }); - } - - private EventProcess processRedo(ToolbarEvent event) { - return new EventProcess(null, new EventProcess.CallBack() { - - @Override - public void process() { - editor.getEditingDomain().getCommandStack().redo(); - } - }); - } - - private EventProcess processValidate(ToolbarEvent event) { - Diagnostician diagnostician = new Diagnostician() { - - @Override - public String getObjectLabel(EObject eObject) { - return !eObject.eIsProxy() ? editor.getItemDelegator().getText(eObject) : super.getObjectLabel(eObject); - } - }; - Map context = diagnostician.createDefaultContext(); - EList resources = editor.getEditingDomain().getResourceSet().getResources(); - BasicDiagnostic diagnostics = new BasicDiagnostic(); - for (Resource resource : resources) { - if (resource.isLoaded()) { - for (EObject eObject : resource.getContents()) { - diagnostician.validate(eObject, diagnostics, context); - } - } - } - final ErrorDialog dialogBox; - final Object newSelection; - if (diagnostics.getSeverity() == Diagnostic.OK) { - dialogBox = new ErrorDialog("Problems", Diagnostic.OK_INSTANCE) { - - /* - * (non-Javadoc) - * - * @see org.eclipse.emf.eef.runtime.ui.gwt.dialog.ErrorDialog# - * processError() - */ - @Override - protected Object processError(TreeItem treeItem) { - if (treeItem != null) { - return treeItem.getUserObject(); - } - return null; - } - - }; - newSelection = dialogBox.getSelection(); - } else { - dialogBox = new ErrorDialog("Problems", diagnostics.getChildren()) { - - /* - * (non-Javadoc) - * - * @see org.eclipse.emf.eef.runtime.ui.gwt.dialog.ErrorDialog# - * processError() - */ - @Override - protected Object processError(TreeItem treeItem) { - if (treeItem != null) { - return treeItem.getUserObject(); - } - return null; - } - - }; - newSelection = dialogBox.getSelection(); - } - dialogBox.open(); - return new EventProcess(null, new EventProcess.CallBack() { - - @Override - public void process() { - updateTreeSelection(newSelection); - } - }); - } - - private EventProcess processNavigate(ToolbarEvent event) { - return new EventProcess(null, new EventProcess.CallBack() { - - @Override - public void process() { - editor.getNavigationManager().navigate(); - } - }); - } - - protected void updateTreeSelection(Object newSelection) { - editor.getNavigationManager().setSelection(newSelection); - editor.getNavigationManager().navigate(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/EventProcess.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/EventProcess.java deleted file mode 100644 index 27c3efb28..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/EventProcess.java +++ /dev/null @@ -1,51 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor.util; - -import org.eclipse.emf.common.command.Command; - - -public class EventProcess { - - public Command command; - public CallBack callback; - /** - * @param command - * @param callback - */ - public EventProcess(Command command, CallBack callback) { - super(); - this.command = command; - this.callback = callback; - } - - /** - * @return - */ - public boolean canExecute() { - boolean result = false; - if (command != null) { - result = command.canExecute(); - } - if (callback != null) { - result &= true; - } - return result; - } - - public interface CallBack { - - void process(); - - } - -} - diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/NavigationManager.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/NavigationManager.java deleted file mode 100644 index 15701f956..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/util/NavigationManager.java +++ /dev/null @@ -1,135 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor.util; - -import java.util.List; - -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.widget.EEFTreeViewer; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.widget.EEFTreeViewerContentProvider; - -import com.google.gwt.core.client.Scheduler; -import com.google.gwt.event.dom.client.BlurEvent; -import com.google.gwt.event.dom.client.BlurHandler; -import com.google.gwt.event.dom.client.ChangeEvent; -import com.google.gwt.event.dom.client.ChangeHandler; -import com.google.gwt.event.dom.client.FocusEvent; -import com.google.gwt.event.dom.client.FocusHandler; -import com.google.gwt.event.shared.HandlerRegistration; -import com.google.gwt.user.client.ui.ListBox; - -/** - * @author glefur - * - */ -public class NavigationManager { - - private Object selection; - - private EditingDomain editingDomain; - private EEFTreeViewer treeviewer; - private NavigationListener navigationListener; - - - /** - * @param editingDomain - * @param treeviewer - */ - public NavigationManager(EditingDomain editingDomain, EEFTreeViewer treeviewer) { - this.editingDomain = editingDomain; - this.treeviewer = treeviewer; - this.navigationListener = new NavigationListener(); - } - - /** - * @return the selection - */ - public Object getSelection() { - return selection; - } - - /** - * @param selection - * the selection to set - */ - public void setSelection(Object selection) { - this.selection = selection; - //TODO: if selection == null => disabling Navigation button - } - - /** - * - */ - public void navigate() { - EEFTreeViewerContentProvider contentProvider = (EEFTreeViewerContentProvider) treeviewer.getTreeViewModel(); - final Object oldSelection = contentProvider.getTreeSelection(); - focus(); - Scheduler.get().scheduleDeferred(new Scheduler.ScheduledCommand() { - public void execute() { - setSelection(oldSelection); - } - }); - - } - - public void focus() { - treeviewer.expand(editingDomain.getTreePath(editingDomain.getParent(selection))); - ((EEFTreeViewerContentProvider) treeviewer.getTreeViewModel()).setSelected(selection, true); - - } - - - public void listenTo(ListBox listBox, List values) { - navigationListener.listenTo(listBox, values); - } - - /** - * @return the navigationListener - */ - public NavigationListener getNavigationListener() { - return navigationListener; - } - - private class NavigationListener { - - public void listenTo(final ListBox listBox, final List values) { - listBox.addFocusHandler(new FocusHandler() { - protected HandlerRegistration changeHandlerRegistration; - - { - listBox.addBlurHandler(new BlurHandler() { - public void onBlur(BlurEvent event) { - if (changeHandlerRegistration != null) { - changeHandlerRegistration.removeHandler(); - changeHandlerRegistration = null; - } - } - }); - } - - public void onFocus(FocusEvent event) { - updateSelection(); - changeHandlerRegistration = listBox.addChangeHandler(new ChangeHandler() { - public void onChange(ChangeEvent event) { - updateSelection(); - } - }); - } - - void updateSelection() { - int selectedIndex = listBox.getSelectedIndex(); - setSelection(selectedIndex == -1 || selectedIndex >= values.size() ? null : values.get(selectedIndex)); - } - }); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/EEFTreeViewer.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/EEFTreeViewer.java deleted file mode 100644 index ffd45b20a..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/EEFTreeViewer.java +++ /dev/null @@ -1,50 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor.widget; - -import java.util.List; - -import com.google.gwt.core.client.GWT; -import com.google.gwt.user.cellview.client.CellTree; -import com.google.gwt.user.cellview.client.TreeNode; -import com.google.gwt.view.client.SelectionChangeEvent; -import com.google.gwt.view.client.TreeViewModel; - -public class EEFTreeViewer extends CellTree { - public EEFTreeViewer(TreeViewModel viewModel, T rootValue) { - super(viewModel, rootValue, (Resources) GWT.create(CellTree.BasicResources.class)); - } - - public void expand(List path) { - TreeNode node = getRootTreeNode(); - if (node != null) { - LOOP: for (int i = 0, size = path.size(); i < size; ++i) { - Object segment = path.get(i); - for (int j = 0, count = node.getChildCount(); j < count; ++j) { - Object childValue = node.getChildValue(j); - if (childValue.equals(segment)) { - node = node.setChildOpen(j, true); - continue LOOP; - } - } - break; - } - } - } - - /** - * @param handler - */ - public void addSelectionChangeHandler(SelectionChangeEvent.Handler handler) { - ((EEFTreeViewerContentProvider)getTreeViewModel()).addSelectionChangeHandler(handler); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/EEFTreeViewerContentProvider.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/EEFTreeViewerContentProvider.java deleted file mode 100644 index 6b7203299..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/EEFTreeViewerContentProvider.java +++ /dev/null @@ -1,191 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor.widget; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collection; -import java.util.HashSet; -import java.util.List; -import java.util.Set; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.notify.impl.AdapterImpl; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.eef.runtime.ui.gwt.editor.EEFEditor; - -import com.google.gwt.view.client.HasData; -import com.google.gwt.view.client.ListDataProvider; -import com.google.gwt.view.client.SelectionChangeEvent; -import com.google.gwt.view.client.SingleSelectionModel; -import com.google.gwt.view.client.TreeViewModel; - - -/** - * @author glefur - * - */ - -public class EEFTreeViewerContentProvider implements TreeViewModel { - - - private SingleSelectionModel treeSelection; - - private EEFEditor editor; - private EditingDomain editingDomain; - - public EEFTreeViewerContentProvider(EEFEditor editor) { - this.treeSelection = new SingleSelectionModel(); - this.editor = editor; - } - - /** - * @param editingDomain the editingDomain to set - */ - public void setEditingDomain(EditingDomain editingDomain) { - this.editingDomain = editingDomain; - } - - /** - * @param newSelection - */ - public void setSelected(Object selection, boolean state) { - treeSelection.setSelected(selection, state); - } - - /** - * @param handler - */ - public void addSelectionChangeHandler(SelectionChangeEvent.Handler handler) { - treeSelection.addSelectionChangeHandler(handler); - } - - /** - * @return the selection - */ - public Object getTreeSelection() { - return treeSelection.getSelectedObject(); - } - - public NodeInfo getNodeInfo(final T value) { - final ListDataProvider abstractListViewAdapter = new ListDataProvider() { - int size; - - class NodeAdapter extends AdapterImpl implements INotifyChangedListener { - Set children = new HashSet(); - - @Override - public void notifyChanged(Notification msg) { - if (msg.getEventType() != Notification.REMOVING_ADAPTER) { - update(); - if (!(msg.getNotifier() instanceof EObject)) { - for (Runnable runnable : editor.getPropertiesPanel().getPropertyUpdater()) { - runnable.run(); - } - } - } - } - - public void listenTo(Object target) { - if (target instanceof Notifier) { - ((Notifier) target).eAdapters().add(this); - } else if (target instanceof IChangeNotifier) { - ((IChangeNotifier) target).addListener(this); - } - } - - public void stopListeningTo(Object target) { - if (target instanceof Notifier) { - ((Notifier) target).eAdapters().remove(this); - } else if (target instanceof IChangeNotifier) { - ((IChangeNotifier) target).removeListener(this); - } - } - - public void listenTo(List children) { - // TODO - // I don't know how to update just one child. :-( - - boolean isListeningToValue = !this.children.isEmpty(); - Set oldChildren = new HashSet(this.children); - for (Object child : children) { - if (this.children.contains(child)) { - oldChildren.remove(child); - } else { - this.children.add(child); - listenTo(child); - } - } - for (Object child : oldChildren) { - stopListeningTo(child); - this.children.remove(child); - } - if (isListeningToValue) { - if (children.isEmpty()) { - stopListeningTo(value); - } - } else if (!children.isEmpty()) { - listenTo(value); - } - } - } - - protected NodeAdapter nodeAdapter = new NodeAdapter(); - - @Override - protected void onRangeChanged(HasData display) { - if (value instanceof Resource) { - Resource resource = (Resource) value; - if (!resource.isLoaded()) { - try { - resource.load(editingDomain.getResourceSet().getLoadOptions()); - } catch (IOException e) { - // Ignore. - } - } - } - update(); - } - - protected void update() { - Collection children = editor.getItemDelegator().getChildren(value); - ArrayList childrenList = new ArrayList(children); - nodeAdapter.listenTo(childrenList); - int size = children.size(); - if (this.size < size) { - updateRowCount(size, true); - this.size = size; - } else { - // Pad with dummy objects. - for (int i = size; i < this.size; ++i) { - childrenList.add(new Object()); - } - } - updateRowData(0, childrenList); - if (this.size > size) { - updateRowCount(size, true); - this.size = size; - } - } - }; - - return new DefaultNodeInfo(abstractListViewAdapter, new ModelViewerCell(editor.getItemDelegator()), treeSelection, null); - } - - public boolean isLeaf(Object value) { - return !editor.getItemDelegator().hasChildren(value); - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/ModelViewerCell.java b/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/ModelViewerCell.java deleted file mode 100644 index e17d4fe94..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.gwt/src/org/eclipse/emf/eef/runtime/ui/gwt/editor/widget/ModelViewerCell.java +++ /dev/null @@ -1,120 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.gwt.editor.widget; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator; -import org.eclipse.emf.edit.provider.ComposedImage; - -import com.google.gwt.cell.client.AbstractCell; -import com.google.gwt.resources.client.ImageResource; -import com.google.gwt.safehtml.shared.SafeHtmlBuilder; - -/** - * @author glefur - * - */ -public class ModelViewerCell extends AbstractCell { - - private AdapterFactoryItemDelegator itemDelegator; - - /** - * @param consumedEvents - * @param itemDelegator - */ - public ModelViewerCell(AdapterFactoryItemDelegator itemDelegator) { - this.itemDelegator = itemDelegator; - } - - @Override - public void render(Context context, Object value, SafeHtmlBuilder safeHtmlBuilder) { - StringBuilder sb = new StringBuilder(); - Object image = itemDelegator.getImage(value); - if (image instanceof ImageResource) { - ImageResource imageResource = (ImageResource) image; - sb.append("
"); - sb.append("
"); - sb.append(itemDelegator.getText(value)); - sb.append("
"); - } else if (image instanceof ComposedImage) { - ComposedImage composedImage = (ComposedImage) image; - List sizes = new ArrayList(); - List images = new ArrayList(composedImage.getImages()); - List nestedImagesData = new ArrayList(); - for (Object nestedImage : images) { - ImageData nestedImageData = getImageData(nestedImage); - ComposedImage.Size size = new ComposedImage.Size(); - size.height = nestedImageData.height; - size.width = nestedImageData.width; - sizes.add(size); - nestedImagesData.add(nestedImageData); - } - ComposedImage.Size size = composedImage.getSize(sizes); - sb.append("
"); - List drawPoints = composedImage.getDrawPoints(size); - int i = 0; - for (ComposedImage.Point drawPoint : drawPoints) { - ImageResource nestedImage = (ImageResource) images.get(i++); - sb.append("
"); - } - sb.append(itemDelegator.getText(value)); - sb.append("
"); - } else { - sb.append(itemDelegator.getText(value)); - } - safeHtmlBuilder.appendHtmlConstant(sb.toString()); - } - - protected ImageData getImageData(Object image) { - ImageData imageData = new ImageData(); - if (image instanceof ImageResource) { - ImageResource imageResource = (ImageResource) image; - imageData.height = imageResource.getHeight(); - imageData.width = imageResource.getWidth(); - } else if (image instanceof ComposedImage) { - ComposedImage composedImage = (ComposedImage) image; - List sizes = new ArrayList(); - List images = new ArrayList(composedImage.getImages()); - List nestedImagesData = new ArrayList(); - for (Object nestedImage : images) { - ImageData nestedImageData = getImageData(nestedImage); - ComposedImage.Size size = new ComposedImage.Size(); - size.height = nestedImageData.height; - size.width = nestedImageData.width; - sizes.add(size); - nestedImagesData.add(nestedImageData); - } - } - return imageData; - } - - public static class ImageData { - public int width; - public int height; - } - - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/.checkstyle b/plugins/org.eclipse.emf.eef.runtime.ui.widget/.checkstyle deleted file mode 100644 index 4ba2827a9..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/.checkstyle +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/.classpath b/plugins/org.eclipse.emf.eef.runtime.ui.widget/.classpath deleted file mode 100644 index 64c5e31b7..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/.gitignore b/plugins/org.eclipse.emf.eef.runtime.ui.widget/.gitignore deleted file mode 100644 index 5e56e040e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/bin diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/.project b/plugins/org.eclipse.emf.eef.runtime.ui.widget/.project deleted file mode 100644 index 73bf5e41c..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/.project +++ /dev/null @@ -1,34 +0,0 @@ - - - org.eclipse.emf.eef.runtime.ui.widget - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - org.eclipse.pde.api.tools.apiAnalysisBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - org.eclipse.pde.api.tools.apiAnalysisNature - - diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.runtime.ui.widget/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index af0f20f97..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,7 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.runtime.ui.widget/META-INF/MANIFEST.MF deleted file mode 100644 index 4eedd0a77..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/META-INF/MANIFEST.MF +++ /dev/null @@ -1,9 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Runtime Widget plugin -Bundle-SymbolicName: org.eclipse.emf.eef.runtime.ui.widget -Bundle-Version: 2.0.0.qualifier -Bundle-Vendor: Eclipse Modeling Project -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Require-Bundle: org.eclipse.emf.eef.runtime;bundle-version="2.0.0" -Import-Package: com.google.common.collect diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/build.properties b/plugins/org.eclipse.emf.eef.runtime.ui.widget/build.properties deleted file mode 100644 index fe82bc0a5..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/build.properties +++ /dev/null @@ -1,14 +0,0 @@ -############################################################################### -# Copyright (c) 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - . diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/EEFSelectionDialog.java b/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/EEFSelectionDialog.java deleted file mode 100644 index 411ec7e11..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/EEFSelectionDialog.java +++ /dev/null @@ -1,218 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.jface.dialogs.Dialog; -import org.eclipse.jface.viewers.IBaseLabelProvider; -import org.eclipse.jface.viewers.IContentProvider; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.TreeViewer; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Shell; - -import com.google.common.collect.Lists; - -/** - * @author Goulwen Le Fur - * - */ -public class EEFSelectionDialog extends Dialog { - - private String title; - private TreeViewer selectionViewer; - private boolean multi; - - private AdapterFactory adapterFactory; - private IContentProvider contentProvider; - private IBaseLabelProvider labelProvider; - private Object input; - private Object selection; - private Collection filters; - - /** - * @param parent - */ - public EEFSelectionDialog(Shell parent, boolean multi) { - super(parent); - this.multi = multi; - this.filters = Lists.newArrayList(); - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell) - */ - @Override - protected void configureShell(Shell newShell) { - super.configureShell(newShell); - if (title != null) { - newShell.setText(title); - } - //newShell.setSize(UIConstants.EEF_SELECTION_DIALOG_WIDTH, UIConstants.EEF_SELECTION_DIALOG_HEIGHT); - newShell.setSize(200, 200); - } - - /** - * @return the title - */ - public String getTitle() { - return title; - } - - /** - * @param title the title to set - */ - public void setTitle(String title) { - this.title = title; - } - - /** - * @param input the input to set - */ - public void setInput(Object input) { - this.input = input; - } - - /** - * @return the input - */ - public Object getInput() { - return input; - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.dialogs.Dialog#isResizable() - */ - protected boolean isResizable() { - return true; - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite) - */ - protected Control createDialogArea(Composite parent) { - Composite control = new Composite(parent, SWT.NONE); - control.setLayoutData(new GridData(GridData.FILL_BOTH)); - control.setLayout(new GridLayout()); - Label message = new Label(control, SWT.NONE); - message.setText("Select the element(s) to process:"); - int style = SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER; - if (multi) { - style |= SWT.MULTI; - } - selectionViewer = new TreeViewer(control, style); - selectionViewer.getControl().setLayoutData(new GridData(GridData.FILL_BOTH)); - - for (ViewerFilter filter : filters) { - selectionViewer.addFilter(filter); - } - - selectionViewer.setContentProvider(getContentProvider()); - selectionViewer.setLabelProvider(getLabelProvider()); - selectionViewer.setInput(input); - selectionViewer.addSelectionChangedListener(new ISelectionChangedListener() { - - - public void selectionChanged(SelectionChangedEvent event) { - StructuredSelection sSel = (StructuredSelection) selectionViewer.getSelection(); - if (sSel.size() == 0) { - EEFSelectionDialog.this.selection = null; - } else if (sSel.size() == 1) { - EEFSelectionDialog.this.selection = sSel.getFirstElement(); - } else { - EEFSelectionDialog.this.selection = sSel.toList(); - } - } - }); - - return control; - } - - /** - * @param adapterFactory the adapterFactory to set - */ - public void setAdapterFactory(AdapterFactory adapterFactory) { - this.adapterFactory = adapterFactory; - } - - /** - * @return the contentProvider - */ - public IContentProvider getContentProvider() { - if (contentProvider == null) { - if (adapterFactory == null) { - //adapterFactory = EEFRuntimeUI.getPlugin().getRegistryAdapterFactory(); - adapterFactory = EEFRuntimePlugin.getDefault().getAdapterFactory(); - } - contentProvider = new AdapterFactoryContentProvider(adapterFactory); - } - return contentProvider; - } - - /** - * @param contentProvider the contentProvider to set - */ - public void setContentProvider(IContentProvider contentProvider) { - this.contentProvider = contentProvider; - } - - /** - * @return the labelProvider - */ - public IBaseLabelProvider getLabelProvider() { - if (labelProvider == null) { - if (adapterFactory == null) { -// adapterFactory = EEFRuntimeUI.getPlugin().getRegistryAdapterFactory(); - adapterFactory = EEFRuntimePlugin.getDefault().getAdapterFactory(); - } - labelProvider = new AdapterFactoryLabelProvider(adapterFactory); - } - return labelProvider; - } - - /** - * @param labelProvider the labelProvider to set - */ - public void setLabelProvider(IBaseLabelProvider labelProvider) { - this.labelProvider = labelProvider; - } - - /** - * @return the selection - */ - public Object getSelection() { - return selection; - } - - /** - * @param choiceOfValuesFilter - */ - public void addFilter(ViewerFilter filter) { - this.filters.add(filter); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/EReferenceEditor.java b/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/EReferenceEditor.java deleted file mode 100644 index cb9226340..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/EReferenceEditor.java +++ /dev/null @@ -1,553 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets; - -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.List; - -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.jface.viewers.IBaseLabelProvider; -import org.eclipse.jface.viewers.IContentProvider; -import org.eclipse.jface.viewers.IDoubleClickListener; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.ISelectionChangedListener; -import org.eclipse.jface.viewers.IStructuredContentProvider; -import org.eclipse.jface.viewers.ITreeViewerListener; -import org.eclipse.jface.viewers.SelectionChangedEvent; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.jface.viewers.TreeViewer; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.jface.viewers.ViewerSorter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.dnd.DragSourceListener; -import org.eclipse.swt.dnd.DropTargetListener; -import org.eclipse.swt.dnd.Transfer; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Widget; - -import com.google.common.collect.Lists; - -/** - * @author Goulwen Le Fur - */ -public class EReferenceEditor extends StructuredViewer { - - private int lowerBound = 0; - private int upperBound = -1; - - private Composite control; - private TreeViewer tree; - private Collection listeners; - private Button addButton; - private Button removeButton; - private Button upButton; - private Button downButton; - - /** - * @param parent - * @param style - */ - public EReferenceEditor(Composite parent, int style) { - control = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(4, false); - layout.marginWidth = 0; - layout.marginHeight = 0; - control.setLayout(layout); - addButton = new Button(control, SWT.PUSH); - GridData addButtonData = new GridData(GridData.FILL_HORIZONTAL); - addButtonData.horizontalAlignment = SWT.RIGHT; - //addButton.setImage(EEFRuntimeUI.getPlugin().getRuntimeImage("Add")); - addButton.setImage(EEFRuntimePlugin.getImage("Add")); - addButton.setLayoutData(addButtonData); - addButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - for (ReferenceEditorListener listener : listeners) { - listener.add(); - } - } - - }); - - GridData buttonData = new GridData(); - buttonData.horizontalAlignment = SWT.RIGHT; - removeButton = new Button(control, SWT.PUSH); - //removeButton.setImage(EEFRuntimeUI.getPlugin().getRuntimeImage("Delete")); - removeButton.setImage(EEFRuntimePlugin.getImage("Delete")); - removeButton.setLayoutData(buttonData); - removeButton.addSelectionListener(new ReferenceEditorSelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.widgets.EReferenceEditor.ReferenceEditorSelectionAdapter#fireSingleSelection(java.lang.Object) - */ - public void fireSingleSelection(Object selection) { - for (ReferenceEditorListener listener : listeners) { - listener.remove(selection); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.widgets.EReferenceEditor.ReferenceEditorSelectionAdapter#fireMultiSelection(java.util.List) - */ - protected void fireMultiSelection(List selection) { - for (ReferenceEditorListener listener : listeners) { - listener.removeAll(selection); - } - } - - - }); - - upButton = new Button(control, SWT.PUSH); - //upButton.setImage(EEFRuntimeUI.getPlugin().getRuntimeImage("ArrowUp")); - upButton.setImage(EEFRuntimePlugin.getImage("ArrowUp")); - upButton.setLayoutData(buttonData); - upButton.addSelectionListener(new ReferenceEditorSelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.widgets.EReferenceEditor.ReferenceEditorSelectionAdapter#fireSingleSelection(java.lang.Object) - */ - public void fireSingleSelection(Object selection) { - for (ReferenceEditorListener listener : listeners) { - listener.moveUp(selection); - } - } - }); - - downButton = new Button(control, SWT.PUSH); - //downButton.setImage(EEFRuntimeUI.getPlugin().getRuntimeImage("ArrowDown")); - downButton.setImage(EEFRuntimePlugin.getImage("ArrowDown")); - downButton.setLayoutData(buttonData); - downButton.addSelectionListener(new ReferenceEditorSelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.widgets.EReferenceEditor.ReferenceEditorSelectionAdapter#fireSingleSelection(java.lang.Object) - */ - public void fireSingleSelection(Object selection) { - for (ReferenceEditorListener listener : listeners) { - listener.moveDown(selection); - } - } - }); - - tree = new TreeViewer(control, style); - GridData treeData = new GridData(GridData.FILL_BOTH); - treeData.horizontalSpan = 4; - tree.getControl().setLayoutData(treeData); - tree.addSelectionChangedListener(new ISelectionChangedListener() { - - public void selectionChanged(SelectionChangedEvent event) { - updateButtons(); - } - }); - listeners = Lists.newArrayList(); - } - - /** - * @param lowerBound the lowerBound to set - */ - public void setLowerBound(int lowerBound) { - this.lowerBound = lowerBound; - } - - /** - * @param upperBound the upperBound to set - */ - public void setUpperBound(int upperBound) { - this.upperBound = upperBound; - } - - /** - * Add a {@link ReferenceEditorListener} to this instance. - * @param listener {@link ReferenceEditorListener} to add. - */ - public void addReferenceEditorListener(ReferenceEditorListener listener) { - listeners.add(listener); - } - - /** - * Remove a {@link ReferenceEditorListener} to this instance. - * @param listener {@link ReferenceEditorListener} to remove. - */ - public void removeReferenceEditorListener(ReferenceEditorListener listener) { - listeners.remove(listener); - } - - /** - * @see org.eclipse.jface.viewers.ContentViewer#getContentProvider() - */ - public IContentProvider getContentProvider() { - return tree.getContentProvider(); - } - - /** - * @see org.eclipse.jface.viewers.ContentViewer#getInput() - */ - public Object getInput() { - return tree.getInput(); - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.Viewer#inputChanged(java.lang.Object, java.lang.Object) - */ - protected void inputChanged(Object input, Object oldInput) { - tree.setInput(input); - } - - /** - * @see org.eclipse.jface.viewers.TreeViewer#getLabelProvider() - */ - public IBaseLabelProvider getLabelProvider() { - return tree.getLabelProvider(); - } - - /** - * @see org.eclipse.jface.viewers.ColumnViewer#setLabelProvider(org.eclipse.jface.viewers.IBaseLabelProvider) - */ - public void setLabelProvider(IBaseLabelProvider labelProvider) { - tree.setLabelProvider(labelProvider); - } - - /** - * @see org.eclipse.jface.viewers.StructuredViewer#addDoubleClickListener(org.eclipse.jface.viewers.IDoubleClickListener) - */ - public void addDoubleClickListener(IDoubleClickListener listener) { - tree.addDoubleClickListener(listener); - } - - /** - * @see org.eclipse.jface.viewers.Viewer#setSelection(org.eclipse.jface.viewers.ISelection) - */ - public void setSelection(ISelection selection) { - tree.setSelection(selection); - } - - /** - * @see org.eclipse.jface.viewers.StructuredViewer#addDragSupport(int, org.eclipse.swt.dnd.Transfer[], org.eclipse.swt.dnd.DragSourceListener) - */ - public void addDragSupport(int operations, Transfer[] transferTypes, DragSourceListener listener) { - tree.addDragSupport(operations, transferTypes, listener); - } - - /** - * @see org.eclipse.jface.viewers.StructuredViewer#addDropSupport(int, org.eclipse.swt.dnd.Transfer[], org.eclipse.swt.dnd.DropTargetListener) - */ - public void addDropSupport(int operations, Transfer[] transferTypes, DropTargetListener listener) { - tree.addDropSupport(operations, transferTypes, listener); - } - - /** - * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(org.eclipse.jface.viewers.ViewerFilter) - */ - public void addFilter(ViewerFilter filter) { - tree.addFilter(filter); - } - - /** - * @see org.eclipse.jface.viewers.StructuredViewer#getFilters() - */ - public ViewerFilter[] getFilters() { - return tree.getFilters(); - } - - /** - * @see org.eclipse.jface.viewers.TreeViewer#setContentProvider(org.eclipse.jface.viewers.IContentProvider) - */ - public void setContentProvider(IContentProvider provider) { - //super.setContentProvider(new NullContentProvider()); - tree.setContentProvider(provider); - } - - /** - * @see org.eclipse.jface.viewers.StructuredViewer#getSorter() - */ - public ViewerSorter getSorter() { - return tree.getSorter(); - } - - /** - * @see org.eclipse.jface.viewers.TreeViewer#setSelection(org.eclipse.jface.viewers.ISelection, boolean) - */ - public void setSelection(ISelection selection, boolean reveal) { - tree.setSelection(selection, reveal); - } - - /** - * @see org.eclipse.jface.viewers.StructuredViewer#setFilters(org.eclipse.jface.viewers.ViewerFilter[]) - */ - public void setFilters(ViewerFilter[] filters) { - tree.setFilters(filters); - } - - /** - * @param listener - * @see org.eclipse.jface.viewers.Viewer#addSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener) - */ - public void addSelectionChangedListener(ISelectionChangedListener listener) { - tree.addSelectionChangedListener(listener); - } - - /** - * @param listener - * @see org.eclipse.jface.viewers.StructuredViewer#addPostSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener) - */ - public void addPostSelectionChangedListener(ISelectionChangedListener listener) { - tree.addPostSelectionChangedListener(listener); - } - - /** - * @param listener - * @see org.eclipse.jface.viewers.AbstractTreeViewer#addTreeListener(org.eclipse.jface.viewers.ITreeViewerListener) - */ - public void addTreeListener(ITreeViewerListener listener) { - tree.addTreeListener(listener); - } - - /** - * @param layoutData - * @see org.eclipse.swt.widgets.Control#setLayoutData(java.lang.Object) - */ - public void setLayoutData(Object layoutData) { - control.setLayoutData(layoutData); - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.StructuredViewer#doFindInputItem(java.lang.Object) - */ - @Override - protected Widget doFindInputItem(Object element) { - //TODO - return null; - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.StructuredViewer#doFindItem(java.lang.Object) - */ - @Override - protected Widget doFindItem(Object element) { - //TODO - return null; - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.StructuredViewer#doUpdateItem(org.eclipse.swt.widgets.Widget, java.lang.Object, boolean) - */ - @Override - protected void doUpdateItem(Widget item, Object element, boolean fullMap) { - //TODO - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.StructuredViewer#getSelectionFromWidget() - */ - @Override - protected List getSelectionFromWidget() { - ISelection selection = tree.getSelection(); - if (selection instanceof StructuredSelection) { - return ((StructuredSelection) selection).toList(); - } else { - if (selection != null) { - if (selection.isEmpty()) { - return Collections.EMPTY_LIST; - } else { - return Lists.newArrayList(selection); - } - } - } - return Collections.emptyList(); - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.StructuredViewer#internalRefresh(java.lang.Object) - */ - @Override - protected void internalRefresh(Object element) { - tree.refresh(); - updateButtons(); - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.StructuredViewer#reveal(java.lang.Object) - */ - @Override - public void reveal(Object element) { - tree.reveal(element); - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.StructuredViewer#setSelectionToWidget(java.util.List, boolean) - */ - @Override - protected void setSelectionToWidget(@SuppressWarnings("rawtypes") List elements, boolean reveal) { - StructuredSelection selection = new StructuredSelection(elements); - tree.setSelection(selection, reveal); - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.Viewer#getControl() - */ - @Override - public Control getControl() { - return control; - } - - /** - * Update the list buttons. - */ - protected void updateButtons() { - StructuredSelection selection = (StructuredSelection) tree.getSelection(); - addButton.setEnabled(shouldEnableAdd(selection)); - if (selection.size() == 0) { - removeButton.setEnabled(false); - upButton.setEnabled(false); - downButton.setEnabled(false); - } else if (selection.size() == 1) { - removeButton.setEnabled(shouldEnableRemove(selection)); - upButton.setEnabled(shouldEnableUp(selection)); - downButton.setEnabled(shouldEnableDown(selection)); - } else { - removeButton.setEnabled(shouldEnableRemove(selection)); - upButton.setEnabled(false); - downButton.setEnabled(false); - } - } - - private boolean shouldEnableAdd(StructuredSelection selection) { - Object[] elements = ((IStructuredContentProvider)tree.getContentProvider()).getElements(tree.getInput()); - return ((upperBound == -1) || (elements.length < upperBound)); - } - - private boolean shouldEnableRemove(StructuredSelection selection) { - Object[] elements = ((IStructuredContentProvider)tree.getContentProvider()).getElements(tree.getInput()); - return ((lowerBound == 0) || (elements.length > lowerBound)); - } - - private boolean shouldEnableUp(StructuredSelection selection) { - Object selectedElement = selection.getFirstElement(); - Object[] elements = ((IStructuredContentProvider)tree.getContentProvider()).getElements(tree.getInput()); - if (elements != null) { - List listInput = Arrays.asList(elements); - return listInput.size() > 1 && listInput.indexOf(selectedElement) > 0; - } - return false; - } - - private boolean shouldEnableDown(StructuredSelection selection) { - Object selectedElement = selection.getFirstElement(); - Object[] elements = ((IStructuredContentProvider)tree.getContentProvider()).getElements(tree.getInput()); - if (elements != null) { - List listInput = Arrays.asList(elements); - return (listInput.size() > 1) && (listInput.indexOf(selectedElement) < listInput.size() - 1); - } - return false; - } - - /** - * @author Goulwen Le Fur - * - */ - public interface ReferenceEditorListener { - - /** - * Handle a "add" request. - */ - void add(); - - /** - * Handle a "edit" request. - * @param editedElement Edited Element. - */ - void edit(Object editedElement); - - /** - * Handle a "remove" request. - * @param removedElement Removed Element. - */ - void remove(Object removedElement); - - /** - * Handle a "remove" request for several elements. - * @param removedElements Removed Elements. - */ - void removeAll(Collection removedElements); - - /** - * Handle a "move up" request. - * @param movedElement Moved Element. - */ - void moveUp(Object movedElement); - - /** - * Handle a "move down" request. - * @param movedElement Moved Element. - */ - void moveDown(Object movedElement); - - } - - /** - * @author Goulwen Le Fur - * - */ - private abstract class ReferenceEditorSelectionAdapter extends SelectionAdapter { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - if (tree.getSelection() != null && !tree.getSelection().isEmpty()) { - if (tree.getSelection() instanceof StructuredSelection) { - StructuredSelection sSel = (StructuredSelection) tree.getSelection(); - if (sSel.size() == 1) { - fireSingleSelection(sSel.getFirstElement()); - } else { - fireMultiSelection((List) sSel.toList()); - } - - } - } - } - - public abstract void fireSingleSelection(Object selection); - - protected void fireMultiSelection(List selection) { - //do nothing - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/ArrayFeatureContentProvider.java b/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/ArrayFeatureContentProvider.java deleted file mode 100644 index 103bc8bc7..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/ArrayFeatureContentProvider.java +++ /dev/null @@ -1,84 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.util; - -import java.util.Collection; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jface.viewers.IStructuredContentProvider; -import org.eclipse.jface.viewers.ITreeContentProvider; -import org.eclipse.jface.viewers.Viewer; - -/** - * @author Goulwen Le Fur - * - */ -public class ArrayFeatureContentProvider implements IStructuredContentProvider, ITreeContentProvider { - - private EStructuralFeature feature; - - /** - * @param feature - */ - public ArrayFeatureContentProvider(EStructuralFeature feature) { - assert feature != null && feature.isMany():"The feature can't be null and must be many"; - this.feature = feature; - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.IContentProvider#dispose() - */ - public void dispose() {} - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public void inputChanged(Viewer viewer, Object oldInput, Object newInput) { } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.IStructuredContentProvider#getElements(java.lang.Object) - */ - public Object[] getElements(Object inputElement) { - if (inputElement instanceof EObject && feature.eContainer().equals(((EObject)inputElement).eClass())) { - return ((Collection)((EObject)inputElement).eGet(feature)).toArray(); - } - return new Object[0]; - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.ITreeContentProvider#getChildren(java.lang.Object) - */ - public Object[] getChildren(Object parentElement) { - return null; - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.ITreeContentProvider#getParent(java.lang.Object) - */ - public Object getParent(Object element) { - return null; - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.ITreeContentProvider#hasChildren(java.lang.Object) - */ - public boolean hasChildren(Object element) { - return false; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/ChoiceOfValuesFilter.java b/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/ChoiceOfValuesFilter.java deleted file mode 100644 index d3fe891c3..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/ChoiceOfValuesFilter.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.util; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - -import com.google.common.collect.Lists; - -/** - * @author Goulwen Le Fur - * - */ -public class ChoiceOfValuesFilter extends ViewerFilter { - - private final AdapterFactory adapterFactory; - private final EObject editedElement; - private final EStructuralFeature feature; - private final SelectionMode mode; - - private Collection choiceOfValues; - private Collection intermediateChoices; - - - - /** - * @param adapterFactory {@link AdapterFactory} to use for the choice of value. - * @param editedElement {@link EObject} to edit. - * @param feature edited {@link EStructuralFeature}. - */ - public ChoiceOfValuesFilter(AdapterFactory adapterFactory, EObject editedElement, EStructuralFeature feature, SelectionMode mode) { - this.adapterFactory = adapterFactory; - this.editedElement = editedElement; - this.feature = feature; - this.mode = mode; - IItemPropertySource propertySource = (IItemPropertySource) this.adapterFactory.adapt(this.editedElement, IItemPropertySource.class); - if (propertySource != null) { - IItemPropertyDescriptor descriptor = propertySource.getPropertyDescriptor(this.editedElement, this.feature); - choiceOfValues = descriptor.getChoiceOfValues(this.editedElement); - intermediateChoices = Lists.newArrayList(); - for (Object object : choiceOfValues) { - if (object instanceof EObject) { - populateIntermediateChoices(intermediateChoices, (EObject)object); - } - } - } - } - - private void populateIntermediateChoices(Collection intermediateChoices, EObject object) { - EObject container = object.eContainer(); - while (container != null) { - intermediateChoices.add(container); - container = container.eContainer(); - } - if (object.eResource() != null) { - intermediateChoices.add(object.eResource()); - } - } - - /** - * {@inheritDoc} - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - return choiceOfValues.contains(element) - || ((mode == SelectionMode.TREE) && (intermediateChoices.contains(element))); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/EEFOverrideViewer.java b/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/EEFOverrideViewer.java deleted file mode 100644 index c3d8ffa3e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/EEFOverrideViewer.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.util; - -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.swt.widgets.Control; - -public class EEFOverrideViewer extends Viewer { - - @Override - public Control getControl() { - // TODO Auto-generated method stub - return null; - } - - @Override - public Object getInput() { - // TODO Auto-generated method stub - return null; - } - - @Override - public ISelection getSelection() { - // TODO Auto-generated method stub - return null; - } - - @Override - public void refresh() { - // TODO Auto-generated method stub - - } - - @Override - public void setInput(Object input) { - // TODO Auto-generated method stub - - } - - @Override - public void setSelection(ISelection selection, boolean reveal) { - // TODO Auto-generated method stub - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/SelectionMode.java b/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/SelectionMode.java deleted file mode 100644 index f17d12415..000000000 --- a/plugins/org.eclipse.emf.eef.runtime.ui.widget/src/org/eclipse/emf/eef/runtime/ui/widgets/util/SelectionMode.java +++ /dev/null @@ -1,20 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets.util; - -/** - * @author Goulwen Le Fur - * - */ -public enum SelectionMode { - TREE, - FLAT -} diff --git a/plugins/org.eclipse.emf.eef.runtime/.checkstyle b/plugins/org.eclipse.emf.eef.runtime/.checkstyle deleted file mode 100644 index 7124c8710..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/.checkstyle +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime/.classpath b/plugins/org.eclipse.emf.eef.runtime/.classpath deleted file mode 100644 index 5e4c1fe99..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime/.gitignore b/plugins/org.eclipse.emf.eef.runtime/.gitignore deleted file mode 100644 index d44cd35e0..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target -bin diff --git a/plugins/org.eclipse.emf.eef.runtime/.project b/plugins/org.eclipse.emf.eef.runtime/.project deleted file mode 100644 index 23efd3d41..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - org.eclipse.emf.eef.runtime - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/plugins/org.eclipse.emf.eef.runtime/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.eef.runtime/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index aebbb3c38..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,12 +0,0 @@ -#Fri Oct 01 15:11:45 CEST 2010 -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 -org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve -org.eclipse.jdt.core.compiler.compliance=1.5 -org.eclipse.jdt.core.compiler.debug.lineNumber=generate -org.eclipse.jdt.core.compiler.debug.localVariable=generate -org.eclipse.jdt.core.compiler.debug.sourceFile=generate -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.5 diff --git a/plugins/org.eclipse.emf.eef.runtime/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.runtime/META-INF/MANIFEST.MF deleted file mode 100644 index fbef857ef..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/META-INF/MANIFEST.MF +++ /dev/null @@ -1,65 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: EEF Runtime Plug-in -Bundle-SymbolicName: org.eclipse.emf.eef.runtime;singleton:=true -Bundle-Version: 1.5.2.qualifier -Bundle-Activator: org.eclipse.emf.eef.runtime.EEFRuntimePlugin -Bundle-Vendor: Eclipse Modeling Project -Require-Bundle: org.eclipse.ui;bundle-version="3.3.0", - org.eclipse.core.runtime;bundle-version="3.3.0", - org.eclipse.core.resources;bundle-version="3.3.0", - org.eclipse.jface.databinding;bundle-version="1.1.0";visibility:=reexport, - org.eclipse.emf.ecore;bundle-version="2.3.0", - org.eclipse.emf.ecore.xmi;bundle-version="2.3.0", - org.eclipse.emf.edit;bundle-version="2.3.0", - org.eclipse.emf.edit.ui;bundle-version="2.3.0";visibility:=reexport, - org.eclipse.emf.validation;bundle-version="1.1.0", - org.eclipse.ui.views.properties.tabbed;bundle-version="3.3.0";visibility:=reexport, - org.eclipse.ui.ide;bundle-version="3.3.0";resolution:=optional, - org.eclipse.jdt.core;bundle-version="3.3.0";resolution:=optional, - org.eclipse.emf.workspace;bundle-version="1.1.0";resolution:=optional, - org.eclipse.jface.text;bundle-version="3.3.0" -Bundle-ActivationPolicy: lazy -Export-Package: org.eclipse.emf.eef.runtime, - org.eclipse.emf.eef.runtime.api.adapters, - org.eclipse.emf.eef.runtime.api.component, - org.eclipse.emf.eef.runtime.api.context, - org.eclipse.emf.eef.runtime.api.notify, - org.eclipse.emf.eef.runtime.api.parts, - org.eclipse.emf.eef.runtime.api.providers, - org.eclipse.emf.eef.runtime.context, - org.eclipse.emf.eef.runtime.context.impl, - org.eclipse.emf.eef.runtime.impl.command, - org.eclipse.emf.eef.runtime.impl.components, - org.eclipse.emf.eef.runtime.impl.filters, - org.eclipse.emf.eef.runtime.impl.filters.business, - org.eclipse.emf.eef.runtime.impl.notify, - org.eclipse.emf.eef.runtime.impl.operation, - org.eclipse.emf.eef.runtime.impl.parts, - org.eclipse.emf.eef.runtime.impl.providers, - org.eclipse.emf.eef.runtime.impl.services, - org.eclipse.emf.eef.runtime.impl.utils, - org.eclipse.emf.eef.runtime.impl.validation, - org.eclipse.emf.eef.runtime.part.impl, - org.eclipse.emf.eef.runtime.policies, - org.eclipse.emf.eef.runtime.policies.impl, - org.eclipse.emf.eef.runtime.providers, - org.eclipse.emf.eef.runtime.providers.impl, - org.eclipse.emf.eef.runtime.ui, - org.eclipse.emf.eef.runtime.ui.adapters;version="1.5.1", - org.eclipse.emf.eef.runtime.ui.comparator, - org.eclipse.emf.eef.runtime.ui.notify, - org.eclipse.emf.eef.runtime.ui.parts, - org.eclipse.emf.eef.runtime.ui.parts.sequence, - org.eclipse.emf.eef.runtime.ui.properties.sections, - org.eclipse.emf.eef.runtime.ui.providers, - org.eclipse.emf.eef.runtime.ui.utils, - org.eclipse.emf.eef.runtime.ui.viewers, - org.eclipse.emf.eef.runtime.ui.viewers.filters, - org.eclipse.emf.eef.runtime.ui.widgets, - org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo, - org.eclipse.emf.eef.runtime.ui.widgets.imageviewer, - org.eclipse.emf.eef.runtime.ui.widgets.referencestable, - org.eclipse.emf.eef.runtime.ui.widgets.settings, - org.eclipse.emf.eef.runtime.ui.wizards -Bundle-RequiredExecutionEnvironment: J2SE-1.5 diff --git a/plugins/org.eclipse.emf.eef.runtime/about.html b/plugins/org.eclipse.emf.eef.runtime/about.html deleted file mode 100644 index f3a55ce5f..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/about.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - -About - - -

About This Content

- -

June 15, 2010

-

License

- -

The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at http://www.eclipse.org/legal/epl-v10.html. -For purposes of the EPL, "Program" will mean the Content.

- -

If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at http://www.eclipse.org.

- - - \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.runtime/build.properties b/plugins/org.eclipse.emf.eef.runtime/build.properties deleted file mode 100644 index 4a374d74b..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/build.properties +++ /dev/null @@ -1,22 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2012 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - plugin.xml,\ - schema/,\ - icons/,\ - .,\ - about.html -src.includes = about.html,\ - pom.xml,\ - schema/ - diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/Add_16x16.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/Add_16x16.gif deleted file mode 100644 index 252d7ebcb8c74d6e5de66ef0eb8856622a0e9d89..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 318 zcmZ?wbhEHb6krfwxXQp_S{7na6>d=(Ze15;Qy1mX8t2lT^ zHOHgY9FJamJZkN+sI|wVk6ueSb}ixP)r4bLfn?%^+sU^crQUj&`rv8W|Ns9PC;*B- zSr{1@v>9|jW`O*}z!rUAYJrE2RKG`JYNRKhwpQrnor{(Ph`sVEnyR2Kc;c~(o$WdP zMb0Wl6K^dQ-0hgs;s)RRH2yZMG-dG{LyHRvkqv*C;prFW}Cb1QH0&9u|R~HDbFBMu_B(%Cf zXj8fH`cmQLIReYF1^)m4&p+|z+lLr1JVKV69Zf3ff)rJI#S8AmOS&g!objY zXp*F{?P9eo9}@`oK{Iw9&}i^SBU4D}c3FLN?5SiQ`V!5RSYo{04T diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/ArrowLeft_16x16.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/ArrowLeft_16x16.gif deleted file mode 100644 index 4fb41501036b940c99c8a839d7459c88eb98385c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 327 zcmZ?wbhEHb6krfwxXQrr@9+D+zn}g6e)He2XMaAO`UhluzxDUq&A;Dn{du|K&)c1U zKb`yw6#sVf_k*54PiFppGV{-i6@Ol={QGw2@4L-^fP#-_?rjlUS1PoI4}+ox2M@c;!iyI;EP0M4 zDfSD$=;@GFSru%pQBc diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/ArrowRight_16x16.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/ArrowRight_16x16.gif deleted file mode 100644 index 19567890aa88ad1da1a5828bdf726d9c4bd66278..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 541 zcmZ?wbhEHb6krfwc*el+|No``{~!GS|NQ^|7ytji`~Uy_|NkHU|Nr#=|F{4DfBygf z=l`FB|9_wP|8>^?Z@d2gy8i#qv;QCF{Qofb|Ceq5zwZ41>)!w05C4By@&D77|DU)1 z|9be}w+sJ&T>1ZI;s1Aw|9{x{|MS7WpHKb&cK-jj3;*7%{{L?M-*>zIf86`;!`{E| z_x$^O=HHjI|G%F9|7Pt!p!oYeyXtv&HwtbpVc1y2u)cs{OBv&)62@(1Oq)uWmSr(* zE@j?S#=fRo zT#&>vKapioD(9j!?j;$#^J0Kr1_6e_0Th3-FfuR%G3bDt1Bw#{_Ns=UrskH`w)Tz| zLxav%yFl~aX4Akxqc$5W3kx%2drpo(;}&Z!c2+hP7G^O~0d|vSH%1vHX=NR4Ek$j9 zCfg=U9tCxcWBO`(nod*`SKk--`OT*-X9 diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/Create_16x16.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/Create_16x16.gif deleted file mode 100644 index cb415064e026e17ab2b67610add4b665fbe48f65..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 124 zcmZ?wbhEHb6krfw*v!DN^3?Rc9imd};Y ztdrJZ^8f#T1~5?k$->CMz{{Wm;(^RyVA0%g(sT7*i`Qp&pKnz1V0QL!2=eJl^58D^ Y@R;QD@Wzz%$?N7XDDb%B!oXk+04^vkg8%>k diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/Delete_16x16.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/Delete_16x16.gif deleted file mode 100644 index b6922ac11cf64e16a15cf2976cdaa1e40118abed..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 351 zcmZ?wbhEHb6krfwxXQqA+}QL>Vab=`lFvmYpNmUxXz4%DF}bf}d|cDunVH>FGrOY- z+D{EEKZPcINzVS9ob?$uHn=&y~n$8D`1 z2l;<(sQc1T_xQ+>|Ns9p5DgT6vM@3*7&7R9bb$QCz*ci$MuCTpRKNR-^bncK1eb^v zqDfrti^MpzbSB1VUt0b}aql73M;xvKD|}WtK1fk5iV!?;_@hVR1O_f%UNKGv4?_+f zX(=fl4i6boi78XK>s@7pr?3jKN=S;#aFP{YATA>-vrJN4*4aRuZH4n{cJUaejf8dYK!wBBy9aOw^8;pdHq$o3r)z-~WyK-gX^+H|^BNr5C?!x%K1Fqu&=^ z{r&#u|L5QT-~al5_4EJNKmWh`_5bD1|8IW%fB*ac=Rf~{|NH;z-~Y4c&t@msbr%~q z=b2V#S`?>Pr^VPOMmkQb)SpylFsaP2r`V_^&$K4f;{X5u47h>fPZmZ71~Ud7kP?ue z7}zQtX8ST#8i;VVEL6zh;uby4I{9MG48MgcP8k+z-OOg(zh|76j|h|a-Eptr=B;H# z?C;*+ob!#5m4#7RS-V(AUap)`QN^@aS6)?>aiXk7r=O<0j7(=|gP)$fnh2wax(M@h eU;Q-^f78}2yEi#9SOWlu>Xowq diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/Switch_Visibility.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/Switch_Visibility.gif deleted file mode 100644 index 6e19538d5e558e25cb7edc230f6b97d49d7753c4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 973 zcmYjQe@GK?6o0p-o=Q5$#4}2_5?mk=QgHqtS6ey7LW@$=NJX0ywV|txJapPrD9D*V zqJl8+k8B7d5^VmnWQIt@pwv8|%gwvMXH?2S z20xNuXwZgzrts(tV<8!BbWNdONurj+IT;2}u1cP5cy_k4&f6f2$ zr?++E`*fdB+~0P6puM8cTGV6Y9~$|d`ZErb)?v~;GUxXgGv;U9LD2vdpgtWB!<%w2 zNarnqZ8>nO4uOy86$p@y(HY(=ETe;H8sNM1Fdc^XQyh$M$)N~yYlH$CFsktxi(Wp# zK{Ddw(52|=!5pwM3g8h>@BO9TA{m-O`LAybHf`mD%|7xSI)GROl4!tibfXLWfwSVB&k)r34WEA?NM*emp* z+dPj26GoaxgEhntzTLJDRD%tw_x5B(4Al~rb}7NQzn6t^4yHW}u*hNFo58$SyI;3# z%_i0(3=EhL`#)O%m8oCS6(go;42X07n~U~U441(bl*9Uydx8mTsUPAfFV>1!;!43< zCAue7{joKFiqV&C%(UE@Vr=D>+e@ilWCi$z9_XAerCpKHxv05utE%pV!KfsJ587x( zKkjc6bx-{c?Qadw25Hh6iG3QHgGHPY^Uxe3-T#a3iw+u*`HEijX#mUIH{%d-_>s3T#k*Z*{ZtUFLX!()GX?J^FNo?XF^=!qUvpa@6 a%)5MZ4NOczplhsjNYm|ZdA53xg{;3Vcu~Fp diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/ValidationErrors.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/ValidationErrors.gif deleted file mode 100644 index 9b048d60532c805102fb835e8b808b6ffab9eb3f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 353 zcmZ?wbhEHb6krfwxXQrrHNWU&+b%ltZ`Yw@A<{iLE#Es0saCN{wV^@&N+MqoU=Lk%4bN3s&FkWVC9j>%9h|}XJKSv bTe;d-LWoy{S7?<_wwK4gLx&GJGFSruf?#b8 diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/ValidationWarnings.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/ValidationWarnings.gif deleted file mode 100644 index e8d763d147824d86627f5709d46deaf0b299ad64..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 326 zcmZ?wbhEHb6krfwxXQrr|JC;Yuebkyckutmv;RL|`G0@L|EDYdKVA9%<+lGXxBq{8 z`2UBq|4+vMKLtdI|4%3WKb7?VZ07%4{r_)G{C|7e|2xzE-<|dU-rVXy;f7Grrf{*w zP_fQviS}rTo;ax~DY8eKb&t2|9c$G;*=}&6-QaYm(YYRzi+$!-CR$#fVtsvz&8_Kn zH>cU%o#}9ArsIP-&i7_Jo$EHeGQsly|Njg`0L7myj0_CM3_2jSAU`p%B_Ehs;GrYc zf8ycmsVav!SR#s_DRHp0giSK#NHAzP`f5gy1mFE;$Awy_gjy@yg!L5yj!a&1@Ogz4 x53i8AtC}#MK&Jq|u%WxEh@h;zps1>+vY522m`bpsxVTcVlY+vM6)PPXtN~eZh|2%~ diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/disabled/th_horizontal.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/disabled/th_horizontal.gif deleted file mode 100644 index ce1a29cab8d4e5e7507778224d4008f1e60b3d63..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 354 zcmZ?wbhEHb6krfwxXQqA;NX#W?>`aw*Y6)ce;qz@ z^uw30KY#!J@$1*0zkh%K`E&Tlky97W&0Dqj%FS#0j_x~g;>d{;M~@#rdhFQIQzws{ zI(hWui6dwC@4a>Y-2JOp4jnvr?AWpY|Nk@43@H9&VPs%XWY7WG0P+(9Tm69v1s*zl z_9vDYRmND%ow@w;=G?SrE7AK%h$DkF000h%4gdfE diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/disabled/th_vertical.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/disabled/th_vertical.gif deleted file mode 100644 index a404f8d3eadabc75006ab3d5b6d6a72acd5257d1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 221 zcmZ?wbhEHb6krfwIKsfNYtO+W$4=e6b!YRo-RCY`{`u?okDtFjeEItG_wPS{|Nj2- zXWpvCS8iV0cXZ#eV@J>K-+Sx)x%*eI96EUL|Ns9CL;%H~EQ|~c!VEefwIDkgSfd`O z^rdKeWvp7ZxMWX3jmO)AIz0>Dv(?IVA3J2gz{1fK_x6~B0+-+N{6|3%>u;>oKKQn3 vYu|>7Hy2KwOPd$gWIOe*K>@f6>R^|G)nE|K`{Kx4-^>`2GLOpZ~9a{eSoS|NGznKmYmv{qO&`zyE&% z3Idh={XhBWCi58yE6#1N*-<-h(Y!@VXRlZ>eeLQg8`n+Tx}k6H*3O-qdiHPYcsFnI zgY3B16Wjj(|Ia`cQ2fcl$iSe>paaqk@)HBwT diff --git a/plugins/org.eclipse.emf.eef.runtime/icons/16x16/th_vertical.gif b/plugins/org.eclipse.emf.eef.runtime/icons/16x16/th_vertical.gif deleted file mode 100644 index 50a54e0b4a7646c58f90c6a577a46e93dc7758ea..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 352 zcmZ?wbhEHb6krfwxXQq=W%tF-8N27NKAv8?vZP}}+mv-3Q`huNU)4Wr#gsWq-~al5 z_4EH3^A~;n^Z&=+|6l(6fBozK```b~XC$mRx4mXZ?Yu?v7A>8WqPZmZ721N!PkPRR|F|gGhm{8!M!)1M9 ziIL?Uop~2tBpE-^QJch>a=NvkZB}cGQX>xsBO}8i$+UGhJzNy0r?<^G`uO6F-`^#i z#ku)f+uFsQ#kzZXdz?jsCW$)paL3LN;Bn^UR#1?iDZuH>F;7ljFg=q&ki(gsTYhtW X9lJAIOZ#p%XV(1(4jyoFWUvMRLN<)70gTKs4C1cL;$950eynn#jFRyJ z95oD5iM%ptobs9M!U+PRxk8fJf-;p1Dv@mJ32b^<9L8y!w&grh{S3x4xO5gUn5<;5 zU&~>*ozr*^gY6-9yR!@)JK00`Nk#3mkJ|0!e45Gk8f(ZonWz(@0av+0Zt_H2mxwv9 z8F|!u^;RC&rhej3W9Exr^)?SXSzZFsc zAgt?Na`)Y=uKU@u@1=J?_v?7+HT7xOq$fG^-li;npSS!|{?u#z)9*CQxZgDQe$%{r zo%8PWthzsU@sp0_k7uuYIB(<2#%<4+?Rc_v-;*7u|IIu1cm9!Qdk(zZefI5~iM6|vnMu(>fy1#wR4dTSgoE?x$rJSgbsmL>SlZec{%h1!TvX<0;kD^w z`1r7?nW2%zs)1vo6C0njNz|GT1`P>Kg6b{{IurOh$B*|-6LmthE{M)xWNO>nz%0ze!C(yla;&-s diff --git a/plugins/org.eclipse.emf.eef.runtime/plugin.xml b/plugins/org.eclipse.emf.eef.runtime/plugin.xml deleted file mode 100644 index bf0746b5a..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/plugin.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime/pom.xml b/plugins/org.eclipse.emf.eef.runtime/pom.xml deleted file mode 100644 index 905242c8c..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/pom.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - 4.0.0 - - - org.eclipse.emf - org.eclipse.emf.eef.releng.parent - ../../releng/org.eclipse.emf.eef.releng.parent - 1.5.2-SNAPSHOT - - - org.eclipse.emf.eef.runtime - eclipse-plugin - - EEF Runtime Plug-in - - diff --git a/plugins/org.eclipse.emf.eef.runtime/schema/LockPolicyProvider.exsd b/plugins/org.eclipse.emf.eef.runtime/schema/LockPolicyProvider.exsd deleted file mode 100644 index 634a1d0d8..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/schema/LockPolicyProvider.exsd +++ /dev/null @@ -1,102 +0,0 @@ - - - - - - - - - Declare a EEF Lock Policy Provider - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [Enter the first release in which this extension point appears.] - - - - - - - - - [Enter extension point usage example here.] - - - - - - - - - [Enter API information here.] - - - - - - - - - [Enter information about supplied implementation of this extension point.] - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionComponentListenerProvider.exsd b/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionComponentListenerProvider.exsd deleted file mode 100644 index 8cc6a7193..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionComponentListenerProvider.exsd +++ /dev/null @@ -1,102 +0,0 @@ - - - - - - - - - Declare a EEF PropertiesEditionComponent Listener Provider - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [Enter the first release in which this extension point appears.] - - - - - - - - - [Enter extension point usage example here.] - - - - - - - - - [Enter API information here.] - - - - - - - - - [Enter information about supplied implementation of this extension point.] - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionPartProvider.exsd b/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionPartProvider.exsd deleted file mode 100644 index fc60b45af..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionPartProvider.exsd +++ /dev/null @@ -1,102 +0,0 @@ - - - - - - - - - Declare a EEF Part Provider - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [Enter the first release in which this extension point appears.] - - - - - - - - - [Enter extension point usage example here.] - - - - - - - - - [Enter API information here.] - - - - - - - - - [Enter information about supplied implementation of this extension point.] - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionPolicyProvider.exsd b/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionPolicyProvider.exsd deleted file mode 100644 index f0106e2e4..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionPolicyProvider.exsd +++ /dev/null @@ -1,102 +0,0 @@ - - - - - - - - - Declare a EEF Edit Policy Provider - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [Enter the first release in which this extension point appears.] - - - - - - - - - [Enter extension point usage example here.] - - - - - - - - - [Enter API information here.] - - - - - - - - - [Enter information about supplied implementation of this extension point.] - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionProvider.exsd b/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionProvider.exsd deleted file mode 100644 index a7df4bb15..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/schema/PropertiesEditionProvider.exsd +++ /dev/null @@ -1,105 +0,0 @@ - - - - - - - - - Declare a EEF Component Provider - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [Enter the first release in which this extension point appears.] - - - - - - - - - [Enter extension point usage example here.] - - - - - - - - - [Enter API information here.] - - - - - - - - - [Enter information about supplied implementation of this extension point.] - - - - - - - - - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime/schema/ReadOnlyPolicyProvider.exsd b/plugins/org.eclipse.emf.eef.runtime/schema/ReadOnlyPolicyProvider.exsd deleted file mode 100644 index 62853de5b..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/schema/ReadOnlyPolicyProvider.exsd +++ /dev/null @@ -1,102 +0,0 @@ - - - - - - - - - Declare a EEF Read Only Policy Provider - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [Enter the first release in which this extension point appears.] - - - - - - - - - [Enter extension point usage example here.] - - - - - - - - - [Enter API information here.] - - - - - - - - - [Enter information about supplied implementation of this extension point.] - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime/schema/WizardOpeningPolicyProvider.exsd b/plugins/org.eclipse.emf.eef.runtime/schema/WizardOpeningPolicyProvider.exsd deleted file mode 100644 index 249e621b0..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/schema/WizardOpeningPolicyProvider.exsd +++ /dev/null @@ -1,102 +0,0 @@ - - - - - - - - - Declare a EEF Opening Wizard Policy Provider - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [Enter the first release in which this extension point appears.] - - - - - - - - - [Enter extension point usage example here.] - - - - - - - - - [Enter API information here.] - - - - - - - - - [Enter information about supplied implementation of this extension point.] - - - - - diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/EEFRuntimePlugin.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/EEFRuntimePlugin.java deleted file mode 100644 index de0197098..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/EEFRuntimePlugin.java +++ /dev/null @@ -1,188 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime; - -import java.util.Map; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.util.Diagnostician; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.jface.resource.ImageDescriptor; -import org.eclipse.jface.resource.ImageRegistry; -import org.eclipse.swt.graphics.Image; -import org.eclipse.ui.plugin.AbstractUIPlugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle. - * - * @author Goulwen Le Fur - */ -public class EEFRuntimePlugin extends AbstractUIPlugin { - - /** The icons path. */ - public static final String ICONS_16x16 = "icons/16x16/"; //$NON-NLS-1$ - - /** The plug-in ID. */ - public static final String PLUGIN_ID = "org.eclipse.emf.eef.runtime"; //$NON-NLS-1$ - - /** The shared instance. */ - private static EEFRuntimePlugin plugin; - - /** The shared adapterFactory. */ - private static AdapterFactory adapterFactory; - - /** The shared diagnostician. */ - private static Diagnostician diagnostician; - - /** The shared imageRegistry. */ - private static ImageRegistry imageRegistry = null; - - /** - * @return the Image associated to the key - */ - public Image getRegisteredImage(String key) { - return getImageRegistry().get(key); - } - - /** - * @param key - * @param path - */ - public void registerImage(String key, String path) { - if (getImageRegistry().get(key) != null) - getImageRegistry().remove(key); - getImageRegistry().put(key, ImageDescriptor.createFromFile(null, path)); - } - - public ImageRegistry getImageRegistry() { - if (imageRegistry == null) - imageRegistry = new ImageRegistry(); - return imageRegistry; - } - - /** - * The constructor. - */ - public EEFRuntimePlugin() { - plugin = this; - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - diagnostician = new Diagnostician() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.ecore.util.Diagnostician#doValidateContents(org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.common.util.DiagnosticChain, java.util.Map) - */ - @Override - protected boolean doValidateContents(EObject eObject, DiagnosticChain diagnostics, - Map context) { - return true; - } - - }; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - if (imageRegistry != null) - imageRegistry.dispose(); - super.stop(context); - } - - /** - * Returns the shared instance. - * - * @return the shared instance - */ - public static EEFRuntimePlugin getDefault() { - return plugin; - } - - /** - * Returns the shared adapterFactory. - * - * @return the shared adapterFactory - */ - public AdapterFactory getAdapterFactory() { - return adapterFactory; - } - - /** - * @return the diagnostician - */ - public static Diagnostician getEEFValidator() { - return diagnostician; - } - - /** - * @param msg - * a description message - * @param e - * the error - */ - public void logError(String msg, Exception e) { - getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, IStatus.OK, msg, e)); - } - - /** - * Returns an org.eclipse.swt.graphics.Image identified by its key.
- * By default, it returns a default image. This image is the image placed in the directory - * resources/icons/default.gif - * - * @param key - * the key of the image - * @return the Image - */ - public static Image getImage(String key) { - final ImageRegistry registry = getDefault().getImageRegistry(); - Image image = registry.get(key); - if (image == null) { - final ImageDescriptor desc = AbstractUIPlugin.imageDescriptorFromPlugin(PLUGIN_ID, key); - registry.put(key, desc); - image = registry.get(key); - } - return image; - } - - /** - * Returns an org.eclipse.swt.graphics.Image identified by its key.
- * By default, it returns a default image. This image is the image placed in the directory - * resources/icons/default.gif - * - * @param key - * the key of the image - * @return the Image - */ - public static ImageDescriptor getImageDescriptor(String key) { - return AbstractUIPlugin.imageDescriptorFromPlugin(PLUGIN_ID, key); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/adapters/SemanticAdapter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/adapters/SemanticAdapter.java deleted file mode 100644 index 746dbcc51..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/adapters/SemanticAdapter.java +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.adapters; - -import org.eclipse.emf.ecore.EObject; - -/** - * Interface that allows to defines a way to access to the semantic object to edit with editing component. - * - * @author Goulwen Le Fur - */ -public interface SemanticAdapter { - - /** - * returns the semantic object to edit. - * - * @return the semantic element to edit - */ - EObject getEObject(); -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/component/IPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/component/IPropertiesEditionComponent.java deleted file mode 100644 index 5e37383e1..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/component/IPropertiesEditionComponent.java +++ /dev/null @@ -1,213 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.component; - -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -/** - * A stateful element to edit an EObject divided in one or more parts. - * - * @author Goulwen Le Fur - * @author Mikael Barbero - */ -public interface IPropertiesEditionComponent extends IPropertiesEditionListener { - - String BATCH_MODE = "Batch"; //$NON-NLS-1$ - - String LIVE_MODE = "Live"; //$NON-NLS-1$ - - /** - * Returns the Edition Parts list. - * - * @return a String array with all parts keys - */ - String[] partsList(); - - /** - * Return the Edition Part in the given context. - * - * @param kind - * the kind of the expected Part - * @param key - * the Part key - * @return the Part created in the parent - */ - IPropertiesEditionPart getPropertiesEditionPart(int kind, String key); - - /** - * @return the current editingContext. - */ - PropertiesEditingContext getEditingContext(); - - /** - * @param key - * the key identifying the ElementEditor - * @param kind - * the kind of the part - * @param element - * the element which initialize the part - * @param allResource - * the resource where the part has to process - */ - void initPart(Object key, int kind, EObject element, ResourceSet allResource); - - /** - * @param key - * the key identifying the ElementEditor - * @param kind - * the kind of the part - * @param element - * the element which initialize the part - */ - void initPart(Object key, int kind, EObject element); - - /** - * Return the diagnostic object linked to the current state validation. - * - * @return a list of errors message - */ - Diagnostic validateValue(IPropertiesEditionEvent event); - - /** - * Return the diagnostic object linked to the edited element. - * - * @return a list of errors message - */ - Diagnostic validate(); - - /** - * Specifies that a feature value has changed and will be fired later. - * - * @param event - */ - void delayedFirePropertiesChanged(IPropertiesEditionEvent event); - - /** - * Activates this controller. Do nothing it it is already activated. - */ - void activate(); - - /** - * Deactivates this controller. Do nothing if it is not activated. - */ - void deactivate(); - - /** - * Listening management - Adding a new listener. - * - * @param listener - * the new listener to notify - */ - void addListener(IPropertiesEditionListener listener); - - /** - * Listening management - Removing a new listener. - * - * @param listener - * the listener to no longer notify - */ - void removeListener(IPropertiesEditionListener listener); - - /** - * Allows to define editingDomain for live synchronization. - * - * @param editingDomain - * the editingDomain to define - */ - void setLiveEditingDomain(EditingDomain editingDomain); - - /** - * Dispose the component. - */ - void dispose(); - - /** - * Set a part of the Component. - * - * @param key - * the key identifying the part - * @param kind - * the kind of the part - * @param propertiesEditionPart - * the part to set - */ - void setPropertiesEditionPart(Object key, int kind, IPropertiesEditionPart propertiesEditionPart); - - /** - * In dynamic case, managed PropertiesEditionPart can ask the component do decide if they compose a - * sub-view or not. - * - * @param key - * the sub-view to check - * @param kind - * the of the view - * @return true if the sub-view must be composed - */ - boolean mustBeComposed(Object key, int kind); - - /** - * This method allow managed PropertiesEditionPart to ask the component if a elementEditor is required or - * not. - * - * @param key - * the key identifying the ElementEditor - * @param kind - * the kind of the part - * @return true if the given ElementEditor if required - */ - boolean isRequired(Object key, int kind); - - /** - * This method allow managed PropertiesEditionPart to ask the component for an ElementEditor help - * documentation. - * - * @param key - * the key identifying the ElementEditor - * @param kind - * the kind of the part - * @return the help content for the given ElementEditor according the help strategy - */ - String getHelpContent(Object key, int kind); - - /** - * This method translate a Part name into his identifier. - * - * @param key - * the part name - * @return the key identifying the part - */ - Object translatePart(String key); - - /** - * Returns the internationalized text for the specified tab ( in wizards ). - * - * @param key - * the tab key - * @return the internationalized message - */ - String getTabText(String key); - - /** - * @param editorKey - * key of the editor we searching associated feature. - * @return the associated feature. - * @since 0.9 - */ - EStructuralFeature associatedFeature(Object editorKey); -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/context/ContextEntry.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/context/ContextEntry.java deleted file mode 100644 index 0f2d4071a..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/context/ContextEntry.java +++ /dev/null @@ -1,64 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.context; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -/** - * Element that store a navigation step in a properties edition context. - * - * @author Goulwen Le Fur - */ -public class ContextEntry { - - /** - * The element edited at this step. - */ - private EObject element; - - /** - * The component that edited the element at this step. - */ - private IPropertiesEditionComponent propertiesEditionComponent; - - /** - * Parameterized constructors. - * - * @param element - * the edited element - * @param propertiesEditionComponent - * the edition Component - */ - public ContextEntry(EObject element, IPropertiesEditionComponent propertiesEditionComponent) { - this.element = element; - this.propertiesEditionComponent = propertiesEditionComponent; - } - - /** - * Returns the edited element. - * - * @return the edited element - */ - public EObject getElement() { - return element; - } - - /** - * Returns the edition component. - * - * @return the propertiesEditionComponent - */ - public IPropertiesEditionComponent getPropertiesEditionComponent() { - return propertiesEditionComponent; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/EClassifierNotificationFilter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/EClassifierNotificationFilter.java deleted file mode 100644 index 1581b30bd..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/EClassifierNotificationFilter.java +++ /dev/null @@ -1,36 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2010 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.notify; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.ecore.EClassifier; - -/** - * @author Goulwen Le Fur - */ -public class EClassifierNotificationFilter extends NotificationFilter { - - private List eClassifiers; - - public EClassifierNotificationFilter(EClassifier... eClassifiers) { - super(); - this.eClassifiers = new ArrayList(); - for (EClassifier eClassifier : eClassifiers) { - this.eClassifiers.add(eClassifier); - } - } - - public List getEClassifiers() { - return eClassifiers; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/EStructuralFeatureNotificationFilter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/EStructuralFeatureNotificationFilter.java deleted file mode 100644 index f6da24e0f..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/EStructuralFeatureNotificationFilter.java +++ /dev/null @@ -1,37 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2010 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.notify; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.ecore.EStructuralFeature; - -/** - * @author Goulwen Le Fur - */ -public class EStructuralFeatureNotificationFilter extends NotificationFilter { - - private List features; - - public EStructuralFeatureNotificationFilter(EStructuralFeature... features) { - super(); - this.features = new ArrayList(); - for (EStructuralFeature feature : features) { - this.features.add(feature); - } - } - - public List getFeatures() { - return features; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionComponentListener.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionComponentListener.java deleted file mode 100644 index c38774bdd..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionComponentListener.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.notify; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -/** - * Listener on Properties Edition Component : activated on - * org.eclipse.emf.eef.runtime - * .impl.components.SinglePartPropertiesEditingComponent.activate() and dispose - * on org.eclipse.emf.eef.runtime.impl.components. - * SinglePartPropertiesEditingComponent.dispose() - * - * @author Nathalie Lepine - * - */ -public interface IPropertiesEditionComponentListener { - - /** - * @param component IPropertiesEditionComponent - * - * Activate the listener - */ - void activate(IPropertiesEditionComponent component); - - /** - * @param component IPropertiesEditionComponent - * - * Dispose the listener - */ - void deactivate(IPropertiesEditionComponent component); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionEvent.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionEvent.java deleted file mode 100644 index 537d2dd06..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionEvent.java +++ /dev/null @@ -1,65 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.notify; - -import java.util.List; - - -/** - * @author Stephane Bouchet - */ -public interface IPropertiesEditionEvent { - /** - * @param newHolder - */ - public void addHolder(IPropertiesEditionListener newHolder); - - /** - * @return the changedEditor - */ - public Object getAffectedEditor(); - - /** - * @return the holders - */ - public List getHolders(); - - /** - * @return the kind - */ - public int getKind(); - - /** - * @return the newIndex - */ - public int getNewIndex(); - - /** - * @return the newValue - */ - public Object getNewValue(); - - /** - * @return the oldValue - */ - public Object getOldValue(); - - /** - * @return the state - */ - public int getState(); - - /** - * @param toTest - * @return - */ - public boolean hold(IPropertiesEditionListener toTest); -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionListener.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionListener.java deleted file mode 100644 index 7b7c76314..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/IPropertiesEditionListener.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.notify; - -/** - * @author Goulwen Le Fur - */ -public interface IPropertiesEditionListener { - - /** - * Specifies that a feature value has changed. - * - * @param event - * the object - */ - void firePropertiesChanged(IPropertiesEditionEvent event); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/NotificationFilter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/NotificationFilter.java deleted file mode 100644 index 0e3c041c1..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/NotificationFilter.java +++ /dev/null @@ -1,18 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2010 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.notify; - -/** - * @author Goulwen Le Fur - */ -public abstract class NotificationFilter { - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/PropertiesEditingSemanticListener.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/PropertiesEditingSemanticListener.java deleted file mode 100644 index 4bcf8b327..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/PropertiesEditingSemanticListener.java +++ /dev/null @@ -1,90 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.notify; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.swt.widgets.Display; -import org.eclipse.ui.PlatformUI; - -/** - * @author Goulwen Le Fur - */ -public abstract class PropertiesEditingSemanticListener { - - private IPropertiesEditionComponent component; - - private IPropertiesEditionPart part; - - private NotificationFilter[] filters; - - /** - * @param component - */ - public PropertiesEditingSemanticListener(IPropertiesEditionComponent component, NotificationFilter... filters) { - this.component = component; - this.filters = filters; - } - - /** - * @return the part - */ - public IPropertiesEditionPart getPart() { - return part; - } - - /** - * @param part - * the part to set - */ - public void setPart(IPropertiesEditionPart part) { - this.part = part; - } - - /** - * @return - */ - public NotificationFilter[] getFilters() { - return filters; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.ecore.util.EContentAdapter#notifyChanged(org.eclipse.emf.common.notify.Notification) - */ - public void notifyChanged(final Notification notification) { - if (part == null) - component.dispose(); - else { - Runnable updateRunnable = new Runnable() { - public void run() { - runUpdateRunnable(notification); - } - }; - if (null == Display.getCurrent()) { - PlatformUI.getWorkbench().getDisplay().asyncExec(updateRunnable); - } else { - updateRunnable.run(); - } - } - } - - /** - * Performs update in the views - * - * @param notification - * the model notification - */ - public abstract void runUpdateRunnable(Notification notification); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/PropertiesEditingSemanticLister.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/PropertiesEditingSemanticLister.java deleted file mode 100644 index 76fd3aedf..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/PropertiesEditingSemanticLister.java +++ /dev/null @@ -1,83 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.notify; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.util.EContentAdapter; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.swt.widgets.Display; -import org.eclipse.ui.PlatformUI; - -/** - * @author Goulwen Le Fur - */ -@Deprecated -public abstract class PropertiesEditingSemanticLister extends EContentAdapter { - - private IPropertiesEditionComponent component; - - private IPropertiesEditionPart part; - - /** - * @param component - */ - public PropertiesEditingSemanticLister(IPropertiesEditionComponent component) { - this.component = component; - } - - /** - * @return the part - */ - public IPropertiesEditionPart getPart() { - return part; - } - - /** - * @param part - * the part to set - */ - public void setPart(IPropertiesEditionPart part) { - this.part = part; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.ecore.util.EContentAdapter#notifyChanged(org.eclipse.emf.common.notify.Notification) - */ - @Override - public void notifyChanged(final Notification notification) { - if (part == null) - component.dispose(); - else { - Runnable updateRunnable = new Runnable() { - public void run() { - runUpdateRunnable(notification); - } - }; - if (null == Display.getCurrent()) { - PlatformUI.getWorkbench().getDisplay().asyncExec(updateRunnable); - } else { - updateRunnable.run(); - } - } - } - - /** - * Performs update in the views - * - * @param notification - * the model notification - */ - public abstract void runUpdateRunnable(Notification notification); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/ResourceSetAdapter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/ResourceSetAdapter.java deleted file mode 100644 index 69bc12ac9..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/notify/ResourceSetAdapter.java +++ /dev/null @@ -1,230 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2010 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.notify; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.EContentAdapter; - -/** - * @author Goulwen Le Fur - */ -public class ResourceSetAdapter extends EContentAdapter { - - /** - * The eClassifiers listeners. - */ - private Map> eClassifierListeners; - - /** - * The features listeners. - */ - private Map> eStructuralFeatureListeners; - - /** - * The resource set we listen to. - */ - private ResourceSet resourceSet; - - /** - * Constructor. - */ - public ResourceSetAdapter(ResourceSet resourceSet) { - super(); - this.resourceSet = resourceSet; - eClassifierListeners = new HashMap>(); - eStructuralFeatureListeners = new HashMap>(); - } - - @Override - public boolean isAdapterForType(Object type) { - return type == ResourceSetAdapter.class || ResourceSetAdapter.class.getName().equals(type); - } - - /** - * Activates the resource set adapter. - */ - public void activate() { - resourceSet.eAdapters().add(this); - } - - - /** - * Removes the current adapter from the resource set adapters. - */ - public void deactivate() { - resourceSet.eAdapters().remove(this); - } - - /** - * Adds the given listener to the registered listeners. - * - * @param listener - * the listener to remove - */ - public void addEditingSemanticListener(PropertiesEditingSemanticListener listener) { - for (NotificationFilter filter : listener.getFilters()) { - if (filter instanceof EStructuralFeatureNotificationFilter) { - for (EStructuralFeature feature : ((EStructuralFeatureNotificationFilter)filter) - .getFeatures()) { - addEditingSemanticListener(feature, listener); - } - } else if (filter instanceof EClassifierNotificationFilter) { - for (EClassifier eClassifier : ((EClassifierNotificationFilter)filter).getEClassifiers()) { - addEditingSemanticListener(eClassifier, listener); - } - } - } - } - - /** - * Adds the given listener to the registered listeners. - * - * @param feature - * the feature key - * @param listener - * the listener to remove - */ - private void addEditingSemanticListener(EStructuralFeature feature, - PropertiesEditingSemanticListener listener) { - List listeners = eStructuralFeatureListeners.get(feature); - if (listeners == null) { - listeners = new ArrayList(); - eStructuralFeatureListeners.put(feature, listeners); - } - listeners.add(listener); - } - - /** - * Adds the given listener to the registered listeners. - * - * @param eClassifier - * the eClassifier key - * @param listener - * the listener to remove - */ - private void addEditingSemanticListener(EClassifier eClassifier, - PropertiesEditingSemanticListener listener) { - List listeners = eClassifierListeners.get(eClassifier); - if (listeners == null) { - listeners = new ArrayList(); - eClassifierListeners.put(eClassifier, listeners); - } - listeners.add(listener); - } - - /** - * Removes the given listener from the registered listeners. - * - * @param listener - * the listener to remove - */ - public void removeEditingSemanticListener(PropertiesEditingSemanticListener listener) { - unregisterEditingSemanticListener(listener); - - // if there are no listeners left we remove the adapter - if (eClassifierListeners.size() + eStructuralFeatureListeners.size() == 0) - deactivate(); - } - - /** - * Unregisters the given listener - * @param listener {@link PropertiesEditingSemanticListener} to unregister. - */ - public void unregisterEditingSemanticListener(PropertiesEditingSemanticListener listener) { - for (NotificationFilter filter : listener.getFilters()) { - if (filter instanceof EStructuralFeatureNotificationFilter) { - for (EStructuralFeature feature : ((EStructuralFeatureNotificationFilter)filter).getFeatures()) { - removeEditingSemanticListener(feature, listener); - } - } else if (filter instanceof EClassifierNotificationFilter) { - for (EClassifier eClassifier : ((EClassifierNotificationFilter)filter).getEClassifiers()) { - removeEditingSemanticListener(eClassifier, listener); - } - } - } - } - /** - * Removes the given listener from the registered listeners. - * - * @param feature - * the feature key - * @param listener - * the listener to remove - */ - private void removeEditingSemanticListener(EStructuralFeature feature, - PropertiesEditingSemanticListener listener) { - List listeners = eStructuralFeatureListeners.get(feature); - if (listeners != null) { - listeners.remove(listener); - if (listeners.isEmpty()) { - eStructuralFeatureListeners.remove(feature); - } - } - } - - /** - * Removes the given listener from the registered listeners. - * - * @param eClassifier - * the classifier key - * @param listener - * the listener to remove - */ - private void removeEditingSemanticListener(EClassifier eClassifier, - PropertiesEditingSemanticListener listener) { - List listeners = eClassifierListeners.get(eClassifier); - if (listeners != null) { - listeners.remove(listener); - if (listeners.isEmpty()) { - eClassifierListeners.remove(eClassifier); - } - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.ecore.util.EContentAdapter#notifyChanged(org.eclipse.emf.common.notify.Notification) - */ - public void notifyChanged(Notification notification) { - super.notifyChanged(notification); - if (notification.getNotifier() instanceof EObject) { - EObject notifier = (EObject)notification.getNotifier(); - EClass eClass = notifier.eClass(); - if (eClassifierListeners.get(eClass) != null) { - List listeners = eClassifierListeners.get(eClass); - for (PropertiesEditingSemanticListener listener : new ArrayList(listeners)) { - listener.notifyChanged(notification); - } - } - } - if (notification.getFeature() instanceof EStructuralFeature) { - EStructuralFeature feature = (EStructuralFeature)notification.getFeature(); - if (eStructuralFeatureListeners.get(feature) != null) { - List listeners = eStructuralFeatureListeners.get(feature); - for (PropertiesEditingSemanticListener listener : new ArrayList(listeners)) { - listener.notifyChanged(notification); - } - } - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/IFormPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/IFormPropertiesEditionPart.java deleted file mode 100644 index d102e0f87..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/IFormPropertiesEditionPart.java +++ /dev/null @@ -1,38 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.parts; - -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * @author Goulwen Le Fur - */ -public interface IFormPropertiesEditionPart { - - /** - * Create the figure in the specified element. - * - * @param parent - * the parent - * @return the created view - */ - public abstract Composite createFigure(Composite parent, FormToolkit widgetFactory); - - /** - * Create all elements of the figure. This method is the stateless way to populate another composite. - * - * @param parent - * @param widgetFactory - */ - public abstract void createControls(FormToolkit widgetFactory, Composite parent); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/IPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/IPropertiesEditionPart.java deleted file mode 100644 index 2363df12b..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/IPropertiesEditionPart.java +++ /dev/null @@ -1,70 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.parts; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.jface.databinding.swt.ISWTObservableValue; -import org.eclipse.swt.widgets.Composite; - -/** - * A interface for part of element edition. - * - * @author Goulwen Le Fur - */ -public interface IPropertiesEditionPart extends IPropertiesEditionListener { - - /** - * Getter for the view - * - * @return the part view - */ - public Composite getFigure(); - - /** - * Defines the context (edited element, resourceset) of the part - * - * @param eObject - * the EObject to edit - * @param allResources - * the resourceset where edit - */ - public void setContext(EObject eObject, ResourceSet allResources); - - /** - * Return an observer on the given Element Editor - * - * @param key - * the key qualifying the Element Editor - * @return an observer on the given Element Editor - */ - public ISWTObservableValue getObserver(String key); - - /** - * Returns the internationalized title text. - * - * @return the internationalized title text. - */ - public String getTitle(); - - - /** - * @return true if the part is visible - */ - public boolean isVisible(); - - /** - * Defines the part visibility. - * @param visibility to set. - */ - public void setVisible(boolean visibility); -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/ISWTPropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/ISWTPropertiesEditionPart.java deleted file mode 100644 index e78bdf00e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/parts/ISWTPropertiesEditionPart.java +++ /dev/null @@ -1,37 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.parts; - -import org.eclipse.swt.widgets.Composite; - -/** - * @author Goulwen Le Fur - */ -public interface ISWTPropertiesEditionPart { - - /** - * Create the figure in the specified element. - * - * @param parent - * the parent - * @return the created view - */ - public abstract Composite createFigure(Composite parent); - - /** - * Create all elements of the figure. This method is the stateless way to populate another composite. - * - * @param parent - * the parent - */ - public abstract void createControls(Composite parent); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IPropertiesEditionPartProvider.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IPropertiesEditionPartProvider.java deleted file mode 100644 index 4d4ea3d74..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IPropertiesEditionPartProvider.java +++ /dev/null @@ -1,44 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.providers; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; - -/** - * Interface to implement by {@link IPropertiesEditionPart} providers. - * - * @author Goulwen Le Fur - */ -public interface IPropertiesEditionPartProvider { - - /** - * Indicates whether this provider provides the specified ViewRepository. - * - * @param key - * the key identifing the ViewRepository to check - * @return true if this provider provides for this ; false otherwise. - */ - public abstract boolean provides(Object key); - - /** - * @param key - * the key identifing the expected View. - * @param kind - * the kind of the expected view - * @param component - * the {@link IPropertiesEditionComponent} that manages this view - * @return the expected view - */ - public abstract IPropertiesEditionPart getPropertiesEditionPart(Object key, int kind, - IPropertiesEditionComponent component); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IPropertiesEditionPartProviderFactory.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IPropertiesEditionPartProviderFactory.java deleted file mode 100644 index 1c31a02f0..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IPropertiesEditionPartProviderFactory.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.providers; - -/** - * Defines the {@link IPropertiesEditionPartProvider} factories interface. - * - * @author Goulwen Le Fur - */ -public interface IPropertiesEditionPartProviderFactory { - - /** - * Indicates whether this provider provides the specified ViewRepository. - * - * @param key - * the ViewRepository to provide - * @return true if this provider provides the ViewRepository; false otherwise. - */ - public abstract boolean provides(Object key); - - /** - * Register a new {@link IPropertiesEditionPartProvider} in the factory. - * - * @param editPropertiesProvider - */ - public abstract void register(IPropertiesEditionPartProvider editPropertiesPartProvider); - - /** - * Provides a {@link IPropertiesEditionPartProvider} for the specified ViewRepository. - * - * @param the - * ViewRepository to provide - * @return the {@link IPropertiesEditionPartProvider} for the specified ViewRepository. - */ - public abstract IPropertiesEditionPartProvider getProvider(Object key); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IReadOnlyPolicy.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IReadOnlyPolicy.java deleted file mode 100644 index 90f6aef0a..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/api/providers/IReadOnlyPolicy.java +++ /dev/null @@ -1,32 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.api.providers; - -import org.eclipse.emf.ecore.EObject; - -/** - * Policy for read only widgets. - * - * @author Nathalie Lepine - * - */ -public interface IReadOnlyPolicy { - - /** - * @param context - * Semantic EObject - * @param eStructuralFeature - * EStructuralFeature - * @return if the widget is read only - */ - boolean isReadOnly(EObject context, Object eStructuralFeature); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/ExtendedPropertiesEditingContext.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/ExtendedPropertiesEditingContext.java deleted file mode 100644 index eb0d83943..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/ExtendedPropertiesEditingContext.java +++ /dev/null @@ -1,72 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.context; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.ResourceSetAdapter; -import org.eclipse.emf.eef.runtime.ui.parts.ViewHelper; - -/** - * @author Goulwen Le Fur - * @since 1.1 - */ -public interface ExtendedPropertiesEditingContext extends PropertiesEditingContext { - - - /** - * Returns a new {@link IPropertiesEditionComponent} in the given mode. - * @param mode mode for the {@link IPropertiesEditionComponent} - * @return the created {@link IPropertiesEditionComponent} - */ - public IPropertiesEditionComponent createPropertiesEditingComponent(String mode); - - /** - * Returns a new {@link IPropertiesEditionComponent} in the given mode. - * @param mode mode for the {@link IPropertiesEditionComponent} - * @param part part of the {@link IPropertiesEditionComponent} - * @return the created {@link IPropertiesEditionComponent} - */ - public IPropertiesEditionComponent createPropertiesEditingComponent(String mode, String part); - - /** - * Returns a new {@link IPropertiesEditionComponent} in the given mode. - * @param mode mode for the {@link IPropertiesEditionComponent} - * @param part part of the {@link IPropertiesEditionComponent} - * @param refinement specialization of the part for {@link IPropertiesEditionComponent} - * @return the created {@link IPropertiesEditionComponent} - */ - public IPropertiesEditionComponent createPropertiesEditingComponent(String mode, String part, Class refinement); - - /** - * @return the {@link IPropertiesEditionComponent} of the context. - */ - public abstract IPropertiesEditionComponent getPropertiesEditingComponent(); - - /** - * @return the {@link ViewHelper} of the context. - */ - public ViewHelper getHelper(); - - /** - * @param helper {@link ViewHelper} to use. - */ - public void setHelper(ViewHelper helper); - - /** - * @return - */ - public ResourceSetAdapter getResourceSetAdapter(); - - /** - * @return - */ - public boolean canReachResourceSetAdapter(); -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/PropertiesEditingContext.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/PropertiesEditingContext.java deleted file mode 100644 index 748561962..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/PropertiesEditingContext.java +++ /dev/null @@ -1,73 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.context; - -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.change.util.ChangeRecorder; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFEditorSettings; - -/** - * @author Goulwen Le Fur - * use {@link ExtendedPropertiesEditingContext} instead of this interface. - */ -public interface PropertiesEditingContext { - - /** - * Intialize the ChangeRecorder of the editing session. - */ - public void initializeRecorder(); - - /** - * @return the changeRecorder of the editing session - */ - public ChangeRecorder getChangeRecorder(); - - /** - * Dispose and "nullify" the nested change recorder - */ - public void disposeRecorder(); - - /** - * @return the currently edited {@link EObject}. - */ - public EObject getEObject(); - - /** - * @return the resourceSet where to work. - */ - public ResourceSet getResourceSet(); - - /** - * @return the {@link AdapterFactory} to use during the editing. - */ - public AdapterFactory getAdapterFactory(); - - /** - * dispose the context - */ - public void dispose(); - - /** - * @return the parentContext - */ - public PropertiesEditingContext getParentContext(); - - /** - * @param eObject - */ - public void seteObject(EObject eObject); - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/DomainPropertiesEditionContext.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/DomainPropertiesEditionContext.java deleted file mode 100644 index 4d5926ef7..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/DomainPropertiesEditionContext.java +++ /dev/null @@ -1,103 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.context.impl; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -/** - * @author Goulwen Le Fur - */ -public class DomainPropertiesEditionContext extends EObjectPropertiesEditionContext { - - /** - * The domain where edit the EObject - */ - protected EditingDomain editingDomain; - - /** - * @param parentContext - * the parent context - * @param editionComponent - * editingComponent holding the EObject editing - * @param domain - * domain where to perform commands - * @param adapterFactory - * adapterFactory to use to get editing providers - * @param eObject - * eObject to edit - */ - public DomainPropertiesEditionContext(PropertiesEditingContext parentContext, - IPropertiesEditionComponent editionComponent, EditingDomain domain, - AdapterFactory adapterFactory, EObject eObject) { - super(parentContext, editionComponent, eObject, adapterFactory); - this.editingDomain = domain; - } - - /** - * @return the editingDomain - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext#getResourceSet() - */ - public ResourceSet getResourceSet() { - if (editingDomain != null && editingDomain.getResourceSet() != null) - return editingDomain.getResourceSet(); - return super.getResourceSet(); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext#createPropertiesEditingComponent(java.lang.String) - */ - public IPropertiesEditionComponent createPropertiesEditingComponent(String mode) { - IPropertiesEditionComponent propertiesEditingComponent = super.createPropertiesEditingComponent(mode); - if (IPropertiesEditionComponent.LIVE_MODE.equals(mode)) { - propertiesEditingComponent.setLiveEditingDomain(editingDomain); - } - return propertiesEditingComponent; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext#createPropertiesEditingComponent(java.lang.String, java.lang.String) - */ - public IPropertiesEditionComponent createPropertiesEditingComponent(String mode, String part) { - IPropertiesEditionComponent propertiesEditingComponent = super.createPropertiesEditingComponent(mode, part); - if (IPropertiesEditionComponent.LIVE_MODE.equals(mode)) { - propertiesEditingComponent.setLiveEditingDomain(editingDomain); - } - return propertiesEditingComponent; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext#createPropertiesEditingComponent(java.lang.String, java.lang.String, java.lang.Class) - */ - public IPropertiesEditionComponent createPropertiesEditingComponent(String mode, String part, Class refinement) { - IPropertiesEditionComponent propertiesEditingComponent = super.createPropertiesEditingComponent(mode, part, refinement); - if (IPropertiesEditionComponent.LIVE_MODE.equals(mode)) { - propertiesEditingComponent.setLiveEditingDomain(editingDomain); - } - return propertiesEditingComponent; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/EObjectPropertiesEditionContext.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/EObjectPropertiesEditionContext.java deleted file mode 100644 index 3889e6978..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/EObjectPropertiesEditionContext.java +++ /dev/null @@ -1,309 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.context.impl; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.change.util.ChangeRecorder; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.ResourceSetAdapter; -import org.eclipse.emf.eef.runtime.context.ExtendedPropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.ui.parts.ViewHelper; -import org.eclipse.emf.eef.runtime.ui.parts.impl.BindingViewHelper; -import org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFEditorSettings; - -/** - * @author Goulwen Le Fur - */ -public class EObjectPropertiesEditionContext implements ExtendedPropertiesEditingContext { - - /** - * the source EditionComponent - * @since 1.1 - */ - protected IPropertiesEditionComponent parentPropertiesEditionComponent; - - /** - * Helper for created graphical elements of the view - */ - private ViewHelper helper; - - /** - * the EObject to edit - */ - protected EObject eObject; - - /** - * EEF editor settings to use. - */ - private List allSettings; - - /** - * - */ - protected ChangeRecorder changeRecorder; - - /** - * The AdapterFactory to use in the editing context - */ - protected AdapterFactory adapterFactory; - - /** - * The parent context (can be null) - */ - protected PropertiesEditingContext parentContext; - - /** - * The {@link IPropertiesEditionComponent} of the context - */ - private IPropertiesEditionComponent propertiesEditingComponent; - - /** - * @param parentContext - * the parent context - * @param propertiesEditionComponent - * editingComponent holding the EObject editing - * @param eObject - * eObject to edit - * @param adapterFactory - * adapterFactory to use to get editing providers - */ - public EObjectPropertiesEditionContext(PropertiesEditingContext parentContext, - IPropertiesEditionComponent propertiesEditionComponent, EObject eObject, - AdapterFactory adapterFactory) { - this.parentContext = parentContext; - this.parentPropertiesEditionComponent = propertiesEditionComponent; - this.eObject = eObject; - this.adapterFactory = adapterFactory; - this.allSettings = new ArrayList(); - } - - /** - * @return the parentContext - */ - public PropertiesEditingContext getParentContext() { - return parentContext; - } - - /** - * (non-Javadoc) - * @see org.eclipse.emf.eef.runtime.context.PropertiesEditingContext#initializeRecorder() - */ - public void initializeRecorder() { - if (this.changeRecorder == null) { - Notifier highestNotifier = EEFUtils.highestNotifier(eObject); - if (highestNotifier instanceof ResourceSet) { - this.changeRecorder = new ChangeRecorder((ResourceSet) highestNotifier); - } else if (highestNotifier instanceof Resource) { - this.changeRecorder = new ChangeRecorder((Resource) highestNotifier); - } else if (highestNotifier instanceof EObject) { - this.changeRecorder = new ChangeRecorder((EObject) highestNotifier); - } - } - if (getParentContext() != null) { - getParentContext().initializeRecorder(); - } - } - - /** - * @return the changeRecorder - */ - public ChangeRecorder getChangeRecorder() { - return changeRecorder; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.context.PropertiesEditingContext#disposeRecorder() - */ - public void disposeRecorder() { - changeRecorder.dispose(); - changeRecorder = null; - } - - /** - * @return the eObject - */ - public EObject getEObject() { - return eObject; - } - - /** - * @param eObject - */ - public void seteObject(EObject eObject) { - this.eObject = eObject; - } - - /** - * @return the settings to use. - */ - public List getAllSettings() { - return allSettings; - } - - /** - * set the settings to use. - */ - public void setAllSettings(List settings) { - this.allSettings = settings; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.context.PropertiesEditingContext#createPropertiesEditingComponent(java.lang.String) - * @since 1.1 - */ - public IPropertiesEditionComponent createPropertiesEditingComponent(String mode) { - if (propertiesEditingComponent == null) { - PropertiesEditingProvider propertiesEditionProvider = (PropertiesEditingProvider)adapterFactory - .adapt(eObject, PropertiesEditingProvider.class); - if (propertiesEditionProvider != null) { - this.propertiesEditingComponent = propertiesEditionProvider.getPropertiesEditingComponent( - this, mode); - } - } - return propertiesEditingComponent; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.context.PropertiesEditingContext#createPropertiesEditingComponent(java.lang.String, - * java.lang.String) - * @since 1.1 - */ - public IPropertiesEditionComponent createPropertiesEditingComponent(String mode, String part) { - if (propertiesEditingComponent == null) { - PropertiesEditingProvider propertiesEditionProvider = (PropertiesEditingProvider)adapterFactory - .adapt(eObject, PropertiesEditingProvider.class); - if (propertiesEditionProvider != null) { - this.propertiesEditingComponent = propertiesEditionProvider.getPropertiesEditingComponent( - this, mode, part); - } - } - return propertiesEditingComponent; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.context.PropertiesEditingContext#createPropertiesEditingComponent(java.lang.String, - * java.lang.String, java.lang.Class) - * @since 1.1 - */ - public IPropertiesEditionComponent createPropertiesEditingComponent(String mode, String part, - Class refinement) { - if (propertiesEditingComponent == null) { - PropertiesEditingProvider propertiesEditionProvider = (PropertiesEditingProvider)adapterFactory - .adapt(eObject, PropertiesEditingProvider.class); - if (propertiesEditionProvider != null) { - this.propertiesEditingComponent = propertiesEditionProvider.getPropertiesEditingComponent( - this, mode, part, refinement); - } - } - return propertiesEditingComponent; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.context.PropertiesEditingContext#getPropertiesEditingComponent() - * @since 1.1 - */ - public IPropertiesEditionComponent getPropertiesEditingComponent() { - return propertiesEditingComponent; - } - - /** - * @return the resourceSet - */ - public ResourceSet getResourceSet() { - if (eObject != null && eObject.eResource() != null && eObject.eResource().getResourceSet() != null) - return eObject.eResource().getResourceSet(); - if (parentContext != null) - return parentContext.getResourceSet(); - return null; - } - - /** - * @return the adapterFactory - */ - public AdapterFactory getAdapterFactory() { - return adapterFactory; - } - - /** - * Dispose the change recorder - */ - public void dispose() { - if (changeRecorder != null) - changeRecorder.dispose(); - } - - /** - * @return the {@link ViewHelper} of the context. - * @since 1.1 - */ - public ViewHelper getHelper() { - if (helper == null) { - helper = new BindingViewHelper(this); - } - return helper; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.context.PropertiesEditingContext#setHelper(org.eclipse.emf.eef.runtime.ui.parts.ViewHelper) - * @since 1.1 - */ - public void setHelper(ViewHelper helper) { - this.helper = helper; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.context.ExtendedPropertiesEditingContext#getResourceSetAdapter() - */ - public ResourceSetAdapter getResourceSetAdapter() { - ResourceSet resourceSet = getResourceSet(); - for (Adapter adapter : resourceSet.eAdapters()) { - if (adapter instanceof ResourceSetAdapter) { - return (ResourceSetAdapter)adapter; - } - } - ResourceSetAdapter resourceSetAdapter = new ResourceSetAdapter(resourceSet); - resourceSetAdapter.activate(); - return resourceSetAdapter; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.context.ExtendedPropertiesEditingContext#canReachResourceSetAdapter() - */ - public boolean canReachResourceSetAdapter() { - return eObject != null && eObject.eResource() != null && eObject.eResource().getResourceSet() != null; - } - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/EReferencePropertiesEditionContext.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/EReferencePropertiesEditionContext.java deleted file mode 100644 index b72f91692..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/EReferencePropertiesEditionContext.java +++ /dev/null @@ -1,89 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.context.impl; - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFEditorSettings; - -/** - * @author Goulwen Le Fur - */ -public class EReferencePropertiesEditionContext extends EObjectPropertiesEditionContext { - - /** - * the EReference to edit - */ - protected EReference eReference; - - /** - * EEF editor settings to use. - */ - private EEFEditorSettings settings; - - protected Collection instanciableTypeFilters = new ArrayList(); - - /** - * @param parentContext - * @param propertiesEditionComponent - * @param settings - * @param adapterFactory - */ - public EReferencePropertiesEditionContext(PropertiesEditingContext parentContext, IPropertiesEditionComponent propertiesEditionComponent, EEFEditorSettings settings, AdapterFactory adapterFactory) { - super(parentContext, propertiesEditionComponent, settings.getSource(), adapterFactory); - this.settings = settings; - this.eReference = settings.getLastReference(); - } - - /** - * @return the eReference - */ - public EReference getEReference() { - return eReference; - } - - /** - * @return the settings to use. - */ - public EEFEditorSettings getSettings() { - return settings; - } - - /** - * @return the filters - */ - public Collection getInstanciableTypeFilters() { - return instanciableTypeFilters; - } - - /** - * Add a filter to the list - * @param filter - */ - public void addInstanciableTypeFilter(InstanciableTypeFilter filter) { - instanciableTypeFilters.add(filter); - } - - public interface InstanciableTypeFilter { - /** - * Tests if the provided type can be instantiated - * @param instanciableType Tested type - * @return True if the type can be instantiate - */ - public boolean select(EClass instanciableType); - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/TypedEReferencePropertiesEditingContext.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/TypedEReferencePropertiesEditingContext.java deleted file mode 100644 index 7c70cc04e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/context/impl/TypedEReferencePropertiesEditingContext.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.context.impl; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; - -/** - * @author Goulwen Le Fur - * @deprecated {@link EReferencePropertiesEditionContext} can now handle filters on type in a more generic way - */ -public class TypedEReferencePropertiesEditingContext extends EReferencePropertiesEditionContext { - - private EClass expectedType; - - /** - * @param parentContext - * @param propertiesEditionComponent - * @param settings - * @param adapterFactory - */ - public TypedEReferencePropertiesEditingContext(PropertiesEditingContext parentContext, - IPropertiesEditionComponent propertiesEditionComponent, ReferencesTableSettings settings, - EClass expectedType, AdapterFactory adapterFactory) { - super(parentContext, propertiesEditionComponent, settings, adapterFactory); - this.expectedType = expectedType; - } - - /** - * @return the expectedType - */ - public EClass getExpectedType() { - return expectedType; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/command/StandardEditingCommand.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/command/StandardEditingCommand.java deleted file mode 100644 index ab7ec8369..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/command/StandardEditingCommand.java +++ /dev/null @@ -1,63 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.command; - -import org.eclipse.emf.common.command.AbstractCommand; -import org.eclipse.emf.ecore.change.ChangeDescription; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; - -/** - * @author Goulwen Le Fur - */ -public abstract class StandardEditingCommand extends AbstractCommand { - - - - protected PropertiesEditingContext context; - - public StandardEditingCommand(PropertiesEditingContext context) { - super(); - this.context = context; - } - - public StandardEditingCommand(String label, String description) { - super(label, description); - } - - public StandardEditingCommand(String label) { - super(label); - } - - protected ChangeDescription description; - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.common.command.AbstractCommand#prepare() - */ - @Override - protected boolean prepare() { - return true; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.common.command.Command#redo() - */ - public void redo() { - description.applyAndReverse(); - } - - public void undo() { - description.applyAndReverse(); - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/command/WizardEditingCommand.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/command/WizardEditingCommand.java deleted file mode 100644 index 0d8a5c213..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/command/WizardEditingCommand.java +++ /dev/null @@ -1,82 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.command; - -import org.eclipse.emf.common.command.AbstractCommand; -import org.eclipse.emf.ecore.change.ChangeDescription; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.services.WizardOpeningPolicyProviderService; -import org.eclipse.emf.eef.runtime.ui.wizards.IWizardOpeningPolicy; -import org.eclipse.emf.eef.runtime.ui.wizards.PropertiesEditionWizard; - -/** - * @author Goulwen Le Fur - */ -public class WizardEditingCommand extends AbstractCommand { - - protected DomainPropertiesEditionContext editionContext; - - protected ChangeDescription description; - - /** - * @param editionContext - */ - public WizardEditingCommand(DomainPropertiesEditionContext editionContext) { - this.editionContext = editionContext; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.common.command.AbstractCommand#prepare() - */ - @Override - protected boolean prepare() { - PropertiesEditionWizard wizard = new PropertiesEditionWizard(editionContext, - editionContext.getAdapterFactory(), editionContext.getEObject()); - IWizardOpeningPolicy wizardOpeningPolicy = WizardOpeningPolicyProviderService.provide(editionContext.getEObject()); - boolean openWizard = wizardOpeningPolicy.openWizard(editionContext, wizard); - this.description = wizardOpeningPolicy.getDescription(); - return openWizard; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.common.command.Command#execute() - */ - public void execute() { - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.common.command.AbstractCommand#undo() - */ - @Override - public void undo() { - if (description != null) { - description.applyAndReverse(); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.common.command.Command#redo() - */ - public void redo() { - if (description != null) { - description.applyAndReverse(); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/ComposedPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/ComposedPropertiesEditionComponent.java deleted file mode 100644 index 8c866d4e2..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/ComposedPropertiesEditionComponent.java +++ /dev/null @@ -1,378 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.components; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.parts.NullCompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.utils.EEFRuntimeMessages; -import org.eclipse.emf.eef.runtime.impl.utils.StringTools; - -/** - * @author Goulwen Le Fur - * @author Mikaël Barbero - */ -public class ComposedPropertiesEditionComponent implements IPropertiesEditionComponent { - - /** - * List of managed components - */ - protected List subComponents; - - /** - * List of this component listeners - */ - private List listeners; - - /** - * The current editingContext - */ - private PropertiesEditingContext editingContext; - - /** - * Default constructor - */ - public ComposedPropertiesEditionComponent(PropertiesEditingContext editingContext, String mode) { - this.editingContext = editingContext; - this.subComponents = new ArrayList(); - this.listeners = new ArrayList(); - } - - /** - * Parameterized constructor - * - * @param subComponents - * list of the managed components - */ - public ComposedPropertiesEditionComponent(List subComponents) { - this.subComponents = subComponents; - this.listeners = new ArrayList(); - for (IPropertiesEditionComponent component : subComponents) { - listeners.add(component); - component.addListener(this); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#setLiveEditingDomain(org.eclipse.emf.edit.domain.EditingDomain) - */ - public void setLiveEditingDomain(EditingDomain editingDomain) { - for (IPropertiesEditionComponent component : subComponents) { - component.setLiveEditingDomain(editingDomain); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#partsList() - */ - public String[] partsList() { - List partsList = new ArrayList(); - for (IPropertiesEditionComponent component : subComponents) { - String[] partsList2 = component.partsList(); - for (int i = 0; i < partsList2.length; i++) { - String string = partsList2[i]; - if (!partsList.contains(string)) - partsList.add(string); - } - } - String[] result = new String[partsList.size()]; - int i = 0; - for (String nextPart : partsList) { - result[i++] = nextPart; - } - return result; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, - * int, org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.resource.ResourceSet) - */ - public void initPart(Object key, int kind, EObject element, ResourceSet allResource) { - for (IPropertiesEditionComponent component : subComponents) { - component.initPart(key, kind, element, allResource); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, - * int, org.eclipse.emf.ecore.EObject) - */ - public void initPart(Object key, int kind, EObject element) { - this.initPart(key, kind, element, element.eResource().getResourceSet()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#getPropertiesEditionPart(java.lang.String, - * java.lang.String) - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - for (IPropertiesEditionComponent component : subComponents) { - IPropertiesEditionPart propertiesEditionPart = component.getPropertiesEditionPart(kind, key); - if (propertiesEditionPart != null - && !(propertiesEditionPart instanceof NullCompositePropertiesEditionPart)) - return propertiesEditionPart; - } - return new NullCompositePropertiesEditionPart(this); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#getEditingContext() - */ - public PropertiesEditingContext getEditingContext() { - return editingContext; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - event.addHolder(this); - for (IPropertiesEditionListener listener : listeners) { - if (!event.hold(listener)) - listener.firePropertiesChanged(event); - } - } - - public void delayedFirePropertiesChanged(IPropertiesEditionEvent event) { - for (IPropertiesEditionComponent propertiesEditionComponent : subComponents) { - if (!event.hold(propertiesEditionComponent)) - propertiesEditionComponent.delayedFirePropertiesChanged(event); - } - } - - public void activate() { - for (IPropertiesEditionComponent propertiesEditionComponent : subComponents) { - propertiesEditionComponent.activate(); - } - } - - public void deactivate() { - for (IPropertiesEditionComponent propertiesEditionComponent : subComponents) { - propertiesEditionComponent.deactivate(); - } - } - - /** - * Add a new component of the managed components - * - * @param component - * the component to add - */ - public void addSubComponent(IPropertiesEditionComponent component) { - if (subComponents != null && listeners != null) { - subComponents.add(component); - listeners.add(component); - component.addListener(this); - } - } - - /** - * Remove a component from the managed components - * - * @param component - * the component to removed - */ - public void removeSubComponent(IPropertiesEditionComponent component) { - if (subComponents != null && listeners != null) { - component.removeListener(this); - subComponents.remove(component); - listeners.remove(component); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#addListener(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener) - */ - public void addListener(IPropertiesEditionListener listener) { - if (listeners == null) - listeners = new ArrayList(); - listeners.add(listener); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#removeListener(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener) - */ - public void removeListener(IPropertiesEditionListener listener) { - if (listeners != null) - listeners.remove(listener); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validateValue(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - BasicDiagnostic diagnostic = new BasicDiagnostic(Diagnostic.OK, - EEFRuntimeMessages.ComposedPropertiesEditionComponent_eef_validation_diagnostic, 0, - EEFRuntimeMessages.ComposedPropertiesEditionComponent_no_problem, null); - for (IPropertiesEditionComponent component : subComponents) { - Diagnostic validateValue = component.validateValue(event); - if (validateValue != null) - diagnostic.add(validateValue); - } - diagnostic.recomputeSeverity(); - return diagnostic; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validate() - */ - public Diagnostic validate() { - BasicDiagnostic diagnostic = new BasicDiagnostic(Diagnostic.OK, - EEFRuntimeMessages.ComposedPropertiesEditionComponent_eef_validation_diagnostic, Status.OK, - EEFRuntimeMessages.ComposedPropertiesEditionComponent_no_problem, null); - for (IPropertiesEditionComponent component : subComponents) { - diagnostic.getChildren().add(component.validate()); - } - return diagnostic; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#dispose() - */ - public void dispose() { - for (IPropertiesEditionComponent component : subComponents) { - component.dispose(); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#mustBeComposed(java.lang.Object, - * int) Very strange case ... shouldn't be invoke ... - */ - public boolean mustBeComposed(Object key, int kind) { - for (IPropertiesEditionComponent component : subComponents) { - if (!component.mustBeComposed(key, kind)) - return false; - } - return true; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#isRequired(java.lang.Object, - * int) - */ - public boolean isRequired(Object key, int kind) { - for (IPropertiesEditionComponent component : subComponents) { - if (component.isRequired(key, kind)) - return true; - } - return false; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#getHelpContent(java.lang.String, - * int) - */ - public String getHelpContent(Object key, int kind) { - for (IPropertiesEditionComponent component : subComponents) { - if (component.getHelpContent(key, kind) != StringTools.EMPTY_STRING) - return component.getHelpContent(key, kind); - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#translatePart(java.lang.String) - */ - public Object translatePart(String key) { - for (IPropertiesEditionComponent component : subComponents) { - if (component.translatePart(key) != null) - return component.translatePart(key); - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#setPropertiesEditionPart(java.lang.Object, - * int, org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - */ - public void setPropertiesEditionPart(Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - for (IPropertiesEditionComponent component : subComponents) { - component.setPropertiesEditionPart(key, kind, propertiesEditionPart); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#getTabText(java.lang.Object) - */ - public String getTabText(String key) { - for (IPropertiesEditionComponent component : subComponents) { - IPropertiesEditionPart part = component.getPropertiesEditionPart(0, key); - if (part != null) - return part.getTitle(); - } - return key; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#associatedFeature(java.lang.Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - for (IPropertiesEditionComponent component : subComponents) { - EStructuralFeature associatedFeature = component.associatedFeature(editorKey); - if (associatedFeature != null) - return associatedFeature; - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/SinglePartPropertiesEditingComponent.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/SinglePartPropertiesEditingComponent.java deleted file mode 100644 index f1596d819..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/SinglePartPropertiesEditingComponent.java +++ /dev/null @@ -1,257 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.components; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionComponentListener; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.context.ExtendedPropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.notify.EEFLockNotification; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionComponentListenerProviderService; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesEditionPartProviderService; - -/** - * @author Goulwen Le Fur - * @author Mikaël Barbero - */ -public abstract class SinglePartPropertiesEditingComponent extends StandardPropertiesEditionComponent { - - /** - * EObject to edit - */ - protected EObject semanticObject; - - /** - * Component's part - */ - protected IPropertiesEditionPart editingPart; - - /** - * Key to use to get the Part provider - */ - protected java.lang.Object repositoryKey; - - /** - * Key to use to get the Part - */ - protected java.lang.Object partKey; - - /** - * Default constructor - */ - public SinglePartPropertiesEditingComponent(PropertiesEditingContext editingContext, - EObject semanticObject, String editing_mode) { - this.semanticObject = semanticObject; - this.editingContext = editingContext; - if (IPropertiesEditionComponent.LIVE_MODE.equals(editing_mode)) { - semanticAdapter = initializeSemanticAdapter(); - } - this.editing_mode = editing_mode; - activate(); - } - - /** - * {@inheritDoc} - * - * @see IPropertiesEditionComponent#activate() - */ - public void activate() { - if (semanticAdapter != null) { - PropertiesEditingContext editingContext = getEditingContext(); - if (editingContext instanceof ExtendedPropertiesEditingContext) { - ((ExtendedPropertiesEditingContext)editingContext).getResourceSetAdapter().addEditingSemanticListener(semanticAdapter); - } - } - for (IPropertiesEditionComponentListener listener : PropertiesEditionComponentListenerProviderService.getInstance().getListeners()) { - listener.activate(this); - } - } - - /** - * {@inheritDoc} - * - * @see IPropertiesEditionComponent#deactivate() - */ - public void deactivate() { - if (semanticAdapter != null) { - PropertiesEditingContext editingContext = getEditingContext(); - if (editingContext instanceof ExtendedPropertiesEditingContext && ((ExtendedPropertiesEditingContext)editingContext).canReachResourceSetAdapter()) { - ((ExtendedPropertiesEditingContext)editingContext).getResourceSetAdapter().removeEditingSemanticListener(semanticAdapter); - } - } - for (IPropertiesEditionComponentListener listener : PropertiesEditionComponentListenerProviderService.getInstance().getListeners()) { - listener.deactivate(this); - } - } - - /** - * @return - */ - private String partID() { - return parts[0]; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#translatePart(java.lang.String) - */ - public java.lang.Object translatePart(String key) { - if (partID().equals(key)) - return partKey; - return super.translatePart(key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent# - * setPropertiesEditionPart(java.lang.Object, int, - * org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - */ - public void setPropertiesEditionPart(java.lang.Object key, int kind, - IPropertiesEditionPart propertiesEditionPart) { - if (key == partKey) { - this.editingPart = propertiesEditionPart; - if (semanticAdapter != null) - semanticAdapter.setPart(editingPart); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#shouldProcess(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - */ - protected boolean shouldProcess(IPropertiesEditionEvent event) { - if (event.getKind() == PropertiesEditionEvent.EDIT) { - return true; - } else { - if (event instanceof PropertiesEditionEvent && (!(event.getKind() == PropertiesEditionEvent.EDIT)) && associatedFeature(event.getAffectedEditor()) != null) { - Object currentValue = semanticObject.eGet(associatedFeature(event.getAffectedEditor())); - if (currentValue == null) { - return event.getNewValue() != null || event.getKind() == PropertiesEditionEvent.ADD; - } else { - if (event.getKind() == PropertiesEditionEvent.REMOVE) { - return ( - ((currentValue instanceof Collection) && ((Collection)currentValue).contains(event.getNewValue())) - || currentValue.equals(event.getNewValue()) - ); - } else { - return (currentValue != null && !currentValue.equals(event.getNewValue())); - } - } - } - } - return super.shouldProcess(event); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#getEditingContext() - */ - public PropertiesEditingContext getEditingContext() { - return editingContext; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#validate() - */ - public Diagnostic validate() { - Diagnostic validate = Diagnostic.OK_INSTANCE; - validate = EEFRuntimePlugin.getEEFValidator().validate(semanticObject); - return validate; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#dispose() - */ - public void dispose() { - deactivate(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#getPropertiesEditionPart - * (java.lang.String, java.lang.String) - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (semanticObject != null && partID().equals(key)) { - if (editingPart == null) { - IPropertiesEditionPartProvider provider = PropertiesEditionPartProviderService.getInstance() - .getProvider(repositoryKey); - if (provider != null) { - editingPart = provider.getPropertiesEditionPart(partKey, kind, this); - addListener((IPropertiesEditionListener)editingPart); - if (semanticAdapter != null) - semanticAdapter.setPart(editingPart); - } - } - return (IPropertiesEditionPart)editingPart; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#getTabText(java.lang.String) - */ - public String getTabText(String p_key) { - return editingPart.getTitle(); - } - - /** - * @param key - * of the editor to ckeck - * @return true is the editor is visible. - */ - public boolean isAccessible(Object key) { - if (editingPart != null && ((CompositePropertiesEditionPart)editingPart).getComposer() != null) { - return ((CompositePropertiesEditionPart)editingPart).getComposer().isVisible(key); - } - return false; - } - - @Override - public void updatePart(Notification msg) { - if (msg instanceof EEFLockNotification && editingPart instanceof CompositePropertiesEditionPart) { - ((CompositePropertiesEditionPart) editingPart).refresh(); - } - } - - /** - * @return IPropertiesEditionPart - */ - public IPropertiesEditionPart getEditingPart() { - return editingPart; - } - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/StandardPropertiesEditionComponent.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/StandardPropertiesEditionComponent.java deleted file mode 100644 index 737d740cb..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/components/StandardPropertiesEditionComponent.java +++ /dev/null @@ -1,403 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.components; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.core.runtime.jobs.Job; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.change.util.ChangeRecorder; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.api.notify.NotificationFilter; -import org.eclipse.emf.eef.runtime.api.notify.PropertiesEditingSemanticListener; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.command.StandardEditingCommand; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesValidationEditionEvent; -import org.eclipse.emf.eef.runtime.impl.utils.StringTools; - -/** - * @author Goulwen Le Fur - * @author Mikaël Barbero - */ -public abstract class StandardPropertiesEditionComponent implements IPropertiesEditionComponent { - - private static final long DELAY = 500L; - - public static final Object FIRE_PROPERTIES_CHANGED_JOB_FAMILY = new Object(); - - /** - * List of IPropertiesEditionComponentListeners - */ - private List listeners; - - /** - * the semantic listener dedicated to update view - */ - protected PropertiesEditingSemanticListener semanticAdapter; - - /** - * the editing domain where to perform live update - */ - protected EditingDomain liveEditingDomain; - - /** - * the job that will fire the property changed event - */ - protected FirePropertiesChangedJob firePropertiesChangedJob; - - /** - * Editing context - */ - protected PropertiesEditingContext editingContext; - - /** - * the editing mode - */ - protected String editing_mode; - - /** - * Is the component is current initializing - */ - protected boolean initializing = false; - - /** - * List of {@link IPropertiesEditionPart}'s key managed by the component. - */ - protected String[] parts; - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, - * int, org.eclipse.emf.ecore.EObject) - */ - public void initPart(Object key, int kind, EObject element) { - this.initPart(key, kind, element, editingContext.getResourceSet()); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#partsList() - */ - public String[] partsList() { - return parts; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#addListener(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener) - */ - public void addListener(IPropertiesEditionListener listener) { - if (listeners == null) - listeners = new ArrayList(); - listeners.add(listener); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#removeListener(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener) - */ - public void removeListener(IPropertiesEditionListener listener) { - if (listeners != null) - listeners.remove(listener); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#setLiveEditingDomain(org.eclipse.emf.edit.domain.EditingDomain) - */ - public void setLiveEditingDomain(EditingDomain editingDomain) { - this.liveEditingDomain = editingDomain; - } - - /** - * Initialize the semantic model listener for live editing mode - * - * @return the semantic model listener - */ - protected PropertiesEditingSemanticListener initializeSemanticAdapter() { - PropertiesEditingSemanticListener listener = new PropertiesEditingSemanticListener( - this, getNotificationFilters()) { - - @Override - public void runUpdateRunnable(Notification notification) { - if (getPart() != null && getPart().getFigure() != null - && !getPart().getFigure().isDisposed()) { - updatePart(notification); - } else { - dispose(); - } - } - }; - return listener; - } - - /** - * Returns the list of notification filters to use. - * - * @return the list of notification filters to use - */ - protected abstract NotificationFilter[] getNotificationFilters(); - - /** - * Update the part in response to a semantic event - * - * @param msg - * the semantic event - */ - public abstract void updatePart(Notification msg); - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - */ - private void propagateEvent(IPropertiesEditionEvent event) { - event.addHolder(this); - for (IPropertiesEditionListener listener : listeners) { - if (!event.hold(listener)) - listener.firePropertiesChanged(event); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - */ - public void firePropertiesChanged(final IPropertiesEditionEvent event) { - if (!isInitializing() && shouldProcess(event)) { - Diagnostic valueDiagnostic = validateValue(event); - if (valueDiagnostic.getSeverity() != Diagnostic.OK && valueDiagnostic instanceof BasicDiagnostic) - propagateEvent(new PropertiesValidationEditionEvent(event, valueDiagnostic)); - else { - editingContext.initializeRecorder(); - if (IPropertiesEditionComponent.BATCH_MODE.equals(editing_mode)) { - updateSemanticModel(event); - } else if (IPropertiesEditionComponent.LIVE_MODE.equals(editing_mode)) { - - switch (event.getKind()) { - case PropertiesEditionEvent.ADD: - case PropertiesEditionEvent.CHANGE: - case PropertiesEditionEvent.EDIT: - case PropertiesEditionEvent.REMOVE: - case PropertiesEditionEvent.MOVE: - case PropertiesEditionEvent.SET: - liveEditingDomain.getCommandStack().execute( - new StandardEditingCommand(new EObjectPropertiesEditionContext(editingContext, - this, editingContext.getEObject(), editingContext.getAdapterFactory())) { - - public void execute() { - updateSemanticModel(event); - ChangeRecorder changeRecorder = editingContext.getChangeRecorder(); - if (changeRecorder != null) { - description = changeRecorder.endRecording(); - editingContext.disposeRecorder(); - } - } - - }); - default: - break; - } - } - - Diagnostic validate = validate(); - propagateEvent(new PropertiesValidationEditionEvent(event, validate)); - } - propagateEvent(event); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#lazyFirePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - */ - public void delayedFirePropertiesChanged(IPropertiesEditionEvent event) { - if (IPropertiesEditionComponent.BATCH_MODE.equals(editing_mode)) { - firePropertiesChanged(event); - } else if (IPropertiesEditionComponent.LIVE_MODE.equals(editing_mode)) { - if (getFirePropertiesChangedJob().cancel()) { - getFirePropertiesChangedJob().setEvent(event); - getFirePropertiesChangedJob().schedule(DELAY); - } else { - try { - getFirePropertiesChangedJob().join(); - getFirePropertiesChangedJob().setEvent(event); - getFirePropertiesChangedJob().schedule(); - } catch (InterruptedException e) { - getFirePropertiesChangedJob().setEvent(null); - } - } - } - } - - protected FirePropertiesChangedJob getFirePropertiesChangedJob() { - if (firePropertiesChangedJob == null) { - firePropertiesChangedJob = new FirePropertiesChangedJob("Fire properties changed..."); - } - return firePropertiesChangedJob; - } - - protected class FirePropertiesChangedJob extends Job { - - private IPropertiesEditionEvent fEvent; - - public FirePropertiesChangedJob(String name) { - super(name); - } - - @Override - public boolean belongsTo(Object family) { - return family == FIRE_PROPERTIES_CHANGED_JOB_FAMILY; - } - - @Override - public boolean shouldSchedule() { - return fEvent != null; - } - - @Override - public boolean shouldRun() { - return fEvent != null; - } - - @Override - protected void canceling() { - super.canceling(); - fEvent = null; - } - - public void setEvent(IPropertiesEditionEvent event) { - fEvent = event; - } - - @Override - protected IStatus run(IProgressMonitor monitor) { - deactivate(); - firePropertiesChanged(fEvent); - activate(); - fEvent = null; - return Status.OK_STATUS; - } - } - - /** - * @param event - * event to process - * @return true if the event should really launch a command. - * @since 0.9 - */ - protected boolean shouldProcess(IPropertiesEditionEvent event) { - return false; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#associatedFeature(Object) - */ - public EStructuralFeature associatedFeature(Object editorKey) { - return null; - } - - /** - * Update the model in response to a view event - * - * @param event - * the view event - */ - public abstract void updateSemanticModel(IPropertiesEditionEvent event); - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#mustBeComposed(java.lang.Object, - * int) - */ - public boolean mustBeComposed(Object key, int kind) { - return true; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#isRequired(java.lang.String, - * int) - */ - public boolean isRequired(Object key, int kind) { - return false; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#getHelpContent(java.lang.String, - * int) - */ - public String getHelpContent(Object key, int kind) { - return StringTools.EMPTY_STRING; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#translatePart(java.lang.String) - */ - public Object translatePart(String key) { - return null; - } - - /** - * @return the initializing - */ - public boolean isInitializing() { - return initializing; - } - - /** - * @param initializing - * the initializing to set - */ - public void setInitializing(boolean initializing) { - this.initializing = initializing; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#setPropertiesEditionPart(java.lang.Object, - * int, org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart) - */ - public void setPropertiesEditionPart(Object key, int kind, IPropertiesEditionPart propertiesEditionPart) { - // Default case : nothing to do - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/EObjectFilter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/EObjectFilter.java deleted file mode 100644 index c6fb771bc..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/EObjectFilter.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.filters; - -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - -/** - * Provide a generic filter, it returns the exact elements and the containers of elements of the given - * type. - * - * @author Jerome Benois - * @author Stephane Bouchet - */ -public class EObjectFilter extends ViewerFilter { - - protected EClass eClassToFilter; - - /** - * @param eClassToFilter - * the type use to filter elements - */ - public EObjectFilter(EClass eClassToFilter) { - this.eClassToFilter = eClassToFilter; - } - - @Override - public boolean select(Viewer viewer, Object parentElement, Object element) { - // this is a resource display it only if it contains a given type - if (element instanceof Resource) { - TreeIterator iter = (((Resource)element)).getAllContents(); - while (iter.hasNext()) { - if (EEFUtils.containsInstanceOfEClass(iter.next(), eClassToFilter)) - return true; - } - } - if (element instanceof EObject) { - EObject eObject = (EObject)element; - return EEFUtils.containsInstanceOfEClass(eObject, eClassToFilter); - } - return false; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/EObjectStrictFilter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/EObjectStrictFilter.java deleted file mode 100644 index 7de256e56..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/EObjectStrictFilter.java +++ /dev/null @@ -1,44 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.filters; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - -/** - * Provide a generic filter, it returns the exact elements and the containers of elements of the given - * type. - * - * @author Goulwen Le Fur - */ -public class EObjectStrictFilter extends ViewerFilter { - - protected EClass eClassToFilter; - - /** - * @param eClassToFilter - * the type use to filter elements - */ - public EObjectStrictFilter(EClass eClassToFilter) { - this.eClassToFilter = eClassToFilter; - } - - @Override - public boolean select(Viewer viewer, Object parentElement, Object element) { - if (element instanceof EObject) - return eClassToFilter.isInstance(element); - else - return true; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/BusinessViewerFilter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/BusinessViewerFilter.java deleted file mode 100644 index 86f227e63..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/BusinessViewerFilter.java +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.filters.business; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.jface.viewers.ViewerFilter; - -/** - * Filter for business rules - * - * @author Nathalie Lepine - */ -public abstract class BusinessViewerFilter extends ViewerFilter { - - /** - * the name - */ - protected String name; - - /** - * the description - */ - protected String description; - - /** - * current object on which the filter is applicated - */ - protected EObject current; - - /** - * empty line or not - */ - protected boolean nullable; - - /** - * @param eObject - * @param nullable - */ - public BusinessViewerFilter(EObject eObject, boolean nullable) { - super(); - this.current = eObject; - this.nullable = nullable; - } - - - /** - * @param eObject - * @param name - */ - public BusinessViewerFilter(EObject eObject, String name, boolean nullable) { - super(); - this.name = name; - this.current = eObject; - this.nullable = nullable; - } - - /** - * @param eObject - * @param name - * @param description - */ - public BusinessViewerFilter(EObject eObject, String name, String description, boolean nullable) { - super(); - this.name = name; - this.description = description; - this.current = eObject; - this.nullable = nullable; - } - - /** - * @return description - */ - public String getDescription() { - return description; - } - - /** - * @return name - */ - public String getName() { - return name; - } - - /** - * @return current object - */ - public EObject getCurrent() { - return current; - } - - /** - * @return if it is nullable - */ - public boolean isNullable() { - return nullable; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/CurrentModelViewerFilter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/CurrentModelViewerFilter.java deleted file mode 100644 index 9c17c2553..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/CurrentModelViewerFilter.java +++ /dev/null @@ -1,61 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.filters.business; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesContextService; -import org.eclipse.emf.eef.runtime.impl.utils.EEFRuntimeMessages; -import org.eclipse.jface.viewers.Viewer; - -/** - * Filter which returns elements of the current model - * - * @author Nathalie Lepine - */ -public class CurrentModelViewerFilter extends BusinessViewerFilter { - - /** - * @param current - * @param nullable - */ - public CurrentModelViewerFilter(EObject current, boolean nullable) { - super(current, nullable); - name = EEFRuntimeMessages.CurrentModelViewerFilter_name; - } - - /* - * (non-Javadoc) - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers .Viewer, java.lang.Object, - * java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - if (nullable && element instanceof String && element.equals("")) //$NON-NLS-1$ - return true; - if (current.eResource() != null) - return (element instanceof EObject && ((EObject)element).eResource() != null && current - .eResource().equals(((EObject)element).eResource())); - else if (PropertiesContextService.getInstance().entryPointElement().eResource() != null) { - return (element instanceof EObject && ((EObject)element).eResource() != null && PropertiesContextService - .getInstance().entryPointElement().eResource().getURI() - .equals(((EObject)element).eResource().getURI())); - } else - return true; - - } - - /** - * @param current - */ - public void setCurrent(EObject current) { - this.current = current; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/ReferencedModelsViewerFilter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/ReferencedModelsViewerFilter.java deleted file mode 100644 index bec50907f..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/filters/business/ReferencedModelsViewerFilter.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.filters.business; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesContextService; -import org.eclipse.emf.eef.runtime.impl.utils.EEFRuntimeMessages; -import org.eclipse.jface.viewers.Viewer; - -/** - * Filter which returns elements of referenced models - * - * @author Nathalie Lepine - */ -public class ReferencedModelsViewerFilter extends BusinessViewerFilter { - - /** - * @param eObject - * @param nullable - */ - public ReferencedModelsViewerFilter(EObject eObject, boolean nullable) { - super(eObject, nullable); - name = EEFRuntimeMessages.ReferencedModelsViewerFilter_name; - } - - /* - * (non-Javadoc) - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers .Viewer, java.lang.Object, - * java.lang.Object) - */ - public boolean select(Viewer viewer, Object parentElement, Object element) { - if (nullable && element instanceof String && element.equals("")) //$NON-NLS-1$ - return true; - if (current.eResource() != null) - return (element instanceof EObject && ((EObject)element).eResource() != null && !current - .eResource().equals(((EObject)element).eResource())); - else if (PropertiesContextService.getInstance().entryPointElement().eResource() != null) - return (element instanceof EObject && ((EObject)element).eResource() != null && !PropertiesContextService - .getInstance().entryPointElement().eResource().getURI() - .equals(((EObject)element).eResource().getURI())); - else - return true; - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/EEFLockNotification.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/EEFLockNotification.java deleted file mode 100644 index ee44c2bec..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/EEFLockNotification.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.notify; - -import org.eclipse.emf.common.notify.impl.NotificationImpl; -import org.eclipse.emf.ecore.EObject; - -/** - * @author Nathalie Lepine - * - */ -public class EEFLockNotification extends NotificationImpl { - - public EEFLockNotification(EObject value) { - super(-1, value, value); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/PropertiesEditionEvent.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/PropertiesEditionEvent.java deleted file mode 100644 index 4908af061..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/PropertiesEditionEvent.java +++ /dev/null @@ -1,187 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.notify; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; - -/** - * @author Goulwen Le Fur - */ -public class PropertiesEditionEvent implements IPropertiesEditionEvent { - - /** - * Describe an event that just change the view state - */ - public static final int CHANGE = 0; - - /** - * Describe an event that change the model - */ - public static final int COMMIT = 1; - - /** - * A value has been set - */ - public static final int SET = 1; - - /** - * A value has been unset - */ - public static final int UNSET = 2; - - /** - * A value has been added - */ - public static final int ADD = 3; - - /** - * A value has been removed - */ - public static final int REMOVE = 4; - - /** - * A value has been moved - */ - public static final int MOVE = 7; - - /** - * The selection of a ElementEditor has changed - */ - public static final int SELECTION_CHANGED = 8; - - /** - * A value has been edited - */ - public static final int EDIT = 9; - - /** - * The focus of a ElementEditor has changed - */ - public static final int FOCUS_CHANGED = 10; - - /** - * The focus of a ElementEditor has changed - */ - public static final int FOCUS_LOST = 11; - - /** - * The focus of a ElementEditor has changed - */ - public static final int FOCUS_GAINED = 12; - - protected String affectedEditor; - - protected Object oldValue; - - protected Object newValue; - - protected List holders; - - protected int kind; - - protected int state; - - protected int newIndex; - - /** - * @param holdedNotification - * @param holder - */ - public PropertiesEditionEvent(IPropertiesEditionListener holder, String affectedEditor, int state, - int kind, Object oldValue, Object newValue) { - this.affectedEditor = affectedEditor; - this.oldValue = oldValue; - this.newValue = newValue; - this.state = state; - this.kind = kind; - holders = new ArrayList(); - holders.add(holder); - } - - /** - * @param holdedNotification - * @param holder - */ - public PropertiesEditionEvent(IPropertiesEditionListener holder, String affectedEditor, int state, - int kind, Object newValue, int newIndex) { - this(holder, affectedEditor, state, kind, null, newValue); - this.newIndex = newIndex; - } - - /** - * @param newHolder - */ - public void addHolder(IPropertiesEditionListener newHolder) { - holders.add(newHolder); - } - - /** - * @param toTest - * @return - */ - public boolean hold(IPropertiesEditionListener toTest) { - return holders.contains(toTest); - } - - /** - * @return the changedEditor - */ - public Object getAffectedEditor() { - return affectedEditor; - } - - /** - * @return the oldValue - */ - public Object getOldValue() { - return oldValue; - } - - /** - * @return the newValue - */ - public Object getNewValue() { - return newValue; - } - - /** - * @return the newIndex - */ - public int getNewIndex() { - return newIndex; - } - - /** - * @return the holders - */ - public List getHolders() { - return holders; - } - - /** - * @return the state - */ - public int getState() { - return state; - } - - /** - * @return the kind - */ - public int getKind() { - return kind; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/PropertiesValidationEditionEvent.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/PropertiesValidationEditionEvent.java deleted file mode 100644 index 677175ed6..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/notify/PropertiesValidationEditionEvent.java +++ /dev/null @@ -1,113 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.notify; - -import java.util.List; - -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; - -/** - * @author Stephane Bouchet - */ -public class PropertiesValidationEditionEvent implements IPropertiesEditionEvent { - - private IPropertiesEditionEvent event; - - private Diagnostic diagnostic; - - /** - * @return the diagnostic - */ - public Diagnostic getDiagnostic() { - return diagnostic; - } - - public PropertiesValidationEditionEvent(IPropertiesEditionEvent event, Diagnostic diag) { - this.event = event; - this.diagnostic = diag; - } - - /** - * @param newHolder - * @see org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent#addHolder(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener) - */ - public void addHolder(IPropertiesEditionListener newHolder) { - event.addHolder(newHolder); - } - - /** - * @return - * @see org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent#getAffectedEditor() - */ - public Object getAffectedEditor() { - return event.getAffectedEditor(); - } - - /** - * @return - * @see org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent#getHolders() - */ - public List getHolders() { - return event.getHolders(); - } - - /** - * @return - * @see org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent#getKind() - */ - public int getKind() { - return event.getKind(); - } - - /** - * @return - * @see org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent#getNewIndex() - */ - public int getNewIndex() { - return event.getNewIndex(); - } - - /** - * @return - * @see org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent#getNewValue() - */ - public Object getNewValue() { - return event.getNewValue(); - } - - /** - * @return - * @see org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent#getOldValue() - */ - public Object getOldValue() { - return event.getOldValue(); - } - - /** - * @return - * @see org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent#getState() - */ - public int getState() { - return event.getState(); - } - - /** - * @param toTest - * @return - * @see org.eclipse.emf.eef.runtime.impl.notify.PropertiesEditionEvent#hold(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener) - */ - public boolean hold(IPropertiesEditionListener toTest) { - return event.hold(toTest); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/operation/WizardEditingOperation.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/operation/WizardEditingOperation.java deleted file mode 100644 index efff171fa..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/operation/WizardEditingOperation.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.operation; - -import org.eclipse.core.commands.ExecutionException; -import org.eclipse.core.runtime.IAdaptable; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.services.WizardOpeningPolicyProviderService; -import org.eclipse.emf.eef.runtime.ui.wizards.IWizardOpeningPolicy; -import org.eclipse.emf.eef.runtime.ui.wizards.PropertiesEditionWizard; -import org.eclipse.emf.transaction.TransactionalEditingDomain; -import org.eclipse.emf.workspace.AbstractEMFOperation; - -/** - * @author glefur - */ -public class WizardEditingOperation extends AbstractEMFOperation { - - protected PropertiesEditingContext editingContext; - - /** - * @param domain - * @param label - */ - public WizardEditingOperation(DomainPropertiesEditionContext editingContext) { - super((TransactionalEditingDomain)editingContext.getEditingDomain(), "EEF Editing Operaiton"); - this.editingContext = editingContext; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.workspace.AbstractEMFOperation#doExecute(org.eclipse.core.runtime.IProgressMonitor, - * org.eclipse.core.runtime.IAdaptable) - */ - protected IStatus doExecute(IProgressMonitor monitor, IAdaptable info) throws ExecutionException { - PropertiesEditionWizard wizard = new PropertiesEditionWizard(editingContext, - editingContext.getAdapterFactory(), editingContext.getEObject()); - IWizardOpeningPolicy wizardOpeningPolicy = WizardOpeningPolicyProviderService.provide(editingContext.getEObject()); - boolean open = wizardOpeningPolicy.openWizard(editingContext, wizard); - if (open) { - return Status.OK_STATUS; - } else { - return Status.CANCEL_STATUS; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/parts/CompositePropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/parts/CompositePropertiesEditionPart.java deleted file mode 100644 index 8f7caba51..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/parts/CompositePropertiesEditionPart.java +++ /dev/null @@ -1,283 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.parts; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.providers.IReadOnlyPolicy; -import org.eclipse.emf.eef.runtime.context.ExtendedPropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.services.ReadOnlyPolicyProviderService; -import org.eclipse.emf.eef.runtime.ui.parts.PartComposer; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFEditorSettings; -import org.eclipse.jface.databinding.swt.ISWTObservableValue; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Label; -import org.eclipse.ui.views.properties.tabbed.AbstractPropertySection; - -/** - * A standard implementation of the {@link IPropertiesEditionPart} by a SWT {@link Composite}. - * - * @author Goulwen Le Fur - */ -public abstract class CompositePropertiesEditionPart implements IPropertiesEditionPart { - - /** - * The component that manage this part. - */ - protected IPropertiesEditionComponent propertiesEditionComponent; - - /** - * The part view. - */ - protected Composite view; - - /** - * Helper to use to create the part. - */ - protected PartComposer composer; - - /** - * The adapter factory. - */ - protected AdapterFactory adapterFactory; - - /** - * The edited element - */ - protected EObject current; - - /** - * the current ResourceSet - */ - protected ResourceSet resourceSet; - - /** - * Defines if part has changed - */ - protected boolean partHasChanged = false; - - /** - * Defines the part visibility. - */ - protected boolean visibility = true; - - /** - * EEF editor settings to use. - */ - private List settings; - - /** - * For {@link AbstractPropertySection} use only. Do not use with PropertiesEditingViewer. - */ - protected CompositePropertiesEditionPart() { - super(); - this.settings = new ArrayList(); - } - - /** - * Parameterized constructeur. - * - * @param editionComponent - * the component that manage this part - */ - public CompositePropertiesEditionPart(IPropertiesEditionComponent editionComponent) { - this.propertiesEditionComponent = editionComponent; - this.adapterFactory = propertiesEditionComponent.getEditingContext().getAdapterFactory(); - this.settings = new ArrayList(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#setContext(org.eclipse.emf.ecore.EObject, - * org.eclipse.emf.ecore.resource.ResourceSet) - */ - public void setContext(EObject eObject, ResourceSet allResources) { - this.current = eObject; - this.resourceSet = allResources; - } - - /** - * Getter for the view - * - * @return the part view - */ - public Composite getFigure() { - return view; - } - - /** - * @return the composer - */ - public PartComposer getComposer() { - return composer; - } - - /** - * @param event - */ - public void handleNotificationEvent(Notification event) { - partHasChanged = true; - } - - /** - * Return true if part has changed - * - * @return the hasChanged - */ - public boolean hasChanged() { - return partHasChanged; - } - - /** - * @param partHasChanged - * the partHasChanged to set - */ - protected void setHasChanged(boolean partHasChanged) { - this.partHasChanged = partHasChanged; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getObserver(java.lang.String) - */ - public ISWTObservableValue getObserver(String key) { - return null; - } - - /** - * Refresh the part - */ - public void refresh() { - if (!view.isDisposed()) { - clear(); - composer.compose(view); - view.layout(); - } - } - - /** - * Clear all the graphical elements of the view - */ - protected void clear() { - if (!view.isDisposed()) { - while (view.getChildren().length > 0) { - Control next = view.getChildren()[0]; - next.dispose(); - } - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#isVisible() - */ - public boolean isVisible() { - return visibility; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#setVisible(boolean) - */ - public void setVisible(boolean visibility) { - this.visibility = visibility; - } - - /** - * @param parent - * label container - * @param editor - * key of the editor - * @param alternate - * text to display if no information can be found - * @return created label. - */ - protected String getDescription(Object editor, String alternate) { - if (propertiesEditionComponent.getEditingContext() instanceof ExtendedPropertiesEditingContext) { - return ((ExtendedPropertiesEditingContext)propertiesEditionComponent.getEditingContext()) - .getHelper().getDescription(editor, alternate); - } else { - return alternate; - } - } - - /** - * @param parent - * label container - * @param editor - * key of the editor - * @param alternate - * text to display if no information can be found - * @return created label. - */ - protected Label createDescription(Composite parent, Object editor, String alternate) { - if (propertiesEditionComponent.getEditingContext() instanceof ExtendedPropertiesEditingContext) { - return ((ExtendedPropertiesEditingContext)propertiesEditionComponent.getEditingContext()) - .getHelper().createLabel(parent, editor, alternate); - } else { - return SWTUtils.createPartLabel(parent, alternate, - propertiesEditionComponent.isRequired(editor, 0)); - } - } - - /** - * @param editorKey - * EditorKey - * - * @return if the widget is read only - */ - public boolean isReadOnly(Object editorKey, EObject context) { - EObject eObject = context; - if (eObject == null) { - eObject = propertiesEditionComponent.getEditingContext().getEObject(); - } - - if (eObject != null) { - List policies = ReadOnlyPolicyProviderService.getInstance().getPolicies(); - for (IReadOnlyPolicy iReadOnlyPolicy : policies) { - if (iReadOnlyPolicy.isReadOnly(eObject, propertiesEditionComponent.associatedFeature(editorKey))) { - return true; - } - } - } - return false; - } - - /** - * @param editorKey - * EditorKey - * - * @return if the widget is read only - */ - public boolean isReadOnly(Object editorKey) { - return isReadOnly(editorKey, null); - } - - /** - * @return the settings to use. - */ - public List getSettings() { - return settings; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/parts/NullCompositePropertiesEditionPart.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/parts/NullCompositePropertiesEditionPart.java deleted file mode 100644 index 0e340845c..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/parts/NullCompositePropertiesEditionPart.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.parts; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.swt.SWT; -import org.eclipse.swt.widgets.Composite; - -/** - * A "Null Object" implementation for the {@link CompositePropertiesEditionPart} . - * - * @author Goulwen Le Fur - */ -public class NullCompositePropertiesEditionPart extends CompositePropertiesEditionPart { - - /** - * Default constructor. - * - * @param editionComponent - * the edition component. - */ - public NullCompositePropertiesEditionPart(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart#createFigure(org.eclipse.swt.widgets.Composite) - */ - public Composite createFigure(Composite parent) { - return new Composite(parent, SWT.NONE); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart#initComponent(org.eclipse.emf.ecore.EObject) - */ - public void initComponent(EObject eObject) { - // nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener#firePropertiesChanged(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) - */ - public void firePropertiesChanged(IPropertiesEditionEvent event) { - // nothing - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#requiredFeaturesNotEmpty() - */ - public List requiredFeaturesNotEmpty() { - // Nothing to do - return new ArrayList(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#typeValidation() - */ - public List typeValidation() { - // Nothing to do - return new ArrayList(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#getTitle() - */ - public String getTitle() { - return ""; //$NON-NLS-1$ - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#isVisible() - */ - public boolean isVisible() { - return false; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart#setVisible(boolean) - */ - public void setVisible(boolean visibility) { - - } - - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/providers/ComposedPropertiesEditionProvider.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/providers/ComposedPropertiesEditionProvider.java deleted file mode 100644 index 26f17a799..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/providers/ComposedPropertiesEditionProvider.java +++ /dev/null @@ -1,161 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.providers; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; -import org.eclipse.emf.eef.runtime.providers.impl.PropertiesEditingProviderImpl; - -/** - * An implementation of {@link PropertiesEditingProvider} composing several {@link PropertiesEditingProvider}. - * - * @author Goulwen Le Fur - */ -public class ComposedPropertiesEditionProvider extends PropertiesEditingProviderImpl { - - /** - * The managed providers. - */ - private List editPropertiesProviders; - - /** - * Default constructor. - */ - public ComposedPropertiesEditionProvider() { - editPropertiesProviders = new ArrayList(); - } - - /** - * Constructor with initialized providers. - * - * @param editPropertiesProviders - * the initialized providers - */ - public ComposedPropertiesEditionProvider(List editPropertiesProviders) { - this.editPropertiesProviders = editPropertiesProviders; - } - - /** - * Append a IEditPropertiesProvider to the list - * - * @param editPropertiesProvider - * the IEditPropertiesProvider to add - */ - public void append(PropertiesEditingProvider editPropertiesProvider) { - editPropertiesProviders.add(editPropertiesProvider); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - */ - public boolean provides(PropertiesEditingContext editingContext) { - for (PropertiesEditingProvider editPropertiesProvider : editPropertiesProviders) { - if (editPropertiesProvider.provides(editingContext)) - return true; - } - return false; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, - * java.lang.String) - */ - public boolean provides(PropertiesEditingContext editingContext, String part) { - for (PropertiesEditingProvider editPropertiesProvider : editPropertiesProviders) { - if (editPropertiesProvider.provides(editingContext, part)) - return true; - } - return false; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, - * java.lang.Class) - */ - public boolean provides(PropertiesEditingContext editingContext, Class refinement) { - for (PropertiesEditingProvider editPropertiesProvider : editPropertiesProviders) { - if (editPropertiesProvider.provides(editingContext, refinement)) - return true; - } - return false; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#provides(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, - * java.lang.String, java.lang.Class) - */ - public boolean provides(PropertiesEditingContext editingContext, String part, Class refinement) { - for (PropertiesEditingProvider editPropertiesProvider : editPropertiesProviders) { - if (editPropertiesProvider.provides(editingContext, part, refinement)) - return true; - } - return false; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, - * java.lang.String) - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, - String mode) { - for (PropertiesEditingProvider editPropertiesProvider : editPropertiesProviders) { - if (editPropertiesProvider.provides(editingContext)) - return editPropertiesProvider.getPropertiesEditingComponent(editingContext, mode); - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, - * java.lang.String, java.lang.String) - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, - String mode, String part) { - for (PropertiesEditingProvider editPropertiesProvider : editPropertiesProviders) { - if (editPropertiesProvider.provides(editingContext, part)) - return editPropertiesProvider.getPropertiesEditingComponent(editingContext, mode, part); - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, - * java.lang.String, java.lang.String, java.lang.Class) - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, - String mode, String part, Class refinement) { - for (PropertiesEditingProvider editPropertiesProvider : editPropertiesProviders) { - if (editPropertiesProvider.provides(editingContext, part, refinement)) - return editPropertiesProvider.getPropertiesEditingComponent(editingContext, mode, part, - refinement); - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/providers/StandardPropertiesEditionPartProviderFactory.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/providers/StandardPropertiesEditionPartProviderFactory.java deleted file mode 100644 index 87199d539..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/providers/StandardPropertiesEditionPartProviderFactory.java +++ /dev/null @@ -1,71 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.providers; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProviderFactory; - -/** - * @author Goulwen Le Fur - */ -public class StandardPropertiesEditionPartProviderFactory implements IPropertiesEditionPartProviderFactory { - - /** - * List of managed providers. - */ - private List editPropertiesPartProviders; - - /** - * Default constructor. - */ - public StandardPropertiesEditionPartProviderFactory() { - editPropertiesPartProviders = new ArrayList(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProviderFactory#getProvider(java.lang.Object) - */ - public IPropertiesEditionPartProvider getProvider(Object key) { - for (IPropertiesEditionPartProvider editPropertiesPartProvider : editPropertiesPartProviders) { - if (editPropertiesPartProvider.provides(key)) - return editPropertiesPartProvider; - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProviderFactory#provides(java.lang.Object) - */ - public boolean provides(Object key) { - for (IPropertiesEditionPartProvider editPropertiesPartProvider : editPropertiesPartProviders) { - if (editPropertiesPartProvider.provides(key)) - return true; - } - return false; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProviderFactory#register(org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider) - */ - public void register(IPropertiesEditionPartProvider editPropertiesPartProvider) { - editPropertiesPartProviders.add(editPropertiesPartProvider); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/LockPolicyProviderService.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/LockPolicyProviderService.java deleted file mode 100644 index 35dc1e5d7..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/LockPolicyProviderService.java +++ /dev/null @@ -1,117 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.services; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IConfigurationElement; -import org.eclipse.core.runtime.IExtension; -import org.eclipse.core.runtime.IExtensionPoint; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.policies.ILockPolicy; - -/** - * Service that manage all the registered {@link ILockPolicy}. - * - * @author Nathalie Lepine - */ -public class LockPolicyProviderService { - - /** - * The extension name. - */ - public static final String EXTENSION_NAME = "LockPolicyProvider"; //$NON-NLS-1$ - - /** - * The extension's element name. - */ - private static final String EXTENSION_ELEMENT_NAME = "LockPolicyProvider"; //$NON-NLS-1$ - - /** - * The element's attribute name. - */ - private static final String EXTENSION_ATTRIBUTE_NAME = "policyClass"; //$NON-NLS-1$ - - /** - * A singleton for the service. - */ - private static LockPolicyProviderService instance = new LockPolicyProviderService(); - - /** - * The factory where the providers are registered. - */ - private List lockPolicies; - - /** - * Default constructor. - */ - private LockPolicyProviderService() { - lockPolicies = new ArrayList(); - configureService(); - } - - /** - * Singleton constructor. - * - * @return the Singleton instance - */ - public static LockPolicyProviderService getInstance() { - return instance; - } - - /** - * @return all the registered policies - */ - public List getPolicies() { - return lockPolicies; - } - - - /** - * Register a policy. - * - * @param lockPolicy LockPolicy - */ - public void register(ILockPolicy lockPolicy) { - lockPolicies.add(lockPolicy); - } - - /** - * Load all the providers registered by extension point. - */ - private void configureService() { - IExtensionPoint extensionPoint = Platform.getExtensionRegistry().getExtensionPoint( - EEFRuntimePlugin.PLUGIN_ID, EXTENSION_NAME); - - IExtension[] extensions = extensionPoint.getExtensions(); - for (int extensionIndex = 0; extensionIndex < extensions.length; extensionIndex++) { - IExtension extension = extensions[extensionIndex]; - IConfigurationElement[] configurationElements = extension.getConfigurationElements(); - for (int i = 0; i < configurationElements.length; i++) { - IConfigurationElement cfg = configurationElements[i]; - - if (EXTENSION_ELEMENT_NAME.equals(cfg.getName())) { - try { - register((ILockPolicy)cfg - .createExecutableExtension(EXTENSION_ATTRIBUTE_NAME)); - } catch (CoreException e) { - e.printStackTrace(); - } - } - } - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesContextService.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesContextService.java deleted file mode 100644 index 68f2dbb37..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesContextService.java +++ /dev/null @@ -1,145 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.services; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.Stack; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.context.ContextEntry; - -/** - * A service to store edition context - * - * @author Goulwen Le Fur - */ -public class PropertiesContextService { - - /** - * The navigation stack. - */ - private Stack navigationStack; - - /** - * A singleton for the service. - */ - private static PropertiesContextService contextService = new PropertiesContextService(); - - /** - * Default constructor. - */ - private PropertiesContextService() { - super(); - navigationStack = new Stack(); - } - - /** - * Singleton constructor. - * - * @return the contextService - */ - public static PropertiesContextService getInstance() { - return contextService; - } - - /** - * Push a new {@link ContextEntry} in the navigation stack. - * - * @param element - * the edited element - * @param component - * the component that edit this element - */ - public void push(EObject element, IPropertiesEditionComponent component) { - navigationStack.push(new ContextEntry(element, component)); - } - - /** - * Pop the last {@link ContextEntry} - */ - public void pop() { - if (!navigationStack.empty()) - navigationStack.pop(); - } - - /** - * Returns the first edited element in this edition context. - * - * @return the first edited element - */ - public EObject entryPointElement() { - if (!navigationStack.isEmpty()) - return navigationStack.get(0).getElement(); - return null; - } - - /** - * Returns the first edition component in this edition context. - * - * @return the first editon component - */ - public IPropertiesEditionComponent entryPointComponent() { - if (!navigationStack.isEmpty()) - return navigationStack.get(0).getPropertiesEditionComponent(); - return null; - } - - /** - * Returns the last edited element in this edition context. - * - * @return the last edited component - */ - public EObject lastElement() { - if (!navigationStack.isEmpty()) - return navigationStack.peek().getElement(); - return null; - } - - /** - * Returns the last edition component in this edition context. - * - * @return the last editon component - */ - public IPropertiesEditionComponent lastComponent() { - if (!navigationStack.isEmpty()) - return navigationStack.peek().getPropertiesEditionComponent(); - return null; - } - - /** - * Returns a list of all edition component of the specified kind in the context. - * - * @param kind - * the searched kind of edition component - * @return all the corresponding edition component in the context - */ - public List getComponentsInContext(Class kind) { - List result = new ArrayList(); - for (ContextEntry entry : navigationStack) { - if (entry.getPropertiesEditionComponent().getClass().equals(kind)) - result.add(0, entry.getPropertiesEditionComponent()); - } - return result; - } - - /** - * Return an {@link Iterator} on the navigation stack. - * - * @return an {@link Iterator} on the navigation stack - */ - public Iterator iterator() { - return navigationStack.iterator(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesEditionComponentListenerProviderService.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesEditionComponentListenerProviderService.java deleted file mode 100644 index d867e1ae2..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesEditionComponentListenerProviderService.java +++ /dev/null @@ -1,117 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.services; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IConfigurationElement; -import org.eclipse.core.runtime.IExtension; -import org.eclipse.core.runtime.IExtensionPoint; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionComponentListener; - -/** - * Service that manage all the registered {@link IPropertiesEditionComponentListener}. - * - * @author Nathalie Lepine - */ -public class PropertiesEditionComponentListenerProviderService { - - /** - * The extension name. - */ - public static final String EXTENSION_NAME = "PropertiesEditionComponentListenerProvider"; //$NON-NLS-1$ - - /** - * The extension's element name. - */ - private static final String EXTENSION_ELEMENT_NAME = "PropertiesEditionComponentListenerProvider"; //$NON-NLS-1$ - - /** - * The element's attribute name. - */ - private static final String EXTENSION_ATTRIBUTE_NAME = "listenerClass"; //$NON-NLS-1$ - - /** - * A singleton for the service. - */ - private static PropertiesEditionComponentListenerProviderService instance = new PropertiesEditionComponentListenerProviderService(); - - /** - * The factory where the providers are registered. - */ - private List pecListeners; - - /** - * Default constructor. - */ - private PropertiesEditionComponentListenerProviderService() { - pecListeners = new ArrayList(); - configureService(); - } - - /** - * Singleton constructor. - * - * @return the Singleton instance - */ - public static PropertiesEditionComponentListenerProviderService getInstance() { - return instance; - } - - /** - * @return all the registered policies - */ - public List getListeners() { - return pecListeners; - } - - - /** - * Register a listener. - * - * @param pecListener IPropertiesEditionComponentListener - */ - public void register(IPropertiesEditionComponentListener pecListener) { - pecListeners.add(pecListener); - } - - /** - * Load all the providers registered by extension point. - */ - private void configureService() { - IExtensionPoint extensionPoint = Platform.getExtensionRegistry().getExtensionPoint( - EEFRuntimePlugin.PLUGIN_ID, EXTENSION_NAME); - - IExtension[] extensions = extensionPoint.getExtensions(); - for (int extensionIndex = 0; extensionIndex < extensions.length; extensionIndex++) { - IExtension extension = extensions[extensionIndex]; - IConfigurationElement[] configurationElements = extension.getConfigurationElements(); - for (int i = 0; i < configurationElements.length; i++) { - IConfigurationElement cfg = configurationElements[i]; - - if (EXTENSION_ELEMENT_NAME.equals(cfg.getName())) { - try { - register((IPropertiesEditionComponentListener)cfg - .createExecutableExtension(EXTENSION_ATTRIBUTE_NAME)); - } catch (CoreException e) { - e.printStackTrace(); - } - } - } - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesEditionPartProviderService.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesEditionPartProviderService.java deleted file mode 100644 index d084cb23d..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/PropertiesEditionPartProviderService.java +++ /dev/null @@ -1,126 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.services; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IConfigurationElement; -import org.eclipse.core.runtime.IExtension; -import org.eclipse.core.runtime.IExtensionPoint; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider; -import org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProviderFactory; -import org.eclipse.emf.eef.runtime.impl.providers.StandardPropertiesEditionPartProviderFactory; - -/** - * Service that manage all the registered {@link IPropertiesEditionPartProviderFactory}. - * - * @author Goulwen Le Fur - */ -public class PropertiesEditionPartProviderService implements IPropertiesEditionPartProviderFactory { - - /** - * The extension name. - */ - public static final String EXTENSION_NAME = "PropertiesEditionPartProvider"; //$NON-NLS-1$ - - /** - * The extension's element name. - */ - private static final String EXTENSION_ELEMENT_NAME = "PropertiesEditionPartProvider"; //$NON-NLS-1$ - - /** - * The element's attribute name. - */ - private static final String EXTENSION_ATTRIBUTE_NAME = "providerClass"; //$NON-NLS-1$ - - /** - * A singleton for the service. - */ - private static PropertiesEditionPartProviderService instance = new PropertiesEditionPartProviderService(); - - /** - * The factory where the providers are registered. - */ - private IPropertiesEditionPartProviderFactory editPropertiesPartProviderFactory; - - /** - * Default constructor. - */ - private PropertiesEditionPartProviderService() { - editPropertiesPartProviderFactory = new StandardPropertiesEditionPartProviderFactory(); - configureService(); - } - - /** - * Singleton constructor. - * - * @return the Singleton instance - */ - public static PropertiesEditionPartProviderService getInstance() { - return instance; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProviderFactory#getProvider(java.lang.Object) - */ - public IPropertiesEditionPartProvider getProvider(Object key) { - return editPropertiesPartProviderFactory.getProvider(key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProviderFactory#provides(java.lang.Object) - */ - public boolean provides(Object key) { - return editPropertiesPartProviderFactory.provides(key); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProviderFactory#register(org.eclipse.emf.eef.runtime.api.providers.IPropertiesEditionPartProvider) - */ - public void register(IPropertiesEditionPartProvider editPropertiesProvider) { - editPropertiesPartProviderFactory.register(editPropertiesProvider); - } - - /** - * Load all the providers registered by extension point. - */ - private void configureService() { - IExtensionPoint extensionPoint = Platform.getExtensionRegistry().getExtensionPoint( - EEFRuntimePlugin.PLUGIN_ID, EXTENSION_NAME); - - IExtension[] extensions = extensionPoint.getExtensions(); - for (int extensionIndex = 0; extensionIndex < extensions.length; extensionIndex++) { - IExtension extension = extensions[extensionIndex]; - IConfigurationElement[] configurationElements = extension.getConfigurationElements(); - for (int i = 0; i < configurationElements.length; i++) { - IConfigurationElement cfg = configurationElements[i]; - - if (EXTENSION_ELEMENT_NAME.equals(cfg.getName())) { - try { - register((IPropertiesEditionPartProvider)cfg - .createExecutableExtension(EXTENSION_ATTRIBUTE_NAME)); - } catch (CoreException e) { - e.printStackTrace(); - } - } - } - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/ReadOnlyPolicyProviderService.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/ReadOnlyPolicyProviderService.java deleted file mode 100644 index 2e592bab8..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/ReadOnlyPolicyProviderService.java +++ /dev/null @@ -1,117 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.services; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IConfigurationElement; -import org.eclipse.core.runtime.IExtension; -import org.eclipse.core.runtime.IExtensionPoint; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.api.providers.IReadOnlyPolicy; - -/** - * Service that manage all the registered {@link IReadOnlyPolicy}. - * - * @author Nathalie Lepine - */ -public class ReadOnlyPolicyProviderService { - - /** - * The extension name. - */ - public static final String EXTENSION_NAME = "ReadOnlyPolicyProvider"; //$NON-NLS-1$ - - /** - * The extension's element name. - */ - private static final String EXTENSION_ELEMENT_NAME = "ReadOnlyPolicyProvider"; //$NON-NLS-1$ - - /** - * The element's attribute name. - */ - private static final String EXTENSION_ATTRIBUTE_NAME = "policyClass"; //$NON-NLS-1$ - - /** - * A singleton for the service. - */ - private static ReadOnlyPolicyProviderService instance = new ReadOnlyPolicyProviderService(); - - /** - * The factory where the providers are registered. - */ - private List readOnlyPolicies; - - /** - * Default constructor. - */ - private ReadOnlyPolicyProviderService() { - readOnlyPolicies = new ArrayList(); - configureService(); - } - - /** - * Singleton constructor. - * - * @return the Singleton instance - */ - public static ReadOnlyPolicyProviderService getInstance() { - return instance; - } - - /** - * @return all the registered policies - */ - public List getPolicies() { - return readOnlyPolicies; - } - - - /** - * Register a policy. - * - * @param readOnlyPolicy IReadOnlyPolicy - */ - public void register(IReadOnlyPolicy readOnlyPolicy) { - readOnlyPolicies.add(readOnlyPolicy); - } - - /** - * Load all the providers registered by extension point. - */ - private void configureService() { - IExtensionPoint extensionPoint = Platform.getExtensionRegistry().getExtensionPoint( - EEFRuntimePlugin.PLUGIN_ID, EXTENSION_NAME); - - IExtension[] extensions = extensionPoint.getExtensions(); - for (int extensionIndex = 0; extensionIndex < extensions.length; extensionIndex++) { - IExtension extension = extensions[extensionIndex]; - IConfigurationElement[] configurationElements = extension.getConfigurationElements(); - for (int i = 0; i < configurationElements.length; i++) { - IConfigurationElement cfg = configurationElements[i]; - - if (EXTENSION_ELEMENT_NAME.equals(cfg.getName())) { - try { - register((IReadOnlyPolicy)cfg - .createExecutableExtension(EXTENSION_ATTRIBUTE_NAME)); - } catch (CoreException e) { - e.printStackTrace(); - } - } - } - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/WizardOpeningPolicyProviderService.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/WizardOpeningPolicyProviderService.java deleted file mode 100644 index a25e208e6..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/services/WizardOpeningPolicyProviderService.java +++ /dev/null @@ -1,140 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.services; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IConfigurationElement; -import org.eclipse.core.runtime.IExtension; -import org.eclipse.core.runtime.IExtensionPoint; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.ui.wizards.IWizardOpeningPolicy; -import org.eclipse.emf.eef.runtime.ui.wizards.impl.StandardWizardOpeningPolicy; - -/** - * Service that manage all the registered {@link IWizardOpeningPolicy}. - * - * @author Nathalie Lepine - */ -public class WizardOpeningPolicyProviderService { - - /** - * The extension name. - */ - public static final String EXTENSION_NAME = "WizardOpeningPolicyProvider"; //$NON-NLS-1$ - - /** - * The extension's element name. - */ - private static final String EXTENSION_ELEMENT_NAME = "WizardOpeningPolicyProvider"; //$NON-NLS-1$ - - /** - * The element's attribute name. - */ - private static final String EXTENSION_ATTRIBUTE_NAME = "policyClass"; //$NON-NLS-1$ - - /** - * A singleton for the service. - */ - private static WizardOpeningPolicyProviderService instance = new WizardOpeningPolicyProviderService(); - - /** - * The factory where the providers are registered. - */ - private List wizardOpeningPolicies; - - /** - * Default constructor. - */ - private WizardOpeningPolicyProviderService() { - wizardOpeningPolicies = new ArrayList(); - configureService(); - } - - /** - * Singleton constructor. - * - * @return the Singleton instance - */ - public static WizardOpeningPolicyProviderService getInstance() { - return instance; - } - - /** - * @return all the registered policies - */ - public List getPolicies() { - return wizardOpeningPolicies; - } - - - /** - * Register a policy. - * - * @param wizardOpeningPolicy IWizardOpeningPolicy - */ - public void register(IWizardOpeningPolicy wizardOpeningPolicy) { - wizardOpeningPolicies.add(wizardOpeningPolicy); - } - - /** - * Load all the providers registered by extension point. - */ - private void configureService() { - IExtensionPoint extensionPoint = Platform.getExtensionRegistry().getExtensionPoint( - EEFRuntimePlugin.PLUGIN_ID, EXTENSION_NAME); - - IExtension[] extensions = extensionPoint.getExtensions(); - for (int extensionIndex = 0; extensionIndex < extensions.length; extensionIndex++) { - IExtension extension = extensions[extensionIndex]; - IConfigurationElement[] configurationElements = extension.getConfigurationElements(); - for (int i = 0; i < configurationElements.length; i++) { - IConfigurationElement cfg = configurationElements[i]; - - if (EXTENSION_ELEMENT_NAME.equals(cfg.getName())) { - try { - register((IWizardOpeningPolicy)cfg - .createExecutableExtension(EXTENSION_ATTRIBUTE_NAME)); - } catch (CoreException e) { - e.printStackTrace(); - } - } - } - } - - } - - /** - * @param eObject EObject - * @return the first IWizardOpeningPolicy providing eObject - */ - public static IWizardOpeningPolicy provide(EObject eObject) { - IWizardOpeningPolicy wizardOpeningPolicy = getWizardOpeningPolicy(eObject); - if (wizardOpeningPolicy == null) { - wizardOpeningPolicy = new StandardWizardOpeningPolicy(); - } - return wizardOpeningPolicy; - } - - private static IWizardOpeningPolicy getWizardOpeningPolicy(EObject eObject) { - for (IWizardOpeningPolicy openingPolicy : WizardOpeningPolicyProviderService.getInstance().getPolicies()) { - if (openingPolicy.provide(eObject)) { - return openingPolicy; - } - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFCommandParameter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFCommandParameter.java deleted file mode 100644 index 30d72688f..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFCommandParameter.java +++ /dev/null @@ -1,39 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.utils; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EReference; - -/** - * @author Goulwen Le Fur - */ -public class EEFCommandParameter { - - private EReference reference; - - private EClass eClass; - - public EEFCommandParameter(EReference reference, EClass eClass) { - super(); - this.reference = reference; - this.eClass = eClass; - } - - public EClass geteClass() { - return eClass; - } - - public EReference getReference() { - return reference; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFConverterUtil.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFConverterUtil.java deleted file mode 100644 index 190094519..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFConverterUtil.java +++ /dev/null @@ -1,154 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.runtime.impl.utils; - -import org.eclipse.emf.ecore.EDataType; -import org.eclipse.emf.ecore.util.EcoreUtil; - -/** - * @author Stephane Bouchet - */ -public class EEFConverterUtil extends EcoreUtil { - - /** - * Converts from a string to an int - * - * @param eInt - * the EDatatype EInt - * @param literal - * the literal to convert - * @return the primitive int representing the literal. - */ - public static int createIntFromString(EDataType eInt, String literal) { - Integer value = (Integer)createFromString(eInt, literal); - return value.intValue(); - } - - /** - * Converts from a string to a double - * - * @param eDouble - * the EDatatype EDouble - * @param literal - * the literal to convert - * @return the primitive double representing the literal. - */ - public static double createDoubleFromString(EDataType eDouble, String literal) { - Double value = (Double)createFromString(eDouble, literal); - return value.doubleValue(); - } - - /** - * Converts from a string to a byte - * - * @param eByte - * the EDatatype EByte - * @param literal - * the literal to convert - * @return the primitive byte representing the literal. - */ - public static byte createByteFromString(EDataType eByte, String literal) { - Byte value = (Byte)createFromString(eByte, literal); - return value.byteValue(); - } - - /** - * Converts from a string to a short - * - * @param eShort - * the EDatatype EShort - * @param literal - * the literal to convert - * @return the primitive short representing the literal. - */ - public static short createShortFromString(EDataType eShort, String literal) { - Short value = (Short)createFromString(eShort, literal); - return value.shortValue(); - } - - /** - * Converts from a string to a long - * - * @param eLong - * the EDatatype ELong - * @param literal - * the literal to convert - * @return the primitive long representing the literal. - */ - public static long createLongFromString(EDataType eLong, String literal) { - Long value = (Long)createFromString(eLong, literal); - return value.longValue(); - } - - /** - * Converts from a string to a float - * - * @param eFloat - * the EDatatype EFloat - * @param literal - * the literal to convert - * @return the primitive float representing the literal. - */ - public static float createFloatFromString(EDataType eFloat, String literal) { - Float value = (Float)createFromString(eFloat, literal); - return value.floatValue(); - } - - /** - * Converts from a string to a char - * - * @param eChar - * the EDatatype EChar - * @param literal - * the literal to convert - * @return the primitive char representing the literal. - */ - public static char createCharFromString(EDataType eChar, String literal) { - Character value = (Character)createFromString(eChar, literal); - return value.charValue(); - } - - /** - * Converts from a string to a boolean - * - * @param eBoolean - * the EDatatype EBoolean - * @param literal - * the literal to convert - * @return the primitive boolean representing the literal. - */ - public static boolean createBooleanFromString(EDataType eBoolean, String literal) { - Boolean value = (Boolean)createFromString(eBoolean, literal); - return value.booleanValue(); - } - - /** - * Creates an instance of the datatype. - * - * @param eDataType - * the datatype to instantiate. - * @param literal - * the string value of the datatype. - * @return an instance of the datatype. - * @see #convertToString(EDataType, Object) - */ - public static Object createFromString(EDataType eDataType, String literal) { - // If the string literal is null or empty, the returned value is the - // default value of the DataType - if (literal == null || literal.trim().length() == 0) { - return eDataType.getDefaultValue(); - } else { - return EcoreUtil.createFromString(eDataType, literal); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFRuntimeMessages.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFRuntimeMessages.java deleted file mode 100644 index 57868c3c0..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFRuntimeMessages.java +++ /dev/null @@ -1,38 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.utils; - -import org.eclipse.osgi.util.NLS; - -public class EEFRuntimeMessages extends NLS { - private static final String BUNDLE_NAME = "org.eclipse.emf.eef.runtime.impl.utils.eefRuntimeMessages"; //$NON-NLS-1$ - - public static String ComposedPropertiesEditionComponent_cmd_not_performed; - - public static String ComposedPropertiesEditionComponent_eef_validation_diagnostic; - - public static String ComposedPropertiesEditionComponent_no_problem; - - public static String CurrentModelViewerFilter_name; - - public static String ModelViewerHelper_name_feature; - - public static String ReferencedModelsViewerFilter_name; - - public static String StringTools_color_delim; - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, EEFRuntimeMessages.class); - } - - private EEFRuntimeMessages() { - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFUtils.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFUtils.java deleted file mode 100755 index 271aa78cf..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/EEFUtils.java +++ /dev/null @@ -1,441 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.utils; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.core.runtime.IAdaptable; -import org.eclipse.core.runtime.Platform; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.command.CommandParameter; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.api.adapters.SemanticAdapter; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.ui.widgets.eobjflatcombo.EObjectFlatComboSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings; -import org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFEditorSettings; -import org.osgi.framework.Bundle; - -/** - * @author Goulwen Le Fur - */ -public class EEFUtils { - - public static final String JDT_CORE_SYMBOLIC_NAME = "org.eclipse.jdt.core"; //$NON-NLS-1$ - - public static Object choiceOfValues(EObject eObject, EStructuralFeature feature) { - return choiceOfValues(EEFRuntimePlugin.getDefault().getAdapterFactory(), eObject, feature); - } - - /** - * Return the choice of value for the given feature - * - * @param adapterFactory - * the adapterFactory to use - * @param eObject - * the EObject to process - * @param feature - * the feature to process - * @return list of possible values - */ - public static Object choiceOfValues(AdapterFactory adapterFactory, EObject eObject, - EStructuralFeature feature) { - Object choiceOfValues = null; - IItemPropertySource ps = (IItemPropertySource)adapterFactory - .adapt(eObject, IItemPropertySource.class); - if (ps != null) { - IItemPropertyDescriptor propertyDescriptor = ps.getPropertyDescriptor(eObject, feature); - if (propertyDescriptor != null) - choiceOfValues = propertyDescriptor.getChoiceOfValues(eObject); - } - if (choiceOfValues == null && eObject.eResource() != null - && eObject.eResource().getResourceSet() != null) - choiceOfValues = eObject.eResource().getResourceSet(); - if (choiceOfValues == null) - choiceOfValues = ""; - else if (choiceOfValues instanceof List) { - List list = (List)choiceOfValues; - for (int i = 0; i < list.size(); i++) { - Object next = list.get(i); - if (next == null) { - list.set(i, ""); - } - } - } - return choiceOfValues; - } - - /** - * Return the choice of value for the given feature - * - * @param adapterFactory - * the adapterFactory to use - * @param eObject - * the EObject to process - * @param feature - * the feature to process - * @return list of possible values - */ - public static String getLabel(AdapterFactory adapterFactory, EObject eObject) { - IItemLabelProvider labelProvider = (IItemLabelProvider)adapterFactory.adapt(eObject, - IItemLabelProvider.class); - if (labelProvider != null) { - return labelProvider.getText(eObject); - } - return null; - } - - /** - * Return all the instanciable types for a given reference. - * - * @param eReference - * the reference to process. - * @param editingDomain - * the editing domain where we live ! - * @return a list of {@link EClass} containing all the instanciable type for the give reference. - */ - public static List allTypeFor(EReference eReference, EditingDomain editingDomain) { - Collection list = editingDomain.getNewChildDescriptors( - EEFUtils.searchInstanceOf(editingDomain.getResourceSet(), eReference.getEContainingClass()), - null); - ArrayList instanciableTypesInHierarchy = new ArrayList(); - for (Object object : list) { - if (object instanceof CommandParameter) { - if (((CommandParameter)object).getFeature() instanceof EReference) { - if ((((CommandParameter)object).getFeature()).equals(eReference)) { - instanciableTypesInHierarchy.add(((CommandParameter)object).getEValue().eClass()); - } - } - } - } - return instanciableTypesInHierarchy; - } - - /** - * Search an instance of a given Class. - * - * @param allResources - * the ResourceSet where to search - * @param eClass - * the searched type - * @return the first instance of the given type. - */ - public static EObject searchInstanceOf(ResourceSet allResources, EClass eClass) { - for (Resource resource : allResources.getResources()) { - TreeIterator iterator = resource.getAllContents(); - while (iterator.hasNext()) { - Object objectTemp = iterator.next(); - if (objectTemp instanceof EObject) { - if (eClass.isInstance(objectTemp)) - return (EObject)objectTemp; - } - } - } - return null; - } - - /** - * @param eClassifier - * @param resourceSet - * @return all the concret types of a given classifier. - */ - public static List instanciableTypesInHierarchy(EClassifier eClassifier, ResourceSet resourceSet) { - List result = new ArrayList(); - if (eClassifier instanceof EClass) { - EClass eClass = (EClass)eClassifier; - if (!eClass.isAbstract()) - result.add(eClass); - result.addAll(instanciableSubTypes(eClass, resourceSet)); - } - return result; - } - - private static List instanciableSubTypes(EClass eClass, ResourceSet resourceSet) { - List result = new ArrayList(); - for (EPackage ePackage : allPackages(eClass, resourceSet)) { - for (EClassifier eClassifier : ePackage.getEClassifiers()) { - if (eClassifier instanceof EClass) { - EClass eClass2 = (EClass)eClassifier; - if (!eClass2.equals(eClass) && eClass.isSuperTypeOf(eClass2) && !eClass2.isAbstract() - && !eClass2.isInterface()) - result.add(eClass2); - } - } - } - - return result; - } - - private static List allPackages(EClass eClass, ResourceSet resourceSet) { - List result = new ArrayList(); - if (eClass.eResource() != null) { - EcoreUtil.resolveAll(eClass); - List resourcesToProcess = null; - if (eClass.eResource().getResourceSet() != null) - resourcesToProcess = eClass.eResource().getResourceSet().getResources(); - else { - resourcesToProcess = new ArrayList(); - resourcesToProcess.add(eClass.eResource()); - } - for (Resource resource : resourcesToProcess) - result.addAll(allPackageOfResource(resource)); - } else { - EPackage rootPackage = eClass.getEPackage(); - while (rootPackage.getESuperPackage() != null) - rootPackage = rootPackage.getESuperPackage(); - result.addAll(allSubPackages(rootPackage)); - } - - if (resourceSet != null) { - for (EPackage ePackage : getAllEPackagesFromResourceSet(resourceSet)) { - if (!result.contains(ePackage)) - result.add(ePackage); - } - } - return result; - } - - /** - * Retrieves all the EPackages used by the ResourceSet - */ - private static List getAllEPackagesFromResourceSet(ResourceSet resourceSet_p) { - List result = new ArrayList(); - for (Resource resource : resourceSet_p.getResources()) { - for (EPackage pkg : allPackageOfResource(resource)) { - EPackage staticPackage = getStaticPackage(pkg); - if (staticPackage != null) { - result.add(staticPackage); - } - } - } - return result; - } - - /** - * Get the equivalent package from the Global EPackage registry. - */ - private static EPackage getStaticPackage(EPackage ePackage_p) { - Object staticPackage = EPackage.Registry.INSTANCE.get(ePackage_p.getNsURI()); - if (null != staticPackage) { - if (staticPackage instanceof EPackage) { - return (EPackage)staticPackage; - } else if (staticPackage instanceof EPackage.Descriptor) { - return ((EPackage.Descriptor)staticPackage).getEPackage(); - } - } - return null; - } - - private static List allSubPackages(EPackage ePackage) { - List result = new ArrayList(); - for (EPackage subPackage : ePackage.getESubpackages()) - result.addAll(allSubPackages(subPackage)); - return result; - } - - private static List allPackageOfResource(Resource resource) { - List result = new ArrayList(); - for (Iterator iterator = resource.getAllContents(); iterator.hasNext();) { - EObject type = (EObject)iterator.next(); - if (type instanceof EPackage) - result.add((EPackage)type); - } - return result; - } - - /** - * Convert a treeIterator in Object list - * - * @param iter - * the iterator - * @return the result list - */ - public static List asList(TreeIterator iter) { - List result = new ArrayList(); - while (iter.hasNext()) - result.add(iter.next()); - return result; - } - - /** - * Convert a treeIterator in EObject list - * - * @param iter - * the iterator - * @return the result list - */ - public static List asEObjectList(TreeIterator iter) { - List result = new ArrayList(); - while (iter.hasNext()) - result.add(iter.next()); - return result; - } - - /** - * method defining if a bundle is loaded or not - * - * @param name - * the searched bundle - * @return true when the bundle is loaded - */ - public static boolean isBundleLoaded(String name) { - Bundle bundle = Platform.getBundle(name); - return bundle != null && bundle.getState() == Bundle.ACTIVE; - } - - /** - * @param eObject - * the element to check - * @return true if the given element match or contains a matching element - */ - public static boolean containsInstanceOfEClass(EObject element, EClass eClassToCheck) { - // Check type and super type matching - if (isInstanceOfEClass(element, eClassToCheck)) { - return true; - } - // Check containment - for (EObject container : element.eContents()) { - if (containsInstanceOfEClass(container, eClassToCheck)) { - return true; - } - } - return false; - } - - /** - * @param eObject - * the element to check - * @return true if the given element match or contains a matching element - */ - public static boolean isInstanceOfEClass(EObject element, EClass eClassToCheck) { - // Check type and super type matching - EClass eClass = element.eClass(); - if (eClass.equals(eClassToCheck)) { - return true; - } else { - for (EClass eSuperClass : eClass.getEAllSuperTypes()) { - if (eSuperClass.equals(eClassToCheck)) { - return true; - } - } - } - return false; - } - - /** - * @param settings - * @param eObject - */ - public static void putToReference(EEFEditorSettings settings, EObject eObject) { - if (settings instanceof ReferencesTableSettings) { - ((ReferencesTableSettings)settings).addToReference(eObject); - } else if (settings instanceof EObjectFlatComboSettings) { - ((EObjectFlatComboSettings)settings).setToReference(eObject); - } - } - - /** - * Search an {@link EditingDomain} in the given {@link PropertiesEditingContext} hierarchy. - * - * @param editingContext - * to process - * @return an {@link EditingDomain} if there is a {@link DomainPropertiesEditionContext} in the given - * hierarchy - */ - public static EditingDomain getEditingDomain(PropertiesEditingContext editingContext) { - if (editingContext instanceof DomainPropertiesEditionContext) { - return ((DomainPropertiesEditionContext)editingContext).getEditingDomain(); - } else if (editingContext.getParentContext() != null) { - return getEditingDomain(editingContext.getParentContext()); - } else { - return null; - } - } - - /** - * This method analyze an input to exact the EObject to edit. First we try to adapt this object in - * {@link SemanticAdapter}. If this can't be done, we check if this object is an {@link EObject}. Finally, - * if this object isn't an {@link EObject}, we try to adapt it in EObject. - * - * @param object - * element to test - * @return the EObject to edit with EEF. - */ - public static EObject resolveSemanticObject(Object object) { - IAdaptable adaptable = null; - if (object instanceof IAdaptable) { - adaptable = (IAdaptable)object; - Object getAdapter = adaptable.getAdapter(SemanticAdapter.class); - if (getAdapter != null) { - // 1 - Object is an IAdaptable and we can adapt this object in a SemanticAdapter - return ((SemanticAdapter) getAdapter).getEObject(); - } - } - Object loadAdapter = Platform.getAdapterManager().loadAdapter(object, SemanticAdapter.class.getName()); - if (loadAdapter != null) { - // 2 - Platform can adapt Object in a SemanticAdapter - return ((SemanticAdapter) loadAdapter).getEObject(); - } - if (object instanceof EObject) { - return (EObject)object; - } - if (adaptable != null) { - if (adaptable.getAdapter(EObject.class) != null) { - // 3 - we can adapt Object in EObject - return (EObject)adaptable.getAdapter(EObject.class); - } - } - return null; - } - - - /** - * FIXME - * @param src - * @return - */ - public static Notifier highestNotifier(final EObject src) { - if (src.eResource() != null) { - Resource resource = src.eResource(); - if (resource.getResourceSet() != null) { - return resource.getResourceSet(); - } else { - return resource; - } - } else { - EObject tmp = src; - while (tmp.eContainer() != null) { - tmp = tmp.eContainer(); - } - return tmp; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/ModelViewerHelper.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/ModelViewerHelper.java deleted file mode 100644 index 208f43831..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/ModelViewerHelper.java +++ /dev/null @@ -1,80 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.utils; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.resources.IContainer; -import org.eclipse.core.resources.IResource; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.TreeViewer; - -/** - * @author Nathalie Lepine - */ -public class ModelViewerHelper { - - private static IStructuredSelection lastSelection; - - public static void setLastSelection(IStructuredSelection selection) { - lastSelection = selection; - } - - public static IStructuredSelection getLastSelection() { - return lastSelection; - } - - public static final String NAME = EEFRuntimeMessages.ModelViewerHelper_name_feature; - - public static String getName(Object element) { - if (element instanceof EObject) { - EObject eobj = (EObject)element; - EStructuralFeature structuralFeature = eobj.eClass().getEStructuralFeature(NAME); - if (structuralFeature != null) { - Object name = eobj.eGet(structuralFeature); - if (name == null) { - return null; - } - return name.toString(); - } - if (eobj instanceof EClass) { - String type = ((EClass)eobj).getName(); - if (type != null && type != "") { //$NON-NLS-1$ - return type; - } - } - return null; - } - return null; - } - - /** - * Sets the selected existing container. - * - * @param container - */ - public static void setSelectedElement(TreeViewer treeViewer, IResource resource) { - // expand to and select the specified container - List itemsToExpand = new ArrayList(); - IContainer parent = resource.getParent(); - while (parent != null) { - itemsToExpand.add(0, parent); - parent = parent.getParent(); - } - treeViewer.setExpandedElements(itemsToExpand.toArray()); - treeViewer.setSelection(new StructuredSelection(resource), true); - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/PatternTool.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/PatternTool.java deleted file mode 100644 index 4b7da4fd2..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/PatternTool.java +++ /dev/null @@ -1,162 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.utils; - -import org.eclipse.jdt.core.search.SearchPattern; - -/** - * @author Nathalie Lepine - */ -public class PatternTool { - - /** - * @param text - * : the element name - * @param pattern - * @return if name match the pattern - */ - public static boolean getPattern(String text, String pattern) { - if (text == null) { - return false; - } - if (pattern == null || "".equals(pattern)) { //$NON-NLS-1$ - return true; - } - PatternMatcher fNameMatcher = new PatternMatcher(pattern, true); - return fNameMatcher.matches(text); - } - - private static class PatternMatcher { - - private String fPattern; - - private int fMatchKind; - - private StringMatcher fStringMatcher; - - private static final char END_SYMBOL = '<'; - - private static final char ANY_STRING = '*'; - - private static final char BLANK = ' '; - - public PatternMatcher(String pattern, boolean ignoreCase) { - this(pattern, SearchPattern.R_EXACT_MATCH | SearchPattern.R_PREFIX_MATCH - | SearchPattern.R_PATTERN_MATCH | SearchPattern.R_CAMELCASE_MATCH); - } - - public PatternMatcher(String pattern, int allowedModes) { - initializePatternAndMatchKind(pattern); - fMatchKind = fMatchKind & allowedModes; - if (fMatchKind == SearchPattern.R_PATTERN_MATCH) { - fStringMatcher = new StringMatcher(fPattern, true, false); - } - } - - public String getPattern() { - return fPattern; - } - - public int getMatchKind() { - return fMatchKind; - } - - public boolean matches(String text) { - switch (fMatchKind) { - case SearchPattern.R_PATTERN_MATCH: - return fStringMatcher.match(text); - case SearchPattern.R_EXACT_MATCH: - return fPattern.equalsIgnoreCase(text); - case SearchPattern.R_CAMELCASE_MATCH: - if (SearchPattern.camelCaseMatch(fPattern, text)) { - return true; - } - // fall through to prefix match if camel case failed (bug - // 137244) - default: - return startsWithIgnoreCase(text, fPattern); - } - } - - public static boolean startsWithIgnoreCase(String text, String prefix) { - int textLength = text.length(); - int prefixLength = prefix.length(); - if (textLength < prefixLength) - return false; - for (int i = prefixLength - 1; i >= 0; i--) { - if (Character.toLowerCase(prefix.charAt(i)) != Character.toLowerCase(text.charAt(i))) - return false; - } - return true; - } - - private void initializePatternAndMatchKind(String pattern) { - int length = pattern.length(); - if (length == 0) { - fMatchKind = SearchPattern.R_EXACT_MATCH; - fPattern = pattern; - return; - } - char last = pattern.charAt(length - 1); - - if (pattern.indexOf('*') != -1 || pattern.indexOf('?') != -1) { - fMatchKind = SearchPattern.R_PATTERN_MATCH; - switch (last) { - case END_SYMBOL: - fPattern = pattern.substring(0, length - 1); - break; - case BLANK: - fPattern = pattern.trim(); - break; - case ANY_STRING: - fPattern = pattern; - break; - default: - fPattern = pattern + ANY_STRING; - } - return; - } - - if (last == END_SYMBOL) { - fMatchKind = SearchPattern.R_EXACT_MATCH; - fPattern = pattern.substring(0, length - 1); - return; - } - - if (last == BLANK) { - fMatchKind = SearchPattern.R_EXACT_MATCH; - fPattern = pattern.trim(); - return; - } - - if (isCamelCasePattern(pattern)) { - fMatchKind = SearchPattern.R_CAMELCASE_MATCH; - fPattern = pattern; - return; - } - - fMatchKind = SearchPattern.R_PREFIX_MATCH; - fPattern = pattern; - } - - /** - * Returns whether the given pattern is a camel case pattern or not. - * - * @param pattern - * the pattern to inspect - * @return whether it is a camel case pattern or not - */ - public static boolean isCamelCasePattern(String pattern) { - return SearchPattern.validateMatchRule(pattern, SearchPattern.R_CAMELCASE_MATCH) == SearchPattern.R_CAMELCASE_MATCH; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/StringMatcher.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/StringMatcher.java deleted file mode 100644 index d9dfb37a7..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/StringMatcher.java +++ /dev/null @@ -1,421 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2000, 2011 IBM Corporation 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: - * IBM Corporation - initial API and implementation - * Obeo - fixed i18n messages - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.utils; - -import java.util.Vector; - -/** - * A string pattern matcher. Supports '*' and '?' wildcards. - */ -public class StringMatcher { - protected String fPattern; - - protected int fLength; // pattern length - - protected boolean fIgnoreWildCards; - - protected boolean fIgnoreCase; - - protected boolean fHasLeadingStar; - - protected boolean fHasTrailingStar; - - protected String fSegments[]; // the given pattern is split into * separated - // segments - - /* boundary value beyond which we don't need to search in the text */ - protected int fBound = 0; - - protected static final char fSingleWildCard = '\u0000'; - - public static class Position { - int start; // inclusive - - int end; // exclusive - - public Position(int start, int end) { - this.start = start; - this.end = end; - } - - public int getStart() { - return start; - } - - public int getEnd() { - return end; - } - } - - /** - * StringMatcher constructor takes in a String object that is a simple pattern. The pattern may contain - * '*' for 0 and many characters and '?' for exactly one character. Literal '*' and '?' characters must be - * escaped in the pattern e.g., "\*" means literal "*", etc. Escaping any other character (including the - * escape character itself), just results in that character in the pattern. e.g., "\a" means "a" and "\\" - * means - * "\" If invoking the StringMatcher with string literals in Java, don't forget escape characters are represented by " - * \\". - * - * @param pattern - * the pattern to match text against - * @param ignoreCase - * if true, case is ignored - * @param ignoreWildCards - * if true, wild cards and their escape sequences are ignored (everything is taken literally). - */ - public StringMatcher(String pattern, boolean ignoreCase, boolean ignoreWildCards) { - if (pattern == null) - throw new IllegalArgumentException(); - fIgnoreCase = ignoreCase; - fIgnoreWildCards = ignoreWildCards; - fPattern = pattern; - fLength = pattern.length(); - - if (fIgnoreWildCards) { - parseNoWildCards(); - } else { - parseWildCards(); - } - } - - /** - * Find the first occurrence of the pattern between startend - * (exclusive). - * - * @param text - * the String object to search in - * @param start - * the starting index of the search range, inclusive - * @param end - * the ending index of the search range, exclusive - * @return an StringMatcher.Position object that keeps the starting (inclusive) and ending - * positions (exclusive) of the first occurrence of the pattern in the specified range of the - * text; return null if not found or subtext is empty (start==end). A pair of zeros is returned if - * pattern is empty string Note that for pattern like "*abc*" with leading and trailing stars, - * position of "abc" is returned. For a pattern like"*??*" in text "abcdf", (1,3) is returned - */ - public StringMatcher.Position find(String text, int start, int end) { - if (text == null) - throw new IllegalArgumentException(); - - int tlen = text.length(); - if (start < 0) - start = 0; - if (end > tlen) - end = tlen; - if (end < 0 || start >= end) - return null; - if (fLength == 0) - return new Position(start, start); - if (fIgnoreWildCards) { - int x = posIn(text, start, end); - if (x < 0) - return null; - return new Position(x, x + fLength); - } - - int segCount = fSegments.length; - if (segCount == 0)// pattern contains only '*'(s) - return new Position(start, end); - - int curPos = start; - int matchStart = -1; - int i; - for (i = 0; i < segCount && curPos < end; ++i) { - String current = fSegments[i]; - int nextMatch = regExpPosIn(text, curPos, end, current); - if (nextMatch < 0) - return null; - if (i == 0) - matchStart = nextMatch; - curPos = nextMatch + current.length(); - } - if (i < segCount) - return null; - return new Position(matchStart, curPos); - } - - /** - * match the given text with the pattern - * - * @return true if matched eitherwise false - * @param text - * a String object - */ - public boolean match(String text) { - return match(text, 0, text.length()); - } - - /** - * Given the starting (inclusive) and the ending (exclusive) positions in the text, determine - * if the given substring matches with aPattern - * - * @return true if the specified portion of the text matches the pattern - * @param text - * a String object that contains the substring to match - * @param start - * marks the starting position (inclusive) of the substring - * @param end - * marks the ending index (exclusive) of the substring - */ - public boolean match(String text, int start, int end) { - if (null == text) - throw new IllegalArgumentException(); - - if (start > end) - return false; - - if (fIgnoreWildCards) - return (end - start == fLength) && fPattern.regionMatches(fIgnoreCase, 0, text, start, fLength); - int segCount = fSegments.length; - if (segCount == 0 && (fHasLeadingStar || fHasTrailingStar)) // pattern - // contains - // only - // '*'(s) - return true; - if (start == end) - return fLength == 0; - if (fLength == 0) - return start == end; - - int tlen = text.length(); - if (start < 0) - start = 0; - if (end > tlen) - end = tlen; - - int tCurPos = start; - int bound = end - fBound; - if (bound < 0) - return false; - int i = 0; - String current = fSegments[i]; - int segLength = current.length(); - - /* process first segment */ - if (!fHasLeadingStar) { - if (!regExpRegionMatches(text, start, current, 0, segLength)) - return false; - ++i; - tCurPos = tCurPos + segLength; - } - if ((fSegments.length == 1) && (!fHasLeadingStar) && (!fHasTrailingStar)) { - // only one segment to match, no wildcards specified - return tCurPos == end; - } - /* process middle segments */ - while (i < segCount) { - current = fSegments[i]; - int currentMatch; - int k = current.indexOf(fSingleWildCard); - if (k < 0) { - currentMatch = textPosIn(text, tCurPos, end, current); - if (currentMatch < 0) - return false; - } else { - currentMatch = regExpPosIn(text, tCurPos, end, current); - if (currentMatch < 0) - return false; - } - tCurPos = currentMatch + current.length(); - i++; - } - - /* process final segment */ - if (!fHasTrailingStar && tCurPos != end) { - int clen = current.length(); - return regExpRegionMatches(text, end - clen, current, 0, clen); - } - return i == segCount; - } - - /** - * This method parses the given pattern into segments seperated by wildcard '*' characters. Since - * wildcards are not being used in this case, the pattern consists of a single segment. - */ - private void parseNoWildCards() { - fSegments = new String[1]; - fSegments[0] = fPattern; - fBound = fLength; - } - - /** - * Parses the given pattern into segments seperated by wildcard '*' characters. - */ - private void parseWildCards() { - if (fPattern.startsWith("*")) //$NON-NLS-1$ - fHasLeadingStar = true; - if (fPattern.endsWith("*")) { //$NON-NLS-1$ - /* make sure it's not an escaped wildcard */ - if (fLength > 1 && fPattern.charAt(fLength - 2) != '\\') { - fHasTrailingStar = true; - } - } - - Vector temp = new Vector(); - - int pos = 0; - StringBuffer buf = new StringBuffer(); - while (pos < fLength) { - char c = fPattern.charAt(pos++); - switch (c) { - case '\\': - if (pos >= fLength) { - buf.append(c); - } else { - char next = fPattern.charAt(pos++); - /* if it's an escape sequence */ - if (next == '*' || next == '?' || next == '\\') { - buf.append(next); - } else { - /* not an escape sequence, just insert literally */ - buf.append(c); - buf.append(next); - } - } - break; - case '*': - if (buf.length() > 0) { - /* new segment */ - temp.addElement(buf.toString()); - fBound += buf.length(); - buf.setLength(0); - } - break; - case '?': - /* append special character representing single match wildcard */ - buf.append(fSingleWildCard); - break; - default: - buf.append(c); - } - } - - /* add last buffer to segment list */ - if (buf.length() > 0) { - temp.addElement(buf.toString()); - fBound += buf.length(); - } - - fSegments = new String[temp.size()]; - temp.copyInto(fSegments); - } - - /** - * @param text - * a string which contains no wildcard - * @param start - * the starting index in the text for search, inclusive - * @param end - * the stopping point of search, exclusive - * @return the starting index in the text of the pattern , or -1 if not found - */ - protected int posIn(String text, int start, int end) {// no wild card in - // pattern - int max = end - fLength; - - if (!fIgnoreCase) { - int i = text.indexOf(fPattern, start); - if (i == -1 || i > max) - return -1; - return i; - } - - for (int i = start; i <= max; ++i) { - if (text.regionMatches(true, i, fPattern, 0, fLength)) - return i; - } - - return -1; - } - - /** - * @param text - * a simple regular expression that may only contain '?'(s) - * @param start - * the starting index in the text for search, inclusive - * @param end - * the stopping point of search, exclusive - * @param p - * a simple regular expression that may contains '?' - * @return the starting index in the text of the pattern , or -1 if not found - */ - protected int regExpPosIn(String text, int start, int end, String p) { - int plen = p.length(); - - int max = end - plen; - for (int i = start; i <= max; ++i) { - if (regExpRegionMatches(text, i, p, 0, plen)) - return i; - } - return -1; - } - - protected boolean regExpRegionMatches(String text, int tStart, String p, int pStart, int plen) { - while (plen-- > 0) { - char tchar = text.charAt(tStart++); - char pchar = p.charAt(pStart++); - - /* process wild cards */ - if (!fIgnoreWildCards) { - /* skip single wild cards */ - if (pchar == fSingleWildCard) { - continue; - } - } - if (pchar == tchar) - continue; - if (fIgnoreCase) { - if (Character.toUpperCase(tchar) == Character.toUpperCase(pchar)) - continue; - // comparing after converting to upper case doesn't handle all - // cases; - // also compare after converting to lower case - if (Character.toLowerCase(tchar) == Character.toLowerCase(pchar)) - continue; - } - return false; - } - return true; - } - - /** - * @param text - * the string to match - * @param start - * the starting index in the text for search, inclusive - * @param end - * the stopping point of search, exclusive - * @param p - * a string that has no wildcard - * @return the starting index in the text of the pattern , or -1 if not found - */ - protected int textPosIn(String text, int start, int end, String p) { - - int plen = p.length(); - int max = end - plen; - - if (!fIgnoreCase) { - int i = text.indexOf(p, start); - if (i == -1 || i > max) - return -1; - return i; - } - - for (int i = start; i <= max; ++i) { - if (text.regionMatches(true, i, p, 0, plen)) - return i; - } - - return -1; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/StringTools.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/StringTools.java deleted file mode 100644 index 458b4d382..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/StringTools.java +++ /dev/null @@ -1,108 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.utils; - -import java.util.StringTokenizer; - -import org.eclipse.swt.graphics.RGB; - -/** - * @author Goulwen Le Fur - */ -public class StringTools { - - public static final String EMPTY_STRING = ""; //$NON-NLS-1$ - - public static RGB toRGB(String s) { - if (s != null) { - StringTokenizer st = new StringTokenizer(s, EEFRuntimeMessages.StringTools_color_delim); - if (st.countTokens() == 3) { - try { - int red = Integer.parseInt(st.nextToken()); - int green = Integer.parseInt(st.nextToken()); - int blue = Integer.parseInt(st.nextToken()); - return new RGB(red, green, blue); - } catch (NumberFormatException e) { - return null; - } - } - } - return null; - } - - public static boolean isInt(String text) { - try { - Integer.parseInt(text); - return true; - } catch (NumberFormatException e) { - return false; - } - } - - public static boolean isFloat(String text) { - try { - Float.parseFloat(text); - return true; - } catch (NumberFormatException e) { - return false; - } - } - - public static boolean isByte(String text) { - try { - Byte.parseByte(text); - return true; - } catch (NumberFormatException e) { - return false; - } - } - - public static boolean isDouble(String text) { - try { - Double.parseDouble(text); - return true; - } catch (NumberFormatException e) { - return false; - } - } - - public static boolean isLong(String text) { - try { - Long.parseLong(text); - return true; - } catch (NumberFormatException e) { - return false; - } - } - - public static boolean isShort(String text) { - try { - Short.parseShort(text); - return true; - } catch (NumberFormatException e) { - return false; - } - } - - public static String toL1Case(String name) { - StringBuffer buf = new StringBuffer(); - buf.append(name.substring(0, 1).toLowerCase()); - buf.append(name.substring(1)); - return buf.toString(); - } - - public static String toU1Case(String name) { - StringBuffer buf = new StringBuffer(); - buf.append(name.substring(0, 1).toUpperCase()); - buf.append(name.substring(1)); - return buf.toString(); - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/ValidationUtils.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/ValidationUtils.java deleted file mode 100644 index 0e8af9d8b..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/ValidationUtils.java +++ /dev/null @@ -1,42 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.utils; - -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.util.EObjectValidator; - -/** - * @author Goulwen Le Fur - */ -public class ValidationUtils { - - /** - * Append a new validation failure to an existing validation diagnostic - * - * @param diagnostic - * the original diagnostic - * @param validatedObject - * the object in failure - * @param severity - * the severity of the failure - * @param errorMessage - * the associated error message - */ - public static void appendDiagnostic(Diagnostic diagnostic, EObject validatedObject, int severity, - String errorMessage) { - Diagnostic newD = new BasicDiagnostic(EObjectValidator.DIAGNOSTIC_SOURCE, severity, errorMessage, - new Object[] {validatedObject}); - ((BasicDiagnostic)diagnostic).merge(newD); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/eefRuntimeMessages.properties b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/eefRuntimeMessages.properties deleted file mode 100644 index abe5e1464..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/utils/eefRuntimeMessages.properties +++ /dev/null @@ -1,17 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2010 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -ComposedPropertiesEditionComponent_cmd_not_performed=Cannot perform command. -ComposedPropertiesEditionComponent_eef_validation_diagnostic=EEF Validation -ComposedPropertiesEditionComponent_no_problem=No problem detected -CurrentModelViewerFilter_name=Elements of the current model only -ModelViewerHelper_name_feature=nom -ReferencedModelsViewerFilter_name=Elements of the referenced models only -StringTools_color_delim=, diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/validation/EEFValidationClientSelector.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/validation/EEFValidationClientSelector.java deleted file mode 100644 index a6a8b6cb2..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/validation/EEFValidationClientSelector.java +++ /dev/null @@ -1,24 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.validation; - -import org.eclipse.emf.validation.model.IClientSelector; - -/** - * @author Goulwen Le Fur - */ -public class EEFValidationClientSelector implements IClientSelector { - - public boolean selects(Object object) { - return true; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/validation/EEFValidator.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/validation/EEFValidator.java deleted file mode 100644 index 7eb29cf35..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/impl/validation/EEFValidator.java +++ /dev/null @@ -1,95 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.impl.validation; - -import java.util.Map; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.core.runtime.Status; -import org.eclipse.emf.common.util.BasicDiagnostic; -import org.eclipse.emf.common.util.DiagnosticChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.util.EObjectValidator; -import org.eclipse.emf.validation.model.EvaluationMode; -import org.eclipse.emf.validation.model.IConstraintStatus; -import org.eclipse.emf.validation.service.IBatchValidator; -import org.eclipse.emf.validation.service.ModelValidationService; - -/** - * @author Goulwen Le Fur - */ -public class EEFValidator extends EObjectValidator { - - private final IBatchValidator batchValidator; - - public EEFValidator() { - super(); - batchValidator = (IBatchValidator)ModelValidationService.getInstance().newValidator( - EvaluationMode.BATCH); - batchValidator.setIncludeLiveConstraints(true); - batchValidator.setReportSuccesses(false); - } - - public boolean validate(EObject eObject, DiagnosticChain diagnostics, Map context) { - return validate(eObject.eClass(), eObject, diagnostics, context); - } - - public boolean validate(EClass eClass, EObject eObject, DiagnosticChain diagnostics, - Map context) { - super.validate(eClass, eObject, diagnostics, context); - IStatus status = Status.OK_STATUS; - if (diagnostics != null) { - if (!hasProcessed(eObject, context)) { - status = batchValidator.validate(eObject, new NullProgressMonitor()); - processed(eObject, context, status); - appendDiagnostics(status, diagnostics); - } - } - return status.isOK(); - } - - private void processed(EObject eObject, Map context, IStatus status) { - if (context != null) { - context.put(eObject, status); - } - } - - private boolean hasProcessed(EObject eObject, Map context) { - EObject toTest = eObject; - boolean result = false; - if (context != null) { - while (toTest != null) { - if (context.containsKey(toTest)) { - result = true; - toTest = null; - } else { - toTest = toTest.eContainer(); - } - } - } - return result; - } - - private void appendDiagnostics(IStatus status, DiagnosticChain diagnostics) { - if (status.isMultiStatus()) { - IStatus[] children = status.getChildren(); - for (int i = 0; i < children.length; i++) { - appendDiagnostics(children[i], diagnostics); - } - } else if (status instanceof IConstraintStatus) { - diagnostics.add(new BasicDiagnostic(status.getSeverity(), status.getPlugin(), status.getCode(), - status.getMessage(), ((IConstraintStatus)status).getResultLocus().toArray())); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/part/impl/SectionPropertiesEditingPart.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/part/impl/SectionPropertiesEditingPart.java deleted file mode 100644 index ce42f9fa8..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/part/impl/SectionPropertiesEditingPart.java +++ /dev/null @@ -1,441 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.part.impl; - -import java.lang.reflect.Field; -import java.lang.reflect.Method; -import java.util.Iterator; -import java.util.List; -import java.util.Map; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesValidationEditionEvent; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.emf.eef.runtime.part.impl.util.ValidationMessageInjector; -import org.eclipse.emf.eef.runtime.ui.parts.impl.BindingViewHelper; -import org.eclipse.emf.eef.runtime.ui.utils.EEFRuntimeUIMessages; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionMessageManager; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.swt.SWT; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.views.properties.tabbed.ISection; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; - -/** - * @author Goulwen Le Fur - */ -public abstract class SectionPropertiesEditingPart extends CompositePropertiesEditionPart implements IFormPropertiesEditionPart, ISection { - - /** - * The tabbed property sheet page - */ - private TabbedPropertySheetPage tabbedPropertySheetPage; - - /** - * The editingDomain where the viewer must perform editing commands. - */ - private EditingDomain editingDomain; - - /** - * The current selected object or the first object in the selection when - * multiple objects are selected. - */ - protected EObject eObject; - - /** - * The list of current selected objects. - */ - protected List eObjectList; - - protected Composite container; - - private boolean usedAsPropertySection; - - /** - * Manager for error message - */ - private PropertiesEditionMessageManager messageManager; - - private Composite editingComposite; - - private ValidationMessageInjector injector; - - /** - * - */ - protected SectionPropertiesEditingPart() { - super(); - adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); - } - - public SectionPropertiesEditingPart(IPropertiesEditionComponent editionComponent) { - super(editionComponent); - this.usedAsPropertySection = false; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.views.properties.tabbed.ISection#createControls(org.eclipse.swt.widgets.Composite, - * org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage) - */ - public void createControls(Composite parent, TabbedPropertySheetPage tabbedPropertySheetPage) { - this.tabbedPropertySheetPage = tabbedPropertySheetPage; - this.container = tabbedPropertySheetPage.getWidgetFactory().createComposite(parent); - container.setLayout(new GridLayout(3, false)); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.views.properties.tabbed.ISection#setInput(org.eclipse.ui.IWorkbenchPart, - * org.eclipse.jface.viewers.ISelection) - */ - public void setInput(IWorkbenchPart part, ISelection selection) { - initializeEditingDomain(part, selection); - if (!(selection instanceof IStructuredSelection)) { - return; - } - if (resolveSemanticObject(((IStructuredSelection) selection).getFirstElement()) != null) { - EObject newEObject = resolveSemanticObject(((IStructuredSelection) selection).getFirstElement()); - if (newEObject != eObject) { - eObject = newEObject; - if (eObject != null) { - injector = new ValidationMessageInjector(tabbedPropertySheetPage); - messageManager = new PropertiesEditionMessageManager() { - - @Override - protected void updateStatus(String message) { - if (injector != null) { - injector.setMessage(message, IStatus.OK); - } - } - - @Override - protected void updateError(String message) { - if (injector != null) { - injector.setMessage(message, IStatus.ERROR); - } - } - - @Override - protected void updateWarning(String message) { - if (injector != null) { - injector.setMessage(message, IStatus.WARNING); - } - } - - }; - disposeComponent(); - refreshComponent(); - } - } - } - eObjectList = ((IStructuredSelection) selection).toList(); - this.usedAsPropertySection = true; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart#refresh() - */ - @Override - public void refresh() { - if (usedAsPropertySection) { - initSemanticContents(); - } else { - super.refresh(); - } - } - - protected void initializeEditingDomain(IWorkbenchPart part, ISelection selection) { - editingDomain = EditingUtils.getResourceSetFromEditor(part); - } - - /** - * @see EEFUtils#resolveSemanticObject(Object) - */ - protected EObject resolveSemanticObject(Object object) { - return EEFUtils.resolveSemanticObject(object); - } - - private void refreshComponent() { - DomainPropertiesEditionContext propertiesEditingContext = new DomainPropertiesEditionContext(null, null, editingDomain, adapterFactory, eObject); - propertiesEditionComponent = propertiesEditingContext.createPropertiesEditingComponent(IPropertiesEditionComponent.LIVE_MODE, getDescriptor()); - if (propertiesEditionComponent != null) { - this.adapterFactory = propertiesEditionComponent.getEditingContext().getAdapterFactory(); - propertiesEditingContext.setHelper(new BindingViewHelper(propertiesEditingContext, tabbedPropertySheetPage.getWidgetFactory())); - propertiesEditionComponent.setPropertiesEditionPart(propertiesEditionComponent.translatePart(getDescriptor()), 0, this); - propertiesEditionComponent.setLiveEditingDomain(editingDomain); - if (editingComposite != null) { - editingComposite.dispose(); - } - editingComposite = this.createFigure(container, tabbedPropertySheetPage.getWidgetFactory()); - if (editingComposite != null) { - editingComposite.setLayoutData(new GridData(GridData.FILL_BOTH)); - container.layout(); - } - if (messageManager != null) { - messageManager.processMessage(new PropertiesValidationEditionEvent(null, Diagnostic.OK_INSTANCE)); - propertiesEditionComponent.addListener(new IPropertiesEditionListener() { - - public void firePropertiesChanged(IPropertiesEditionEvent event) { - messageManager.processMessage(event); - - } - }); - } - } - } - - /** - * @param descriptor - */ - protected void initSemanticContents() { - propertiesEditionComponent.initPart(propertiesEditionComponent.translatePart(getDescriptor()), 1, eObject); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.views.properties.tabbed.ISection#aboutToBeShown() - */ - public void aboutToBeShown() { - /* empty default implementation */ - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.views.properties.tabbed.ISection#aboutToBeHidden() - */ - public void aboutToBeHidden() { - if (injector != null) { - injector.dispose(); - injector = null; - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.views.properties.tabbed.ISection#dispose() - */ - public void dispose() { - disposeComponent(); - } - - private void disposeComponent() { - if (propertiesEditionComponent != null) { - PropertiesEditingContext editingContext = propertiesEditionComponent.getEditingContext(); - if (editingContext != null && editingContext.getParentContext() == null) { - editingContext.dispose(); - } - propertiesEditionComponent.dispose(); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.views.properties.tabbed.ISection#getMinimumHeight() - */ - public int getMinimumHeight() { - return SWT.DEFAULT; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.views.properties.tabbed.ISection#shouldUseExtraSpace() - */ - public boolean shouldUseExtraSpace() { - return false; - } - - /** - * Magic method For eclipse 3.2 & 3.3 & 3.4 & 3.5 - * - * @return - */ - protected String getDescriptor() { - Map descriptor = getPageDescriptor(tabbedPropertySheetPage); - for (Iterator iterator = descriptor.keySet().iterator(); iterator.hasNext();) { - Object key = iterator.next(); - Object tab = descriptor.get(key); - Method getSectionAtIndex = getMethod(tab, "getSectionAtIndex", int.class); //$NON-NLS-1$ - if (getSectionAtIndex != null) { - Object result = callMethod(tab, getSectionAtIndex, new Integer(0)); - if (result == this) { - Method getId = getMethod(key, "getId"); //$NON-NLS-1$ - if (getId != null) { - String id = (String) callMethod(key, getId); - return id; - } - } else { - if (result != null) { - boolean oldLegacySectionAccessible = false; - Field legacySectionField = null; - Class cls = result.getClass(); - - try { - legacySectionField = cls.getDeclaredField("legacySection"); //$NON-NLS-1$ - } catch (NoSuchFieldException e) { - // Do nothing, we are testing if the field exist - } - - if (legacySectionField != null) { - try { - oldLegacySectionAccessible = legacySectionField.isAccessible(); - legacySectionField.setAccessible(true); - result = legacySectionField.get(result); - if (result == this) { - Method getId = getMethod(key, "getId"); //$NON-NLS-1$ - if (getId != null) { - String id = (String) callMethod(key, getId); - return id; - } - } - } catch (SecurityException e) { - EEFRuntimePlugin.getDefault().logError(EEFRuntimeUIMessages.PropertiesEditionSection_legacySection_not_found, e); - } catch (IllegalArgumentException e) { - EEFRuntimePlugin.getDefault().logError(EEFRuntimeUIMessages.PropertiesEditionSection_legacySection_not_found, e); - } catch (IllegalAccessException e) { - EEFRuntimePlugin.getDefault().logError(EEFRuntimeUIMessages.PropertiesEditionSection_legacySection_not_found, e); - } finally { - if (legacySectionField != null) { - legacySectionField.setAccessible(oldLegacySectionAccessible); - } - } - } - } - } - } - } - return ""; //$NON-NLS-1$ - } - - private Map getPageDescriptor(TabbedPropertySheetPage propertySheetPage) { - Field descriptorToTabField = null; - Field pageField = null; - Object page = propertySheetPage; - boolean oldDescriptorToTabAccessible = false; - boolean oldPageAccessible = false; - try { - Class cls = propertySheetPage.getClass(); - while (!cls.getName().contains("TabbedPropertySheetPage")) { - cls = cls.getSuperclass(); - } - try { - descriptorToTabField = cls.getDeclaredField("descriptorToTab"); //$NON-NLS-1$ - } catch (NoSuchFieldException e) { - pageField = cls.getDeclaredField("page"); //$NON-NLS-1$ - cls = pageField.getType(); - oldPageAccessible = pageField.isAccessible(); - pageField.setAccessible(true); - page = pageField.get(propertySheetPage); - descriptorToTabField = cls.getDeclaredField("descriptorToTab"); //$NON-NLS-1$ - } - oldDescriptorToTabAccessible = descriptorToTabField.isAccessible(); - descriptorToTabField.setAccessible(true); - return (Map) descriptorToTabField.get(page); - - } catch (SecurityException e) { - - EEFRuntimePlugin.getDefault().logError(EEFRuntimeUIMessages.PropertiesEditionSection_descriptorToTab_not_found, e); - } catch (NoSuchFieldException e) { - - EEFRuntimePlugin.getDefault().logError(EEFRuntimeUIMessages.PropertiesEditionSection_descriptorToTab_not_found, e); - } catch (IllegalArgumentException e) { - - EEFRuntimePlugin.getDefault().logError(EEFRuntimeUIMessages.PropertiesEditionSection_descriptorToTab_not_found, e); - } catch (IllegalAccessException e) { - - EEFRuntimePlugin.getDefault().logError(EEFRuntimeUIMessages.PropertiesEditionSection_descriptorToTab_not_found, e); - } finally { - if (descriptorToTabField != null) { - descriptorToTabField.setAccessible(oldDescriptorToTabAccessible); - } - if (pageField != null) { - pageField.setAccessible(oldPageAccessible); - } - } - return null; - } - - /** - * @param source - * the source object - * @param name - * the method to get - * @param argsType - * the method arguments type - * @return the given method - */ - private Method getMethod(Object source, String name, Class... argsType) { - try { - return source.getClass().getDeclaredMethod(name, argsType); - } catch (Exception e) { - EEFRuntimePlugin.getDefault().logError(EEFRuntimeUIMessages.PropertiesEditionSection_method_not_found + name, e); - } - return null; - } - - /** - * @param source - * the source object - * @param name - * the method to get - * @param argsType - * the method arguments type - * @return the result of the given method - */ - private Object callMethod(Object source, Method method, Object... args) { - try { - return method.invoke(source, args); - } catch (Exception e) { - EEFRuntimePlugin.getDefault().logError(EEFRuntimeUIMessages.PropertiesEditionSection_error_occured_on + method.getName() + EEFRuntimeUIMessages.PropertiesEditionSection_call, e); - } - return null; - } - - /** - * @return the editing domain - */ - public EditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * @param editingDomain - */ - public void setEditingDomain(EditingDomain editingDomain) { - this.editingDomain = editingDomain; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/part/impl/util/ValidationMessageInjector.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/part/impl/util/ValidationMessageInjector.java deleted file mode 100644 index 99f60c4f9..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/part/impl/util/ValidationMessageInjector.java +++ /dev/null @@ -1,177 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.part.impl.util; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.swt.SWT; -import org.eclipse.swt.custom.CLabel; -import org.eclipse.swt.graphics.Color; -import org.eclipse.swt.layout.FormAttachment; -import org.eclipse.swt.layout.FormData; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.ui.forms.IFormColors; -import org.eclipse.ui.internal.views.properties.tabbed.view.TabbedPropertyComposite; -import org.eclipse.ui.internal.views.properties.tabbed.view.TabbedPropertyTitle; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetWidgetFactory; - -/** - * Utility class in order to inject a validation label in a {@link TabbedPropertySheetPage}. - * - * @author Goulwen Le Fur - */ -public class ValidationMessageInjector { - - private static final String VALIDATION_MESSAGE_KEY = "org.eclipse.emf.eef.runtime.part.impl.util.ValidationMessageInjector"; - - private TabbedPropertySheetPage page; - - private TabbedPropertyComposite propertyComposite; - - private TabbedPropertyTitle propertyTitle; - - private CLabel propertyTitleLabel; - - /** - * @param page - * to inject. - */ - public ValidationMessageInjector(TabbedPropertySheetPage page) { - this.page = page; - initialize(); - } - - public void setMessage(String message, int severity) { - if (isValide()) { - if (severity == IStatus.ERROR) { - CLabel messageControl = getMessage(); - messageControl.setText("Errors"); - messageControl.setForeground(propertyComposite.getDisplay().getSystemColor(SWT.COLOR_RED)); - messageControl.setImage(EEFRuntimePlugin.getImage(EEFRuntimePlugin.ICONS_16x16 - + "ValidationErrors.gif")); - messageControl.setToolTipText(message); - } else if (severity == IStatus.WARNING) { - CLabel messageControl = getMessage(); - messageControl.setText("Warnings"); - messageControl.setForeground(propertyComposite.getDisplay().getSystemColor( - SWT.COLOR_DARK_YELLOW)); - messageControl.setImage(EEFRuntimePlugin.getImage(EEFRuntimePlugin.ICONS_16x16 - + "ValidationWarnings.gif")); - messageControl.setToolTipText(message); - } else { - dispose(); - } - } - } - - public final void dispose() { - if (isValide()) { - CLabel message = getMessage(); - if (message != null && !message.isDisposed()) { - FormData data = (FormData)message.getLayoutData(); - data.left = new FormAttachment(0, 0); - data.right = new FormAttachment(0, 0); - data.top = new FormAttachment(0, 0); - data.bottom = new FormAttachment(0, 0); - message.setVisible(false); - propertyTitle.layout(); - message.dispose(); - } - if (propertyTitleLabel.getLayoutData() instanceof FormData) { - FormData data = (FormData)propertyTitleLabel.getLayoutData(); - data.right = new FormAttachment(100, 0); - } - propertyTitle.layout(); - propertyComposite.setData(VALIDATION_MESSAGE_KEY, null); - } - } - - /** - * @return true if the injector has been correctly initialized. - */ - public final boolean isValide() { - return propertyComposite != null && !propertyComposite.isDisposed() && propertyTitleLabel != null; - } - - private void initialize() { - if (page.getControl() instanceof TabbedPropertyComposite) { - propertyComposite = (TabbedPropertyComposite)page.getControl(); - propertyTitle = searchTitle(propertyComposite); - if (propertyTitle != null) { - propertyTitleLabel = searchLabel(propertyTitle); - } - } - - } - - private CLabel getMessage() { - if (propertyComposite.getData(VALIDATION_MESSAGE_KEY) != null - && !(((CLabel)propertyComposite.getData(VALIDATION_MESSAGE_KEY)).isDisposed())) { - return (CLabel)propertyComposite.getData(VALIDATION_MESSAGE_KEY); - } else { - CLabel message = instanciateMessageAt(propertyTitle, propertyTitleLabel); - relayoutTitleLabel(propertyTitleLabel); - propertyTitle.layout(); - propertyComposite.layout(); - propertyComposite.setData(VALIDATION_MESSAGE_KEY, message); - return message; - } - } - - private TabbedPropertyTitle searchTitle(Composite composite) { - return (TabbedPropertyTitle)searchComposite(composite, TabbedPropertyTitle.class); - } - - private CLabel searchLabel(TabbedPropertyTitle title) { - return (CLabel)searchComposite(title, CLabel.class); - } - - private Composite searchComposite(Composite composite, Class clazz) { - for (int i = 0; i < composite.getChildren().length; i++) { - Control control = composite.getChildren()[i]; - if (clazz.isInstance(control)) { - return (Composite)control; - } else if (control instanceof Composite) { - Composite searchedComposite = searchComposite((Composite)control, clazz); - if (searchedComposite != null) { - return searchedComposite; - } - } - } - return null; - } - - private CLabel instanciateMessageAt(final TabbedPropertyTitle title, final CLabel titleLabel) { - TabbedPropertySheetWidgetFactory factory = page.getWidgetFactory(); - CLabel result = factory.createCLabel(title, "default"); - result.setBackground(new Color[] {factory.getColors().getColor(IFormColors.H_GRADIENT_END), - factory.getColors().getColor(IFormColors.H_GRADIENT_START)}, new int[] {100}, true); - FormData errordata = new FormData(); - errordata.left = new FormAttachment(90, 5); - errordata.top = new FormAttachment(0, 0); - errordata.right = new FormAttachment(100, 5); - errordata.bottom = new FormAttachment(100, 0); - result.setLayoutData(errordata); - return result; - } - - private boolean relayoutTitleLabel(CLabel label) { - if (label.getLayoutData() instanceof FormData) { - FormData data = (FormData)label.getLayoutData(); - data.right = new FormAttachment(90, -5); - return true; - } - return false; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/ILockPolicy.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/ILockPolicy.java deleted file mode 100644 index e9d2ec382..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/ILockPolicy.java +++ /dev/null @@ -1,36 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.policies; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -/** - * Lock Policy. - * - * @author Nathalie Lepine - */ - -public interface ILockPolicy { - /** - * Lock. - * - * @param propertiesEditingComponent IPropertiesEditionComponent. - */ - void lock(IPropertiesEditionComponent propertiesEditingComponent); - - /** - * Unlock. - * - * @param propertiesEditingComponent IPropertiesEditionComponent. - */ - void release(IPropertiesEditionComponent propertiesEditingComponent); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/PropertiesEditingPolicy.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/PropertiesEditingPolicy.java deleted file mode 100644 index bd80f97d0..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/PropertiesEditingPolicy.java +++ /dev/null @@ -1,23 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.policies; - -/** - * @author Goulwen Le Fur - */ -public interface PropertiesEditingPolicy { - - /** - * Execute the editing operation - */ - void execute(); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/PropertiesEditingPolicyWithResult.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/PropertiesEditingPolicyWithResult.java deleted file mode 100644 index ae0ea5059..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/PropertiesEditingPolicyWithResult.java +++ /dev/null @@ -1,23 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.policies; - -/** - * @author Goulwen Le Fur - */ -public interface PropertiesEditingPolicyWithResult extends PropertiesEditingPolicy { - - /** - * @return the result of the policy execution - */ - Object getResult(); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/impl/CreateEditingPolicy.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/impl/CreateEditingPolicy.java deleted file mode 100644 index b07fb498f..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/impl/CreateEditingPolicy.java +++ /dev/null @@ -1,86 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.policies.impl; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.context.impl.TypedEReferencePropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.services.WizardOpeningPolicyProviderService; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicyWithResult; -import org.eclipse.emf.eef.runtime.ui.wizards.IWizardOpeningPolicy; -import org.eclipse.emf.eef.runtime.ui.wizards.PropertiesEditionWizard; - -/** - * @author Goulwen Le Fur - */ -public class CreateEditingPolicy implements PropertiesEditingPolicyWithResult { - - protected EReferencePropertiesEditionContext editionContext; - - protected EObject result; - - /** - * @param editionContext - */ - public CreateEditingPolicy(EReferencePropertiesEditionContext editionContext) { - this.editionContext = editionContext; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy#execute() - */ - public void execute() { - editionContext.initializeRecorder(); - EClassifier eType = editionContext.getEReference().getEType(); - PropertiesEditionWizard wizard; - if (editionContext instanceof TypedEReferencePropertiesEditingContext) { - EObject create = EcoreUtil.create(((TypedEReferencePropertiesEditingContext)editionContext).getExpectedType()); - editionContext.seteObject(create); - if (editionContext.getSettings() != null) { - EEFUtils.putToReference(editionContext.getSettings(), create); - } - wizard = new PropertiesEditionWizard(editionContext, editionContext.getAdapterFactory(), create); - } else if (eType instanceof EClass && ((EClass)eType).isAbstract()) { - wizard = new PropertiesEditionWizard(editionContext, editionContext.getAdapterFactory(), editionContext.getEReference()); - } else { - EObject create = EcoreUtil.create((EClass)eType); - editionContext.seteObject(create); - if (editionContext.getSettings() != null) { - EEFUtils.putToReference(editionContext.getSettings(), create); - } - wizard = new PropertiesEditionWizard(editionContext, editionContext.getAdapterFactory(), create); - } - IWizardOpeningPolicy wizardOpeningPolicy = WizardOpeningPolicyProviderService.provide(editionContext.getEObject()); - boolean open = wizardOpeningPolicy.openWizard(editionContext, wizard); - if (open) { - result = wizard.getEObject(); - } else{ - result = null; - } - editionContext.dispose(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicyWithResult#getResult() - */ - public Object getResult() { - return result; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/impl/StandardEditingPolicy.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/impl/StandardEditingPolicy.java deleted file mode 100644 index d0ca9a14e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/policies/impl/StandardEditingPolicy.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.policies.impl; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.services.WizardOpeningPolicyProviderService; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.ui.wizards.IWizardOpeningPolicy; -import org.eclipse.emf.eef.runtime.ui.wizards.PropertiesEditionWizard; - -/** - * @author Goulwen Le Fur - */ -public class StandardEditingPolicy implements PropertiesEditingPolicy { - - protected PropertiesEditingContext context; - - /** - * @param propertiesEditionContext - */ - public StandardEditingPolicy(PropertiesEditingContext propertiesEditionContext) { - this.context = propertiesEditionContext; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy#execute() - */ - public void execute() { - PropertiesEditingContext editionContext = (PropertiesEditingContext)context; - EObject eObject = editionContext.getEObject(); - PropertiesEditionWizard wizard = new PropertiesEditionWizard(editionContext, - editionContext.getAdapterFactory(), eObject); - IWizardOpeningPolicy wizardOpeningPolicy = WizardOpeningPolicyProviderService.provide(eObject); - wizardOpeningPolicy.openWizard(context, wizard); - editionContext.dispose(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/providers/PropertiesEditingProvider.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/providers/PropertiesEditingProvider.java deleted file mode 100644 index 85879da3a..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/providers/PropertiesEditingProvider.java +++ /dev/null @@ -1,128 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.providers; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; - -/** - * Interface to implement by {@link IPropertiesEditionComponent} providers. - * - * @author Goulwen Le Fur - */ -public interface PropertiesEditingProvider { - - /** - * Indicates whether this provider provides the specified {@link PropertiesEditingContext}. - * - * @param editingContext - * the {@link PropertiesEditingContext} to provide - * @return true if this provider provides the editingContext; false otherwise. - */ - public abstract boolean provides(PropertiesEditingContext editingContext); - - /** - * Indicates whether this provider provides the specified {@link PropertiesEditingContext} for the given - * part. - * - * @param editingContext - * the {@link PropertiesEditingContext} to provide - * @param part - * the key of the PropertiesEditingPart to provide - * @return true if this provider provides for the specified parameters; false - * otherwise. - */ - public abstract boolean provides(PropertiesEditingContext editingContext, String part); - - /** - * Indicates whether this provider provides the specified {@link PropertiesEditingContext} for the - * expected type. - * - * @param editingContext - * the {@link PropertiesEditingContext} to provide - * @return true if this provider provides the eObject; false otherwise. - */ - public abstract boolean provides(PropertiesEditingContext editingContext, Class refinement); - - /** - * Indicates whether this provider provides the specified {@link PropertiesEditingContext} for the given - * part (with the expected type). - * - * @param editingContext - * the {@link PropertiesEditingContext} to provide - * @param part - * the key of the PropertiesEditingPart to provide - * @param refinement - * the expected type - * @return true if this provider provides the eObject; false otherwise. - */ - public abstract boolean provides(PropertiesEditingContext editingContext, String part, Class refinement); - - /** - * Returns a {@link IPropertiesEditionComponent} able to edit the {@link EObject} in the current - * {@link PropertiesEditingContext}. - * - * @param editingContext - * the current {@link PropertiesEditingContext} - * @param mode - * the editing mode. Available modes are IPropertiesEditionComponent.BATCH_MODE or - * IPropertiesEditionComponent.LIVE_MODE. - * @return a {@link IPropertiesEditionComponent} to edit the {@link EObject} in the editingContext - */ - public abstract IPropertiesEditionComponent getPropertiesEditingComponent( - PropertiesEditingContext editingContext, String mode); - - /** - * Returns a {@link IPropertiesEditionComponent} able to edit the {@link EObject} in the current - * {@link PropertiesEditingContext} for the given part. - * - * @param editingContext - * the current {@link PropertiesEditingContext} - * @param mode - * the editing mode. Available modes are IPropertiesEditionComponent.BATCH_MODE or - * IPropertiesEditionComponent.LIVE_MODE. - * @param part - * the key of the part determining the {@link IPropertiesEditionComponent} to provide - * @return a {@link IPropertiesEditionComponent} to edit the {@link EObject} in the editingContext - */ - public abstract IPropertiesEditionComponent getPropertiesEditingComponent( - PropertiesEditingContext editingContext, String mode, String part); - - /** - * Returns a {@link IPropertiesEditionComponent} able to edit the specified eObject for a specific part - * with a specific type. - * - * @param editingContext - * the current {@link PropertiesEditingContext} - * @param mode - * the editing mode. Available modes are IPropertiesEditionComponent.BATCH_MODE or - * IPropertiesEditionComponent.LIVE_MODE. - * @param part - * the key of the part determining the {@link IPropertiesEditionComponent} to provide - * @param refinement - * the expected type - * @return a {@link IPropertiesEditionComponent} to edit the {@link EObject} in the editingContext - */ - public abstract IPropertiesEditionComponent getPropertiesEditingComponent( - PropertiesEditingContext editingContext, String mode, String part, Class refinement); - - /** - * Returns a {@link PropertiesEditingPolicy} defining the editing policy for the given context. - * - * @param editingContext - * the current {@link PropertiesEditingContext} - * @return a {@link PropertiesEditingPolicy} to edit the given context - */ - public abstract PropertiesEditingPolicy getPolicy(PropertiesEditingContext context); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/providers/impl/PropertiesEditingProviderImpl.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/providers/impl/PropertiesEditingProviderImpl.java deleted file mode 100644 index 5025ba076..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/providers/impl/PropertiesEditingProviderImpl.java +++ /dev/null @@ -1,110 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.providers.impl; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.notify.impl.AdapterImpl; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.context.impl.EReferencePropertiesEditionContext; -import org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.CreateEditingPolicy; -import org.eclipse.emf.eef.runtime.policies.impl.StandardEditingPolicy; -import org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider; - -/** - * @author Goulwen Le Fur - */ -public abstract class PropertiesEditingProviderImpl extends AdapterImpl implements PropertiesEditingProvider { - - private List superProviders; - - /** - * @param superProviders - */ - public PropertiesEditingProviderImpl() { - this.superProviders = new ArrayList(); - } - - /** - * @param superProviders - */ - public PropertiesEditingProviderImpl(List superProviders) { - this.superProviders = superProviders; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicyProvider#getPolicy(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext) - */ - public PropertiesEditingPolicy getPolicy(PropertiesEditingContext context) { - if (context instanceof EReferencePropertiesEditionContext) { - return new CreateEditingPolicy((EReferencePropertiesEditionContext)context); - } - if (context instanceof EObjectPropertiesEditionContext) { - return new StandardEditingPolicy((PropertiesEditingContext)context); - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, - * java.lang.String) - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode) { - for (PropertiesEditingProvider provider : superProviders) { - IPropertiesEditionComponent propertiesEditingComponent = provider.getPropertiesEditingComponent(editingContext, mode); - if (propertiesEditingComponent != null) { - return propertiesEditingComponent; - } - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, - * java.lang.String, java.lang.String) - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part) { - for (PropertiesEditingProvider provider : superProviders) { - IPropertiesEditionComponent propertiesEditingComponent = provider.getPropertiesEditingComponent(editingContext, mode, part); - if (propertiesEditingComponent != null) { - return propertiesEditingComponent; - } - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.emf.eef.runtime.providers.PropertiesEditingProvider#getPropertiesEditingComponent(org.eclipse.emf.eef.runtime.context.PropertiesEditingContext, - * java.lang.String, java.lang.String, java.lang.Class) - */ - public IPropertiesEditionComponent getPropertiesEditingComponent(PropertiesEditingContext editingContext, String mode, String part, Class refinement) { - for (PropertiesEditingProvider provider : superProviders) { - IPropertiesEditionComponent propertiesEditingComponent = provider.getPropertiesEditingComponent(editingContext, mode, part, refinement); - if (propertiesEditingComponent != null) { - return propertiesEditingComponent; - } - } - return null; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/UIConstants.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/UIConstants.java deleted file mode 100644 index b2eb7fbf4..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/UIConstants.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui; - -import org.eclipse.swt.graphics.Point; - -/** - * List of UI constants used by EEF - * - * @author Goulwen Le Fur - */ -public interface UIConstants { - - /** - * Defines the initial size for the Editing wizard. - */ - Point INITIAL_WIZARD_SIZE = new Point(650, 800); - - /** - * Defines the constant for an unknown EEF representation type. - */ - String UNKNOW_EEF_TYPE = "unknown eef type"; - - /** - * Defines the key for the EEF widgets id. - */ - String EEF_WIDGET_ID_KEY = "org.eclipse.emf.eef.widgets.id"; - - /** - * Defines the key for the EEF widgets type. - */ - String EEF_WIDGET_TYPE_KEY = "org.eclipse.emf.eef.widgets.type"; -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/adapters/EEFBatchEditingUtil.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/adapters/EEFBatchEditingUtil.java deleted file mode 100644 index ea249ef72..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/adapters/EEFBatchEditingUtil.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015 Obeo. - * 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: - * Obeo - initial API and implementation - */ -package org.eclipse.emf.eef.runtime.ui.adapters; - - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.command.WizardEditingCommand; - - -/** - * @author Goulwen Le Fur - * - */ -public class EEFBatchEditingUtil { - - /** - * @param domain - * @param adapterFactory - * @param element - */ - public void editObjectInBatchMode(EditingDomain editingDomain, AdapterFactory adapterFactory, EObject eObject) { - if (eObject != null) { - DomainPropertiesEditionContext propertiesEditionContext = new DomainPropertiesEditionContext(null, null, editingDomain, adapterFactory, eObject); - WizardEditingCommand wizardEditingCommand = new WizardEditingCommand(propertiesEditionContext); - editingDomain.getCommandStack().execute(wizardEditingCommand); - propertiesEditionContext.dispose(); - } - } - -} \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/adapters/SimplestSemanticAdapter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/adapters/SimplestSemanticAdapter.java deleted file mode 100644 index 69bbd99df..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/adapters/SimplestSemanticAdapter.java +++ /dev/null @@ -1,37 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.adapters; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.api.adapters.SemanticAdapter; - -/** - * @author Nathalie Lepine - * - */ -public final class SimplestSemanticAdapter implements SemanticAdapter { - - private EObject target; - - public SimplestSemanticAdapter(EObject target) { - super(); - this.target = target; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.api.adapters.SemanticAdapter#getEObject() - */ - public EObject getEObject() { - return target; - } - -} \ No newline at end of file diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/comparator/EMFModelViewerComparator.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/comparator/EMFModelViewerComparator.java deleted file mode 100644 index becfa3ade..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/comparator/EMFModelViewerComparator.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.comparator; - -import org.eclipse.jface.viewers.ITableLabelProvider; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerComparator; - -/** - * @author Goulwen Le Fur - */ -public class EMFModelViewerComparator extends ViewerComparator { - - private final ITableLabelProvider labelProvider; - - private int columnIndex; - - private int order; - - public EMFModelViewerComparator(ITableLabelProvider labelProvider) { - this.labelProvider = labelProvider; - columnIndex = 0; - order = 1; - } - - public void doSort(int columnIndex) { - this.columnIndex = columnIndex; - order = -order; - } - - public int compare(Viewer viewer, Object o1, Object o2) { - final String text1 = labelProvider.getColumnText(o1, columnIndex); - final String text2 = labelProvider.getColumnText(o2, columnIndex); - int r = order * text1.compareTo(text2); - if (r == 0) { - String text11 = ""; //$NON-NLS-1$ - String text22 = ""; //$NON-NLS-1$ - if (columnIndex == 0) { - text11 = labelProvider.getColumnText(o1, 1); - text22 = labelProvider.getColumnText(o2, 1); - } - if (columnIndex == 1) { - text11 = labelProvider.getColumnText(o1, 0); - text22 = labelProvider.getColumnText(o2, 0); - } - if (text11 != null && text22 != null && text11 != "" && text22 != "") { //$NON-NLS-1$//$NON-NLS-2$ - return order * text11.compareToIgnoreCase(text22); - } - } - return order * text1.compareToIgnoreCase(text2); - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/DropDownSelectionListener.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/DropDownSelectionListener.java deleted file mode 100644 index 37fea765d..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/DropDownSelectionListener.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.notify; - -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.graphics.Point; -import org.eclipse.swt.graphics.Rectangle; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Menu; -import org.eclipse.swt.widgets.MenuItem; - -/** - * @author Goulwen Le Fur - */ -public abstract class DropDownSelectionListener extends SelectionAdapter { - - protected Button dropdown; - - protected Menu menu; - - public DropDownSelectionListener(Button dropdown) { - this.dropdown = dropdown; - this.menu = new Menu(dropdown.getParent().getShell()); - } - - public void add(String item) { - MenuItem menuItem = new MenuItem(menu, SWT.NONE); - menuItem.setText(item); - menuItem.addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent e) { - MenuItem selected = (MenuItem)e.widget; - dropdown.setText(selected.getText()); - } - }); - } - - @Override - public void widgetSelected(SelectionEvent e) { - - Button item = (Button)e.widget; - - Rectangle rectangle = item.getBounds(); - Point point = item.getParent().toDisplay(new Point(rectangle.x, rectangle.y)); - menu.setLocation(point.x, point.y + rectangle.height); - menu.setVisible(true); - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/OpenTransactionalWizardOnDoubleClick.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/OpenTransactionalWizardOnDoubleClick.java deleted file mode 100644 index 64ed5a2f9..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/OpenTransactionalWizardOnDoubleClick.java +++ /dev/null @@ -1,89 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.notify; - -import org.eclipse.core.commands.ExecutionException; -import org.eclipse.core.runtime.IAdaptable; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.operation.WizardEditingOperation; -import org.eclipse.jface.viewers.DoubleClickEvent; -import org.eclipse.jface.viewers.IDoubleClickListener; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; - -/** - * @author Goulwen Le Fur - */ -public class OpenTransactionalWizardOnDoubleClick implements IDoubleClickListener { - - protected EditingDomain editingDomain; - - protected AdapterFactory adapterFactory; - - private IProgressMonitor progressMonitor; - - /** - * @param editingDomain - */ - public OpenTransactionalWizardOnDoubleClick(EditingDomain editingDomain, AdapterFactory adapterFactory) { - this.editingDomain = editingDomain; - this.adapterFactory = adapterFactory; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IDoubleClickListener#doubleClick(org.eclipse.jface.viewers.DoubleClickEvent) - */ - public void doubleClick(DoubleClickEvent event) { - ISelection selection = event.getSelection(); - if (selection instanceof StructuredSelection) { - EObject eObject = null; - Object firstElement = ((StructuredSelection)selection).getFirstElement(); - if (firstElement instanceof EObject) { - eObject = (EObject)firstElement; - } else if (firstElement instanceof IAdaptable) { - if (((IAdaptable)firstElement).getAdapter(EObject.class) != null) - eObject = (EObject)((IAdaptable)firstElement).getAdapter(EObject.class); - } - if (eObject != null) { - DomainPropertiesEditionContext propertiesEditionContext = new DomainPropertiesEditionContext( - null, null, editingDomain, adapterFactory, eObject); - WizardEditingOperation operation = new WizardEditingOperation(propertiesEditionContext); - try { - operation.execute(getProgressMonitor(), null); - } catch (ExecutionException e) { - EEFRuntimePlugin.getDefault().logError("An error occured during wizard editing.", e); - } - } - } - } - - /** - * @return - */ - public IProgressMonitor getProgressMonitor() { - return progressMonitor; - } - - /** - * @param progressMonitor - */ - public void setProgressMonitor(IProgressMonitor progressMonitor) { - this.progressMonitor = progressMonitor; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/OpenWizardOnDoubleClick.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/OpenWizardOnDoubleClick.java deleted file mode 100644 index 6780f2c48..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/notify/OpenWizardOnDoubleClick.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.notify; - -import org.eclipse.core.runtime.IAdaptable; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.command.WizardEditingCommand; -import org.eclipse.jface.viewers.DoubleClickEvent; -import org.eclipse.jface.viewers.IDoubleClickListener; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; - -/** - * @author Goulwen Le Fur - */ -public class OpenWizardOnDoubleClick implements IDoubleClickListener { - - protected EditingDomain editingDomain; - - protected AdapterFactory adapterFactory; - - /** - * @param editingDomain - */ - public OpenWizardOnDoubleClick(EditingDomain editingDomain, AdapterFactory adapterFactory) { - this.editingDomain = editingDomain; - this.adapterFactory = adapterFactory; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IDoubleClickListener#doubleClick(org.eclipse.jface.viewers.DoubleClickEvent) - */ - public void doubleClick(DoubleClickEvent event) { - ISelection selection = event.getSelection(); - if (selection instanceof StructuredSelection) { - EObject eObject = null; - Object firstElement = ((StructuredSelection)selection).getFirstElement(); - if (firstElement instanceof EObject) { - eObject = (EObject)firstElement; - } else if (firstElement instanceof IAdaptable) { - if (((IAdaptable)firstElement).getAdapter(EObject.class) != null) - eObject = (EObject)((IAdaptable)firstElement).getAdapter(EObject.class); - } - if (eObject != null) { - DomainPropertiesEditionContext propertiesEditionContext = new DomainPropertiesEditionContext( - null, null, editingDomain, adapterFactory, eObject); - WizardEditingCommand wizardEditingCommand = new WizardEditingCommand(propertiesEditionContext); - editingDomain.getCommandStack().execute(wizardEditingCommand); - propertiesEditionContext.dispose(); - } - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/PartComposer.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/PartComposer.java deleted file mode 100644 index 1d0ae98f7..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/PartComposer.java +++ /dev/null @@ -1,91 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.parts; - -import java.util.List; - -import org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep; -import org.eclipse.swt.widgets.Composite; - -/** - * @author Goulwen Le Fur - */ -public abstract class PartComposer { - - private CompositionStep compositionSequence; - - /** - * Default constructor. The composition sequence is empty. - */ - public PartComposer(CompositionStep sequence) { - compositionSequence = sequence; - } - - /** - * @return the compositionSequence - */ - public CompositionStep getCompositionSequence() { - return compositionSequence; - } - - /** - * Compose the part. - * - * @param parent - * the view where to compose the part - */ - public void compose(Composite parent) { - List subSteps = compositionSequence.getSubSteps(); - if (!subSteps.isEmpty()) { - for (CompositionStep compositionStep : subSteps) { - composeDelegate(parent, compositionStep); - } - } - } - - /** - * Compose the part. - * - * @param parent - * the view where to compose the part - */ - protected void composeDelegate(Composite parent, CompositionStep step) { - if (step.isVisibile()) { - Composite currentContainer = addToPart(parent, step.key); - List subSteps = step.getSubSteps(); - if (!subSteps.isEmpty()) { - for (CompositionStep compositionStep : subSteps) { - composeDelegate(currentContainer, compositionStep); - } - } - } - } - - /** - * @return true if the Editor associated to the key is visible. - */ - public boolean isVisible(Object key) { - if (compositionSequence != null) { - return compositionSequence.isVisible(key); - } - return false; - } - - /** - * Ask for subclasses to instantiate the element with key {@code key} in the given parent. - * - * @param parent - * the element parent - * @param key - * the element - */ - public abstract Composite addToPart(Composite parent, Object key); -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/ViewHelper.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/ViewHelper.java deleted file mode 100644 index 17fb39bc1..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/ViewHelper.java +++ /dev/null @@ -1,50 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.parts; - -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Label; - -/** - * @author glefur - * - */ -public interface ViewHelper { - - /** - * Return the label text for a given editor. - * @param editor key of editor to process - * @param alternate altenative text - * @return the text - */ - String getDescription(Object editor, String alternate); - - /** - * Instantiate a new label to display the given feature. - * @param parent label container. - * @param editor feature to display. - * @param alternate alternative text. - * @return created label. - */ - public Label createLabel(Composite parent, Object editor, String alternate); - - /** - * Instantiate a help button for the given feature. - * @param parent button container. - * @param editor feature to process. - * @param alternate alternative text. - * @param helpID help ID - * @return created control. - */ - public Control createHelpButton(final Composite parent, Object editor); - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/impl/BindingViewHelper.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/impl/BindingViewHelper.java deleted file mode 100644 index 103425110..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/impl/BindingViewHelper.java +++ /dev/null @@ -1,143 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2011, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.runtime.ui.parts.impl; - -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.context.ExtendedPropertiesEditingContext; -import org.eclipse.emf.eef.runtime.ui.parts.ViewHelper; -import org.eclipse.jface.resource.JFaceResources; -import org.eclipse.swt.SWT; -import org.eclipse.swt.graphics.Image; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.ToolBar; -import org.eclipse.swt.widgets.ToolItem; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * @author Goulwen Le Fur - * - */ -public class BindingViewHelper implements ViewHelper { - - private static final String EMPTY_STRING = ""; //$NON-NLS-1$ - - /** - * Image registry key for help image (value "dialog_help_image" ). - */ - public static final String DLG_IMG_HELP = "dialog_help_image"; //$NON-NLS-1$ - - private ExtendedPropertiesEditingContext context; - private FormToolkit toolkit; - - /** - * @param context - */ - public BindingViewHelper(ExtendedPropertiesEditingContext context) { - this.context = context; - this.toolkit = null; - } - - /** - * @param context - * @param toolkit - */ - public BindingViewHelper(ExtendedPropertiesEditingContext context, FormToolkit toolkit) { - this.context = context; - this.toolkit = toolkit; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.parts.ViewHelper#createLabel(org.eclipse.swt.widgets.Composite, java.lang.Object, java.lang.String) - */ - public Label createLabel(Composite parent, Object editor, String alternate) { - IPropertiesEditionComponent propertiesEditingComponent = context.getPropertiesEditingComponent(); - String text = getDescription(editor, alternate); - if (!text.endsWith(": ") && !text.endsWith(":")) { - text += ": "; - } - Label label; - if (toolkit != null) { - label = toolkit.createLabel(parent, text); - } else { - label = new Label(parent, SWT.NONE); - label.setText(text); - } - // Asserting that toolkit is setted => kind == Form - if (propertiesEditingComponent != null && propertiesEditingComponent.isRequired(editor, toolkit == null?0:1)) { - label.setFont(JFaceResources.getFontRegistry().getBold(JFaceResources.DEFAULT_FONT)); - } - return label; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.parts.ViewHelper#getDescription(java.lang.Object, java.lang.String) - */ - public String getDescription(Object editor, String alternate) { - IPropertiesEditionComponent propertiesEditingComponent = context.getPropertiesEditingComponent(); - String text = alternate; - EStructuralFeature associatedFeature = propertiesEditingComponent.associatedFeature(editor); - if (associatedFeature != null) { - IItemPropertySource labelProvider = (IItemPropertySource) context.getAdapterFactory().adapt(context.getEObject(), org.eclipse.emf.edit.provider.IItemPropertySource.class); - if (labelProvider != null) { - IItemPropertyDescriptor propertyDescriptor = labelProvider.getPropertyDescriptor(context.getEObject(), associatedFeature); - if (propertyDescriptor != null) { - text = propertyDescriptor.getDisplayName(editor); - } - } - } - return text; - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.parts.ViewHelper#createHelpButton(org.eclipse.swt.widgets.Composite, java.lang.Object) - */ - @SuppressWarnings("unused") - public Control createHelpButton(Composite parent, Object feature) { - //To manage in future - String helpID = null; - String alternate = context.getPropertiesEditingComponent().getHelpContent(feature, toolkit == null?0:1); - Image image = JFaceResources.getImage(DLG_IMG_HELP); - if (helpID != null && !EMPTY_STRING.equals(helpID)) { //$NON-NLS-1$ - ToolBar result = new ToolBar(parent, SWT.FLAT | SWT.NO_FOCUS); - ((GridLayout)parent.getLayout()).numColumns++; - result.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_CENTER)); - ToolItem item = new ToolItem(result, SWT.NONE); - item.setImage(image); - if (alternate != null && !EMPTY_STRING.equals(alternate)) //$NON-NLS-1$ - item.setToolTipText(alternate); - return result; - } else { - Label result = null; - if (toolkit != null) { - result = toolkit.createLabel(parent, EMPTY_STRING); //$NON-NLS-1$ - } else { - result = new Label(parent, SWT.NONE); - } - if (alternate != null && !EMPTY_STRING.equals(alternate)) { //$NON-NLS-1$ - result.setImage(image); - result.setToolTipText(alternate); - } - return result; - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/impl/ViewHelperImpl.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/impl/ViewHelperImpl.java deleted file mode 100644 index 97a184be2..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/impl/ViewHelperImpl.java +++ /dev/null @@ -1,50 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.runtime.ui.parts.impl; - -import org.eclipse.emf.eef.runtime.ui.parts.ViewHelper; -import org.eclipse.emf.eef.runtime.ui.widgets.SWTUtils; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Label; - -/** - * @author Goulwen Le Fur - * - */ -public class ViewHelperImpl implements ViewHelper { - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.parts.ViewHelper#createLabel(org.eclipse.swt.widgets.Composite, java.lang.Object, java.lang.String) - */ - public Label createLabel(Composite parent, Object feature, String alternate) { - return SWTUtils.createPartLabel(parent, getDescription(feature, alternate), false); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.parts.ViewHelper#createHelpButton(org.eclipse.swt.widgets.Composite, java.lang.Object) - */ - public Control createHelpButton(Composite parent, Object feature) { - return SWTUtils.createHelpButton(parent, "", null); - } - - /** - * {@inheritDoc} - * @see org.eclipse.emf.eef.runtime.ui.parts.ViewHelper#getDescription(java.lang.Object, java.lang.String) - */ - public String getDescription(Object editor, String alternate) { - return alternate; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/BindingCompositionSequence.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/BindingCompositionSequence.java deleted file mode 100644 index be48119f6..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/BindingCompositionSequence.java +++ /dev/null @@ -1,39 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.parts.sequence; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -/** - * @author Goulwen Le Fur - * - */ -public class BindingCompositionSequence extends CompositionSequence { - - private IPropertiesEditionComponent component; - - public BindingCompositionSequence(IPropertiesEditionComponent component) { - super(); - this.component = component; - } - - public BindingCompositionSequence(IPropertiesEditionComponent component, CompositionStep parent, Object id) { - super(parent, id); - this.component = component; - } - - public CompositionStep addStep(Object key) { - CompositionStep compositionStep = new BindingCompositionStep(component, this, key); - subSteps.add(compositionStep); - return compositionStep; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/BindingCompositionStep.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/BindingCompositionStep.java deleted file mode 100644 index fe45865a1..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/BindingCompositionStep.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.parts.sequence; - -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; - -/** - * @author Goulwen Le Fur - * - */ -public class BindingCompositionStep extends CompositionStep { - - private IPropertiesEditionComponent component; - - /** - * @param parent - * @param key - */ - public BindingCompositionStep(IPropertiesEditionComponent component, CompositionStep parent, Object key) { - super(parent, key); - this.component = component; - } - - /** - * (inheritDoc) - * - * @see org.eclipse.emf.eef.runtime.ui.parts.sequence.CompositionStep#isVisibile() - */ - @Override - public boolean isVisibile() { - return super.isVisibile() && component.mustBeComposed(key, 0); - } - - @Override - public CompositionStep addStep(Object key) { - CompositionStep compositionStep = new BindingCompositionStep(component, this, key); - subSteps.add(compositionStep); - return compositionStep; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/CompositionSequence.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/CompositionSequence.java deleted file mode 100644 index 91f90a705..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/CompositionSequence.java +++ /dev/null @@ -1,34 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.parts.sequence; - -/** - * @author Goulwen Le Fur - */ -public class CompositionSequence extends CompositionStep { - - public static final String START_SEQUENCE_ID = "start"; - - /** - * A start point composition sequence with default ID - */ - public CompositionSequence() { - super(null, START_SEQUENCE_ID); - } - - /** - * A sub sequence - */ - public CompositionSequence(CompositionStep parent, Object id) { - super(parent, id); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/CompositionStep.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/CompositionStep.java deleted file mode 100644 index 26b1a9359..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/parts/sequence/CompositionStep.java +++ /dev/null @@ -1,244 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.parts.sequence; - -import java.util.ArrayList; -import java.util.List; - -/** - * @author Goulwen Le Fur - */ -public class CompositionStep { - - public CompositionStep parent; - - public Object key; - - protected List subSteps; - - private boolean visibility; - - /** - * @param parent - * the containing {@link CompositionSequence} - * @param key - * of this Step - */ - public CompositionStep(CompositionStep parent, Object key) { - super(); - this.parent = parent; - this.key = key; - subSteps = new ArrayList(); - this.visibility = true; - } - - /** - * @return the subSteps - */ - public List getSubSteps() { - return subSteps; - } - - /** - * Add a Sub-Step to the sequence. - * - * @param key - * the key of the sub step - * @return the created {@link CompositionStep} - */ - public CompositionStep addStep(Object key) { - CompositionStep compositionStep = new CompositionStep(this, key); - subSteps.add(compositionStep); - return compositionStep; - } - - /** - * Remove a Sub-Step to the sequence. - * - * @param key - * the key of the sub step to remove - * @return this - */ - public CompositionStep removeStep(Object key) { - for (CompositionStep step : subSteps) { - if (step.key == key) { - subSteps.remove(step); - return this; - } - } - return this; - } - - /** - * @return the visibility - */ - public boolean isVisibile() { - return visibility && (parent == null || parent.isVisibile()); - } - - /** - * switch the step visibility - */ - public void switchVisibilty() { - visibility = !visibility; - } - - /** - * @return the next step of the sequence. - */ - public CompositionStep next() { - if (subSteps.isEmpty()) { - return parent.nextOf(this); - } else { - return subSteps.get(0); - } - } - - /** - * Search the next step following the deep first algorithm - * - * @param step - * step search the following - * @return the following step for step, null otherwise. - */ - protected CompositionStep nextOf(CompositionStep step) { - if (step == null) { - return null; - } else { - int index = subSteps.indexOf(step); - if (index >= 0) { - if (index + 1 < subSteps.size()) { - return subSteps.get(index + 1); - } else { - if (parent != null) { - return parent.nextOf(this); - } else { - return null; - } - } - } - return null; - } - } - - /** - * @return the previous step - */ - public CompositionStep before() { - if (parent != null) { - return parent.beforeOf(this); - } else { - return null; - } - - } - - /** - * @param compositionStep - */ - private CompositionStep beforeOf(CompositionStep step) { - if (step == null) { - return null; - } else { - int index = subSteps.indexOf(step); - if (index >= 0) { - if (index - 1 >= 0) { - return subSteps.get(index - 1); - } else { - if (parent != null) { - return parent.beforeOf(this); - } else { - return null; - } - } - } - return null; - } - } - - /** - * up the step in the sequence - */ - public void up() { - if (parent != null) { - parent.upStep(this); - } - } - - /** - * @param step - * the step to up - */ - private void upStep(CompositionStep step) { - if (step != null) { - int index = subSteps.indexOf(step); - if (index > 0) { - subSteps.set(index, subSteps.get(index - 1)); - subSteps.set(index - 1, step); - } - } - } - - /** - * down the step in the sequence - */ - public void down() { - if (parent != null) { - parent.downStep(this); - } - } - - /** - * @param step - * the step to down - */ - private void downStep(CompositionStep step) { - if (step != null) { - int index = subSteps.indexOf(step); - if (index < subSteps.size() - 1) { - subSteps.set(index, subSteps.get(index + 1)); - subSteps.set(index + 1, step); - } - } - } - - /** - * Move the current Step to a new container. - * - * @param newParent - * the new container - */ - public void moveTo(CompositionStep newParent) { - if (newParent != null) { - parent.subSteps.remove(this); - newParent.subSteps.add(this); - parent = newParent; - } - } - - /** - * @param key the concerning key. - * @return visibility if the key correspond to the key of the step false otherwise. - */ - public boolean isVisible(Object key) { - if (key == this.key) { - return isVisibile(); - } else { - for (CompositionStep step : subSteps) { - if (step.isVisible(key)) { - return true; - } - } - } - return false; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/properties/sections/EEFAdvancedPropertySection.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/properties/sections/EEFAdvancedPropertySection.java deleted file mode 100644 index 4925267e6..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/properties/sections/EEFAdvancedPropertySection.java +++ /dev/null @@ -1,66 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.properties.sections; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.ui.provider.PropertySource; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.views.properties.IPropertySource; -import org.eclipse.ui.views.properties.IPropertySourceProvider; -import org.eclipse.ui.views.properties.tabbed.AdvancedPropertySection; - -/** - * @author Goulwen Le Fur - */ -public class EEFAdvancedPropertySection extends AdvancedPropertySection implements IPropertySourceProvider { - - private AdapterFactory adapterFactory; - - public EEFAdvancedPropertySection() { - super(); - } - - public AdapterFactory getAdapterFactory() { - if (adapterFactory == null) { - if (page != null) { - adapterFactory = EEFRuntimePlugin.getDefault().getAdapterFactory(); - } - } - return adapterFactory; - } - - public IPropertySource getPropertySource(Object object) { - if (getAdapterFactory() != null) { - IItemPropertySource item = (IItemPropertySource)getAdapterFactory().adapt(object, - IItemPropertySource.class); - if (item != null) - return new PropertySource(object, item); - } - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.ui.views.properties.tabbed.AdvancedPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, - * org.eclipse.jface.viewers.ISelection) - */ - @Override - public void setInput(IWorkbenchPart part, ISelection selection) { - super.setInput(part, selection); - if (page != null) - page.setPropertySourceProvider(this); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/providers/EMFListContentProvider.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/providers/EMFListContentProvider.java deleted file mode 100644 index 796d913fb..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/providers/EMFListContentProvider.java +++ /dev/null @@ -1,93 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.providers; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.util.TreeIterator; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.jface.viewers.IStructuredContentProvider; -import org.eclipse.jface.viewers.Viewer; - -/** - * @author Goulwen Le Fur - */ -public class EMFListContentProvider implements IStructuredContentProvider { - - private boolean nullable; - - public EMFListContentProvider() { - super(); - } - - /** - * @param nullable - * define if there is a null value or not - */ - public EMFListContentProvider(boolean nullable) { - super(); - this.nullable = nullable; - } - - /* - * (non-Javadoc) - * @see org.eclipse.jface.viewers.IContentProvider#dispose() - */ - public void dispose() { - // TODO Auto-generated method stub - } - - /* - * (non-Javadoc) - * @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface .viewers.Viewer, - * java.lang.Object, java.lang.Object) - */ - public void inputChanged(Viewer viewer, Object oldInput, Object newInput) { - // TODO Auto-generated method stub - } - - public Object[] getElements(Object inputElement) { - if (inputElement instanceof EObject) { - EObject eObject = (EObject)inputElement; - TreeIterator allContents = EcoreUtil.getAllContents(eObject, true); - return asList(allContents).toArray(); - } - if (inputElement instanceof Resource) { - Resource resource = (Resource)inputElement; - TreeIterator allContents = resource.getAllContents(); - return asList(allContents).toArray(); - } - if (inputElement instanceof ResourceSet) { - ResourceSet resourceSet = (ResourceSet)inputElement; - TreeIterator allContents = resourceSet.getAllContents(); - return asList(allContents).toArray(); - } - if (inputElement instanceof Collection) { - return ((Collection) inputElement).toArray(); - } - return null; - } - - private List asList(TreeIterator iter) { - List result = new ArrayList(); - if (nullable) - result.add(""); //$NON-NLS-1$ - while (iter.hasNext()) - result.add(iter.next()); - return result; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EEFLabelProvider.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EEFLabelProvider.java deleted file mode 100644 index ed3b90b75..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EEFLabelProvider.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.utils; - -import org.eclipse.core.runtime.IAdaptable; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.jface.viewers.DecoratingLabelProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.swt.graphics.Image; - -/** - * @author glefur - */ -public class EEFLabelProvider extends DecoratingLabelProvider { - - /** - * - */ - public EEFLabelProvider() { - super(new AdapterFactoryLabelProvider(EEFRuntimePlugin.getDefault().getAdapterFactory()), null); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.LabelProvider#getImage(java.lang.Object) - */ - public Image getImage(Object element) { - return super.getImage(unwrap(element)); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.LabelProvider#getText(java.lang.Object) - */ - public String getText(Object element) { - return super.getText(unwrap(element)); - } - - /** - * - */ - private Object unwrap(Object element) { - if (element instanceof IStructuredSelection) { - return unwrap(((IStructuredSelection)element).getFirstElement()); - } - if (element instanceof IAdaptable) { - EObject eObject = (EObject)((IAdaptable)element).getAdapter(EObject.class); - if (eObject != null) { - return eObject; - } - } - return element; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EEFRuntimeUIMessages.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EEFRuntimeUIMessages.java deleted file mode 100644 index fa0ff4045..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EEFRuntimeUIMessages.java +++ /dev/null @@ -1,128 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.utils; - -import org.eclipse.osgi.util.NLS; - -public class EEFRuntimeUIMessages extends NLS { - private static final String BUNDLE_NAME = "org.eclipse.emf.eef.runtime.ui.utils.eefRuntimeUImessages"; //$NON-NLS-1$ - - public static String AbstractEEFMasterDetailsBlock_horizontal_layout; - - public static String AbstractEEFMasterDetailsBlock_validate_action_tooltip; - - public static String AbstractEEFMasterDetailsBlock_vertical_layout; - - public static String AbstractEEFMasterPart_part_cannot_be_null; - - public static String AbstractEEFMasterPart_part_title; - - public static String AbstractEEFMasterPart_viewer_not_defined_on_filter_adding; - - public static String AbstractEEFMasterPart_viewer_not_defined_on_input_model_definition; - - public static String AbstractEEFMasterPart_viewer_not_defined_on_selection_listener_adding; - - public static String AdvancedEObjectFlatComboViewer_remove_tooltip; - - public static String AdvancedEObjectFlatComboViewer_set_tooltip; - - public static String EditPropertyWizard_main_page_description; - - public static String EditPropertyWizard_main_page_title; - - public static String EEFFeatureEditorDialog_current_model_filter_title; - - public static String EEFFeatureEditorDialog_different_container_filter_title; - - public static String EEFFeatureEditorDialog_filter_name; - - public static String EEFFeatureEditorDialog_referenced_models_filter_title; - - public static String EMFModelViewerDialog_current_model_filter_title; - - public static String EMFModelViewerDialog_different_container_filter_title; - - public static String EMFModelViewerDialog_filter_name; - - public static String EMFModelViewerDialog_multi_selection_title; - - public static String EMFModelViewerDialog_name_column_title; - - public static String EMFModelViewerDialog_referenced_models_filter_title; - - public static String EMFModelViewerDialog_single_element_title; - - public static String EMFModelViewerDialog_type_column_title; - - public static String EObjectFlatComboViewer_add_button; - - public static String FlatReferencesTable_featureEditor_title; - - public static String FlatReferencesTable_nothing_to_do; - - public static String LinkEReferenceViewer_add_tooltip; - - public static String ModelChooserDialog_choose_model; - - public static String ModelChooserDialog_title; - - public static String PropertiesEditionContentProvider_editingDomain_not_defined; - - public static String PropertiesEditionSection_call; - - public static String PropertiesEditionSection_descriptorToTab_not_found; - - public static String PropertiesEditionSection_legacySection_not_found; - - public static String PropertiesEditionSection_error_occured_on; - - public static String PropertiesEditionSection_method_not_found; - - public static String PropertiesEditionViewer_widget_factory_not_defined; - - public static String PropertiesEditionWizard_creation_page_description; - - public static String PropertiesEditionWizard_creation_page_key; - - public static String PropertiesEditionWizard_creation_page_title; - - public static String PropertiesEditionWizard_error_wizard_live_mode; - - public static String PropertiesEditionWizard_main_page_description; - - public static String PropertiesEditionWizard_main_page_key; - - public static String ReferencesTable_add_tooltip; - - public static String ReferencesTable_down_tooltip; - - public static String ReferencesTable_remove_tooltip; - - public static String ReferencesTable_up_tooltip; - - public static String TabbedPropertiesEditionSheetPage_descriptorToTab_not_found; - - public static String TabElementTreeSelectionDialog_all_resources_tab_title; - - public static String TabElementTreeSelectionDialog_model_resource_tab_title; - - public static String TabElementTreeSelectionDialog_shell_title; - - public static String TabElementTreeSelectionDialog_title; - static { - // initialize resource bundle - NLS.initializeMessages(BUNDLE_NAME, EEFRuntimeUIMessages.class); - } - - private EEFRuntimeUIMessages() { - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EditingUtils.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EditingUtils.java deleted file mode 100644 index 5f1d58aa4..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/EditingUtils.java +++ /dev/null @@ -1,113 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.utils; - -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.domain.IEditingDomainProvider; -import org.eclipse.emf.eef.runtime.ui.UIConstants; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.PlatformUI; - -/** - * @author Goulwen Le Fur - */ -public class EditingUtils { - - /** - * @param part - * the workbench part managing the editing domain - * @return if provided the editingDomain of the given workbench part - */ - public static EditingDomain getResourceSetFromEditor(IWorkbenchPart part) { - EditingDomain editingDomain = null; - if (part instanceof IEditingDomainProvider) { - editingDomain = ((IEditingDomainProvider)part).getEditingDomain(); - } else { - if (part.getAdapter(IEditingDomainProvider.class) != null) - editingDomain = ((IEditingDomainProvider)part - .getAdapter(IEditingDomainProvider.class)).getEditingDomain(); - else if (part.getAdapter(EditingDomain.class) != null) - editingDomain = (EditingDomain)part.getAdapter(EditingDomain.class); - } - return editingDomain; - } - - /** - * Set an id to a given widget. - * - * @param widget - * the widget where put the ID - * @param value - * the ID to put - */ - public static void setID(Control widget, Object value) { - if (widget != null) - widget.setData(UIConstants.EEF_WIDGET_ID_KEY, value); - } - - /** - * Return the ID of a widget? - * - * @param widget - * the widget to inspect - * @return the ID of the widget - */ - public static Object getID(Control widget) { - if (widget != null) - return widget.getData(UIConstants.EEF_WIDGET_ID_KEY); - return null; - } - - /** - * Set the EEF type of widget. - * - * @param widget - * the widget where put the ID - * @param value - * the type of the widget - */ - public static void setEEFtype(Control widget, String value) { - if (widget != null) - widget.setData(UIConstants.EEF_WIDGET_TYPE_KEY, value); - } - - /** - * Return the ID of a widget? - * - * @param widget - * the widget to inspect - * @return the ID of the widget - */ - public static String getEEFType(Control widget) { - if (widget != null) { - Object data = widget.getData(UIConstants.EEF_WIDGET_ID_KEY); - if (data instanceof String) - return (String)data; - } - return UIConstants.UNKNOW_EEF_TYPE; - } - - /** - * @return platform shell - */ - public static Shell getShell() { - Shell theShell = null; - if (PlatformUI.getWorkbench() != null && PlatformUI.getWorkbench().getActiveWorkbenchWindow() != null) { - theShell = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(); - } else { - theShell = new Shell(); - } - return theShell; - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/eefRuntimeUImessages.properties b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/eefRuntimeUImessages.properties deleted file mode 100644 index 822760eca..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/utils/eefRuntimeUImessages.properties +++ /dev/null @@ -1,62 +0,0 @@ -############################################################################### -# Copyright (c) 2008, 2010 Obeo. -# 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: -# Obeo - initial API and implementation -############################################################################### -AbstractEEFMasterDetailsBlock_horizontal_layout=Horizontal layout -AbstractEEFMasterDetailsBlock_validate_action_tooltip=Validate the current selection -AbstractEEFMasterDetailsBlock_vertical_layout=Vertical layout -AbstractEEFMasterPart_part_cannot_be_null=The viewer of the master part cannot be null -AbstractEEFMasterPart_part_title=Model -AbstractEEFMasterPart_viewer_not_defined_on_filter_adding=The viewer cannot be null when adding filters -AbstractEEFMasterPart_viewer_not_defined_on_input_model_definition=The viewer cannot be null when defining the input model -AbstractEEFMasterPart_viewer_not_defined_on_selection_listener_adding=The viewer cannot be null when adding selection change listeners -AdvancedEObjectFlatComboViewer_remove_tooltip=Unset the reference value -AdvancedEObjectFlatComboViewer_set_tooltip=Set the reference value -EditPropertyWizard_main_page_description=Editing of the properties of an object -EditPropertyWizard_main_page_title=Main page -EEFFeatureEditorDialog_current_model_filter_title=Elements of the current model only -EEFFeatureEditorDialog_different_container_filter_title=Elements of the different containers only -EEFFeatureEditorDialog_filter_name=Filter name -EEFFeatureEditorDialog_referenced_models_filter_title=Elements of the referenced models only -EMFModelViewerDialog_current_model_filter_title=Elements of the current model only -EMFModelViewerDialog_different_container_filter_title=Elements of the different containers only -EMFModelViewerDialog_filter_name=Filter name -EMFModelViewerDialog_multi_selection_title=Select one or several elements -EMFModelViewerDialog_name_column_title=Nom -EMFModelViewerDialog_referenced_models_filter_title=Elements of the referenced models only -EMFModelViewerDialog_single_element_title=Select an element -EMFModelViewerDialog_type_column_title=Type -EObjectFlatComboViewer_add_button=... -LinkEReferenceViewer_add_tooltip=Add a new element -FlatReferencesTable_featureEditor_title=Edit Feature -FlatReferencesTable_nothing_to_do=Nothing to do for the moment ... -ModelChooserDialog_choose_model=Choose a data model : -ModelChooserDialog_title=Rechercher un modele -PropertiesEditionContentProvider_editingDomain_not_defined=You have to define an EditingDomain when using LIVE_MODE -PropertiesEditionSection_call=\ call. -PropertiesEditionSection_descriptorToTab_not_found=Error while getting descriptorToTab -PropertiesEditionSection_legacySection_not_found=Error while getting legacySection -PropertiesEditionSection_error_occured_on=An error occured on -PropertiesEditionSection_method_not_found=Cannot found method -PropertiesEditionViewer_widget_factory_not_defined=A widget factory must be set in viewer to use 'Form' style. -PropertiesEditionWizard_creation_page_description=Choose the type of element to create -PropertiesEditionWizard_creation_page_key=Element creation page page -PropertiesEditionWizard_creation_page_title=Element type -PropertiesEditionWizard_error_wizard_live_mode=Trying to use PropertiesEditionWizard in LIVE_MODE. -PropertiesEditionWizard_main_page_description=Editing of the properties of an object -PropertiesEditionWizard_main_page_key=Main page -ReferencesTable_add_tooltip=Add a new element -ReferencesTable_down_tooltip=Down -ReferencesTable_remove_tooltip=Delete selected element(s) -ReferencesTable_up_tooltip=Up -TabbedPropertiesEditionSheetPage_descriptorToTab_not_found=Error while getting descriptorToTab -TabElementTreeSelectionDialog_all_resources_tab_title=All Resources -TabElementTreeSelectionDialog_model_resource_tab_title=Model Resource -TabElementTreeSelectionDialog_shell_title=Select -TabElementTreeSelectionDialog_title=Element Selection diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionContentProvider.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionContentProvider.java deleted file mode 100644 index ae555b12e..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionContentProvider.java +++ /dev/null @@ -1,247 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.viewers; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.ExtendedPropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.services.PropertiesContextService; -import org.eclipse.emf.eef.runtime.ui.utils.EEFRuntimeUIMessages; -import org.eclipse.jface.viewers.IStructuredContentProvider; -import org.eclipse.jface.viewers.Viewer; - -/** - * @author Goulwen Le Fur - */ -public class PropertiesEditionContentProvider implements IStructuredContentProvider { - - private AdapterFactory adapterFactory; - - private IPropertiesEditionComponent propertiesEditionComponent; - - private String mode; - - private EditingDomain editingDomain; - - private List propertiesEditionListeners; - - /** - * @param adapterFactory - */ - public PropertiesEditionContentProvider(AdapterFactory adapterFactory, String mode) - throws InstantiationException { - if (IPropertiesEditionComponent.LIVE_MODE.equals(mode)) - throw new InstantiationException( - EEFRuntimeUIMessages.PropertiesEditionContentProvider_editingDomain_not_defined); - this.adapterFactory = adapterFactory; - this.mode = mode; - this.propertiesEditionListeners = new ArrayList(); - } - - /** - * @param adapterFactory - */ - public PropertiesEditionContentProvider(AdapterFactory adapterFactory, String mode, - EditingDomain editingDomain) { - this.adapterFactory = adapterFactory; - this.mode = mode; - this.editingDomain = editingDomain; - this.propertiesEditionListeners = new ArrayList(); - } - - /** - * @return the {@link IPropertiesEditionComponent} - * @since 1.1 - */ - public IPropertiesEditionComponent getPropertiesEditingComponent() { - return propertiesEditionComponent; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IContentProvider#dispose() - */ - public void dispose() { - if (propertiesEditionComponent != null) { - PropertiesContextService.getInstance().pop(); - propertiesEditionComponent.dispose(); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface.viewers.Viewer, - * java.lang.Object, java.lang.Object) - */ - public void inputChanged(Viewer viewer, Object oldInput, Object newInput) { - if (propertiesEditionComponent != null) { - PropertiesContextService.getInstance().pop(); - propertiesEditionComponent.dispose(); - propertiesEditionComponent = null; - } - EObject eObject = null; - ExtendedPropertiesEditingContext context = null; - if (newInput instanceof EObject) { - eObject = (EObject)newInput; - if (mode == IPropertiesEditionComponent.LIVE_MODE) { - context = new DomainPropertiesEditionContext(null, null, editingDomain, adapterFactory, - eObject); - } else if (mode == IPropertiesEditionComponent.BATCH_MODE) { - context = new EObjectPropertiesEditionContext(null, null, eObject, adapterFactory); - } - } else if (newInput instanceof EObjectPropertiesEditionContext) { - context = (ExtendedPropertiesEditingContext)newInput; - eObject = context.getEObject(); - } - if (eObject != null) { - propertiesEditionComponent = context.createPropertiesEditingComponent(mode); - if (propertiesEditionComponent != null) { - updateListeners(); - } - } - - // FIXME: find a better way to manage the context - PropertiesContextService.getInstance().push(eObject, propertiesEditionComponent); - } - - /** - * @param listener - * the properties listener to add - */ - public void addPropertiesListener(IPropertiesEditionListener listener) { - propertiesEditionListeners.add(listener); - if (propertiesEditionComponent != null) - propertiesEditionComponent.addListener(listener); - } - - /** - * @param listener - * listener to remove - */ - public void removePropertiesListener(IPropertiesEditionListener listener) { - propertiesEditionListeners.add(listener); - if (propertiesEditionComponent != null) - propertiesEditionComponent.removeListener(listener); - } - - /** - * Validate the model and return the resulting Diagnostic - * - * @param event - * the event triggering the validation - * @return the resulting value - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - if (propertiesEditionComponent != null) - return propertiesEditionComponent.validateValue(event); - return null; - } - - /** - * Returns the Edition Parts list. - * - * @return a String array with all parts keys - */ - public String[] partsList() { - if (propertiesEditionComponent != null) - return propertiesEditionComponent.partsList(); - return new String[0]; - } - - /** - * Return the Edition Part in the given context. - * - * @param kind - * the kind of the expected Part - * @param key - * the Part key - * @return the Part created in the parent - */ - public IPropertiesEditionPart getPropertiesEditionPart(int kind, String key) { - if (propertiesEditionComponent != null) - return propertiesEditionComponent.getPropertiesEditionPart(kind, key); - return null; - } - - /** - * This method translate a Part name into his identifier - * - * @param key - * the part name - * @return the key identifying the part - */ - public Object translatePart(String key) { - if (propertiesEditionComponent != null) - return propertiesEditionComponent.translatePart(key); - return null; - } - - /** - * @param key - * the key identifying the ElementEditor - * @param kind - * the kind of the part - * @param element - * the element which initialize the part - */ - public void initPart(Object key, int kind, EObject element) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.initPart(key, kind, element); - } - - /** - * @param key - * the key identifying the ElementEditor - * @param kind - * the kind of the part - * @param element - * the element which initialize the part - * @param allResources - * the resource where the part has to process - */ - public void initPart(Object key, int kind, EObject element, ResourceSet allResources) { - if (propertiesEditionComponent != null) - propertiesEditionComponent.initPart(key, kind, element, allResources); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.IStructuredContentProvider#getElements(java.lang.Object) - */ - public Object[] getElements(Object inputElement) { - return new Object[] {inputElement}; - } - - /** - * - */ - protected void updateListeners() { - for (IPropertiesEditionListener listener : propertiesEditionListeners) { - propertiesEditionComponent.addListener(listener); - } - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionMessageManager.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionMessageManager.java deleted file mode 100644 index 275dd70d2..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionMessageManager.java +++ /dev/null @@ -1,76 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.viewers; - -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.impl.notify.PropertiesValidationEditionEvent; -import org.eclipse.swt.widgets.Display; - -/** - * @author Stephane Bouchet - * @author Mikaël Barbero - */ -public abstract class PropertiesEditionMessageManager { - - public void processMessage(IPropertiesEditionEvent event) { - if (event instanceof PropertiesValidationEditionEvent) { - final Diagnostic diag = ((PropertiesValidationEditionEvent)event).getDiagnostic(); - if (diag != null) { - Display.getDefault().asyncExec(new Runnable() { - public void run() { - String message = computeMessage(diag); - if (diag.getSeverity() == Diagnostic.ERROR) { - updateError(message); - } else if (diag.getSeverity() == Diagnostic.WARNING) { - updateWarning(message); - } else { - updateStatus(message); - } - } - }); - } else { - Display.getDefault().asyncExec(new Runnable() { - public void run() { - updateStatus(null); - } - }); - } - } - } - - protected abstract void updateStatus(final String message); - - protected void updateError(final String message) { - updateStatus(message); - } - - protected void updateWarning(final String message) { - updateStatus(message); - } - - private String computeMessage(Diagnostic diag) { - if (diag.getSeverity() == Diagnostic.OK) { - return ""; - } else { - for (Diagnostic child : diag.getChildren()) { - if (child.getSeverity() != Diagnostic.OK) { - if (child.getChildren().isEmpty()) { - return child.getMessage(); - } - return computeMessage(child); - } - } - } - return diag.getMessage(); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionViewer.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionViewer.java deleted file mode 100644 index 684aad4bd..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/PropertiesEditionViewer.java +++ /dev/null @@ -1,643 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.viewers; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.core.runtime.Assert; -import org.eclipse.emf.common.util.Diagnostic; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.ResourceSet; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.api.parts.IFormPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.api.parts.ISWTPropertiesEditionPart; -import org.eclipse.emf.eef.runtime.context.ExtendedPropertiesEditingContext; -import org.eclipse.emf.eef.runtime.context.PropertiesEditingContext; -import org.eclipse.emf.eef.runtime.impl.parts.CompositePropertiesEditionPart; -import org.eclipse.emf.eef.runtime.ui.parts.impl.BindingViewHelper; -import org.eclipse.emf.eef.runtime.ui.utils.EEFRuntimeUIMessages; -import org.eclipse.emf.eef.runtime.ui.viewers.filters.PropertiesEditionPartFilter; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.custom.CTabFolder; -import org.eclipse.swt.custom.CTabItem; -import org.eclipse.swt.custom.ScrolledComposite; -import org.eclipse.swt.events.ControlEvent; -import org.eclipse.swt.events.ControlListener; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.graphics.Color; -import org.eclipse.swt.layout.FillLayout; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Widget; -import org.eclipse.ui.forms.IFormColors; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * @author Goulwen Le Fur - */ -public class PropertiesEditionViewer extends StructuredViewer { - - /** - * Graphical purpose fields - */ - private FormToolkit toolkit; - - /** - * TODO: sets this private - */ - protected CTabFolder folder = null; - - /** - * TODO: sets this private - */ - protected Composite control; - - protected boolean dynamicTabHeader = true; - - /** - * The expected kind for the part. - */ - private int kind; - - private List filters; - - private boolean initState = false; - - protected ResourceSet allResources; - - private ItemListener listener; - - /** - * TODO: sets this private - */ - protected ScrolledComposite scroll; - - /** - * Create an Viewer for EEF properties editing in the given parent composite. - * - * @param parent - * the parent control - * @param style - * the SWT style bits - * @param kind - * the kind of the part - */ - public PropertiesEditionViewer(Composite container, ResourceSet allResources, int style, int kind) { - control = new Composite(container, SWT.NONE); - control.setLayout(new FillLayout()); - control.setLayoutData(new GridData(GridData.FILL_BOTH)); - scroll = new ScrolledComposite(control, SWT.V_SCROLL | SWT.H_SCROLL); - folder = new CTabFolder(scroll, style); - folder.setSimple(false); - this.allResources = allResources; - this.kind = kind; - scroll.setContent(folder); - scroll.setExpandHorizontal(true); - scroll.setExpandVertical(true); - listener = new ItemListener(); - folder.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - listener.updateControlListener(); - } - - }); - control.addControlListener(listener); - } - - /** - * Create an Viewer for EEF properties editing in the given parent composite - * - * @param parent - * the parent control - * @param kind - * the kind of the part - */ - public PropertiesEditionViewer(Composite container, ResourceSet allResources, int kind) { - this(container, allResources, SWT.BORDER, kind); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.Viewer#getControl() - */ - public Control getControl() { - return control; - } - - /** - * @return the toolkit - */ - public FormToolkit getToolkit() { - return toolkit; - } - - /** - * @param toolkit - * the toolkit to set - */ - public void setToolkit(FormToolkit toolkit) { - this.toolkit = toolkit; - toolkit.adapt(control); - toolkit.adapt(scroll); - toolkit.adapt(folder); - } - - /** - * @return true if the viewer is initializing - */ - public boolean isInitializing() { - return initState; - } - - /** - * Defines if the tab headers are visible when there is more than 1 tab. - * - * @param dynamic - * the dynamic tab header - */ - public void setDynamicTabHeader(boolean dynamic) { - dynamicTabHeader = dynamic; - } - - /** - * @param listener - * the properties listener to add - */ - public void addPropertiesListener(IPropertiesEditionListener listener) { - if (getContentProvider() != null) - ((PropertiesEditionContentProvider)getContentProvider()).addPropertiesListener(listener); - } - - /** - * Returns the root element. - *

- * The default implementation of this framework method forwards to getInput. Override if the - * root element is different from the viewer's input element. - *

- * - * @return the root element, or null if none - */ - protected Object getRoot() { - return getEObjectFromInput(); - } - - /** - * @return - */ - public EObject getEObjectFromInput() { - EObject result = null; - if (getInput() instanceof EObject) { - result = (EObject)getInput(); - } else if (getInput() instanceof PropertiesEditingContext) { - result = ((PropertiesEditingContext)getInput()).getEObject(); - } - return result; - } - - /* - * =============================== Filters management =============================== - */ - - /** - * Returns this viewer's filters. - * - * @return an array of viewer filters - * @see StructuredViewer#setFilters(ViewerFilter[]) - */ - public ViewerFilter[] getFilters() { - if (filters == null) { - return new ViewerFilter[0]; - } - ViewerFilter[] result = new ViewerFilter[filters.size()]; - filters.toArray(result); - return result; - } - - /** - * Adds the given filter to this viewer, and triggers refiltering and resorting of the elements. If you - * want to add more than one filter consider using {@link StructuredViewer#setFilters(ViewerFilter[])}. - * - * @param filter - * a viewer filter - * @see StructuredViewer#setFilters(ViewerFilter[]) - */ - public void addFilter(ViewerFilter filter) { - if (filters == null) { - filters = new ArrayList(); - } - filters.add(filter); - refresh(); - } - - /** - * Removes the given filter from this viewer, and triggers refiltering and resorting of the elements if - * required. Has no effect if the identical filter is not registered. If you want to remove more than one - * filter consider using {@link StructuredViewer#setFilters(ViewerFilter[])}. - * - * @param filter - * a viewer filter - * @see StructuredViewer#setFilters(ViewerFilter[]) - */ - public void removeFilter(ViewerFilter filter) { - Assert.isNotNull(filter); - if (filters != null) { - // Note: can't use List.remove(Object). Use identity comparison - // instead. - for (Iterator i = filters.iterator(); i.hasNext();) { - Object o = i.next(); - if (o == filter) { - i.remove(); - refresh(); - if (filters.size() == 0) { - filters = null; - } - return; - } - } - } - } - - /** - * Sets the filters, replacing any previous filters, and triggers refiltering and resorting of the - * elements. - * - * @param filters - * an array of viewer filters - * @since 3.3 - */ - public void setFilters(ViewerFilter[] filters) { - if (filters.length == 0) { - resetFilters(); - } else { - this.filters = new ArrayList(Arrays.asList(filters)); - refresh(); - } - } - - /** - * Discards this viewer's filters and triggers refiltering and resorting of the elements. - */ - public void resetFilters() { - if (filters != null) { - filters = null; - refresh(); - } - } - - /** - * Returns the result of running the given elements through the filters. - * - * @param elements - * the elements to filter - * @return only the elements which all filters accept - */ - private boolean selectPart(String key, IPropertiesEditionPart propertiesEditionPart) { - boolean result = true; - if (filters != null) { - boolean select = true; - for (int j = 0; j < filters.size(); j++) { - ViewerFilter viewerFilter = filters.get(j); - if (viewerFilter instanceof PropertiesEditionPartFilter) { - select = viewerFilter.select(this, key, propertiesEditionPart); - if (!select) { - result = false; - break; - } - } - } - } - return result; - } - - /** - * Validate the model and return the resulting Diagnostic - * - * @param event - * the event triggering the validation - * @return the resulting value - */ - public Diagnostic validateValue(IPropertiesEditionEvent event) { - if (getContentProvider() != null) - return ((PropertiesEditionContentProvider)getContentProvider()).validateValue(event); - return null; - } - - /* - * ============================== Selection management ============================== - */ - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.Viewer#getSelection() - */ - public ISelection getSelection() { - Object root = getRoot(); - if (root != null) - return new StructuredSelection(root); - return new StructuredSelection(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.Viewer#setSelection(org.eclipse.jface.viewers.ISelection, boolean) - */ - public void setSelection(ISelection selection, boolean reveal) { - // TODO Auto-generated method stub - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#setSelectionToWidget(java.util.List, boolean) - */ - protected void setSelectionToWidget(List l, boolean reveal) { - // TODO Auto-generated method stub - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#getSelectionFromWidget() - */ - protected List getSelectionFromWidget() { - // TODO Auto-generated method stub - return null; - } - - /* - * ============================== Graphical management ============================== - */ - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#internalRefresh(java.lang.Object) - */ - protected void internalRefresh(Object element) { - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.Viewer#inputChanged(java.lang.Object, java.lang.Object) - */ - protected void inputChanged(Object input, Object oldInput) { - super.inputChanged(input, oldInput); - initControl(); - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#reveal(java.lang.Object) - */ - public void reveal(Object element) { - // Nothing to do - } - - /** - * @param propertiesEditionContentProvider - * @return - */ - public CompositePropertiesEditionPart getSelectedPart() { - PropertiesEditionContentProvider propertiesEditionContentProvider = (PropertiesEditionContentProvider)getContentProvider(); - String selectedPartTitle = folder.getSelection().getText(); - return (CompositePropertiesEditionPart)propertiesEditionContentProvider.getPropertiesEditionPart(kind, selectedPartTitle); - } - - /** - * Create the control content - */ - protected void initControl() { - if (getContentProvider() != null) { - PropertiesEditionContentProvider propertiesEditionProvider = (PropertiesEditionContentProvider)getContentProvider(); - // first set initState to true to not handle changes yet - initState = true; - String[] partsList = propertiesEditionProvider.partsList(); - initTabbedControl(propertiesEditionProvider, partsList); - initState = false; - } - } - - /** - * Initialize the control of the viewer in "Tabbed case". Defines one tab for each PropertiesEditionPart - * of the component. - * - * @param propertiesEditionProvider - * @param partsList - */ - protected void initTabbedControl(PropertiesEditionContentProvider propertiesEditionProvider, String[] partsList) { - resetTab(); - List selectedParts = new ArrayList(); - if (kind == 1) { - if (propertiesEditionProvider.getPropertiesEditingComponent().getEditingContext() instanceof ExtendedPropertiesEditingContext) { - ExtendedPropertiesEditingContext editingContext = (ExtendedPropertiesEditingContext) propertiesEditionProvider.getPropertiesEditingComponent().getEditingContext(); - editingContext.setHelper(new BindingViewHelper(editingContext, toolkit)); - } - toolkit.adapt(folder, true, true); - toolkit.getColors().initializeSectionToolBarColors(); - folder.setSelectionBackground( - new Color[] {toolkit.getColors().getColor(IFormColors.H_GRADIENT_START), toolkit.getColors().getColor(IFormColors.H_GRADIENT_END)}, - new int[] {50}, - true); - folder.setForeground(toolkit.getColors().getColor(IFormColors.TITLE)); - folder.setSelectionForeground(toolkit.getColors().getColor(IFormColors.TITLE)); - } - for (int i = 0; i < partsList.length; i++) { - String nextComponentKey = partsList[i]; - IPropertiesEditionPart part = propertiesEditionProvider.getPropertiesEditionPart(kind, nextComponentKey); - if (selectPart(nextComponentKey, part)) { - selectedParts.add(nextComponentKey); - addPartTab(propertiesEditionProvider, part, nextComponentKey); - } else { - part.setVisible(false); - } - } - if (dynamicTabHeader) { - if (selectedParts.size() > 1) - folder.setTabHeight(SWT.DEFAULT); - else - folder.setTabHeight(0); - } - folder.setSelection(0); - } - - /** - * Create a new tab in the folder for a given PropertiesEditionPart. - * - * @param propertiesEditionProvider - * the EEF properties provider - * @param key - * the key of the part - * @param tabText - * the title of the tab - */ - private void addPartTab(PropertiesEditionContentProvider propertiesEditionProvider, IPropertiesEditionPart part, String key) { - Composite editComposite = null; - if (part instanceof ISWTPropertiesEditionPart) - editComposite = ((ISWTPropertiesEditionPart)part).createFigure(folder); - if (part instanceof IFormPropertiesEditionPart) { - Assert.isNotNull(toolkit, EEFRuntimeUIMessages.PropertiesEditionViewer_widget_factory_not_defined); - editComposite = ((IFormPropertiesEditionPart)part).createFigure(folder, toolkit); - } - if (editComposite != null) { - if (allResources == null && getEObjectFromInput() != null) - propertiesEditionProvider.initPart(propertiesEditionProvider.translatePart(key), kind, - ((EObject)getEObjectFromInput())); - else - propertiesEditionProvider.initPart(propertiesEditionProvider.translatePart(key), kind, - ((EObject)getEObjectFromInput()), allResources); - } else - editComposite = new Composite(folder, SWT.NONE); - CTabItem tab = new CTabItem(folder, SWT.NONE); - tab.setControl(editComposite); - tab.setText(part.getTitle()); - } - - /** - * Reset all the tabs of the folder. - */ - private void resetTab() { - if (folder.getItemCount() > 0) { - CTabItem[] items = folder.getItems(); - for (int i = 0; i < items.length; i++) { - CTabItem cTabItem = items[i]; - - if (!cTabItem.getControl().isDisposed()) - cTabItem.getControl().dispose(); //adding this line solves my problem. - if (!cTabItem.isDisposed()) - cTabItem.dispose(); - } - } - } - - /** - * Refresh the active tab. - */ - public void refreshTab() { - getSelectedPart().refresh(); - PropertiesEditionContentProvider propertiesEditionContentProvider = (PropertiesEditionContentProvider)getContentProvider(); - propertiesEditionContentProvider.initPart(propertiesEditionContentProvider.translatePart(folder.getSelection().getText()), kind, ((EObject)getEObjectFromInput())); - } - - /* - * ================================= Search methods ================================= - */ - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#doFindInputItem(java.lang.Object) - */ - protected Widget doFindInputItem(Object element) { - // TODO Auto-generated method stub - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#doFindItem(java.lang.Object) - */ - protected Widget doFindItem(Object element) { - // TODO Auto-generated method stub - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#doUpdateItem(org.eclipse.swt.widgets.Widget, - * java.lang.Object, boolean) - */ - protected void doUpdateItem(Widget item, Object element, boolean fullMap) { - // TODO Auto-generated method stub - - } - - /* - * ================================= Scroll management ================================= - */ - /** - * update the scroll composite size - */ - private void updateScrollSize() { - if (folder.getSelection() != null && folder.getSelection().getControl() != null) { - scroll.setMinSize(folder.getSelection().getControl().computeSize(SWT.DEFAULT, SWT.DEFAULT)); - } - } - - private class ItemListener implements ControlListener { - - Control listenedControl = null; - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.ControlListener#controlMoved(org.eclipse.swt.events.ControlEvent) - */ - public void controlMoved(ControlEvent e) { - // Nothing to do - - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.swt.events.ControlListener#controlResized(org.eclipse.swt.events.ControlEvent) - */ - public void controlResized(ControlEvent e) { - updateScrollSize(); - } - - /** - * update listeners managing scroll composite size - */ - public void updateControlListener() { - removeControlListener(); - Control control2 = folder.getSelection().getControl(); - if (control2 != null) { - listener.listenedControl = control2; - control2.addControlListener(listener); - } - - } - - public void removeControlListener() { - if (listener.listenedControl != null && !listener.listenedControl.isDisposed()) { - listener.listenedControl.removeControlListener(listener); - } - } - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/filters/PropertiesEditionPartFilter.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/filters/PropertiesEditionPartFilter.java deleted file mode 100644 index 9e99b5c6d..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/viewers/filters/PropertiesEditionPartFilter.java +++ /dev/null @@ -1,48 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.viewers.filters; - -import org.eclipse.emf.eef.runtime.api.parts.IPropertiesEditionPart; -import org.eclipse.jface.viewers.Viewer; -import org.eclipse.jface.viewers.ViewerFilter; - -/** - * @author Goulwen Le Fur - */ -public class PropertiesEditionPartFilter extends ViewerFilter { - - private String key; - - /** - * Default constructor. - * - * @param key - * the key of the part to select - */ - public PropertiesEditionPartFilter(String key) { - super(); - this.key = key; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, - * java.lang.Object) - */ - @Override - public boolean select(Viewer viewer, Object parentElement, Object element) { - if (parentElement instanceof String && element instanceof IPropertiesEditionPart) - return parentElement.equals(key); - return true; - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/AbstractAdvancedEObjectFlatComboViewer.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/AbstractAdvancedEObjectFlatComboViewer.java deleted file mode 100644 index 50f94d8f4..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/AbstractAdvancedEObjectFlatComboViewer.java +++ /dev/null @@ -1,394 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 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: - * Patrick Tessier (CEA LIST) Patrick.tessier@cea.fr - Initial API and implementation - * Obeo - Some improvements - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.ui.utils.EEFRuntimeUIMessages; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.widgets.settings.EEFEditorSettings; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.MouseAdapter; -import org.eclipse.swt.events.MouseEvent; -import org.eclipse.swt.layout.FormAttachment; -import org.eclipse.swt.layout.FormData; -import org.eclipse.swt.layout.FormLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; -import org.eclipse.ui.forms.widgets.ExpandableComposite; -import org.eclipse.ui.forms.widgets.FormToolkit; - -/** - * This is an Abstract class use to display a label with the referenced named - * Element For example type of a property - * - * @author Patrick Tessier - * @author Jerome Benois - * @author Stephane Bouchet - */ -public abstract class AbstractAdvancedEObjectFlatComboViewer implements - IPropertiesFilteredWidget { - - /** Image for the remove button */ - protected final org.eclipse.swt.graphics.Image deleteImage = EEFRuntimePlugin - .getImage(EEFRuntimePlugin.ICONS_16x16 + "Delete_16x16.gif"); //$NON-NLS-1$ - - /** Image for the add button */ - protected final org.eclipse.swt.graphics.Image addImage = EEFRuntimePlugin - .getImage(EEFRuntimePlugin.ICONS_16x16 + "Add_16x16.gif"); //$NON-NLS-1$ - - protected static final String UNDEFINED_VALUE = ""; //$NON-NLS-1$ - - /** - * the dialog title - */ - private String dialogTitle = ""; //$NON-NLS-1$ - - /** The parent Composite */ - protected Composite parent; - - protected EObject selection; - - protected Object input; - - protected Button browseButton; - - protected EObjectFlatComboViewerListener callback; - - /** - * The main composite - */ - protected Composite composite; - - /** - * The adapter factory. - */ - protected AdapterFactory adapterFactory; - - protected AdapterFactoryLabelProvider labelProvider; - - protected List filters; - - protected List brFilters; - - protected FormToolkit widgetFactory; - - protected ButtonsModeEnum button_mode = ButtonsModeEnum.BROWSE; - - private Resource mainResource; - - private Button removeButton; - - protected Text field; - - /** - * the constructor of this display - * - * @param labeltoDisplay - * use to display the name is the label - * @param filter - * use to look for the good element - */ - public AbstractAdvancedEObjectFlatComboViewer(String dialogTitle, Object input, - ViewerFilter filter, AdapterFactory adapterFactory, - EObjectFlatComboViewerListener callback) { - this.dialogTitle = dialogTitle; - this.input = input; - this.callback = callback; - this.labelProvider = new AdapterFactoryLabelProvider(adapterFactory); - this.filters = new ArrayList(); - if (filter != null) { - this.filters.add(filter); - } - this.brFilters = new ArrayList(); - this.adapterFactory = adapterFactory; - } - - public void createControls(Composite parent, FormToolkit widgetFactory) { - this.widgetFactory = widgetFactory; - createControls(parent); - } - - public void createControls(Composite parent) { - - this.composite = createComposite(parent); - this.parent = parent; - if (parent instanceof ExpandableComposite) { - ((ExpandableComposite) parent).setClient(composite); - } - - FormLayout layout = new FormLayout(); - layout.marginWidth = 1;// 7; - layout.marginHeight = 1;// 4; - layout.spacing = 7; - // layout.marginTop = 7; - composite.setLayout(layout); - - // browse and remove Buttons - createButtons(composite); - // display and value labels - createLabels(composite); - - } - - private void createButtons(Composite parent) { - removeButton = createButton(parent, "", SWT.PUSH); - removeButton.setImage(deleteImage); - FormData data = new FormData(); - data.right = new FormAttachment(100, -5); - data.top = new FormAttachment(0, -2); - removeButton.setLayoutData(data); - removeButton - .setToolTipText(EEFRuntimeUIMessages.AdvancedEObjectFlatComboViewer_remove_tooltip); - EditingUtils.setEEFtype(removeButton, "eef::AdvancedEObjectFlatComboViewer::removebutton"); - - this.browseButton = createButton(parent, "", SWT.PUSH); //$NON-NLS-1$ - browseButton.setImage(addImage); - data = new FormData(); - data.right = new FormAttachment(removeButton, 2); - data.top = new FormAttachment(0, -2); - browseButton.setLayoutData(data); - browseButton.setToolTipText(EEFRuntimeUIMessages.AdvancedEObjectFlatComboViewer_set_tooltip); - EditingUtils.setEEFtype(browseButton, "eef::AdvancedEObjectFlatComboViewer::browsebutton"); - - // listeners setting - removeButton.addMouseListener(new MouseAdapter() { - @Override - public void mouseUp(MouseEvent e) { - // reset value - handleSelection(null); - } - }); - browseButton.addMouseListener(new MouseAdapter() { - @Override - public void mouseUp(MouseEvent e) { - browseButtonPressed(); - } - }); - } - - public void setInput(Object input) { - this.input = input; - } - - /** - * Sets the given ID to the EObjectFlatComboViewer - * - * @param id - * the id of the widget - */ - public void setID(Object id) { - EditingUtils.setID(field, id); - EditingUtils.setID(removeButton, id); - EditingUtils.setID(browseButton, id); - } - - /** - * @return the ID of the EObjectFlatComboViewer - */ - public Object getID() { - return EditingUtils.getID(field); - } - - protected abstract void createLabels(Composite parent); - - private Composite createComposite(Composite parent) { - Composite composite; - if (widgetFactory == null) { - composite = new Composite(parent, SWT.NONE); - } else { - composite = widgetFactory.createComposite(parent); - } - return composite; - } - - protected Button createButton(Composite parent, String text, int style) { - Button button; - if (widgetFactory == null) { - button = new Button(parent, style); - button.setText(text); - } else { - button = widgetFactory.createButton(parent, text, style); - } - return button; - } - - public abstract void setSelection(ISelection selection); - - public abstract void setSelection(EObject selection); - - public EObject getSelection() { - return selection; - } - - /** - * Behavior executed when browse button is pressed. - */ - protected void browseButtonPressed() { - switch (button_mode) { - case BROWSE: - TabElementTreeSelectionDialog dialog = new TabElementTreeSelectionDialog( - input, filters, brFilters, dialogTitle, adapterFactory, - getMainResource()) { - @Override - public void process(IStructuredSelection selection) { - if (selection != null && !selection.isEmpty()) { - handleSelection((EObject) selection.getFirstElement()); - } - } - }; - // Select the actual element in dialog - if (selection != null) { - dialog.setSelection(new StructuredSelection(selection)); - } - dialog.open(); - break; - case CREATE: - handleCreate(); - break; - default: - break; - } - } - - public void handleSelection(EObject selectedElement) { - setSelection(selectedElement); - callback.handleSet(selectedElement); - } - - public void handleCreate() { - setSelection(callback.handleCreate()); - } - - public void handleEdit(EObject element) { - callback.handleEdit(element); - // refresh the text; - setSelection(element); - } - - public interface EObjectFlatComboViewerListener { - public void handleSet(EObject element); - - public void navigateTo(EObject element); - - public EObject handleCreate(); - - public void handleEdit(EObject element); - } - - /** - * @param layoutData - * the layoutData to set - */ - public void setLayoutData(Object layoutData) { - composite.setLayoutData(layoutData); - } - - public void addFilter(ViewerFilter filter) { - filters.add(filter); - } - - public void addBusinessRuleFilter(ViewerFilter filter) { - brFilters.add(filter); - } - - public void removeBusinessRuleFilter(ViewerFilter filter) { - brFilters.remove(filter); - } - - public void removeFilter(ViewerFilter filter) { - filters.remove(filter); - } - - public void setButtonMode(ButtonsModeEnum button_mode) { - this.button_mode = button_mode; - } - - /** - * Returns the main resource. - * - * @return the main resource. - */ - - public Resource getMainResource() { - if (this.mainResource == null && this.input instanceof EEFEditorSettings) { - Resource mainResourceFromSettings = null; - - // Gets the mainResource from the settings. - EEFEditorSettings settings = (EEFEditorSettings) this.input; - if (settings.getSource() != null) { - // The default mainResource is the resource of the edited - // object. - mainResourceFromSettings = settings.getSource().eResource(); - if (settings.getValue() instanceof EObject && ((EObject) settings.getValue()).eResource() != null) { - - // The mainResource is the resource of the value. - mainResourceFromSettings = ((EObject) settings.getValue()).eResource(); - } - } - if (mainResourceFromSettings != null) { - return mainResourceFromSettings; - } - } - - // - - // Client has specified a main resource. Let's use it ! - - return this.mainResource; - - } - - public void setMainResource(Resource mainResource) { - this.mainResource = mainResource; - } - - /** - * Sets the viewer readonly - * - * @param enabled - * sets the viewer read only or not. - */ - public void setEnabled(boolean enabled) { - browseButton.setEnabled(enabled); - removeButton.setEnabled(enabled); - } - - /** - * @return if the table is enabled - */ - public boolean isEnabled() { - return true; - } - - /** - * Sets the tooltip text on the viewer - * - * @param tooltip - * the tooltip text - */ - public void setToolTipText(String tooltip) { - browseButton.setToolTipText(tooltip); - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/AdvancedEObjectFlatComboViewer.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/AdvancedEObjectFlatComboViewer.java deleted file mode 100644 index d9b14f8fd..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/AdvancedEObjectFlatComboViewer.java +++ /dev/null @@ -1,169 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2013 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: - * Patrick Tessier (CEA LIST) Patrick.tessier@cea.fr - Initial API and implementation - * Obeo - Some improvements - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.MouseAdapter; -import org.eclipse.swt.events.MouseEvent; -import org.eclipse.swt.layout.FormAttachment; -import org.eclipse.swt.layout.FormData; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Text; - -/** - * This is an Abstract class use to display a label with the referenced named - * Element For example type of a property - * - * @author Patrick Tessier - * @author Jerome Benois - * @author Stephane Bouchet - */ -public class AdvancedEObjectFlatComboViewer extends AbstractAdvancedEObjectFlatComboViewer { - - /** Associated text */ - protected Text valueText; - - /** - * the constructor of this display - * - * @param labeltoDisplay - * use to display the name is the label - * @param filter - * use to look for the good element - */ - public AdvancedEObjectFlatComboViewer(String dialogTitle, Object input, - ViewerFilter filter, AdapterFactory adapterFactory, - org.eclipse.emf.eef.runtime.ui.widgets.AbstractAdvancedEObjectFlatComboViewer.EObjectFlatComboViewerListener callback) { - super(dialogTitle, input, filter, adapterFactory, callback); - } - - protected void createLabels(Composite parent) { - // Display label - // final Label displayLabel = createLabel(parent, dialogTitle, - // SWT.NONE); - // FormData data = new FormData(); - // data.left = new FormAttachment(0, 0); - // data.top = new FormAttachment(0, 0); - // displayLabel.setLayoutData(data); - - // Value Label - String value = UNDEFINED_VALUE; - if (selection != null) { - value = labelProvider.getText(selection); - } - this.valueText = createText(parent, value, SWT.NONE); - valueText.setEditable(false); - // TODO set background color and dispose! - // valueText.setEnabled(false); - // valueText.setBackground(...); - FormData data = new FormData(); - // data.left = new FormAttachment(displayLabel, 5); - data.left = new FormAttachment(0, 0); - data.right = new FormAttachment(browseButton, 0); - data.top = new FormAttachment(0, 1); - valueText.setLayoutData(data); - valueText.addMouseListener(new MouseAdapter() { - @Override - public void mouseDoubleClick(MouseEvent e) { - callback.navigateTo(selection); - } - }); - } - - private Text createText(Composite parent, String value, int style) { - if (widgetFactory == null) { - field = new Text(parent, SWT.PUSH); - field.setText(value); - } else { - field = widgetFactory.createText(parent, value, style); - } - EditingUtils.setEEFtype(field, - "eef::AdvancedEObjectFlatComboViewer::field"); - return field; - } - - public void setSelection(ISelection selection) { - if (selection instanceof StructuredSelection) { - StructuredSelection structuredSelection = (StructuredSelection) selection; - if (!structuredSelection.isEmpty() - && !"".equals(structuredSelection.getFirstElement())) { - setSelection((EObject) structuredSelection.getFirstElement()); - } else { - this.valueText.setText(UNDEFINED_VALUE); - // this.parent.pack(); - } - } - } - - public void setSelection(EObject selection) { - this.selection = selection; - String text = labelProvider.getText(selection); - if ("".equals(text)) //$NON-NLS-1$ - this.valueText.setText(UNDEFINED_VALUE); - else - this.valueText.setText(text); - } - - /** - * Sets the viewer readonly - * - * @param enabled - * sets the viewer read only or not. - */ - public void setEnabled(boolean enabled) { - super.setEnabled(enabled); - valueText.setEnabled(enabled); - } - - /** - * Sets the given ID to the EObjectFlatComboViewer - * - * @param id - * the id of the widget - */ - public void setID(Object id) { - super.setID(id); - EditingUtils.setID(valueText, id); - } - - - /** - * @return if the table is enabled - */ - public boolean isEnabled() { - return super.isEnabled() && valueText.isEnabled(); - } - - /** - * Sets the tooltip text on the viewer - * - * @param tooltip - * the tooltip text - */ - public void setToolTipText(String tooltip) { - super.setToolTipText(tooltip); - valueText.setToolTipText(tooltip); - } - - @Deprecated - public static abstract class EObjectFlatComboViewerListener implements org.eclipse.emf.eef.runtime.ui.widgets.AbstractAdvancedEObjectFlatComboViewer.EObjectFlatComboViewerListener { - - public void handleEdit(EObject element) {} - - } -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ButtonsModeEnum.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ButtonsModeEnum.java deleted file mode 100644 index 45abce742..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ButtonsModeEnum.java +++ /dev/null @@ -1,18 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets; - -/** - * @author Stephane Bouchet - */ -public enum ButtonsModeEnum { - BROWSE, CREATE -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ContainmentPropertiesEditingViewer.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ContainmentPropertiesEditingViewer.java deleted file mode 100644 index fdca55d6f..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/ContainmentPropertiesEditingViewer.java +++ /dev/null @@ -1,649 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2012 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ - -package org.eclipse.emf.eef.runtime.ui.widgets; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; -import org.eclipse.emf.eef.runtime.EEFRuntimePlugin; -import org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent; -import org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionListener; -import org.eclipse.emf.eef.runtime.context.impl.DomainPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.context.impl.EObjectPropertiesEditionContext; -import org.eclipse.emf.eef.runtime.impl.utils.EEFUtils; -import org.eclipse.emf.eef.runtime.ui.utils.EditingUtils; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionContentProvider; -import org.eclipse.emf.eef.runtime.ui.viewers.PropertiesEditionViewer; -import org.eclipse.emf.eef.runtime.ui.widgets.ReferencesTable.ReferencesTableListener; -import org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableContentProvider; -import org.eclipse.jface.resource.JFaceColors; -import org.eclipse.jface.resource.JFaceResources; -import org.eclipse.jface.viewers.IContentProvider; -import org.eclipse.jface.viewers.StructuredViewer; -import org.eclipse.swt.SWT; -import org.eclipse.swt.custom.CLabel; -import org.eclipse.swt.custom.ScrolledComposite; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.graphics.Color; -import org.eclipse.swt.graphics.Image; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Widget; -import org.eclipse.ui.forms.FormColors; -import org.eclipse.ui.forms.IFormColors; -import org.eclipse.ui.forms.widgets.FormToolkit; -import org.eclipse.ui.forms.widgets.ScrolledForm; - -/** - * @author Goulwen Le Fur - * - */ -public class ContainmentPropertiesEditingViewer extends StructuredViewer { - - /** - * Image for the add element button. - */ - final protected static Image NEW_ELEMENT_IMG = EEFRuntimePlugin.getImage(EEFRuntimePlugin.ICONS_16x16 - + "Add_16x16.gif"); //$NON-NLS-1$ - - /** - * Image for the delete element button. - */ - final protected static Image DELETE_ELEMENT_IMG = EEFRuntimePlugin.getImage(EEFRuntimePlugin.ICONS_16x16 - + "Delete_16x16.gif"); //$NON-NLS-1$ - - /** - * Image for the up button. - */ - final protected static Image UP_ELEMENT_IMG = EEFRuntimePlugin.getImage(EEFRuntimePlugin.ICONS_16x16 - + "ArrowUp_16x16.gif"); //$NON-NLS-1$ - - /** - * Image for the down button. - */ - final protected static Image DOWN_ELEMENT_IMG = EEFRuntimePlugin.getImage(EEFRuntimePlugin.ICONS_16x16 - + "ArrowDown_16x16.gif"); //$NON-NLS-1$ - - private Composite control; - - private int kind; - private String mode; - private FormToolkit toolkit; - private IPropertiesEditionComponent component; - private Object viewerInput; - - private List listeners; - - private boolean scrolledFormSearched; - private ScrolledForm scrolledForm; - - private boolean refreshState; - private CLabel title; - private Button addButton; - private Label helpButton; - private FormColors colors; - - - - - /** - * Default container for SWT mode. - * @param parent parent composite - * @param kind kind of view - */ - public ContainmentPropertiesEditingViewer(Composite parent, int kind) { - super(); - this.kind = kind; - this.listeners = new ArrayList(); - this.scrolledFormSearched = false; - - control = new Composite(parent, SWT.NONE); - GridLayout layout = new GridLayout(2, false); - layout.marginLeft = -4; - ((Composite) control).setLayout(layout); - title = new CLabel((Composite) control, SWT.NONE); - title.setLayoutData(new GridData(GridData.FILL_HORIZONTAL)); - addButton = new Button((Composite) control, SWT.PUSH); - addButton.setImage(NEW_ELEMENT_IMG); - addButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - for (ReferencesTableListener listener : listeners) { - listener.handleAdd(); - } - } - - - }); - } - - /** - * Constructor with toolkit for Form mode. - * @param parent parent composite - * @param kind kind of view - * @param toolkit toolkit to use - */ - public ContainmentPropertiesEditingViewer(Composite parent, int kind, FormToolkit toolkit) { - super(); - this.kind = kind; - this.toolkit = toolkit; - this.listeners = new ArrayList(); - this.scrolledFormSearched = false; - - control = toolkit.createComposite(parent, SWT.NONE); - GridLayout layout = new GridLayout(3, false); - layout.marginLeft = -4; - ((Composite) control).setLayout(layout); - title = new CLabel((Composite) control, SWT.NONE); - title.setLayoutData(new GridData(GridData.FILL_HORIZONTAL)); - EditingUtils.setEEFtype(title, "eef::ContainmentPropertiesEditingViewer::title"); - addButton = toolkit.createButton((Composite) control, "", SWT.PUSH); - addButton.setImage(NEW_ELEMENT_IMG); - addButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - public void widgetSelected(SelectionEvent e) { - for (ReferencesTableListener listener : listeners) { - listener.handleAdd(); - } - } - - - }); - EditingUtils.setEEFtype(addButton, "eef::ContainmentPropertiesEditingViewer::addbutton"); - Control createHelpButton = FormUtils.createHelpButton(toolkit, control, "", ""); - if (createHelpButton instanceof Label) { - helpButton = (Label)createHelpButton; - GridData layoutData = new GridData(); - layoutData.widthHint = 0; - createHelpButton.setLayoutData(layoutData); - } - } - - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#doFindInputItem(java.lang.Object) - */ - @Override - protected Widget doFindInputItem(Object element) { - // TODO Auto-generated method stub - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#doFindItem(java.lang.Object) - */ - @Override - protected Widget doFindItem(Object element) { - // TODO Auto-generated method stub - return null; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#doUpdateItem(org.eclipse.swt.widgets.Widget, - * java.lang.Object, boolean) - */ - @Override - protected void doUpdateItem(Widget item, Object element, boolean fullMap) { - // TODO Auto-generated method stub - - } - - /** - * @param listener to add. - */ - public void addListener(ReferencesTableListener listener) { - listeners.add(listener); - } - - /** - * @param listener to remove. - */ - public void removeListener(ReferencesTableListener listener) { - listeners.remove(listener); - } - - /** - * @param mode the mode to set - */ - public void setMode(String mode) { - this.mode = mode; - } - - /** - * @return the component - */ - public IPropertiesEditionComponent getPropertiesEditingComponent() { - return component; - } - - /** - * @param component the component to set - */ - public void setPropertiesEditingComponent(IPropertiesEditionComponent component) { - this.component = component; - } - - /** - * @param text title of the widget. - */ - public void setText(String text) { - if (text != null) { - title.setText(text); - } - } - - /** - * @param text help of the widget - */ - public void setHelpText(String text) { - if (text != null && !"".equals(text)) { - ((GridData)helpButton.getLayoutData()).widthHint = 25; - helpButton.setToolTipText(text); - } else { - ((GridData)helpButton.getLayoutData()).widthHint = 0; - } - } - - /** - * @param id - */ - public void setID(Object id) { - EditingUtils.setID(control, id); - EditingUtils.setID(title, id); - EditingUtils.setID(addButton, id); - } - - /** - * @param required whether the feature is required or not. - */ - public void setRequired(boolean required) { - if (required) { - title.setFont(JFaceResources.getFontRegistry().getBold(JFaceResources.DEFAULT_FONT)); - } else { - title.setFont(JFaceResources.getFontRegistry().get(JFaceResources.DEFAULT_FONT)); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#internalRefresh(java.lang.Object) - */ - @Override - protected void internalRefresh(Object element) { - clear(); - this.viewerInput = element; - if (getContentProvider() != null) { - refreshState = true; - Object[] elements = getChildrenViewer(element); - for (Object object : elements) { - if (object instanceof EObject) { - Composite controlAsComposite = (Composite) control; - createChild((EObject) object, controlAsComposite); - } - } - refreshState = false; - } - if (control.getLayoutData() instanceof GridData) { - Composite parent = control.getParent(); - while (parent != null) { - parent.layout(true); - if (parent instanceof ScrolledComposite){ - parent = null; - } else { - parent = parent.getParent(); - } - } - control.layout(true); - - } - ScrolledForm owningScrolledForm = owningScrolledForm(control); - if (owningScrolledForm != null) { - owningScrolledForm.reflow(true); - } - - } - - /** - * @param element to process - * @return the children of the element. - */ - private Object[] getChildrenViewer(Object element) { - ReferencesTableContentProvider propertiesEditionProvider = (ReferencesTableContentProvider)getContentProvider(); - Object[] elements = propertiesEditionProvider.getElements(element); - return elements; - } - - /** - * @param elements - * @param searched - * @return - */ - private int indexOf(Object searched) { - Object[] elements = getChildrenViewer(viewerInput); - for (int i = 0; i < elements.length; i++) { - if (searched.equals(elements[i])) { - return i; - } - } - return -1; - } - - /** - * Remove all the children elements of the viewer. - */ - protected void clear() { - for (Control child : control.getChildren()) { - if (child instanceof ChildComposite) { - child.dispose(); - } - } - } - - /** - * @param composite - * @return the ScrolledForm owning the current viewer null otherwise. - */ - private ScrolledForm gettingOwningScrolledForm(Composite composite) { - if (composite instanceof ScrolledForm) { - return (ScrolledForm) composite; - } else if (composite != null) { - return owningScrolledForm(composite.getParent()); - } else { - return null; - } - } - - /** - * Search the ScrolledForm owning the current viewer. - * @param composite current viewer. - * @return the ScrolledForm owning the current viewer null otherwise. - */ - private ScrolledForm owningScrolledForm(Composite composite) { - if (!scrolledFormSearched) { - scrolledForm = gettingOwningScrolledForm(composite); - scrolledFormSearched = true; - } - return scrolledForm; - } - - /** - * Creates a ChildComposite for the given EObject. - * @param object EObject to display. - * @param parent the viewer control. - */ - private void createChild(EObject object, Composite parent) { - ChildComposite child = new ChildComposite(parent, SWT.NONE); - child.setInput(object); - } - - private String labelTitle(Object object) { - IItemLabelProvider labelProvider = (IItemLabelProvider) adapterFactory().adapt(object, IItemLabelProvider.class); - String text = null; - if (labelProvider != null) - text = labelProvider.getText(object); - else - text = object.toString(); - return text; - } - - private Image labelImage(Object object) { - return new AdapterFactoryLabelProvider(adapterFactory()).getImage(object); - } - private AdapterFactory adapterFactory() { - return component.getEditingContext().getAdapterFactory(); - } - - protected IContentProvider getInternContentProvider() { - if (component != null && component.getEditingContext() != null) { - if (mode == IPropertiesEditionComponent.LIVE_MODE) { - return new PropertiesEditionContentProvider(adapterFactory(), mode, EEFUtils.getEditingDomain(component.getEditingContext())); - } else { - try { - return new PropertiesEditionContentProvider(adapterFactory(), mode); - } catch (InstantiationException e) { - throw new IllegalStateException("An EditingDomain must be defined for live mode."); - } - } - } else { - throw new IllegalStateException("A PropertiesEditingComponent must be defined for this widget."); - } - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#reveal(java.lang.Object) - */ - @Override - public void reveal(Object element) {} - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#getSelectionFromWidget() - */ - @Override - protected List getSelectionFromWidget() { - return Collections.EMPTY_LIST; - } - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.StructuredViewer#setSelectionToWidget(java.util.List, - * boolean) - */ - @Override - protected void setSelectionToWidget(List l, boolean reveal) {} - - /** - * {@inheritDoc} - * - * @see org.eclipse.jface.viewers.Viewer#getControl() - */ - @Override - public Control getControl() { - return control; - } - - private Color getColor(String key) { - if (colors == null) { - colors = new FormColors(control.getDisplay()); - } - return colors.getColor(key); - } - - private class ChildComposite extends Composite { - - private CLabel objectTitle; - private PropertiesEditionViewer viewer; - private EObject input; - private IPropertiesEditionListener listener; - - public ChildComposite(Composite parent, int style) { - super(parent, style); - GridData compositeData = new GridData(GridData.FILL_BOTH); - compositeData.horizontalSpan= 3; - setLayoutData(compositeData); - GridLayout layout = new GridLayout(4, false); - layout.marginWidth = 5; - layout.verticalSpacing = 5; - setLayout(layout); - Button removeButton; - Button upButton; - Button downButton; - if (kind == 1) { - setBackground(getColor(IFormColors.TB_BG)); - objectTitle = new CLabel(this, SWT.NONE); - removeButton = toolkit.createButton(this, "", SWT.PUSH); - upButton = toolkit.createButton(this, "", SWT.PUSH); - downButton = toolkit.createButton(this, "", SWT.PUSH); - } else { - setBackground(JFaceColors.getBannerBackground(getDisplay())); - objectTitle = new CLabel(this, SWT.NONE); - objectTitle.setBackground(JFaceColors.getBannerBackground(getDisplay())); - removeButton = new Button(this, SWT.PUSH); - upButton = new Button(this, SWT.PUSH); - downButton = new Button(this, SWT.PUSH); - } - EditingUtils.setEEFtype(objectTitle, "eef::ContainmentPropertiesEditingViewer::childtitle"); - EditingUtils.setEEFtype(removeButton, "eef::ContainmentPropertiesEditingViewer::removechildbutton"); - EditingUtils.setEEFtype(upButton, "eef::ContainmentPropertiesEditingViewer::upchildbutton"); - EditingUtils.setEEFtype(downButton, "eef::ContainmentPropertiesEditingViewer::downchildbutton"); - GridData labelData = new GridData(GridData.FILL_HORIZONTAL); - objectTitle.setLayoutData(labelData); - removeButton.setImage(DELETE_ELEMENT_IMG); - removeButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - @Override - public void widgetSelected(SelectionEvent e) { - for (ReferencesTableListener listener : listeners) { - listener.handleRemove(input); - } - } - - }); - upButton.setImage(UP_ELEMENT_IMG); - upButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - @Override - public void widgetSelected(SelectionEvent e) { - for (ReferencesTableListener listener : listeners) { - int indexOf = indexOf(input); - if (indexOf > 0) { - listener.handleMove(input, indexOf, indexOf - 1); - } - } - } - - - }); - downButton.setImage(DOWN_ELEMENT_IMG); - downButton.addSelectionListener(new SelectionAdapter() { - - /** - * {@inheritDoc} - * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent) - */ - @Override - public void widgetSelected(SelectionEvent e) { - for (ReferencesTableListener listener : listeners) { - int indexOf = indexOf(input); - if (indexOf > -1 && indexOf < (getChildrenViewer(viewerInput).length - 1)) { - listener.handleMove(input, indexOf, indexOf + 1); - } - } - } - - - }); - viewer = new PropertiesEditionViewer(this, null, SWT.NONE, kind); - if (toolkit != null) { - viewer.setToolkit(toolkit); - } - viewer.setContentProvider(getInternContentProvider()); - GridData data = new GridData(GridData.FILL_HORIZONTAL); - data.horizontalSpan = 4; - viewer.getControl().setLayoutData(data); - } - - /** - * Defines input of the viewer. - * @param object the viewer input - */ - public void setInput(EObject object) { - this.input = object; - if (component != null && component.getEditingContext() != null) { - if (mode == IPropertiesEditionComponent.LIVE_MODE) { - viewer.setInput(new DomainPropertiesEditionContext(component.getEditingContext(), component, EEFUtils.getEditingDomain(component.getEditingContext()), adapterFactory(), (EObject) object)); - } else { - viewer.setInput(new EObjectPropertiesEditionContext(component.getEditingContext(), component, (EObject) object, adapterFactory())); - } - } else { - viewer.setInput(object); - } - listener = new IPropertiesEditionListener() { - - public void firePropertiesChanged(IPropertiesEditionEvent event) { - refreshTitle(input); - } - }; - ((PropertiesEditionContentProvider)viewer.getContentProvider()).addPropertiesListener(listener); - refreshTitle(object); - } - - /** - * {@inheritDoc} - * @see org.eclipse.swt.widgets.Widget#dispose() - */ - @Override - public void dispose() { - if (listener != null) { - ((PropertiesEditionContentProvider)viewer.getContentProvider()).removePropertiesListener(listener); - } - super.dispose(); - } - - /** - * @return input of the viewer. - */ - public EObject getInput() { - return input; - } - - public void refreshTitle(Object object) { - objectTitle.setText(labelTitle(object)); - Image labelImage = labelImage(object); - if (labelImage != null) { - objectTitle.setImage(labelImage); - } - } - - - - } - -} diff --git a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/EEFFeatureEditorDialog.java b/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/EEFFeatureEditorDialog.java deleted file mode 100644 index d956ccaf9..000000000 --- a/plugins/org.eclipse.emf.eef.runtime/src/org/eclipse/emf/eef/runtime/ui/widgets/EEFFeatureEditorDialog.java +++ /dev/null @@ -1,485 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2011 Obeo. - * 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: - * Obeo - initial API and implementation - *******************************************************************************/ -package org.eclipse.emf.eef.runtime.ui.widgets; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; -import org.eclipse.emf.common.ui.celleditor.ExtendedComboBoxCellEditor; -import org.eclipse.emf.common.util.BasicEList; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClassifier; -import org.eclipse.emf.ecore.EDataType; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.ItemProvider; -import org.eclipse.emf.edit.ui.EMFEditUIPlugin; -import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider; -import org.eclipse.emf.eef.runtime.impl.filters.business.BusinessViewerFilter; -import org.eclipse.emf.eef.runtime.ui.utils.EEFRuntimeUIMessages; -import org.eclipse.jface.dialogs.Dialog; -import org.eclipse.jface.viewers.DoubleClickEvent; -import org.eclipse.jface.viewers.IContentProvider; -import org.eclipse.jface.viewers.IDoubleClickListener; -import org.eclipse.jface.viewers.ILabelProvider; -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.StructuredSelection; -import org.eclipse.jface.viewers.TableViewer; -import org.eclipse.jface.viewers.ViewerFilter; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.KeyAdapter; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Display; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.swt.widgets.Table; -import org.eclipse.swt.widgets.Text; - -/** - * @author Goulwen Le Fur - */ -public class EEFFeatureEditorDialog extends Dialog { - - protected ILabelProvider labelProvider; - - protected IContentProvider contentProvider; - - protected Object object; - - protected EClassifier eClassifier; - - protected String displayName; - - protected ItemProvider values; - - protected List choiceOfValues; - - protected EList result; - - protected boolean multiLine; - - /** - * List of static filters - */ - private List filters; - - /** - * List of business filters - */ - private List brFilters; - - public EEFFeatureEditorDialog(Shell parent, String displayName, ILabelProvider labelProvider, - List currentValues, List choiceOfValues, boolean multiLine, boolean sortChoices, - List filters, List brFilters) { - super(parent); - setShellStyle(getShellStyle() | SWT.RESIZE | SWT.MAX); - this.labelProvider = labelProvider; - this.displayName = displayName; - this.choiceOfValues = choiceOfValues; - this.multiLine = multiLine; - this.filters = filters; - this.brFilters = brFilters; - - AdapterFactory adapterFactory = new ComposedAdapterFactory(Collections. emptyList()); - values = new ItemProvider(adapterFactory, currentValues); - contentProvider = new AdapterFactoryContentProvider(adapterFactory); - if (sortChoices && choiceOfValues != null) { - this.choiceOfValues = new ArrayList(choiceOfValues); - ExtendedComboBoxCellEditor.createItems(this.choiceOfValues, labelProvider, true); - } - } - - public EEFFeatureEditorDialog(Shell parent, String displayName, ILabelProvider labelProvider, - List currentValues, EClassifier eClassifier, List choiceOfValues, boolean multiLine, - boolean sortChoices, List filters, List brFilters) { - this(parent, displayName, labelProvider, currentValues, choiceOfValues, multiLine, sortChoices, - filters, brFilters); - this.eClassifier = eClassifier; - } - - @Override - protected void configureShell(Shell shell) { - super.configureShell(shell); - shell.setText(EMFEditUIPlugin.INSTANCE.getString( - "_UI_FeatureEditorDialog_title", new Object[] {displayName, //$NON-NLS-1$ - labelProvider.getText(object)})); - shell.setImage(labelProvider.getImage(object)); - } - - @Override - protected Control createDialogArea(Composite parent) { - - Composite contents = (Composite)super.createDialogArea(parent); - - GridLayout contentsGridLayout = (GridLayout)contents.getLayout(); - contentsGridLayout.numColumns = 3; - - GridData contentsGridData = (GridData)contents.getLayoutData(); - contentsGridData.horizontalAlignment = SWT.FILL; - contentsGridData.verticalAlignment = SWT.FILL; - - Composite choiceComposite = new Composite(contents, SWT.NONE); - { - GridData data = new GridData(SWT.FILL, SWT.FILL, true, true); - data.horizontalAlignment = SWT.END; - choiceComposite.setLayoutData(data); - - GridLayout layout = new GridLayout(); - data.horizontalAlignment = SWT.FILL; - layout.marginHeight = 0; - layout.marginWidth = 0; - layout.numColumns = 1; - choiceComposite.setLayout(layout); - } - - Label choiceLabel = new Label(choiceComposite, SWT.NONE); - choiceLabel - .setText(choiceOfValues == null ? EMFEditUIPlugin.INSTANCE.getString("_UI_Value_label") : EMFEditUIPlugin.INSTANCE //$NON-NLS-1$ - .getString("_UI_Choices_label")); //$NON-NLS-1$ - GridData choiceLabelGridData = new GridData(); - choiceLabelGridData.verticalAlignment = SWT.FILL; - choiceLabelGridData.horizontalAlignment = SWT.FILL; - choiceLabel.setLayoutData(choiceLabelGridData); - - final Table choiceTable = choiceOfValues == null ? null : new Table(choiceComposite, SWT.MULTI - | SWT.BORDER); - if (choiceTable != null) { - GridData choiceTableGridData = new GridData(); - choiceTableGridData.widthHint = Display.getCurrent().getBounds().width / 5; - choiceTableGridData.heightHint = Display.getCurrent().getBounds().height / 3; - choiceTableGridData.verticalAlignment = SWT.FILL; - choiceTableGridData.horizontalAlignment = SWT.FILL; - choiceTableGridData.grabExcessHorizontalSpace = true; - choiceTableGridData.grabExcessVerticalSpace = true; - choiceTable.setLayoutData(choiceTableGridData); - } - - final TableViewer choiceTableViewer = choiceOfValues == null ? null : new TableViewer(choiceTable); - if (choiceTableViewer != null) { - choiceTableViewer.setContentProvider(new AdapterFactoryContentProvider(new AdapterFactoryImpl())); - choiceTableViewer.setLabelProvider(labelProvider); - choiceTableViewer.setInput(new ItemProvider(choiceOfValues)); - if (filters != null) { - for (ViewerFilter filter : filters) { - choiceTableViewer.addFilter(filter); - } - } - // business rules - List